After successfully implementing the MACDriver for my mcu, I wanted to try the webserver using lwip. I am using a simulator for my mcu which uses the host machine's linux loopback-interface. I copied the webserver from the ARMCM3-STM32F107-LWIP demo.
My main looks like this:
Code: Select all
halInit();
chSysInit();
chThdCreateStatic(wa_lwip_thread, LWIP_THREAD_STACK_SIZE, NORMALPRIO + 1,
lwip_thread, NULL);
chThdCreateStatic(wa_http_server, sizeof(wa_http_server), NORMALPRIO + 1,
http_server, NULL);
chThdSetPriority(LOWPRIO);
while (TRUE) {
puts("main\n");
chThdSleepMilliseconds(500);
}
When starting the application I can see ARP who-has requests on the loopback interface (using tcpdump).
Using curl 192.168.1.20, I get "no route to host".
Do I have to configure lwip to be able to use localhost?