Hi All,

I am trying to get packet address using AMPacket.source(&packet) in 
apps/RadioCountToLeds application.

Here is my RadioCountToLeds.h code:

#ifndef RADIO_COUNT_TO_LEDS_H
#define RADIO_COUNT_TO_LEDS_H

typedef nx_struct radio_count_msg {
  nx_uint16_t counter;
nx_am_addr_t senderId;
} radio_count_msg_t;

enum {
  AM_RADIO_COUNT_MSG = 6,
};

And then I use below line in RadioCountToLedsC.nc file to receive the address:

am_addr_t senderId = call AMPacket.source(&packet);

I get the following error when I compile my application with telosb:

RadioCountToLeds.h:46: syntax error before `nx_am_addr_t'
RadioCountToLeds.h:46: warning: no semicolon at end of struct or union
RadioCountToLeds.h:48: warning: data definition has no type or storage class
failed to parse message file RadioCountToLeds.h
make: *** [RadioCountMsg.py] Error 1


Can anybody help me out, what am I doing wrong? And why I am getting this error?

Thanks.
Jenis
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to