Re: [Tinyos-help] printf error

2013-01-14 Thread Sarah John Mwariti
Thanks all for the reply...

I have taken all your comments into consideration.

This what i get when i am trying to print.It prints nothing
Thread[Thread-1,5,main]serial@/dev/ttyUSB0:115200: resynchronising

Any suggestion of what i didnt do?




On Thu, Jan 10, 2013 at 2:01 PM, Saeid Yazdani  wrote:

>  Do you have the following line in your configuration file?
>
> components SerialPrintfC;
>
> notice that you don't need to wire it to anything.
>
>
>
>
> On 10-1-2013 9:28, Sarah John Mwariti wrote:
>
>  Happy new year guys...
>
> I want to use printf statements in an application and I added the
> following flags in the makefile.
> CFLAGS += -I$(TOSDIR)/lib/printf
> CFLAGS += -DPRINTF_BUFFER_SIZE=250
>
>
>  and i have added include :#include "printf.h" header file
>
>  but when i make telosb install, i get the following errors
>
> "
> /opt/tinyos-2.1.2/tos/chips/cc2420/lpl/DummyLplC.nc:39:2: warning:
> #warning "*** LOW POWER COMMUNICATIONS DISABLED ***"
> /opt/tinyos-2.1.2/tos/chips/msp430/adc12/Msp430Adc12ImplP.nc:68:4:
> warning: #warning Accessing TimerA for ADC12
> /opt/tinyos-2.1.2/tos/chips/sht11/SensirionSht11LogicP.nc: In function
> ‘SensirionSht11LogicP__0__readSensor__runTask’:
> /opt/tinyos-2.1.2/tos/chips/sht11/SensirionSht11LogicP.nc:322:11: warning:
> variable ‘crc’ set but not used [-Wunused-but-set-variable]
> /opt/tinyos-2.1.2/tos/chips/msp430/adc12/AdcStreamP.nc: In function
> ‘AdcStreamP__nextBuffer’:
> /opt/tinyos-2.1.2/tos/chips/msp430/adc12/AdcStreamP.nc:191:20: warning:
> variable ‘tmp_count’ set but not used [-Wunused-but-set-variable]
> /opt/tinyos-2.1.2/tos/chips/sht11/SensirionSht11LogicP.nc: In function
> ‘SensirionSht11LogicP__0__performCommand’:
> /opt/tinyos-2.1.2/tos/chips/sht11/SensirionSht11LogicP.nc:193:19: warning:
> variable ‘crc’ set but not used [-Wunused-but-set-variable]
> /opt/msp430-46/bin/../lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(printf.o):
> In function `printf':
> /home/cire/mm/w/tp/tinyos-2.x/tools/platforms/msp430/toolchain-46/msp430-libc-20120224/src/./stdlib/printf.c:42:
> undefined reference to `putchar'
> /opt/msp430-46/bin/../lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(printf.o):
> In function `vprintf':
> /home/cire/mm/w/tp/tinyos-2.x/tools/platforms/msp430/toolchain-46/msp430-libc-20120224/src/./stdlib/printf.c:50:
> undefined reference to `putchar'
> collect2: ld returned 1 exit status
> make: *** [exe0] Error 1
>
>
>
>
>  Please help!
>
>
> ___
> Tinyos-help mailing 
> listTinyos-help@millennium.berkeley.eduhttps://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>
>
>
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] printf error

2013-01-14 Thread Sarah John Mwariti
Tried running it ober and over again...this what i am recieving

serial@/dev/ttyUSB0:115200: bad packet
serial@/dev/ttyUSB0:115200: ignoring unknown packet type 0x0
serial@/dev/ttyUSB0:115200: bad packet
serial@/dev/ttyUSB0:115200: bad packet
serial@/dev/ttyUSB0:115200: ignoring unknown packet type 0x0


any suggestions of what's wrong?


On Mon, Jan 14, 2013 at 10:59 AM, Sarah John Mwariti
wrote:

