forked from kofal.net/zmk
refactor: Move away from deprecated label usages.
* Move away from DT_LABEL. * Move to DEVICE_DT_GET for non-behavior device access. * Move various drivers to `gpio_spec_dt` and `DT` related macros. * Remove mcp23017 while at it, since better upstream driver is available.
This commit is contained in:
committed by
Pete Johanson
parent
062f94d014
commit
09ed79a867
@@ -17,12 +17,10 @@ LOG_MODULE_REGISTER(zmk, CONFIG_ZMK_LOG_LEVEL);
|
||||
#include <zmk/display.h>
|
||||
#include <drivers/ext_power.h>
|
||||
|
||||
#define ZMK_KSCAN_DEV DT_LABEL(ZMK_MATRIX_NODE_ID)
|
||||
|
||||
void main(void) {
|
||||
LOG_INF("Welcome to ZMK!\n");
|
||||
|
||||
if (zmk_kscan_init(ZMK_KSCAN_DEV) != 0) {
|
||||
if (zmk_kscan_init(DEVICE_DT_GET(ZMK_MATRIX_NODE_ID)) != 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user