Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Leeloo v2 and Leeloo-Micro v1 updates to support Zephyr 3.2 #1762

Merged
merged 20 commits into from Jul 17, 2023
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
d03848f
Leeloo v2 and Leeloo v1 updates to support Zephyr 3.2
ClicketySplit Apr 20, 2023
b964048
Leeloo-Micro v1 updates to support Zephyr 3.2
ClicketySplit Apr 20, 2023
e3af7f4
Resolving base conflict.
ClicketySplit Apr 26, 2023
cd979ae
Resolve base conflict.
ClicketySplit Apr 26, 2023
a538c5b
Resolve base conflict.
ClicketySplit Apr 26, 2023
82e396c
Resolve base conflict.
ClicketySplit Apr 26, 2023
47f63ab
Resolve base conflict.
ClicketySplit Apr 26, 2023
2b1e91f
Clean up of white space.
ClicketySplit Apr 26, 2023
6cadaa7
Updates from pre-commit.
ClicketySplit Apr 26, 2023
3364c96
Merge branch 'zmkfirmware:main' into leeloo_micro_v1_branch
ClicketySplit Jun 4, 2023
1010c88
Merge branch 'zmkfirmware:main' into leeloo_micro_v1_branch
ClicketySplit Jun 5, 2023
efdfe99
Merge branch 'zmkfirmware:main' into leeloo_micro_v1_branch
ClicketySplit Jun 6, 2023
ed754e9
Merge branch 'zmkfirmware:main' into leeloo_micro_v1_branch
ClicketySplit Jun 20, 2023
6f2066f
Merge branch 'zmkfirmware:main' into leeloo_micro_v1_branch
ClicketySplit Jun 23, 2023
f8d6495
Merge branch 'zmkfirmware:main' into leeloo_micro_v1_branch
ClicketySplit Jul 7, 2023
d83caf4
Update app/boards/shields/leeloo_micro/README.md
ClicketySplit Jul 7, 2023
44f09fc
Updated based on recommendations.
ClicketySplit Jul 7, 2023
e9937f9
Merge branch 'leeloo_micro_v1_branch' of https://github.com/ClicketyS…
ClicketySplit Jul 7, 2023
32bd6b6
Refactored for new Encoder Configuration
ClicketySplit Jul 7, 2023
4a3f26f
Adjust pulses to 120 and steps to 30.
ClicketySplit Jul 9, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo/Kconfig.defconfig
@@ -1,4 +1,4 @@
# Copyright (c) 2022 The ZMK Contributors
# Copyright (c) 2023 The ZMK Contributors
# SPDX-License-Identifier: MIT

if SHIELD_LEELOO_REV2_LEFT
Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo/Kconfig.shield
@@ -1,4 +1,4 @@
# Copyright (c) 2022 The ZMK Contributors
# Copyright (c) 2023 The ZMK Contributors
# SPDX-License-Identifier: MIT

config SHIELD_LEELOO
Expand Down
34 changes: 4 additions & 30 deletions app/boards/shields/leeloo/README.md
Expand Up @@ -61,14 +61,14 @@ west build -d build/right_v2 -p -b nice_nano_v2 -- -DSHIELD=leeloo_rev2_right
Build commands for your custom keymap of Leeloo v1:

```
west build -d build/right -p -b nice_nano_v2 -- -DSHIELD=leeloo_right -DZMK_CONFIG="C:/dev/zmk/[yourNmae]/leeloo/config"
west build -d build/right -p -b nice_nano_v2 -- -DSHIELD=leeloo_right -DZMK_CONFIG="C:/dev/zmk/[yourName]/leeloo/config"
west build -d build/left -p -b nice_nano_v2 -- -DSHIELD=leeloo_left -DZMK_CONFIG="C:/dev/zmk/[yourName]/leeloo/config"
```

Build commands for your custom keymap of Leeloo v2:

```
west build -d build/right_v2 -p -b nice_nano_v2 -- -DSHIELD=leeloo_rev2_right -DZMK_CONFIG="C:/dev/zmk/[yourNmae]/leeloo_v2/config"
west build -d build/right_v2 -p -b nice_nano_v2 -- -DSHIELD=leeloo_rev2_right -DZMK_CONFIG="C:/dev/zmk/[yourName]/leeloo_v2/config"
west build -d build/left_v2 -p -b nice_nano_v2 -- -DSHIELD=leeloo_rev2_left -DZMK_CONFIG="C:/dev/zmk/[yourName]/leeloo_v2/config"
```

