Re: [Tinyos-help] Increasing Baudrate for Atmega-128

2008-07-02 Thread Andrey Gursky
Hello Varun!

In my answer to you

https://www.millennium.berkeley.edu/pipermail/tinyos-help/2008-July/034704.html

there was already a link to

http://mail.millennium.berkeley.edu/pipermail/tinyos-help/2008-June/034373.html

where the problem is solved.

It is strange but the standard speed 256000 is not declared in the 
tinyos implementation of serial communication. That's why I used 230400.


Andrey


Varun Jain wrote:
> Hi,
> I am trying to increase the baudrate of the incoming packet for motes
> with atmega-128 processor. I am adding code in  the implementation
> Atm128UartP.nc located at /tos/chips/atm128/Atm128UartP.nc as follows:
> 
>  
> 
> else if (PLATFORM_BAUDRATE == 256000UL)
> 
>   m_byte_time = 15;  // 1 TMicor ~= 2.12 us, one byte = 31us ~= 15
> 
>  
> 
>  
> 
> $ java TestSerial -comm [EMAIL PROTECTED]:256000
> 
> [EMAIL PROTECTED]:256000 died - exiting (java.io.IOException: Could not
> configure COM1
> 
>  TOSComm JNI library runtime error: Error 87.
> 
>   The parameter is incorrect.
> 
>   in set_params.SetCommState)
> 
> 
> 
> I am running this in Windows(Cygwin) Why cant it configure this
> baudrate?? How and where is it configured, is it done in
> /tools/tinyos/java/ ???
> 
>  
> 
> Cheers,
> 
>  
> 
> Varun
> 
>  
> 
> 
> 
> 
> 
> 
> ___
> 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


Re: [Tinyos-help] Undefined reference to pow and sqrt functions in telosb!!!

2008-07-02 Thread Paul Stickney
You must link in the math library (-lm) -- also support may be
platform dependent and/or emulated.

On Tue, Jul 1, 2008 at 7:02 AM, John Paul <[EMAIL PROTECTED]> wrote:
> Hi,
> I am working on telosb motes. I am using the pow and sqrt functions of
> math.h library. I include the math.h header file in the source code. When i
> typed the command "make telosb", it gave me the following errors.

> app.c:(.text+0x4486): undefined reference to `pow'
> app.c:(.text+0x44a8): undefined reference to `pow'
> app.c:(.text+0x44b8): undefined reference to `sqrt'
>
>
> While if i compiled of micaz it didn't show any error.
>
> Could someone help in this regard. Help appreciated.
>
>
> Regards,
> john Paul
> ___
> 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


Re: [Tinyos-help] Problem with tinyos.jar

2008-07-02 Thread Paul Stickney
Odd.
What happens when you try to access the jar directly (via the jar command)?
Is it somehow corrupt? Really strange permissions? Non existant?

On Sun, Jun 29, 2008 at 11:34 PM, Anirudh Sivaraman
<[EMAIL PROTECTED]> wrote:
> Hi
>
> I tried to compile the application TestSerial in
> TOSROOT/apps/test/TestSerial using the make micaz command. I get the
> following error:

> " error reading /opt/tinyos-2.x/support/sdk/java/tinyos.jar; error in
> opening zip file"
>
> Can anybody help me out with this?
>
> Regards
> Anirudh
> ___
> 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


Re: [Tinyos-help] SPI - mica 2

2008-07-02 Thread
I have seen that the mote mica2 download the folder cc1000 (... 
tos/platforms/mica2/chips/ ). But on my programm I didn't implement this folder 
where is this initialize?

thanks

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

[Tinyos-help] about Broadcast component in tinyos2.x

2008-07-02 Thread jiwen zhang
Hello David :

I see there is Broadcast component in tinyos1.x in tos\lib\Broadcast,
is there the similar component in tinyos2.x ? i want to use it , but i don't
find . why is it taken out ?

thank you !!
-- 
zhang jiwen
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

tinyos-help@millennium.berkeley.edu

2008-07-02 Thread Antonio Prados Vilchez
I connected a 10K resistor between SCL (CLK in MDA300) and Vcc and another 
between SDA (DATA in MDA300) and Vcc, but it didn't work. Using the MTS300 to 
communicate with the microphone and magnetometer through the I2C interface, it 
happens the same, event I2CPacket.writeDone is not signaled, and I think they 
have the pull-up network implemented. Any ideas??

Thanks for your help.


-Mensaje original-
De: Christopher Leung [mailto:[EMAIL PROTECTED]
Enviado el: vie 27/06/2008 15:26
Para: Antonio Prados Vilchez; tinyos-help@millennium.berkeley.edu
Asunto: RE: [Tinyos-help] ADC&MDA300
 
You have to add a pull-up network to both I2C lines Data and Clk. On the MDA300 
board, just put a 10kOhm resistor between the Data and Vcc pins, and another 
one between Clk and Vcc.

Chris

 



From: Antonio Prados Vilchez [mailto:[EMAIL PROTECTED] 
Sent: June 27, 2008 7:50 AM
To: Christopher Leung; tinyos-help@millennium.berkeley.edu
Subject: RE: [Tinyos-help] ADC&MDA300

 

Thanks for your help Christopher.

I'm following the steps to read from the ADC ADS7828 in the MDA300 board, using 
the I2C interface. However, event I2CPacket.writeDone never occurs. I thought 
that it could be because of a mistake in my code, but I did a bit of research 
about the sensors of the MTS300 sensorboard which use the I2C interface 
(Microphone and magnetometer). In those components it also happens, the event 
I2CPacket.writeDone is never signaled. Does anybody know how to solve this 
problem?

Thanks in advance.


-Mensaje original-
De: Christopher Leung [mailto:[EMAIL PROTECTED]
Enviado el: lun 23/06/2008 18:30
Para: Antonio Prados Vilchez; tinyos-help@millennium.berkeley.edu
Asunto: RE: [Tinyos-help] ADC&MDA300

You also need to use the interface Resource from the Atm128I2CMasterC component.
Here are the steps you will need to do: Resource.request, wait for 
Resource.granted, I2C.write, wait for I2C.writeDone, I2C.read, wait for 
I2C.readDone, Resource.release.  It's important that you release the I2C 
resource especially if you have other components relying on it.
Chris



From: Antonio Prados Vilchez [mailto:[EMAIL PROTECTED]
Sent: Mon 6/23/2008 5:16 AM
To: Christopher Leung; tinyos-help@millennium.berkeley.edu
Subject: RE: [Tinyos-help] ADC&MDA300



Thanks for your help, Christopher.

Now I'm trying to use the I2C interface, as you said, but it doesn´t work. I 
get a lot of compiling errors in the I2CPacket and Atm128I2CMasterC files, so I 
think it's because of the instantiation. Am I doing it right? Should I upgrade 
my TinyOS files to a newer version? The way I instantiate these interfaces and 
components is:
---
implementation
{
...
components new Atm128I2CMasterC();

...   
App.I2CPacket -> Atm128I2CMasterC;
}

---
module SensorToRadioC
{
uses
{
...
interface I2CPacket;
}
}
---

Thanks in advance




 

 




Este mensaje se dirige exclusivamente a su destinatario, y puede contener 
información confidencial sometida a secreto profesional, o cuya divulgación 
esté legalmente prohibida.Cualquier opinión en él contenida es exclusiva de su 
autor y no representa necesariamente la opinión de la empresa. Si ha recibido 
este mensaje por error, le rogamos nos lo comunique de forma inmediata por esta 
misma vía y proceda a su eliminación, así como a la de cualquier documento 
adjunto al mismo. El correo electrónico vía Internet no es seguro y no se puede 
garantizar que no haya errores ya que puede ser interceptado, modificado, 
perdido o destruido, o contener virus. Cualquier persona que se ponga en 
contacto con nosotros por correo electrónico se considerará que asume estos 
riesgos.

This e-mail is addressed exclusively to the recipient and may contain 
privileged information under a professional confidential agreement or it may be 
against the law to disclose its contents. Any opinion contained in it belongs 
exclusively to his/her author and does not necessarily reflect the company's 
view. If you receive this e-mail in error, please let us know immediately (by 
return e-mail) and proceed to its destruction, as well as any document attached 
to it. The sending of e-mails through the Internet is not safe and, therefore, 
error-free communications cannot be guaranteed, as they can be intercepted, 
changed, misled or destroyed or they might contain a virus. Any user contacting 
us through e-mails shall be understood to be assuming these risks.



 


==
Este mensaje se dirige exclusivamente a su destinatario, y puede contener 
información confidencial sometida a secreto profesional, o cuya divulgación 
esté legalmente prohibida.Cualquier opinión en él contenida es exclusiva de su 
autor y no representa necesariamente la opinión de la empresa. Si ha recibido 
es

[Tinyos-help] MOTES for me to BUY

2008-07-02 Thread ekol
Hello everybody.

We think of forming a testbed and we would like to buy some motes, a  
base station a  connecting board to PC and S/W.

I have searched the web a lot and I would be gratefully if I had any  
suggestions of yours.

You may e-mail me at: [EMAIL PROTECTED] privately if postings brand  
name to the list could be considered an advertising.

Thanks in advance,

Eva Kolega
Phd student
National Technical University of Athens, GREECE

P.S. I have seen a lot about manageable motes with IPs Is this  
really operational ??(battery consumption??).


This Webmail system is supported by TEI of Athens Servers Team

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


[Tinyos-help] Question about nx_structs in C

2008-07-02 Thread Ashik Manandhar
Hi,

I am currently using TinyOS 1.1, and am using the serial forwarder program
to forward messages from my motes to a specific C file.  I want get data
from these messages since they are a known message type, but I don't know
how to incorporate this nx_struct into my C code.  Does anyone know how to
this, or if there is another dynamic way to do this?

-- 
Ashik Raj Manandhar
Undergraduate
Electrical Engineering and Computer Science
University of California, Berkeley
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Tmote UART0 RX?

2008-07-02 Thread Danne
Hello. I have tried works the ample code TestUart0 using tinyos 1.0 version. 
The error is showed: 21: parse error before 'new'.  
  
What is wrong?   
  
I don't change nothing in the code, and I'm trying connect a GPS module serial 
with a Tmote Sky.   
  
Any other code example?  
  
Thanks  
  
sorry about my english, I'm brazilian
---
Danne MCA
http://dannemca.multiply.com/___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Random Backoff Delays in TinyOS 2.x Channel Access

2008-07-02 Thread Anton
Hello!

There is probable bug in the 
/tinyos-2.x/tos/chips/cc2420/csma/CC2420CsmaP.nc (lines 218 and 225)

Communicating wireless modules should wait some random delay before 
performing Clear Channel Assess.
According to the IEEE 802.15.4 standard, that delay should be   
random(2^BE-1)   backoff periods, where BE can vary from 3 to 5 (the 
default values macMinBE and macMaxBE, IEEE 802.15.4-2006, pages 
163-164). This means that for CC2420 the maximum backoff delay is 31*320 
= 9920 microseconds (when BE=5), and the maximum initial backoff delay 
is 7*320 = 2240 microseconds (since initially BE=3).

But according to CC2420CsmaP.nc file the maximum initial backoff delay 
can be around 9765 microseconds (line 218) and maximum congestion 
backoff delay can be around 2441 microseconds (line 225).
It seems that the ranges of these random delays are swapped. Even in 
TinyOS 1.x the range of the initial delay is smaller than that of 
congestion backoff delay 
(/tinyos-1.x/tos/lib/CC2420Radio/CC2420RadioM.nc, lines 745 and 752). In 
TinyOS 2.x this is conversely.

Also, according to the standard the range of the random delay should 
expand (by default BE should change from 3 to 5) each time the channel 
is sensed busy (CSMA/CA algorithm - page 172 of the standard). But the 
range of all random delays is constant both in TinyOS 1.x and TinyOS 2.x.

Please, tell whether it is bug or not.

Kind regards,

Anton.

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


[Tinyos-help] tinyos,matlab

2008-07-02 Thread alka gautam
Hi,



I've been trying for days to get the Matlab->Java->SerialForwarder interface

to work.  I get the following error when I try to compile

MatlabControl.java.

MatlabContrl.java:39: cannot access com.mathworks.jmi.Matlab

bad class file:
C:\PROGRAM~1\UCB\cygwin\opt\tinyos-1.x\tools\java\jars\jmi.jar

class file has wrong version 49.0,should be 48.0

please remove or make sure it appears in the correct subdirectory of the
classpath

Matlab matlab = null;// this is the com.mathworks.jmi.Matlab class,which has


 functionality allowing one to  interact with the matlab session.
   ^

1 error



This looks to me like it's a problem with the java code, not my environment

or setup.  If that's the case then someone else must have run into this

problem.  Please help!!



Thanks,



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

[Tinyos-help] External hardware component using SPI

2008-07-02 Thread Gonçalo Teixeira
Dear Dr. Philip Levis,

I'm working on a school project where there's the need to add a hardware
component - an ADC - to micaz, using SPI. I've been looking for answers in
the mailing list archive and i've found 2. In the most recent one, someone
questioned you if you could share your code  and your circuit diagram. Since
i'm completely novice in this kind of matter, i wonder if you could be kind
enough to send it to me as well, as i would learn a lot from an example of
such implementation. Here's the previous answer for the same matter:
http://mail.millennium.berkeley.edu/pipermail/tinyos-help/2008-April/032819.html

Thank you for your attention,

Best regards,
Gonçalo Teixeira
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] LowPowerListening DutyCycle with mica2 motes

2008-07-02 Thread shalini k.s
I am trying to implement duty cycle on mica2 motes. I have a few doubts to 
clarify and I 
 need your help.
 
 Following are the few doubts related to duty cycle:
 
 1. How do we set the radio duty cycle to 1%( i have included
 call LowPowerListening.setLocalDutyCycle(100) in the application).
 Is this correct?
 
 2. What is the significance of the constants TIME_AFTER_CHECK  and
CC1K_LPL_CHECK_TIME.
 
 3. How is the parameter 100 (for 1%) set in the application converted to 1% 
dutycycle.
 
 Thanks and regards,
 Shalini.
   
-
 Did you know? You can CHAT without downloading messenger.  Click here___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] AMSend.sendDone

2008-07-02 Thread ndessart
Hello every body

 I have implented an algorithm on TOSSIM , in which nodes broadcat a
message every x seconds. It works well.

Now I'm trying to do a very simple algorithm where there 2 nodes, node
1 send a message to node 2 and node 2 displays a message when receiving.

But the event senDone is neiver signal (I have put a message to be print),
 I don't understand , i also try BlinkToRadioC (found in the Mote-mote_radio
communication tutorial) and adding a printing message in send done, nothing
occurs??

Is there some nuance I don't realize? 


Here is the cpp code I use to run the BlinkToRadioC simulation

#include
#include
#include
#include
#include

//number of motes
int nbCapteurs=2;

int main(int argc,char **argv)
{  

Tossim * t=new Tossim(NULL);
Radio *r;
int i,j,k,val;  
t->addChannel("Boot",stdout);

for(i=1;i<=nbCapteurs;i++)
{
for(j=i+1;j<=nbCapteurs;j++)
{
r->add(i,j,-4);
r->add(j,i,-4);
}   
}

for(i=1;i<=nbCapteurs;i++)
{
t->getNode(i)->addNoiseTraceReading(-18);
t->getNode(i)->createNoiseModel();
t->getNode(i)->bootAtTime(0);
}

while(nb<4000)
{
t->runNextEvent();
nb++;
}   

return EXIT_SUCCESS;
}

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


[Tinyos-help] Differential Analog Channels

2008-07-02 Thread Lutz, Thomas D
Hi All,

I'm trying to collect and record data from external sensors hardwired to an 
MDA320 board. I can get the single-ended channels to work just fine. However, 
I'm having trouble with the differential ones, I thought I could call the 
channel numbers (7-13) just like I did the single-ended channels but the data 
received is nonsense. Does anyone know how or have experience working with the 
differential channels on any of the boards?

Thanks in advance,

Tom Lutz
University of Kentucky
Anderson Tower S016
[EMAIL PROTECTED]
(740) 550-1327

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


[Tinyos-help] Time in Trickle

2008-07-02 Thread Jimmy Lee
Hi, everyone:

  I've read the Trickle implementation code
(\tos\lib\net\TrickleTimerImplP.nc) in 2.X.

  And I'm puzzled by the variable "time" in this code.

  This is the defination of struct "trickle_t":
  typedef struct {
uint16_t period;
uint32_t time;
uint32_t remainder;
uint8_t count;
  } trickle_t;


  I wonder about what the "time" and "remainder" means?

  Also, at the function "adjustTimer()", I have some  questions.

event void Timer.fired()
{
uint8_t i;
uint32_t dt = call Timer.getdt();

for (i = 0; i < count; i++)
{
  uint32_t remaining = trickles[i].time;//What does the remaining mean?
  if (remaining != 0)
{
  remaining -= dt;// Does this make remaining negative?
  if (remaining == 0)

{
  if (trickles[i].count < k)
{
  atomic
{
call Pending.set(i);
  }
  post timerTask();
  }

generateTime(i);

   /* Note that this logic is not the exact trickle algorithm.
* Rather than C being reset at the beginning of an interval,
* it is being reset at a firing point. This means that the
* listening period, rather than of length tau/2, is in the
* range [tau/2, tau].
*/


trickles[i].count = 0;//
   }
   else
{
trickles[i].time = remaining;//So trickles[i].time becomes
negative?
   }
  }
  }
adjustTimer();
  }
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] FTSP

2008-07-02 Thread Fazekas Adrian
Hi all,

I'm having some trouble compiling a Test application which uses FTSP 
(TestFTSP), downloaded from CVS rep 
http://tinyos.cvs.sourceforge.net/tinyos/tinyos-2.x-contrib/stanford-lgl/apps/

After having worked around some errors about not found Components, I get a 
strange syntax error. I didn't alter the downloaded code.

In file included from 
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncC.nc:43,
 from TestTimeSyncC.nc:33:
In component `TimeSyncM':
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc:43: syntax error 
before `T32khz'
In file included from 
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncC.nc:43,
 from TestTimeSyncC.nc:33:
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc: In function 
`sendMsg.runTask':
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc:352: `Send' undeclared 
(first use in this function)
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc:352: (Each undeclared 
identifier is reported only once
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc:352: for each function 
it appears in.)
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc: At top level:
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc:359: unknown interface 
`Send'
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc: In function 
`Init.init':
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncM.nc:434: `Send' undeclared 
(first use in this function)
In file included from /opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageC.nc:46,
 from 
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncC.nc:57,
 from TestTimeSyncC.nc:33:
