I have created an LCD GUI project using MDK5 porting the STCube
LCD & touch drivers into RTX RTOS task.
I have another task which blinks LEDs based on button presses, which
But when I run net_initialize() my LCD screen goes blank but the
task is still running and the touch input is still working as well.
It is just dark.
My LED blinking\Button RTOS task still functions.
The eth_thread is running, my thread that executes net_main() is also
However I am not getting an IP assigned, but I can troubleshoot that
I enabled net_debug and can see it is trying to request an IP from
the DHCP server.
But my first priority is to figure out why net_initialize is
effecting my LCD.
None of the pins used for the network PHY conflict with the display
in any way that I can tell.
When I run the lwip demo from ST using FreeRTOS it works fine.
If I comment out net_initialize() my LCD and touch screen work
perfectly, as do my other RTOS tasks, that my button and LED
When I configured RL-NET using the configuration wizard I setup
MII mode just it was in my ST lwip example, using the same pins it
was in lwip. So none of those should effect my LCD.
I read an article on this site saying the PIN PI10 needs to be
omitted from the PHY configuration and set back to GPIO mode. But
that was causing the guy problems with Ethernet not working, and that
pin is not used for the LCD or LTDC function.
I am leaning towards at least one of my port pins used for LTDC is
being changed to a different configuration inside
Is there anyway to know what else net_intialize is doing to port pin
Does anyone have any ideas what I can look for?
Could it change the NVIC and disable the HAL_LTDC INT ISR?
Again all the tasks are running after net_initialize() is executed
my LCD screen just goes blank.
net_initialize() initializes the Network stack and also the
interfaces and its associated drivers. Network stack itself does not
directly configure the port pins but leaves this to the drivers.
You can debug the Ethernet driver in order to figure out if there
is any port configuration conflict. Locate the Ethernet driver in
your project under CMSIS Drivers group. Ethernet pin configuration is
typically done in the Initialize function.
Make a simple routine to dump out all the pin configuration
registers, with some decoding, and review the before/after stats
I dumped the MODER reg for the pins used for LCD and they do not
appear to be changing after net_initialize() is executed.
As I was writing this I forgot the STM32F429I-EVAL kit uses an I2C
IO expander for the ethernet INT pin. So I will also check that.
The next thing I was thinking about was if the LCD buffer is being
changed by ethernet init.
The LCD frame buffers are stored in the external SDRAM by the LCD
driver I used from the ST eval. I did not change much to get it to
work with my Keil project.
Frame buffer layer 1 is at 0xC0002000
Frame buffer layer 2 is at 0xC0004000
And I know I have emWin setup in GUIConf.c to allocate the base of
SDRAM at 0xC000000 for emWin.
I will see if I can figure out where the ethernet buffers are
stored. I did not specify them to be placed anywhere so I guess I
would expect them to be in IRAM1 by the compiler by default.
View all questions in Keil forum