[Tinyos-help] Re: connecting to the SerialForwarder

2007-06-05 Thread Javier Barbarán Sánchez

Hi Islam,

Try to do it as I do... In my case it is working, but anyway, you have not 
implemented properly de protocol

(the code is in pseudo-C#)

//First we have to send the protocol initialization, sending the protocol 
version

us[0]='T'; us= '!';
socket.Send(us,0,us.Length, );
//After that we have to receive also de protocol information
byte[] check = new byte[2];
socket.Receive(check,0, check.Lengh, ...)
//Now, receive the platform information (4 bytes)
byte[] nonceRem = new byte[4];
socket.Receive(nonceRem,0, nonceRem.Length,...)
//And send the information of the platform we are using,
//in my case the platform is micaz and the corresponding value is 3
char[] nonce = new char[4];

int platform = 3; //micaz

nonce[0] = (char)platform;
nonce[1] = (char) (platform >> 8);
nonce[2] = (char) (platform >> 16);
nonce[3] = (char) (platform >> 24);

socket.send(nonce, 0, nonce.Length,...)

//And thats all falks ;)
// Following you will receive one byte that show you the length of the next 
message

//And following you have to read from socket tha amount of bytes

byte[] myLength = new byte[1];
socket.receive(myLength,0, 1,..)
byte[] data = new byte[myLength];
socket.receive(data,0, data.Length,...)


Anyway, if it doesn't work, check that you have compiled the last version 
for C-based SerialForwarder (you can download it from tinyos cvs).


Greetings


- Original Message - 
From: "Islam Hegazy" <[EMAIL PROTECTED]>

To: "Javier Barbarán" <[EMAIL PROTECTED]>
Cc: 
Sent: Tuesday, June 05, 2007 7:49 AM
Subject: Re: connecting to the SerialForwarder



Thanks very much for the paper. It was really helpful.
Now I can receive from the SF. However, what I receive is unexpected. 
First,

what is the platform that I have to send to the SF? At the moment I resend
the platform that I receive from the SF. Second, the data length byte is
always '\t' which leads to wrong readings. Following is my code:
char s[2];

char dataLen[1];

char packet[256];

char platform[4];

int rcd;

short data;

short len;


if ((rcd = recv(sd, s, 2, 0)) != 0)

{

   send(sd, s, 2, 0);

   rcd = recv(sd, platform, 4, 0);//reads 4 bytes

   send(sd, platform, 4, 0);//send the platform that I received


   rcd = recv(sd, dataLen, 1, 0);//dataLen is always '\t'

   sscanf(dataLen, "%d", &len); //wrong len

   printf("%d\n", len);


   rcd = recv(sd, packet, len, 0);//read wrong data

   sscanf(packet, "%d", &data); //read the first byte

   printf("%d\n", data);


}


I also found this article about the SF protocol:
http://www.stanza.co.uk/emergentcity/?cat=11

Regards
Islam Hegazy



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


Re: [Tinyos-help] sending packets via Tython

2007-06-05 Thread Sarfraz Nawaz

Lets say the packet structure is defined as

typedef struct myPacket {
  uint16_t senderId;
  uint16_t someData;
}

then use mig to generate the corresponding java class file. At tython prompt
issue these commands

from simcore import *;
import myPacket;

myMsg = myPacket();
myMsg.set_senderId(0);
myMsg.set_someData(11);

comm.sendRadioMessage(20, sim.getTossimTime()+10, myMsg);

These commans import necessary stuff, create the packet, set corresponding
fields and send the packet to node 20.

On 6/5/07, Faisal Karim <[EMAIL PROTECTED]> wrote:


Hi Sarfaraz

Thanks again. But how to set the sender ID for comm.sendRadioMessage() coz
three arguments accepted by this method dont specify who is sender.

Looking forward for your early reply

 Regards
Faisal Karim



- Original Message 
From: Sarfraz Nawaz <[EMAIL PROTECTED]>
To: Faisal Karim <[EMAIL PROTECTED]>
Cc: tinyos help 
Sent: Tuesday, June 5, 2007 2:51:49 AM
Subject: Re: [Tinyos-help] sending packets via Tython

Its the simulation environment that is sending the packets not the base
station node. Though you can set the sender ID to be 0 and have the
receiving node believe that the packet came from node 0.

On 6/4/07, Faisal Karim <[EMAIL PROTECTED]> wrote:
>
>  Hi Sarfaraz
>
> Thanks for reply. Thats true but "who" is using these methods (
> comm.sendRadioMessage() and comm.sendUARTMessage() ) to send messages to
> any node. I assume its base station ie node 0.
>
> Im looking forward to send messages from specific node. Lets say node 2
> send message to node 10. How we can do by using Tython.
>
> Thanks in advance.
> Looking Forward
>
>  Regards
> Faisal Karim
>
>
>
> - Original Message 
> From: Sarfraz Nawaz < [EMAIL PROTECTED]>
> To: Faisal Karim <[EMAIL PROTECTED]>
> Cc: tinyos help 
> Sent: Sunday, June 3, 2007 6:12:12 AM
> Subject: Re: [Tinyos-help] sending packets via Tython
>
> comm.sendRadioMessage() and comm.sendUARTMessage() are used to send a
> packet to "any" node in the network on the uart and radio respectively.
>
> On 6/1/07, Faisal Karim < [EMAIL PROTECTED] > wrote:
> >
> >  Hi All
> >
> > Im looking forward to send packets from specific node in simulation
> > via Tython. In Tython manual it is described to send using moteIF(), but
> > what i understand this is to send some msg from base station ie some serial
> > port. To send to base station there is a method comm.sendUARTMessage(),
> > also there is comm.sendRadioMessage() which im assuming to send msg
> > from base station to specific node via radio as this method do not describe
> > which node is sending the message.
> >
> > any comments and help will be highly appreciated
> >
> >  Regards
> > Faisal Karim
> >
> >
> > --
> > Get the Yahoo! toolbar and be alerted to new email
> > 
wherever
> > you're surfing.
> >
> > ___
> > Tinyos-help mailing list
> > Tinyos-help@Millennium.Berkeley.EDU
> > https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
> >
> >
>
>
>
> --
> Get the free Yahoo! toolbar
> 
and
> rest assured with the added security of spyware protection.
>



--
Ready for the edge of your seat? Check out tonight's top 
pickson Yahoo! TV.

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

FW: [Tinyos-help] [lesson 4 with tinyOs2.0]

2007-06-05 Thread Firat TARAKTAS
 

-Original Message-
From: vazoumana fofana [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, June 05, 2007 6:47 PM
To: Firat TARAKTAS
Subject: RE: [Tinyos-help] [lesson 4 with tinyOs2.0]

Thanks for your answer. I ve succeeded. but i think the tutorial was not clear. 
indeed, Java testserial always failed if you don't add
something(options) or export MOTECOM. It was written after.

>From: "Firat TARAKTAS" <[EMAIL PROTECTED]>
>To: "vazoumana fofana" 
><[EMAIL PROTECTED]>,
>Subject: RE: [Tinyos-help] [lesson 4 with tinyOs2.0]
>Date: Tue, 5 Jun 2007 17:39:59 +0300
>
>
>Hi,
>
>1. Did you run the command like "java TestSerial -comm [EMAIL 
>PROTECTED]:telos"  
>or assign MOTECOM correctly?
>2. Be sure that other running programs on your PC does not use your port.
>
>Firat TARAKTAS
>
>
>-Original Message-
>From: [EMAIL PROTECTED]
>[mailto:[EMAIL PROTECTED] On Behalf Of 
>vazoumana fofana
>Sent: Tuesday, June 05, 2007 5:26 PM
>To: tinyos-help@Millennium.Berkeley.EDU
>Subject: [Tinyos-help] [lesson 4 with tinyOs2.0]
>
>Hi,
>
>i try to compile the lesson 4 Mote Pc serial Communication and Serial 
>Forwarder :
>When i execute java TestSerial, there is an error message wich appears :
>[EMAIL PROTECTED]:9002 died - exiting (java.net.ConnectException: Connection 
>refused).
>somebody can help me , please ?
>
>thanks.
>
>_
>Avec Windows Live OneCare éliminez tous les virus de votre PC !
>http://www.windowslive.fr/liveonecare/default.asp
>
>___
>Tinyos-help mailing list
>Tinyos-help@Millennium.Berkeley.EDU
>https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-he
>lp

_
Windows Live Spaces : créez votre blog à votre image ! 
http://www.windowslive.fr/spaces


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


Re: [Tinyos-help] sending packets via Tython

2007-06-05 Thread Sarfraz Nawaz

Lets say my packet is defined as follows

typedef struct myMsg {


On 6/5/07, Faisal Karim <[EMAIL PROTECTED]> wrote:


Hi Sarfaraz

Thanks again. But how to set the sender ID for comm.sendRadioMessage() coz
three arguments accepted by this method dont specify who is sender.

Looking forward for your early reply

 Regards
Faisal Karim



- Original Message 
From: Sarfraz Nawaz <[EMAIL PROTECTED]>
To: Faisal Karim <[EMAIL PROTECTED]>
Cc: tinyos help 
Sent: Tuesday, June 5, 2007 2:51:49 AM
Subject: Re: [Tinyos-help] sending packets via Tython

Its the simulation environment that is sending the packets not the base
station node. Though you can set the sender ID to be 0 and have the
receiving node believe that the packet came from node 0.

On 6/4/07, Faisal Karim <[EMAIL PROTECTED]> wrote:
>
>  Hi Sarfaraz
>
> Thanks for reply. Thats true but "who" is using these methods (
> comm.sendRadioMessage() and comm.sendUARTMessage() ) to send messages to
> any node. I assume its base station ie node 0.
>
> Im looking forward to send messages from specific node. Lets say node 2
> send message to node 10. How we can do by using Tython.
>
> Thanks in advance.
> Looking Forward
>
>  Regards
> Faisal Karim
>
>
>
> - Original Message 
> From: Sarfraz Nawaz < [EMAIL PROTECTED]>
> To: Faisal Karim <[EMAIL PROTECTED]>
> Cc: tinyos help 
> Sent: Sunday, June 3, 2007 6:12:12 AM
> Subject: Re: [Tinyos-help] sending packets via Tython
>
> comm.sendRadioMessage() and comm.sendUARTMessage() are used to send a
> packet to "any" node in the network on the uart and radio respectively.
>
> On 6/1/07, Faisal Karim < [EMAIL PROTECTED] > wrote:
> >
> >  Hi All
> >
> > Im looking forward to send packets from specific node in simulation
> > via Tython. In Tython manual it is described to send using moteIF(), but
> > what i understand this is to send some msg from base station ie some serial
> > port. To send to base station there is a method comm.sendUARTMessage(),
> > also there is comm.sendRadioMessage() which im assuming to send msg
> > from base station to specific node via radio as this method do not describe
> > which node is sending the message.
> >
> > any comments and help will be highly appreciated
> >
> >  Regards
> > Faisal Karim
> >
> >
> > --
> > Get the Yahoo! toolbar and be alerted to new email
> > 
wherever
> > you're surfing.
> >
> > ___
> > Tinyos-help mailing list
> > Tinyos-help@Millennium.Berkeley.EDU
> > https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
> >
> >
>
>
>
> --
> Get the free Yahoo! toolbar
> 
and
> rest assured with the added security of spyware protection.
>



--
Ready for the edge of your seat? Check out tonight's top 
pickson Yahoo! TV.

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

[Tinyos-help] HELP- spi serial data reception on atmega microcontroller

2007-06-05 Thread Dipti
Dear all,

I want to send serial data from a microcontroller to the atmega 
microcontroller on a mica2 mote via the SPI interface. The mica2 mote is 
basically a slave in this serial data transfer which just receives the serial 
data sent by another master microcontroller and forwards the same on the RF. 
How should i start building my application on the mica2 mote? Is there any 
built in example which can guide me on similar lines.

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

[Tinyos-help] Java Tools moteiv

2007-06-05 Thread keerthii

Does anyone know,

Is it possible to install the java tools and have it working without  
installing any of the TinyOS stuff?


If so, where are all the serial drivers that I need to use for the MoteIV ?

Regards

Keerthi

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


[Tinyos-help] Is there anyone know how to use java to get the data from motes?

2007-06-05 Thread Hover Dong
hi, I am doing a application. I should use java to get the data from motes 
thought serial port on PC. I think there some source code about it. Is there 
any one has done it or know which source code about it. If so, please tell me. 
I will appreciate ur helps!!! BTW, I am using TinyOS2.0.
_
Live Earth is coming.  Learn more about the hottest summer event - only on MSN.
http://liveearth.msn.com?source=msntaglineliveearthwlm___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] Tmote Sky and LCD Panel

2007-06-05 Thread Preethi Naveen

Hello,

I have been trying to connect a GPIO based LCD panel to Tmote sky but am not
able to figure out how to do so. Can someone please give me pointers towards
the same?

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

Re: [Tinyos-help] Keymap with Generics Design?

2007-06-05 Thread Philip Levis

On Jun 5, 2007, at 4:28 PM, J. Ryan Stinnett wrote:

I'm still pretty new to the concept of generics in T2, and I'm  
unsure of the best way to design the following set of components.   
I was trying to use something similar to the pattern in AMSenderC,  
where a configuration hides the creation of a unique instance of  
the Send interface from the application.  However, in my case, not  
only can there be an arbitrary number of clients (the role of  
AMSenderC), but the service is also generic and there could be an  
arbitrary number of those as well.


As an example, let's say there are two service instances, A and B,  
and 5 client instances, 1 through 5.  1 and 2 are connected to A  
and 3 through 5 are connected to B.  What would be a clean way to  
do this?  My goal would be to do it all through wiring so there's  
no need for a table mapping clients to services.


I looked over the design pattens in the TinyOS Programming Manual,  
and the Keymap seems close, but it doesn't add generics into the  
picture which seems to complicate things.


Take a look at the flash driver example in the document text. Here's  
an example. The bottom level thing that has 5 clients is called  
UnderlyingService. On top of it you have two services ServiceA and  
ServiceB. The coding trick is in the ClientA and ClientB  
configurations, where you allocate a key for the UnderlyingService  
keyspace (5 entries) as well as one for the ServiceA or ServiceB  
keyspace (2 or 3 entries), and map them by doing a parameterized-to- 
parameterized wiring.



module UnderlyingService {
  provides interface X[uint8_t key];
}

generic module Service {
  provides interface X as TopX[uint8_t key];
  uses interface X as BottomX[uint8_t key];
}

configuration ServiceA {
  provides interface X as TopX[uint8_t key];
  uses interface X as BottomX[uint8_t key];
}
implementation {
  components new Service();
  TopX = Service.TopX;
  BottomX = Service.BottomX;
}

configuration ServiceB {
  provides interface X as TopX[uint8_t key];
  uses interface X as BottomX[uint8_t key];
}
implementation {
  components new Service();
  TopX = Service.TopX;
  BottomX = Service.BottomX;
}

configuration ClientA {
  provides interface X;
}
implementation {
  enum {
SERVICE_KEY = unique("ServiceA.TopX"), // Should be a #define  
string, but I omitted for clarity

IMPL_KEY = unique("UnderlyingService.X"),
  };
  components ServiceA, UnderlyingService;
  X = ServiceA.TopX[SERVICE_KEY];
  ServiceA.BottomX[SERVICE_KEY] -> UnderlyingService.X[IMPL_KEY];
}

configuration ClientB {
  provides interface X;
}
implementation {
  enum {
SERVICE_KEY = unique("ServiceB.TopX"), // Should be a #define  
string, but I omitted for clarity

IMPL_KEY = unique("UnderlyingService.X"),
  };
  components ServiceB, UnderlyingService;
  X = ServiceB.TopX[SERVICE_KEY];
  ServiceB.BottomX[SERVICE_KEY] -> UnderlyingService.X[IMPL_KEY];
}

Hope this helps,

Phil

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


[Tinyos-help] Keymap with Generics Design?

2007-06-05 Thread J. Ryan Stinnett
I'm still pretty new to the concept of generics in T2, and I'm unsure of 
the best way to design the following set of components.  I was trying to 
use something similar to the pattern in AMSenderC, where a configuration 
hides the creation of a unique instance of the Send interface from the 
application.  However, in my case, not only can there be an arbitrary 
number of clients (the role of AMSenderC), but the service is also 
generic and there could be an arbitrary number of those as well.


As an example, let's say there are two service instances, A and B, and 5 
client instances, 1 through 5.  1 and 2 are connected to A and 3 through 
5 are connected to B.  What would be a clean way to do this?  My goal 
would be to do it all through wiring so there's no need for a table 
mapping clients to services.


I looked over the design pattens in the TinyOS Programming Manual, and 
the Keymap seems close, but it doesn't add generics into the picture 
which seems to complicate things.


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


RE: [Tinyos-help] [CC2420_lpl] What happens when the duty cycle expiresin the middle of a receiving a packet?

2007-06-05 Thread David Moss
This is a valid issue with the current stack - although it should rarely
occur.  As soon as the energy of a packet is detected, the radio stays on
longer to accept that packet.  If the packet is not accepted within a
certain amount of time, the radio shuts off and assumes the packet(s) flying
around are not valid. 

The problem comes down to the type of receive check being performed.
Currently, we're performing energy-based and packet-based receive checks,
but have left out the byte-based received checks which is in the middle.
Byte-based receive checks will allow the receiver, in the future, to remain
on while the radio is receiving a valid bytes that compose a packet.

To make the stack more reliable at the current time without the byte-based
receive check, I've upped the amount of time the radio spends on after
detecting energy, so that there's less of a chance of cutting off packets
while they're being received.

-David




-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of John
Hendrie
Sent: Tuesday, June 05, 2007 7:44 AM
To: tinyos-help@Millennium.Berkeley.EDU
Subject: [Tinyos-help] [CC2420_lpl] What happens when the duty cycle
expiresin the middle of a receiving a packet?

Hi,

I know it's a bit of an edge case, but what happens when the duty
cycle expires in the middle of a receiving a packet using the LPL
stack in TinyOS 2.0?
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


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


[Tinyos-help] Question on MultiOscilloscope Application

2007-06-05 Thread M A

Hi

I have started learning tinyos-2.x and I have a simple question related to
MultiOscilloscope function in directory tinyos-2.x/apps/MultihopOscilloscope.
In the file MultioscilloscopeC.nc we declare a message buffer " message_t
uartbuf ". But I dont understand where is this initialized. We call the
command SerialSend.getPayload(&uartbuf); in the Recevie.receive() event.
Thus  basically we are getting the payload from the message stored in
uartbuf. But I cant figure out where and when a message is being stored in
uartbuf.

I guess when Receive.receive returns it returns a buffer for the stack. Is
it the same buffer? I am confused. Can anyone explain this to me ?

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

Re: [Tinyos-help] IBM JDK segfaults on libtoscomm.so

2007-06-05 Thread David Gay

On 6/2/07, Ákos Maróy <[EMAIL PROTECTED]> wrote:

Aurélien Francillon wrote:
> IIRC (not sure), i tracked it back to some known regression of gcc 4.1.x ...
>  it works fine with gcc-3.x

I tried with gcc-3.x, and while it doesn't crash - it doesn't work either.

by that I mean that the mote stops sending as soon as TestSerial starts
up (the TX flashes before that, doesn't flash afterwards), and the mote
doesn't react to the data sent by TestSerial either (it should change
it's LEDs AFAIK)


Hmm, trying this on an x86_64 kernel, I did find one bug which is
fixed by the following patch (the change to the Makefile is necessary
to keep Sun's JDK happy at least):

cvs diff: Diffing .
Index: Makefile.am
===
RCS file: /cvsroot/tinyos/tinyos-2.x/tools/tinyos/java/serial/Makefile.am,v
retrieving revision 1.3
diff -u -r1.3 Makefile.am
--- Makefile.am 9 Jan 2007 23:45:17 -   1.3
+++ Makefile.am 5 Jun 2007 20:36:36 -
@@ -19,7 +19,7 @@
  TOSComm_wrap.cxx

libtoscomm.so: $(libtoscomm_so_SOURCES)
-   $(CXX) -O2 -shared -fPIC "-I$(JDK)/include" "-I$(JDK)/include/linux" \
+   $(CXX) -m32 -O2 -shared -fPIC "-I$(JDK)/include"
"-I$(JDK)/include/linux" \
 -o $@ NativeSerial_linux.cpp

toscomm.dll: $(toscomm_dll_SOURCES)
Index: NativeSerial_linux.cpp
===
RCS file: 
/cvsroot/tinyos/tinyos-2.x/tools/tinyos/java/serial/NativeSerial_linux.cpp,v
retrieving revision 1.4
diff -u -r1.4 NativeSerial_linux.cpp
--- NativeSerial_linux.cpp  12 Dec 2006 18:23:02 -  1.4
+++ NativeSerial_linux.cpp  5 Jun 2007 20:36:36 -
@@ -351,19 +351,21 @@

while( m_wait_for_events && (m_fd != -1) && (m_events_out == 0) )
{
+  int fd = m_fd;
+
  FD_ZERO( &input );
-  FD_SET( m_fd, &input );
+  FD_SET( fd, &input );
  tv.tv_sec = 0;
  tv.tv_usec = 100*1000; // 1ms is the minimum resolution, at best

-  if( select( m_fd+1, &input, NULL, NULL, &tv ) == -1 )
+  if( select( fd+1, &input, NULL, NULL, &tv ) == -1 )
  {
   if( errno == EINTR )
 break;
   errno_wrap( true, "waitForEvent.select" );
  }

-  if( FD_ISSET( m_fd, &input ) )
+  if( FD_ISSET( fd, &input ) )
   m_events_out |= DATA_AVAILABLE;
}


However it's not clear to me that this is the same problem.

David Gay

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


[Tinyos-help] Wiki

2007-06-05 Thread Benjamin Madore
I tried to find a TinyOS Wiki. The one I could find, the owner never got
back to me. So I created one.

http://tinyoscommunity.elwiki.com/Main_Page

The idea is that anyone here who has a question answered, develops a
solution, or finds a resource online should add it in the appropriate
section.

We can, by sharing what worked for us, have a resource that covers the
common questions and documents the obscure facts of TinyOS.

There is little on it right now, but as I get time, I will add my
experiences. I hope you will add yours.

I don't host it, elwiki does, so I can provide no technical support for it.

-- 
The difference between the right word and the almost right word is really a
large matter- it's the difference between a lightning bug and the lightning.
-Twain

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


Re: [Tinyos-help] Active message protocol

2007-06-05 Thread jose m
Thanks! Ok, don't worry, I understand concurrency. However, when you use AM 
protocol, you use AMStandard (not UartStream), and AMStandard doesn't allow 
send radio and uart packets "at the same time", even when the uart (or radio) 
is idle (a variable named "state" is checked). This behavior looks 
intentional... any reason for this?

- Mensaje original 
De: Steve McKown <[EMAIL PROTECTED]>
Para: tinyos-help@millennium.berkeley.edu
CC: jose m <[EMAIL PROTECTED]>
Enviado: martes 5 de junio de 2007, 1:20:23
Asunto: Re: [Tinyos-help] Active message protocol

On Monday 04 June 2007 13:38, jose m wrote:
> Checking out the AMStandard.nc file I see that, if you are transmitting a
> radio message, the AMStandard component is occupied until the tx is done,
> and you cannot tx to UART until then. Why? any problem tx to radio and UART
> at the same time?

Assuming the radio and serial UART don't share any common resources, their 
operations can certainly be interleaved.  For example, you can call 
AMSend.send(...) and then on the very next line call UartStream.send(...).  
The actual order of execution occurs based upon the TinyOS concurrency model.   
AMSend.sendDone() and UartStream.sendDone() will be each called as their 
relevant split-phase operations complete.

If you want to learn more about TinyOS concurrency, check out Philip Levis' 
programming guide @ http://csl.stanford.edu/~pal/pubs/tinyos-programming.pdf

All the best,
Steve











__ 
Preguntá. Respondé. Descubrí. 
Todo lo que querías saber, y lo que ni imaginabas, 
está en Yahoo! Respuestas (Beta). 
¡Probalo ya! 
http://www.yahoo.com.ar/respuestas 
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

[Tinyos-help] SOS on BBFS ;)

2007-06-05 Thread Mayur Maheshwari

Hi David,



I am using bbfs but have been facing a few problems. Your inputs will help a
lot.



- does bbfs handles flash access contention itself, or do I need to add a
bool, to allow only single access to bbfs read/write.

- does bbfs defines an upper limit on max number of files on flash and/or
max number of open files etc

- does bbfs have any issues with the same file being opened/read/write
simultaneously



I am reading a lot of files and sending over radio (while writing continues
simultaneously). It seems that bbfs open of a file fails after sometime and
every other bbfs operations fails too.



It will help a lot it you can share some test code where multiple read,
write and delete happen simultaneously.



Thanks,

Mayur


--
Mayur Maheshwari([EMAIL PROTECTED])

"Karmanye Vadhikaraste Ma Phaleshu Kadachana,
Ma Karma Phala Hetur Bhurmatey Sangostva Akarmani"
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] Tinyos 2 Tutorial 11 Linker Problems

2007-06-05 Thread Marek Jawurek
Thank you very much Phil.
You were right, my nesc from the tinyos 1 install was used.

Now everything is working alright. With the micaz sim at least.
Do you know whether other platforms will be supported as simulations ?

Marek



Am Dienstag, den 05.06.2007, 10:37 -0700 schrieb Philip Levis:
> On Jun 5, 2007, at 10:27 AM, Marek Jawurek wrote:
> 
> > Thanks for looking into it Phil, here is what
> > avr-objdump -t build/micaz/sim.o
> > produces.
> >
> > I am sorry but actually I can hardly grasp at what I am looking.
> > But it appears that the sim.o object file is in elf32-avr format and
> > tossim.o and pytossim.o both in elf32-little. But where is the
> > difference ? When I call make micaz sim I get some different errors on
> > top. I appended the output of that call to the end.
> >
> >
> > build/micaz/sim.o: file format elf32-avr
> 
> This is the problem: for some reason, TOSSIM is compiling sim.o using  
> avr-gcc rather than gcc. That is, it's compiling it for an atmega128  
> microcontroller instead of your x86 processor.
> 
> If you add the -v option to your CFLAGS you might be able to figure  
> out what's going on.
> 
> Do you have an existing TinyOS 1.x install on this machine? If so, my  
> guess is that you're calling the wrong ncc. Try ncc --version. You  
> should have 1.2.1 or 1.2.3. Try 'which ncc' to figure out which one  
> you're executing, and look in /usr/bin as well as /usr/local/bin for  
> the right one.
> 
> Phil
> ___
> Tinyos-help mailing list
> Tinyos-help@Millennium.Berkeley.EDU
> https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
-- 
Marek Jawurek <[EMAIL PROTECTED]>

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


[Tinyos-help] Trying to simulate tutorial 12 EasyDisseminationAppC - error

2007-06-05 Thread Hugo Sousa

I get these errors (no errors or warnings present with "make micaz")

In file included from /opt/tinyos-2.x/tos/lib/net/TrickleTimerMilliC.nc:50,
from /opt/tinyos-2.x/tos/lib/net/DisseminationTimerP.nc:49,
from /opt/tinyos-2.x/tos/lib/net/DisseminatorC.nc:66,
from EasyDisseminationAppC.nc:8:
In component `TrickleTimerImplP':
/opt/tinyos-2.x/tos/lib/net/TrickleTimerImplP.nc: In function `adjustTimer':
/opt/tinyos-2.x/tos/lib/net/TrickleTimerImplP.nc:215: warning: declaration of `t
ime' shadows global declaration
/usr/include/time.h:49: warning: location of shadowed declaration
/opt/tinyos-2.x/tos/lib/net/TrickleTimerImplP.nc: In function `generateTime':
/opt/tinyos-2.x/tos/lib/net/TrickleTimerImplP.nc:247: warning: declaration of `t
ime' shadows global declaration
/usr/include/time.h:49: warning: location of shadowed declaration
In component `TossimPacketModelC':
/opt/tinyos-2.x/tos/lib/tossim/TossimPacketModelC.nc: In function `startDoneTask
.runTask':
/opt/tinyos-2.x/tos/lib/tossim/TossimPacketModelC.nc:85: Control.startDone not c
onnected
/opt/tinyos-2.x/tos/lib/tossim/TossimPacketModelC.nc: In function `stopDoneTask.
runTask':
/opt/tinyos-2.x/tos/lib/tossim/TossimPacketModelC.nc:90: Control.stopDone not co
nnected
make: *** [sim-exe] Error 1

What is the problem?

Another thing, I couldn't compile the program with the makefile
provided, I had to chage
CFLAGS += -I$(TOSDIR)/lib/net
to
PFLAGS += -I$(TOSDIR)/lib/net

Thanks in advance,

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


RE: [Tinyos-help] MEP-SYS / MoteView 1.2 Problems

2007-06-05 Thread Giri Baleri
Hello Ognjen,
 
The MEP nodes in the MEP-SYS are programmed with XMesh 1.2 firmware and
the low power version of the app doesn't support the commands (eg.
change data rates). You can power-cycle the MEP nodes to get them back
to original configuration (i.e. data once every 3 minutes).
 
For your base station, what node ID, group ID, RF band and RF channel
did you use? 
 
The MEP410s and MEP510s operate in low power mode and can not be
reprogrammed over the air (especially since they run XMesh 1.2).
 
Regards,
Giri Baleri
Crossbow Technology, Inc



From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of ognjen
popovic
Sent: Tuesday, June 05, 2007 9:39 AM
To: tinyos-help@Millennium.Berkeley.EDU
Subject: [Tinyos-help] MEP-SYS / MoteView 1.2 Problems


Hello,
I work on the MEP-SYS enviromental system from crossbow. With the
enviromental system came the MoteView 1.2.
I tried to change Data Rate of motes.
Beofre that , motes periodically sent their data exactly every 3
minutes. But when I tried to change the Data Rate to 6 minutes, they
lost their synchronisation , and now some motes are sending data 10
times per minute, and some almost never. 
 
I tried to reprogramm the Base Station (MBR 410) (with XMesh_Base_lp),
but after some time, led 1 and 2 turned on, and led 3 blinks every 30
seconds. 
Does anyone have some experience with these devices, and is there a way
I could return the system into the original state?
 
I'm not sure how te reprogramm the motes ( MEP 410 and  MEP 510) over
the air, and any instructions would be more then useful.
 
Regards,
 
Ognjen Popovic
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] Tinyos 2 Tutorial 11 Linker Problems

2007-06-05 Thread Philip Levis

On Jun 5, 2007, at 10:27 AM, Marek Jawurek wrote:


Thanks for looking into it Phil, here is what
avr-objdump -t build/micaz/sim.o
produces.

I am sorry but actually I can hardly grasp at what I am looking.
But it appears that the sim.o object file is in elf32-avr format and
tossim.o and pytossim.o both in elf32-little. But where is the
difference ? When I call make micaz sim I get some different errors on
top. I appended the output of that call to the end.


build/micaz/sim.o: file format elf32-avr


This is the problem: for some reason, TOSSIM is compiling sim.o using  
avr-gcc rather than gcc. That is, it's compiling it for an atmega128  
microcontroller instead of your x86 processor.


If you add the -v option to your CFLAGS you might be able to figure  
out what's going on.


Do you have an existing TinyOS 1.x install on this machine? If so, my  
guess is that you're calling the wrong ncc. Try ncc --version. You  
should have 1.2.1 or 1.2.3. Try 'which ncc' to figure out which one  
you're executing, and look in /usr/bin as well as /usr/local/bin for  
the right one.


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


Re: [Tinyos-help] Tinyos 2 Tutorial 11 Linker Problems

2007-06-05 Thread Marek Jawurek
Thanks for looking into it Phil, here is what 
avr-objdump -t build/micaz/sim.o 
produces.

I am sorry but actually I can hardly grasp at what I am looking. 
But it appears that the sim.o object file is in elf32-avr format and
tossim.o and pytossim.o both in elf32-little. But where is the
difference ? When I call make micaz sim I get some different errors on
top. I appended the output of that call to the end.


Marek

build/micaz/sim.o: file format elf32-avr

SYMBOL TABLE:
 ldf *ABS*   app.c
 ld  .text  
 ld  .data  
 ld  .bss   
003f l   *ABS*   __SREG__
003e l   *ABS*   __SP_H__
003d l   *ABS*   __SP_L__
 l   *ABS*   __tmp_reg__
0001 l   *ABS*   __zero_reg__
0034 l F .text  0010 __nesc_disable_interrupt
0c0c l F .text  0012 RealMainP$Scheduler$init
077e l F .text  0030 RealMainP$PlatformInit$init
074e l F .text  0030 RealMainP$Scheduler$runNextTask
05c0 l F .text  0030 RealMainP$SoftwareInit$init
05b0 l F .text  0010 __nesc_enable_interrupt
04b8 l F .text  0012 RealMainP$Boot$booted
00ba l F .text  0012 RealMainP$Scheduler$taskLoop
00cc l F .text  003a SchedulerBasicP$Scheduler$taskLoop
03ce l F .text  00ea SchedulerBasicP$popTask
0186 l F .text  0012 SchedulerBasicP$McuSleep$sleep
0106 l F .text  0058 SchedulerBasicP$TaskBasic$runTask
1aee l F .text  0066 AlarmToTimerC$0$fired$runTask
0cb4 l F .text  0154 VirtualizeTimerC$0$updateFromTimer
$runTask
015e l F .text  0028 SchedulerBasicP$TaskBasic$default
$runTask
0198 l F .text  0086 McuSleepC$McuSleep$sleep
031c l F .text  0030 McuSleepC$McuPowerOverride$lowestState
025e l F .text  00be McuSleepC$getPowerState
021e l F .text  0040 mcombine
034c l F .text  0082 HplAtm128Timer0AsyncP$McuPowerOverride
$lowestState
04ca l F .text  0032 BlinkC$Boot$booted
0574 l F .text  003c BlinkC$Timer0$startPeriodic
0538 l F .text  003c BlinkC$Timer1$startPeriodic
04fc l F .text  003c BlinkC$Timer2$startPeriodic
1c52 l F .text  0058 VirtualizeTimerC$0$Timer$startPeriodic
05f0 l F .text  0052 Atm128AlarmAsyncP$0$Init$init
0724 l F .text  0012 Atm128AlarmAsyncP$0$TimerAsync
$setTimer0Asynchronous
06c8 l F .text  002e Atm128AlarmAsyncP$0$TimerCtrl
$setControl
066c l F .text  002e Atm128AlarmAsyncP$0$Compare$set
0642 l F .text  0012 Atm128AlarmAsyncP$0$Compare$start
17cc l F .text  01ac Atm128AlarmAsyncP$0$setInterrupt
0654 l F .text  0018 HplAtm128Timer0AsyncP$Compare$start
069a l F .text  002e HplAtm128Timer0AsyncP$Compare$set
06f6 l F .text  002e HplAtm128Timer0AsyncP$TimerCtrl
$setControl
0736 l F .text  0018 HplAtm128Timer0AsyncP$TimerAsync
$setTimer0Asynchronous
0c64 l F .text  0050 SchedulerBasicP$Scheduler$runNextTask
07ae l F .text  0056 PlatformP$Init$init
0a82 l F .text  0030 PlatformP$MeasureClock$init
0862 l F .text  003e PlatformP$MoteInit$init
0818 l F .text  004a ecombine
0804 l F .text  0014 PlatformP$power_init
095c l F .text  002a LedsP$Init$init
08a0 l F .text  0026 MotePlatformP$PlatformInit$init
0932 l F .text  0012 MotePlatformP$SerialIdPin$makeInput
0908 l F .text  0012 MotePlatformP$SerialIdPin$clr
08c6 l F .text  0030 MotePlatformP$SubInit$init
08f6 l F .text  0012 MotePlatformP$SubInit$default$init
091a l F .text  0018 HplAtm128GeneralIOPinP$4$IO$clr
0944 l F .text  0018 HplAtm128GeneralIOPinP$4$IO$makeInput
0a58 l F .text  0012 LedsP$Led0$makeOutput
0a2e l F .text  0012 LedsP$Led1$makeOutput
0a04 l F .text  0012 LedsP$Led2$makeOutput
09da l F .text  0012 LedsP$Led0$set
09b0 l F .text  0012 LedsP$Led1$set
0986 l F .text  0012 LedsP$Led2$set
0998 l F .text  0018 HplAtm128GeneralIOPinP$0$IO$set
09c2 l F .text  0018 HplAtm128GeneralIOPinP$1$IO$set
09ec l F .text  0018 HplAtm128GeneralIOPinP$2$IO$set
0a16 l F .text  0018 HplAtm128GeneralIOPinP$0$IO$makeOutput
0a40 l F .text  0018 HplAtm128GeneralIOPinP$1$IO$makeOutput
0a6a l F .text  0018 HplAtm128GeneralIOPinP$2$IO$makeOutput
0ab2 l F .text  015a MeasureClockC$Init$init
0c1e l F .text  0046 SchedulerBasicP$Scheduler$init
0fe0 l F .text  0042 VirtualizeTimerC$0$TimerFrom$getNow
0f6c l F .text  0012 VirtualizeTimerC$0$TimerFrom$stop
1248 l F .text  0116 Virtualiz

Re: [Tinyos-help] Tinyos 2 Tutorial 11 Linker Problems

2007-06-05 Thread Philip Levis


On Jun 5, 2007, at 9:37 AM, Marek Jawurek wrote:

Well to me it doesn't look like a Problem with the tmote target but  
with

linking the python libs together. I tried it with : make micaz sim
but it produces the same result, (just the linker output):

  linking into shared object ./_TOSSIMmodule.so
g++ -shared -fPIC  build/micaz/pytossim.o build/micaz/sim.o
build/micaz/tossim.o build/micaz/c-support.o -lstdc++  -o
_TOSSIMmodule.so
/usr/bin/ld: build/micaz/sim.o: Relocations in generic ELF (EM: 83)
/usr/bin/ld: build/micaz/sim.o: Relocations in generic ELF (EM: 83)
build/micaz/sim.o: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make: *** [sim-exe] Fehler 1


It looks like sim.o isn't being compiled properly. Is it compiling an  
avr object file? Try using objdump (or avr-objdump) to figure out  
what's going on.


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


Re: [Tinyos-help] [lesson 4 with tinyOs2.0]

2007-06-05 Thread Benjamin Madore

On Tue, June 5, 2007 12:48 pm, vazoumana fofana said:
> My platform is Xubuntos. I've got a firewall. I know it 's possible to
> execute java Testserial without defining MOTECOM.

Only if you have the SerialForwarder running.

> I understand you must
> execute java testserial in adding options -comm with port. if you just type
> java testserial, it doesn't work. Is it right ?

Java mote communication defaults to a loopback connection, not the serial
port. If you want to communicate over the serial port you use one of:

  export [EMAIL PROTECTED]:19200 # mica baud rate
  export [EMAIL PROTECTED]:mica  # mica baud rate, again
  export [EMAIL PROTECTED]:mica2 # the mica2 baud rate, on a different
serial port
  export [EMAIL PROTECTED]:57600 # explicit mica2 baud rate

or you may:

  java net.tinyos.sf.SerialForwarder -comm [EMAIL PROTECTED]:

But I am not familiar with the testserial program. It may be able to take
arguments on its own or not work with the SerialForwarder.

>>From: "Benjamin Madore"
>>To: "vazoumana fofana"
>>CC: tinyos-help@millennium.berkeley.edu
>>Subject: Re: [Tinyos-help] [lesson 4 with tinyOs2.0]
>>Date: Tue, 5 Jun 2007 12:12:37 -0400 (EDT)
>>
>>
>>On Tue, June 5, 2007 10:26 am, vazoumana fofana said:
>> > i try to compile the lesson 4 Mote Pc serial Communication and Serial
>> > Forwarder :
>> > When i execute java TestSerial, there is an error message wich appears :
>> > [EMAIL PROTECTED]:9002 died - exiting (java.net.ConnectException: 
>> > Connection
>> > refused).
>>
>>What platform? (Windows, Linux, Mac) Do you have a firewall? Have you set
>>up
>>your motecom variable? What commands are you using to execute TestSerial?
>>Are you using the serial forwarder or not?
>>
>>What version of TinyOS?
>>
>>--
>>The difference between the right word and the almost right word is really a
>>large matter- it's the difference between a lightning bug and the
>>lightning.
>>-Twain
>>
>
> _
> Gagnez des écrans plats avec Live.com http://www.image-addict.fr/
>


-- 
The difference between the right word and the almost right word is really a
large matter- it's the difference between a lightning bug and the lightning.
-Twain

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


Re: [Tinyos-help] Tinyos 2 Tutorial 11 Linker Problems

2007-06-05 Thread Marek Jawurek
Well to me it doesn't look like a Problem with the tmote target but with
linking the python libs together. I tried it with : make micaz sim
but it produces the same result, (just the linker output):

  linking into shared object ./_TOSSIMmodule.so
g++ -shared -fPIC  build/micaz/pytossim.o build/micaz/sim.o
build/micaz/tossim.o build/micaz/c-support.o -lstdc++  -o
_TOSSIMmodule.so
/usr/bin/ld: build/micaz/sim.o: Relocations in generic ELF (EM: 83)
/usr/bin/ld: build/micaz/sim.o: Relocations in generic ELF (EM: 83)
build/micaz/sim.o: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make: *** [sim-exe] Fehler 1


Marek


Am Dienstag, den 05.06.2007, 09:31 -0700 schrieb Philip Levis:
> As the tutorial states, tmote is not currently supported. So you must  
> type make micaz sim.
> 
> Phil
> 
> On Jun 5, 2007, at 9:24 AM, Marek Jawurek wrote:
> 
> > Hi everyone,
> >
> > I cannot get TOSSIM compiled with python support properly on my Debian
> > system. I have python-dev installed and everything seems fine until  
> > the
> > linker is invoked:
> >
> > I tried 'make tmote sim' in the Blink app directory and got back an
> > error msg (see below). Apparently a linker error but I have no clues.
> >
> > Any help is appreciated
> >
> >
> > Marek
> >
> >
> >  make tmote sim
> > mkdir -p build/telosb
> >   placing object files in build/telosb
> >   writing XML schema to app.xml
> >   compiling BlinkAppC to object file sim.o
> > ncc -c -shared -fPIC -o build/telosb/sim.o -g -O0 -O -tossim
> > -fnesc-nido-tosnodes=1000 -fnesc-simulate
> > -fnesc-nido-motenumber=sim_node\(\)   -mdisable-hwmul -Wall -Wshadow
> > -DDEF_TOS_AM_GROUP=0x7d -Wnesc-all -target=telosb
> > -fnesc-cfile=build/telosb/app.c -board=  -Wno-nesc-data-race
> > BlinkAppC.nc   -fnesc-dump=components -fnesc-dump=variables
> > -fnesc-dump=constants -fnesc-dump=typedefs -fnesc-dump=interfacedefs
> > -fnesc-dump=tags -fnesc-dumpfile=app.xml
> > /data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/TransformCounterC.nc: In
> > function `TransformCounterC$0$CounterFrom$overflow':
> > /data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/TransformCounterC.nc:126:
> > warning: implicit declaration of function `sim_node'
> > /data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc: In
> > function `__nesc_nido_resolve':
> > /data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc:158:
> > warning: implicit declaration of function `strcmp'
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc: In  
> > function
> > `__nesc_nido_initialise':
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:228:  
> > warning:
> > passing arg 1 of `memset' discards qualifiers from pointer target type
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:229:  
> > warning:
> > passing arg 1 of `memset' discards qualifiers from pointer target type
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:230:  
> > warning:
> > passing arg 1 of `memset' discards qualifiers from pointer target type
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:231:  
> > warning:
> > passing arg 1 of `memset' discards qualifiers from pointer target type
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:232:  
> > warning:
> > passing arg 1 of `memset' discards qualifiers from pointer target type
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:263:  
> > warning:
> > passing arg 1 of `memset' discards qualifiers from pointer target type
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:264:  
> > warning:
> > passing arg 1 of `memset' discards qualifiers from pointer target type
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:270:  
> > warning:
> > implicit declaration of function `memcpy'
> > /data/hiwi/tinyos/tinyos-2.x/tos/interfaces/Scheduler.nc: At top  
> > level:
> > /data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc:152:
> > warning: `__nesc_nido_resolve' defined but not used
> > /data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:222:  
> > warning:
> > `__nesc_nido_initialise' defined but not used
> >   compiling Python support and C libraries into pytossim.o, tossim.o,
> > and c-support.o
> > g++ -c  -shared -fPIC -o build/telosb/pytossim.o -g -O0
> > -O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx
> > -I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
> > -DHAVE_CONFIG_H
> > g++ -c  -shared -fPIC -o build/telosb/tossim.o -g -O0
> > -O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/tossim.c
> > -I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
> > g++ -c  -shared -fPIC -o build/telosb/c-support.o -g -O0
> > -O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/hashtable.c
> > -I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
> >   linking into shared object ./_TOSSIMmodule.so
> > g++ -shared -fPIC  build/telosb/pytossim.o build/telosb/sim.o
> > build/telosb/tossim.o build/telo

[Fwd: Re: [Tinyos-help] [lesson 4 with tinyOs2.0]]

2007-06-05 Thread Benjamin Madore
Forwarding to the list (remember everyone, REPLY ALL)

- Original Message -
Subject: Re: [Tinyos-help] [lesson 4 with tinyOs2.0]


My platform is Xubuntos. i ve got a firewall. I know it 's possible to 
execute java Testserial without defining MOTECOM. i understand you must 
execute java testserial in adding options -comm with port. if you just type 
java testserial, it doesn't work. Is it right ?

>From: "Benjamin Madore"
>To: "vazoumana fofana"
>CC: tinyos-help@millennium.berkeley.edu
>Subject: Re: [Tinyos-help] [lesson 4 with tinyOs2.0]
>Date: Tue, 5 Jun 2007 12:12:37 -0400 (EDT)
>
>
>On Tue, June 5, 2007 10:26 am, vazoumana fofana said:
> > i try to compile the lesson 4 Mote Pc serial Communication and Serial
Forwarder :
> > When i execute java TestSerial, there is an error message wich appears :
[EMAIL PROTECTED]:9002 died - exiting (java.net.ConnectException: Connection
refused).
>
>What platform? (Windows, Linux, Mac) Do you have a firewall? Have you set  up
>your motecom variable? What commands are you using to execute TestSerial?
Are you using the serial forwarder or not?
>
>What version of TinyOS?
>
>--
>The difference between the right word and the almost right word is really a
large matter- it's the difference between a lightning bug and the 
lightning.
>-Twain
>

_
Gagnez des écrans plats avec Live.com http://www.image-addict.fr/



-- 
The difference between the right word and the almost right word is really a
large matter- it's the difference between a lightning bug and the lightning.
-Twain

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


Re: [Tinyos-help] [lesson 4 with tinyOs2.0]

2007-06-05 Thread Peizhao Hu

A common problem that have to be mentioned in the documentation.
possible reasons:
1. if you are using SerialForwarder, make sure your problem is pointing 
to the same port number, which SerialForwarder is outputing to.

you can start your SerialForwarder as

java net.tinyos.sf.SerialForwarder -port 9003 -comm serial@/dev/ttyS0:mica2

then you use use [EMAIL PROTECTED]:9003

2. if you tried to connect from other host rather than localhost, you 
have to make sure the System-wide Environment Variable for "MOTECOM" is 
set to whatever you desired to use.

i.e.: [EMAIL PROTECTED]:PORT
if you look into the TinyOS source code, you will found the JNI function 
tries to get this variable using ENV.getenv("MOTECOM"). It binds to 
default value ([EMAIL PROTECTED]:9002) when it can't resolve the variable. 
for Mac Users, there is a tool, called "RCEnvironment", which allows you 
to add system-wide environment variable (require reboot/logout to take 
effect).



Benjamin Madore wrote:

On Tue, June 5, 2007 10:26 am, vazoumana fofana said:
  

i try to compile the lesson 4 Mote Pc serial Communication and Serial
Forwarder :
When i execute java TestSerial, there is an error message wich appears :
[EMAIL PROTECTED]:9002 died - exiting (java.net.ConnectException: Connection
refused).



What platform? (Windows, Linux, Mac) Do you have a firewall? Have you set up
your motecom variable? What commands are you using to execute TestSerial?
Are you using the serial forwarder or not?

What version of TinyOS?

  


--
regards;

Peizhao

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


[Tinyos-help] MEP-SYS / MoteView 1.2 Problems

2007-06-05 Thread ognjen popovic

Hello,
I work on the MEP-SYS enviromental system from crossbow. With the
enviromental system came the MoteView 1.2.
I tried to change Data Rate of motes.
Beofre that , motes periodically sent their data exactly every 3 minutes.
But when I tried to change the Data Rate to 6 minutes, they lost their
synchronisation , and now some motes are sending data 10 times per minute,
and some almost never.

I tried to reprogramm the Base Station (MBR 410) (with XMesh_Base_lp), but
after some time, led 1 and 2 turned on, and led 3 blinks every 30 seconds.
Does anyone have some experience with these devices, and is there a way I
could return the system into the original state?

I'm not sure how te reprogramm the motes ( MEP 410 and  MEP 510) over the
air, and any instructions would be more then useful.

Regards,

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

Re: [Tinyos-help] sending and receiving packets ->MoteIF, BcastInject, Packetizer...

2007-06-05 Thread Michael Schippling

As far as I know, in T1 at least, Packetizer is used near the bottom
of all of the Java side message I/O, and it presupposes that the
messages are in TOS_Msg (AM) format, which is compatible with
GenericComm on the mote side. If you only want send single bytes
you will have to reinvent both ends of the tube using UARTM on the
motes and raw serial port access on the host.

tools\java\net\tinyos\tools\Send.java is probably the easiest example
of how to open a port and send a message using (after many object oriented
bait-and-switches) Packetizer.java, but it doesn't do any message
initialization and formatting.

tools\java\net\tinyos\tools\BcastInject.java does all the setup and sending
(in a slightly different way of course, why be consistent?) using a "mig"
generated class for the apps\SimpleCmd\SimpleCmdMsg.h message struct.

My code at http://www.etantdonnes.com/Motes/robocode.tar.gz contains
an example of a middle way, using hand coded message classes and the
Send.java type of port usage, both of which I believe to be more
understandable. But that's just me...

For the most part, if you understand 'C' and can wrap your head partially
around object(-dis-)oriented constructs, you shouldn't have too much
trouble muddling through Java code. If you can get (and learn...) an
IDE like Eclipse it helps a lot in navigating code because it can find
definitions for classes that are buried way deep in other peoples projects.

MS




julien falco wrote:

Hi all

I am trying to send packets to a mote (tmote telosB) through another one 
(with TOSBase).


I have seen that there are different options, such as MoteIF, 
Bcastinject, Packetizer...


What I am trying to send and receive are bytes (command for a sensor: 
something like 15 bytes commands). I am confused because there are many 
options, and most of the examples usually just send AM commands.


Can someone help me and redirect me to an easy example ( I don't have 
high java programming skills).


Thanks.




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

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


Re: [Tinyos-help] Tinyos 2 Tutorial 11 Linker Problems

2007-06-05 Thread Philip Levis
As the tutorial states, tmote is not currently supported. So you must  
type make micaz sim.


Phil

On Jun 5, 2007, at 9:24 AM, Marek Jawurek wrote:


Hi everyone,

I cannot get TOSSIM compiled with python support properly on my Debian
system. I have python-dev installed and everything seems fine until  
the

linker is invoked:

I tried 'make tmote sim' in the Blink app directory and got back an
error msg (see below). Apparently a linker error but I have no clues.

Any help is appreciated


Marek


 make tmote sim
mkdir -p build/telosb
  placing object files in build/telosb
  writing XML schema to app.xml
  compiling BlinkAppC to object file sim.o
ncc -c -shared -fPIC -o build/telosb/sim.o -g -O0 -O -tossim
-fnesc-nido-tosnodes=1000 -fnesc-simulate
-fnesc-nido-motenumber=sim_node\(\)   -mdisable-hwmul -Wall -Wshadow
-DDEF_TOS_AM_GROUP=0x7d -Wnesc-all -target=telosb
-fnesc-cfile=build/telosb/app.c -board=  -Wno-nesc-data-race
BlinkAppC.nc   -fnesc-dump=components -fnesc-dump=variables
-fnesc-dump=constants -fnesc-dump=typedefs -fnesc-dump=interfacedefs
-fnesc-dump=tags -fnesc-dumpfile=app.xml
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/TransformCounterC.nc: In
function `TransformCounterC$0$CounterFrom$overflow':
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/TransformCounterC.nc:126:
warning: implicit declaration of function `sim_node'
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc: In
function `__nesc_nido_resolve':
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc:158:
warning: implicit declaration of function `strcmp'
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc: In  
function

`__nesc_nido_initialise':
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:228:  
warning:

passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:229:  
warning:

passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:230:  
warning:

passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:231:  
warning:

passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:232:  
warning:

passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:263:  
warning:

passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:264:  
warning:

passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:270:  
warning:

implicit declaration of function `memcpy'
/data/hiwi/tinyos/tinyos-2.x/tos/interfaces/Scheduler.nc: At top  
level:

/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc:152:
warning: `__nesc_nido_resolve' defined but not used
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:222:  
warning:

`__nesc_nido_initialise' defined but not used
  compiling Python support and C libraries into pytossim.o, tossim.o,
and c-support.o
g++ -c  -shared -fPIC -o build/telosb/pytossim.o -g -O0
-O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx
-I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
-DHAVE_CONFIG_H
g++ -c  -shared -fPIC -o build/telosb/tossim.o -g -O0
-O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/tossim.c
-I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
g++ -c  -shared -fPIC -o build/telosb/c-support.o -g -O0
-O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/hashtable.c
-I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
  linking into shared object ./_TOSSIMmodule.so
g++ -shared -fPIC  build/telosb/pytossim.o build/telosb/sim.o
build/telosb/tossim.o build/telosb/c-support.o -lstdc++  -o
_TOSSIMmodule.so
/usr/bin/ld: build/telosb/sim.o: Relocations in generic ELF (EM: 105)
/usr/bin/ld: build/telosb/sim.o: Relocations in generic ELF (EM: 105)
build/telosb/sim.o: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make: *** [sim-exe] Fehler 1
--
Marek Jawurek <[EMAIL PROTECTED]>

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


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


Re: [Tinyos-help] multihop

2007-06-05 Thread Benjamin Madore

On Tue, June 5, 2007 12:10 pm, Boushra MAALA said:
> hello;
> i want to build a network consists of several clusters. Where, in a cluster,
>  all nodes send their messages to a clusterhead which sends these messages
> to Sink.
> But in addition to that, there is  an exchanging of messages between the
> clusterheads.
> can any body say to me, if  i need to use multihops or i need to tree.
> if i need to multihops, can anybody tell me what is the interface and the
> component which are used for doing the mutlihop cmmunications.
>
>
> note: i work with tinyos 1 and i use TOSSIM1.
>
> thank you for your help.

Perhaps you can modify MultiHop for your cluster-to-clusterhead routing.
Tree I don't have in my 1.x install, and I suspect you mean the tree from
2.x, which will not work with 1.x.

To be quite honest, what you're describing is a new routing protocol instead
of tree or MultiHop. You need to decide if you want to write your own
protocol. You need to ask yourseif questions like: How do I decide the
clusterheads? Is node function static or dynamic? Why am I creating this
protocol, is there an easier way?

-- 
The difference between the right word and the almost right word is really a
large matter- it's the difference between a lightning bug and the lightning.
-Twain

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


[Tinyos-help] Tinyos 2 Tutorial 11 Linker Problems

2007-06-05 Thread Marek Jawurek
Hi everyone, 

I cannot get TOSSIM compiled with python support properly on my Debian
system. I have python-dev installed and everything seems fine until the
linker is invoked:

I tried 'make tmote sim' in the Blink app directory and got back an
error msg (see below). Apparently a linker error but I have no clues.

Any help is appreciated


Marek


 make tmote sim
mkdir -p build/telosb
  placing object files in build/telosb
  writing XML schema to app.xml
  compiling BlinkAppC to object file sim.o
ncc -c -shared -fPIC -o build/telosb/sim.o -g -O0 -O -tossim
-fnesc-nido-tosnodes=1000 -fnesc-simulate
-fnesc-nido-motenumber=sim_node\(\)   -mdisable-hwmul -Wall -Wshadow
-DDEF_TOS_AM_GROUP=0x7d -Wnesc-all -target=telosb
-fnesc-cfile=build/telosb/app.c -board=  -Wno-nesc-data-race
BlinkAppC.nc   -fnesc-dump=components -fnesc-dump=variables
-fnesc-dump=constants -fnesc-dump=typedefs -fnesc-dump=interfacedefs
-fnesc-dump=tags -fnesc-dumpfile=app.xml
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/TransformCounterC.nc: In
function `TransformCounterC$0$CounterFrom$overflow':
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/TransformCounterC.nc:126:
warning: implicit declaration of function `sim_node'
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc: In
function `__nesc_nido_resolve':
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc:158:
warning: implicit declaration of function `strcmp'
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc: In function
`__nesc_nido_initialise':
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:228: warning:
passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:229: warning:
passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:230: warning:
passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:231: warning:
passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:232: warning:
passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:263: warning:
passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:264: warning:
passing arg 1 of `memset' discards qualifiers from pointer target type
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:270: warning:
implicit declaration of function `memcpy'
/data/hiwi/tinyos/tinyos-2.x/tos/interfaces/Scheduler.nc: At top level:
/data/hiwi/tinyos/tinyos-2.x/tos/lib/timer/VirtualizeTimerC.nc:152:
warning: `__nesc_nido_resolve' defined but not used
/data/hiwi/tinyos/tinyos-2.x/tos/chips/msp430/McuSleepC.nc:222: warning:
`__nesc_nido_initialise' defined but not used
  compiling Python support and C libraries into pytossim.o, tossim.o,
and c-support.o
g++ -c  -shared -fPIC -o build/telosb/pytossim.o -g -O0
-O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/tossim_wrap.cxx
-I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
-DHAVE_CONFIG_H
g++ -c  -shared -fPIC -o build/telosb/tossim.o -g -O0
-O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/tossim.c
-I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
g++ -c  -shared -fPIC -o build/telosb/c-support.o -g -O0
-O  /data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim/hashtable.c
-I/usr/include/python2.5 -I/data/hiwi/tinyos/tinyos-2.x/tos/lib/tossim
  linking into shared object ./_TOSSIMmodule.so
g++ -shared -fPIC  build/telosb/pytossim.o build/telosb/sim.o
build/telosb/tossim.o build/telosb/c-support.o -lstdc++  -o
_TOSSIMmodule.so
/usr/bin/ld: build/telosb/sim.o: Relocations in generic ELF (EM: 105)
/usr/bin/ld: build/telosb/sim.o: Relocations in generic ELF (EM: 105)
build/telosb/sim.o: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make: *** [sim-exe] Fehler 1
-- 
Marek Jawurek <[EMAIL PROTECTED]>

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


Re: [Tinyos-help] can't compile MultihopOscilloscope for telosa

2007-06-05 Thread Philip Levis

On Jun 5, 2007, at 8:31 AM, Ákos Maróy wrote:


when I try to compile the MultihopOscilloscope sample app from the
TinyOS 2.0.1 samples, I get the following error:

$ make telos install.0 bsl,/dev/ttyUSB0
mkdir -p build/telosa
compiling MultihopOscilloscopeAppC to a telosa binary
ncc -o build/telosa/main.exe -Os -O -mdisable-hwmul -Wall -Wshadow
-DDEF_TOS_AM_GROUP=0x7d -Wnesc-all -target=telosa
-fnesc-cfile=build/telosa/app.c -board=
-I/usr/src/tinyos-2.x/tos/lib/net/ -I/usr/src/tinyos-2.x/tos/lib/ 
net/lqi

 MultihopOscilloscopeAppC.nc -lm
msp430-ld: address 0xb99 of build/telosa/main.exe section .bss is not
within region data
msp430-ld: address 0xb99 of build/telosa/main.exe section .noinit  
is not

within region data
make: *** [exe0] Error 1


It's allocating too much RAM for the telosa.

Compiling for telosb, it looks like the app is allocating 3K of RAM.  
2K of this is in PoolP, which is the component that allocates packets  
for queues. The default forwarding queue for routing is 12 (it should  
probably be smaller), the UART queue is 10, and most importantly, the  
debugging system has a queue of 20.  The first is defined in tos/lib/ 
net/Ctp/CtpP.nc while the second and third are defined in   
MultihopOscilloscopeAppC.nc.


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


Re: [Tinyos-help] [lesson 4 with tinyOs2.0]

2007-06-05 Thread Benjamin Madore

On Tue, June 5, 2007 10:26 am, vazoumana fofana said:
> i try to compile the lesson 4 Mote Pc serial Communication and Serial
> Forwarder :
> When i execute java TestSerial, there is an error message wich appears :
> [EMAIL PROTECTED]:9002 died - exiting (java.net.ConnectException: Connection
> refused).

What platform? (Windows, Linux, Mac) Do you have a firewall? Have you set up
your motecom variable? What commands are you using to execute TestSerial?
Are you using the serial forwarder or not?

What version of TinyOS?

-- 
The difference between the right word and the almost right word is really a
large matter- it's the difference between a lightning bug and the lightning.
-Twain

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


[Tinyos-help] multihop

2007-06-05 Thread Boushra MAALA
hello;
i want to build a network consists of several clusters. Where, in a cluster,  
all nodes send their messages to a clusterhead which sends these messages to 
Sink.
But in addition to that, there is  an exchanging of messages between the 
clusterheads. 
can any body say to me, if  i need to use multihops or i need to tree.
if i need to multihops, can anybody tell me what is the interface and the 
component which are used for doing the mutlihop cmmunications.


note: i work with tinyos 1 and i use TOSSIM1.

thank you for your help.

   
-
Got a little couch potato? 
Check out fun summer activities for kids.___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] the TinyOS 2 serial protocol