In component `TimeSyncMessageP':
/opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageP.nc: At top level:
/opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageP.nc:93: conflicting types for 
`Packet.getPayload'
/opt/tinyos-2.x/tos/interfaces/Packet.nc:108: previous declaration of 
`Packet.getPayload'
/opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageP.nc: In function 
`Packet.getPayload':
/opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageP.nc:94: warning: passing 
argument 2 of `SubPacket.getPayload' makes pointer from integer without a cast
/opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageP.nc: In function 
`TimeSyncSend32khz.getPayload':
/opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageP.nc:129: too many arguments to 
function
In file included from /opt/tinyos-2.x/tos/chips/cc2420/csma/CC2420CsmaC.nc:53,
 from 
/opt/tinyos-2.x/tos/chips/cc2420/CC2420ActiveMessageC.nc:58,
 from /opt/tinyos-2.x/tos/platforms/telosa/ActiveMessageC.nc:61,
 from /opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageC.nc:46,
 from 
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncC.nc:57,
 from TestTimeSyncC.nc:33:
In component `CC2420CsmaP':
/opt/tinyos-2.x/tos/chips/cc2420/csma/CC2420CsmaP.nc: At top level:
/opt/tinyos-2.x/tos/chips/cc2420/csma/CC2420CsmaP.nc:159: conflicting types for 
`Send.getPayload'
/opt/tinyos-2.x/tos/interfaces/Send.nc:114: previous declaration of 
`Send.getPayload'
In component `CC2420ReceiveP':
/opt/tinyos-2.x/tos/chips/cc2420/receive/CC2420ReceiveP.nc:66: 
`Receive.payloadLength' not implemented
/opt/tinyos-2.x/tos/chips/cc2420/receive/CC2420ReceiveP.nc:66: 
`Receive.getPayload' not implemented
In file included from 
/opt/tinyos-2.x/tos/chips/cc2420/receive/CC2420ReceiveC.nc:51,
 from 
/opt/tinyos-2.x/tos/chips/cc2420/transmit/CC2420TransmitC.nc:90,
 from /opt/tinyos-2.x/tos/chips/cc2420/csma/CC2420CsmaC.nc:65,
 from 
/opt/tinyos-2.x/tos/chips/cc2420/CC2420ActiveMessageC.nc:58,
 from /opt/tinyos-2.x/tos/platforms/telosa/ActiveMessageC.nc:61,
 from /opt/tinyos-2.x/tos/chips/cc2420/TimeSyncMessageC.nc:46,
 from 
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncC.nc:57,
 from TestTimeSyncC.nc:33:
In component `CC2420PacketC':
/opt/tinyos-2.x/tos/chips/cc2420/packet/CC2420PacketC.nc:47: interface 
LinkPacketMetadata not found
/opt/tinyos-2.x/tos/chips/cc2420/packet/CC2420PacketC.nc:99: 
`highChannelQuality' is not in interface `LinkPacketMetadata'
In component `TimeSyncC':
/opt/tinyos-2.x/tos/chips/cc2420/interfaces/TimeSyncC.nc:59: cannot find `Send'
make: *** [exe0] Error 1

Somebody any ideas?

Greets,

Adrian

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

[Tinyos-help] Dear Sir, need help in programming Micaz

2008-07-02 Thread zhia howe chong
HI Sir,

I am a beginner in this micaz and mda320 devices. So far, i have acquired 4
micaz motes and 4 mda320 platform from my supervisor. Now, my task is to
setup a WSN, where each of the motes will take data for different readings
and different places, and whicn be setup easily.

I have done the first part by just connecting sensor to AD0 port, and the
reading of the data will be displayed in VOLTAGE in Moteview. I have done
some conversion of the reading through formula provided by the sensor
vendors.

Next, my project critical part is this. I have to program the motes so tat
one of the mote, which connects to the mda320, will do counter purpose. Let
say, i connect a rain gauge to that platform, so for every 10 drops of rain,
the MDA320 will count the number of rain drops. So, let say my Mote 2 to
Mote 4 are taking data for the temperature at an interval of 30 minutes,
after 10 drops of rain, the Motes will reduce the interval time to 20
minutes in data recording. When there are even more frequent of rain drops,
the interval time for Mote 2  to Mote 4 will change to 10 minutes of
interval time to take reading. How can i achieve this objective?

Can i use Motework in WIndow XP? How can i edit the binary files using
TinyOS?

Can sir lead me to this in a step-by-step manner? i would appreciate it a
lot.

Best Regards,
David Chong
Petronas University of Technology
Malaysia
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Size Code problem

2008-07-02 Thread Roger Potter
Hello,
it is my first mail.
I'm interested in knowing if there is any size code limitation, because I am 
developing an app of more than 1000 lines and during the test i see that 
tossim  does not execute well parts of the code that alone goes well or has 
been  tested by others member of the tinyos community.
Thanks for your time,
--Roger. 


  __ 
Enviado desde Correo Yahoo! La bandeja de entrada más inteligente.___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Dissemination in TinyOS

2008-07-02 Thread Umair Bhatti
Hello

Hope you will be fine. Actually i doing my B.E final year project on wsn. I
am running dissemination code using multihop routing on micaz motes
successfully in tinyos2. But i have to interface MDA2400 programming board
with the Electrochemical sensor. Actually i dont have code of MDA 2400 in
tinyos2, so i have to shift my code of dissemination in tinyos1.x. So can
you please provide me guideline about the disseminatin using multihop
routing in tinyos1.x.

Waiting for your reply

Thanks.

Regards:

Umair Ahmed Bhatti
B.E (Infomation and Communicaiton System Engg)
NUST
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Mandriva tinyos-2.0.1-5

2008-07-02 Thread ndessart
Hello

Timers don't works well with mandriva 2008.0
using tossim and tinyos 2.0.1-5.

what's wrong?

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


[Tinyos-help] Differential Analog Channels

2008-07-02 Thread Lutz, Thomas D
I'm using an MDA320 on an iris mote. I want to be able to use the differential 
channels to read data from a sensor. Does anyone know what changes must be made 
to the XMDA320M.nc (and subsequent files) in order to enable and read the 
differential channels?

Thanks for your help,

Tom Lutz
University of Kentucky
[EMAIL PROTECTED]


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


Re: [Tinyos-help] boomerang lowpower mesh

2008-07-02 Thread david henry
 The macro UARTDETECT_POLL is set to 3 seconds, so the base expects a
UartDetectMsg message before that. The Trawler application sends the message
every 2 secs. If you are sending only every 5 secs it would explain why UART
detect requests keep appearing.

I also have the problem where the base station sometimes 'locks up'. If you
connect the base station to Serial Forwarder and then open up Trawler (via
SF) you will see that the 'packets written' counter increments every 2 secs
(as it should). After a random time I start getting a Write Failed message
in the SF window, again every 2 secs. This problem happens both with and
without the lowpower compile option.

 Apropos your comment about receiving messages that were queued up, isn't
that what is supposed to happen?

Finally I spotted another issue which may or may not be relevant to you. I
am using heterogeneous hardware. My base station is a telosb and the motes
are homebrewed. Netsync has a mechanism to detect slippage between the 32KHz
clocks of the base station and the mote. With a heterogenous system its
probaby more likely to happen as the 32KHz crystals were sourced
differently. Making a base station based upon my homebrew is a bit difficult
as the UART1 lines are inaccesible. Even if I could I'm not convinced that a
heterogeneous net would not exhibit slippage between crystals.
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] a question about TYMO protocol

