Trouble with stream_burst using Ethernet | LabJack
 

Trouble with stream_burst using Ethernet

5 posts / 0 new
Last post
Rocketmench
ematlis's picture
Trouble with stream_burst using Ethernet

Hello-

 

I am having problems using stream_burst.c under Linux using a T7 with a direct tcp/ip connection and  with the latest stable firmware 1.028700.  I modified the code to increase the number of channels to 5 (AIN0-AIN4).  I increased the number of scans to 5000 (for a total of 25k points).  I decreased the sample rate to 1 kHz.  

 

I'm getting the following error:

****** 21420 data values were placeholders for scans that were skipped ******
****** 85.7 % of the scans were skipped ******

If I increase the streamBufferSize to 32768 in the HardcodedConfigureStream subroutine with the command:

WriteNameOrDie(handle, "STREAM_BUFFER_SIZE_BYTES", streamBufferSize);

the behavior changes- instead of returning, I get errors:

Starting stream:
   scan rate: 1000.00 Hz (5000.00 sample rate)
   number of scans  : 5000
   number of samples: 25000
LJM_eStreamBurst error: "LJME_NO_RESPONSE_BYTES_RECEIVED" (ErrorCode: 1263)

What's going on, and how can I fix this? I've attached the stream_burst.c code.

Thank you

File Attachment: 
LabJack Support
labjack support's picture
I was unable to replicate the

I was unable to replicate the issue. On Ubuntu Linux with a wireless connection to the T7 on the local network, running your code gave no skipped scans and no errors.

What version of Linux are you running? Is there another computer or another network interface you can try?

Does it happen via USB?

Please see these troubleshooting tips for skipped scans:

https://labjack.com/support/software/api/ljm/streaming-lots-of-9999-values

Rocketmench
ematlis's picture
Thanks for the quick response

Thanks for the quick response.  I think I have isolated the problem to the breakout board I am using.  I am using the (CB37?) board that came with the T7 to enable 5 analog inputs in addition to my digital output signals. 

As per your suggestion, I moved the labjack T7 to another computer and found (minus the CB37) that there were no issues.  When I brought the unit back to the original laptop, but without hooking up the breakout board, again no problems.  However, when I reconnect the breakout board, the missed scans problems return.  

On that breakout board I have 4 FIO lines plus a common ground that go to two stepper motor drivers,  and 5 AIN lines with 5 grounds. The AIN channels are currently floating (they are BNC connectors that are not currently connected to a signal source).

Interestingly, if I move the FIO signal lines to the main chassis, the problem goes away, even with the CB37 unit still attached.  I believe this is consistent but I can run any tests you would suggest.

Please advise, I really hope there isn't a hardware issue/electronic noise issue that can't be resolved here.

 

Thanks.

LabJack Support
labjack support's picture
Seems strange, I would not

Seems strange, I would not expect connections to a CB37 board itself to cause any issues. Did you change the number of channels you are streaming between the no CB37 connection and adding the CB37 back? If not, maybe test if you have the same issue when you remove everything from the CB37 except for the FIO line connections and have your 5 AIN lines shorted to GND terminals.

Rocketmench
ematlis's picture
Well, as of this morning I

Well, as of this morning I cannot replicate the problem.  Moving FIO control lines back to the CB37 board from the main chassis does not affect operation. Not sure what changed from yesterday. I will continue to monitor and report back if/when it re-occurs.  Thank you for your help.