[Tinyos-help] Warnings when compiling Dissemination

2007-08-09 Thread Alban Hessler
Hi,

I got those warning when compiling TestDissemination:

/tinyos-2.x/tos/lib/net/DisseminationValue.nc: In function
`TestDisseminationC$Value16$get':
/tinyos-2.x/tos/lib/net/DisseminationValue.nc:47: warning: assignment from
incompatible pointer type
/ubisecsens/tinyos-2.x/tos/lib/net/DisseminationValue.nc:47: warning: return
from incompatible pointer type


Is this normal? I haven't found the way to get rid of them yet. Any help
would be appreciated.

Thank you,

Alban
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

RE: [Tinyos-help] Duty cycle

2007-08-09 Thread Murray, Ben
Thanks David !
 
...just to make sure I understand it...
 
setLocalDutyCycle(2000) will mean the radio is off for 8 seconds and then on
(actively receiving) for 2 seconds (approx).
 
whereas setLocalSleepInterval(8000) would mean the radio is off for 8
seconds and then on (actively receiving) for X seconds, where X is the
shortest possible on-time to perform an effective receive check (presumably
in the scale of milliseconds?), this method being better for more frequent
checks setLocalSleepInterval(100) ..where the radio) is on for X seconds
every 100ms? 
 
...is there a case for setting the sleep interval to, say, 60 seconds and
the wake tine to, for example, 2 seconds (i.e. basically controlling the on
period rather than X seconds as described above) or should I really be using
my own duty-cycle framework outside of Lpl to achieve that sort of on/off
relationship? I suppose you'd want to avoid your transmitters running for 60
seconds where possible...
 
Cheers, 
Ben 
 
p.s. not sure if it's been corrected yet but in the tep105 I printed out,
section 2.3 opens with "...minimizing energy efficiency and...". This should
probably either read "minimizing energy usage" /or/ "mazimizing energy
efficiency"? minimal efficiency is an easier goal to achieve ;-)

-Original Message-
From: David Moss [mailto:[EMAIL PROTECTED]
Sent: 08 August 2007 22:13
To: 'Murray, Ben'; 'mona zima'
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: RE: [Tinyos-help] Duty cycle



Hi Ben -

 

You're only able to specify the OFF time.  The ON time is statically set by
the radio stack to be the shortest possible on-time to perform an effective
receive check. 

 

If you're setting the sleep interval as a duty cycle %, the max is 1 ms
off.  You can specify it to be much larger if you're setting it with
setLocalSleepInterval(). 

 

-David

 


  _  


From: Murray, Ben [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, August 08, 2007 9:22 AM
To: 'David Moss'; 'mona zima'
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: RE: [Tinyos-help] Duty cycle

 

are we able to set both the on time and the off time with those duty-cycle
commands? From the tep105.txt and the comments in the file itself it seems
to imply that all we can do is state the ON time (either discretely or as a
%) within a total period time of 10,000ms? For example if I wanted to use
Lpl but with an 'on' time of 10ms and an off time of 490ms - is this
possible using the current Lpl interface or would I need to edit the
underlying hardware definitions...?

 

[I'm using micaz motes so it'd be the cc2420 stack in my case]

 

Cheers,

Ben

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of David Moss
Sent: 08 August 2007 16:14
To: 'mona zima'
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: RE: [Tinyos-help] Duty cycle

Hi Mona,

 

There is a .txt version of it here:

 

http://tinyos.cvs.sourceforge.net/*checkout*/tinyos/tinyos-2.x/doc/txt/tep10
5.txt
 

 

I would recommend putting setLocalSleepInterval early on in your
application's execution.  I typically put the setLocalSleepInterval() inside
of either Boot.booted() or the radio's SplitControl.startDone(error_t error)
events.

 

event void Boot.booted() {

  call LowPowerListening.setLocalSleepInterval(400);

}

 

-or-

event void SplitControl.startDone(error_t error) {

  call LowPowerListening.setLocalSleepInterval(400);

}

 

That way your node will turn on with a low power duty cycling state.  Before
you send your messages, make sure you call
LowPowerListening.setRxSleepInterval(&myMsg, 400); somewhere to tell your
radio that the message will be sent to another low power listening node.
That call only needs to happen one time, and I usually call it once at
booted(), or multiple times at the place in the code where the node is about
to send the message.

 

Hope that helps,

 

-David

 

 

 

 


  _  


From: mona zima [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, August 08, 2007 6:54 AM
To: David Moss
Subject: Re: [Tinyos-help] Duty cycle

 

Hi David,
Just to let you know that I could not find Tep 105 , could you please let me
know where can I find it ? or what do you think ?

Also I have simple question and hope that you have some time to answer: I
want to put the node to sleep for 400ms then to power it up and so on, but I
don't know where should I put : call
LowPowerListening.setLocalSleepInterval(100);

suppose this is the code, i think to put it after senddone () what do you
think? is that right ?

Thank you for any help or suggestions 
Mona 

suppose this is the code, I think to put it after sendDone () what do you
think? is that OK ?
 
event void Boot.booted() {
call AMControl.start ();
  }

event void AMControl.startDone(error_t err) { ...}
event void Timer0.fired() {  }
event void AMSend.sendDone(message_t* msg, error_t err) {
   }
event message_t* Receive.recei

[Tinyos-help] help

2007-08-09 Thread Akarsha Ramani
  I am a beginner with nesC programming. I am working on an application where I 
need to send voltage values from the node to the base station. I am programming 
Mica2 motes with OscilloscopeRF code to get the voltage readings. I am not sure 
if the data is being collected from the right channel as I get readings such as 
  7E42  0A7D 5D1A 0100 C800 0100 A100 A100 A100 A100 A100 A100 A100 A100 
A100 A100 B0D9 7E.
   
  Can someone provide any inputs on reading voltage values using Mica2 ?
  
   
-
Park yourself in front of a world of choices in alternative vehicles.
Visit the Yahoo! Auto Green Center.___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Environment Variables (path is empty in tinyos) !!!!

2007-08-09 Thread mejda chouaieb
Hello, all
 
Now I am studying Lesson 1 of TinyOS 2.x tutorial.
I have two tmote sky(s) (Telosb) and I also have a problem.
I have installed tinyos in windows and when I type tos-check-env I have these 
warnings ( I joned a printscreen). the path variable is empty when I type echo 
$path there is nothing.
can someone help me please? thank you in advance.


  
_ 
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail 

path warnings.doc
Description: Binary data
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] SDK for Imote2

2007-08-09 Thread Szymon Fedor
Hi,

Does anyone know what is the best software development kit to work with 
Imote2?(maybe something like AVRStudio for Atmega128/Mica2) 
I am interested in developing C and assembly routines on this platform. 
Is there any simulating environment for Imote2/Xscale?

thanks for your help,
Szymon___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] CCA Threshold

2007-08-09 Thread Mathieu DAVID

Hi,
We wanted to know about the procedure to change the *CCA threshold* 
using tinyOS.
We are trying to simulate the scenario from the tutorials in chapter 11. 
However, the nodes were established, but we could not see the packets 
received. We attribute this to the default value of CCA if -110dbm. Is 
this correct?
And if so, how does one alter the CCA threshold to facilitate packet 
transfer?


We are actually facing the problem described in the tutorial with this 
output:


1 2 -54.0
2 1 -55.0
1 3 -60.0
3 1 -60.0
2 3 -64.0
3 2 -64.0
DEBUG (1): Application booted.
DEBUG (1): Application booted again.
DEBUG (1): Application booted a third time.
DEBUG (2): Application booted.
DEBUG (2): Application booted again.
DEBUG (2): Application booted a third time.
DEBUG (3): Application booted.
DEBUG (3): Application booted again.
DEBUG (3): Application booted a third time.
DEBUG (1): RadioCountToLedsC: timer fired, counter is 1.
DEBUG (1): RadioCountToLedsC: packet sent.
DEBUG (2): RadioCountToLedsC: timer fired, counter is 1.
DEBUG (2): RadioCountToLedsC: packet sent.
DEBUG (3): RadioCountToLedsC: timer fired, counter is 1.
DEBUG (3): RadioCountToLedsC: packet sent.
DEBUG (1): RadioCountToLedsC: timer fired, counter is 2.
DEBUG (2): RadioCountToLedsC: timer fired, counter is 2.
DEBUG (3): RadioCountToLedsC: timer fired, counter is 2.

In the tutorial, some commands are given to modify the parameters of the 
radio channel :


/>>> from TOSSIM import *

t = Tossim([])
r = t.radio()
dir(r)

['__class__', '__del__', '__delattr__', '__dict__', '__doc__',
'__getattr__', '__getattribute__', '__hash__', '__init__',
'__module__', '__new__', '__reduce__', '__reduce_ex__',
'__repr__', '__setattr__', '__str__', '__swig_getmethods__',
'__swig_setmethods__', '__weakref__', 'add', 'connected',
'gain', 'remove', 'setNoise', 'this', 'thisown',
]
   /

/The first set of methods (with the double underscores) are ones that 
you usually don't call. The important ones are at the end. They are:/


   * /*|add(src, dest, gain)|*: Add a link from //src to //dest with
 //gain. When //src transmits, //dest will receive a packet
 attenuated by the //gain value. /
   * /*|connected(src, dest)|*: Return whether there is a link from
 //src to //dest. /
   * /*|gain(src, dest)|*: Return the gain value of the link from //src
 to //dest. /
   * /*|threshold()|*: Return the CCA threshold. /
   * /*|setThreshold(val)|*: Set the CCA threshold value in dBm. The
 default is -72dbM./


*But the fact is, None of the two last command exists !! *How can we 
solve this issue??

Thx,
Mathieu & Aravind
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


[Tinyos-help] TOSSIM 2.x doesn't run

2007-08-09 Thread [EMAIL PROTECTED]
When I try to compile an application fot TOSSIM I see always the same 
errors. I have tested some of the solution proposed in this Forum but 
noone solve my problem. My errors are:
$ make micaz sim-cygwin
mkdir -p 
build/micaz
  placing object files in build/micaz
  writing XML schema 
to app.xml
  compiling BlinkAppC to object file sim.o
ncc -c -
DUSE_DL_IMPORT -fpic -o build/micaz/sim.o -g -O0 -tossim
-fnesc-nido-
tos
nodes=1000 -fnesc-simulate -fnesc-nido-motenumber=sim_node\(\)
-
finline-limit=
10 -Wall -Wshadow -Wnesc-all -target=micaz
-fnesc-
cfile=build/micaz/app.c -b
oard=micasb  -Wno-nesc-data-race BlinkAppC.
nc   -fnesc-dump=components
-fnesc-du
mp=variables -fnesc-
dump=constants -fnesc-dump=typedefs
-fnesc-dump=interfacedef
s -fnesc-
dump=tags -fnesc-dumpfile=app.xml
In file included from /opt/tinyos-2.
x/tos/lib/tossim/sim_mac.c:34,
 from /opt/tinyos-2.
x/tos/lib/tossim/tos.h:89:
/opt/tinyos-2.x/tos/lib/tossim/sim_gain.c:
14: warning: declaration of `link'
sha
dows global declaration
/usr/include/sys/unistd.h:97: warning: location of shadowed declaration
/opt/tinyos-2.x/tos/lib/tossim/sim_gain.c:20: warning: declaration of 
`link'
sha
dows global declaration
/usr/include/sys/unistd.h:97: 
warning: location of shadowed declaration
/opt/tinyos-2.
x/tos/lib/tossim/sim_gain.c: In function
`sim_gain_allocate_link':

