1 #pragma once 2 #include <nlohmann/json.hpp> 3 4 namespace control 5 { 6 // clang-format off 7 8 enum class ControlType{ 9 Invalid, 10 Temperature, 11 Power, 12 Frequency, 13 FrequencyMHz, 14 Pressure, 15 }; 16 17 enum class SetPointType{ 18 Invalid, 19 Single, 20 Range, 21 }; 22 23 enum class ControlMode{ 24 Invalid, 25 Automatic, 26 Override, 27 Manual, 28 Disabled, 29 }; 30 31 enum class ImplementationType{ 32 Invalid, 33 Programmable, 34 Direct, 35 Monitored, 36 }; 37 38 NLOHMANN_JSON_SERIALIZE_ENUM(ControlType, { 39 {ControlType::Invalid, "Invalid"}, 40 {ControlType::Temperature, "Temperature"}, 41 {ControlType::Power, "Power"}, 42 {ControlType::Frequency, "Frequency"}, 43 {ControlType::FrequencyMHz, "FrequencyMHz"}, 44 {ControlType::Pressure, "Pressure"}, 45 }); 46 47 NLOHMANN_JSON_SERIALIZE_ENUM(SetPointType, { 48 {SetPointType::Invalid, "Invalid"}, 49 {SetPointType::Single, "Single"}, 50 {SetPointType::Range, "Range"}, 51 }); 52 53 NLOHMANN_JSON_SERIALIZE_ENUM(ControlMode, { 54 {ControlMode::Invalid, "Invalid"}, 55 {ControlMode::Automatic, "Automatic"}, 56 {ControlMode::Override, "Override"}, 57 {ControlMode::Manual, "Manual"}, 58 {ControlMode::Disabled, "Disabled"}, 59 }); 60 61 NLOHMANN_JSON_SERIALIZE_ENUM(ImplementationType, { 62 {ImplementationType::Invalid, "Invalid"}, 63 {ImplementationType::Programmable, "Programmable"}, 64 {ImplementationType::Direct, "Direct"}, 65 {ImplementationType::Monitored, "Monitored"}, 66 }); 67 68 } 69 // clang-format on 70