2008-07-02 Thread mohammed tarek
hiii
I am working on my graduate project which is distributed control system using 
wireless network and I am using TYMO protocol to implement a network layer in 
my project and I have used the dymo library and I followed the instructions in 
the lesson associated with this toppic but when I build the program the 
following message appears
Setting up for TinyOS 2.x
[EMAIL PROTECTED]:/opt/tinyos-2.x/apps/smarthouse/RadioSenseToLeds$ make 
telosbmkdir -p build/telosbncc -o build/telosb/main.exe -Os -O -mdisable-hwmul 
-Wall -Wshadow -DDEF_TOS_AM_GROUP=0x7d -Wnesc-all -target=telosb 
-fnesc-cfile=build/telosb/app.c -board= -I/opt/tinyos-2.x/tos/lib/net 
-I/opt/tinyos-2.x/tos/lib/net/dymo -I/opt/tinyos-2.x/tos/lib/net/le 
-I/opt/tinyos-2.x/tos/lib/net/ctp -DIDENT_PROGRAM_NAME=\"RadioSenseToLed\" 
-DIDENT_USER_ID=\"mohammed\" -DIDENT_HOSTNAME=\"mohammed-laptop\" 
-DIDENT_USER_HASH=0x7476a828L -DIDENT_UNIX_TIME=0x4858f591L 
-DIDENT_UID_HASH=0xe8e1896aL RadioSenseToLedsAppC.nc -lmcompiling 
RadioSenseToLedsAppC to a telosb binaryIn file included from 
RadioSenseToLedsAppC.nc:55:In component 
`RadioSenseToLedsC':RadioSenseToLedsC.nc: In function 
`Boot.booted':RadioSenseToLedsC.nc:71: parameters missing in call to 
parameterised command or event
RadioSenseToLedsC.nc: At top level:RadioSenseToLedsC.nc:81: conflicting types 
for `SplitControl.startDone
/'opt/tinyos-2.x/tos/interfaces/SplitControl.nc:92: previous declaration of 
`SplitControl.startDone'RadioSenseToLedsC.nc:87: conflicting types for 
`SplitControl.stopDone
/
/
In file included from 
RadioSenseToLedsAppC.nc:56'opt/tinyos-2.x/tos/interfaces/SplitControl.nc:117: 
previous declaration of 
`SplitControl.stopDone'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:26:33: 
warning: extra tokens at end of #ifdef directive:In component `DymoNetworkC
/
In file included from RadioSenseToLedsAppC.nc:56
/':opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:32: interface MHControl not 
found:opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:39: component MHServiceC not 
found/opt/tinyos-2.x/tos/lib/net/DymoServiceC.nc:6:28: StorageVolumes.h: No 
such file or directory/opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:39: failed to 
preprocess /opt/tinyos-2.x/tos/lib/net/DymoServiceC.nc/
/
/
/
/
/
/
/
/
/
/
/
/
/
/
/
/opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:48: cannot find 
`MHSend'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:49: cannot find 
`Receive'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:51: cannot find 
`MHPacket'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:52: cannot find 
`Packet'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:53: cannot find 
`Intercept'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:64: cannot find 
`AMPacket'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:65: cannot find 
`SubPacket'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:66: cannot find 
`AMSend'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:67: cannot find 
`SubReceive'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:68: cannot find 
`Acks'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:70: cannot find 
`AMPacket'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:71: cannot find 
`Packet'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:72: cannot find 
`AMSend'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:73: cannot find
 `Receive'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:75: cannot find 
`LinkMonitor'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:80: cannot find 
`SplitControl'opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:86: cannot find 
`MHControl'In component `RadioSenseToLedsAppC':RadioSenseToLedsAppC.nc:63: no 
match
make: *** [exe0] Error 1


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

[Tinyos-help] Begginer in tinyos an tenet.

2008-07-02 Thread Érico Lemos
Hi,

Can I test tenet without a mote ??

-- 
[]s,
Érico Lemos



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


Re: [Tinyos-help] Segfault in TOSSIM. Please help

2008-07-02 Thread Morten Hansen
Have you tried with the latest version from CVS?

On Thu, Jun 19, 2008 at 9:51 PM, Elvar Ólafsson <[EMAIL PROTECTED]> wrote:

> Hi.
>
> The output in our first message is the stacktace from gdb. Our simulation
> runs for quite some time before segfaulting. We have no idea why it fails in
> that sim_noise.c file. We are running TinyOS 2.0.2 if that is any help.
>
> Hope you can help us with this.
>
> With regards,
> Elvar and Henrik
>
>
> On Fri, Jun 20, 2008 at 3:32 AM, Philip Levis <[EMAIL PROTECTED]> wrote:
>
>>
>> On Jun 18, 2008, at 1:36 AM, Elvar Ólafsson wrote:
>>
>>  Thank you for your response.
>>>
>>> We think we are adding more than 100 noise readings. We are using the
>>> meyer-heavy.txt that comes with the TOS distribution to add noise
>>> readings.
>>>
>>> Our driver cpp program can be seen below. Any ideas or obvious flaws in
>>> that
>>> respect?
>>>
>>> Again, any help is appreciated.
>>>
>>>
>>> #include 
>>> #include 
>>> #include 
>>> #include 
>>> #include 
>>>
>>> using namespace std;
>>>
>>> int main(int argc, char *argv[])
>>> {
>>>
>>>  Tossim* t = new Tossim(NULL);
>>>  Radio* r = t->radio();
>>>
>>>  FILE* pFile;
>>>  pFile = fopen("topo.txt", "r");
>>>
>>>  int source = 0;
>>>  int dest = 0;
>>>  float gain = 0.0;
>>>
>>>
>>>  while((fscanf(pFile, "%u %u %f", &source, &dest, &gain)) != EOF)
>>>  {
>>>r->add(source, dest, gain);
>>>  }
>>>
>>>  FILE* pFile1;
>>>  pFile1 = fopen("meyer-heavy.txt", "r");
>>>  int noise = 0;
>>>
>>>  while((fscanf(pFile1, "%d", &noise)) != EOF)
>>>  {
>>>for(int i = 0; i < 6; i++)
>>>{
>>>  t->getNode(i)->addNoiseTraceReading(noise);
>>>}
>>>  }
>>>
>>>  for(int i = 0; i < 6; i++)
>>>  {
>>>t->getNode(i)->createNoiseModel();
>>>  }
>>>
>>>  int startTime = 1000;
>>>  for(int i = 0; i < 6 ; i++)
>>>  {
>>>t->getNode(i)->bootAtTime(startTime);
>>>startTime += 100;
>>>  }
>>>
>>>  while(true)
>>>  {
>>>t->runNextEvent();
>>>  }
>>>
>>>  return 0;
>>> }
>>>
>>>
>>>
>>> On Tue, Jun 17, 2008 at 6:12 PM, Paul Stickney <[EMAIL PROTECTED]>
>>> wrote:
>>> Ensure that you are adding 100 noise trace readings before trying to
>>> build a model.
>>>
>>>
>> Can you run it in gdb and figure out what's wrong?
>>
>> Phil
>
>
>
> ___
> Tinyos-help mailing list
> Tinyos-help@millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>



-- 
Morten Hansen, http://mortent.dk
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] About resource arbitration between Uart0 and Radio on telosb mote

2008-07-02 Thread Kirak, Hong
Hello, guys,

 

I'm making a program which uses radio and uart0 on the telosb mote.

 

Since the radio and uart0 share bus on telosb, I had to deal with resource
arbitration.

 

The thing is, when I made an uart0 manager like this, it dosen't work.

 

More specifically, after some time, I never receive sendDone() signal after
I send() and got a SUCCESS return value, 

 

So the entire program is collapsed.

 


--

  task void requestTask()

  {

call UartResource.request();

  }

 

  async event void UartRequested.requested()

  {

UartResource.releaseTask();

post requestTask();

  }

 

  async event void UartRequested.immediateRequested()

  {

UartResource.releaseTask();

post requestTask();

 

  }


--

 

I know it's greedy, because everytime it releases, it requests again.

 

But as I know about CC2420 on telosb, it should work.

 

Anyway, I tried another case like following, and it works!

 


--

  

  event void RadioSend.sendDone[am_id_t id](message_t* msg, error_t error) {

 

post requestTask();

}

 

  task void requestTask()

  {

call UartResource.request();

  }

 

  async event void UartRequested.requested()

  {

UartResource.releaseTask();

  }

 

  async event void UartRequested.immediateRequested()

  {

UartResource.releaseTask();

  }


--

 

It seems much less greedy since it only tries to grab the resource after
sendDone() has signaled.

 

Does anybody can answer me about the problem with case 1?

 

And in addition, why the CC2420 releases the resource between send() and
sendDone()?

 

Thanks.

 

With Kind Regards,

Kirak

 

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

[Tinyos-help] Disable backoff CC2420 tmote sky

2008-07-02 Thread Alessandro Camillo'
I am wondering if disabling CCA check before sending a packet also 
implies that i will not be able to detect collision.

If am not interested in detecting collision i would see CCA to false. 
But checking CC2420 radio stack and precisely in attemptSend()
it seems that the stack just send the packet, using either STXONCCA or 
STXON, but still manages congestions even if
m_cca was set to false. I past a piece of code from the 
CC2420TransmitP.nc module

>   status = m_cca ? call STXONCCA.strobe() : call STXON.strobe();
>   if ( !( status & CC2420_STATUS_TX_ACTIVE ) ) {
> status = call SNOP.strobe();
> if ( status & CC2420_STATUS_TX_ACTIVE ) {
>   congestion = FALSE;
> }
>   }
>   
>   m_state = congestion ? S_SAMPLE_CCA : S_SFD;
>   call CSN.set();
> }
> 
> if ( congestion ) {
>   totalCcaChecks = 0;
>   releaseSpiResource();
>   congestionBackoff();
> } else {
>   call BackoffTimer.start(CC2420_ABORT_PERIOD);
> }
>  

Shouldn't the last if (congestion) be executed if and only if CCA was 
set to true and congestion detected? The default value of congestion is 
TRUE.

Thanks
Alessandro


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


[Tinyos-help] Set path for TOSSIM

2008-07-02 Thread anand . ankit04
I have tried upgading my tinyos with the help of this site. and set the path
accordingly.
http://www.tinyos.net/tinyos-2.x/doc/html/upgrade-tinyos.html


TOSROOT/opt/tinyos-2.xsame as in Cygwin
TOSDIR$TOSROOT/tossame as in Cygwin
CLASSPATHC:\tinyos\cygwin\opt\tinyos-2.x\support\sdk\java\tinyos.jar;.$TOSROOT/support/sdk/java/tinyos.jar:.
MAKERULES$TOSROOT/support/make/Makerulessame as in Cygwin
PATH†/opt/msp430/bin:$PATHsame as in Cygwin



export PYTHONPATH=$TOSROOT/support/sdk/pytho
but i am not able to run command as described in the tutorial
from TOSSIM impòrt  *
this line shows import error no module called TOSSIM.

Please help me to solve my problem.


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

[Tinyos-help] Xubuntos + tos1 tinyviz

2008-07-02 Thread chen
Hi:
I download XubunTOS 7.04 + TinyOS 2.0.2.
I was  trying to run the tinyviz under tos1 environment, but has some
java errorr:
Exception in thread "main" java.awt.AWTError: Cannot load AWT toolkit:
gnu.java.awt.peer.gtk.GtkToolkit
   at java.awt.Toolkit.getDefaultToolkit(libgcj.so.70)
   at java.awt.Font.tk(libgcj.so.70)
   at java.awt.Font.getPeerFromToolkit(libgcj.so.70)
   at java.awt.Font.(libgcj.so.70)
   at net.tinyos.sim.TinyViz.(TinyViz.java:58)
   at java.lang.Class.initializeClass(libgcj.so.70)
   at net.tinyos.sim.SimDriver.(SimDriver.java:282)
   at net.tinyos.sim.SimDriver.main(SimDriver.java:539)
Caused by: java.lang.UnsatisfiedLinkError: libgtkpeer: libgtkpeer.so: cannot
open shared object file: No such file or directory
   at java.lang.Runtime._load(libgcj.so.70)
   at java.lang.Runtime.loadLibrary(libgcj.so.70)
   at java.lang.System.loadLibrary(libgcj.so.70)
   at gnu.java.awt.peer.gtk.GtkToolkit.(libgcj.so.70)
   at java.lang.Class.initializeClass(libgcj.so.70)
   at java.lang.Class.forName(libgcj.so.70)
   at java.awt.Toolkit.getDefaultToolkit(libgcj.so.70)
   ...7 more

Do you guys know how to solve this problem?

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

Re: [Tinyos-help] About TOSH_READ_RADIO_CCA_PIN()

2008-07-02 Thread 정관희
I use cc2420 radio chip. So, I know it has a CCA pin.
What i'm saying, TOSH_READ_RADIO_CCA_PIN() checks whether CCA pin is
available or not.
That is, I want to confirm how to run this function through its code.
how do I do?
2008/6/13 Min Guo <[EMAIL PROTECTED]>:

>
> Which radio do you use? On cc2420 there is a CCA pin available. CCA
> indicates whether the channel is clear or with energy, and surely the
> neighborhood nodes affects if they are communicating in the same
> channel.
>
> On Fri, Jun 13, 2008 at 10:34 AM, JeongKwanhee <[EMAIL PROTECTED]> wrote:
> > Hello, all members of TinyOS
> >
> >
> >
> > In general TinyOS, TOSH_READ_RADIO_CCA_PIN() is able to use some function
> if
> > we want to check the state of channel.
> >
> > But, I don't know how to calculate whether channel is clear or not.
> >
> >
> >
> > I just think that it compares to rssi and cca.
> >
> > But, in this case, I think it does not consider the interference of
> adjacent
> > nodes.
> >
> > For example, SINR.
> >
> >
> >
> > So, I want to check TOSH_READ_RADIO_CCA_PIN() function, and then to fix
> this
> > function.
> >
> >
> >
> > If you know about this, please contact to me. Thank you.
> >
> >
> >
> > _
> >
> > Kwanhee Jeong
> >
> > Tel: +82-62-970-3147
> > Cell: +82-16-387-6870
> > Fax: +82-62-970-2291
> >
> > _
> >
> >
> >
> > ___
> > 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

[Tinyos-help] question about LoggerWrite

