Skip to content

Commit

Permalink
m66
Browse files Browse the repository at this point in the history
  • Loading branch information
Alin Marin Elena committed Nov 8, 2023
1 parent 5733ae9 commit 6863877
Showing 1 changed file with 27 additions and 23 deletions.
50 changes: 27 additions & 23 deletions config/boards/shields/mlego_m66_rev4/mlego_m66_rev4.overlay
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ RC(4,0) RC(4,1) RC(4,2) RC(4,3) RC(4,4) RC(4,5) RC(4,6) RC(4,7) RC(4,8) RC(4,9
compatible = "zmk,kscan-gpio-matrix";
label = "kscan";
diode-direction = "col2row";
col-gpios = <&shift_reg 2 (GPIO_ACTIVE_HIGH)>
col-gpios = <&shift_reg 2 (GPIO_ACTIVE_HIGH)>
, <&shift_reg 9 (GPIO_ACTIVE_HIGH)>
, <&shift_reg 10 (GPIO_ACTIVE_HIGH)>
, <&shift_reg 11 (GPIO_ACTIVE_HIGH)>
Expand All @@ -62,11 +62,11 @@ RC(4,0) RC(4,1) RC(4,2) RC(4,3) RC(4,4) RC(4,5) RC(4,6) RC(4,7) RC(4,8) RC(4,9
, <&shift_reg 7 (GPIO_ACTIVE_HIGH)>
, <&shift_reg 1 (GPIO_ACTIVE_HIGH)>
;
row-gpios = <&pro_micro 0 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
,<&pro_micro 18(GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
,<&pro_micro 21(GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
,<&pro_micro 20(GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
,<&pro_micro 19(GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
row-gpios = <&pro_micro 0 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
, <&pro_micro 18(GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
, <&pro_micro 21(GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
, <&pro_micro 20(GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
, <&pro_micro 19(GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)>
;
};

Expand All @@ -91,16 +91,18 @@ RC(4,0) RC(4,1) RC(4,2) RC(4,3) RC(4,4) RC(4,5) RC(4,6) RC(4,7) RC(4,8) RC(4,9
&pinctrl {
spi0_default: spi0_default {
group1 {
psels = <NRF_PSEL(SPIM_SCK, 1, 13)>,
<NRF_PSEL(SPIM_MOSI, 0, 10)>,
<NRF_PSEL(SPIM_MISO, 1, 11)>;
psels = <NRF_PSEL(SPIM_SCK, 1, 13)>
, <NRF_PSEL(SPIM_MOSI, 0, 10)>
, <NRF_PSEL(SPIM_MISO, 1, 11)>
;
};
};
spi0_sleep: spi0_sleep {
group1 {
psels = <NRF_PSEL(SPIM_SCK, 1, 13)>,
<NRF_PSEL(SPIM_MOSI, 0, 10)>,
<NRF_PSEL(SPIM_MISO, 1, 11)>;
psels = <NRF_PSEL(SPIM_SCK, 1, 13)>
, <NRF_PSEL(SPIM_MOSI, 0, 10)>
, <NRF_PSEL(SPIM_MISO, 1, 11)>
;
low-power-enable;
};
};
Expand All @@ -111,14 +113,15 @@ RC(4,0) RC(4,1) RC(4,2) RC(4,3) RC(4,4) RC(4,5) RC(4,6) RC(4,7) RC(4,8) RC(4,9
};

nice_nano_spi: &spi0 {
status = "okay";
status = "okay";
compatible = "nordic,nrf-spim";
pinctrl-0 = <&spi0_default>;
pinctrl-1 = <&spi0_sleep>;
pinctrl-names = "default", "sleep";

cs-gpios = <&pro_micro 10 GPIO_ACTIVE_LOW>
,<&pro_micro 6 GPIO_ACTIVE_LOW>;
cs-gpios = <&pro_micro 10 GPIO_ACTIVE_LOW>
, <&pro_micro 6 GPIO_ACTIVE_HIGH>
;
shift_reg: 595@0 {
compatible = "zmk,gpio-595";
status = "okay";
Expand All @@ -129,12 +132,13 @@ nice_nano_spi: &spi0 {
label = "4HC595";
ngpios = <16>;
};
nice_view: ls0xx@0 {
compatible = "sharp,ls0xx";
label = "DISPLAY";
spi-max-frequency = <1000000>;
reg = <0>;
width = <128>;
height = <128>;
};
nice_view: ls0xx@0 {
compatible = "sharp,ls0xx";
label = "DISPLAY";
spi-max-frequency = <1000000>;
disp-en-gpios = <&pro_micro 9 GPIO_ACTIVE_HIGH>
reg = <0>;
width = <168>;
height = <144>;
};
};

0 comments on commit 6863877

Please sign in to comment.