/opt/tinyos-2.x/tos/lib/tossim/sim_gain.c:134: warning: declaration of
`link' sh
adows global declaration
/usr/include/sys/unistd.h:97: 
warning: location of shadowed declaration
/opt/tinyos-2.
x/tos/lib/tossim/sim_gain.c: At top level:
/opt/tinyos-2.
x/tos/lib/tossim/sim_gain.c:141: warning: declaration of
`link' sh
adows global declaration
/usr/include/sys/unistd.h:97: warning: 
location of shadowed declaration
In file included from /opt/tinyos-2.x
/tos/chips/atm128/timer/sim/HplAtm128Timer0
AsyncC.nc:58,
 from /opt/tinyos-2.x
/tos/platforms/mica/AlarmCounterMilliP.nc:3
0,
 from 
/opt/tinyos-2.x
/tos/platforms/mica/sim/HilTimerMilliC.nc:4
1,
 from /opt/tinyos-2.x/tos/system/TimerMilliP.nc:41,
 from /opt/tinyos-2.x/tos/system/TimerMilliC.nc:40,
 from BlinkAppC.nc:46:
In component 
`HplAtm128CompareC':
/opt/tinyos-2.
x/tos/chips/atm128/timer/sim/HplAtm128CompareC.nc: In function
`ti
mer0_compare_handle':
/opt/tinyos-2.
x/tos/chips/atm128/timer/sim/HplAtm128CompareC.nc:195:
warning: de
claration of `time' shadows global declaration
/usr/include/time.h:49: 
warning: location of shadowed declaration
cc1: warning: -fpic ignored 
for target (all code is position independent)
  compiling Python 
support into pytossim.o and tossim.o
g++ -c -DUSE_DL_IMPORT -shared -
fpic -o build/micaz/pytossim.o -g -O0
/opt/tiny
os-2.
x/tos/lib/tossim/tossim_wrap.cxx -I/usr/include/python2.3
-I/opt/tinyos-
2.x
/tos/lib/tossim -DHAVE_CONFIG_H
cc1plus: warning: -fpic ignored for 
target (all code is position
independent)
g++ -c -DUSE_DL_IMPORT -
shared -fpic -o build/micaz/tossim.o -g -O0
/opt/tinyos
-2.
x/tos/lib/tossim/tossim.c -I/usr/include/python2.3 -I/opt/tinyos-2.x
/tos/lib/
tossim
cc1plus: warning: -fpic ignored for target (all code 
is position
independent)
  linking into shared object ./_TOSSIM.dll
g++ 
-fpic -shared -W1,--enable-auto-image-base  build/micaz/pytossim.o
build/mic
az/sim.o build/micaz/tossim.o -L/usr/lib/python2.3/config -
lpython2.3-lstdc++ -
o _TOSSIM.dll
build/micaz/sim.o(.text+0x239): In 
function `fillInOutput':
/opt/tinyos-2.x/tos/lib/tossim/sim_log.c:97: 
undefined reference to
`_hashtable_
search'
build/micaz/sim.o(.
text+0x309):/opt/tinyos-2.x/tos/lib/tossim/sim_log.c:127:
und
efined 
reference to `_hashtable_search'
build/micaz/sim.o(.text+0x2f04): In 
function `sim_log_init':
/opt/tinyos-2.x/tos/lib/tossim/sim_log.c:154: 
undefined reference to
`_create_ha
shtable'
build/micaz/sim.o(.
text+0x2f86): In function `sim_log_add_channel':
/opt/tinyos-2.
x/tos/lib/tossim/sim_log.c:166: undefined reference to
`_hashtable
_search'
build/micaz/sim.o(.text+0x3050):/opt/tinyos-2.
x/tos/lib/tossim/sim_log.c:181:
un
defined reference to 
`_hashtable_insert'
build/micaz/sim.o(.text+0x3100): In function 
`sim_log_remove_channel':
/opt/tinyos-2.x/tos/lib/tossim/sim_log.c:207: 
undefined reference to
`_hashtable
_search'
build/micaz/tossim.o(.
text+0x9c9): In function `_ZN4MoteC2EP8nesc_app':
/opt/tinyos-2.
x/tos/lib/tossim/tossim.c:125: undefined reference to
`_create_has
htable'
build/micaz/tossim.o(.text+0xa01): In function 
`_ZN4MoteC1EP8nesc_app':
/opt/tinyos-2.x/tos/lib/tossim/tossim.c:125: 
undefined reference to
`_create_has
htable'
build/micaz/tossim.o(.
text+0xb62): In function `_ZN4Mote11getVariableEPc':
/opt/tinyos-2.
x/tos/lib/tossim/tossim.c:172: undefined reference to
`_hashtable_
search'
build/micaz/tossim.o(.text+0xcaa):/opt/tinyos-2.
x/tos/lib/tossim/tossim.c:188:
u
ndefined reference to 
`_hashtable_insert'
collect2: ld returned 1 exit status
make: *** [sim-
exe] Error 1


