Motion Master 6.0.0-alpha.86
Next-generation motion control software
Loading...
Searching...
No Matches
integro_variant.cc File Reference
#include "node/integro_variant.h"
#include <algorithm>
#include <array>
#include <cstdint>
#include <expected>
#include <format>
#include <nlohmann/json.hpp>
#include <optional>
#include <span>
#include <string>
#include <string_view>
#include <utility>
#include <vector>
Include dependency graph for integro_variant.cc:

Namespaces

namespace  mm
 
namespace  mm::node
 

Functions

std::string_view mm::node::toString (VariantOperationMode mode)
 The mode's name, or "unknown" for a value no firmware release defines.
 
std::span< const IntegroVariantOptionmm::node::integroVariantOptions ()
 The whole catalogue, in code order.
 
const IntegroVariantOptionmm::node::integroVariantOption (uint16_t id)
 Looks a code up in the catalogue.
 
void mm::node::to_json (nlohmann::json &j, const IntegroVariantOption &option)
 Serialises one catalogue entry — the body of GET /api/integro-variant/options.
 
std::expected< IntegroVariant, std::string > mm::node::parseIntegroVariant (std::span< const uint8_t > content)
 Decodes content as a .variant file.
 
std::optional< uint16_t > mm::node::variantFieldbusProtocol (const IntegroVariant &variant)
 The selected fieldbus protocol, for the tail of a full firmware descriptor (specification §3.4.2.1).
 
void mm::node::to_json (nlohmann::json &j, const IntegroVariant &variant)
 Serialises a parsed file.