C language does not support structure evaluation. You need to do copy operation for each member in the structure one by one or using : memcpy(payload, &msg_contents, sizeof(DebugMsg))
On 4/29/08, Dimas Abreu Dutra <[EMAIL PROTECTED]> wrote: > > Hello all, > > I'm getting a very strange warning from the msp430-gcc when I compile an > app I made. I use the default make tmote and what I get the folowing output: > > /tmp/cc1ZKIEK.o: In function `EasyDebugP$sendMessage$runTask': > app.c:(.text+0x390e): warning: internal error: unsupported relocation > error > app.c:(.text+0x3912): warning: internal error: unsupported relocation > error > > > Besides that, the app is compiled, but it does not behave as intended. > Using comment-oriented debugging, I found out that the code originating the > warning is > > DebugMsg msg_contents; > DebugMsg *payload; > msg_contents = call Queue.dequeue(); > payload = call EasyAMSend.getPayload(&msg); > > **payload = msg_contents;* //Commenting this out removes the warning > > > where the type DebugMsg is: > > typedef nx_struct { > nx_uint16_t id; > nx_uint16_t value; > }DebugMsg; > > > Should this warning occur? I'm writing this e-mail because internal error > sounds like it could be something wrong with the compiler. > > ~Dimas~ > > _______________________________________________ > Tinyos-help mailing list > Tinyos-help@millennium.berkeley.edu > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help > -- Renjie Huang Sensorweb Research Laboratory http://sensorweb.vancouver.wsu.edu/ Washington State University
_______________________________________________ Tinyos-help mailing list Tinyos-help@millennium.berkeley.edu https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help