Is t

[Tinyos-help] Request for Comments on TEP 113

2007-08-09 Thread Matt Welsh

Dear TinyOS developer community:

TinyOS Extension Proposal (TEP) 113 on "Serial Communications" has  
been released for public review. I am writing to solicit comments and  
suggestions on TEP 113 before it is finalized. Your comments are  
essential to providing feedback and driving revisions to the TEP. So,  
if you have an active interest in the serial communications API and  
protocol for TinyOS, I encourage you to send me comments.


You can access the text for TEP 113 here:

http://tinyos.cvs.sourceforge.net/*checkout*/tinyos/tinyos-2.x/doc/ 
html/tep113.html


Please direct all comments, questions, and concerns to me.
I will collect all feedback and forward to the authors of the TEP in  
about 3 weeks.


Thanks!
Matt Welsh


___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


[TinyOS-Help]about received data packet

2007-08-09 Thread 李 祺安
I visited this web  
http://www.tinyos.net/tinyos-1.x/doc/tutorial/lesson6.html

According by this web, I try to key in "java net.tinyos.tools.Listen".
There are two questions I want to ask,
1.Why do i received two data packet at the same time? 
example:
20 01 08 45 FF FF FF FF 08 7D 01 00 01 00 44 00 44 00 FC 21 3B 00 00 00 76 
0B FF

