ESP8266 Webserver Project

Moderator: Sprite_tm

User avatar
By komita
#9763 Afternon everyone, first of all thank you to the author of the webserver code for releasing it for the rest of us and also thank you for everyone else that has been posting updates to it and the dev environment setup.

I like some other people can't compile the webserver and one of the last changes I made that got me almost there was changing the c_types.h "#if 0" to "#if 1" as suggested by kadimski which got me past the error for an undefined uint32_t type.

Now I have a different error when compiling and I am having a tough time finding references for it on the web, does this look familiar to anyone? (I am not very comfortable on linux so everything is taking me 10x longer to do)
Code: Select allkomita@komita-linux:~/Electronics/esphttpd$ make
LD build/httpd.out
/home/komita/Electronics/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/bin/ld: group ended before it began (--help for usage)
collect2: error: ld returned 1 exit status
make: *** [build/httpd.out] Error 1
komita@komita-linux:~/Electronics/esphttpd$


EDIT: I am sorry, I guess all of this is overwhelming with the environment setup so I didn't even rellize that the esp_iot_sdk_v0.9.5 folder was not there for me (the zip file had never been unzipped). I though the automatic script would take care of everything but obviously I am not doing everything right, so forgive me for my ignorance. After uncompressing that zip file and running MAKE in it I am no longer getting the above errrs, though stuck elsewhere.

At this point I am trying to deal with:
Code: Select all/home/komita/Electronics/esp-open-sdk/xtensa-lx106-elf/lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/bin/ld: group ended before it began (--help for usage)
collect2: error: ld returned 1 exit status
make: *** [build/httpd.out] Error 1

I will edit this post as I make new progress. Its definitely a bit discouraging, I have spend 2 days trying to set up the dev environment and I am yet to code 1 line.

EDIT2: Wait ... wait ... wait a minute ... I could believe I somehow missed installing esp_iot_sdk_v0.9.5 as a folder under esp-open-sdk but I know for a fact that there was a "sdk" folder under esp-open-sdk, and now that is gone too!!! I must be going crazy.

EDIT3: At least part of my problems may have been caused by me installing the esp-open-sdk with the STANDALONE=n option. I am currently re-installing it with the "y" option. Wish me luck, I hope this works. ... Nope .. still getting - group ended before it began error 1. Damn.

EDIT4: Well I think I progerssed a bit. I did so many different things that I don't really know what helped, but I believe the main points were re-installing the open sdk with STANDLONE=y and inputing the right paths in the makefile of the esphttpd project.

Next step (will this ever end?)
Code: Select allkomita@komita-linux:~/Electronics/esphttpd$ make
FW firmware/0x00000.bin
make: execvp: /home/komita/Electronics/esp-open-sdk/esptool: Permission denied
make: *** [firmware/0x00000.bin] Error 127


Oh and I forgot to mention the edphttpd/firmware folder is empty. No 0x00000.bin as suggested on the output above.
:(
Last edited by komita on Sun Feb 15, 2015 10:27 am, edited 9 times in total.
User avatar
By andrew melvin
#9784
bwhouse wrote:First up thanks Sprite_tm for the awesome work on this.

I seem to be having an annoying problem and no luck trying to compile the esp-httpd source. I am using the esp-open-sdk on OS X and havent had any trouble compiling my own code or the MQTT library. But when ever I try to compile esp-httpd i get the following errors.

Code: Select allCC user/auth.c
In file included from /esptools/esp-open-sdk/sdk/include/os_type.h:10:0,
                 from /esptools/esp-open-sdk/sdk/include/user_interface.h:9,
                 from user/auth.c:17:
/esptools/esp-open-sdk/sdk/include/ets_sys.h:14:1: error: unknown type name 'uint32_t'
 typedef uint32_t ETSSignal;
 ^
/esptools/esp-open-sdk/sdk/include/ets_sys.h:15:1: error: unknown type name 'uint32_t'
 typedef uint32_t ETSParam;
 ^
/esptools/esp-open-sdk/sdk/include/ets_sys.h:27:1: error: unknown type name 'uint32_t'
 typedef uint32_t ETSHandle;
 ^
/esptools/esp-open-sdk/sdk/include/ets_sys.h:32:5: error: unknown type name 'uint32_t'
     uint32_t              timer_expire;
     ^
/esptools/esp-open-sdk/sdk/include/ets_sys.h:33:5: error: unknown type name 'uint32_t'
     uint32_t              timer_period;
     ^


I assume I have some form of problem with the Makefile, but for the life of me I cant work it out. All the paths look correct and the Libs all look fine.

Any one got any ideas?


Hi, Im getting this exact problem.

1) using the latest git, only pulled a few min ago
2) editits #if=0 to #if=1 in the c_types.h file. no difference

is there anything else i need to do.

I can complete the nodemcu, and the the blink example just fine. really wan esphttpd to compile.
Is there a way to not flash the files directly. I need to use a different computer so flashing straight away is not good.

Cheers

Andrew
User avatar
By rith87
#9883 Sprite_tm, thanks a ton for esp-httpd! I managed to set it up and I can access the pages hosted on the esp8266 on my Windows 7 laptop and my IPhone 6. Unfortunately, I can't seem to access 192.168.4.1 on my Ubuntu 14.04 LTS.

Here's what I get when I do ifconfig:

Code: Select alllo        Link encap:Local Loopback 
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:3038 errors:0 dropped:0 overruns:0 frame:0
          TX packets:3038 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:558221 (558.2 KB)  TX bytes:558221 (558.2 KB)

wlan0     Link encap:Ethernet  HWaddr [laptop MAC address] 
          inet6 addr: fe80::9ef3:87ff:feb6:ad9e/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:29386 errors:0 dropped:0 overruns:0 frame:1071417
          TX packets:22661 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:11908748 (11.9 MB)  TX bytes:6502030 (6.5 MB)
          Interrupt:18


Any idea why there is an IPv6 address but not an IPv4 one? Has anyone else got it to work on an Ubuntu 14.04?