#ifndef MAIN_H #define MAIN_H // Define the following if using for base station //#define BASESTATION_PROG #define REMOTEDEVICE_PROG #define DEVICEADDR 'Q' // Base station states // Wait for a command to arrive on the serial port #define BS_WAITSERIAL_S 0 // Process the command including any transmissions over RF #define BS_PROCCMD_S 1 // Wait for a response from the target device #define BS_WAITRESP_S 2 // Once response is received, print on serial and wait for next cmd // Remote device states // Wait for a message to arrive on the RF link #define RD_AUTO_S 0 // Process transmitting response #define RD_MANUAL1_S 1 // Process receiving response #define RD_MANUAL2_S 2 // After the message is processed and transmitted, wait for next cmd void initialize(); // Interpret received command, either from RF or USART void interpretCommand(); int main(); #endif