REDAC HybridController
Firmware for LUCIDAC/REDAC Teensy
Loading...
Searching...
No Matches
cblock.h
Go to the documentation of this file.
1#pragma once
2
3#include <block/cblock.h>
4#include <entity/meta.h>
5#include <utils/logging.h>
6
7#include <chips/AD5452.h>
8
9#include "entity/hardware.h"
10
11namespace blocks {
12
14
16
17protected:
18 std::array<functions::AD5452, 32> f_coeffs;
19
20public:
21 static std::array<functions::AD5452, 32> make_f_coeffs(bus::addr_t block_address,
22 std::array<const uint8_t, 32> f_coeffs_cs,
23 uint8_t alt_function_idx);
24
25 CBlockHAL_Common(bus::addr_t block_address, bus::addr_t temperature_sensor_address,
26 std::array<const uint8_t, 32> f_coeffs_cs, uint8_t alt_function_idx);
27
28 bool write_factor(uint8_t idx, float value) override;
29};
30
32public:
33 explicit CBlockHAL_V_1_0_X(bus::addr_t block_address);
34};
35
37public:
38 explicit CBlockHAL_V_1_1_X(bus::addr_t block_address);
39};
40
42public:
43 explicit CBlockHAL_V_1_2_X(bus::addr_t block_address);
44};
45
46} // namespace blocks
static std::array< functions::AD5452, 32 > make_f_coeffs(bus::addr_t block_address, std::array< const uint8_t, 32 > f_coeffs_cs, uint8_t alt_function_idx)
Definition cblock.cpp:38
bool write_factor(uint8_t idx, float value) override
Definition cblock.cpp:81
std::array< functions::AD5452, 32 > f_coeffs
Definition cblock.h:18
CBlockHAL_Common(bus::addr_t block_address, bus::addr_t temperature_sensor_address, std::array< const uint8_t, 32 > f_coeffs_cs, uint8_t alt_function_idx)
Definition cblock.cpp:75
CBlockHAL_V_1_0_X(bus::addr_t block_address)
Definition cblock.cpp:89
CBlockHAL_V_1_1_X(bus::addr_t block_address)
Definition cblock.cpp:106
CBlockHAL_V_1_2_X(bus::addr_t block_address)
Definition cblock.cpp:119
entities::EntitySharedHardware< CBlockHAL > CBlockHAL_Parent
Definition cblock.h:13