Hello, Actually, looking closer at the samd21 datasheet, my led pin can be configured in SPI MOSI.
In board/samd2l2/arduino-m0/src/ I added sam_ws2812.c, sam_ws2812.h which are a adapted copy of the stm32 version. Everything compiles but on "nsh> ls /dev", I can see that the led device (/dev/leds0) is not here. I would like to debug with Syslog but I can't get any error messages in the console. I am expecting to get error messages in the console but I get only 'nsh> ABD Now my bringup.c is looking like: #ifdef CONFIG_WS2812 /* Configure and initialize the WS2812 LEDs. */ #pragma message ("Configure and initialize the WS2812 LEDs with spi driver") ret = board_ws2812_initialize(0, 2, CONFIG_WS2812_LED_COUNT); if (ret < 0) { syslog(LOG_ERR, "ERROR: board_ws2812_initialize() failed: %d\n", ret); } #endif I setup the board.h with sercom2 to be SPI: /* SERCOM2 SPI is available on EXT2 * * PIN PORT SERCOM FUNCTION * --- ------------------ ----------- * ** PA17 SERCOM2 PAD2 SPI SS * ** PA15 SERCOM2 PAD3 SPI MOSI * ** PA8 SERCOM2 PAD0 SPI MISO * ** PA9 SERCOM2 PAD1 SPI SCK */ #define BOARD_SERCOM2_GCLKGEN 0 #define BOARD_SERCOM2_SLOW_GCLKGEN BOARD_SERCOM05_SLOW_GCLKGEN #define BOARD_SERCOM2_MUXCONFIG (SPI_CTRLA_DOPO_DOPAD231 | SPI_CTRLA_DIPAD0) #define BOARD_SERCOM2_PINMAP_PAD0 PORT_SERCOM2_PAD0_2 /* SPI_MISO */ #define BOARD_SERCOM2_PINMAP_PAD2 0 /* microSD_SS */ #define BOARD_SERCOM2_PINMAP_PAD3 PORT_SERCOM2_PAD3_1 /* SPI_MOSI */ #define BOARD_SERCOM2_PINMAP_PAD1 PORT_SERCOM2_PAD1_2 /* SPI_SCK */ #define BOARD_SERCOM2_FREQUENCY BOARD_GCLK0_FREQUENCY In menuconfig, I activated debug Syslog in Build Setup->Debug Option: (0) Fortify Source [*] Define NDEBUG globally [*] Enable Debug Features *** Debug SYSLOG Output Controls *** [*] Enable Error Output [*] Enable Warnings Output [*] Enable Informational Debug Output [ ] Enable Debug Assertions *** Subsystem Debug Options *** [ ] File System Debug Features [ ] Graphics Debug Features [ ] C Library Debug Features [ ] Memory Manager Debug Features [ ] Power-related Debug Features [ ] Battery-related Debug Features [ ] Scheduler Debug Features *** OS Function Debug Options *** [ ] Interrupt Controller Debug Features *** Driver Debug Options *** [*] Low-level LED Debug Features [*] LED Driver Error Output [*] LED Driver Warnings Output [*] LED Driver Informational Output [*] GPIO Debug Features [*] GPIO Error Output [*] GPIO Warnings Output [*] GPIO Informational Output [*] SPI Debug Features [*] SPI Error Output [*] SPI Warnings Output [*] SPI Informational Output [ ] Timer Debug Features [ ] IPC (Interprocessor communication) Debug Features [ ] Stack coloration [ ] Compiler stack canaries [ ] Generate stack usage information (0) Detect use of large stack variables [*] Generate Debug Symbols Device Driver -> System logging option: *** SYSLOG options *** (1) Maximum SYSLOG channels [ ] RAM log device support [ ] Use buffered output [ ] Use interrupt buffer *** Formatting options *** [ ] Prepend timestamp to syslog message [ ] Prepend priority to syslog message [ ] Prepend process name to syslog message [ ] Prepend process ID to syslog message [ ] Prepend prefix to syslog message [ ] Colored syslog output *** SYSLOG channels *** (/dev/ttyS0) System log device [ ] Log to a character device [ ] Log to stream [*] Log to /dev/console [*] Default SYSLOG device [ ] SYSLOG rpmsg server character device [ ] Syslog file output ---- [*] SYSLOG character device [ ] SYSLOG IOCTL support Regards, Bertrand.