FF 03 00 FF FF FF FF FF FF FF 7F FF 7F FF 7F
14 01 08 46 FF FF FF FF 07 7D 01 00 01 00 45 00 45 00 01 00 FF FF FE FF FF 
00 00

00 00 00

2.In that web site, the data packet is :
dest addr   handlerID   groupID   msg len   source addr   counter   channel 
 readings 
7e 00 0a  7d 1a   01 00
14 00  01 00  96 03 97 03 97 03 98 03 97 03 96 03 97 03 96 03 96 03 
96 03 


It seems not like the data I received...why..?

Lee.

_
Windows Live Messenger 正式版熱烈下載中:共用資料夾,傳檔案再大也不怕 
http://get.live.com/messenger/overview 


___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


RE: [Tinyos-help] Environment Variables (path is empty in tinyos) !!!!

2007-08-09 Thread Siirtola Harri
You asked this last Friday and got replies. Didn't you read them? Go to the 
archive and find the answers.
 
Regards,
Harri
 
PS. Remember that environment vars are case sensitive! (path var is $PATH)



From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of mejda chouaieb
Sent: Thursday, August 02, 2007 3:36 PM
To: tinyos-help@Millennium.Berkeley.EDU
Subject: [Tinyos-help] Environment Variables (path is empty in tinyos) 



Hello, all
 
Now I am studying Lesson 1 of TinyOS 2.x tutorial.
I have two tmote sky(s) (Telosb) and I also have a problem.
I have installed tinyos in windows and when I type tos-check-env I have these 
warnings ( I joned a printscreen). the path variable is empty when I type echo 
$path there is nothing.
can someone help me please? thank you in advance.
  





Ne gardez plus qu'une seule adresse mail ! Copiez vos mails 
  vers Yahoo! Mail 
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Extend battery life of Micaz

2007-08-09 Thread Luis Ruiz Garcia
Hello everybody,

 

Our aim is to extend as much as possible the battery life of Micaz motes, at
least for 2 weeks. How can we do it?

We are using the standard application which came with the motes. 

Any ideas, suggestions or comments are welcome !

 

Thanks in advance.

 

Luis Ruiz

 

 

___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Exception in thread main!!

2007-08-09 Thread mejda chouaieb
I have two tmote sky(s) (Telosb) and I also have a problem.
I have installed tinyos in windows and when I type make tmote and then motelist 
it is ok, but when I try to run Trawler I have errors
when I Type :
[EMAIL PROTECTED]:tmote java com.trawler.Trawler
Exception in thread "main" 
java.lang.NoClassDefFoundError:com/moteiv/trawler/Trawler
 
I think I have a problem with java environment variables but I don't know how 
to resolve this problem !! can someone help me please ?
Thank you.


  
_ 
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail ___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [TinyOS-Help]about received data packet

2007-08-09 Thread Tsung-Han Lin
Hi Lee

I guess you used micaz or telos. The message structure in the tutorial
is for mica2; you can find the correct message format in
tos/platform/telos/AM.h
I have no idea on what you have done to receive packets and cannot
comment on your first question.

-Han