Expand All @@ -82,10 +82,6 @@ Near the top 3rd of the leeloo[_rev2].keymap file, locate the following code blo

```
//nice_view_spi: &spi0 {
// compatible = "nordic,nrf-spim";
// pinctrl-0 = <&spi0_default>;
// pinctrl-1 = <&spi0_sleep>;
// pinctrl-names = "default", "sleep";
// cs-gpios = <&pro_micro 4 GPIO_ACTIVE_HIGH>;
//};
```
Expand All @@ -94,34 +90,12 @@ Remove the forward slashes to resemble the following:

```
nice_view_spi: &spi0 {
compatible = "nordic,nrf-spim";
pinctrl-0 = <&spi0_default>;
pinctrl-1 = <&spi0_sleep>;
pinctrl-names = "default", "sleep";
cs-gpios = <&pro_micro 4 GPIO_ACTIVE_HIGH>;
};
```

Save your changes and close the file.

### Edit the leeloo[_rev2].conf file:

Near the top of the leeloo[_rev2].conf file, locate the following line items:

```
# Uncomment the following line to enable the OLED Display or nice!view Display
# CONFIG_ZMK_DISPLAY=y
```

Remove the # character in front of the CONFIG_ZMK_DISPLAY configuration item to resemble the following:

```
# Uncomment the following line to enable the OLED Display or nice!view Display
CONFIG_ZMK_DISPLAY=y
```

Save your changes and close the file.

### Sample Build Commands for nice!view Displays

Build commands for the default keymap of Leeloo v1:
Expand All @@ -141,8 +115,8 @@ west build -d build/right_v2 -p -b nice_nano_v2 -- -DSHIELD="leeloo_rev2_right n
Build commands for your custom keymap of Leeloo v2:

```
west build -d build/left -p -b nice_nano_v2 -- -DSHIELD="leeloo_rev2_left nice_view_adapter nice_view" -DZMK_CONFIG="/workspaces/zmk-config/[yourNmae]/leeloo_v2/config"
west build -d build/right -p -b nice_nano_v2 -- -DSHIELD="leeloo_rev2_right nice_view_adapter nice_view" -DZMK_CONFIG="/workspaces/zmk-config/[yourNmae]/leeloo_v2/config"
west build -d build/left -p -b nice_nano_v2 -- -DSHIELD="leeloo_rev2_left nice_view_adapter nice_view" -DZMK_CONFIG="/workspaces/zmk-config/[yourName]/leeloo_v2/config"
west build -d build/right -p -b nice_nano_v2 -- -DSHIELD="leeloo_rev2_right nice_view_adapter nice_view" -DZMK_CONFIG="/workspaces/zmk-config/[yourName]/leeloo_v2/config"
```

# Support
Expand Down
8 changes: 4 additions & 4 deletions app/boards/shields/leeloo/leeloo.conf
@@ -1,14 +1,14 @@
# Copyright (c) 2022 The ZMK Contributors
# Copyright (c) 2023 The ZMK Contributors
# SPDX-License-Identifier: MIT

# Uncomment the following line to enable the OLED Display or nice!view Display
# Uncomment the following line to enable the OLED Display
# CONFIG_ZMK_DISPLAY=y

# Uncomment to turn off WPM Status.
# CONFIG_ZMK_WIDGET_WPM_STATUS=n

# Uncomment to invert colour, if using nice!view Displays
# CONFIG_LVGL_USE_THEME_MONO=y
# Uncomment to invert colour when using nice!view Displays
# CONFIG_ZMK_DISPLAY_INVERT=y


# Uncomment these two lines to add support for encoders
Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo/leeloo.dtsi
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand Down
17 changes: 4 additions & 13 deletions app/boards/shields/leeloo/leeloo.keymap
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand All @@ -8,11 +8,6 @@
#include <dt-bindings/zmk/keys.h>
#include <dt-bindings/zmk/bt.h>

// Layers
#define DEFAULT 0 // default_layer
#define LOWER 1 // lower_layer
#define RAISE 2 // raise_layer

/*
* Assign the cs-gpios pin to 4.
* Uncomment these next few lines if implementing nice!view Displays
Expand All @@ -21,10 +16,6 @@
* the pins with Arduino Labels.
*/
//nice_view_spi: &spi0 {
// compatible = "nordic,nrf-spim";
// pinctrl-0 = <&spi0_default>;
// pinctrl-1 = <&spi0_sleep>;
// pinctrl-names = "default", "sleep";
// cs-gpios = <&pro_micro 4 GPIO_ACTIVE_HIGH>;
//};