2008-07-02 Thread milos rovcanin
Hi!
I was wondering if you could help me: i am trying to develop an application
which will be able
to receive a packet of a certain ( user defined ) type (nested headers).
Now, i have a problem because i dont know how to write a whole packet to
EEPROM. LoggerWrite.write(...)  function expects a uint8_t * data type and
here i have a packet  more than 30 bytes long! My question is : how to write
my packet into EEPROM using LoggerWrite functions?

thank you for your help
 Milos Rovcanin,Serbia
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] How to design a hardware platform

2008-07-02 Thread dum dummy
Hi,

I have a basic question; not sure it belongs to which list, if it belongs
here at all. But I think some of you can give me some pointers.

How do I go about designing a hardware platform that would run software? I
am well versed in designing "hardware" that do not run any software (e.g.,
amplifiers; combinatorial circuits, etc.). I am also well versed in software
(that I run on PC). What I do not know is the glue (bootloader/BIOS?). I am
assuming that there is a standard way of doing it. But somehow I could not
find any resource (books or online documents) that explain that. For
concreteness, suppose that I want to design a system with an  OMAP processor
and 802.11g wireless. I can get the processors, RAM, crystal and wireless
chips. I am pretty sure that I can design a circuit board to connect them,
as per the data sheet. Now what? How does the "cold-start" work? How do I
configure the system (both my board and the PC) so that I can download
codes? There must be some software running on the board that would download
the code via a USB/serial cable. How is *that* code first downloaded (kind
of a chichen-and-egg problem :) )? Do the processors "come" with such a
code? Next, how is the 802.11g chip "recognized"?

Any pointer is appreciated (book, online site, academic courses that cover
this...).

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

[Tinyos-help] lagunita noise

2008-07-02 Thread ndessart
hello


does somebody try the lagunita noise model in tossim?

thanks

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


[Tinyos-help] Initializing an nx_struct

2008-07-02 Thread Symon Vezina
Hi,

I'm trying to initialize an nx_struct like follows:

typedef nx_struct subscriber {
nx_uint8_t taskId;
nx_uint8_t eventId;
} subscriber_t;

subscriber_t sub = {1,2};

but the compiler keeps giving me theses warnings:

