All the TinyOS functions are static (i.e. private) and cannot be
accessed outside a module. However, you can define a public function
using special attributes and that function could be called from your C
code and vica versa.
If you want to have a public function inside a TinyOS module then use
following attribute.
void publicFunctionInTinyOSModule() __attribute((C,spontaneous)) {
}
Once you have a public function in a module then it can call any static
(private) functions of the module and you can pass any parameters you wish.
Faisal
Kostantinos Katsaros wrote:
> Hi there,
>
> I use the BlinkRadio example for tinyOS 2.x which has been modified
> and is pure C (no nesC) and I want to pass a parameter from the
> application layer to the HAL which uses nesC. This parameter may
> change per packet. Is there a function that I can use or how can I
> develop one ?
>
> Thank you
> --
> Katsaros Konstantinos
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Tinyos-help mailing list
> [email protected]
> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help