cancel
Showing results for 
Search instead for 
Did you mean: 

H7 UDP example

APasi
Associate II

Hello,

We run on platform STM32H743ZI and I made new UdpEchoClient application using source STM32H743ZI _EVAL\Applications\LwIP (in other word UdpEchoClient for Nucleo144) without RTOS!

Unfortunately , it doesn't work ...

Maybe you know about any working UdpEchoClient /Server without RTOS (location, download ?

Other question, if Udp (not TCP/Web) example RTOS is available?

PS: When I try to built trivial Ethernet sample using MX (STM32CubeIDE/MX) it says me that LwIP cannot be attached if RTOS is not enabled - ?

Thanks Alexp

18 REPLIES 18

Dear @Pavel A.​  .

I have Nucleo STM32H743 board and program it with example for EVAL board - code don't work.

I want to create UDP client, that send to PC some data ( "Hello world" for example) and in PC via terminal program i will get that data.

Could you give me working code for STM32H743 NUCLEO , may be download it to GITHUB ? Work code will help me so much.

Best regards.

@AAnt.1​ Does it at least respond to ping? Is data cache disabled?

@Pavel A.​ 

"Does it at least respond to ping?" No, that's why i ask you to get me work code.

 For UDP i will use program: "Packet sender", or "Docklight scripting".

I don't have any experience with sending data from STM to PC, thats why i ask you for code with simple transaction some Data (Hello world) from STM to PC.

Best regards.

I have UDP server only, this is what I can share. It does respond to ping.

If your PC runs Windows, disable the firewall.

-- pa

UDP server - it is will be very good for me too.

Hi @AAnt.1​ The project is attached below.

It has two configurations and link scripts, to run in RAM (convenient for debug) and flash.

LwIP is configured for static IP only,

As @Piranha​ wrote so many times, the ethernet link check code related to DHCP in the example is questionable. To avoid any cache related bugs, the cache is disabled =)

An UDP client is included too (python 3.6 script). It generates random packets and the source port is automatic (ephemeral), so it works on Windows 10 with the firewall on.

Enjoy ,

--pa

Pavel A.
Evangelist III

Attachment: LwIP UDP echo server example for Nucleo STM32H743, ported from STM32H43-EVAL2.

It is very close to the original, except of obvious SystemClockInit change and ETH pinout specific for the Nucleo,

and UDP server fix to allow pinging from any client port (not only 7).

Built and tested with Cube H7 library v. 1.9.0, CubeIDE 1.6.0.

Included also a python client script to test the UDP server.

IMPORTANT: the CubeIDE (Eclipse) project has links into the Cube H7 library installed in custom location.

Your library likely will be in a different place, so need to edit the location in the Linked folders (.project) and Build variables (.cproject).

(I don't know how to make Eclipse recognize a linked folder path in Build variables so duplication is necessary).

--pa

Does it work for you?

Hi. I used Wind CMD for ping code - one from four it ping ok.. (i could send code) That,s all(( I don't stoppet to find work code.

Nowadays i look for UDP code for STM32F4 - maybe here i will get possitive result and after this i will come bach to STM32H7