Hello,
My main question is : what could cause messages to be detectable by a queue by batches instead of right after they are published ?
Here are the details :
- I publish a message at 500Hz
- I'm checking the callback queue (=spinning) at 500Hz
- the callback duration is < 0.1ms ( when a batch of 10 ( max queue size ) callabacks are called, it takes less then a ms )
- using the callbackqueue->isempty() function, i can see that the CallbackQueue is empty most of the time which is not normal ( its size should be 1 (+-1) at each iteration )
- After a variable time, the callbackqueue is no more empty ( isempty =0 ) and I receive all the messages that i should have received earlier ( in the limit of my queue ).
All the informations i'm giving above have been verified using text outputs.If needed i can upload codes and text outputs ( but the texts output takes arround 200 lines to be meaningfull ).
I tried to test the standard ros behavior by creating 2 simple nods : 1 publisher at 500hz, 1 subscriber at 500Hz, the subscriber node code being nearly the same than in my real code and it worked as expected. At nearly each iteration, isempty = false and i receive a message.
So my question is, is there any known things could delay the detection of the send messages (or the pushing in the queue?) and be responsible for the behavior i'm experiencing ?
Thanks a lot if anyone as an idee, TTDM
Originally posted by TTDM on ROS Answers with karma: 267 on 2017-10-05
Post score: 0