[Tinyos-help] Transmisison delay 32khz Timer precision in telosb mote

2012-04-06 Thread Han Bin

Dear everybody,

1. I'm implementing MAC protocol on tinyOS 2.1 and telosb mote. I use
AMSend/ActiveMessageC interface to send and receive messages. There is no
collision because only one node sends message to another node. I also
disable initial backoff  by calling command call
SubBackoff.setCongestionBackoff(0)  in async event void
SubBackoff.requestCongestionBackoff(message_t *msg) in CC2420CsmaP.nc
 I measure the total transmission delay by calculating the time passed from
call send.send event to Send.senddone event (with ACK enable). The delay is
constant about 12 ms.
But my packet length is about 100 byte, so the delay may be about 100*8 /
250 kbps = 3.2 ms (plus ACK transmission delay). Why is the delay time so
long in my case? it might be CCA enabled. What is the delay time of CCA?

2. To disable CCA, I use setCca(FALSE) in CC2420CsmaP.nc as the Tep126
instruction

async event void SubBackoff.requestCca(message_t *msg) {
// Lower layers than this do not configure the CCA settings
RadioBackoff.setCca(FALSE)
signal RadioBackoff.requestCca(msg);
  }
Is it correct or not?

3. I want to use CSMA with one kind of message and don't use CSMA with
another type of message. How can I do like this?

4. For timers, I see that TinyOS provides TMilli timer by default, but I
don't know how to use Timer with 32kHz precision. I can use LocalTime32kHz)
to get the current time with 32kHz precision.
// HilTimerMilliC component
configuration HilTimerMilliC
{
  provides interface Init;
  provides interface TimerTMilli as TimerMilli[ uint8_t num ];
  provides interface LocalTimeTMilli;
}
How can I use Timer with 32kHz precision?
Thank you for any reply. I'm looking forward to your comments!

Best regards,
Bin
-- 
View this message in context: 
http://old.nabble.com/Transmisison-delay---32khz-Timer-precision-in-telosb-mote-tp33598688p33598688.html
Sent from the TinyOS - Help mailing list archive at Nabble.com.

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


Re: [Tinyos-help] help lesson 4 - The java class is not found: TestSerial

2012-04-06 Thread tifenn . rault
Hello everyone

Thanks a lot to Michael, Varun, Janos, Andris and Prasanth for their  
quick responses.

I finally get it.In fact, there were two problems.

1) My JNI files were not correctly installed.
This was because :

A) I had to modify the tos-install-jni file to change the uname and  
the group.
* I obtained uname by typing $ uname in cygwin. For me it is  
CYGWIN_NT-6.1-WOW64.
So at line 13 : [`uname` = Darwin] became [ `uname` =  
CYGWIN_NT-6.1-WOW64 ]
* I obtained the group by typing $ id in cygwin. For me the gid 
is 513.
So at line 16 and 29 : install --group=SYSTEM became install 
--group=513

B) tos-install-jni tried to access the directory C:\Program Files  
(x86)\Java\jdk1.7.0_03\jre\bin to install getenv.dll and toscomm.dll.  
However, in windows the directory were read-only. So, I changed  
permissions and tos-install-jni ran correctly.

2) I had to use the command
java -classpath `cygpath -wp  
.:/cygdrive/c/cygwin/opt/tinyos-2.x/support/sdk/java/tinyos.jar`   
TestSerial
to launch the application. Without the . it wasn't looking in the  
current directory even if I were in the directory.

Best regards,

Tifenn