Expand All @@ -43,7 +34,7 @@
&kp LALT &kp LCTRL &lt 1 RET &lt 2 MINUS &lt 2 EQUAL &lt 1 SPACE &kp BSPC &kp DEL
>;

// sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};

lower_layer {
Expand All @@ -56,7 +47,7 @@
&trans &trans &trans &trans &trans &trans &trans &trans
>;

// sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};

raise_layer {
Expand All @@ -69,7 +60,7 @@
&trans &trans &trans &trans &trans &trans &bt BT_CLR &trans
>;

// sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};

};
Expand Down
9 changes: 4 additions & 5 deletions app/boards/shields/leeloo/leeloo_common.dtsi
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand Down Expand Up @@ -50,22 +50,21 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7)
label = "LEFT_ENCODER";
a-gpios = <&pro_micro 21 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro 20 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
resolution = <2>;
status = "disabled";
steps = <80>;
};

right_encoder: right_encoder {
compatible = "alps,ec11";
label = "RIGHT_ENCODER";
a-gpios = <&pro_micro 20 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro 21 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
resolution = <2>;
status = "disabled";
steps = <80>;
};

sensors {
compatible = "zmk,keymap-sensors";
sensors = <&left_encoder &right_encoder>;
triggers-per-rotation = <30>;
caksoylar marked this conversation as resolved.
Show resolved Hide resolved
};

};
Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo/leeloo_left.overlay
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand Down
8 changes: 4 additions & 4 deletions app/boards/shields/leeloo/leeloo_rev2.conf
@@ -1,14 +1,14 @@
# Copyright (c) 2022 The ZMK Contributors
# Copyright (c) 2023 The ZMK Contributors
# SPDX-License-Identifier: MIT

# Uncomment the following line to enable the OLED Display or nice!view Display
# Uncomment the following line to enable the OLED Display
# CONFIG_ZMK_DISPLAY=y

# Uncomment to turn off WPM Status.
# CONFIG_ZMK_WIDGET_WPM_STATUS=n

# Uncomment to invert colour, if using nice!view Displays
# CONFIG_LVGL_USE_THEME_MONO=y
# Uncomment to invert colour when using nice!view Displays
# CONFIG_ZMK_DISPLAY_INVERT=y


# Uncomment the following line to enable per-key lighting
Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo/leeloo_rev2.dtsi
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand Down
17 changes: 4 additions & 13 deletions app/boards/shields/leeloo/leeloo_rev2.keymap
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand All @@ -9,11 +9,6 @@
#include <dt-bindings/zmk/bt.h>
#include <dt-bindings/zmk/rgb.h>

// Layers
#define DEFAULT 0 // default_layer
#define LOWER 1 // lower_layer
#define RAISE 2 // raise_layer

// Short versions
#define RGBON &rgb_ug RGB_ON
#define RGBOFF &rgb_ug RGB_OFF
Expand All @@ -32,10 +27,6 @@
* Uncomment these next few lines if implementing nice!view Displays
*/
//nice_view_spi: &spi0 {
// compatible = "nordic,nrf-spim";
// pinctrl-0 = <&spi0_default>;
// pinctrl-1 = <&spi0_sleep>;
// pinctrl-names = "default", "sleep";
// cs-gpios = <&pro_micro 4 GPIO_ACTIVE_HIGH>;
//};

Expand All @@ -55,7 +46,7 @@
&kp LALT &kp LCTRL &lt 1 RET &lt 2 MINUS &lt 2 EQUAL &lt 1 SPACE &kp BSPC &kp DEL
>;

// sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};

