Community
cancel
Showing results for 
Search instead for 
Did you mean: 
FTinetti
Honored Contributor I
1,705 Views

Webserver Ethernet(Galileo) Ex., eglibc img., etc.

WebServer example in the Arduino IDE, Ethernet(Galileo) :

Examples --> Ethernet(Galileo) --> WebServer

WebServer.ino

1) It works as expected (i.e changing only the MAC address) if the Intel Galileo is turned on without any SD-Linux image

2) It does not work if the Intel Galileo is booted with the eglibc image (iot-devkit-prof-dev-image-galileo-20160606.zip)

Also, I attach two "simpler" versions of the webserver sketch without MAC usage and without SPI.h usage, taking advantage of function "system" available in Intel Galileo:

1) WebSrvrNoSD.ino is expected to be used in an Intel Galileo booted without any SD-Linux image

2) WebSrvrEglibc.ino is expected to be used in an Intel Galileo booted with the eglibc image (iot-devkit-prof-dev-image-galileo-20160606.zip)

Both sketches "serve" HTTP in port 80, and differences are in the setup() function, as expected...

Fernando.

0 Kudos
5 Replies
FTinetti
Honored Contributor I
47 Views

Thanks to Sergio's contribution in another thread

it is not necessary to have 2 versions of the web server initialization

Fernando.

wcaro
New Contributor I
47 Views

thanks for the info,

I have a question, you have an example in which a webserver is made by calling index.html that is in the Galilean sd ?.

I want to take an analog signal and is displayed every 1 second on an analog clock. but that index.html is in the sd gen2 Galilean. to graph it and make statistics.

I appreciate if you can help

FTinetti
Honored Contributor I
47 Views

It's "relatively" simple, since you can have the .html in your sd and use Linux filesystem operations (it's easier than in Arduino, I think). I'll try to post a simple example if you think you need one. Are you developing in Arduino IDE, right?

Fernando.

wcaro
New Contributor I
47 Views

Yes, and please post one example thanks

FTinetti
Honored Contributor I
47 Views

Your SD Card should be seen like this, using the current eglibc yocto image

There is an example www directory in the attached .zip

The webserver in the attached .zip is basically one of the previous ones, modified so that reads and sends the contents of the index.html file in the SD filesystem instead of HTML contained in the sketch itself.

HTH,

Fernando.

Reply