> Thanks all for the reply...
>
> I have taken all your comments into consideration.
>
> This what i get when i am trying to print.It prints nothing
> Thread[Thread-1,5,main]serial@/dev/ttyUSB0:115200: resynchronising
>
> Any suggestion of what i didnt do?
>
>
>
>
> On Thu, Jan 10, 2013 at 2:01 PM, Saeid Yazdani wrote:
>
>>  Do you have the following line in your configuration file?
>>
>> components SerialPrintfC;
>>
>> notice that you don't need to wire it to anything.
>>
>>
>>
>>
>> On 10-1-2013 9:28, Sarah John Mwariti wrote:
>>
>>  Happy new year guys...
>>
>> I want to use printf statements in an application and I added the
>> following flags in the makefile.
>> CFLAGS += -I$(TOSDIR)/lib/printf
>> CFLAGS += -DPRINTF_BUFFER_SIZE=250
>>
>>
>>  and i have added include :#include "printf.h" header file
>>
>>  but when i make telosb install, i get the following errors
>>
>> "
>> /opt/tinyos-2.1.2/tos/chips/cc2420/lpl/DummyLplC.nc:39:2: warning:
>> #warning "*** LOW POWER COMMUNICATIONS DISABLED ***"
>> /opt/tinyos-2.1.2/tos/chips/msp430/adc12/Msp430Adc12ImplP.nc:68:4:
>> warning: #warning Accessing TimerA for ADC12
>> /opt/tinyos-2.1.2/tos/chips/sht11/SensirionSht11LogicP.nc: In function
>> ‘SensirionSht11LogicP__0__readSensor__runTask’:
>> /opt/tinyos-2.1.2/tos/chips/sht11/SensirionSht11LogicP.nc:322:11:
>> warning: variable ‘crc’ set but not used [-Wunused-but-set-variable]
>> /opt/tinyos-2.1.2/tos/chips/msp430/adc12/AdcStreamP.nc: In function
>> ‘AdcStreamP__nextBuffer’:
>> /opt/tinyos-2.1.2/tos/chips/msp430/adc12/AdcStreamP.nc:191:20: warning:
>> variable ‘tmp_count’ set but not used [-Wunused-but-set-variable]
>> /opt/tinyos-2.1.2/tos/chips/sht11/SensirionSht11LogicP.nc: In function
>> ‘SensirionSht11LogicP__0__performCommand’:
>> /opt/tinyos-2.1.2/tos/chips/sht11/SensirionSht11LogicP.nc:193:19:
>> warning: variable ‘crc’ set but not used [-Wunused-but-set-variable]
>> /opt/msp430-46/bin/../lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(printf.o):
>> In function `printf':
>> /home/cire/mm/w/tp/tinyos-2.x/tools/platforms/msp430/toolchain-46/msp430-libc-20120224/src/./stdlib/printf.c:42:
>> undefined reference to `putchar'
>> /opt/msp430-46/bin/../lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(printf.o):
>> In function `vprintf':
>> /home/cire/mm/w/tp/tinyos-2.x/tools/platforms/msp430/toolchain-46/msp430-libc-20120224/src/./stdlib/printf.c:50:
>> undefined reference to `putchar'
>> collect2: ld returned 1 exit status
>> make: *** [exe0] Error 1
>>
>>
>>
>>
>>  Please help!
>>
>>
>> ___
>> Tinyos-help mailing 
>> listTinyos-help@millennium.berkeley.eduhttps://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>>
>>
>>
>
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Eclipse and tinyOs

2013-01-14 Thread aron bengio
Hi to all, my name is Antonio i'm a student i''ll do a tesis for my teacher and 
i''ll use telosB for read the value from a  small WSN (wireless sensor network)
now, i will create a small java application,  for read the value that sensor 
give me. 
can you give me a simple example for to undestend to create this application? 
can you know book or web site for this example?
this is a my pc for develop:  
XUbunutu 12.10
tinyos-2.1.1
eclipse indico relase 2