source/TestListP.nc:30: warning: missing braces around initializer
source/TestListP.nc:30: warning: (near initialization for `sub.taskId')


The initialization doesn't generate warnings if I take away the "nx_"
prefix keyword from the whole structure.

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


[Tinyos-help] pb with rssi and mig with micaz on tinyos2

2008-07-02 Thread Plaçais Pierre
Hello,
I work on a wireless sensing network with micaz. I use tinyos2 on xubuntos.

For my project, I need the rssi value. I have used the function get.rssi( ) but 
I have some questions:

What is the format of the rssi value (int8_t, int16_t, uint16_t) and how 
convert the value to found a value in dBm?

And I have an other problem with mig function.
When I use java net.tinyos.tools.MsgReader -comm network@:
I have just yriting on the screen network@: :resynchronising and 
nothing happened.

Thanks for your answers.
Cordially.
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] why the blink application cannot work?

2008-07-02 Thread Meiying Su
hi everyone,

   when i add the code " _BIS_SR(LPM3_bits);"in McuSleepC,why the blink
application cannot work ?could you give me some advice .thanks a lot


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

Re: [Tinyos-help] about Broadcast component in tinyos2.x

2008-07-02 Thread Omprakash Gnawali
On Wed, Jul 2, 2008 at 12:51 AM, jiwen zhang <[EMAIL PROTECTED]> wrote:
>
> Hello David :
>
> I see there is Broadcast component in tinyos1.x in tos\lib\Broadcast,
> is there the similar component in tinyos2.x ? i want to use it , but i don't
> find . why is it taken out ?
>

You should look into Dissemination.

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


Re: [Tinyos-help] Begginer in tinyos an tenet.

2008-07-02 Thread Omprakash Gnawali
On Mon, Jun 30, 2008 at 5:34 AM, Érico Lemos <[EMAIL PROTECTED]> wrote:
> Hi,
>
> Can I test tenet without a mote ??
>

Yes. There is a support for emstar emulation now. You should read this
document to learn how:
http://enl.usc.edu/cgi-bin/viewcvs/viewcvs.cgi/tenet/doc/Centroute_and_Emulation.HOWTO?rev=1.8&content-type=text/vnd.viewcvs-markup

- om_p

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


Re: [Tinyos-help] problems with tymo-dymo

2008-07-02 Thread Andrey Gursky
Hi!

So there is an error I get when I compile TestTymo with the latest 
tinyos-2.x cvs and nesc-1.3.0beta4 for sim or sim-sf. The platforms I'm 
using are IRIS and MicaZ.

It doesn't like these lines in
$TOSROOT/tos/lib/safe/include/annots_stage1.h


(31) struct @safe { };
(32) struct @unsafe { };




[EMAIL PROTECTED]:~/tinyos-2.x/apps/tests/TestTymo$ make micaz sim
mkdir -p simbuild/micaz
   placing object files in simbuild/micaz
   writing XML schema to app.xml
   compiling TestC to object file sim.o
ncc -c -shared -fPIC -o simbuild/micaz/sim.o -g -O0 
-I../../../tos/lib/net/tymo -I../../../tos/lib/net/tymo/dymo 
-I../../../tos/lib/net/tymo/mh -tossim -fnesc-nido-tosnodes=1000 
-fnesc-simulate -fnesc-nido-motenumber=sim_node\(\)   -Wall -Wshadow 
-Wnesc-all -target=micaz -fnesc-cfile=simbuild/micaz/app.c -board=micasb 
-DDEFINED_TOS_AM_GROUP=0x22 --param max-inline-insns-single=10 
-Isimbuild/micaz -DIDENT_APPNAME=\"TestC\" -DIDENT_USERNAME=\"andrii\" 
-DIDENT_HOSTNAME=\"wetnts19\" -DIDENT_USERHASH=0x54b84176L 
-DIDENT_TIMESTAMP=0x486b6c77L -DIDENT_UIDHASH=0xdf6689cfL 
-Wno-nesc-data-race TestC.nc   -fnesc-dump=components 
-fnesc-dump=variables -fnesc-dump=constants -fnesc-dump=typedefs 
-fnesc-dump=interfacedefs -fnesc-dump=tags -fnesc-dumpfile=app.xml
   compiling Python support and C libraries into pytossim.o, tossim.o, 
and c-support.o
g++ -c  -shared -fPIC -o simbuild/micaz/pytossim.o -g -O0 
-DIDENT_APPNAME=\"TestC\" -DIDENT_USERNAME=\"andrii\" 
-DIDENT_HOSTNAME=\"wetnts19\" -DIDENT_USERHASH=0x54b84176L 
-DIDENT_TIMESTAMP=0x486b6c77L -DIDENT_UIDHASH=0xdf6689cfL 
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx 
-I/usr/include/python2.5 -I/home/andrii/tinyos-2.x/tos/lib/tossim 
-DHAVE_CONFIG_H
In file included from /home/andrii/tinyos-2.x/tos/lib/tossim/tos.h:66,
  from /home/andrii/tinyos-2.x/tos/lib/tossim/tossim.h:39,
  from 
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:681:
/home/andrii/tinyos-2.x/tos/lib/tossim/../../lib/safe/include/annots_stage1.h:31:
 
error: stray [EMAIL PROTECTED] in program
/home/andrii/tinyos-2.x/tos/lib/tossim/../../lib/safe/include/annots_stage1.h:32:
 
error: stray [EMAIL PROTECTED] in program
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx: In function 
‘PyObject* _wrap_nesc_app_t_numVariables_set(PyObject*, PyObject*)’:
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:1999: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2000: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx: In function 
‘PyObject* _wrap_nesc_app_t_numVariables_get(PyObject*, PyObject*)’:
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2066: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2067: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx: In function 
‘PyObject* _wrap_nesc_app_t_variableNames_set(PyObject*, PyObject*)’:
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2134: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2135: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx: In function 
‘PyObject* _wrap_nesc_app_t_variableNames_get(PyObject*, PyObject*)’:
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2202: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2203: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx: In function 
‘PyObject* _wrap_nesc_app_t_variableTypes_set(PyObject*, PyObject*)’:
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2270: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2271: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx: In function 
‘PyObject* _wrap_nesc_app_t_variableTypes_get(PyObject*, PyObject*)’:
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2338: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2339: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx: In function 
‘PyObject* _wrap_nesc_app_t_variableArray_set(PyObject*, PyObject*)’:
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2406: warning: 
deprecated conversion from string constant to ‘char*’
/home/andrii/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx:2407: warning: 
deprecated conversion from strin

[Tinyos-help] a little question about SENSORBOARD and make

2008-07-02 Thread Javier Almansa Sobrino
Hi. I'm trying to program a mica2 with this command:

SENSORBOARD=mts300 make mica2.0x1001 install mib510,/dev/ttyS0

the problem is that it doesn't do nothing, absolutely nothing. If I try

SENSORBOARD=mts300 make mica2 install mib510,/dev/ttyS0

it compiles and load the program into the mica2, but I can't give a
specific node id to the mica.
Also if I try

make mica2.0x1001 mib510,/dev/ttyS0

it tryes to compile and load (obviously it can't because it doesn't
found the sensor modules required by my application).

and with

SENSORBOARD=mts300 make mica2
make mica2.0x1001 reinstall mib510,/dev/ttyS0

I can compile but I can't load the program into mica2 flash

someone knows how to compile with a specific node id and a specific
sensorboard?

thanks in advance

-- 
Nunca confies en un S.O. del que no tienes código fuente ;-)


Javier Almansa Sobrino.
Ingeniero Técnico en Informática de Sistemas.

Grupo de Investigación ARCo.
Escuela Superior de Informática. Ciudad Real
Tel: (+34)926 29 53 00 Ext: 3705


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


Re: [Tinyos-help] [Tinyos-devel] How to design a hardware platform

2008-07-02 Thread Aurelien Francillon
Le Tuesday 01 July 2008 08:13:21 dum dummy, vous avez écrit :
> Hi,
>
> I have a basic question; not sure it belongs to which list, if it belongs
> here at all. But I think some of you can give me some pointers.
>
> How do I go about designing a hardware platform that would run software?

well I really can't explain you how to design a platform from scratch, my 
first guess would be to look how the similar ones are working in deep 
details ... and read the datasheets ...

> Now what? How does the 
> "cold-start" work? How do I configure the system (both my board and the PC)
> so that I can download codes? There must be some software running on the
> board that would download the code via a USB/serial cable. How is *that*
> code first downloaded (kind of a chichen-and-egg problem :) )? Do the
> processors "come" with such a code? 

JTAG is one of the more widespread way to program "cold" hardware, most of the 
existing cpu/microcontrollers have one. 
Other than that (disclaimer not all info here has been checked) some hardware 
can come with it's own protocol/bus in hardware i.e.  :
- AVR parallel/serial/spi programming ( see the section called "memory 
programming" p288 of Atmega128 datasheet)

or present as software in some dedicated place such as  :
- bsl in the msp430 (telosb) 
- sam bootloader in some arm7 CPU by Atmel 


> Next, how is the 802.11g chip "recognized"?

well the simplest is to design the software according to the platform 
otherwise if you have no idea run linux, but then you are completely out of 
topic from this list ...

Aurélien

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


tinyos-help@millennium.berkeley.edu

2008-07-02 Thread Christopher Leung
I don't think the microphone and the magnetometer on the MTS300 use the I2C 
bus. Try using the digital pins on the MDA300 because it uses the I2C bus. To 
write to it, just send the value of the 8 pins to address 63.

 

Chris

 



From: Antonio Prados Vilchez [mailto:[EMAIL PROTECTED] 
Sent: July 2, 2008 4:44 AM
To: Christopher Leung; tinyos-help@millennium.berkeley.edu
Subject: RE: [Tinyos-help] ADC&MDA300

 

I connected a 10K resistor between SCL (CLK in MDA300) and Vcc and another 
between SDA (DATA in MDA300) and Vcc, but it didn't work. Using the MTS300 to 
communicate with the microphone and magnetometer through the I2C interface, it 
happens the same, event I2CPacket.writeDone is not signaled, and I think they 
have the pull-up network implemented. Any ideas??

Thanks for your help.


-Mensaje original-
De: Christopher Leung [mailto:[EMAIL PROTECTED]
Enviado el: vie 27/06/2008 15:26
Para: Antonio Prados Vilchez; tinyos-help@millennium.berkeley.edu
Asunto: RE: [Tinyos-help] ADC&MDA300

You have to add a pull-up network to both I2C lines Data and Clk. On the MDA300 
board, just put a 10kOhm resistor between the Data and Vcc pins, and another 
one between Clk and Vcc.

Chris





From: Antonio Prados Vilchez [mailto:[EMAIL PROTECTED]
Sent: June 27, 2008 7:50 AM
To: Christopher Leung; tinyos-help@millennium.berkeley.edu
Subject: RE: [Tinyos-help] ADC&MDA300



Thanks for your help Christopher.

I'm following the steps to read from the ADC ADS7828 in the MDA300 board, using 
the I2C interface. However, event I2CPacket.writeDone never occurs. I thought 
that it could be because of a mistake in my code, but I did a bit of research 
about the sensors of the MTS300 sensorboard which use the I2C interface 
(Microphone and magnetometer). In those components it also happens, the event 
I2CPacket.writeDone is never signaled. Does anybody know how to solve this 
problem?

Thanks in advance.


-Mensaje original-
De: Christopher Leung [mailto:[EMAIL PROTECTED]
Enviado el: lun 23/06/2008 18:30
Para: Antonio Prados Vilchez; tinyos-help@millennium.berkeley.edu
Asunto: RE: [Tinyos-help] ADC&MDA300

You also need to use the interface Resource from the Atm128I2CMasterC component.
Here are the steps you will need to do: Resource.request, wait for 
Resource.granted, I2C.write, wait for I2C.writeDone, I2C.read, wait for 
I2C.readDone, Resource.release.  It's important that you release the I2C 
resource especially if you have other components relying on it.
Chris



From: Antonio Prados Vilchez [mailto:[EMAIL PROTECTED]
Sent: Mon 6/23/2008 5:16 AM
To: Christopher Leung; tinyos-help@millennium.berkeley.edu
Subject: RE: [Tinyos-help] ADC&MDA300



Thanks for your help, Christopher.

Now I'm trying to use the I2C interface, as you said, but it doesn´t work. I 
get a lot of compiling errors in the I2CPacket and Atm128I2CMasterC files, so I 
think it's because of the instantiation. Am I doing it right? Should I upgrade 
my TinyOS files to a newer version? The way I instantiate these interfaces and 
components is:
---
implementation
{
...
components new Atm128I2CMasterC();

...  
App.I2CPacket -> Atm128I2CMasterC;
}

---
module SensorToRadioC
{
uses
{
...
interface I2CPacket;
}
}
---

Thanks in advance











Este mensaje se dirige exclusivamente a su destinatario, y puede contener 
información confidencial sometida a secreto profesional, o cuya divulgación 
esté legalmente prohibida.Cualquier opinión en él contenida es exclusiva de su 
autor y no representa necesariamente la opinión de la empresa. Si ha recibido 
este mensaje por error, le rogamos nos lo comunique de forma inmediata por esta 
misma vía y proceda a su eliminación, así como a la de cualquier documento 
adjunto al mismo. El correo electrónico vía Internet no es seguro y no se puede 
garantizar que no haya errores ya que puede ser interceptado, modificado, 
perdido o destruido, o contener virus. Cualquier persona que se ponga en 
contacto con nosotros por correo electrónico se considerará que asume estos 
riesgos.

This e-mail is addressed exclusively to the recipient and may contain 
privileged information under a professional confidential agreement or it may be 
against the law to disclose its contents. Any opinion contained in it belongs 
exclusively to his/her author and does not necessarily reflect the company's 
view. If you receive this e-mail in error, please let us know immediately (by 
return e-mail) and proceed to its destruction, as well as any document attached 
to it. The sending of e-mails through the Internet is not safe and, therefore, 
error-free communications cannot be guaranteed, as they can be intercepted, 
changed, misled or destroyed or they might contain a virus. Any user contacting 
us through e-mails shall be understood 

Re: [Tinyos-help] [Tinyos-devel] How to design a hardware platform

2008-07-02 Thread shankar satish
Hi,

Essentially, you need to know the science/art of firmware development.
There is no *standard* way of going about it: it all depends on the hardware
platform/microprocessor you are stating off with.

In any board, on reset, all register values and data pointer assume
pre-defined values. (Only you, the h/w designer knows these values). The
first instruction that is fetched by the uP (always written in assebly) is
of the type JMP . After jumping, the uP executes the "startup" code
(again written in assembly). The start-up code finally points to the rest of
the application, which is usually written in C.


Since you want to develop a board from absolute scratch, the best way to go
about it would be by reading the processor's datasheet. Generally speaking,
the more customized your board is, the more difficult it gets to find
information on the API's for firmware development: it eventually degenerates
to a black art.

It might be useful to do a google book search on topics like "embedded linux
development", "embedded firmware development", etc. Most firmware today is
written in assembly and C. It might be worth looking at the "Forth"
programming language. Bootloaders for a wide veriety of platforms have been
developed in Forth.

I too want to know more about how one goes about developing boards from
scratch. Please post any additional info you come across.

Thank you.

-Regards,
Shankar.


On Wed, Jul 2, 2008 at 1:44 PM, Aurelien Francillon <
[EMAIL PROTECTED]> wrote:

> Le Tuesday 01 July 2008 08:13:21 dum dummy, vous avez écrit :
> > Hi,
> >
> > I have a basic question; not sure it belongs to which list, if it belongs
> > here at all. But I think some of you can give me some pointers.
> >
> > How do I go about designing a hardware platform that would run software?
>
> well I really can't explain you how to design a platform from scratch, my
> first guess would be to look how the similar ones are working in deep
> details ... and read the datasheets ...
>
> > Now what? How does the
> > "cold-start" work? How do I configure the system (both my board and the
> PC)
> > so that I can download codes? There must be some software running on the
> > board that would download the code via a USB/serial cable. How is *that*
> > code first downloaded (kind of a chichen-and-egg problem :) )? Do the
> > processors "come" with such a code?
>
> JTAG is one of the more widespread way to program "cold" hardware, most of
> the
> existing cpu/microcontrollers have one.
> Other than that (disclaimer not all info here has been checked) some
> hardware
> can come with it's own protocol/bus in hardware i.e.  :
> - AVR parallel/serial/spi programming ( see the section called "memory
> programming" p288 of Atmega128 datasheet)
>
> or present as software in some dedicated place such as  :
> - bsl in the msp430 (telosb)
> - sam bootloader in some arm7 CPU by Atmel
>
>
> > Next, how is the 802.11g chip "recognized"?
>
> well the simplest is to design the software according to the platform
> otherwise if you have no idea run linux, but then you are completely out of
> topic from this list ...
>
> Aurélien
>
> ___
> 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

[Tinyos-help] Tymo/Dymo

2008-07-02 Thread fhg07
Thanks to your help, I was capable of fixing some problems which I
previously had, regarding changes that ocurred in some interfaces.
But leaving that aside, I still get some error messages which reasons
I cannot understand.

"[EMAIL PROTECTED]:/opt/tinyos2/tinyos-2.x-src/apps/MHBaseStation$ make mica2
mkdir -p build/mica2
compiling TymaBaseAppC to a mica2 binary
ncc -o build/mica2/main.exe  -Os -I../../tos/lib/net/dymo
-I../../tos/lib/net/multihop -I../tymaluate/monitor/ -I../tymaluate/sense/
-Wall -Wshadow -Wnesc-all -target=mica2 -fnesc-cfile=build/mica2/app.c
-board=micasb -DDEFINED_TOS_AM_GROUP=0x22 -finline-limit=10
-DIDENT_PROGRAM_NAME=\"TymaBaseAppC\" -DIDENT_USER_ID=\"fernando\"
-DIDENT_HOSTNAME=\"baco.inf.ufpr.b\" -DIDENT_USER_HASH=0x92905e1aL
-DIDENT_UNIX_TIME=0x486b83d3L -DIDENT_UID_HASH=0x61734aefL
-fnesc-dump=wiring -fnesc-dump='interfaces(!abstract())'
-fnesc-dump='referenced(interfacedefs, components)'
-fnesc-dumpfile=build/mica2/wiring-check.xml TymaBaseAppC.nc -lm
../tymaluate/monitor/MonitorM.nc:1:26: dymo_routing.h: No such file or
directory
In file included from TymaBaseAppC.nc:11:
In component `MonitorC':
MonitorC.nc:5: failed to preprocess ../tymaluate/monitor/MonitorM.nc
MonitorC.nc:5: component DymoNetworkC not found
MonitorC.nc:8: cannot find `Leds'
MonitorC.nc:9: cannot find `Read'
MonitorC.nc:10: cannot find `SplitControl'
MonitorC.nc:11: cannot find `DymoMonitor'
MonitorC.nc:12: cannot find `RoutingTableInfo'
MonitorC.nc:18: cannot find `Receive'
MonitorC.nc:19: cannot find `MHSend'
MonitorC.nc:20: cannot find `Intercept'
MonitorC.nc:22: cannot find `MHPacket'
In component `BaseStationC':
BaseStationC.nc:77: cannot find `SplitControl'
BaseStationC.nc:87: cannot find `MHSend'
BaseStationC.nc:88: cannot find `Receive'
BaseStationC.nc:89: cannot find `Receive'
BaseStationC.nc:90: cannot find `MHPacket'
BaseStationC.nc:96: cannot find `Packet'
BaseStationC.nc:97: cannot find `MHPacket'
make: *** [exe0] Error 1"

How come these interfaces cannot be found if they clearly are in my
tos/interfaces/ directory?




Thx,
Fernando.

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


Re: [Tinyos-help] tinyos,matlab

2008-07-02 Thread Eric Keller
Maybe you could rebuild the jar file?

On Mon, May 26, 2008 at 11:56 PM, alka gautam <[EMAIL PROTECTED]> wrote:
> Hi,
>
>
>
> I've been trying for days to get the Matlab->Java->SerialForwarder interface
>
> to work.  I get the following error when I try to compile
>
> MatlabControl.java.
>
> MatlabContrl.java:39: cannot access com.mathworks.jmi.Matlab
>
> bad class file:
> C:\PROGRAM~1\UCB\cygwin\opt\tinyos-1.x\tools\java\jars\jmi.jar
>
> class file has wrong version 49.0,should be 48.0
>
> please remove or make sure it appears in the correct subdirectory of the
> classpath
>
> Matlab matlab = null;// this is the com.mathworks.jmi.Matlab class,which has
>
>  functionality allowing one to  interact with the matlab session.
>
>^
>
> 1 error
>
>
>
> This looks to me like it's a problem with the java code, not my environment
>
> or setup.  If that's the case then someone else must have run into this
>
> problem.  Please help!!
>
>
>
> Thanks,
>
>
>
> Alka gautam
>
>
>
>
>
>
>
> ___
> 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


Re: [Tinyos-help] about Broadcast component in tinyos2.x

2008-07-02 Thread jiwen zhang
Hello :
   that is to say Dissemination is a substitutor of Broadcast in tinyos1.x ?


  i have spend some time researching the Dissemination , i have a question
:

  in my opinion , once the Disseminator disseminate a data , it will
increase the sequence number , for example , if the disseminator's nodeid is
0, after two times's disseminations , the the sequence number should be
0x0002 , so the whole network maintains the same sequence number
(assuming there is only one disseminator), and at this time the disseminator
is rebooted for some reason , so the sequence number is reset to zero , so
when it disseminates new datas to the network , the other nodes maybe
discard the new data . how does the Dissemination resolve the problem ?

  thank you !!
2008/7/2 Omprakash Gnawali <[EMAIL PROTECTED]>:

> On Wed, Jul 2, 2008 at 12:51 AM, jiwen zhang <[EMAIL PROTECTED]>
> wrote:
> >
> > Hello David :
> >
> > I see there is Broadcast component in tinyos1.x in tos\lib\Broadcast,
> > is there the similar component in tinyos2.x ? i want to use it , but i
> don't
> > find . why is it taken out ?
> >
>
> You should look into Dissemination.
>
> - om_p
>



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

[Tinyos-help] Strange Ranges of Random Backoff Delays

2008-07-02 Thread Anton
Hello!

There is something in the 
/tinyos-2.x/tos/chips/cc2420/csma/CC2420CsmaP.nc (lines 218 and 225), 
which I don't understand.

Communicating wireless modules should wait some random delay before 
performing Clear Channel Assess.
According to the IEEE 802.15.4 standard, that delay should be   
random(2^BE-1)   backoff periods, where BE can vary from 3 to 5 (the 
default values macMinBE and macMaxBE, IEEE 802.15.4-2006, pages 
163-164). This means that for CC2420 the maximum backoff delay is 31*320 
= 9920 microseconds (when BE=5), and the maximum initial backoff delay 
is 7*320 = 2240 microseconds (since initially BE=3).

But according to CC2420CsmaP.nc file the maximum initial backoff delay 
can be around 9765 microseconds (line 218) and maximum congestion 
backoff delay can be around 2441 microseconds (line 225). So, the range 
of congestion backoff delay is shorter than that of initial backoff delay.


Of course, if BE (mentioned in the standard) is initially set to 5, the 
range of the initial backoff delay should be 9920 microseconds. But in 
such a case, all subsequent congestion backoff delays which might happen 
should take on some value within the same range (according to standard 
CSMA-CA algorithm).

Could anybody explain it?

Thanks.

Anton.

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


[Tinyos-help] TestNetwork scripts for parsing debug messages

2008-07-02 Thread Gaurav Chandwani
Hi,

I have installed TestNetwork on many telosb motes(am using  2.0.2 release).
Where can I find the scripts to parse the debug messages sent by
these nodes ?
In the readme on CVS, its written that they should be available on net2 website,
but am unable to open it ?
I believe test.py is just a simulation script or it has any relevance
in parsing ?

Best Regards,
GC



-- 
-
To accomplish great things, we must not only act, but also dream; not
only plan, but also believe.
 - Anatole France
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


Re: [Tinyos-help] a question about TYMO protocol

2008-07-02 Thread Romain Thouvenin
See my first response:

I think it is because you need to create the StorageVolumes.h file in
the RadioSenseToLeds directory.
You can have a look at the storage tutorial to know what this is
about, and look in apps/tests/TestTymo/StorageVolumes.h to have
correct values

Moreover, make sure you use the latest TinyOS CVS code, NOT the code
from the tymo project of sourceforge.

Hope this helps,
Romain

On Wed, Jun 18, 2008 at 1:53 PM, mohammed tarek
<[EMAIL PROTECTED]> wrote:
> hiii
> I am working on my graduate project which is distributed control system
> using wireless network and I am using TYMO protocol to implement a network
> layer in my project and I have used the dymo library and I followed the
> instructions in the lesson associated with this toppic but when I build the
> program the following message appears
>
> Setting up for TinyOS 2.x
>
> [EMAIL PROTECTED]:/opt/tinyos-2.x/apps/smarthouse/RadioSenseToLeds$
> make telosb
>
> mkdir -p build/telosb
>
> compiling RadioSenseToLedsAppC to a telosb binary
>
> ncc -o build/telosb/main.exe -Os -O -mdisable-hwmul -Wall -Wshadow
> -DDEF_TOS_AM_GROUP=0x7d -Wnesc-all -target=telosb
> -fnesc-cfile=build/telosb/app.c -board= -I/opt/tinyos-2.x/tos/lib/net
> -I/opt/tinyos-2.x/tos/lib/net/dymo -I/opt/tinyos-2.x/tos/lib/net/le
> -I/opt/tinyos-2.x/tos/lib/net/ctp -DIDENT_PROGRAM_NAME=\"RadioSenseToLed\"
> -DIDENT_USER_ID=\"mohammed\" -DIDENT_HOSTNAME=\"mohammed-laptop\"
> -DIDENT_USER_HASH=0x7476a828L -DIDENT_UNIX_TIME=0x4858f591L
> -DIDENT_UID_HASH=0xe8e1896aL RadioSenseToLedsAppC.nc -lm
>
> In file included from RadioSenseToLedsAppC.nc:55
>
> :
>
> In component `RadioSenseToLedsC
>
> ':
>
> RadioSenseToLedsC.nc: In function `Boot.booted
>
> ':
>
> RadioSenseToLedsC.nc:71: parameters missing in call to parameterised command
> or event
>
> RadioSenseToLedsC.nc: At top level
>
> :
>
> RadioSenseToLedsC.nc:81: conflicting types for `SplitControl.startDone
>
> '
>
> /
>
> opt/tinyos-2.x/tos/interfaces/SplitControl.nc:92: previous declaration of
> `SplitControl.startDone'
>
> RadioSenseToLedsC.nc:87: conflicting types for `SplitControl.stopDone
>
> '
>
> /
>
> opt/tinyos-2.x/tos/interfaces/SplitControl.nc:117: previous declaration of
> `SplitControl.stopDone'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:26:33: warning: extra tokens at
> end of #ifdef directive
>
> In file included from RadioSenseToLedsAppC.nc:56
>
> :
>
> In component `DymoNetworkC
>
> ':
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:32: interface MHControl not found
>
> In file included from RadioSenseToLedsAppC.nc:56
>
> :
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:39: component MHServiceC not
> found
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoServiceC.nc:6:28: StorageVolumes.h: No such
> file or directory
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:39: failed to preprocess
> /opt/tinyos-2.x/tos/lib/net/DymoServiceC.nc
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:48: cannot find `MHSend'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:49: cannot find `Receive'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:51: cannot find `MHPacket'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:52: cannot find `Packet'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:53: cannot find `Intercept'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:64: cannot find `AMPacket'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:65: cannot find `SubPacket'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:66: cannot find `AMSend'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:67: cannot find `SubReceive'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:68: cannot find `Acks'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:70: cannot find `AMPacket'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:71: cannot find `Packet'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:72: cannot find `AMSend'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:73: cannot find `Receive'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:75: cannot find `LinkMonitor'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:80: cannot find `SplitControl'
>
> /
>
> opt/tinyos-2.x/tos/lib/net/DymoNetworkC.nc:86: cannot find `MHControl'
>
> In component `RadioSenseToLedsAppC
>
> ':
>
> RadioSenseToLedsAppC.nc:63: no match
>
> make: *** [exe0] Error 1
>
> ___
> 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


[Tinyos-help] Finding the energy of the mote in tinyos - telosb motes

2008-07-02 Thread John Paul
Hi,
I am working on a routing scheme in tinyos that takes into account the
energy of the mote. Can anyone please tell me whether there is any way to
measure the energy of the mote. I am currently working on telosb motes.

Help appreciated.

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

Re: [Tinyos-help] Tymo/Dymo

2008-07-02 Thread Romain Thouvenin
On Wed, Jul 2, 2008 at 3:39 PM,  <[EMAIL PROTECTED]> wrote:
> Thanks to your help, I was capable of fixing some problems which I
> previously had, regarding changes that ocurred in some interfaces.
> But leaving that aside, I still get some error messages which reasons
> I cannot understand.

[...]

> ../tymaluate/monitor/MonitorM.nc:1:26: dymo_routing.h: No such file or
> directory

[...]

Is the dymo_routing.h file present in your source tree too?

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


Re: [Tinyos-help] Differential Analog Channels on MDA320 with TinyOS 1

2008-07-02 Thread Christopher Leung
Hi Tom,

Change lines 170-200 in XMDA320M.nc. I think you just have to change the
first parameter in the function Sample.getSample(...) to the number
corresponding to the differential channels. That's about all I can say
without trying to understand the messy code in MDA320 driver folder.

Chris

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Lutz,
Thomas D
Sent: June 6, 2008 3:24 PM
To: tinyos-help@millennium.berkeley.edu
Subject: [Tinyos-help] Differential Analog Channels

I'm using an MDA320 on an iris mote. I want to be able to use the
differential channels to read data from a sensor. Does anyone know what
changes must be made to the XMDA320M.nc (and subsequent files) in order
to enable and read the differential channels?


Thanks for your help,

Tom Lutz
University of Kentucky
[EMAIL PROTECTED]


___
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


Re: [Tinyos-help] Problem with tinyos.jar

2008-07-02 Thread Paul Stickney
I believe jar requires the -f flag to read from a file.

On Wed, Jul 2, 2008 at 12:59 AM, Anirudh Sivaraman <[EMAIL PROTECTED]> wrote:
> Hi
>
> The file exists and I have been able to find it. However on the jar
> command ie sudo jar -x ./tinyos.jar I do not get any output. The shell
> keeps me waiting indefinitely. The same thing happens with -t also. I
> installed the tinyos distribution from the stanford repository. Is it
> necessary to install java SDK separately cause the instructions did
> not say so.
>
> Regards
> ANirudh
>
> On Wed, Jul 2, 2008 at 12:36 PM, Paul Stickney <[EMAIL PROTECTED]> wrote:
>> Odd.
>> What happens when you try to access the jar directly (via the jar command)?
>> Is it somehow corrupt? Really strange permissions? Non existant?
>>
>> On Sun, Jun 29, 2008 at 11:34 PM, Anirudh Sivaraman
>> <[EMAIL PROTECTED]> wrote:
>>> Hi
>>>
>>> I tried to compile the application TestSerial in
>>> TOSROOT/apps/test/TestSerial using the make micaz command. I get the
>>> following error:
>>
>>> " error reading /opt/tinyos-2.x/support/sdk/java/tinyos.jar; error in
>>> opening zip file"
>>>
>>> Can anybody help me out with this?
>>>
>>> Regards
>>> Anirudh
>>> ___
>>> 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
>>
>
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


Re: [Tinyos-help] Question about nx_structs in C

2008-07-02 Thread Philip Levis

On May 27, 2008, at 12:27 PM, Ashik Manandhar wrote:

> Hi,
>
> I am currently using TinyOS 1.1, and am using the serial forwarder  
> program to forward messages from my motes to a specific C file.  I  
> want get data from these messages since they are a known message  
> type, but I don't know how to incorporate this nx_struct into my C  
> code.  Does anyone know how to this, or if there is another dynamic  
> way to do this?

Please read the TinyOS programming manual. While a lot of the  
component stuff is for T2, the nx_struct text should be helpful for 1.x.

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


[Tinyos-help] Problem in printf library

2008-07-02 Thread Shikhar Sachan
Hello Users,

I had been using the printf library and the printfs worked absolutely
fine ... however ... after I changed the default msg size from 28
bytes to 42 bytes (TOSH_DATA_LENGTH 28) my printfs have started
giving me problems ... I have no idea why this is happening.
The printing skips some characters.  I donot how changing length of
messages could affect printfs. I hope I am able to find a solution.

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


Re: [Tinyos-help] tinyos,matlab

2008-07-02 Thread Philip Levis

On May 26, 2008, at 8:56 PM, alka gautam wrote:

> Hi,
>
>
> I've been trying for days to get the Matlab->Java->SerialForwarder  
> interface
>
> to work.  I get the following error when I try to compile
>
> MatlabControl.java.
>
> MatlabContrl.java:39: cannot access com.mathworks.jmi.Matlab
>
> bad class file: C:\PROGRAM~1\UCB\cygwin\opt\tinyos-1.x\tools\java 
> \jars\jmi.jar
>
> class file has wrong version 49.0,should be 48.0
>
> please remove or make sure it appears in the correct subdirectory of  
> the classpath
>
> Matlab matlab = null;// this is the com.mathworks.jmi.Matlab  
> class,which has
>
>
>  functionality allowing one to  interact with the matlab session.
>
>^
> 1 error
>
>
> This looks to me like it's a problem with the java code, not my  
> environment
>
> or setup.  If that's the case then someone else must have run into  
> this
>
> problem.  Please help!!
>
>

You're using an older version of Java. Try updating to a newer Java.

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


Re: [Tinyos-help] Random Backoff Delays in TinyOS 2.x Channel Access

2008-07-02 Thread Philip Levis

On Jun 12, 2008, at 12:29 PM, Anton wrote:

> Hello!
>
> There is probable bug in the
> /tinyos-2.x/tos/chips/cc2420/csma/CC2420CsmaP.nc (lines 218 and 225)
>
> Communicating wireless modules should wait some random delay before
> performing Clear Channel Assess.
> According to the IEEE 802.15.4 standard, that delay should be
> random(2^BE-1)   backoff periods, where BE can vary from 3 to 5 (the
> default values macMinBE and macMaxBE, IEEE 802.15.4-2006, pages
> 163-164). This means that for CC2420 the maximum backoff delay is  
> 31*320
> = 9920 microseconds (when BE=5), and the maximum initial backoff delay
> is 7*320 = 2240 microseconds (since initially BE=3).
>
> But according to CC2420CsmaP.nc file the maximum initial backoff delay
> can be around 9765 microseconds (line 218) and maximum congestion
> backoff delay can be around 2441 microseconds (line 225).
> It seems that the ranges of these random delays are swapped. Even in
> TinyOS 1.x the range of the initial delay is smaller than that of
> congestion backoff delay
> (/tinyos-1.x/tos/lib/CC2420Radio/CC2420RadioM.nc, lines 745 and  
> 752). In
> TinyOS 2.x this is conversely.
>
> Also, according to the standard the range of the random delay should
> expand (by default BE should change from 3 to 5) each time the channel
> is sensed busy (CSMA/CA algorithm - page 172 of the standard). But the
> range of all random delays is constant both in TinyOS 1.x and TinyOS  
> 2.x.
>
> Please, tell whether it is bug or not.

No, it is not a bug. TinyOS does not have an 802.15.4 MAC.

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


Re: [Tinyos-help] Random Backoff Delays in TinyOS 2.x Channel Access

2008-07-02 Thread Anton
Thanks for the reply,

but why the range of the congestion delay is shorter than that of 
initial delay?
Isn't it natural to increase the range of backoff delays when the 
channel is not clear?


Philip Levis wrote:
>
> On Jun 12, 2008, at 12:29 PM, Anton wrote:
>
>> Hello!
>>
>> There is probable bug in the
>> /tinyos-2.x/tos/chips/cc2420/csma/CC2420CsmaP.nc (lines 218 and 225)
>>
>> Communicating wireless modules should wait some random delay before
>> performing Clear Channel Assess.
>> According to the IEEE 802.15.4 standard, that delay should be
>> random(2^BE-1)   backoff periods, where BE can vary from 3 to 5 (the
>> default values macMinBE and macMaxBE, IEEE 802.15.4-2006, pages
>> 163-164). This means that for CC2420 the maximum backoff delay is 31*320
>> = 9920 microseconds (when BE=5), and the maximum initial backoff delay
>> is 7*320 = 2240 microseconds (since initially BE=3).
>>
>> But according to CC2420CsmaP.nc file the maximum initial backoff delay
>> can be around 9765 microseconds (line 218) and maximum congestion
>> backoff delay can be around 2441 microseconds (line 225).
>> It seems that the ranges of these random delays are swapped. Even in
>> TinyOS 1.x the range of the initial delay is smaller than that of
>> congestion backoff delay
>> (/tinyos-1.x/tos/lib/CC2420Radio/CC2420RadioM.nc, lines 745 and 752). In
>> TinyOS 2.x this is conversely.
>>
>> Also, according to the standard the range of the random delay should
>> expand (by default BE should change from 3 to 5) each time the channel
>> is sensed busy (CSMA/CA algorithm - page 172 of the standard). But the
>> range of all random delays is constant both in TinyOS 1.x and TinyOS 
>> 2.x.
>>
>> Please, tell whether it is bug or not.
>
> No, it is not a bug. TinyOS does not have an 802.15.4 MAC.
>
> Phil


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


Re: [Tinyos-help] Random Backoff Delays in TinyOS 2.x Channel Access

2008-07-02 Thread Philip Levis

On Jul 2, 2008, at 10:12 AM, Anton wrote:

> Thanks for the reply,
>
> but why the range of the congestion delay is shorter than that of  
> initial delay?
> Isn't it natural to increase the range of backoff delays when the  
> channel is not clear?
>

That leads to the capture effect.

Phil

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


Re: [Tinyos-help] Problem in printf library

2008-07-02 Thread Kevin Klues
If you are printing stuff out in quick succession, it may be due to
the fact that the 'old' printf library will fail any attempt to print
characters while in the middle of flushing out a message.  With loner
messages this takes more time, and it is therefore more likely that
characters may be lost.  The newest version of printf (i.e. the one in
the cvs HEAD doesn't have this problem anymore).

Kevin

On Wed, Jul 2, 2008 at 9:28 AM, Shikhar Sachan <[EMAIL PROTECTED]> wrote:
> Hello Users,
>
> I had been using the printf library and the printfs worked absolutely
> fine ... however ... after I changed the default msg size from 28
> bytes to 42 bytes (TOSH_DATA_LENGTH 28) my printfs have started
> giving me problems ... I have no idea why this is happening.
> The printing skips some characters.  I donot how changing length of
> messages could affect printfs. I hope I am able to find a solution.
>
> Shikhar
> ___
> Tinyos-help mailing list
> Tinyos-help@millennium.berkeley.edu
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>



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


[Tinyos-help] Timers in Telosb

2008-07-02 Thread John Paul
Hi,
The command startPeriodicAt is not working properly in Telosb motes

command void startPeriodicAt( uint32_t t0, uint32_t dt );


While startPeriodic is working. Could anyone please tell me what could be
the problem.


command void startPeriodic( uint32_t dt )

Help Appreciated


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

[Tinyos-help] basic radio communication

2008-07-02 Thread Florentin vf

Hi,
 
I'm using tinyos 1.x with the Cricket system, and I want to send a radio 
message from one mote to another. I only need to send one decimal digit, but I 
am having problems. I've tried going through the radio tutorials but don't 
understand them. I've also tried imitating the format of other messages that 
are being sent in the Cricket code, to no avail. 
 
All I need to do is make it so that, when prompted through the serial input 
with "P BE %d" the radio sends %d to another mote, which acts on it. Here are 
some examples of what I am trying:
 
 
else if (!strncmp("BE", pos+2, 2)) { 
//**
beacon_calldata->x = atoi(pos+4);
beacon_calldata->y = 0;
beacon_calldata->z = 0;
beacon_calldata->temp = 0;
beacon_calldata->tb = FALSE;

call RadioControl.start();
TOSH_uwait(2000); 
call RadioSend.send(&beacon_call);


  }
 
 
 
 
  event TOS_MsgPtr RadioReceive.receive(TOS_MsgPtr data) {
uint8_t i;
 
int result = 0;
int count = 0;
//uint16_t FailedAttemptComp;
//char OutputMsg[128];
 
 
else if (CricketConfig.run_mode == MODE_BEACON){

struct CricketBeacon * beac = (struct CricketBeacon *)data->data;

call Leds.greenToggle();  

if(beac->x == '4')
  {call Leds.redToggle();}
  
  
if (beac->x ==(int)(CricketConfig.spaceid[6]-48))   
//***
{
  call RadioControl.start();
  TOSH_uwait(2000);
 
  if (CricketConfig.run_mode == MODE_BEACON) 
  {
while ( count < CricketConfig.max_beacon_number - 1)
{
  atomic 
  {
ReadyToSend = 0;
  }
  if (ReadyToSend == 0) 
  {
// Send 
the  //location
if (CricketConfig.use_temp_sensor) 
{beacondata->temp = 
CricketConfig.local_temp;}
 
beacondata->tb = readTestSwitch();
result = call RadioSend.send(&beaconmsg);   
  
if (result == SUCCESS)
{
  break;
}
  }
  count++;
}
  }

  

}
 
//return SUCCESS;
  }

return data;
  }

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

Re: [Tinyos-help] Timers in Telosb

2008-07-02 Thread Philip Levis

On Jul 2, 2008, at 12:10 PM, John Paul wrote:

> Hi,
> The command startPeriodicAt is not working properly in Telosb motes
> command void startPeriodicAt( uint32_t t0, uint32_t dt );
>
> While startPeriodic is working. Could anyone please tell me what  
> could be the problem.
>
> command void startPeriodic( uint32_t dt )
>
> Help Appreciated

Please describe the problem in more detail. "Not working properly" is  
hard to work with. E.g., send an example simple app to the list where  
timers don't do what they are supposed to.

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


[Tinyos-help] change TelosB Radio range

2008-07-02 Thread Mr Meddage Saliya Ranal Fernando
Dear all,

I’m new to TinyOS, can you please let me know how to change the radio 
power in a TelosB mote? Can that be done when i'm injecting the program 
to the mote or have I got to do it in a particular file?


Thank you,

Saliya


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

Re: [Tinyos-help] Initializing an nx_struct

2008-07-02 Thread Eric Decker
A nx_struct is actually defined as a structure of byte arrays.

So you would need something like

subscriber_t sub[{1}, {2}};

that is what is going on.

eric


On Fri, Jun 27, 2008 at 2:55 AM, Symon Vezina <
[EMAIL PROTECTED]> wrote:

> Hi,
>
> I'm trying to initialize an nx_struct like follows:
>
>typedef nx_struct subscriber {
>nx_uint8_t taskId;
>nx_uint8_t eventId;
>} subscriber_t;
>
>subscriber_t sub = {1,2};
>
> but the compiler keeps giving me theses warnings:
>
> source/TestListP.nc:30: warning: missing braces around initializer
> source/TestListP.nc:30: warning: (near initialization for `sub.taskId')
>
>
> The initialization doesn't generate warnings if I take away the "nx_"
> prefix keyword from the whole structure.
>
> Thanks,
> Symon.
> ___
> 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
Autonomous Systems Lab
Jack Baskin School of Engineering
UCSC
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] mica2 simulation