lower_layer {
Expand All @@ -68,7 +59,7 @@
&trans &trans &trans &trans &trans &trans &trans &trans
>;

// sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};

raise_layer {
Expand All @@ -81,7 +72,7 @@ RGBOFF RGBEFF RGBHUD RGBSAD RGBBRD &trans &trans &tr
&trans &trans &trans &trans &trans &trans &bt BT_CLR &trans
>;

// sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};

};
Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo/leeloo_rev2_left.overlay
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo/leeloo_rev2_right.overlay
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo/leeloo_right.overlay
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 The ZMK Contributors
* Copyright (c) 2023 The ZMK Contributors
* SPDX-License-Identifier: MIT
*/

Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo_micro/Kconfig.defconfig
@@ -1,4 +1,4 @@
# Copyright (c) 2022 The ZMK Contributors
# Copyright (c) 2023 The ZMK Contributors
# SPDX-License-Identifier: MIT

if SHIELD_LEELOO_MICRO_LEFT
Expand Down
2 changes: 1 addition & 1 deletion app/boards/shields/leeloo_micro/Kconfig.shield
@@ -1,4 +1,4 @@
# Copyright (c) 2022 The ZMK Contributors
# Copyright (c) 2023 The ZMK Contributors
# SPDX-License-Identifier: MIT

config SHIELD_LEELOO_MICRO
Expand Down
32 changes: 3 additions & 29 deletions app/boards/shields/leeloo_micro/README.md
Expand Up @@ -37,7 +37,7 @@ west build -d build/right -p -b nice_nano_v2 -- -DSHIELD=leeloo_micro_right
Build commands for your custom keymap of Leeloo-Micro:

```
west build -d build/right -p -b nice_nano_v2 -- -DSHIELD=leeloo_micro_right -DZMK_CONFIG="C:/dev/zmk/[yourNmae]/leeloo_micro/config"
west build -d build/right -p -b nice_nano_v2 -- -DSHIELD=leeloo_micro_right -DZMK_CONFIG="C:/dev/zmk/[yourName]/leeloo_micro/config"
west build -d build/left -p -b nice_nano_v2 -- -DSHIELD=leeloo_micro_left -DZMK_CONFIG="C:/dev/zmk/[yourName]/leeloo_micro/config"
```

Expand All @@ -51,10 +51,6 @@ Near the top 3rd of the leeloo_micro.keymap file, locate the following code bloc

```
//nice_view_spi: &spi0 {
// compatible = "nordic,nrf-spim";
// pinctrl-0 = <&spi0_default>;
// pinctrl-1 = <&spi0_sleep>;
// pinctrl-names = "default", "sleep";
// cs-gpios = <&pro_micro 4 GPIO_ACTIVE_HIGH>;
//};
```
Expand All @@ -63,34 +59,12 @@ Remove the forward slashes to resemble the following:

```
nice_view_spi: &spi0 {
compatible = "nordic,nrf-spim";
pinctrl-0 = <&spi0_default>;
pinctrl-1 = <&spi0_sleep>;
pinctrl-names = "default", "sleep";
cs-gpios = <&pro_micro 4 GPIO_ACTIVE_HIGH>;
};
```

Save your changes and close the file.

### Edit the leeloo_micro.conf file:

Near the top of the leeloo_micro.conf file, locate the following line items:

```
# Uncomment the following line to enable the OLED Display or nice!view Display
# CONFIG_ZMK_DISPLAY=y
```

Remove the # character in front of the CONFIG_ZMK_DISPLAY configuration item to resemble the following:

```
# Uncomment the following line to enable the OLED Display or nice!view Display
CONFIG_ZMK_DISPLAY=y
```

Save your changes and close the file.

### Sample Build Commands for nice!view Displays

Build commands for the default keymap of Leeloo-Micro:
Expand All @@ -103,8 +77,8 @@ west build -d build/right -p -b nice_nano_v2 -- -DSHIELD="leeloo_micro_right nic
Build commands for your custom keymap of Leeloo-Micro:

```
west build -d build/left -p -b nice_nano_v2 -- -DSHIELD="leeloo_micro_left nice_view_adapter nice_view" -DZMK_CONFIG="/workspaces/zmk-config/[yourNmae]/leeloo_micro/config"
west build -d build/right -p -b nice_nano_v2 -- -DSHIELD="leeloo_micro_right nice_view_adapter nice_view" -DZMK_CONFIG="/workspaces/zmk-config/[yourNmae]/leeloo_micro/config"
west build -d build/left -p -b nice_nano_v2 -- -DSHIELD="leeloo_micro_left nice_view_adapter nice_view" -DZMK_CONFIG="/workspaces/zmk-config/[yourName]/leeloo_micro/config"
west build -d build/right -p -b nice_nano_v2 -- -DSHIELD="leeloo_micro_right nice_view_adapter nice_view" -DZMK_CONFIG="/workspaces/zmk-config/[yourName]/leeloo_micro/config"
```

# Support
Expand Down