Welcome! Log In Create A New Profile

Advanced

Extra behavioral codes received in Blackrock

Posted by mary_hong 
Extra behavioral codes received in Blackrock
February 08, 2024 02:35PM
Hello,

I connected Monkeylogic to the data acquisition system, Blackrock via NIDAQ box, and send the event codes and strobes to Blackrock. When looking at the event codes received, I found sometimes there are extra codes. These extra codes are not always the behavioral codes that I set in the script, and they will occur at the same time of the original behavioral code.

I made sure that the strobes are consistent between ML and Blackrock, also I tried the three methods, rising edge/falling edge/send and clear. The problem still exist.

Has anyone encountered similar problems and have some ideas why this will happen?

Thank you in advance for your time!
Mary
Re: Extra behavioral codes received in Blackrock
February 08, 2024 03:27PM
What is the digital input option used on the Blackrock side? Do you know how frequently your Blackrock scans the digital input? I mean the sample rate.

What do you mean by "they will occur at the same time of the original behavioral code"? Are their Blackrock timestamps exactly the same?

Do the codes and times of the original events recorded by Blackrock match those from NIMH ML, otherwise?
Re: Extra behavioral codes received in Blackrock
February 08, 2024 06:10PM
The sampling rate of Blackrock is 30k/s. The digital input option on Blackrock match the option in ML, i.e. on bit changes for send and clear in ML; on rising edge for rising edge in ML; and on falling edge for falling edge in ML.

---"What do you mean by "they will occur at the same time of the original behavioral code"? Are their Blackrock timestamps exactly the same?"
Sorry I recheck the exact timestamp of Blackrock on 30k sampling rate, they are not exactly the same but they are only off by one timestamp.

Apart from the extra codes, the codes and times match pretty well.
Re: Extra behavioral codes received in Blackrock
February 08, 2024 08:34PM
Does your Blackrock require Strobe Bit? Is any of the digital input pins labeled as "strobe"?

----------

Such a mapping rule between the Blackrock digital input and the NIMH ML strobe cannot be applied here, since it is not certain whether the "rising edge" in the Blackrock option means the rising edge of strobe bit or data bits. If your Blackrock does not require Strobe Bit or you are not sure about it, try setting Blackrock to "on rising edge" and NIMH ML to "Send and Clear".
https://monkeylogic.nimh.nih.gov/docs_MainMenu.html#Strobe
Re: Extra behavioral codes received in Blackrock
February 13, 2024 06:32PM
Thank you for the suggestions Jaewon!
The Blackrock rising edge/falling edge require Strobe bit.

After many troubleshooting, we figure out that it's the digital input settings of Blackrock.
I only connected 8 channels(channel 0 is strobe and channel1-7 is event codes) of DAQ digital output to Blackrock for sending the behavioral codes, since the max event code is less than 127. So the Blackrock digital input need to be 8bit rising/falling edge, not 16 bit rising/falling edge.
When Blackrock digital input properties is set to16 bit, extra event codes happen occasionally.

Best,
Mary

The National Institute of Mental Health (NIMH) is part of the National Institutes of Health (NIH), a component of the U.S. Department of Health and Human Services.