2008-07-02 Thread Bina Basnet
We are using mica2 for our experiment. Can somebody plz give me some
suggestion on what might be the best option to simulate it.
Tinyos 2 tossim doesn't support mica2, so can we make some easy changes so
that it works for mica2 or go for tiyos 1.

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

[Tinyos-help] How to get the transmission power of the received Packet

2008-07-02 Thread John Paul
hi ,

Iam working on telosb motes. Can anyone please tell me how to get the
transmission power of the received packet.

Help appreciated.

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

Re: [Tinyos-help] How to get the transmission power of the received Packet

2008-07-02 Thread Nilesh Mishra
I think you will have to put this information somewhere in the data field of
the packet. The RSSI measured at receiver is receiver's signal strength and
different senders (at different power levels) can give same RSSI value
depending on environment and other parameters, hence you will have to
include the transmission power in the data at the time of transmission.

Regards
Nilesh

Nilesh Mishra
Embedded Networks Laboratory
University of Southern California,
3710 S. McClintock Avenue, Ronald Tutor Hall (RTH) 418
Los Angeles, CA 90089
mail: [EMAIL PROTECTED]
[EMAIL PROTECTED]
[EMAIL PROTECTED]
ph: (213) 821-5627 (lab)

On Wed, Jul 2, 2008 at 5:23 PM, John Paul <[EMAIL PROTECTED]> wrote:

