Skip to content

Conversation

everedero
Copy link
Contributor

@everedero everedero commented Sep 12, 2025

Initial support for the Apex Pro Mini keyboard,
based on STM32L412.

Copy link
Contributor

@nordicjm nordicjm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this board has hwmv1 remnants that need to go

# Enable HW stack protection
CONFIG_HW_STACK_PROTECTION=y

# enable uart driver
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

capitalise first letters of comments

Comment on lines 19 to 33
# enable USB
CONFIG_USB_DEVICE_STACK_NEXT=y
CONFIG_CDC_ACM_SERIAL_INITIALIZE_AT_BOOT=y
CONFIG_USBD_CDC_ACM_LOG_LEVEL_OFF=y

# enable input keyboard matrix
CONFIG_INPUT=y
CONFIG_INPUT_KEYMAP=y
CONFIG_INPUT_GPIO_KBD_MATRIX=y
# Required because rows are actually columns
CONFIG_INPUT_KBD_MATRIX_16_BIT_ROW=y

# enable spi flash
CONFIG_FLASH=y
CONFIG_SPI_NOR_FLASH_LAYOUT_PAGE_SIZE=4096
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

none of this is needed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, it does not have a debug LED or an UART port, it just has a USB port and some keys, so it feels weird to let them be optional features. But maybe they should be anyway?

Copy link
Contributor

@nordicjm nordicjm Sep 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it has USB then CDC ACM as the console by default is ok, the rest though is not

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On this board, USB will not work without CDC_ACM_SERIAL_INITIALIZE_AT_BOOT, and KBD_MATRIX will not work without INPUT_KBD_MATRIX_16_BIT_ROW. Is there a wait to enforce or to document those dependencies?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the USB ones can stay, the kbd one can be done in Kconfig.defconfig a pseudo example:

if BLAH

config BLAH_OTHER
        default SOMETHING

endif # BLAH

@everedero everedero force-pushed the board/apexpromini branch 4 times, most recently from 2e7ebe0 to 72afde9 Compare September 15, 2025 09:29
@everedero everedero force-pushed the board/apexpromini branch 4 times, most recently from a18ff01 to 249117c Compare September 15, 2025 12:13
@decsny
Copy link
Member

decsny commented Sep 15, 2025

@nashif maybe you can help review since you had your opinions about vendor-prefixes.txt being so important

};

&kbd {
keymap {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can put this straight under the kbd node on line 69 if you want to, no point shuffling nodes around

.. _apexpromini_board:

SteelSeries ApexProMini
#######################
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
#######################
.. zephyr:board:: apexpromini

Comment on lines 2 to 3
name: apexpromini
full_name: SteelSeries Apex Pro Mini
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So it does look like official product name is indeed "Apex Pro Mini" (with spaces) so please use the same spelling everywhere.
Also, given there are spaces, i think apex_pro_mini might be a better suited board name?
Finally, vendor name can be ommited in the board "full name"

Suggested change
name: apexpromini
full_name: SteelSeries Apex Pro Mini
name: apex_pro_mini
full_name: Apex Pro Mini

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you check line wrapping in this file and make it consistent? there's a mix of very aggressive (< 80 characters) and no wrapping at all currently :) 100 characters per line would be good. Thanks!

@everedero everedero force-pushed the board/apexpromini branch 2 times, most recently from afb72ed to 5825a2e Compare September 16, 2025 13:39
Comment on lines 12 to 24
if INPUT_GPIO_KBD_MATRIX

config INPUT_KBD_MATRIX_16_BIT_ROW
default y

endif # INPUT_GPIO_KBD_MATRIX

if FLASH

config SPI_NOR_FLASH_LAYOUT_PAGE_SIZE
default 4096

endif # FLASH
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there's no indentation on Kconfig files, just bring the block one tab back

Comment on lines 14 to 15
config INPUT_KBD_MATRIX_16_BIT_ROW
default y
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since there's only one option in the if block you can change this to

default y if INPUT_GPIO_KBD_MATRIX

keep the whole thing compact, same for the flash option below

flash1: fm25q128c@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <10000000>;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can use DT_FREQ_M

Comment on lines 9 to 16
default y
depends on SPI

config INPUT_KBD_MATRIX_16_BIT_ROW
default y if INPUT_GPIO_KBD_MATRIX

config SPI_NOR_FLASH_LAYOUT_PAGE_SIZE
default 4096 if FLASH
Copy link
Member

@fabiobaltieri fabiobaltieri Sep 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry I realize my comment on this was misleading :-) what I mean is that in Kconfig we don't indent the block inside the "if", not that we don't indent at all, so in this case the lines under config (deulfat y, depends on SPI`) should be indented by one tab

Look at other files maybe, I'm clearly pretty bad at explaining it

fabiobaltieri
fabiobaltieri previously approved these changes Sep 17, 2025
fabiobaltieri
fabiobaltieri previously approved these changes Sep 17, 2025
@kartben
Copy link
Contributor

kartben commented Sep 17, 2025

the latest push I made to the branch should fix the doc issues :)

kartben
kartben previously approved these changes Sep 17, 2025
Copy link
Contributor

@kartben kartben left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 for docs!

, <&gpioc 2 GPIO_ACTIVE_HIGH>
, <&gpioc 3 GPIO_ACTIVE_HIGH>
;
keymap {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

newline missing on line 69

fabiobaltieri
fabiobaltieri previously approved these changes Sep 18, 2025
@kartben
Copy link
Contributor

kartben commented Sep 19, 2025

the latest push I made to the branch should fix the doc issues :)

@everedero you need to add my earlier fix back please :)

https://github.com/zephyrproject-rtos/zephyr/compare/dfdcd043592529dbbe529bf0fc3c8fd7dbecaaf8..d270d070324c6d227beee2ad3895d26932c77582

Initial support for the Apex Pro Mini keyboard,
based on STM32L412.

Signed-off-by: Eve Redero <eve.redero@gmail.com>
Copy link

@kartben kartben requested a review from nordicjm September 22, 2025 08:07
@kartben kartben assigned fabiobaltieri and unassigned mbolivar Sep 22, 2025
@kartben
Copy link
Contributor

kartben commented Sep 22, 2025

Assigning to @fabiobaltieri due to this new board having a strong focus on Input subsystem stuff

@kartben kartben merged commit 6b809c2 into zephyrproject-rtos:main Sep 22, 2025
26 checks passed
@everedero everedero deleted the board/apexpromini branch September 25, 2025 13:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants