// Enable debug prints
#define MY_DEBUG

// Enable passive mode
#define MY_PASSIVE_NODE
#define MY_REPEATER_FEATURE

// Passive mode requires static node ID
#define MY_NODE_ID 100

// Enable and select radio type attached
#define MY_RADIO_NRF24
#define MY_RF24_PA_LEVEL RF24_PA_HIGH

//#define MY_RADIO_NRF5_ESB
//#define MY_RADIO_RFM69
//#define MY_RADIO_RFM95

#include <MySensors.h>

#define CHILD_ID 0   // Id of the sensor child

// Initialize general message
MyMessage msg(CHILD_ID, V_TEMP);

void setup()
{
}

void presentation()
{
  // Send the sketch version information to the gateway and controller
  sendSketchInfo("Passive node", "1.0");

  // Register all sensors to gw (they will be created as child devices)
  present(CHILD_ID, S_TEMP);
}

void loop()
{
  // generate some random data
  send(msg.set(25.0+random(0,30)/10.0,2));
  wait(10000);
}
