ProtoTracer  1.0
Real-time 3D rendering and animation engine
Loading...
Searching...
No Matches
APA102Controller.h
Go to the documentation of this file.
1/**
2 * @file APA102Controller.h
3 * @brief Declares the APA102Controller class for managing APA102 LED strips.
4 *
5 * This file defines the APA102Controller class, which extends the Controller base class.
6 * It provides functionality for controlling and displaying content on APA102 LED strips.
7 *
8 * @date 22/12/2024
9 * @author Coela Can't
10 */
11
12#pragma once
13
14#include <stdint.h> // Include for fixed-width integer types.
15#include "Controller.h" // Include for base controller functionality.
16#include "SmartMatrixAPA102.h" // Include for APA102-specific matrix utilities.
17#include "../Camera/CameraManager/CameraManager.h" // Include for camera management.
18#include "../Camera/Pixels/PixelGroup.h" // Include for pixel group management.
19
20/**
21 * @class APA102Controller
22 * @brief Manages APA102 LED strips with camera integration.
23 *
24 * The APA102Controller class extends the Controller base class to provide specific
25 * functionality for initializing, controlling, and displaying content on APA102 LED strips.
26 */
28public:
29 /**
30 * @brief Constructs an APA102Controller with specified parameters.
31 *
32 * @param cameras Pointer to the CameraManager for managing camera data.
33 * @param maxBrightness Maximum brightness for the LED strips.
34 * @param maxAccentBrightness Maximum brightness for accent lighting.
35 */
37
38 /**
39 * @brief Initializes the APA102Controller and sets up the LED strip.
40 */
41 void Initialize() override;
42
43 /**
44 * @brief Updates and displays the content on the LED strip.
45 */
46 void Display() override;
47
48 /**
49 * @brief Sets the maximum brightness of the LED strip.
50 *
51 * @param maxBrightness The maximum brightness value (0-255).
52 */
53 void SetBrightness(uint8_t maxBrightness) override;
54
55 /**
56 * @brief Sets the maximum accent brightness of the LED strip.
57 *
58 * @param maxAccentBrightness The maximum accent brightness value (0-255).
59 */
60 void SetAccentBrightness(uint8_t maxAccentBrightness) override;
61};
Declares the Controller base class for managing lighting controllers.
Manages APA102 LED strips with camera integration.
void Initialize() override
Initializes the APA102Controller and sets up the LED strip.
void Display() override
Updates and displays the content on the LED strip.
void SetAccentBrightness(uint8_t maxAccentBrightness) override
Sets the maximum accent brightness of the LED strip.
void SetBrightness(uint8_t maxBrightness) override
Sets the maximum brightness of the LED strip.
Manages multiple CameraBase objects.
Base class for managing brightness and display operations of lighting controllers.
Definition Controller.h:25
uint8_t maxAccentBrightness
Maximum allowed accent brightness level.
Definition Controller.h:35
uint8_t maxBrightness
Maximum allowed brightness level.
Definition Controller.h:34
CameraManager * cameras
Pointer to the CameraManager for managing camera data.
Definition Controller.h:31