Skip to content

PadLedController

#include "crosspad/pad/PadLedController.hpp"

Generated from crosspad/pad/PadLedController.hpp in crosspad-core. Edit the header’s doxygen comments to change this page.

PadLedController & getPadLedController()

Platform-injected singleton accessor.

Declared in crosspad/pad/PadLedController.hpp:147.

Portable pad LED state and color controller.

Manages per-pad color state, feedback modes, brightness, and LED updates. Replaces the platform-specific KeypadRGBDriver. Uses ILedStrip for hardware abstraction — the ILedStrip implementation handles pad→LED index remapping.

Members

MemberDescription
PadLedController
initPlatform only The platform calls it once at start-up (crosspad_platform_init).
beginPlatform only The platform calls it once at start-up (crosspad_platform_init).
updatePlatform only PadManager::update() calls it.
setCoalescedRefresh
getCoalescedRefresh
handleNoteOn
handleNoteOff
handleAftertouch
notifyNoteOn
notifyNoteOff
notifyAftertouch
notifyNotePlay
setPadColor
setPadPressedColor
setPadPlayingColor
setPadColor
setPadPressedColor
setPadPlayingColor
setDefaultColor
setPressedColor
setPlayingColor
clearPadColor
getPadColor
getPressedColor
getPlayingColor
setAnimationMode
setFeedbackMode
getFeedbackMode
setBrightness
getBrightness
stopAnimation
setAnimating
getAnimating
setNoteOnCallback
setAftertouchCallback
setAnimationCompleteCallback
setCustomColorCallback
getPadFromMidiNote
updateLEDs

Methods

PadLedController() = default

Platform only The platform calls it once at start-up (crosspad_platform_init).

void init(ILedStrip &ledStrip, IEventBus &eventBus, CrosspadSettings *settings, uint8_t padCount=16)

Platform only The platform calls it once at start-up (crosspad_platform_init).

void begin()

Platform only PadManager::update() calls it.

void update()
void setCoalescedRefresh(bool on)
bool getCoalescedRefresh() const
void handleNoteOn(uint8_t channel, uint8_t note, uint8_t velocity)
void handleNoteOff(uint8_t channel, uint8_t note)
void handleAftertouch(uint8_t channel, uint8_t note, uint8_t pressure)
void notifyNoteOn(uint8_t padIdx, uint8_t velocity)
void notifyNoteOff(uint8_t padIdx, uint8_t velocity=0)
void notifyAftertouch(uint8_t padIdx, uint8_t pressure)
void notifyNotePlay(uint8_t padIdx, bool isPlaying)
void setPadColor(uint8_t padIdx, RgbColor color)
void setPadPressedColor(uint8_t padIdx, RgbColor color)
void setPadPlayingColor(uint8_t padIdx, RgbColor color)
void setPadColor(uint8_t padIdx, uint8_t r, uint8_t g, uint8_t b)
void setPadPressedColor(uint8_t padIdx, uint8_t r, uint8_t g, uint8_t b)
void setPadPlayingColor(uint8_t padIdx, uint8_t r, uint8_t g, uint8_t b)
void setDefaultColor(RgbColor color)
void setPressedColor(RgbColor color)
void setPlayingColor(RgbColor color)
void clearPadColor(uint8_t padIdx)
RgbColor getPadColor(uint8_t padIdx)
RgbColor getPressedColor(uint8_t padIdx)
RgbColor getPlayingColor(uint8_t padIdx)
void setAnimationMode(KeypadAnimationMode mode)
void setFeedbackMode(KeypadFeedbackMode mode)
KeypadFeedbackMode getFeedbackMode()
void setBrightness(uint8_t brightness)
uint8_t getBrightness()
void stopAnimation()
void setAnimating(bool v)
bool getAnimating() const
void setNoteOnCallback(KeypadNoteOnCallback callback)
void setAftertouchCallback(KeypadAftertouchCallback callback)
void setAnimationCompleteCallback(KeypadAnimationCompleteCallback callback)
void setCustomColorCallback(KeypadCustomColorCallback callback)
int getPadFromMidiNote(uint8_t note)
void updateLEDs()

Declared in crosspad/pad/PadLedController.hpp:20.