cancel
Showing results for 
Search instead for 
Did you mean: 

Working LwIP RTOS BSD stack example for STM32F767 Nucleo-144 for Makefile toolchain?

MBrai.1
Associate

Hi,

I appreciate that you have a bunch of examples on the LwIP for this board and other boards, but I'm having a great deal of difficulty compiling any of them under Linux. My tool chain is STM32CubeMX, and I'm using Ac6 (eclipse) to compile the projects into a binary.

The examples provided don't have ioc files, and only basic guidance on how to setup the networking in STM32CubeMX, like small notes like use the default timers etc. There is also no makefile provided with the project LwIPexamples, which makes compilation problematic for me.

What I would like is to use RTOS with a simple network example using BSD sockets, to open up a socket, bind to a power, listen and accept a connection, nothing complicated, I'd be satisfied with just an LED turning on when some data is received on that port.

However, I seem to keep getting stuck with numerous issues. I can't work out if I need to be using RTOS 1 or RTOS 2. I can't seem to find any guidance on this, which should i use? When I create a project with STM32CubeMX, it doesn't compile by default anymore (it used to), because there are missing variables like:

PHY_MICR / PHY_MICR_INT_EN / PHY_MICR_INT_OE etc. Now I can find those in the stm32f7xx_hal_conf_template.h file, and if I copy the variables out of there into my stm32f7xx_hal_conf.h, yes it compiles, but i still can't get any networking working, no ping, no sign of life. The network lights are on, but the network configuration gets stuck in netif_add() from which it just never seems to return. Also I wonder if I'm hacking the conf file headers, whether it's correctly configured in STM32CubeMX. My worry is that I'm not entirely sure how it works, if the software is configured to receive and interrupt and the hardware isn't setup to send one, then that could be a problem too!

The problem is that the number of settings and combinations involved in getting networking working that I've spent about 2 weeks guessing combinations and settings. All this could have been avoided with some basic ioc and some makefiles, then it would have been possible to compile one of your examples in my toolchain.

Is there any guidance on how to set things up in STM32CubeMX for this scenario, because if I got that right, this would eliminate a lot of the guesswork. Is there any documentation or guidance on this?

Kind regards!

P.s. it's not a serious problem, but there's a bug in the Makefile generation from STM32CubeMX, sometimes the makefile is generated with duplicate file entries, so may not necessarily compile first time. Do you know about this bug?

0 REPLIES 0