excuse me for my bad english
best regads
Antonio___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] To store some of the received information in the local node module

2013-01-14 Thread Swetha

I need to store some of the received information in the local node module 
before broadcasting it.




implementation{
  message_t pkt;  to hold data for transmitting  the packet 
  message_t store; /// to hold data for storing in local node module





 event message_t* rreqreceiver.receive(message_t* msg, void* payload, uint8_t 
len)  {


   RouteDiscovery_t *rd_msg = (RouteDiscovery_t*) payload;


   RouteDiscovery_t *r_req = (RouteDiscovery_t*)(call  Packet.getPayload(&pkt,  
sizeof 
   (RouteDiscovery_t)));
   r_req->nodeid=rd_msg->source;
  /// codes to send packet (&pkt)




/// Here is my doubt, is this good way to store the received message 
information in the local node module or is  there any other approach to store 
the received message 




  NodeCache_t *cache = (NodeCache_t*)(call  Packet.getPayload(&store,  sizeof 
(NodeCache_t))); 



cache->route=rd_msg=route_id;




  }
}
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] CC2420X stack crash

2013-01-14 Thread Xiaohui Liu
Hi everyone,

I'm using CC2420X stack to deliver unicast traffic over 100 links. Every
sender transmits with a period of 100 ms. Around 10% of the nodes crash
within 3 minutes. I have witnessed similar
issue
before,
don't know if they are related. No node crashes if CC2420 stack is
used. Does anyone encounter this problem using CC2420X? Please do not
hesitate to share any thought. Thank you.

-- 
-Xiaohui Liu
TelosB
TinyOS 2.1.2
www.cs.wayne.edu/xliu/
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] CC2420X stack crash

2013-01-14 Thread Janos Sallai
Xiaohui:

I have not seen this issue. Can you verify that RadioCountToLeds
works? It's essentially the same application that you describe, with
250ms delay instead of 100ms in your case.

Can you put together a simple application that demonstrates this
"freezing" behavior? I'd be more than happy to take a look at it.

Janos

On Mon, Jan 14, 2013 at 11:22 AM, Xiaohui Liu  wrote:
> Hi everyone,
>
> I'm using CC2420X stack to deliver unicast traffic over 100 links. Every
> sender transmits with a period of 100 ms. Around 10% of the nodes crash
> within 3 minutes. I have witnessed similar issue before, don't know if they
> are related. No node crashes if CC2420 stack is used. Does anyone encounter
> this problem using CC2420X? Please do not hesitate to share any thought.
> Thank you.
>
> --
> -Xiaohui Liu
> TelosB
> TinyOS 2.1.2
> www.cs.wayne.edu/xliu/
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


Re: [Tinyos-help] Block Erase problem (at45db), review request

2013-01-14 Thread Janos Sallai
Eric:

I will look into this. There's another at45db (larger page size
support) that I should also address, so I will do both in the near
future.

Janos

