Delphine CC Chiu | 3e30b7a | 2024-04-12 13:11:42 -0500 | [diff] [blame] | 1 | #pragma once |
| 2 | |
Rush Chen | 31ce375 | 2024-11-08 14:57:27 +0800 | [diff] [blame] | 3 | #include <array> |
Patrick Williams | 971312a | 2024-04-12 13:45:50 -0500 | [diff] [blame] | 4 | #include <chrono> |
| 5 | |
Delphine CC Chiu | 3e30b7a | 2024-04-12 13:11:42 -0500 | [diff] [blame] | 6 | constexpr inline auto POWER_DBUS_OBJECT_NAME = |
| 7 | "/xyz/openbmc_project/Chassis/Buttons/Power0"; |
| 8 | constexpr inline auto RESET_DBUS_OBJECT_NAME = |
| 9 | "/xyz/openbmc_project/Chassis/Buttons/Reset0"; |
| 10 | constexpr inline auto ID_DBUS_OBJECT_NAME = |
| 11 | "/xyz/openbmc_project/Chassis/Buttons/ID0"; |
| 12 | constexpr inline auto HS_DBUS_OBJECT_NAME = |
| 13 | "/xyz/openbmc_project/Chassis/Buttons/HostSelector"; |
| 14 | constexpr inline auto DBG_HS_DBUS_OBJECT_NAME = |
| 15 | "/xyz/openbmc_project/Chassis/Buttons/DebugHostSelector"; |
| 16 | constexpr inline auto SERIAL_CONSOLE_MUX_DBUS_OBJECT_NAME = |
| 17 | "/xyz/openbmc_project/Chassis/Buttons/SerialUartMux"; |
| 18 | |
| 19 | constexpr inline auto CHASSIS_STATE_OBJECT_NAME = |
| 20 | "/xyz/openbmc_project/state/chassis"; |
| 21 | constexpr inline auto CHASSISSYSTEM_STATE_OBJECT_NAME = |
| 22 | "/xyz/openbmc_project/state/chassis_system"; |
| 23 | constexpr inline auto HOST_STATE_OBJECT_NAME = |
| 24 | "/xyz/openbmc_project/state/host"; |
| 25 | |
| 26 | constexpr inline auto GPIO_BASE_LABEL_NAME = "1e780000.gpio"; |
Rush Chen | 31ce375 | 2024-11-08 14:57:27 +0800 | [diff] [blame] | 27 | constexpr inline auto gpioDefFile = "/etc/default/obmc/gpio/gpio_defs.json"; |
Delphine CC Chiu | 3e30b7a | 2024-04-12 13:11:42 -0500 | [diff] [blame] | 28 | #define LOOKUP_GPIO_BASE @LOOKUP_GPIO_BASE@ |
| 29 | |
| 30 | constexpr inline auto POWER_BUTTON_PROFILE = @POWER_BUTTON_PROFILE@; |
| 31 | constexpr inline auto ID_LED_GROUP = @ID_LED_GROUP@; |
Patrick Williams | 971312a | 2024-04-12 13:45:50 -0500 | [diff] [blame] | 32 | constexpr inline const auto LONG_PRESS_TIME_MS = |
| 33 | std::chrono::milliseconds(@LONG_PRESS_TIME_MS@); |
Rush Chen | 31ce375 | 2024-11-08 14:57:27 +0800 | [diff] [blame] | 34 | |
| 35 | constexpr inline static auto instances = std::to_array({ @INSTANCES@ }); |