qmk/qmk_firmware

[Bug] Compile error with USE_I2C and RGB_MATRIX_SPLIT

Open

#13 218 ouverte le 16 juin 2021

Voir sur GitHub
 (2 commentaires) (0 réactions) (0 assignés)C (43 867 forks)batch import
bughelp wanted

Métriques du dépôt

Stars
 (20 368 stars)
Métriques de merge PR
 (Merge moyen 20j 9h) (27 PRs mergées en 30 j)

Description

Describe the Bug

  1. config RGB_MATRIX_ENABLE = yes and RGB_MATRIX_DRIVER = WS2812
  2. define USE_I2C and RGB_MATRIX_SPLIT
  3. Compile error occurs.

System Information

Additional Context

Compiling: quantum/process_keycode/process_magic.c                                                  [OK]
Compiling: quantum/process_keycode/process_grave_esc.c                                              [OK]
Compiling: quantum/split_common/transport.c                                                        quantum/split_common/transport.c: In function 'transport_master':
quantum/split_common/transport.c:169:5: error: cannot convert to a pointer type
     i2c_writeReg(SLAVE_I2C_ADDRESS, I2C_RGB_MATRIX_START, (void *)rgb_matrix_config, sizeof(i2c_buffer->rgb_matrix), TIMEOUT);
     ^~~~~~~~~~~~
quantum/split_common/transport.c: In function 'transport_slave':
quantum/split_common/transport.c:225:5: error: cannot convert to a pointer type
     memcpy((void *)i2c_buffer->rgb_matrix, (void *)rgb_matrix_config, sizeof(i2c_buffer->rgb_matrix));
     ^~~~~~
quantum/split_common/transport.c:225:5: error: cannot convert to a pointer type
quantum/split_common/transport.c:225:5: error: null argument where non-null required (argument 1) [-Werror=nonnull]
quantum/split_common/transport.c:225:5: error: null argument where non-null required (argument 2) [-Werror=nonnull]
cc1.exe: all warnings being treated as errors
 [ERRORS]
 |
 |
 |
make[1]: *** [tmk_core/rules.mk:436: .build/obj_yk_4_default/quantum/split_common/transport.o] エラー 1
Make finished with errors
make: *** [Makefile:530: yk_4:default] エラー 1

Guide contributeur