How to use the following call?

System.sleep(dr_echo, RISING, timerInterval, SLEEP_NETWORK_STANDBY);  

The compiler complains:

dr.cpp:163:50: error: 'SLEEP_NETWORK_STANDBY' was not declared in this scope

Make sure your Electron has system firmware 0.5.0 or 0.5.1 and if you are using Particle Build (Web IDE) the Building With popup menu says 0.5.0 or 0.5.1. The SLEEP_NETWORK_STANDBY feature was added in 0.5.0, so it will generate a “was not declared” error in 0.4.8.


It’s 0.4.8. So how to upgrade to 0.5.1?

I upgraded the firmware with the following commands:

particle flash --usb system-part1-0.5.1-electron.bin
particle flash --usb system-part2-0.5.1-electron.bin

But it still shows 0.4.8 in the devices page of

How to check the current firmware version?

It is 0.5.1 now after removing and adding the device again.

1 Like