Error: "Unsupported board: sw0 devicetree alias is not defined" in Button Sample #81266
-
Message: Hi Zephyr Community, I'm building the button sample for the mec15xxevb_assy6853 board, but I encountered the following error: /home/jayesh/zephyrproject/zephyr/samples/basic/button/src/main.c:117:2: error: #error "Unsupported board: sw0 devicetree alias is not defined" It seems like the sw0 devicetree alias is not defined in the configuration. How can I resolve this issue or define the alias for the button (sw0) in the devicetree? Any guidance would be greatly appreciated! |
Beta Was this translation helpful? Give feedback.
Replies: 9 comments 20 replies
-
Hello, sw0 is not defined in devicetree for this board, so you have to create an overlay and define a button and it's alias yourself. |
Beta Was this translation helpful? Give feedback.
-
Hi, I have already cross-checked with the MEC1501 datasheet but couldn’t find clear information about these values or how they relate to the board's GPIO configuration. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Hi adahn I'm encountering errors when trying to build my Zephyr application for controlling an LED using PWM. and i am using the mec1521 assy 6883 board only . Below are the details of my configuration: Device Tree Configuration: /* Define PWM channel for LED2 / Errors Encountered:
|
Beta Was this translation helpful? Give feedback.
-
I recently updated the repository with the suggestions provided, and now when I try to build the application for the mec15xxevb_assy6853 board, I'm encountering the following error: CMake Error at /home/jayesh/zephyrproject/zephyr/cmake/modules/dts.cmake:311 (message): devicetree error: Call Stack (most recent call first): The error points to a parse issue in the mec15xxevb_assy6853_mec1501_hsz.overlay file at line 46. The expected format seems to be a / or label reference, but I'm not sure what went wrong in the overlay configuration. Has anyone faced a similar issue? Could you suggest possible solutions or guide me in troubleshooting this parse error? Here is the updated repository link: https://github.com/leenaarora18/pwm_updated_version_1.git Thank you for your help! |
Beta Was this translation helpful? Give feedback.
-
It's very hard to follow your code, you have 2 files with the same name -
|
Beta Was this translation helpful? Give feedback.
-
I am facing the following error while building the Zephyr blinky_pwm sample application: from /home/jayesh/zephyrproject/zephyr/samples/basic/blinky_pwm/src/main.c:14: I have ensured that the project configuration includes CONFIG_PWM=y, but the errors persist. How can I resolve this issue? Is there anything specific that needs to be added to the device tree or overlay file to define the pwm_led0 alias correctly? For reference, here is the updated link to the repository: https://github.com/leenaarora18/plinky_pwm_version_2.git |
Beta Was this translation helpful? Give feedback.
-
Can you suggest me please ? |
Beta Was this translation helpful? Give feedback.
-
Hi adahn , Issue with Intel Raptor Lake and MEC1521 SPI Image Flashing: I'm working with Intel Raptor Lake and using the open-source ECFW Zephyr (https://github.com/intel/ecfw-zephyr) to generate the ksc.bin file. Here’s what I did: Cloned the CPGZephyrDocs repository and added the necessary SPI image generation files. Set the environment variable for everglades_spi_gen_RomE. Successfully built the project using west build -c -p auto -b mec1501_mtl_p, which generated the ksc.bin file. Stitched the ksc.bin with Intel BIOS and flashed it using Dediprogrammer onto the Intel Raptor Lake S board. After flashing, both the CPU fan and ATX fan started working, and the power sequence voltages were active, but the system did not boot. However, these signals (CPU fan, ATX fan, and power sequence) only activate when I manually touch the RSMRST signal using a multimeter. Any insights on why the system isn't booting after flashing? |
Beta Was this translation helpful? Give feedback.
According to zephyr/include/zephyr/dt-bindings/gpio/microchip-xec-gpio.h file, for example
MCHP_GPIO_DECODE_156
goes toXEC_GPIO_HELPER(&gpio_140_176, 14)
which goes to&gpio_140_176, 14
which can be rewritten as&gpio_140_176, 0xE
. SoMCHP_GPIO_DECODE_156
macro means&gpio_140_176, 14
.