@@ -16,11 +16,11 @@ class LEDControlInterface {
16
16
LEDControlInterface (const LEDControlInterface&) = delete ;
17
17
LEDControlInterface (LEDControlInterface&&) = delete ;
18
18
auto operator =(LEDControlInterface&&) -> LEDControlInterface& = delete ;
19
- auto operator =(const LEDControlInterface&)
20
- -> LEDControlInterface& = delete ;
19
+ auto operator =(const LEDControlInterface&) -> LEDControlInterface& = delete ;
21
20
virtual ~LEDControlInterface () = default ;
22
21
23
- virtual auto set_button_led_power (uint8_t button, uint32_t r, uint32_t g, uint32_t b, uint32_t w) -> void = 0;
22
+ virtual auto set_button_led_power (uint8_t button, uint32_t r, uint32_t g,
23
+ uint32_t b, uint32_t w) -> void = 0;
24
24
};
25
25
26
26
class LEDControlMessageHandler {
@@ -36,14 +36,11 @@ class LEDControlMessageHandler {
36
36
auto handle (std::monostate&) -> void {}
37
37
38
38
auto handle (const led_control_task_messages::PushButtonLED& msg) -> void {
39
- // Sets the Push button LED colors
40
- _hardware.set_button_led_power (
41
- msg.button ,
42
- static_cast <uint32_t >(msg.r ),
43
- static_cast <uint32_t >(msg.g ),
44
- static_cast <uint32_t >(msg.b ),
45
- static_cast <uint32_t >(msg.w )
46
- );
39
+ // Sets the Push button LED colors
40
+ _hardware.set_button_led_power (msg.button , static_cast <uint32_t >(msg.r ),
41
+ static_cast <uint32_t >(msg.g ),
42
+ static_cast <uint32_t >(msg.b ),
43
+ static_cast <uint32_t >(msg.w ));
47
44
}
48
45
49
46
LEDControlInterface& _hardware;
@@ -69,8 +66,7 @@ class LEDControlTask {
69
66
* Task entry point.
70
67
*/
71
68
[[noreturn]] void operator ()(LEDControlInterface* hardware_handle) {
72
- auto handler =
73
- LEDControlMessageHandler (*hardware_handle);
69
+ auto handler = LEDControlMessageHandler (*hardware_handle);
74
70
TaskMessage message{};
75
71
76
72
for (;;) {
0 commit comments