> hi ,
>
> Iam working on telosb motes. Can anyone please tell me how to get the
> transmission power of the received packet.
>
> Help appreciated.
>
> Regards,
> john Pau
>
> ___
> 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

[Tinyos-help] delay measurement in multihop network

2008-07-02 Thread Poonam Hiwal
Hi ,

I am working with Multihop routing protocol and now I have to measure delay.
I am running this on tinyos1.x and telos motes. I am finding difficulty in
making the network because the lab size is small and I am not able to make
network more than 2 hops.
I am keeping radio power level at 5.
Any help in solving this issue will be highly appreciable.

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

[Tinyos-help] Uart0 Serial Stack as Default Owner of Arbiter

2008-07-02 Thread Kirak, Hong
Hi, guys,

 

I am struggling with some resource arbitration problem with CC2420 and
UART0.

 

What I want to do is, making  UART0 serial stack as a default owner of USART
bus.

 

But it looks like it is not enough that I just connect default owner
interface to serial stack because it seems like it checks resource id.

 

Is there any way to use original serial stack as a default owner?

 

Thanks,

Kirak

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

[Tinyos-help] help installing tinyos on Mac OS X

2008-07-02 Thread João Paulo Amaro da Costa Luz Carneiro
Hi,
Following Kevin Klues' TinyOs 2.x installation on Mac OS X (Leopard)  
tutorial, when trying to install the tinyos toolset 
(http://docs.tinyos.net/index.php/Installing_tinyos-2.x_on_Mac_OS_X_(Tiger)#Installing_the_tinyos-2.x_toolset
 
) I get the following:

Making all in platforms
Making all in mica
Making all in cc1000-channelgen
gcc -DPACKAGE_NAME=\"tinyos-tools\" -DPACKAGE_TARNAME=\"tinyos-tools\"  
-DPACKAGE_VERSION=\"1.2.4\" -DPACKAGE_STRING=\"tinyos-tools\ 1.2.4\" - 
DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"tinyos-tools\" -DVERSION=\"1.2.4\"  
-I. -g -O2 -MT tos-channelgen.o -MD -MP -MF .deps/tos- 
channelgen.Tpo -c -o tos-channelgen.o tos-channelgen.c
mv -f .deps/tos-channelgen.Tpo .deps/tos-channelgen.Po
gcc  -g -O2   -o tos-channelgen tos-channelgen.o
Making all in uisp
Making all in src
make  all-am
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT Avr.o -MD -MP -MF .deps/ 
Avr.Tpo -c -o Avr.o Avr.C
mv -f .deps/Avr.Tpo .deps/Avr.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT AvrAtmel.o -MD -MP - 
MF .deps/AvrAtmel.Tpo -c -o AvrAtmel.o AvrAtmel.C
mv -f .deps/AvrAtmel.Tpo .deps/AvrAtmel.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT AvrDummy.o -MD -MP - 
MF .deps/AvrDummy.Tpo -c -o AvrDummy.o AvrDummy.C
mv -f .deps/AvrDummy.Tpo .deps/AvrDummy.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT AvrStargate.o -MD -MP - 
MF .deps/AvrStargate.Tpo -c -o AvrStargate.o AvrStargate.C
mv -f .deps/AvrStargate.Tpo .deps/AvrStargate.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT DAPA.o -MD -MP -MF .deps/ 
DAPA.Tpo -c -o DAPA.o DAPA.C
mv -f .deps/DAPA.Tpo .deps/DAPA.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT Main.o -MD -MP -MF .deps/ 
Main.Tpo -c -o Main.o Main.C
mv -f .deps/Main.Tpo .deps/Main.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT MotIntl.o -MD -MP - 
MF .deps/MotIntl.Tpo -c -o MotIntl.o MotIntl.C
mv -f .deps/MotIntl.Tpo .deps/MotIntl.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT SASA.o -MD -MP -MF .deps/ 
SASA.Tpo -c -o SASA.o SASA.C
mv -f .deps/SASA.Tpo .deps/SASA.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT Serial.o -MD -MP -MF .deps/ 
Serial.Tpo -c -o Serial.o Serial.C
mv -f .deps/Serial.Tpo .deps/Serial.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT Stk500.o -MD -MP -MF .deps/ 
Stk500.Tpo -c -o Stk500.o Stk500.C
mv -f .deps/Stk500.Tpo .deps/Stk500.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT Terminal.o -MD -MP - 
MF .deps/Terminal.Tpo -c -o Terminal.o Terminal.C
mv -f .deps/Terminal.Tpo .deps/Terminal.Po
g++ -DHAVE_CONFIG_H -I.-Wall -g -O2 -MT cygwinp.o -MD -MP - 
MF .deps/cygwinp.Tpo -c -o cygwinp.o cygwinp.C
mv -f .deps/cygwinp.Tpo .deps/cygwinp.Po
g++ -Wall -g -O2   -o uisp Avr.o AvrAtmel.o AvrDummy.o AvrStargate.o  
DAPA.o Main.o MotIntl.o SASA.o Serial.o Stk500.o Terminal.o cygwinp.o
make[4]: Nothing to be done for `all-am'.
make[3]: Nothing to be done for `all-am'.
Making all in msp430
Making all in motelist
make[3]: Nothing to be done for `all'.
Making all in pybsl
Making all in serial
make[4]: Nothing to be done for `all'.
make[4]: Nothing to be done for `all-am'.
make[3]: Nothing to be done for `all-am'.
make[2]: Nothing to be done for `all-am'.
Making all in tinyos
Making all in java
Making all in env
gcc "-I/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/ 
Headers" -bundle -fPIC net_tinyos_util_Env.c -o libgetenv.jnilib
Making all in serial
g++ -O2 -bundle "-I/System/Library/Frameworks/JavaVM.framework/ 
Versions/CurrentJDK/Headers" \
 -o libtoscomm.jnilib NativeSerial_darwin.cpp
make[3]: Nothing to be done for `all-am'.
Making all in misc
gcc -DPACKAGE_NAME=\"tinyos-tools\" -DPACKAGE_TARNAME=\"tinyos-tools\"  
-DPACKAGE_VERSION=\"1.2.4\" -DPACKAGE_STRING=\"tinyos-tools\ 1.2.4\" - 
DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"tinyos-tools\" -DVERSION=\"1.2.4\"  
-I. -g -O2 -MT tos-serial-debug.o -MD -MP -MF .deps/tos-serial- 
debug.Tpo -c -o tos-serial-debug.o tos-serial-debug.c
mv -f .deps/tos-serial-debug.Tpo .deps/tos-serial-debug.Po
gcc  -g -O2   -o tos-serial-debug tos-serial-debug.o
Making all in ncc
Making all in nesdoc-py
make[3]: Nothing to be done for `all'.
make[3]: Nothing to be done for `all-am'.
Making all in tosthreads
make[2]: Nothing to be done for `all'.
Making all in safe
make[2]: Nothing to be done for `all'.
make[2]: Nothing to be done for `all-am'.
make[1]: Nothing to be done for `all-am'.