On Thu, Jan 10, 2013 at 6:47 PM, Eric Decker  wrote:
> r0mi has reported (https://github.com/tinyos/tinyos-main/issues/162) a
> problem when trying to erase the entire media when using the at45db flash
> hardware.
>
> He/she has also proposed a fix
> (https://github.com/tinyos/tinyos-main/pull/163).
>
> However, I don't have sufficient background to be able to determine the
> correctness of this fix.
>
> Can someone who is more familar with the proper workings of at45db  evaluate
> the propsed fix and let us know about its correctness.
>
> thanks,
>
> eric
>
>
> --
> Eric B. Decker
> Senior (over 50 :-) Researcher
>
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


Re: [Tinyos-help] Block Erase problem (at45db), review request

2013-01-14 Thread Eric Decker
thanks.

are you up on github yet?   what is your github id,   I will add you to
Lead Developers as well as assign
the at45db issue to you.

thanks again.

On Mon, Jan 14, 2013 at 10:39 AM, Janos Sallai
wrote:

> Eric:
>
> I will look into this. There's another at45db (larger page size
> support) that I should also address, so I will do both in the near
> future.
>
> Janos
>
> On Thu, Jan 10, 2013 at 6:47 PM, Eric Decker  wrote:
> > r0mi has reported (https://github.com/tinyos/tinyos-main/issues/162) a
> > problem when trying to erase the entire media when using the at45db flash
> > hardware.
> >
> > He/she has also proposed a fix
> > (https://github.com/tinyos/tinyos-main/pull/163).
> >
> > However, I don't have sufficient background to be able to determine the
> > correctness of this fix.
> >
> > Can someone who is more familar with the proper workings of at45db
>  evaluate
> > the propsed fix and let us know about its correctness.
> >
> > thanks,
> >
> > eric
> >
> >
> > --
> > Eric B. Decker
> > Senior (over 50 :-) Researcher
> >
>



-- 
Eric B. Decker
Senior (over 50 :-) Researcher
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] Block Erase problem (at45db), review request

2013-01-14 Thread Janos Sallai
Eric:

My github id is sallai. Please go ahead and assign this issue to me.

Janos

On Mon, Jan 14, 2013 at 11:45 AM, Eric Decker  wrote:
> thanks.
>
> are you up on github yet?   what is your github id,   I will add you to Lead
> Developers as well as assign
> the at45db issue to you.
>
> thanks again.
>
>
> On Mon, Jan 14, 2013 at 10:39 AM, Janos Sallai 
> wrote:
>>
>> Eric:
>>
>> I will look into this. There's another at45db (larger page size
>> support) that I should also address, so I will do both in the near
>> future.
>>
>> Janos
>>
>> On Thu, Jan 10, 2013 at 6:47 PM, Eric Decker  wrote:
>> > r0mi has reported (https://github.com/tinyos/tinyos-main/issues/162) a
>> > problem when trying to erase the entire media when using the at45db
>> > flash
>> > hardware.
>> >
>> > He/she has also proposed a fix
>> > (https://github.com/tinyos/tinyos-main/pull/163).
>> >
>> > However, I don't have sufficient background to be able to determine the
>> > correctness of this fix.
>> >
>> > Can someone who is more familar with the proper workings of at45db
>> > evaluate
>> > the propsed fix and let us know about its correctness.
>> >
>> > thanks,
>> >
>> > eric
>> >
>> >
>> > --
>> > Eric B. Decker
>> > Senior (over 50 :-) Researcher
>> >
>
>
>
>
> --
> Eric B. Decker
> Senior (over 50 :-) Researcher
>
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


Re: [Tinyos-help] Eclipse and tinyOs

2013-01-14 Thread Eric Decker
What you are describing is covered in the basic tutorials for learning
tinyos.

See http://docs.tinyos.net/tinywiki/index.php/TinyOS_Tutorials

On Mon, Jan 14, 2013 at 2:26 AM, aron bengio  wrote:

> Hi to all, my name is Antonio i'm a student i''ll do a tesis for my
> teacher and i''ll use telosB for read the value from a  small WSN (wireless
> sensor network)
> now, i will create a small java application,  for read the value that
> sensor give me.
> can you give me a simple example for to undestend to create this
> application? can you know book or web site for this example?
> this is a my pc for develop:
> XUbunutu 12.10
> tinyos-2.1.1
> eclipse indico relase 2
>
> excuse me for my bad english
> best regads
> Antonio
>
>
>
>
>
> ___
> Tinyos-help mailing list
> Tinyos-help@millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>



-- 
Eric B. Decker
Senior (over 50 :-) Researcher
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] CC2420X stack crash

2013-01-14 Thread Xiaohui Liu
Hi Janos,

I tried the default RadioCountToLeds with cc2420x, with only the following
changes. Within 3 minutes, about 10% of nodes stop toggling led 2 and
crash. If MilliTimer fires every 100 ms, about 30% of nodes crash.

*  event void MilliTimer.fired() {*
*counter++;*
*call Leds.led2Toggle();*
*...*
*}*
*  event message_t* Receive.receive(message_t* bufPtr, *
*   void* payload, uint8_t len) {*
*dbg("RadioCountToLedsC", "Received packet of length %hhu.\n", len);*
*if (len != sizeof(radio_count_msg_t)) {return bufPtr;}*
*else {*
*//  radio_count_msg_t* rcm = (radio_count_msg_t*)payload;*
*//  if (rcm->counter & 0x1) {*
*// call Leds.led0On();*
*//  }*
*//  else {*
*// call Leds.led0Off();*
*//  }*
*//  if (rcm->counter & 0x2) {*
*// call Leds.led1On();*
*//  }*
*//  else {*
*// call Leds.led1Off();*
*//  }*
*//  if (rcm->counter & 0x4) {*
*// call Leds.led2On();*
*//  }*
*//  else {*
*// call Leds.led2Off();*
*//  }*
*  return bufPtr;*
*}*
*  }*

Please let me know if you have any idea what may go wrong. Thanks for your
reply.

-Xiaohui

On Mon, Jan 14, 2013 at 12:37 PM, Janos Sallai
wrote:

> Xiaohui:
>
> I have not seen this issue. Can you verify that RadioCountToLeds
> works? It's essentially the same application that you describe, with
> 250ms delay instead of 100ms in your case.
>
> Can you put together a simple application that demonstrates this
> "freezing" behavior? I'd be more than happy to take a look at it.
>
> Janos
>
> On Mon, Jan 14, 2013 at 11:22 AM, Xiaohui Liu  wrote:
> > Hi everyone,
> >
> > I'm using CC2420X stack to deliver unicast traffic over 100 links. Every
> > sender transmits with a period of 100 ms. Around 10% of the nodes crash
> > within 3 minutes. I have witnessed similar issue before, don't know if
> they
> > are related. No node crashes if CC2420 stack is used. Does anyone
> encounter
> > this problem using CC2420X? Please do not hesitate to share any thought.
> > Thank you.
> >
> > --
> > -Xiaohui Liu
> > TelosB
> > TinyOS 2.1.2
> > www.cs.wayne.edu/xliu/
>



-- 
-Xiaohui Liu
TelosB
TinyOS 2.1.2
www.cs.wayne.edu/xliu/
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] how Many Telosb/z1 nodes can be serially connected to one PC!

2013-01-14 Thread wasif masood
Dear All,

Does any of you have ever experienced about how many sensor nodes we can
attach to a PC. In my experience, using external powered USB hubs, one can
get as many connections as could but when it comes to serial logging, not
all the nodes can get their data to the BaseStation via serial connection.
Yesterday, I tired upto 10 and they worked just fine, but if I try to
increase them beyond 10 some nodes just meteriously can't log any thing.

Please share your experieces!
Regards!
Wasif Masood
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] how Many Telosb/z1 nodes can be serially connected to one PC!

2013-01-14 Thread Michael Schippling
I have a vague memory that there was a problem
getting more than 16 serial COM ports under Windows,
and in some cases the device numbers kept incrementing
even though devices were not attached...

it's been a while since I tried though.
MS

On 1/14/2013 3:12 PM, wasif masood wrote:
>
> Dear All,
>
> Does any of you have ever experienced about how many sensor nodes we can
> attach to a PC. In my experience, using external powered USB hubs, one
> can get as many connections as could but when it comes to serial
> logging, not all the nodes can get their data to the BaseStation via
> serial connection. Yesterday, I tired upto 10 and they worked just fine,
> but if I try to increase them beyond 10 some nodes just meteriously
> can't log any thing.
>
> Please share your experieces!
> Regards!
> Wasif Masood
>
>
> ___
> Tinyos-help mailing list
> Tinyos-help@millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help