Date   

API meeting: agenda

Carles Cufi
 

Hi all,

This week we will look at:

- PWM: Add support for inverted PWM signals
- PR: https://github.com/zephyrproject-rtos/zephyr/pull/20657

- GPIO: Update on progress
- Look at the PRs with driver conversion (https://github.com/zephyrproject-rtos/zephyr/issues/18530)
- Check users of GPIO APIs: https://github.com/zephyrproject-rtos/zephyr/issues/20017
- Tips for converting users can be found here: https://github.com/zephyrproject-rtos/zephyr/issues/20017#issuecomment-549315497 (thanks Peter!)
- Any additional outstanding PRs to topic-gpio

Additional items in the "Triage" column in the GitHub project may be discussed if time permits.
If you want an item included in the meeting, please add it to the GitHub project.

https://github.com/zephyrproject-rtos/zephyr/wiki/Zephyr-Committee-and-Working-Group-Meetings#zephyr-api-discussion
https://github.com/zephyrproject-rtos/zephyr/projects/18
https://docs.google.com/document/d/1lv-8B5QE2m4FjBcvfqAXFIgQfW5oz6306zJ7GIZIWCk/edit

Regards,

Carles


MCP2515 with nRF52832 using zephyr #dts #nrf52832

christophhintz@...
 

Hi I had a question to setup the MCP2515 driver in the zephyr project.

We made a custom board for the decawave DWM1001 module, which uses a nRF52832 chip. They have a device tree file in the zephyr project for this module, so I started with that device tree and configured it for our setup, which is

NRF52832 MCP25625
P0.14 SPI_CS
P0.22 SPI_MISO
P0.31 SPI_MOSI
P0.30 SPI_SCK
P0.27 CAN_RESET
P0.03 CAN_INT

. I attached the devicetree and project file to this post.
The main project file I am using is the can example from zephyr. I only added the pull up for the CAN_RESET GPIO, which I can confirm works. I am not seeing any messages on the SPI pins, which make me suspect that the overlay is incorrect. I just added the mcp into the spi setup in the overlay, from a shield example, I am not to sure if it is correct and what sjw, prop-seg, phase-seg1 and phase-seg2 mean. Any help or pointers are appreciated. The program stops with debug messages "CAN: Device driver not found.".



Re: #stm32 pinmux.c compile failure STM32F407 #stm32

Erwan Gouriou
 

Hi Neo

I'd advise you to have a look to STM32 clock control driver.
It provides MCO support. It might not provide exactly the requested configuration, but at least it would be a working point that you can custom to your own need.

Erwan


On Fri, 8 Nov 2019 at 18:28, <nanjunneo@...> wrote:
Hello guys,

for the board STM32F407 I want to add pin PA8 25 MHz clk output to Etherent Phy. So that I add the following sentence (1)
 
HAL_RCC_MCOConfig(RCC_MCO1, RCC_MCO1SOURCE_HSE, RCC_MCODIV_1)          into the pinmux.c.
 
The rest of code in pinmux.c I copied from stm32f4_dico, except I configure OTG_HS_DM / OTG_HS_DP as virtual port.
 
The compiling fails at the last step:  `HAL_GPIO_Init' is not defined.
[129/134] Linking C executable zephyr/zephyr_prebuilt.elf
FAILED: zephyr/zephyr_prebuilt.elf
.....
.....
/home/neo/ARM-GCC-Toolchain/gcc-arm-none-eabi-8-2019-q3-update-linux/gcc-arm-none-eabi-8-2019-q3-update/bin/../lib/gcc/arm-none-eabi/8.3.1/../../../../arm-none-eabi/bin/ld: modules/stm32/stm32cube/lib..__modules__hal__stm32__stm32cube.a(stm32f4xx_hal_rcc.c.obj): in function `HAL_RCC_MCOConfig':
/home/neo/zephyr_2_0_99/zephyrproject/modules/hal/stm32/stm32cube/stm32f4xx/drivers/src/stm32f4xx_hal_rcc.c:769: undefined reference to `HAL_GPIO_Init'
/home/neo/ARM-GCC-Toolchain/gcc-arm-none-eabi-8-2019-q3-update-linux/gcc-arm-none-eabi-8-2019-q3-update/bin/../lib/gcc/arm-none-eabi/8.3.1/../../../../arm-none-eabi/bin/ld: /home/neo/zephyr_2_0_99/zephyrproject/modules/hal/stm32/stm32cube/stm32f4xx/drivers/src/stm32f4xx_hal_rcc.c:793: undefined reference to `HAL_GPIO_Init'
collect2: error: ld returned 1 exit status
 
The pinmux.c is attaced here. the compile is successful without adding the sentence(1).
 
Do you have any idea? or how can I check it further?
Thank you!
------------------------------------------------------pinmux.c in board file-----------------------------------------------------------------
#include <kernel.h>
#include <device.h>
#include <init.h>
#include <drivers/pinmux.h>
#include <sys/sys_io.h>

#include "stm32f4xx.h"
#include <pinmux/stm32/pinmux_stm32.h>

/* pin assignments for STM32F4DISCOVERY board */
static const struct pin_config pinconf[] = {
 
#ifdef CONFIG_UART_1
{STM32_PIN_PB6, STM32F4_PINMUX_FUNC_PB6_USART1_TX},
{STM32_PIN_PB7, STM32F4_PINMUX_FUNC_PB7_USART1_RX},
#endif /* CONFIG_UART_1 */
 
#ifdef CONFIG_UART_2
{STM32_PIN_PA2, STM32F4_PINMUX_FUNC_PA2_USART2_TX},
{STM32_PIN_PA3, STM32F4_PINMUX_FUNC_PA3_USART2_RX},
#endif /* CONFIG_UART_2 */
 
#ifdef CONFIG_PWM_STM32_2
{STM32_PIN_PA0, STM32F4_PINMUX_FUNC_PA0_PWM2_CH1},
#endif /* CONFIG_PWM_STM32_2 */
 
#ifdef CONFIG_USB_DC_STM32
    { STM32_PIN_PB14, STM32F4_PINMUX_FUNC_PB14_OTG_HS_DM },
    { STM32_PIN_PB15, STM32F4_PINMUX_FUNC_PB15_OTG_HS_DP },
#endif  /* CONFIG_USB_DC_STM32 */
};

static int pinmux_stm32_init(struct device *port)
{
ARG_UNUSED(port);

HAL_RCC_MCOConfig(RCC_MCO1, RCC_MCO1SOURCE_HSE, RCC_MCODIV_1); ----------------------------------------------------------------------(1)

stm32_setup_pins(pinconf, ARRAY_SIZE(pinconf));

return 0;
}

SYS_INIT(pinmux_stm32_init, PRE_KERNEL_1,
CONFIG_PINMUX_STM32_DEVICE_INITIALIZATION_PRIORITY);

Best regards,
Neo


Tomorrow's API meeting: Agenda

Carles Cufi
 

Hi all,

This week we will look at:

- QSPI/jedec API proposal vs SPI API extension:
- https://github.com/zephyrproject-rtos/zephyr/pull/20069
vs
- https://github.com/zephyrproject-rtos/zephyr/pull/20564

- GPIO: Update on progress
- Look at the PRs with driver conversion (https://github.com/zephyrproject-rtos/zephyr/issues/18530)
- Check users of GPIO APIs: https://github.com/zephyrproject-rtos/zephyr/issues/20017
- Tips for converting users can be found here: https://github.com/zephyrproject-rtos/zephyr/issues/20017#issuecomment-549315497 (thanks Peter!)
- Any additional outstanding PRs to topic-gpio

Additional items in the "Triage" column in the GitHub project may be discussed if time permits.
If you want an item included in the meeting, please add it to the GitHub project.

https://github.com/zephyrproject-rtos/zephyr/wiki/Zephyr-Committee-and-Working-Group-Meetings#zephyr-api-discussion
https://github.com/zephyrproject-rtos/zephyr/projects/18
https://docs.google.com/document/d/1lv-8B5QE2m4FjBcvfqAXFIgQfW5oz6306zJ7GIZIWCk/edit

Regards,

Carles


#stm32 pinmux.c compile failure STM32F407 #stm32

nanjunneo@...
 

Hello guys,

for the board STM32F407 I want to add pin PA8 25 MHz clk output to Etherent Phy. So that I add the following sentence (1)
 
HAL_RCC_MCOConfig(RCC_MCO1, RCC_MCO1SOURCE_HSE, RCC_MCODIV_1)          into the pinmux.c.
 
The rest of code in pinmux.c I copied from stm32f4_dico, except I configure OTG_HS_DM / OTG_HS_DP as virtual port.
 
The compiling fails at the last step:  `HAL_GPIO_Init' is not defined.
[129/134] Linking C executable zephyr/zephyr_prebuilt.elf
FAILED: zephyr/zephyr_prebuilt.elf
.....
.....
/home/neo/ARM-GCC-Toolchain/gcc-arm-none-eabi-8-2019-q3-update-linux/gcc-arm-none-eabi-8-2019-q3-update/bin/../lib/gcc/arm-none-eabi/8.3.1/../../../../arm-none-eabi/bin/ld: modules/stm32/stm32cube/lib..__modules__hal__stm32__stm32cube.a(stm32f4xx_hal_rcc.c.obj): in function `HAL_RCC_MCOConfig':
/home/neo/zephyr_2_0_99/zephyrproject/modules/hal/stm32/stm32cube/stm32f4xx/drivers/src/stm32f4xx_hal_rcc.c:769: undefined reference to `HAL_GPIO_Init'
/home/neo/ARM-GCC-Toolchain/gcc-arm-none-eabi-8-2019-q3-update-linux/gcc-arm-none-eabi-8-2019-q3-update/bin/../lib/gcc/arm-none-eabi/8.3.1/../../../../arm-none-eabi/bin/ld: /home/neo/zephyr_2_0_99/zephyrproject/modules/hal/stm32/stm32cube/stm32f4xx/drivers/src/stm32f4xx_hal_rcc.c:793: undefined reference to `HAL_GPIO_Init'
collect2: error: ld returned 1 exit status
 
The pinmux.c is attaced here. the compile is successful without adding the sentence(1).
 
Do you have any idea? or how can I check it further?
Thank you!
------------------------------------------------------pinmux.c in board file-----------------------------------------------------------------
#include <kernel.h>
#include <device.h>
#include <init.h>
#include <drivers/pinmux.h>
#include <sys/sys_io.h>

#include "stm32f4xx.h"
#include <pinmux/stm32/pinmux_stm32.h>

/* pin assignments for STM32F4DISCOVERY board */
static const struct pin_config pinconf[] = {
 
#ifdef CONFIG_UART_1
{STM32_PIN_PB6, STM32F4_PINMUX_FUNC_PB6_USART1_TX},
{STM32_PIN_PB7, STM32F4_PINMUX_FUNC_PB7_USART1_RX},
#endif /* CONFIG_UART_1 */
 
#ifdef CONFIG_UART_2
{STM32_PIN_PA2, STM32F4_PINMUX_FUNC_PA2_USART2_TX},
{STM32_PIN_PA3, STM32F4_PINMUX_FUNC_PA3_USART2_RX},
#endif /* CONFIG_UART_2 */
 
#ifdef CONFIG_PWM_STM32_2
{STM32_PIN_PA0, STM32F4_PINMUX_FUNC_PA0_PWM2_CH1},
#endif /* CONFIG_PWM_STM32_2 */
 
#ifdef CONFIG_USB_DC_STM32
    { STM32_PIN_PB14, STM32F4_PINMUX_FUNC_PB14_OTG_HS_DM },
    { STM32_PIN_PB15, STM32F4_PINMUX_FUNC_PB15_OTG_HS_DP },
#endif  /* CONFIG_USB_DC_STM32 */
};

static int pinmux_stm32_init(struct device *port)
{
ARG_UNUSED(port);

HAL_RCC_MCOConfig(RCC_MCO1, RCC_MCO1SOURCE_HSE, RCC_MCODIV_1); ----------------------------------------------------------------------(1)

stm32_setup_pins(pinconf, ARRAY_SIZE(pinconf));

return 0;
}

SYS_INIT(pinmux_stm32_init, PRE_KERNEL_1,
CONFIG_PINMUX_STM32_DEVICE_INITIALIZATION_PRIORITY);

Best regards,
Neo


Re: OpenOCD on STM32 boards

Lawrence King
 

Hi Marti:

Thanks, setting the udev rules did the trick.

Just so other people know what to do:

$ sudo cp ${HOME}/opt/zephyr-sdk/sysroots/x86_64-pokysdk-linux/usr/share/openocd/contrib/60-openocd.rules /etc/udev/rules.d/
$ sudo udevadm control --reload-rules
$ sudo usermod -aG plugdev $USER

Hi Charles:

This probably should be added somewhere in the 'Getting Started' guide after the Zephyr SDK is installed. It should also be made clear that you don't need to use the compilers in the SDK, but you do need to install the SDK (see the first half of this thread) to get the working version of openocd. I had also put in the rules for pyOCD but these are part of the instructions from pyOCD:

$ git clone https://github.com/mbedmicro/pyOCD.git
$ sudo cp pyOCD/udev/*.rules /etc/udev/rules.d
$ sudo udevadm control --reload
$ sudo udevadm trigger

Lawrence King
Principal Developer
+1(416)627-7302

-----Original Message-----
From: Bolivar, Marti <Marti.Bolivar@nordicsemi.no>
Sent: Tuesday, November 5, 2019 5:51 PM
To: Lawrence King <lawrence.king@irdeto.com>; Zephyr-users@lists.zephyrproject.org
Cc: users@lists.zephyrproject.org
Subject: RE: [Zephyr-users] OpenOCD on STM32 boards

Lawrence King <lawrence.king@irdeto.com> writes:

Hi Marti:

Thanks for your help.
Sure thing!


I had stopped using the zephyr-sdk because I was bisecting the kernel to find a problem, depending on where I was I needed 0.10.0, 0.10.1, 0.10.2 or 0.10.3 versions of the SDK to compile, however when I was using gnuarmemb it worked around this annoyance for me.

I removed openocd (and autoremoved the assorted packages) and installed SDK 0.10.3 into /opt/zephyr-sdk. I also set 'export ZEPHYR_SDK_INSTALL_DIR=/opt/zephyr-sdk' in my bashrc and started a new shell. Quick check and openocd is gone from my path.

The west build went cleanly, and now I have a new error from openocd:

lawrence@VM:~/workspace/rc-demo/zephyrproject/zephyr$ west flash
-- west flash: rebuilding
ninja: no work to do.
-- west flash: using runner openocd
-- runners.openocd: Flashing file:
/home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zep
hyr.hex Open On-Chip Debugger 0.10.0+dev-00992-g3333261df-dirty
(2019-08-16-00:14) Licensed under GNU GPL v2 For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : The selected transport took over low-level target control. The
results might differ compared to plain JTAG/SWD adapter speed: 2000
kHz
adapter_nsrst_delay: 100
srst_only separate srst_nogate srst_open_drain connect_deassert_srst
Info : clock speed 2000 kHz
Error: libusb_open() failed with LIBUSB_ERROR_ACCESS
^^ judging from this, my guess is you need some udev rules to make the USB device accessible to your user.

Marti

Error: open failed


ERROR: command exited with status 1:
/opt/zephyr-sdk/sysroots/x86_64-pokysdk-linux/usr/bin/openocd -s
/opt/zephyr-sdk/sysroots/x86_64-pokysdk-linux/usr/share/openocd/script
s -f
/home/lawrence/workspace/rc-demo/zephyrproject/zephyr/boards/arm/stm32
f746g_disco/support/openocd.cfg -c init -c targets -c 'reset halt' -c
'flash write_image erase
/home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zep
hyr.hex' -c 'reset halt' -c 'verify_image
/home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zep
hyr.hex' -c 'reset run' -c shutdown


This is 'better' than the missing files, but I still haven't successfully flashed the blinky program onto the Nucleo board. Anything else I missed?

Lawrence King
Principal Developer
+1(416)627-7302

-----Original Message-----
From: Bolivar, Marti <Marti.Bolivar@nordicsemi.no>
Sent: Tuesday, November 5, 2019 4:55 PM
To: Lawrence King <lawrence.king@irdeto.com>;
Zephyr-users@lists.zephyrproject.org
Cc: users@lists.zephyrproject.org
Subject: Re: [Zephyr-users] OpenOCD on STM32 boards

"Lawrence King via Lists.Zephyrproject.Org"
<lawrence.king=irdeto.com@lists.zephyrproject.org> writes:

Of course I got complaints about OPENOCD-MISSING, OK, I can fix that:
sudo apt-get install openocd
It's not always wise to trust in your distro's openocd. It has been hard to get support patches merged into upstream openocd, so the downstream version in the Zephyr SDK is usually the right one to use.

Obviously I am doing something silly wrong. Can anyone give me a hint?
Thanks
Use the openocd in the Zephyr SDK. You can do this even if you're not
using the Zephyr SDK's toolchain -- as long as ZEPHYR_SDK_INSTALL_DIR points at a Zephyr SDK install, the build system will use its host tools (like openocd) even if ZEPHYR_TOOLCHAIN_VARIANT != zephyr.


Re: Shell over WebUSB

Andrei
 

Hi Markus,

On Thu, Nov 07, 2019 at 07:59:02AM +0000, Becker Markus wrote:
Hi,

I have enjoyed the WebUSB sample application and it works nicely as
expected.

Is there a possibility to bind the Zephyr Shell to WebUSB?
Yes, I had some dirty hacks working, never went upstream, the JS part is
still here: https://github.com/finikorg/webusb-zephyr-demo

I saw that the webusb.c/.h files are in the samples directory. Is it
planned that they live in subsys/usb/class/ and can enabled in parallel to
e.g. CDC-ACM?
webusb defines interface with 2 endpoints just for tests, to put it to
class we need some Spec.

Probably for the shell you could implement subsys/shell/shell_webusb.c
similar to shell_telnet.c or shell_uart.c.

We can probably create also third endpoint for logs and have special log
screen...

I have created issue for that: https://github.com/zephyrproject-rtos/zephyr/issues/20409

Best regards
Andrei Emeltchenko


Shell over WebUSB

Becker Markus
 

Hi,

 

I have enjoyed the WebUSB sample application and it works nicely as expected.

 

Is there a possibility to bind the Zephyr Shell to WebUSB?

 

I saw that the webusb.c/.h files are in the samples directory. Is it planned that they live in subsys/usb/class/ and can enabled in parallel to e.g. CDC-ACM?

 

Thanks,

Markus


The contents of this e-mail and any attachments are confidential to the intended recipient. They may not be disclosed to or used by or copied in any way by anyone other than the intended recipient. If this e-mail is received in error, please immediately notify the sender and delete the e-mail and attached documents. Please note that neither the sender nor the sender's company accept any responsibility for viruses and it is your responsibility to scan or otherwise check this e-mail and any attachments.


Re: OpenOCD on STM32 boards

Bolivar, Marti
 

Lawrence King <lawrence.king@irdeto.com> writes:

Hi Marti:

Thanks for your help.
Sure thing!


I had stopped using the zephyr-sdk because I was bisecting the kernel to find a problem, depending on where I was I needed 0.10.0, 0.10.1, 0.10.2 or 0.10.3 versions of the SDK to compile, however when I was using gnuarmemb it worked around this annoyance for me.

I removed openocd (and autoremoved the assorted packages) and installed SDK 0.10.3 into /opt/zephyr-sdk. I also set 'export ZEPHYR_SDK_INSTALL_DIR=/opt/zephyr-sdk' in my bashrc and started a new shell. Quick check and openocd is gone from my path.

The west build went cleanly, and now I have a new error from openocd:

lawrence@VM:~/workspace/rc-demo/zephyrproject/zephyr$ west flash
-- west flash: rebuilding
ninja: no work to do.
-- west flash: using runner openocd
-- runners.openocd: Flashing file: /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex
Open On-Chip Debugger 0.10.0+dev-00992-g3333261df-dirty (2019-08-16-00:14)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
adapter speed: 2000 kHz
adapter_nsrst_delay: 100
srst_only separate srst_nogate srst_open_drain connect_deassert_srst
Info : clock speed 2000 kHz
Error: libusb_open() failed with LIBUSB_ERROR_ACCESS
^^ judging from this, my guess is you need some udev rules to make the
USB device accessible to your user.

Marti

Error: open failed


ERROR: command exited with status 1: /opt/zephyr-sdk/sysroots/x86_64-pokysdk-linux/usr/bin/openocd -s /opt/zephyr-sdk/sysroots/x86_64-pokysdk-linux/usr/share/openocd/scripts -f /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/boards/arm/stm32f746g_disco/support/openocd.cfg -c init -c targets -c 'reset halt' -c 'flash write_image erase /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex' -c 'reset halt' -c 'verify_image /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex' -c 'reset run' -c shutdown


This is 'better' than the missing files, but I still haven't successfully flashed the blinky program onto the Nucleo board. Anything else I missed?

Lawrence King
Principal Developer
+1(416)627-7302

-----Original Message-----
From: Bolivar, Marti <Marti.Bolivar@nordicsemi.no>
Sent: Tuesday, November 5, 2019 4:55 PM
To: Lawrence King <lawrence.king@irdeto.com>; Zephyr-users@lists.zephyrproject.org
Cc: users@lists.zephyrproject.org
Subject: Re: [Zephyr-users] OpenOCD on STM32 boards

"Lawrence King via Lists.Zephyrproject.Org"
<lawrence.king=irdeto.com@lists.zephyrproject.org> writes:

Of course I got complaints about OPENOCD-MISSING, OK, I can fix that:
sudo apt-get install openocd
It's not always wise to trust in your distro's openocd. It has been hard to get support patches merged into upstream openocd, so the downstream version in the Zephyr SDK is usually the right one to use.

Obviously I am doing something silly wrong. Can anyone give me a hint?
Thanks
Use the openocd in the Zephyr SDK. You can do this even if you're not using the Zephyr SDK's toolchain -- as long as ZEPHYR_SDK_INSTALL_DIR points at a Zephyr SDK install, the build system will use its host tools (like openocd) even if ZEPHYR_TOOLCHAIN_VARIANT != zephyr.


Re: OpenOCD on STM32 boards

Lawrence King
 

Hi Marti:

Thanks for your help.

I had stopped using the zephyr-sdk because I was bisecting the kernel to find a problem, depending on where I was I needed 0.10.0, 0.10.1, 0.10.2 or 0.10.3 versions of the SDK to compile, however when I was using gnuarmemb it worked around this annoyance for me.

I removed openocd (and autoremoved the assorted packages) and installed SDK 0.10.3 into /opt/zephyr-sdk. I also set 'export ZEPHYR_SDK_INSTALL_DIR=/opt/zephyr-sdk' in my bashrc and started a new shell. Quick check and openocd is gone from my path.

The west build went cleanly, and now I have a new error from openocd:

lawrence@VM:~/workspace/rc-demo/zephyrproject/zephyr$ west flash
-- west flash: rebuilding
ninja: no work to do.
-- west flash: using runner openocd
-- runners.openocd: Flashing file: /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex
Open On-Chip Debugger 0.10.0+dev-00992-g3333261df-dirty (2019-08-16-00:14)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
adapter speed: 2000 kHz
adapter_nsrst_delay: 100
srst_only separate srst_nogate srst_open_drain connect_deassert_srst
Info : clock speed 2000 kHz
Error: libusb_open() failed with LIBUSB_ERROR_ACCESS
Error: open failed


ERROR: command exited with status 1: /opt/zephyr-sdk/sysroots/x86_64-pokysdk-linux/usr/bin/openocd -s /opt/zephyr-sdk/sysroots/x86_64-pokysdk-linux/usr/share/openocd/scripts -f /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/boards/arm/stm32f746g_disco/support/openocd.cfg -c init -c targets -c 'reset halt' -c 'flash write_image erase /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex' -c 'reset halt' -c 'verify_image /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex' -c 'reset run' -c shutdown


This is 'better' than the missing files, but I still haven't successfully flashed the blinky program onto the Nucleo board. Anything else I missed?

Lawrence King
Principal Developer
+1(416)627-7302

-----Original Message-----
From: Bolivar, Marti <Marti.Bolivar@nordicsemi.no>
Sent: Tuesday, November 5, 2019 4:55 PM
To: Lawrence King <lawrence.king@irdeto.com>; Zephyr-users@lists.zephyrproject.org
Cc: users@lists.zephyrproject.org
Subject: Re: [Zephyr-users] OpenOCD on STM32 boards

"Lawrence King via Lists.Zephyrproject.Org"
<lawrence.king=irdeto.com@lists.zephyrproject.org> writes:

Of course I got complaints about OPENOCD-MISSING, OK, I can fix that:
sudo apt-get install openocd
It's not always wise to trust in your distro's openocd. It has been hard to get support patches merged into upstream openocd, so the downstream version in the Zephyr SDK is usually the right one to use.

Obviously I am doing something silly wrong. Can anyone give me a hint?
Thanks
Use the openocd in the Zephyr SDK. You can do this even if you're not using the Zephyr SDK's toolchain -- as long as ZEPHYR_SDK_INSTALL_DIR points at a Zephyr SDK install, the build system will use its host tools (like openocd) even if ZEPHYR_TOOLCHAIN_VARIANT != zephyr.


Re: OpenOCD on STM32 boards

Bolivar, Marti
 

"Lawrence King via Lists.Zephyrproject.Org"
<lawrence.king=irdeto.com@lists.zephyrproject.org> writes:

Of course I got complaints about OPENOCD-MISSING, OK, I can fix that:
sudo apt-get install openocd
It's not always wise to trust in your distro's openocd. It has been hard
to get support patches merged into upstream openocd, so the downstream
version in the Zephyr SDK is usually the right one to use.

Obviously I am doing something silly wrong. Can anyone give me a hint?
Thanks
Use the openocd in the Zephyr SDK. You can do this even if you're not
using the Zephyr SDK's toolchain -- as long as ZEPHYR_SDK_INSTALL_DIR
points at a Zephyr SDK install, the build system will use its host tools
(like openocd) even if ZEPHYR_TOOLCHAIN_VARIANT != zephyr.


Zephyr Release 2.1: Status: Merge window closing this Friday, Nov 8th!

David Leach
 

A reminder that the feature merge window to Zephyr will be closing this Friday (November 8th). For more information on milestone dates please refer to the program management wiki page:

 

https://github.com/zephyrproject-rtos/zephyr/wiki/Program-Management

 

If there are outstanding PRs that the authors want in the 2.1 release than tag them with the “v2.1.0” milestone and work with the maintainers to approve and merge the PR.

 

Issues statistics:

 

Priority

Count

Change from last week

High

2

-

Medium

38

+1

Low

161

+9

No priority

2

-1

 

Over the last 4 weeks we have opened 99 new issues and closed 127 with 203 active issues.

 

Note that the release criteria includes zero high priority bugs and <20 medium priority bugs so if you are assigned a bug in these priority buckets please give them the appropriate attention.

 

David Leach

 

NXP Semiconductors

phone: +1.210.241.6761

Email: david.leach@...

 

 


OpenOCD on STM32 boards

Lawrence King
 

Today I decided to bring up a STLML476 board, specifically the Nucleo-L476RG board.

 

Compile went cleanly

west build -b nucleo_l476rg samples/basic/blinky

Then after connecting the board I tried

              west flash

Of course I got complaints about OPENOCD-MISSING, OK, I can fix that:

              sudo apt-get install openocd

And openocd and a few other packages happily  installed.

 

Now ‘west flash’ complains:

-- west flash: rebuilding

ninja: no work to do.

-- west flash: using runner openocd

-- runners.openocd: Flashing file: /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex

Open On-Chip Debugger 0.10.0

Licensed under GNU GPL v2

For bug reports, read

              http://openocd.org/doc/doxygen/bugs.html

/home/lawrence/workspace/rc-demo/zephyrproject/zephyr/boards/arm/nucleo_l476rg/support/openocd.cfg:1: Error: Can't find board/st_nucleo_l4.cfg

in procedure 'script'

at file "embedded:startup.tcl", line 60

at file "/home/lawrence/workspace/rc-demo/zephyrproject/zephyr/boards/arm/nucleo_l476rg/support/openocd.cfg", line 1

ERROR: command exited with status 1: /usr/bin/openocd -f /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/boards/arm/nucleo_l476rg/support/openocd.cfg -c init -c targets -c 'reset halt' -c 'flash write_image erase /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex' -c 'reset halt' -c 'verify_image /home/lawrence/workspace/rc-demo/zephyrproject/zephyr/build/zephyr/zephyr.hex' -c 'reset run' -c shutdown

 

 

The top of the openocd.cfg files (line 1) says:

source [find board/st_nucleo_l4.cfg]

 

I hunted around for the ‘missing’ file “board/st_nucleo_l4.cfg” to no avail. I also tried several other boards that use openocd and found similar missing include files.

 

I did confirm that the board is correctly connected and visible:

$ sudo lsusb

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 002 Device 008: ID 0483:374b STMicroelectronics ST-LINK/V2.1 (Nucleo-F103RB)

Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

 

Obviously I am doing something silly wrong. Can anyone give me a hint? Thanks

 

 

Lawrence King

Principal Developer

Connected Transport Market Unit

https://www.Irdeto.com

+1(416)627-7302

 

1  2 - linkedin  3 - instagram  4 - youtube  6 - facebook  7

            

CONFIDENTIAL: This e-mail and any attachments are confidential and intended solely for the use of the individual(s) to whom it is addressed. It can contain proprietary confidential information and be subject to legal privilege and/or subject to a non-disclosure Agreement. Unauthorized use, disclosure or copying is strictly prohibited. If you are not the/an addressee and are in possession of this e-mail, please delete the message and notify us immediately. Please consider the environment before printing this e-mail. Thank you.

 

 

 


API meeting: agenda

Carles Cufi
 

Hi all,

This week we will look at GPIO:

- GPIO: Update on progress
- Look at the PRs with driver conversion (https://github.com/zephyrproject-rtos/zephyr/issues/18530)
- Check users of GPIO APIs: https://github.com/zephyrproject-rtos/zephyr/issues/20017
- Tips for converting users can be found here: https://github.com/zephyrproject-rtos/zephyr/issues/20017#issuecomment-549315497 (thanks Peter!)
- Any additional outstanding PRs to topic-gpio

Additional items in the "Triage" column in the GitHub project may be discussed if time permits.
If you want an item included in the meeting, please add it to the GitHub project.

https://github.com/zephyrproject-rtos/zephyr/wiki/Zephyr-Committee-and-Working-Group-Meetings#zephyr-api-discussion
https://github.com/zephyrproject-rtos/zephyr/projects/18
https://docs.google.com/document/d/1lv-8B5QE2m4FjBcvfqAXFIgQfW5oz6306zJ7GIZIWCk/edit

Regards,

Carles


Re: A question about configuring a USB virtual console in DTS? #dts #defconfig

Andrei
 

Hi,

On Mon, Nov 04, 2019 at 02:06:04PM -0800, nanjunneo@gmail.com wrote:
Is it compulsory to add the node "virtualcom" to configure a USB virtual
com port via USB-OTG-HS for STM32F407 under Zephyr 2.0.99?

I got the following code in DTS from a partner but it cannot be built
properly. Error indicates that virtualcom does not have necessary
properties. (It is said that the code was compiled in version 1.13.0.)
.......
    usb_cdc: virtualcom {
        label = "CDC_ACM";
    };
You can just remove virtualcom stuff,
samples/subsys/usb/console/prj.conf should assign right console with:

CONFIG_UART_CONSOLE_ON_DEV_NAME="CDC_ACM_0"

Best regards
Andrei Emeltchenko


    chosen {
        zephyr,console = &usb_cdc;
        zephyr,sram = &sram0;
        zephyr,flash = &flash0;
        zephyr,ccm = &ccm0;
    };
.......
......
&usbotg_hs {
    status = "ok";
};

Moreover, the sample code (usb/console) only requires to add configure
entries to defconfig so that I got confused. Thanks for your reply in
advance!
_._,_._,_


A question about configuring a USB virtual console in DTS? #dts #defconfig

nanjunneo@...
 

Is it compulsory to add the node "virtualcom" to configure a USB virtual com port via USB-OTG-HS for STM32F407 under Zephyr 2.0.99?

I got the following code in DTS from a partner but it cannot be built properly. Error indicates that virtualcom does not have necessary properties. (It is said that the code was compiled in version 1.13.0.)
.......
    usb_cdc: virtualcom {
        label = "CDC_ACM";
    };

    chosen {
        zephyr,console = &usb_cdc;
        zephyr,sram = &sram0;
        zephyr,flash = &flash0;
        zephyr,ccm = &ccm0;
    };
.......
......
&usbotg_hs {
    status = "ok";
};

Moreover, the sample code (usb/console) only requires to add configure entries to defconfig so that I got confused. Thanks for your reply in advance!


Re: Error in services launch sequence #debugging #eclipse #gdb

fashtop3@...
 

All I did was to uncheck the "start pyOCD locally"


Zephyr Release 2.1: Status: Merge window closing Nov 8th

David Leach
 

A reminder that the feature merge window to Zephyr will be closing next Friday (November 8th). For more information on milestone dates please refer to the program management wiki page:

 

https://github.com/zephyrproject-rtos/zephyr/wiki/Program-Management

 

 

Issues statistics:

 

Priority

Count

Change from last week

High

2

-

Medium

37

+1

Low

152

+2

Uncategorized

3

+3

 

Over the last 4 weeks we have opened 103 new issues and closed 123 with 194 active issues.

 

Note that the release criteria includes zero high priority bugs and <20 medium priority bugs so if you are assigned a bug in these priority buckets please give them the appropriate attention.

 

 

 

David Leach

 

NXP Semiconductors

phone: +1.210.241.6761

Email: david.leach@...

 

 


Logger flash backend

Ilan Ganor <ilan@...>
 

Hello 


Nordic presented some of their implementations using the Logger framework which support features like:

logger backend flash (saving logger data to flash)
and save logger definitions 

those are very valuable features

does anyone knows: 

1. if and where can I get this code ?

2. is Zephyr planning to support that officially (currently there is support for Serial, Telnet and RTT)

thank you 


Zephyr Release 2.1: Status

David Leach
 

A reminder that the feature merge window to Zephyr will be closing on November 8th (two short weeks away). Please keep this date in mind for any items you may be working on that you wish to be included in the 2.1 release. For more information on milestone dates please refer to the program management wiki page:

 

https://github.com/zephyrproject-rtos/zephyr/wiki/Program-Management

 

 

Issues statistics:

 

Priority

Count

Change from last week

High

2

+1

Medium

36

+2

Low

150

-12

 

Over the last 4 weeks we have opened 90 new issues and closed 126 with 188 active issues.

 

Note that the release criteria includes zero high priority bugs and <20 medium priority bugs so if you are assigned a bug in these priority buckets please give them the appropriate attention.

 

David Leach

 

NXP Semiconductors

phone: +1.210.241.6761

Email: david.leach@...

 

 

801 - 820 of 2575