I can't find the comport.txt file.
Please assist.
I can't find the comport.txt file.
Please assist.
Another question...
Why do you use port 888 for sending a ttl, while port 889 for recieving a signal? Why isn't it the same port number for both sending and recieving a signal?
Thank you,
Tali
I think I see where the confusion is coming from here. The comport.txt file is an advanced way of getting input from a serial port--it is typically used when lots of continuous data are coming in--as opposed to single button presses. We CAN use this method for your Cedrus box, but let's see if we can do it with TTL first.
The IOTest program is for setting up and testing the simpler TTL functionality--which is used most often for single button presses. For that, you do need an address, and I'm guessing that Windows assigns one to the pretend com port that it creates via the USB driver. Try this:
Go to the Windows Device Manager and head to the COM3 listing for the Cedrus device. Double click that and then click on the resources tab. What do you see? You should see the address that has been assigned to the simulated port. It will be a hexidecimal value.
And in answer to your question regarding 888 and 889, that is because different addresses are assigned to the parallel port--888 is for output and 889 is for input. That is why you often see a range of values in the "resources" tab for a port. Some will be for input and some for output. Although 888 and 889 aren't used for every machine, the input and output addresses will often be sequential like that.
-Blair
Hello Blair,
The port for the Cedrus Response Pad is COM3. At that port properties there isn't a Resource tab. You can look at the posted question #5 and answer #6 of John to get a clearer picture.
We did succeed to communicate with the response pad by using the Hyper Terminal.
The problem is how to confige the DirectRT with a USB device without an address. Since there is no address for USB device, as you can see from Jhon's answer #6.
Thank you,
Tali
Again, these ports are related to the internal hardware on your motherboard. There's a good overview of parallel port interfacing at http://www.beyondlogic.org/Originally Posted by barilan
.
The parallel port contains 25 discrete pins. Some are transmit-only and some are receive-only.
Basically, data you are trying to send OUT of the computer goes to the base address (in many cases, 888) while data being received by the computer from an outside system is read by the computer at address + 1 (or sometimes, address +2. Hence 888 and 889.
In the case of a serial port, data is sent and received through the same port address.
Hope that helps.
From Page 18 in the MediaLab manual:Originally Posted by barilan
In other words, it's just a regular text file. Create it in NotePad or WordPad or similar, and save it with the .txt specification.Code:Input via Serial Port You can now receive input from external devices such as response boxes via the serial port. To do so you just need to create a file called “comport.txt” in your experiment folder and copy the following text into it: comPort, baudRate, parity, dataBit,stopBit 1,19200,n,8,1 inputcode (1-255),responsevalue(1-12) 1,1 2,2 3,3 4,4 5,5 6,6 You shouldn’t modify the first or third line. The second line represents the values of the variables listed on the first line. You can change any of these as necessary. The remaining lines tell MediaLab how to map incoming signals to response keys. On each line you can list a pair where the first value is the signal sent to the serial port (i.e., 1- 255) and the second value is the response it should map on to (i.e., 1 to 12). In the example above, if MediaLab detects a “1” coming through the serial port, it will react as though the 1 or F1 key had just been pressed. This is an easy way to have subjects respond to scale items through an external button box such as those made by www.response-box.com
I've attached a sample 'comport.txt' file for future reference.
Last edited by JEC; 07-11-2006 at 10:51 AM.
I've attached a sample 'comport.txt' file for future reference.
Last edited by jarvis24; 09-17-2006 at 04:56 PM.