> I visited this web  
> http://www.tinyos.net/tinyos-1.x/doc/tutorial/lesson6.html
> According by this web, I try to key in "java net.tinyos.tools.Listen".
> There are two questions I want to ask,
> 1.Why do i received two data packet at the same time? example:
> 20 01 08 45 FF FF FF FF 08 7D 01 00 01 00 44 00 44 00 FC 21 3B 00 00 00 
> 76 0B FF
> FF 03 00 FF FF FF FF FF FF FF 7F FF 7F FF 7F
> 14 01 08 46 FF FF FF FF 07 7D 01 00 01 00 45 00 45 00 01 00 FF FF FE FF 
> FF 00 00
> 00 00 00
> 
> 2.In that web site, the data packet is :
> dest addr   handlerID   groupID   msg len   source addr   counter   
> channel  readings 7e 00 0a  7d 
> 1a   01 0014 00  01 00  96 03 97 03 97 03 98 
> 03 97 03 96 03 97 03 96 03 96 03 96 03
> It seems not like the data I received...why..?
> 
> Lee.
> 
> _
> Windows Live Messenger 正式版熱烈下載中:共用資料夾,傳檔案再大也不怕 
> http://get.live.com/messenger/overview
> ___
> Tinyos-help mailing list
> Tinyos-help@Millennium.Berkeley.EDU
> https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
> 
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


RE: [Tinyos-help] Extend battery life of Micaz

2007-08-09 Thread Murray, Ben
use bigger batteries?
 
;-)
...seriously though, by "standard application" ...do you mean moteworks? If
so I suggest you try calling/emailing crossbow tech support for some help.
Generally though there are several tep's dealing with power saving. Main two
ways to do it are to sleep the mcu and to duty-cycle the radio
 
try TEP105 and TEP112 for starters.
Also tutorial lesson 8 within TinyOS concerns power management.
 
-Ben
 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Luis Ruiz
Garcia
Sent: 09 August 2007 14:58
To: tinyos-help@Millennium.Berkeley.EDU
Subject: [Tinyos-help] Extend battery life of Micaz



Hello everybody,

 

Our aim is to extend as much as possible the battery life of Micaz motes, at
least for 2 weeks. How can we do it?

We are using the standard application which came with the motes. 

Any ideas, suggestions or comments are welcome !

 

Thanks in advance.

 

Luis Ruiz

 

 


***
Please consider the environment before printing this email.
***
This email and any files transmitted with it are intended solely for the use of
the individual or entity to whom they are addressed and may not be divulged to
any third party without the express permission of the originator.  Any views
expressed in this message are those of the individual sender, except where the
sender specifically states them to be the views of Thales Research & Technology
(UK) Limited.
***

___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

RE: [Tinyos-help] Extend battery life of Micaz

2007-08-09 Thread Giri Baleri
You can use Low Power (lp) version of XMesh apps. These are distributed
with MoteView and MoteWorks and can make AA batteries last for several
months.
 
Regards,
Giri



From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Luis
Ruiz Garcia
Sent: Thursday, August 09, 2007 6:58 AM
To: tinyos-help@Millennium.Berkeley.EDU
Subject: [Tinyos-help] Extend battery life of Micaz



Hello everybody,

 

Our aim is to extend as much as possible the battery life of Micaz
motes, at least for 2 weeks. How can we do it?

We are using the standard application which came with the motes. 

Any ideas, suggestions or comments are welcome !

 

Thanks in advance.

 

Luis Ruiz

 

 

___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] making CC2420 work in promiscuous mode

2007-08-09 Thread Avinash Sridharan
I am working on TinyOS-2.x. Is there an interface to turn the CC420 on in
promiscuous mode. I want all unicast packets to be heard by nodes in a
single broadcast domain. I don't want to broadcast the packets since that
would turn off the ACK's.

Thanks,
Avinash

-- 
Phd Dept. of Electrical Engineering
University of Southern California
http://www-scf.usc.edu/~asridhar
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] .extra file not linking up

2007-08-09 Thread Christopher Jenkins
Hello,

I've been making some custom changes to a platform, and when I execute make,
it cannot find definitions for the tinsec.extra variables TINYSEC_KEYSIZE
and TINYSEC_KEY, but it works fine for the same application in mica2.

Below is what my tinysec.extra file looks like...


#-*-Makefile-*- vim:syntax=make
#$Id: tinysec.extra,v 1.1 2006/01/03 07:42:37 mturon Exp $

#
# TinySec processing
#
# The tinysec keyfile to use and the default key name (this re matches the
# first key. you can explicitly list keys by: make mica KEYNAME=mykeyname
KEYFILE := $(HOME)/.tinyos_keyfile
KEYNAME := '\w+'

TINYSEC_KEY := $(shell mote-key -kf $(KEYFILE) -kn $(KEYNAME))
ifeq ($(TINYSEC_KEY),)
$(error tinysec key has not been properly set. It is needed for tinysec. \
 Check to make sure that the script exists)
endif

PFLAGS := $(PFLAGS) -I%T/lib/TinySec -I%T/platform/%p/TinySec
-DTINYSEC_KEY="$(TINYSEC_KEY)" -DTINYSEC_KEYSIZE=8
ifeq ($(TARGET),mica2dot)
PFLAGS := $(PFLAGS) -I%T/platform/mica2/TinySec
endif
# CMJ 7/27/07
# Added an if for cricket too
# CMJ 8/8/07
# Added the definition for TINYSEC_KEYSIZE on
ifeq ($(TARGET),cricket)
PFLAHS := $(PFLAGS) -I%T/platform/cricket/TinySec
-DTINYSEC_KEY="$(TINYSEC_KEY)" -DTINYSEC_KEYSIZE=8
endif



