I'm trying to code up Hibernate for the Boron LTE. I'm using the online IDE build.particle.io. When I try to compile the following code to Hibernate, I get errors that SystemSleepConfiguraiton, config and SystemSleepMode are not defined. I'm guessing that, like in the Arduino IDE, I need to include something. Can anyone tell me what I need to do in order for this to compile? Thank you
What does the rest of your code look like? If you are using the Web IDE and a .ino file you don't need to include anything. If you have a second tab open as a .cpp or .h file, you need to:
I figured out what the problem was. There is a legacy method of hibernation and a more current way (which is what I coded up). After a lot of searching, I found out that early versions of the OS firmware require the use of the legacy method, and to use the current method requires more current firmware. I upgraded the Boron to version 4.1.0 and the code I attempted to compile (above) now compiles and works.