Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

uC/OS-II question

Name: Anonymous 2012-09-29 12:04

So, I am doing some uC/OS stuff and I can't seem to get the OS Queue to work. The documentation fails on me so I thought "Why not ask here?"

I have a struct called "OSQMessage" which contains the data I drop into the queue. I recall it later but the compiler says "request for member 'ID' in something not a structure or union".

OSQPost(QTasks, (void *) &M);
..
OSQMessage *M = (OSQMessage *) OSQPend(QTasks, 50, &err);
printf("Struct: %d\n", M.ID);

source: http://people.ece.cornell.edu/land/courses/ece5760/NiosII_muCOS/uC_Functions.html

Name: Anonymous 2012-09-29 12:06

M is a pointer
M->ID

Name: Anonymous 2012-09-29 12:08

*bangs head on keyboard*
duh.

Name: Anonymous 2012-09-29 12:37

*grabs dick*

Don't change these.
Name: Email:
Entire Thread Thread List