Error reading DI

Lindsey Glickfeld's Avatar

Lindsey Glickfeld

18 Mar, 2020 07:05 PM

Hi Chris,

One of our experiments is inexplicably crashing when we use the nightly from a few weeks ago (I haven't tried the one in which you fixed some of the compile issues). It crashes after the first trial each time and says "ERROR reading DI, stopping IO and returning FALSE" (see screenshot). This experiment works fine with a version of 0.9 from April. Any suggestions for what might be the cause?

Thanks,
Lindsey.

  1. Support Staff 1 Posted by Christopher Sta... on 18 Mar, 2020 07:11 PM

    Christopher Stawarz's Avatar

    Hi Lindsey,

    I don't have any immediate insight into why this might be happening. If you want to send me your current LabJack plugin code, I can take a look and try to spot any issues. (Unfortunately, I'm working from home for the foreseeable future and don't have my LabJack U6 to test on.)

    Cheers,
    Chris

  2. 2 Posted by Lindsey Glickfe... on 18 Mar, 2020 07:18 PM

    Lindsey Glickfeld's Avatar

    Thanks Chris,
    Here is our LabJack Plugin repository:
    https://github.com/Glickfeld-And-Hull-Laboratories/LabJackU6_Plug-in
    Let me know if I need to add you to our group.
    Do you know what kind of conditions will drive this error?
    And let me know if it would help to ship you a new LabJack :)
    Lindsey.

  3. 3 Posted by Lindsey Glickfe... on 18 Mar, 2020 08:59 PM

    Lindsey Glickfeld's Avatar

    It seems to be specific to the variable set used- we'll hopefully hunt it
    down.
    Lindsey.

  4. Support Staff 4 Posted by Christopher Sta... on 19 Mar, 2020 03:36 PM

    Christopher Stawarz's Avatar

    Hi Lindsey,

    Thanks for sharing your code.

    The function call that's failing just tries to read the current state of all ports from the LabJack and doesn't appear to depend on any other settings or plugin state. This makes me think it's some kind of I/O failure. Right next to the code that issues the error message, there's a comment that says "We are seeing USB errors causing this", which seems like a plausible (if unspecific) explanation.

    As for the "crash", the issue is that the plugin's attempt to clean up in the face of this error is leading to a deadlock, which causes MWServer to become unresponsive. I created a pull request with a fix for this issue (along with some general updates and cleanup). If you have any issues building or using the plugin after merging the PR, please let me know.

    Chris

  5. 5 Posted by Lindsey Glickfe... on 19 Mar, 2020 04:44 PM

    Lindsey Glickfeld's Avatar

    Thanks- I'll try this out and let you know if I have issues.
    May be a few days.
    Lindsey.

  6. 6 Posted by Lindsey Glickfe... on 26 Mar, 2020 02:57 PM

    Lindsey Glickfeld's Avatar

    Hi Chris,

    Sorry- I'm a pretty novice GitHub user: I merged your pull request and now
    see your commits and the merge on Github. However, when I pull (or fetch)
    to my local repository using my git client (Sourcetree), it doesn't update-
    is there something else I need to do?

    Also- since I updated to 0.9, I've been having some issues with the
    collection of counter signals using the Labjack/Mworks (this is how we
    synchronize our Mworks data to our microscope). Around the transition
    between trials it often has extra counts at intervals that are too fast to
    be the microscope rate. I can send more details on the issue if it would
    help, but could this have been addressed by some of these changes that you
    just made to the Labjack plugin?

    Thanks,
    Lindsey.

  7. Support Staff 7 Posted by Christopher Sta... on 26 Mar, 2020 06:55 PM

    Christopher Stawarz's Avatar

    Hi Lindsey,

    However, when I pull (or fetch) to my local repository using my git client (Sourcetree), it doesn't update- is there something else I need to do?

    I don't know anything about Sourcetree. (I always use Git's command line tools.) As a workaround, you could just download the latest source.

    Around the transition between trials it often has extra counts at intervals that are too fast to be the microscope rate. I can send more details on the issue if it would help, but could this have been addressed by some of these changes that you just made to the Labjack plugin?

    I really don't have any idea why that would be happening or whether my changes would make a difference. Maybe try with the updated plugin and see if things work better?

    Also, if you haven't already, I'd recommend installing the latest LabJack Exodriver release. It's possible that there were changes in macOS that have been addressed with recent versions of the driver.

    Cheers,
    Chris

  8. 8 Posted by Lindsey Glickfe... on 26 Mar, 2020 06:58 PM

    Lindsey Glickfeld's Avatar

    Thanks- will try those things.
    Lindsey.

  9. Christopher Stawarz closed this discussion on 24 Jun, 2020 02:24 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac