Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

usb 6501 matlab R2012a

For my e-phys experiment, I am setting up the connection between Mac (OS X 10.6.8) and recording machine using NI USB-6501. I am using Matlab R2012a to send out TTL signals. 

 

Using PsychToolbox 3.0.1, I can register usb board in matlab, but I don't know how I send binary info. Could anybody can teach me how I send TTL (e.g., 001011 any binary array is fine)?

 

 

Thank you so much in advance.

Jin

0 Kudos
Message 1 of 3
(5,713 Views)

Hello JKSol,

 

I'm not familiar with the PsychToolbox 3.0.1 so I won't be able to offer much help there.  A quick internet search brought up a forum for the PsychToolbox that appears to have an active community that has performed similar tasks.

 

Most folks I've chatted with that are using National Instruments hardware to acquire data within The Mathworks, Inc. MATLAB® use the Data Acquisition Toolbox provided by The Mathworks, Inc.  If you are using MATLAB® 2008b or earlier you may be able to directly call dll installed by NI-DAQmx.  

 

Another option would be to import your .m files into a MathScript node in LabVIEW, and utilize the NI-DAQmx functions all within the LabVIEW development environment.  For more information about the MathScript Module for LabVIEW, you can review the information available at this link:

 

Inside the LabVIEW MathScript RT Module

 

MATLAB® is a registered trademark of The MathWorks, Inc.

 


David A

0 Kudos
Message 2 of 3
(5,693 Views)

Dear David,

 

Thank you so much for your quick and helpful response. However, Mac version Matlab 2012a doesn't have data acquisition toolbox, as you know. That means I cannot use any functions in that toolbox to control usb-6501 and that's why I'm trying to use Psychtool to control it.

 

Using IOPort, I can open/register the board online during my experiment but I don't know how to send TTL pulses to the rec system. Could you give me help to get me any ideas for that?

 

Thank you very much again for your help,

Jin

0 Kudos
Message 3 of 3
(5,685 Views)