The Main module implements the business logic of the application. It is the only module that knows about the others: it connects the cloud session to network availability, runs the periodic cloud synchronization, forwards location results to the cloud, and coordinates the reboot at the end of a firmware update.
Unlike the other modules, the Main module is not in the modules folder and does not run in a thread of its own. It runs in the main() thread, and it is the module that sets up the hardware watchdog that all other modules add their tasks to.