10 #ifndef logger_types_pico_channel_hpp
11 #define logger_types_pico_channel_hpp
13 #include "generated/pico_channel_generated.h"
40 auto _name =
builder.CreateString(name);
42 auto gs = CreatePico_channel_fb(
builder, _name, channel);
53 return VerifyPico_channel_fbBuffer(verifier);
62 static_cast<void>(len);
64 auto rgs = GetPico_channel_fb(msgBuffer);
67 std::string s =
"Pico Motor: ";
71 s += rgs->name()->c_str();
75 s += std::to_string(rgs->channel());
The MagAO-X logger flatbuffer log base type.
uint16_t eventCodeT
The type of an event code (16-bit unsigned int).
msgLen2T msgLenT
The type used to refer to the message length, regardless of length.
int8_t logPrioT
The type of the log priority code.
static void * messageBuffer(bufferPtrT &logBuffer)
Get the message buffer address.
std::shared_ptr< char > bufferPtrT
The log entry buffer smart pointer.
constexpr static logPrioT LOG_INFO
Informational. The info log level is the lowest level recorded during normal operations.
Message type for resolving log messages with a f.b. builder.
flatbuffers::FlatBufferBuilder builder
Base class for logs consisting of a flatbuffer message.
messageT(const std::string &name, uint8_t channel)
Application State Change.
static std::string msgString(void *msgBuffer, flatlogs::msgLenT len)
Format the message for text output, including translation of state codes to text form.
static const flatlogs::logPrioT defaultLevel
static const flatlogs::eventCodeT eventCode
static bool verify(flatlogs::bufferPtrT &logBuff, flatlogs::msgLenT len)