As you can see, I've added the definition for my platform and even
explicitly defined TINYSEC_KEYSIZE, but the only way I can get the program
to recognize it is by declaring it directly in the top of whatever files
need it (like TinySecC for example).



Thanks,

Chris
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] How to disable radio listening?

2007-08-09 Thread Ittipong Khemapech
Hello everyone,

I am using TOSSIM and PowerTOSSIM to determine how power adaptation affects
the total energy consumption. I adapted the CntToLedsAndRfm application and
got some results. I found that the difference between setting min (-20 dBm)
and max TX (10 dBm) is only 4%. According to the CC1000 specification, the
power required for sending a message at -20 dBm and 10 dBm are around 5 and
25 mA, respectively (400% of power can be saved). I think that I should get
the simulation results which follow those in specification (that is 4 times,
not only 4% power preservation).

I think that one of the main reasons is the motes are listening to their
channel all the time. Significant amount of energy is consumed. So, how can
I disable the radio listening? Any suggestions would be appreciated.

Many thanks,
Ittipong
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Alternate reasons for 'not connected' error

2007-08-09 Thread Christopher Jenkins
Hello,

This is my error output when I execute the make command:

In component `CC1000RadioM':
C:\Crossbow\cygwin\opt\MoteWorks\tos\platform\cricket\CC1000RadioM.nc: In
function `SpiByteFifo.dataReady':
C:\Crossbow\cygwin\opt\MoteWorks\tos\platform\cricket\CC1000RadioM.nc:539:
RadioSendCoordinator.blockTimer not connected
C:\Crossbow\cygwin\opt\MoteWorks\tos\platform\cricket\CC1000RadioM.nc:540:
RadioReceiveCoordinator.blockTimer not connected
C:\Crossbow\cygwin\opt\MoteWorks\tos\platform\cricket\CC1000RadioM.nc:567:
RadioSendCoordinator.startSymbol not connected
C:\Crossbow\cygwin\opt\MoteWorks\tos\platform\cricket\CC1000RadioM.nc:575:
RadioSendCoordinator.byte not connected
C:\Crossbow\cygwin\opt\MoteWorks\tos\platform\cricket\CC1000RadioM.nc:751:
RadioReceiveCoordinator.startSymbol not connected
C:\Crossbow\cygwin\opt\MoteWorks\tos\platform\cricket\CC1000RadioM.nc:785:
RadioReceiveCoordinator.byte not connected
make: *** [exe0] Error 1


Is there any reason I would experience this error OTHER than the events not
being connected, (missing declaration in a header, shared file confusion
etc.) because I'm sure that they are.

Thank you,
Chris
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] TEP106 type error

2007-08-09 Thread Min Guo
I think there maybe some type errors in TEP 106:

module a {
  ...
  provides interface TaskBasic as x;
}
implementation {
  event void x.runTask() {
...
call x.postTask();
  }
}


should be :

module a {
  ...
  uses interface TaskBasic as x;
}
implementation {
  event void x.runTask() {
...
call x.postTask();
  }
}


-

configuration TinySchedulerC {
  provides interface Scheduler;
  provides interface TaskBasic[uint8_t taskID];
  provides interface TaskEdf[uint8_t taskID];
}
implementation {
  components SchedulerEdfP;
  Scheduler = SchedulerEdf;
  TaskBasic = SchedulerEdfP;
  TaskEDF   = SchedulerEdfP;
}

should be :

configuration TinySchedulerC {
  provides interface Scheduler;
  provides interface TaskBasic[uint8_t taskID];
  provides interface TaskEdf[uint8_t taskID];
}
implementation {
  components SchedulerEdfP;
  Scheduler = SchedulerEdfP;
  TaskBasic = SchedulerEdfP;
  TaskEdf   = SchedulerEdfP;
}
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


Re: [Tinyos-help] CCA Threshold

2007-08-09 Thread Philip Levis

On Aug 2, 2007, at 6:39 AM, Mathieu DAVID wrote:


Hi,
We wanted to know about the procedure to change the *CCA threshold*  
using tinyOS.
We are trying to simulate the scenario from the tutorials in  
chapter 11. However, the nodes were established, but we could not  
see the packets received. We attribute this to the default value of  
CCA if -110dbm. Is this correct?
And if so, how does one alter the CCA threshold to facilitate  
packet transfer?


We are actually facing the problem described in the tutorial with  
this output:


1 2 -54.0
2 1 -55.0
1 3 -60.0
3 1 -60.0
2 3 -64.0
3 2 -64.0
DEBUG (1): Application booted.
DEBUG (1): Application booted again.
DEBUG (1): Application booted a third time.
DEBUG (2): Application booted.
DEBUG (2): Application booted again.
DEBUG (2): Application booted a third time.
DEBUG (3): Application booted.
DEBUG (3): Application booted again.
DEBUG (3): Application booted a third time.
DEBUG (1): RadioCountToLedsC: timer fired, counter is 1.
DEBUG (1): RadioCountToLedsC: packet sent.
DEBUG (2): RadioCountToLedsC: timer fired, counter is 1.
DEBUG (2): RadioCountToLedsC: packet sent.
DEBUG (3): RadioCountToLedsC: timer fired, counter is 1.
DEBUG (3): RadioCountToLedsC: packet sent.
DEBUG (1): RadioCountToLedsC: timer fired, counter is 2.
DEBUG (2): RadioCountToLedsC: timer fired, counter is 2.
DEBUG (3): RadioCountToLedsC: timer fired, counter is 2.

