Specify which node should turn off

39 views
Skip to first unread message

andrerica...@gmail.com

unread,
Jun 18, 2021, 8:35:49 AM6/18/21
to Castalia Simulator
https://stackoverflow.com/questions/68035234/specify-which-node-should-turn-off

Hello friends,
I'm trying to simulate a sensor network in Castalia, where each radio works with a different duty cycle. I'm controlling the radio by the application, through the commands toRadioLayer(createRadioCommand(SET_STATE,SLEEP)) to turn off and toNetworkLayer(createRadioCommand(SET_STATE,RX)) to turn on. However, as each radio has its own schedule, I need to send this command to a specific radio. Is it possible to define for which node these commands, or another if it exists, are executed?

andres...@id.uff.br

unread,
Jun 21, 2021, 8:26:01 AM6/21/21
to Castalia Simulator
Being more specific, I'm using the command toNetworkLayer(createRadioCommand(SET_STATE,SLEEP)) to turn off the radios (it turns off all nodes but 0 (sink)), however I need to turn off only one or another specific radio and sink. For example, in a network with 5 nodes (0,1,2,3,4 and 5), I wanted to turn off radio 0 and 2 at a certain point in time. I tried using the same command, passing the node value (toNetworkLayer(createRadioCommand(SET_STATE,SLEEP),,"0")), but it didn't go through make.
I didn't find another reference in the manual. If it is not possible to switch between network nodes, would it be possible to turn the sink on and off (node 0)?
Please kindly ask for your help.
Reply all
Reply to author
Forward
0 new messages