You're absolutely correct. here is the relevant code of
my application ( and i guess the 2 errors are do related as you said):

event message_t* Receive.receive(message_t* msg, void* payload, uint8_t len){ 
    if (len == sizeof(AddressAllocationMsg)) { 
      AddressAllocationMsg* btrpkt = (AddressAllocationMsg*)payload;
   flag=1;    
      call Leds.led0On();    
    } 
    return msg;

  event void Timer1.fired() {   --->>the problem should be here (syntex error 
and implementation) 
    if (flag==0) {              
   event void Boot.booted() {   
  atomic {         
    call setAmAddress(0x0001);
   }
    call AMControl.start();   
  }                
     
 }
 else {                     
      MAX_ID = btrpkt->maxid;           
      TOS_NODE_ID = btrpkt->nodeid;     

  event void Boot.booted() {
  atomic {
    call setAmAddress(TOS_NODE_ID);
   }    
    call AMControl.start();  
  }                    
}
}  
}
----- Original Message -----
From: Kevin Klues <[EMAIL PROTECTED]>
Date: Monday, August 20, 2007 23:38
Subject: Re: [Tinyos-help] Problem with "Make mica2" in a new application
To: Itamar Amsili <[EMAIL PROTECTED]>
Cc: [email protected]

> Ithout seeing line 74 of your application, the error
> 
> > AddressAllocationC.nc:74: syntax error before `event'
> 
> is impossible to debug.
> 
> The error:
> > AddressAllocationC: `Timer1.fired' not implemented
> 
> obviously suggests that you have not implemented the body of the timer
> event.  Maybe the two are related, but without seeing the 
> actual code
> its impossible to tell.
> 
> Kevin
> 
> On 8/20/07, Itamar Amsili <[EMAIL PROTECTED]> wrote:
> > Hi all,
> >
> > I'm trying to implement a new application i wrote, but while 
> building> the code with "make mica2" i'm getting an error 
> message i can't solve:
> > In file included from AddressAllocationAppC.nc:13:
> > In component `AddressAllocationC':
> > AddressAllocationC.nc: In function `Receive.receive':
> > AddressAllocationC.nc:74: syntax error before `event'
> > AddressAllocationC: At top level:
> > AddressAllocationC: `Timer1.fired' not implemented
> > make: *** [exe0] Error 1
> > if someone has an idea or the text looks familiar Pls tell me 
> what to do,
> > i think i've tried almost all.
> >
> > Thanks alot,
> >
> > Itamar
> > _______________________________________________
> > Tinyos-help mailing list
> > [email protected]
> > https://mail.millennium.berkeley.edu/cgi-
> bin/mailman/listinfo/tinyos-help
> >
> 
> 
> -- 
> ~Kevin
> ‎
_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to