Prasanth P prasanthh...@gmail.com a écrit :

 Hi,

   I have faced the same problem and solved. One thing is you might not have
 compiled your java files. Go inside /tinyos-x.x/support/sdk/java folder and
 give command make.

   If that itself is not working  try following
 (a) Download java tar file from the Tiny OS CVS repository:
 http://tinyos.cvs.sourceforge.net/viewvc/tinyos/tinyos-2.x/support/sdk/java/
   (b) Untar and keep it in /opt/tinyos-2.1.0/support/sdk instead of
 existing java folder there.
   (c) Go inside the java folder in terminal and give make command.

 This is how i solved the issue. May be this will help you.

 On Tue, Mar 27, 2012 at 11:28 PM, Bíró, András andras.b...@unicomp.huwrote:

 Hi,

 I think the windows CLASSPATH format is different: It uses ;
 (semicolon) instead of : (colon), and \ (backslash) instead of /
 (slash).

 Andris

 On Tue, Mar 27, 2012 at 4:35 PM,  tifenn.ra...@etu.utc.fr wrote:
 
  Dear all,
 
  I try to follow the tinyos-2.x tutorial in lesson 4: Mote-PC serial
  Communication. I successfully compiled and installed the TestSerial
  application on telosb mote.
 
  However, when I type in the TestSerial directory:
 
  java TestSerial
 
  I get:
 
  The java class is not found:  TestSerial
 
 
  The current directory and the tinyos.jar are included in the CLASSPATH
  as it points to:
 
 .:C:/cygwin/opt/tinyos-2.x/support/sdk/java/tinyos.jar:C:/cygwin/opt/tinyos-2.x/support/sdk/java
 
  The TestSerial.class and TestSerialMsg.class were generated in the
  TestSerial directory.
 
  I am using Cygwin on Windows 7.
 
  I hope someone can help me.
  Thanks a lot in advance.
  Tifenn
 
 
 
 
  
  This message was sent using IMP, the Internet Messaging Program.
 
 
  ___
  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




 --
 Regards
 Prasanth.P






This message was sent using IMP, the Internet Messaging Program.


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


Re: [Tinyos-help] Ctp

2012-04-06 Thread Omprakash Gnawali
On Wed, Feb 29, 2012 at 7:59 PM, yanzhi zeng zengyan...@gmail.com wrote:
 Hi,
 who has a demo that uses Ctp protocol, I want to learn how to use Ctp.

This is a good place to start:
http://docs.tinyos.net/tinywiki/index.php/Network_Protocols

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


[Tinyos-help] Information about how to use Hash functions in NesC

2012-04-06 Thread abel freijo
Hello,

I'm new here, my name is Abel and I am a final year student of Computer
Engineering, and my final degree project is related to sensor networks, so
lately I'm looking for information about this issue.

I am writing to you because I have a problem, I need to know how to apply
Hash functions programming in nesC?

I have read about the MessageDigest, HASH  and MessageDigestInfo
interfaces, but
can not find information of their implementation.

I'll be so thankful  if you can help me with any information on the subject.

Thank you in advance.

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

Re: [Tinyos-help] Information about how to use Hash functions in NesC

2012-04-06 Thread Eric Decker
nesC is a superset of C.   So if you know how to work with hash functions
in C then you should be golden.

If that still doesn't make sense then you are out of luck and your question
is beyond the scope of this list (its too basic, it's like how do I program
such and such a function in C).



On Fri, Apr 6, 2012 at 5:16 PM, abel freijo abel.fre...@gmail.com wrote:

 Hello,

 I'm new here, my name is Abel and I am a final year student of Computer
 Engineering, and my final degree project is related to sensor networks, so
 lately I'm looking for information about this issue.

 I am writing to you because I have a problem, I need to know how to apply
 Hash functions programming in nesC?

 I have read about the MessageDigest, HASH  and MessageDigestInfo
 interfaces, but can not find information of their implementation.

 I'll be so thankful  if you can help me with any information on the
 subject.

 Thank you in advance.

 Regards

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




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

Re: [Tinyos-help] Low duty-cycled Trickle protocol

2012-04-06 Thread Gary Lee
I am wondering what kind of time synchronization (working schedule)
sensor nodes have in Collection Tree protocol?

As stated in CTP paper, Trickle is used for adaptive beaconing.
Suppose node A and node B are neighbors. Nodes A is about to send a
beacon when Trickle timers expires. However, node B is sleeping then.
What shall node A do?

Thanks.


On 4/4/12, Omprakash Gnawali gnaw...@cs.uh.edu wrote:
 On Tue, Apr 3, 2012 at 11:15 AM, Gary Lee gary.lee1...@gmail.com wrote:
 Hi,

 Trickle protocol is used for data dissemination. The original Trickle
 paper
 assumes sensor nodes are always on.

 I am wondering is there some paper/TinyOS implementation that is about
 Trickle on low-duty-cycled sensor networks?

 CTP uses Trickle and works with duty-cycled radios. That might be a
 good place to start.

 - om_p

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