2022-12-28 10:41 PM
Hi!
My problem is, that i use a H743 with Eth and USB configured.
Ethernet works fine, till i set up the usb. When i turn on the usb, than the ethernet stops working, because it didn't recognises the messages from eth. The usb is configured in usb_device mode with HID.
I tried to debug the code, the ethernet works, if i leave the initialization code of the stm32cubeide generator in and comment out the device descriptor initialization. I think it is some memory issue.
Somebody knows or can guess what the problem is?
Thanks
Solved! Go to Solution.
2023-02-17 10:26 AM
Hi @DB.7
I don't know if you found a solution already, but we tried to reproduce the behavior you described and we see no issue integrating USB, ETH, LwIP and FreeRTOS together.
You can find in the attachment a very draft but functional example on STM32H723ZG. Maybe it could help you in your investigations.
The most common points to check I think are:
In order to better help, you can share your project (or part of it) to allow us debug it.
2022-12-29 11:39 AM
Which board? If custom, do you have .ioc for it? any pin conflicts?
> I think it is some memory issue.
That is possible because a lot of ETH/LwIP examples use ugly absolute addresses, so the linker cannot detect overlaps.
2022-12-29 12:06 PM
It is a Nucleo-H743ZI board, i did not see any pin conflicts.
2022-12-29 03:45 PM
Just a blind guess - too small stack memory.
But generally... A broken network integration code with a broken USB stack brought together by a code degenerator and you expect it to work? Also you have provided almost no useful information. Are you using RTOS?
2022-12-29 11:41 PM
Yeah, i am using RTOS. I tried also to change the stack size.
The ethernet is working correctly, it stops working, when i configure the usb. If the ethernet and usb is configured and initialized, than the ethernet did not works. Whan i comment out the init value of the device descriptor(linker places it to other area) than the ethernet works(the usb not because of tge descriptor, but the full init sequence is called)
2023-02-17 10:26 AM
Hi @DB.7
I don't know if you found a solution already, but we tried to reproduce the behavior you described and we see no issue integrating USB, ETH, LwIP and FreeRTOS together.
You can find in the attachment a very draft but functional example on STM32H723ZG. Maybe it could help you in your investigations.
The most common points to check I think are:
In order to better help, you can share your project (or part of it) to allow us debug it.
2023-02-18 10:54 AM
If the code is broken, the behavior is almost unpredictable.
For example, as ST USB stack runs in interrupt context, this issue could be impacted by this flaw:
https://community.st.com/s/question/0D53W00001oImr4SAC/bug-stm32-lwip-ethernet-driver-tx-deadlock
Post edited to adhere community guidelines.