From my reading of the referenced page it looks like the
xml file is used to define storage areas -- like files --
in the external EEPROM, but it doesn't address initializing
the contents prior to running your program.

You could implement a message to send and store your key.
I don't know if there is any erase of external EEPROM done
when a device is programmed, so the contents _might_ persist
across new downloads and thus you would only have to do
the message thing once.

Another possibility is that there is a small internal EEPROM
area on each controller. In T1 one accessed this using the
InternalFlashC component -- which has probably changed names
in T2. This memory _is_ erased but can be initialized at
download time. I don't think TOS has implemented any method
to do this so you would have to dig through the controller
and download utilities to figure out how to do it.

MS


Markus Niedermann wrote:
> Hey!
> Im using tinyos 2.1.1 at micaZ and iris nodes.
> 
> I use ECDH to get a secret key for a symmetric encryption between nodes 
> and with the PC.
> For saving time, I pregenerate my public / private keys at the PC.
> First, I hard-coded them as uint8_t- arrays in the code.
> The configuration is should be installed at different nodes with 
> different keys.
> Now I want to save the 160-bit-keys at the external flash of my nodes.
> How should I handle this?
> The TinyOS-Page seems to be partially offline, so I can't get all 
> Information I need.
> 
> http://docs.tinyos.net/tinywiki/index.php/Storage
> I read this tutorial.
> I'm not quite sure how I have to configure the xml file.
> 
> I guess I have to write a second application, that I use to save the 
> keys on my nodes, right? Or is there a way to save something directly 
> over the serial interface?
> 
> Thanks for your help!
> Markus
> _______________________________________________
> 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

Reply via email to