summaryrefslogtreecommitdiff
path: root/platforms/avr/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'platforms/avr/drivers')
-rw-r--r--platforms/avr/drivers/ws2812_bitbang.c4
-rw-r--r--platforms/avr/drivers/ws2812_i2c.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/platforms/avr/drivers/ws2812_bitbang.c b/platforms/avr/drivers/ws2812_bitbang.c
index aad10d86b0..116053591f 100644
--- a/platforms/avr/drivers/ws2812_bitbang.c
+++ b/platforms/avr/drivers/ws2812_bitbang.c
@@ -37,13 +37,13 @@
static inline void ws2812_sendarray_mask(uint8_t *data, uint16_t datlen, uint8_t masklo, uint8_t maskhi);
-void ws2812_setleds(LED_TYPE *ledarray, uint16_t number_of_leds) {
+void ws2812_setleds(rgb_led_t *ledarray, uint16_t number_of_leds) {
DDRx_ADDRESS(WS2812_DI_PIN) |= pinmask(WS2812_DI_PIN);
uint8_t masklo = ~(pinmask(WS2812_DI_PIN)) & PORTx_ADDRESS(WS2812_DI_PIN);
uint8_t maskhi = pinmask(WS2812_DI_PIN) | PORTx_ADDRESS(WS2812_DI_PIN);
- ws2812_sendarray_mask((uint8_t *)ledarray, number_of_leds * sizeof(LED_TYPE), masklo, maskhi);
+ ws2812_sendarray_mask((uint8_t *)ledarray, number_of_leds * sizeof(rgb_led_t), masklo, maskhi);
_delay_us(WS2812_TRST_US);
}
diff --git a/platforms/avr/drivers/ws2812_i2c.c b/platforms/avr/drivers/ws2812_i2c.c
index f4a2fbe0b3..f52a037b8e 100644
--- a/platforms/avr/drivers/ws2812_i2c.c
+++ b/platforms/avr/drivers/ws2812_i2c.c
@@ -18,12 +18,12 @@ void ws2812_init(void) {
}
// Setleds for standard RGB
-void ws2812_setleds(LED_TYPE *ledarray, uint16_t leds) {
+void ws2812_setleds(rgb_led_t *ledarray, uint16_t leds) {
static bool s_init = false;
if (!s_init) {
ws2812_init();
s_init = true;
}
- i2c_transmit(WS2812_I2C_ADDRESS, (uint8_t *)ledarray, sizeof(LED_TYPE) * leds, WS2812_I2C_TIMEOUT);
+ i2c_transmit(WS2812_I2C_ADDRESS, (uint8_t *)ledarray, sizeof(rgb_led_t) * leds, WS2812_I2C_TIMEOUT);
}