Hello Gilles, here is the code:
RT_QUEUE myqueue; int retval; retval = rt_queue_create(&myqueue, "myqueue", 255, 10, Q_FIFO); char message[100] = "Message "; retval = rt_queue_write(&myqueue,message,sizeof(message),Q_NORMAL); //retval is 0 char msgBuf[255]; retval = rt_queue_read(&myqueue, msgBuf, sizeof(msgBuf), TM_NONBLOCK); //retval is always -1, why? regards, Jens 2010/9/13 Gilles Chanteperdrix <gilles.chanteperd...@xenomai.org> > Jens Köhler wrote: > > Hello > > > > I am try to use a RT_QUEUE. I am writing messages with rt_queue_write to > > the queue. But when function rt_queue_read is called result is always > "-1". > > > > "-1" means EPERM. What means exactly: "EEPERM is returned if this > > service should block"? I don't understand why a function should block to > > get a message from a queue!? > > A piece of code is worth a thousand words. Please send us a piece of > code showing the behaviour you find suspicious. > > -- > Gilles. > >
_______________________________________________ Xenomai-help mailing list Xenomai-help@gna.org https://mail.gna.org/listinfo/xenomai-help