19b11eb9a8
- Removed TactilityC, moved its symbols to existing modules and several new ones (pthread-module, c-symbols-module, cpp-symbols-module, posix-symbols-module, freertos-module). - Removed Firmware subproject and moved main() into Tactility subproject. - Strengthened application archive, path, version, stack-size, and device validation. - Moved symbol resolution for elf_loader to app-esp32-module. - Improved `struct Module` declarations and made module and symbol definitions in modules more consistent. - Removed old http download code from Tactility subproject. - Rename app-module's source files for consistency. - Add missing pthread symbols. - Kernel module symbols are now resolvable on all platforms.
31 lines
559 B
C++
31 lines
559 B
C++
// SPDX-License-Identifier: Apache-2.0
|
|
#include <gps/module.h>
|
|
#include <gps/private/gps_ledger.h>
|
|
|
|
#include <tactility/error.h>
|
|
#include <tactility/module.h>
|
|
|
|
extern "C" {
|
|
|
|
static error_t start() {
|
|
// Materializes devices for configurations persisted in previous sessions.
|
|
gps_ledger_sync();
|
|
return ERROR_NONE;
|
|
}
|
|
|
|
static error_t stop() {
|
|
gps_ledger_clear();
|
|
return ERROR_NONE;
|
|
}
|
|
|
|
Module gps_module = {
|
|
.name = "gps",
|
|
.start = start,
|
|
.stop = stop,
|
|
.drivers = nullptr,
|
|
.symbols = nullptr,
|
|
.internal = nullptr,
|
|
};
|
|
|
|
}
|