Student EMG Recorder Program
This program can be used with an EMG pre-amplifier to record two channels of EMG. Run the "html" file from here: EMG_rec (if you want to run the program just left click on the link, after ensuring that Java has been installed and configured as described below). If you want to download the "html" file right click and save the file, and download the program from here: program. These two files are all you need.

Save the two files and click on the "html" file to run it from within a web browser.


This program is used to display and record EMG signals acquired through the sound card of a computer. The program requires Java Runtime Environment Version 5. Click here to download Java.

Configuring Java

For computers running on windows, open the folder named "Java" in the "Program Files" folder. Then open the folder called "bin" and double click on the application called "policytool". You will see an error message like the one below.




Click "OK" and then click on "Add Policy Entry". You will see a window like the one below.




Click on "Add Permission" to enter a new permission. Then click on "Permission" and select "All Permission" as shown below.






Click "OK" and then "Done" to finish adding the permission. Save the permission by clicking on "File" and then "Save" in "Policy Tool" as shown below.


The permission is saved in "C:\Documents and Settings\Administrator" as a file named ".java.policy". Linux users should use the folder where they have installed Java. The remaining steps for configuration are the same as that for windows.


Connecting the EMG amplifiers to the computer.

The EMG amplifiers are connected to the Line In socket of the sound card of the computer using a stereo plug. The ground wires from the two amplifiers are connected to the ground pin (pin no 3) of the stereo plug. Output wire from one of the amplifiers is connected to pin no 2 (right channel) and the output wire from the other amplifier is connected to pin no 1 (left channel). The illustration given below will be helpful in identifying the pins of the stereo plug.



Stereo plug


Using the program

The program has two channels (Ch.A and Ch.B) for recording EMG.In most computers, the EMG amplifier connected to the right channel of the stereo plug is displayed in channel A and the amplifier connected to the left channel of the stereo plug will be displayed in channel B. In some computers this may be reversed. Verify which channel is shown as channel A and which as channel B. The EMG signal gain can be adjusted by clicking on the "Gain Selection" buttons. This can also be done by increasing the Volume of Line In in the Volume Control of the computer. The display sweep is adjusted by using the "Display Sweep" buttons. The mode of display of the EMG signal can be changed by using the "Display Mode" buttons. Offset is cancelled by clicking on the "Offset Null" button. The display can be frozen by clicking on the "Display Hold" button. The EMG can be recorded on the computer by clicking on the "FileWrite" button. It is recorded as a text file named jdatafile.txt on the "desktop" of the computer. This file gets replaced by the new data file in the next recording; therefore, if you wish to keep the recorded data, you should copy this file under another filename. The data from the two EMG channels are stored as two columns of numbers. These numbers can be read by any program of your choice (a spreadsheet or other data analysis program), to display, analyze, etc.