In the tutorial, some commands are given to modify the parameters  
of the radio channel :


/>>> from TOSSIM import *

t = Tossim([])
r = t.radio()
dir(r)

['__class__', '__del__', '__delattr__', '__dict__', '__doc__',
'__getattr__', '__getattribute__', '__hash__', '__init__',
'__module__', '__new__', '__reduce__', '__reduce_ex__',
'__repr__', '__setattr__', '__str__', '__swig_getmethods__',
'__swig_setmethods__', '__weakref__', 'add', 'connected',
'gain', 'remove', 'setNoise', 'this', 'thisown',
]
   /

/The first set of methods (with the double underscores) are ones  
that you usually don't call. The important ones are at the end.  
They are:/


   * /*|add(src, dest, gain)|*: Add a link from //src to //dest with
 //gain. When //src transmits, //dest will receive a packet
 attenuated by the //gain value. /
   * /*|connected(src, dest)|*: Return whether there is a link from
 //src to //dest. /
   * /*|gain(src, dest)|*: Return the gain value of the link from // 
src

 to //dest. /
   * /*|threshold()|*: Return the CCA threshold. /
   * /*|setThreshold(val)|*: Set the CCA threshold value in dBm. The
 default is -72dbM./


*But the fact is, None of the two last command exists !! *How can  
we solve this issue??


What version are you referring to? For 2.0.1 and 2.0.2, it looks like  
the tutorial is out of sync with the code. I removed those two calls  
because the CCA threshold is often something the node itself can  
adjust. A node can current adjust it by calling  
GainRadioModel.setClearValue(). Note that this call is simulator  
specific. The hope was that future radio models might incorporate  
chip-specific interfaces (e.g., setting the CCA with a CC2420 control  
interface) and map them to this underlying call.


Phil


___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


Re: [Tinyos-help] TOSSIM 2.x doesn't run

2007-08-09 Thread Philip Levis


On Aug 7, 2007, at 6:29 PM, [EMAIL PROTECTED] wrote:


When I try to compile an application fot TOSSIM I see always the same
errors. I have tested some of the solution proposed in this Forum but
noone solve my problem. My errors are:
$ make micaz sim-cygwin


sim-cygwin was deprecated long ago; what version of T2 are you using?  
With more recent versions, you should be able to just type 'make  
micaz sim' and have it work. In particular, sim-cygwin doesn't  
include a critical .o file that was introduced after sim-cygwin was  
deprecated.


Phil
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


Re: [Tinyos-help] help

2007-08-09 Thread Michael Schippling

See this for message decoding tips:
http://www.octavetech.com/pubs/TB5-01%20Deciphering%20TinyOS%20Serial%20Packets.pdf

The A100 values are your samples, in little-endian so the value is 0x00A1.
They are awfully stable (don't change) so I suspect that you are not really
sampling anything. Look into how you've wired DemoSensor or the ADC. You
can poke at my code to see how I went about doing ADC samples in T1:
http://www.etantdonnes.com/Motes/robocode.tar.gz

MS

Akarsha Ramani wrote:


I am a beginner with nesC programming. I am working on an application 
where I need to send voltage values from the node to the base station. I 
am programming Mica2 motes with OscilloscopeRF code to get the voltage 
readings. I am not sure if the data is being collected from the right 
channel as I get readings such as
7E42  0A7D 5D1A 0100 C800 0100 A100 A100 A100 A100 A100 A100 A100 
A100 A100 A100 B0D9 7E.
 
Can someone provide any inputs on reading voltage values using Mica2 ?


Park yourself in front of a world of choices in alternative vehicles.
Visit the Yahoo! Auto Green Center. 
 






___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


RE: [Tinyos-help] Duty cycle

2007-08-09 Thread David Moss
My mistake on this - the max off time is more like 49995 ms when you're
specifying LPL as a duty cycle %.  (~5 ms on, 49995 off). 

 

When specifying a duty cycle, you can get up to 100% .. or,
setLocalDutyCycle(1).  But again, you have better control with
setLocalSleepInterval() than setLocalDutyCycle()

 

-David

 

 

 

  _  

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of David Moss
Sent: Wednesday, August 08, 2007 2:13 PM
To: 'Murray, Ben'; 'mona zima'
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: RE: [Tinyos-help] Duty cycle

 

Hi Ben -

 

You're only able to specify the OFF time.  The ON time is statically set by
the radio stack to be the shortest possible on-time to perform an effective
receive check. 

 

If you're setting the sleep interval as a duty cycle %, the max is 1 ms
off.  You can specify it to be much larger if you're setting it with
setLocalSleepInterval(). 

 

-David

 

  _  

From: Murray, Ben [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, August 08, 2007 9:22 AM
To: 'David Moss'; 'mona zima'
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: RE: [Tinyos-help] Duty cycle

 

are we able to set both the on time and the off time with those duty-cycle
commands? From the tep105.txt and the comments in the file itself it seems
to imply that all we can do is state the ON time (either discretely or as a
%) within a total period time of 10,000ms? For example if I wanted to use
Lpl but with an 'on' time of 10ms and an off time of 490ms - is this
possible using the current Lpl interface or would I need to edit the
underlying hardware definitions...?

 

[I'm using micaz motes so it'd be the cc2420 stack in my case]

 

Cheers,

Ben

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of David Moss
Sent: 08 August 2007 16:14
To: 'mona zima'
Cc: tinyos-help@Millennium.Berkeley.EDU
Subject: RE: [Tinyos-help] Duty cycle

Hi Mona,

 

There is a .txt version of it here:

 

http://tinyos.cvs.sourceforge.net/*checkout*/tinyos/tinyos-2.x/doc/txt/tep10
5.txt

 

