psych_trans2.gif (12714 bytes)
Home Up About MED-PC MED-PC At A Glance Command Glossary


About MED-PC

The on-line control and data acquisition in experimental research has become a staple in psychology laboratories. Much of the on-line research is now being conducted using PC's (as opposed to minicomputers such as DEC's. PDP-11's), because of their increased speed and capacity. In addition, programming languages for specific areas of research (e.g. animal conditioning) have been developed to make it very easy to implement a variety of experimental paradigms.

System Concept

To run an experiment using MED-PC you need to go through three basic steps:

  1. Use a text editor to create an ASCII file that contains a program in MEDSTATE NOTATION. Make sure to save your code in an ASCII file, before going into the next stage (e. g. myfile.mpc.)
  2. Translate your program into PASCAL. To do this run the program called TRANS20. This program will prompt you to enter the name of an RTM file that will be compiled in the last stage (e.g. myfile.rtm). TRANS20 will generate a series of files that will be required in the final step, if there are no errors in your program.
  3. Comp your .rtm file. In this stage all you need to do is type: tpc/m/l myfile.rtm (myfile is the name you chose in TRANS20) in order to produce an executable program (myfile.exe).

 

Note: you may have an error free program, but this does not mean that the program is doing exactly what you want. To find whether everything runs well you have two options.

First, run the program and "play rat" with your equipment and see what happens in the chamber.
Second, there is an option to run your program in "emulation" mode where you play rat from the keyboard and then see what happens. For this purpose you can use any one of the three PC’s in the laboratory. Note though that the first is the better of the two options.

 

Additional Programs: Further explanation of the programs.

Throughout your experimental sessions, you will be using programs that complement MED-PC in order to compile programs and generate data onto the hard disk. There are four additional software programs you will be using throughout this course, as follows: Soft Cumulative Recorder (SoftCR), TRANS20, Turbo Pascal Compiler (TPC), and Turbo Pascal Editor (or any other text editor). It is imperative that you familiarize yourself with each of these programs so that your experimental sessions will run smoothly and efficiently. These programs will also be helpful in creating your own MED-PC programs for your final project in this course.

Soft Cumulative Recorder – Soft CR - A program that generates a cumulative record of IRT data to a separate file or to a printer. You will be generating and analyzing a cumulative record for each of the first four experiments See Chapter 3 of the Soft Cumulative Recorder Manual for details about the Soft CR screen display and printout label.

TRANS20 - A program that translates MED-PC formatted text (a run-time file) to a Pascal translation program. TRANS20 also checks an ASCII text file in MED-PC format for syntax errors. All MED-PC program files must be run through TRANS20 before being compiled in Pascal. This program is accessed in the compile directory.

Turbo Pascal Compiler - TPC - A program that compiles a clean run-time file into an executable file. This program configures the MED-PC program and prepares it to be run properly during experimentation.

Turbo Pascal Editor - A program used to create and edit procedures in an ASCII text file. You can access the Editor by typing "Turbo" at the compile directory.

Getting Help

There are many sources available to you should any problems be encountered when running or creating a MED-PC program. As always, contact your Teaching Fellow immediately if you have an emergency. However, if the problem deals with a simple syntax error or you are confused about the structure of a program, you should consult the MED-PC Medstate Notation Version 2.0 manual. If you are having trouble with the cumulative record portion of an experiment, consult the Soft Cumulative Recorder manual. Both manuals are kept in your lab for immediate consultation, or you can check them out at the Reserve Desk of Mugar Library or the Science and Engineering Library. See also Glossary of Commands.