Skip to content

Problem When Compiling for RP2040 #170

Description

@DanielSim84

Which Board?
Choc

Which Board Revision?
Choc, 2.1

What Software are you using?
Building QMK on QMK_MSYS

What is the issue?
Trying to compile the RP2040 version for a Splinky Controller, but encountered an "ws2812_vendor.c:275:26: error: iteration 29 invokes undefined behavior [-Werror=aggressive-loop-optimizations]" error. Compilation works fine for non RP2040 configuration.

I narrowed down the issue to config.h in keyboards/sofle_choc where RGBLED_NUM is defined as 29 while RGB_MATRIX_LED_COUNT is 58, leading to the undefined behaviour above when the for-loop tried to assess an index bigger than the array. After comparing to other config.h for other keyboards, I decided to change RGBLED_NUM to 58 which allows compilation to proceed but I am not sure if this is the solution (can't test for now... I destroyed a board when desoldering an LED)

What you expected:
Success compilation when running qmk compile -e CONVERT_TO=promicro_rp2040
kb_error_1

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions