07-31-2015 03:47 PM
What is the difference between an XNET project session (an xnet session setup in the project list) and an XNET create session VI (frame input stream)?
My code is continuously reading for CAN frames. When I use the XNET create session.VI (frame input stream), I get read Queue overflow after a minute or so.
Whenever I use a project level XNET session (setup in the project file list), it works fine for as long as I want.
I am using:
Labview 2014
NI-XNET 14.5
NI-9862 NI-XNET High-Speed CAN Module
.dbc file with an incoming cyclic signal at 10ms (8 byte payload)
I need to use the create session VI because I need the session to be setup after my program is started (user input decides parameters). Otherwise I would just use the project level and be done with it.
I've already referred to the extensive help manuals but cannot get the two methods of XNET session creation to behave the same.
Solved! Go to Solution.
08-01-2015 11:09 PM
Would you be able to attach the project you have defined this XNET session out of or the dbc (or simplified dbs/vi) you are using for your session? As far as I know there are no differences but to be honest I never really use the project defined XNET sessions.
08-03-2015 10:50 AM
Unfortunately the program I am working on has some aspects I am not allowed to share. I am working on an example that doesn't show anything but reproduces the problem I am having, I'll post if I can get it done. As an update to what I am troubleshooting, I have set up a property node to show a bunch of the session properties, and I was monitoring specifcally the "number of items pending" and "number of items unused" properties. When the bus is not transmitting the number of unused items is 4000 and items pending is 0 (which I gather that means the buffer/queue is empty). When running, Items pending sits at 40, the unused items at 3960. Seems like there is plenty of queue space, but then I get the queue overflow (still at 40 and 3960), and the items pending jumps back to 0 and unused to 4000. No more data comes in after that. It is really strange. The project level that normally works also sits at 40 and 3960 the same way, but no overflow still...
08-03-2015 01:51 PM
I think I have figured it out, I defined the session in a state machine. The state I defined it in was supposed to be a one-time state, but one of my other states looped the whole thing over, over and over again. After a few stacked session definitions, it gives up. It's always something you wouldn't expect. I appreciate the help!