summaryrefslogtreecommitdiff
path: root/src/system_fsm/include/system_events.hpp
diff options
context:
space:
mode:
authorjacqueline <me@jacqueline.id.au>2024-05-02 19:12:26 +1000
committerjacqueline <me@jacqueline.id.au>2024-05-02 19:12:26 +1000
commit1573a8c4cde1cd9528b422b2dcc598e37ffe94a7 (patch)
treed162822b8fd7054f81bace0c7a65ab4d5e6f93ef /src/system_fsm/include/system_events.hpp
parenta231fd1c8afedbeb14b0bc77d76bad61db986059 (diff)
downloadtangara-fw-1573a8c4cde1cd9528b422b2dcc598e37ffe94a7.tar.gz
WIP merge cyclically dependent components into one big component
Diffstat (limited to 'src/system_fsm/include/system_events.hpp')
-rw-r--r--src/system_fsm/include/system_events.hpp89
1 files changed, 0 insertions, 89 deletions
diff --git a/src/system_fsm/include/system_events.hpp b/src/system_fsm/include/system_events.hpp
deleted file mode 100644
index 22e3b6bd..00000000
--- a/src/system_fsm/include/system_events.hpp
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright 2023 jacqueline <me@jacqueline.id.au>
- *
- * SPDX-License-Identifier: GPL-3.0-only
- */
-
-#pragma once
-
-#include <memory>
-
-#include "battery.hpp"
-#include "bluetooth_types.hpp"
-#include "database.hpp"
-#include "ff.h"
-#include "haptics.hpp"
-#include "samd.hpp"
-#include "service_locator.hpp"
-#include "tinyfsm.hpp"
-
-namespace system_fsm {
-
-struct DisplayReady : tinyfsm::Event {};
-
-/*
- * Sent by SysState when the system has finished with its boot and self-test,
- * and is now ready to run normally.
- */
-struct BootComplete : tinyfsm::Event {
- std::shared_ptr<ServiceLocator> services;
-};
-
-/*
- * May be sent by any component to indicate that the system has experienced an
- * unrecoverable error. This should be used sparingly, as it essentially brings
- * down the device.
- */
-struct FatalError : tinyfsm::Event {};
-
-struct OnIdle : tinyfsm::Event {};
-
-/*
- * Sent by SysState when the system storage has been successfully mounted.
- */
-struct StorageMounted : tinyfsm::Event {};
-
-struct StorageError : tinyfsm::Event {
- FRESULT error;
-};
-
-struct KeyLockChanged : tinyfsm::Event {
- bool locking;
-};
-struct HasPhonesChanged : tinyfsm::Event {
- bool has_headphones;
-};
-struct SdDetectChanged : tinyfsm::Event {
- bool has_sd_card;
-};
-
-struct SamdUsbMscChanged : tinyfsm::Event {
- bool en;
-};
-struct SamdUsbStatusChanged : tinyfsm::Event {
- drivers::Samd::UsbStatus new_status;
-};
-
-struct BatteryStateChanged : tinyfsm::Event {
- battery::Battery::BatteryState new_state;
-};
-
-struct BluetoothEvent : tinyfsm::Event {
- drivers::bluetooth::Event event;
-};
-
-struct HapticTrigger : tinyfsm::Event {
- drivers::Haptics::Effect effect;
-};
-
-namespace internal {
-
-struct GpioInterrupt : tinyfsm::Event {};
-struct SamdInterrupt : tinyfsm::Event {};
-
-struct IdleTimeout : tinyfsm::Event {};
-struct UnmountTimeout : tinyfsm::Event {};
-
-} // namespace internal
-
-} // namespace system_fsm