Hello there,
I am trying to control 2 LED strips (one with a WS2811 LED driver and one with a USC512C4 LED driver) with my STM32L4 with integrated RS485.
Do you have any idea how to do this?
Best regard.
P.Congré
Hello there,
I am trying to control 2 LED strips (one with a WS2811 LED driver and one with a USC512C4 LED driver) with my STM32L4 with integrated RS485.
Do you have any idea how to do this?
Best regard.
P.Congré
In xxx_project.h,
#ifndef __C459_PROJECT_H #define __C459_PROJECT_H // INCLUDES #include "stm32f0xx.h" #include <stdio.h> #include <stdbool.h> #include <stdint.h> // DEFINES #define VERSION 100 #define VERSION_STR "1.0.0" #define FALSE (false) #define TRUE (true) #define MAX_GCI_SKIPS 10 #define FLASH_SIZE 0x200000 #define SECTOR_SIZE 0x10000 #define FLASH_SECTORS 32 #define CONTEXT_SECTOR 0 #define CONTEXT_BLOCK_SIZE 1024 #define SERIALISE_VERSION 0 // must never be 0xff because also used to loactae written areas of flash //#define SET_DMX_TX_EN {GPIOA->BSRR = DMX_TX_EN;} //#define CLR_DMX_TX_EN {GPIOA->BSRR = (DMX_TX_EN) << 16;} //#define SET_FLASH_NSS {GPIOB->BSRR = FLASH_NSS;} //#define CLR_FLASH_NSS {GPIOB->BSRR = (FLASH_NSS) << 16;} //#define SET_FLASH_WP {GPIOB->BSRR = FLASH_WP;} //#define CLR_FLASH_WP {GPIOB->BSRR = (FLASH_WP) << 16;} //#define SET_PROX_STX {GPIOC->BSRR = PROX_STX;} //#define CLR_PROX_STX {GPIOC->BSRR = (PROX_STX) << 16;} //#define SET_PROX_MD {GPIOC->BSRR = PROX_MD;} //#define CLR_PROX_MD {GPIOC->BSRR = (PROX_MD) << 16;} //#define SET_PROX_SC {GPIOC->BSRR = PROX_SC;} //#define CLR_PROX_SC {GPIOC->BSRR = (PROX_SC) << 16;} // PORTA #define IR_RX 1 << 8 #define DMX_TX 1 << 9 #define DMX_RX 1 << 10 #define DMX_TX_EN 1 << 11 #define LED_9 1 << 12 #define UART2_RX 1 << 15 // PORTB #define FLASH_SCK 1 << 3 #define FLASH_MISO 1 << 4 #define FLASH_MOSI 1 << 5 #define FLASH_NSS 1 << 6 #define FLASH_WP 1 << 7 #define LED_8 1 << 15 // PORTC #define LED_2 1 << 0 #define LED_3 1 << 1 #define LED_4 1 << 2 #define LED_5 1 << 3 #define PROX_PRX 1 << 6 #define PROX_STX 1 << 7 #define PROX_MD 1 << 8 #define PROX_SC 1 << 9 #define LED_12 1 << 10 #define LED_13 1 << 11 // PORTF #define LED_6 1 << 4 #define LED_7 1 << 5 #define LED_10 1 << 6 #define LED_11 1 << 7 #define ASC_LF 0x0a #define ASC_CR 0x0d #endif
Hope this helps.
MK