Will RT-STM32-LWIP-FATFS-USB demo work on Nucleo-144 NUCLEO-F207ZG ?
Whether there is another example for LwIP on this board or for NUCLEO-F429ZI ?
LwIP demo for Nucleo-144
Moderators: RoccoMarco, lbednarz, utzig, tfAteba, barthess
- Giovanni
- Site Admin
- Posts: 14455
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1076 times
- Been thanked: 922 times
- Contact:
Re: LwIP demo for Nucleo-144
Hi,
There is an "unified" lwIP demo in trunk, those boards could be added easily but currently are not supported.
Giovanni
There is an "unified" lwIP demo in trunk, those boards could be added easily but currently are not supported.
Giovanni
Re: LwIP demo for Nucleo-144
I have run this example on Nucleo-144, DHCP and ping is working correctly.
I have problem with HTTP server example thread, in netconn_new(NETCONN_TCP) I got timeout and WDG reset, other tasks has stop working. WDG has 1s period.
In function sys_arch_sem_wait(&apimsg->msg.conn->op_completed, 0); at line if (chSemWaitTimeoutS(*sem, tmo) != MSG_OK)
Could you explain why ? Is it LwIP misconfiguration ?
I have problem with HTTP server example thread, in netconn_new(NETCONN_TCP) I got timeout and WDG reset, other tasks has stop working. WDG has 1s period.
In function sys_arch_sem_wait(&apimsg->msg.conn->op_completed, 0); at line if (chSemWaitTimeoutS(*sem, tmo) != MSG_OK)
Could you explain why ? Is it LwIP misconfiguration ?
Code: Select all
u32_t sys_arch_sem_wait(sys_sem_t *sem, u32_t timeout) {
systime_t tmo, start, remaining;
osalSysLock();
tmo = timeout > 0 ? MS2ST((systime_t)timeout) : TIME_INFINITE;
start = osalOsGetSystemTimeX();
if (chSemWaitTimeoutS(*sem, tmo) != MSG_OK) {
osalSysUnlock();
return SYS_ARCH_TIMEOUT;
}
remaining = osalOsGetSystemTimeX() - start;
osalSysUnlock();
return (u32_t)ST2MS(remaining);
}
- Giovanni
- Site Admin
- Posts: 14455
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1076 times
- Been thanked: 922 times
- Contact:
Re: LwIP demo for Nucleo-144
Hi,
You should check for stack overflow or other possible problems. I don't have enough info to tell why it is timing out.
Giovanni
You should check for stack overflow or other possible problems. I don't have enough info to tell why it is timing out.
Giovanni
Re: LwIP demo for Nucleo-144
My stack size is 0x8000.
Without debug functions, DHCP, ping works and led blink/WDG tasks correctly.
I have enabled DBG functions. Without LwIP initialization I got chSysHalt with reason S at this call stack
With enalbled LwIP: lwipInit(NULL); I got chSysHalt with reason S at this call stack
Why idle task has chSysHalt ?
Without debug functions, DHCP, ping works and led blink/WDG tasks correctly.
I have enabled DBG functions. Without LwIP initialization I got chSysHalt with reason S at this call stack
Code: Select all
chSysHalt
_dbg_check_enter_isr
VectorB0
<Exception frame>
_idle_thread
[_port_thread_start + 0x9]
With enalbled LwIP: lwipInit(NULL); I got chSysHalt with reason S at this call stack
Code: Select all
chSysHalt
_dbg_check_lock
chSysLock
chMtxLock
chHeapAllocAligned
chHeapAlloc
sys_sem_new
mem_init
lwip_init
tcpip_init
lwip_thread
[_port_thread_start + 0x9]
Why idle task has chSysHalt ?
- Giovanni
- Site Admin
- Posts: 14455
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1076 times
- Been thanked: 922 times
- Contact:
Re: LwIP demo for Nucleo-144
Hi,
The reason is a string, look for what is after that "S".
Moving this topic in "bug reports".
Giovanni
The reason is a string, look for what is after that "S".
Moving this topic in "bug reports".
Giovanni
Re: LwIP demo for Nucleo-144
For clarification:
In LWIP-FATFS-USB example I got chSysHalt SV#4 or SV#8 only in code compiled with IAR compiler, when http_server task is enabled, without this task ping works. Probably #pragma data_alignment is missing ?
The same code works correctly under GCC 6.3 compiled.
Tested with ChibiOS 17.6 and Nucleo-F429ZI
ps. Do you have plans to release makefile for IAR compiler. There is very nice IAR plugin for Eclipse.
In LWIP-FATFS-USB example I got chSysHalt SV#4 or SV#8 only in code compiled with IAR compiler, when http_server task is enabled, without this task ping works. Probably #pragma data_alignment is missing ?
The same code works correctly under GCC 6.3 compiled.
Tested with ChibiOS 17.6 and Nucleo-F429ZI
ps. Do you have plans to release makefile for IAR compiler. There is very nice IAR plugin for Eclipse.
- Giovanni
- Site Admin
- Posts: 14455
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1076 times
- Been thanked: 922 times
- Contact:
Re: LwIP demo for Nucleo-144
How do you enable the debug options? in chconf.h or project options?
It would be nice to create a rules.ml for IAR but it is not high priority.
Giovanni
It would be nice to create a rules.ml for IAR but it is not high priority.
Giovanni
Re: LwIP demo for Nucleo-144
I enabled it in chconf.h file
Will only two Makefile files be dedicated for IAR? Like in GCC ?
Will the others remain unchanged?
Will only two Makefile files be dedicated for IAR? Like in GCC ?
Code: Select all
$(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk/startup_stm32f4xx.mk
$(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
Will the others remain unchanged?
Who is online
Users browsing this forum: No registered users and 11 guests