2007-06-05 Thread David Gay

On 6/4/07, Ákos Maróy <[EMAIL PROTECTED]> wrote:

David Gay wrote:
> As the previous mails mentioned, our experience so far is that
> "working properly" and "using JavaComm" have not been a good
> combination. Fixing the issue in TOSComm is probably easier (at a
> guess, from the discussion, I would guess there's a 64-bit-related bug
> - the code is clearly working fine for a bunch of other people, who
> probably are using 32-bit OSes).

well, I have used JavaComm for various purposes, such as reading GPS
information through the NMEA-183 protocol, or control industrial scale
automation systems controlling robots using the 3964r protocol. All this
on various platoforms (Linux x86 and MacOS X on G4), and it all worked fine.


Well the earlier state was:
- you had to install it separately from Java itself (so one more install step)
- if I'm not misremembering, Sun's version didn't support Linux for a long time
- closing ports tended to hang (can't remember which version)
- IBM's version for Linux only supported devices names /dev/ttySn (USB
serial port? What's that?), plus the package was hard to find and
tended to move around...



Whereas now I get either segfaults, or if I don't get them, it still
doesn't work.

It's also probably safe to say that the penetration of JavaComm is wider
than TOSComm, and therefore it's more thoroughly tested and verified for
reliability. I would also argue that even though you might have had a
bad experience with some JavaComm implementations, it might have been an
overkill designing a new interface for this purpose.

But anyway - as you guys know the TinyOS codebase a lot better - where
would I replace TOSComm in the Java code with JavaComm? Should I
re-implement the TOSSerial object to use JavaComm calls instead of the
JNI ones? Or create another object implementing the SerialPort
interface, and make sure that's used all over the code?


You just need to replace net/tinyos/packet/SerialByteSource.java. And,
conveniently, there's already a javacomm implementation, in
tinyos-1.x/tools/java/net/tinyos/packet/SerialByteSource.java (get it
from sourceforge CVS if you don't have tinyos 1.x installed), which by
the look of it should just function as is...

David Gay

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


Re: [Tinyos-help] how to run the application in an endless loop on mica2

2007-06-05 Thread Benjamin Madore
init() and start() are only called once by TinyOS.

On Tue, June 5, 2007 5:21 am, Vipin Kashyap said:
> I am writing an application for High Frequency Sampling and wireless data
> transfer. The whole logic of the app works well for one pass, but at the
> end of the pass it does not iterate any further.
>
> StdControl.init() and start() are as below-
>
> command result_t StdControl.init() {
> call Leds.init();
>   call ADCControl.init();
>   {call AllocationReq.request(MAX_SAMPLES * sizeof(sample_t));
>   dbg(DBG_USR1, "MESSAGE: Allocation Req sent\n");}
>   return SUCCESS;
>   }
>
>
>   command result_t StdControl.start() {
>   dbg(DBG_USR1, "MESSAGE: Entered StdControl.start\n");
>   return SUCCESS;
>   }
>
> At the end of the first pass I am calling StdControl.init(). But after
> this the usual  AllocationReq.requestProcessed() does not fire.
>
> Where am I going wrong.

You ought to be posting a task in start() that does your sampling that you
can either call again from a done() signal, or that calls a second task
whose job is to repost the first task.

(You shouldn't repost a task in itself, as it may fail because the task is
already posted and running, and a task can only be posted once in the
queue.)

You may also want to set up a timer that you initiate from start() and use
that to do your sampling.

Either way, I believe there is some posted code in the archives that does
high-speed sampling. Be sure to read them. Searching for "speed" as a title
keyword would be a good start.

-- 
The difference between the right word and the almost right word is really a
large matter- it's the difference between a lightning bug and the lightning.
-Twain

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


[Tinyos-help] can't compile MultihopOscilloscope for telosa

2007-06-05 Thread Ákos Maróy
when I try to compile the MultihopOscilloscope sample app from the
TinyOS 2.0.1 samples, I get the following error:

$ make telos install.0 bsl,/dev/ttyUSB0
mkdir -p build/telosa
compiling MultihopOscilloscopeAppC to a telosa binary
ncc -o build/telosa/main.exe -Os -O -mdisable-hwmul -Wall -Wshadow
-DDEF_TOS_AM_GROUP=0x7d -Wnesc-all -target=telosa
-fnesc-cfile=build/telosa/app.c -board=
-I/usr/src/tinyos-2.x/tos/lib/net/ -I/usr/src/tinyos-2.x/tos/lib/net/lqi
 MultihopOscilloscopeAppC.nc -lm
msp430-ld: address 0xb99 of build/telosa/main.exe section .bss is not
within region data
msp430-ld: address 0xb99 of build/telosa/main.exe section .noinit is not
within region data
make: *** [exe0] Error 1


did anyone else encounter this issue? the other samples seem to compile
/ work fine...
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


[Tinyos-help] which sensor objects to use for the TmoteSky?

2007-06-05 Thread Ákos Maróy
I'm looking at this page:

http://www.moteiv.com/community/Getting_Data_from_Tmote_Sky%27s_Sensors


and trying to find out what nesC Sensor objects to use for the specific
sensors. So far I figured out the following:

- DemoSensorC: the internal voltage sensor
- HamamatsuS10871TsrC: the photo-sensor
- SensirionSht11C.Temperature and SensirionSht11C.Humidity: for the
'external' temperature and humidity sensor. but I always get a maximum
(0x) reading from these... should I put some extra hardware to the
mote to use this one?
- the page writes about an internal temperature sensor - how would one
read from this?


Akos

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


[Tinyos-help] [CC2420_lpl] What happens when the duty cycle expires in the middle of a receiving a packet?

2007-06-05 Thread John Hendrie

Hi,

I know it's a bit of an edge case, but what happens when the duty
cycle expires in the middle of a receiving a packet using the LPL
stack in TinyOS 2.0?
___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


RE: [Tinyos-help] [lesson 4 with tinyOs2.0]

2007-06-05 Thread Firat TARAKTAS
 
Hi,

1. Did you run the command like "java TestSerial -comm [EMAIL PROTECTED]:telos" 
 or assign MOTECOM correctly?
2. Be sure that other running programs on your PC does not use your port.

Firat TARAKTAS


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of vazoumana fofana
Sent: Tuesday, June 05, 2007 5:26 PM
To: tinyos-help@Millennium.Berkeley.EDU
Subject: [Tinyos-help] [lesson 4 with tinyOs2.0]

Hi,

i try to compile the lesson 4 Mote Pc serial Communication and Serial Forwarder 
:
When i execute java TestSerial, there is an error message wich appears :
[EMAIL PROTECTED]:9002 died - exiting (java.net.ConnectException: Connection 
refused).
somebody can help me , please ?

thanks.

_
Avec Windows Live OneCare éliminez tous les virus de votre PC ! 
http://www.windowslive.fr/liveonecare/default.asp

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

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


[Tinyos-help] [lesson 4 with tinyOs2.0]

2007-06-05 Thread vazoumana fofana

Hi,

i try to compile the lesson 4 Mote Pc serial Communication and Serial 
Forwarder :

When i execute java TestSerial, there is an error message wich appears :
[EMAIL PROTECTED]:9002 died - exiting (java.net.ConnectException: Connection 
refused).

somebody can help me , please ?

thanks.

_
Avec Windows Live OneCare éliminez tous les virus de votre PC ! 
http://www.windowslive.fr/liveonecare/default.asp


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


[Tinyos-help] sending and receiving packets ->MoteIF, BcastInject, Packetizer...

2007-06-05 Thread julien falco

Hi all

I am trying to send packets to a mote (tmote telosB) through another one
(with TOSBase).

I have seen that there are different options, such as MoteIF, Bcastinject,
Packetizer...

What I am trying to send and receive are bytes (command for a sensor:
something like 15 bytes commands). I am confused because there are many
options, and most of the examples usually just send AM commands.

Can someone help me and redirect me to an easy example ( I don't have high
java programming skills).

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

[Tinyos-help] how to run the application in an endless loop on mica2

2007-06-05 Thread Vipin Kashyap
Hi all !

I am writing an application for High Frequency Sampling and wireless data
transfer. The whole logic of the app works well for one pass, but at the
end of the pass it does not iterate any further.

StdControl.init() and start() are as below-

command result_t StdControl.init() {
call Leds.init();
call ADCControl.init();
{call AllocationReq.request(MAX_SAMPLES * sizeof(sample_t));
dbg(DBG_USR1, "MESSAGE: Allocation Req sent\n");}
return SUCCESS;
  }


  command result_t StdControl.start() {
dbg(DBG_USR1, "MESSAGE: Entered StdControl.start\n");
return SUCCESS;
  }

At the end of the first pass I am calling StdControl.init(). But after
this the usual  AllocationReq.requestProcessed() does not fire.

Where am I going wrong.

Please help.

Thanks and regards,
-- 
Vipin Kashyap


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


RE: [Tinyos-help] Reducing data loss in Oscilloscope application

2007-06-05 Thread Firat TARAKTAS
Hi Ferry,
 
I faced a problem similar to you this morning. Every timer fired, ı tried to 
read three ADC channel. It sent only the first readings, but not the other two 
channel readings. I solved it by using a integer named sequence. After the 
single ADC reading, i increment it and decide whose turn it is. 
 
 
if sequence % 3 == 0
read ADC1;
else if sequence % 3 ==1
read ADC2;
else if sequence % 3 ==2
read ADC3;
 
 
event void Read1.readDone()
{
getData;
sequnce ++;
}
 
 
It solved my problem. You may say that it lowers reading frequency. You are 
right, but decreasing the timer interval will compensate i think.
 
Note: Since websense does not let, i could not see the screenshots.
 

Firat TARAKTAS

 



From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ferry Cialis
Sent: Tuesday, June 05, 2007 11:46 AM
To: tinyos-help@Millennium.Berkeley.EDU
Subject: [Tinyos-help] Reducing data loss in Oscilloscope application


Hello,

I've a question about data transfer loss that I need help in. Firstly, I'm 
trying to get 2 different sensor readings. The sensor readings are 
Accelerometer X-direction and Accelerometer Y-direction. Previously, I managed 
to get both sensor readings from 2 motes i.e. each motes has each sensor and 
both transmit the sensor data to TOSBASE to be displayed over via Serial 
Forwarder to Oscilloscope GUI. The link below shows a screenshot of the result:

http://i194.photobucket.com/albums/z154/ferrycia/Oscilloscope2.jpg

As seen, the green one is the Accelerometer X sensor readings in a mote in 
channel 1 while the red one is Accelerometer Y in another mote in channel 2. 
The result seems ok. 

Next, I tried to get both of the sensor readings into a single mote to improve 
efficiency. I've modified the code a bit to separate the channels. The sensor 
was mounted on top of a mote and the same procedures with Serial Forwarder and 
Oscilloscope were done. The link below sows the result: 

http://i194.photobucket.com/albums/z154/ferrycia/Oscilloscope1.jpg 

As seen, the red one which represented channel 2 had plenty of data loss and 
the reading for it was patchy and intermittent but the green one for channel 1 
runs as usual. Also, channel 2 readings 

Is the problem lies in the loss data transfer when I tried to transmit 2 (or 
more) sensor readings from the same mote ? How do I correct or optimise the 
method ? Do I need to change anything for the Oscilloscope or TOSBASE code ? 
Please advise me clearly in the matter as I'm quite at loss 

Thank you for the attention,
yours,
Ferry

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

Re: [Tinyos-help] The multi-hop implementation related to Deluge in Tinyos-1.x

2007-06-05 Thread Micfox Micfox





From: Philip Levis <[EMAIL PROTECTED]>
To: Micfox Micfox <[EMAIL PROTECTED]>
CC: tinyos-help@Millennium.Berkeley.EDU
Subject: Re: [Tinyos-help] The multi-hop implementation related to Deluge 

in Tinyos-1.x

Date: Mon, 4 Jun 2007 22:03:05 -0700

On Jun 4, 2007, at 9:01 PM, Micfox Micfox wrote:


Hi,

 As Deluge is supporting multi-hop reprogramming, I wondered which 
 part of the code is doing the multi-hop forwarding for the newer  
packets or pages.For example,


assume node A (installed with TOSBase)is attached with PC, while  
node B and node C (Both installed with DelugeBasic) are deployed in 
 one-hop distance and two-hop distance to Node A. Node B should  
forward the image to Node C, right? I searched  
DelugePageTransferM.nc and can only find one place with the most  
relevant line (I think) in DataRead.readDone():


if (call SendDataMsg.send(nodeAddr, sizeof(DelugeDataMsg), pMsgBuf) 
 == FAIL)

 call Timer.start (TIMER_ONE_SHOT, DELUGE_FAILED_SEND_DELAY);

However, If I attempted to modify this line (with some intentional  
bugs), instead of the forwarding malfunctioning, Ping is not  
working (from PC via Node A) and freezed on "Getting data for image 
 [0]..." I figured  the above line in Node B might send the image  
to  Node A  rather than sending image to Node C.


  The point is that if Deluge supports multi-hop image  
dissemination, there must be somewhere in the code that do the  
forwarding I could not find it so far and I wondered if you  
know where is that part doing the multi-hop forwarding.


  I checked your Network Programming manual but I could not find  
anything related to the above question..




I'd recommend reading the Deluge paper.

Basically, Deluge disseminates a single hop at a time. When a node  
fully receives a page, it can advertise the page and send it along 
to  the next hop.


Thanks for your reply. That is exactly what I need to know (code-wise not 
paper-wise), so that I can match the part in the code to the respective 
part in the paper: 
 "disseminate the page in a single hop" - it is the match to "writeData()" 
call in ReceiveDataMsg.receive(TOS_MsgPtr pMsg).


What I need to find out is the part in the code matches the description 
"send it along 
to  the next hop".






Phil


_
享用世界上最大的电子邮件系统― MSN Hotmail。  http://www.hotmail.com  


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


[Tinyos-help] Reducing data loss in Oscilloscope application

2007-06-05 Thread Ferry Cialis

Hello,

I've a question about data transfer loss that I need help in. Firstly, I'm
trying to get 2 different sensor readings. The sensor readings are
Accelerometer X-direction and Accelerometer Y-direction. Previously, I
managed to get both sensor readings from 2 motes i.e. each motes has each
sensor and both transmit the sensor data to TOSBASE to be displayed over via
Serial Forwarder to Oscilloscope GUI. The link below shows a screenshot of
the result:

http://i194.photobucket.com/albums/z154/ferrycia/Oscilloscope2.jpg

As seen, the green one is the Accelerometer X sensor readings in a mote in
channel 1 while the red one is Accelerometer Y in another mote in channel 2.
The result seems ok.

Next, I tried to get both of the sensor readings into a single mote to
improve efficiency. I've modified the code a bit to separate the channels.
The sensor was mounted on top of a mote and the same procedures with Serial
Forwarder and Oscilloscope were done. The link below sows the result:

http://i194.photobucket.com/albums/z154/ferrycia/Oscilloscope1.jpg

As seen, the red one which represented channel 2 had plenty of data loss and
the reading for it was patchy and intermittent but the green one for channel
1 runs as usual. Also, channel 2 readings

Is the problem lies in the loss data transfer when I tried to transmit 2 (or
more) sensor readings from the same mote ? How do I correct or optimise the
method ? Do I need to change anything for the Oscilloscope or TOSBASE code ?
Please advise me clearly in the matter as I'm quite at loss

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

Re: [Tinyos-help] the TinyOS 2 serial protocol

2007-06-05 Thread Urs Hunkeler
Hi Ákos,

> But anyway - as you guys know the TinyOS codebase a lot better - where
> would I replace TOSComm in the Java code with JavaComm? Should I
> re-implement the TOSSerial object to use JavaComm calls instead of the
> JNI ones? Or create another object implementing the SerialPort
> interface, and make sure that's used all over the code?

I once ported the net.tinyos.comm classes to J2ME and its specific way
of accessing the serial port. As far as I remember I mainly had to
change the TOSSerial class and it was surprisingly easy to do (change
SerialInputStream and SerialOutputStream). However I wouldn't know if
there was an "official" way of implementing an alternative communication
mechanism.

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


Re: [Tinyos-help] sending packets via Tython

2007-06-05 Thread Faisal Karim
Hi Sarfaraz

Thanks again. But how to set the sender ID for comm.sendRadioMessage() coz 
three arguments accepted by this method dont specify who is sender.

Looking forward for your early reply
 
Regards 
Faisal Karim 

   



- Original Message 
From: Sarfraz Nawaz <[EMAIL PROTECTED]>
To: Faisal Karim <[EMAIL PROTECTED]>
Cc: tinyos help 
Sent: Tuesday, June 5, 2007 2:51:49 AM
Subject: Re: [Tinyos-help] sending packets via Tython

Its the simulation environment that is sending the packets not the base station 
node. Though you can set the sender ID to be 0 and have the receiving node 
believe that the packet came from node 0.


On 6/4/07, Faisal Karim <[EMAIL PROTECTED]> wrote: 
Hi Sarfaraz 

Thanks for reply. Thats true but "who" is using these methods 
(comm.sendRadioMessage() and comm.sendUARTMessage() ) to send messages to any 
node. I assume its base station ie node 0.

Im looking forward to send messages from specific node. Lets say node 2 send 
message to node 10. How we can do by using Tython.

Thanks in advance. 
Looking Forward 

 
Regards 
Faisal Karim 






- Original Message 
From: Sarfraz Nawaz < [EMAIL PROTECTED]>
To: Faisal Karim <[EMAIL PROTECTED]>
Cc: tinyos help 
Sent: Sunday, June 3, 2007 6:12:12 AM
Subject: Re: [Tinyos-help] sending packets via Tython 

comm.sendRadioMessage() and comm.sendUARTMessage() are used to send a packet to 
"any" node in the network on the uart and radio respectively.


On 6/1/07, Faisal Karim < [EMAIL PROTECTED] > wrote:
Hi All

Im looking forward to send packets from specific node in simulation via Tython. 
In Tython manual it is described to send using moteIF(), but what i understand 
this is to send some msg from base station ie some serial port. To send to base 
station there is a method comm.sendUARTMessage(), also there is 
comm.sendRadioMessage() which im assuming to send msg from base station to 
specific node via radio as this method do not describe which node is sending 
the message.

any comments and help will be highly appreciated

 
Regards 
Faisal Karim 






Get the Yahoo! toolbar and be alerted to new email wherever you're surfing. 

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








Get the free Yahoo! toolbar and rest assured with the added security of spyware 
protection.


 

No need to miss a message. Get email on-the-go 
with Yahoo! Mail for Mobile. Get started.
http://mobile.yahoo.com/mail ___
Tinyos-help mailing list
Tinyos-help@Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Re: [Tinyos-help] the TinyOS 2 serial protocol

2007-06-05 Thread Ákos Maróy
David Gay wrote:
> As the previous mails mentioned, our experience so far is that
> "working properly" and "using JavaComm" have not been a good
> combination. Fixing the issue in TOSComm is probably easier (at a
> guess, from the discussion, I would guess there's a 64-bit-related bug
> - the code is clearly working fine for a bunch of other people, who
> probably are using 32-bit OSes).

well, I have used JavaComm for various purposes, such as reading GPS
information through the NMEA-183 protocol, or control industrial scale
automation systems controlling robots using the 3964r protocol. All this
on various platoforms (Linux x86 and MacOS X on G4), and it all worked fine.

Whereas now I get either segfaults, or if I don't get them, it still
doesn't work.

It's also probably safe to say that the penetration of JavaComm is wider
than TOSComm, and therefore it's more thoroughly tested and verified for
reliability. I would also argue that even though you might have had a
bad experience with some JavaComm implementations, it might have been an
overkill designing a new interface for this purpose.

But anyway - as you guys know the TinyOS codebase a lot better - where
would I replace TOSComm in the Java code with JavaComm? Should I
re-implement the TOSSerial object to use JavaComm calls instead of the
JNI ones? Or create another object implementing the SerialPort
interface, and make sure that's used all over the code?


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