I would recommend putting setLocalSleepInterval early on in your
application's execution.  I typically put the setLocalSleepInterval() inside
of either Boot.booted() or the radio's SplitControl.startDone(error_t error)
events.

 

event void Boot.booted() {

  call LowPowerListening.setLocalSleepInterval(400);

}

 

-or-

event void SplitControl.startDone(error_t error) {

  call LowPowerListening.setLocalSleepInterval(400);

}

 

That way your node will turn on with a low power duty cycling state.  Before
you send your messages, make sure you call
LowPowerListening.setRxSleepInterval(&myMsg, 400); somewhere to tell your
radio that the message will be sent to another low power listening node.
That call only needs to happen one time, and I usually call it once at
booted(), or multiple times at the place in the code where the node is about
to send the message.

 

Hope that helps,

 

-David

 

 

 

 


  _  


From: mona zima [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, August 08, 2007 6:54 AM
To: David Moss
Subject: Re: [Tinyos-help] Duty cycle

 

Hi David,
Just to let you know that I could not find Tep 105 , could you please let me
know where can I find it ? or what do you think ?

Also I have simple question and hope that you have some time to answer: I
want to put the node to sleep for 400ms then to power it up and so on, but I
don't know where should I put : call
LowPowerListening.setLocalSleepInterval(100);

suppose this is the code, i think to put it after senddone () what do you
think? is that right ?

Thank you for any help or suggestions 
Mona 

suppose this is the code, I think to put it after sendDone () what do you
think? is that OK ?
 
event void Boot.booted() {
call AMControl.start ();
  }

event void AMControl.startDone(error_t err) { ...}
event void Timer0.fired() {  }
event void AMSend.sendDone(message_t* msg, error_t err) {
   }
event message_t* Receive.receive(message_t* msg, void* payload, uint8_t len)
{.} 

On 7/20/07, mona zima < 
[EMAIL PROTECTED]> wrote:

Oh thanks David, 
I am really appreciate it your help. 
Thanks again, I will go and try that...

Many thanks
  Mona

 

On 7/20/07, David Moss <[EMAIL PROTECTED]> wrote:

Hi Mona,

 

Just use the LowPowerListening interface, provided by CC2420ActiveMessageC.

 

call LowPowerListening.setLocalDutyCycle(..)

 -or-

call LowPowerListening.setLocalSleepInterval(..)

 

The setLocalSleepInterval() method is going to give you more precision on
how long your radio is off (compared to the setLocalDutyCycle() method).
See TEP 105 for more details.

 

You don't need to mess with arbitration at this level.  The CC2420 does use
an arbiter down below when accessing the shared SPI bus.

 

-David

 

 

 

 


  _  


From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of mona zima
Sent: Friday, July 20, 2007 12:10 PM
To: Tinyos-help@Millennium.Berkele

RE: [Tinyos-help] Checking CRC

2007-08-09 Thread David Moss
Jon -

I know you sent this awhile ago, and I was just combing through some tinyos
help emails and found it.  Sorry I didn't see it before.

There is currently no platform independent method of checking CRC's from the
application layer.  The radio or radio stack is responsible for rejecting
packets with bad CRC's, so any packet that does get through is assumed to
have a good CRC check.  In the case of the CC2420, the radio auto-checks
CRC's and flips a bit to indicate good or bad (cc2420 datasheet has more
details).  CC2420ReceiveP verifies that bit before doing anything with the
packet.

If you're using the packet link layer and are receiving the same message
twice, then yes, something went wrong.  Either the message didn't pass the
CRC check so it never entered the stack, or the packet was good and the
acknowledgement was dropped/corrupted.  In both cases the transmitter will
continue trying to deliver the packet.  It's then up to the UniqueReceive
layer to filter out duplicates.

-David


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jon Green
Sent: Friday, June 01, 2007 7:48 AM
To: tinyos-help
Subject: [Tinyos-help] Checking CRC

Does anyone know how I can check if a packet passed CRC check in a nice
platform independent way? I can't find any abstraction for CRC checks...

I have an application that is occasionally getting packets with
malformed data in them. When it gets a bad packet, a good packet always
arrives soon after with the same DSN, which means it didn't ack the bad
packet, and the other mote sent the data again. This leads me to believe
that the packet failed the CRC check. 

I'm working with a MicaZ mote. From what I see in the source, the CRC
field gets set in the metadata, but nothing ever gets done with it.
There is no link layer module for received packets, so the bad packet
makes it all the way to the application layer. Now at the application
layer I'm trying to figure out if there is a nice way to check if it
failed CRC without using CC2420Packet. Has anyone faced this before and
how is the accepted way to deal with it? 

I was also wondering if the optional packet link layer packet PacketLink
should include the receive interface? This would allow the networking
stack to drop packets that fail CRC checks. 

-Jon

___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


[Tinyos-help] motetrawler

2007-08-09 Thread n subhash
Hi,
i am unable to use trawler for applications other than delta please suggest
me how can i use trawler for other userdefined applications
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help