Some basics classes/types.
More...
#include <Arduino.h>
#include "type_traits.hpp"
#include "constants.h"
Go to the source code of this file.
|
template<class... Ts> |
constexpr uint8_t | ival (Ts... Vs) |
|
template<char... Vs> |
constexpr integral_constant< uint8_t, ival(Vs...) > | operator""_i () |
|
template<typename _Tp> |
constexpr size_t | size (const _Tp(&)[0]) noexcept |
| Helper function for the special case of a 0-dimension C-array.
|
|
template<typename _Tp, size_t _Nm> |
constexpr size_t | size (const _Tp(&)[_Nm]) noexcept |
| Helper function to retrieve the dimension of a C-array.
|
|
Some basics classes/types.
- Author
- Frédéric Metrich (frede.nosp@m.ric..nosp@m.metri.nosp@m.ch@l.nosp@m.ive.f.nosp@m.r)
- Version
- 0.1
- Date
- 2023-02-09
- Copyright
- Copyright (c) 2023
Definition in file types.h.
◆ LoadStates
Load state (for use if loads are active high (Rev 2 PCB))
Enumerator |
---|
LOAD_OFF | load is OFF
|
LOAD_ON | load is ON
|
Definition at line 48 of file types.h.
◆ OutputModes
Output modes
Enumerator |
---|
ANTI_FLICKER | Anti-flicker mode
|
NORMAL | Normal mode
|
Definition at line 41 of file types.h.
◆ Polarities
Polarities
Enumerator |
---|
NEGATIVE | polarity is negative
|
POSITIVE | polarity is positive
|
Definition at line 34 of file types.h.
◆ RotationModes
Rotation modes
Enumerator |
---|
OFF | Off
|
AUTO | Once a day
|
PIN | Pin triggered
|
Definition at line 59 of file types.h.
◆ SerialOutputType
Enum for serial output types
Enumerator |
---|
HumanReadable | Human-readable output for commissioning
|
IoT | Output for HomeAssistant or similar
|
EmonCMS | Output in EmonCMS format
|
Definition at line 26 of file types.h.
◆ ival()
◆ operator""_i()
◆ size() [1/2]
template<typename _Tp>
size_t size |
( |
const | _Tp(&)[0] | ) |
|
|
constexprnoexcept |
Helper function for the special case of a 0-dimension C-array.
- Template Parameters
-
Definition at line 97 of file types.h.
◆ size() [2/2]
template<typename _Tp, size_t _Nm>
size_t size |
( |
const | _Tp(&)[_Nm] | ) |
|
|
constexprnoexcept |
Helper function to retrieve the dimension of a C-array.
- Template Parameters
-
_Tp | elements type |
_Nm | dimension |
Definition at line 87 of file types.h.
◆ loadStateMask
uint8_t loadStateMask { 0x7FU } |
|
inlineconstexpr |
bit mask for masking load state
Definition at line 55 of file types.h.
◆ loadStateOnBit
bit mask for load state ON
Definition at line 56 of file types.h.