zmk icon indicating copy to clipboard operation
zmk copied to clipboard

Macros freeze/hangs keyboard on stm32

Open macseem opened this issue 7 months ago • 6 comments

Pressing key assigned to a macros doesn't do anything After that keyboard stops responding Macros complexity doesn't matter, default one from documentation behaves the same Key position/layer anything else doesn't change situation.

This is reproducing using on both github actions build and local west build Both builds are successful and don't fail

Any other behaviour works as expected (hold-tap, mod-tap, etc),

Board: STM32 f411ce black pill

Keymap configuration:

#include <behaviors.dtsi>
#include <dt-bindings/zmk/keys.h>

/{
    macros {
        zed_em_kay: zed_em_kay {
            compatible = "zmk,behavior-macro";
            #binding-cells = <0>;
            bindings
                = <&macro_press &kp LSHFT>
                , <&macro_tap &kp Z &kp M &kp K>
                , <&macro_release &kp LSHFT>
                ;
        };
    };
    keymap {
        compatible = "zmk,keymap";
        default_layer {
            bindings = <
&zed_em_kay &none &none &none
&none       &none &none &none
&none       &none &none &none
            >;
            label = "Default layer";
        };
    };
};

Here is overlay

/ {
    chosen {
      zmk,kscan = &default_kscan;
    };

    default_kscan: kscan {
      compatible = "zmk,kscan-gpio-matrix";
      label = "default_kscan";
      diode-direction = "col2row";

      col-gpios
        = <&blackpill 14 GPIO_ACTIVE_HIGH>
        , <&blackpill 15 GPIO_ACTIVE_HIGH>
        , <&blackpill 16 GPIO_ACTIVE_HIGH>
        , <&blackpill 17 GPIO_ACTIVE_HIGH>
        ;

      row-gpios 
        = <&blackpill 18 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
        , <&blackpill 19 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
        , <&blackpill 20 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
        ;

                
    };
};

macseem avatar Jul 15 '24 20:07 macseem