Loading...
 

Zephyr project on STM32

   Zephyr Workbench, a VSCode extension to manage Zephyr on STM32.
It enables users to easily create, develop, and debug Zephyr applications.
Main features:
  • Install host dependencies.
  • Import toolchain and SDK.
  • Create, configure, build and manage apps.
  • Debug STM32.
You can directly download it from the VSCode marketplace
For more details, visit the Zephyr Workbench

System Workbench for STM32


LWiP debug output not working...

hoping someone might be able to help....
Im trying to enable debug output from LWIP , but having troubles. Im working with the NucleoF767ZI board, but I dont imagine this issue is specific.

I’ve setup a project via CubeMX, imported into SW4STM32 and things are starting to look OK, RTOS is up and running, LWIP appears on the network so is up an running also. Now I’d like to enable some debug out from LWIP.

printf has been rerouted to UART3 for debug via the virtual COM. From what I learned it should be able to use the printf when enabled and output some debug.

in the lwipopts.h I added code to enable it ;

  1. define LWIP_DEBUG 1
  2. define ETHARP_DEBUG LWIP_DBG_ON
  3. define NETIF_DEBUG LWIP_DBG_ON
  4. define ICMP_DEBUG LWIP_DBG_ON
  5. define IP_DEBUG LWIP_DBG_ON


No luck so far with this, I have to be missing something here... let me know any ideas please :-)

Hey vikas,

I realize my response is super late, but have you implemented the platform printf in the “cc.h” file?

Assuming you have a printf funct working, you need something like this in the “cc.h” file:

“#define LWIP_PLATFORM_DIAG(message)     do { printf message; } while(0)”

Hope this helps.

EDIT: Formatting.


Hi,

Its quite timely actually- Id occupied myself with getting the USB OTG up and running in the meantime and just came back to wondering about the lwip debug today.

Good news, I added the line as you suggest and looks like it was all that was missing. Now I see the debug from USB and LWIP during startup as desired. Awesome!

I’ll have to add this one to my notebook, thanks for the pointer!

Vik