Can someone please help me solving this problem?
Thanks in advance,

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


Re: [Tinyos-help] Dear Sir, need help in programming Micaz

2008-07-02 Thread Giri Baleri
Hello David,
 
Yes, you can install MoteWorks on WinXP OS.
You can not edit the binary files included in MoteView. Instead, you
will need to edit the application source code available under MoteWorks
(eg. \opt\MoteWorks\apps\xmesh\XMDA320).
 
Attached is an outline of steps involved in reading the counter channel
(Courtesy: Ian McCulley @ DPI).
 
I hope that helps,
Giri
 



From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of zhia
howe chong
Sent: Friday, June 06, 2008 7:21 PM
To: tinyos-help@millennium.berkeley.edu
Subject: [Tinyos-help] Dear Sir, need help in programming Micaz


HI Sir,
 
I am a beginner in this micaz and mda320 devices. So far, i have
acquired 4 micaz motes and 4 mda320 platform from my supervisor. Now, my
task is to setup a WSN, where each of the motes will take data for
different readings and different places, and whicn be setup easily. 
 
I have done the first part by just connecting sensor to AD0 port, and
the reading of the data will be displayed in VOLTAGE in Moteview. I have
done some conversion of the reading through formula provided by the
sensor vendors. 
 
Next, my project critical part is this. I have to program the motes so
tat one of the mote, which connects to the mda320, will do counter
purpose. Let say, i connect a rain gauge to that platform, so for every
10 drops of rain, the MDA320 will count the number of rain drops. So,
let say my Mote 2 to Mote 4 are taking data for the temperature at an
interval of 30 minutes, after 10 drops of rain, the Motes will reduce
the interval time to 20 minutes in data recording. When there are even
more frequent of rain drops, the interval time for Mote 2  to Mote 4
will change to 10 minutes of interval time to take reading. How can i
achieve this objective?
 
Can i use Motework in WIndow XP? How can i edit the binary files using
TinyOS? 
 
Can sir lead me to this in a step-by-step manner? i would appreciate it
a lot. 
 
Best Regards,
David Chong
Petronas University of Technology
Malaysia


Implementing Counters on XMDA300.doc
Description: Implementing Counters on XMDA300.doc
___
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Re Serial Baudrate

2008-07-02 Thread Varun Jain
By 'differently', I am referring to the code at /tools/tinyos/java/serial
à here we can see two files, namely NativeSerial_win32 AND 
NativeSerial_linux 

 

For Windows (Cygwin) machines, I believe it gets the code for Baudrate from In 
NativeSerial_win32 as below: 

 

int getBaudRate()

  {

int baud_rate = get_comm_state().BaudRate;

switch( baud_rate )

{

  case CBR_110:return 110;

  case CBR_300:return 300;

  case CBR_600:return 600;

  case CBR_1200:   return 1200;

  case CBR_2400:   return 2400;

  case CBR_4800:   return 4800;

  case CBR_9600:   return 9600;

  case CBR_14400:  return 14400;

  case CBR_19200:  return 19200;

  case CBR_38400:  return 38400;

  case CBR_56000:  return 56000;

  case CBR_57600:  return 57600;

  case CBR_115200: return 115200;

  case CBR_128000: return 128000;

  case CBR_256000: return 256000;

}

return baud_rate;

  }

 

AND IN Linux machines, we get Baudrates from  NativeSerial_linux file as below:

int baud_to_enum( int baud )

  {

switch( baud )

{

  case 0: return B0;

  case 50: return B50;

  case 75: return B75;

  case 110: return B110;

  case 134: return B134;

  case 150: return B150;

  case 200: return B200;

  case 300: return B300;

  case 600: return B600;

  case 1200: return B1200;

  case 1800: return B1800;

  case 2400: return B2400;

  case 4800: return B4800;

  case 9600: return B9600;

  case 19200: return B19200;

  case 38400: return B38400;

  case 57600: return B57600;

  case 115200: return B115200;

  case 230400: return B230400;

}

throw comm_port_error("baud_to_enum, bad baud rate");

  }

 

  int enum_to_baud( int baudenum )

  {

switch( baudenum )

{

  case B0: return 0;

  case B50: return 50;

  case B75: return 75;

  case B110: return 110;

  case B134: return 134;

  case B150: return 150;

  case B200: return 200;

  case B300: return 300;

  case B600: return 600;

  case B1200: return 1200;

  case B1800: return 1800;

  case B2400: return 2400;

  case B4800: return 4800;

  case B9600: return 9600;

  case B19200: return 19200;

  case B38400: return 38400;

  case B57600: return 57600;

  case B115200: return 115200;

  case B230400: return 230400;

}

throw comm_port_error("enum_to_baud, bad baud rate");

  }

 

All my discussion is based on my belief that when we use Java tools like 
"Listen, MsgReader, etc.", these files are used... if not then I am wrong  but 
if I am right, then we can see that after the baudrate of 115200bps, Linux 
machines can  have only 230400bps whereas Windows can have 128000 and 256000bps.

 

Secondly, my problem is that my platform has an atmel atmega128 processor, and 
all the platforms  having this processor can either have 19200 or 57600bps 
BECAUSE in the UART code for atmega128 located at 
/tos/chips/atm128/Atm128UartP.nc, it defines the following:

 

command error_t Init.init() {

if (PLATFORM_BAUDRATE == 19200UL)

  m_byte_time = 200; // 1 TMicor ~= 2.12 us, one byte = 417us ~= 200

else if (PLATFORM_BAUDRATE == 57600UL)

  m_byte_time = 68;  // 1 TMicor ~= 2.12 us, one byte = 138us ~= 65

 

 return SUCCESS;

}

 

So, I tried to add the code here and define the following:

 

else if (PLATFORM_BAUDRATE == 115200UL)

  m_byte_time = 33;  // 1 TMicor ~= 2.12 us, one byte = 69us ~= 33  -à 1 
byte takes 69 us so 69/2.12 gives 33 (POINT ME IF I AM WRONG)

else if (PLATFORM_BAUDRATE == 230400UL)

  m_byte_time = 17;  // 1 TMicor ~= 2.12 us, one byte = 35us ~= 17

else if (PLATFORM_BAUDRATE == 256000UL)

  m_byte_time = 15;  // 1 TMicor ~= 2.12 us, one byte = 31us ~= 15

 

 

I think either I have a fault in m_byte_time value because for 57600bps 
baudrate, it comes out 65, but a value of 68 is given in the basic code, I do 
not know why??

 

THIS IS WHY I ASKED if the higher baudrates are handled differently in Linux 
and Windows???

 

I need higher baudrate as the BaseStationw ill be receiving number of packets 
per second, so it needs to send it out of serial faster otherwise there will be 
a bottleneck.

 

I hope my question is more clearer now

 

Cheers,

 

Varun Jain

 

From: Eric Decker [mailto:[EMAIL PROTECTED] 
Sent: Thursday, July 03, 2008 7:28 AM
To: Varun Jain
Subject: Re: [Tinyos-help] Serial Baudrate

 

What do you mean "differently for Linux and Windows"?

On Tue, Jul 1, 2008 at 7:37 PM, Varun Jain <[EMAIL PROTECTED]> wrote:

Hi,

Does anyone knows if Baudrate over 115200 bps is handed differently in 
Tinyos-2.x for Linux and Windows(Cygwin). What are the maximum speeds I can set 
up for them? I currently have Atmega-128 controller

 

Cheers, 

 

Varun Jain

 


___
Tinyos-help mailing li

Re: [Tinyos-help] Serial Baudrate

2008-07-02 Thread Varun Jain
I tried doing the 230400 baud rate as well on Cygwin, I think there is 
something either wrong in m_byte_time value that I am defining or something 
else I am missing, I am running Tinyos-2.0.2 under Cygwin, so I do not think I 
can go with the linux code.

 

I do not know how to solve this problem.

 

 

Varun Jain

 

From: Eric Decker [mailto:[EMAIL PROTECTED] 
Sent: Thursday, July 03, 2008 4:08 PM
To: Varun Jain
Subject: Re: [Tinyos-help] Serial Baudrate

 

I haven't ever seen the speeds that the Cygwin code uses.  I have seen what the 
Linux code uses, namely 57600, 115200, and 230400.

The Cygwin may work but it depends on what the underlying hardware supports.  
Given that Cygwin/Windows and Linux runs on the same hardware
it is very interesting the difference.

The easiest thing to do is try it.  I personally would go with the Linux code.

The telosb (msp430) h/w will support either mechanism by tweaking the divider 
and modulator registers.

eric

On Wed, Jul 2, 2008 at 10:51 PM, Varun Jain <[EMAIL PROTECTED]> wrote:

By 'differently', I am referring to the code at /tools/tinyos/java/serial
à here we can see two files, namely NativeSerial_win32 AND 
NativeSerial_linux 

 

For Windows (Cygwin) machines, I believe it gets the code for Baudrate from In 
NativeSerial_win32 as below: 

 

int getBaudRate()

  {

int baud_rate = get_comm_state().BaudRate;

switch( baud_rate )

{

  case CBR_110:return 110;

  case CBR_300:return 300;

  case CBR_600:return 600;

  case CBR_1200:   return 1200;

  case CBR_2400:   return 2400;

  case CBR_4800:   return 4800;

  case CBR_9600:   return 9600;

  case CBR_14400:  return 14400;

  case CBR_19200:  return 19200;

  case CBR_38400:  return 38400;

  case CBR_56000:  return 56000;

  case CBR_57600:  return 57600;

  case CBR_115200: return 115200;

  case CBR_128000: return 128000;

  case CBR_256000: return 256000;

}

return baud_rate;

  }

 

AND IN Linux machines, we get Baudrates from  NativeSerial_linux file as below:

int baud_to_enum( int baud )

  {

switch( baud )

{

  case 0: return B0;

  case 50: return B50;

  case 75: return B75;

  case 110: return B110;

  case 134: return B134;

  case 150: return B150;

  case 200: return B200;

  case 300: return B300;

  case 600: return B600;

  case 1200: return B1200;

  case 1800: return B1800;

  case 2400: return B2400;

  case 4800: return B4800;

  case 9600: return B9600;

  case 19200: return B19200;

  case 38400: return B38400;

  case 57600: return B57600;

  case 115200: return B115200;

  case 230400: return B230400;

}

throw comm_port_error("baud_to_enum, bad baud rate");

  }

 

  int enum_to_baud( int baudenum )

  {

switch( baudenum )

{

  case B0: return 0;

  case B50: return 50;

  case B75: return 75;

  case B110: return 110;

  case B134: return 134;

  case B150: return 150;

  case B200: return 200;

  case B300: return 300;

  case B600: return 600;

  case B1200: return 1200;

  case B1800: return 1800;

  case B2400: return 2400;

  case B4800: return 4800;

  case B9600: return 9600;

  case B19200: return 19200;

  case B38400: return 38400;

  case B57600: return 57600;

  case B115200: return 115200;

  case B230400: return 230400;

}

throw comm_port_error("enum_to_baud, bad baud rate");

  }

 

All my discussion is based on my belief that when we use Java tools like 
"Listen, MsgReader, etc.", these files are used... if not then I am wrong  but 
if I am right, then we can see that after the baudrate of 115200bps, Linux 
machines can  have only 230400bps whereas Windows can have 128000 and 256000bps.

 

Secondly, my problem is that my platform has an atmel atmega128 processor, and 
all the platforms  having this processor can either have 19200 or 57600bps 
BECAUSE in the UART code for atmega128 located at 
/tos/chips/atm128/Atm128UartP.nc, it defines the following:

 

command error_t Init.init() {

if (PLATFORM_BAUDRATE == 19200UL)

  m_byte_time = 200; // 1 TMicor ~= 2.12 us, one byte = 417us ~= 200

else if (PLATFORM_BAUDRATE == 57600UL)

  m_byte_time = 68;  // 1 TMicor ~= 2.12 us, one byte = 138us ~= 65

 

 return SUCCESS;

}

 

So, I tried to add the code here and define the following:

 

else if (PLATFORM_BAUDRATE == 115200UL)

  m_byte_time = 33;  // 1 TMicor ~= 2.12 us, one byte = 69us ~= 33  -à 1 
byte takes 69 us so 69/2.12 gives 33 (POINT ME IF I AM WRONG)

else if (PLATFORM_BAUDRATE == 230400UL)

  m_byte_time = 17;  // 1 TMicor ~= 2.12 us, one byte = 35us ~= 17

else if (PLATFORM_BAUDRATE == 256000UL)

  m_byte_time = 15;  // 1 TMicor ~= 2.12 us, one byte = 31us ~= 15

 

 

I think either I have a fault in m_byte_time value because

[Tinyos-help] Counter32khzC component for mica platform

2008-07-02 Thread m.khezri
Hello
Counter32khzC is available for pxa27x processor and provides
LocalTime32khz interface.
Mica platform have Counter32khz32C but this component doesn't provide
localtime interface.
is it possible to make component like Counter32khzC for mica platform?

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