Changed initialization order of radio/eth to avoid problems.
This commit is contained in:
@@ -83,14 +83,14 @@ int inputPos = 0;
|
|||||||
|
|
||||||
void setup()
|
void setup()
|
||||||
{
|
{
|
||||||
// Initialize gateway at maximum PA level, channel 70 and callback for write operations
|
|
||||||
gw.begin(RF24_PA_LEVEL_GW, RF24_CHANNEL, RF24_DATARATE, writeEthernet);
|
|
||||||
|
|
||||||
Ethernet.begin(mac, myIp);
|
Ethernet.begin(mac, myIp);
|
||||||
|
|
||||||
// give the Ethernet interface a second to initialize
|
// give the Ethernet interface a second to initialize
|
||||||
delay(1000);
|
delay(1000);
|
||||||
|
|
||||||
|
// Initialize gateway at maximum PA level, channel 70 and callback for write operations
|
||||||
|
gw.begin(RF24_PA_LEVEL_GW, RF24_CHANNEL, RF24_DATARATE, writeEthernet);
|
||||||
|
|
||||||
// start listening for clients
|
// start listening for clients
|
||||||
server.begin();
|
server.begin();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user