cancel
Showing results for 
Search instead for 
Did you mean: 

Ethernet configuration with MicroROS

USER_RG
Associate II

Hi,
I'm configuring MicroROS on the STM32F767ZI, but I want to set up a connection with the MicroROS agent using the Ethernet connection on the Nucleo F767ZI board.
I followed the guide at this link (see section UDP

https://github.com/micro-ROS/micro_ros_stm32cubemx_utils/tree/jazzy?tab=readme-ov-file#udp 

but I'm having trouble fixing main.c.
I understand that I need to enable ETH and LWIP, but I can't fix main.c using the sample_main_udp.c and sample_main_embeddedrtps.c files.

I'm attaching the project so you can see the files.
Note: I started by configuring usart3 and then regenerated the code, excluding usart3, adding ETH, and configuring LWIP in the middleware.

4 REPLIES 4
mbarg.1
Senior III

I am not deep in MicroROS but, as you are referring to STM32CubeIde, you should have an .ioc file and a project.

If it is correct, you have to use STM32CubeIde to add ETH - or creat a project with ETH - and move to your main.c all HAL funtions call.

ETH requires near real time reactions to work, DMA + IT are mandatory, some kind of threading must work on ETH demand.

Stats built in will show eth activity on rx side.

Once you retrieve eth packets, you can start adding lwIp ( or other libs) for layer 2 and upper.

Andrew Neil
Super User

Before worrying about micro-ROS, are your basic UDP comms working?

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.

I think no, buy pelas tel me as i can check this.

You really need to know that your UDP is working and solid before trying to add anything which relies on it - including micro-ROS !

There are standard networking tools for testing IP, UDP, etc ...

eg, Wireshark

https://simplecomtools.software.informer.com/ 

via: https://www.google.com/search?q=simple+UDP+test+tool

 

ST Knowledge Base articles on STM32F7 + UDP

Previous forum discussions on STM32F7 + UDP

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.