Display measurements on website

Hello, I have a humidity sensor connected to an Arduino MEGA 2560. I want to have access to the measurements through Chrome, and best I want to make a graphic curve with the measurements. Because I haven't done this before, first of all can this happen? I don't know where to start....

360modena_cs:
I want to make a graphic curve with the measurements.

Your objective is not very clear but, without consideration of what Chrome is, or what a website might be, some possibilities are:

Internet of Things, something like Blynk or Thingspeak, whereby you can check on current events from anywhere in the world

PLX_DAQ v2 a macro for Excel, which effectively turns it into a smart terminal, whereby you can record data from Arduino direct, timestamp it, and see live graphs

Bluetooth Graphics Terminal, which does much the same thing on your phone, but no local timestamping.

Another graphic terminal is Live Graph from University of Melbourne. It was very good, but I think only useful to those who can't beg, borrow, buy, or steal Excel.

There is some x,y plotter facility included in the Arduino IDE. Last time I looked it was junk, and probably still is, but you might get some value out of it.

or, of course, simply record the data, either direct on a plain-vailla terminal such as RealTerm, or on local SD card, for subsequent graphic display by whatever means.

An ESP8266 based board like the WeMos D1 mini can read a sensor, store months of data in it's 4Mb flash memory, add a timestamp from the internet to it, run a webserver with a graph, and much more.
No need for the Mega.
Example code for a DS18B20 temp logger in this guide.
Leo..

Indeed a NodeMCU or WeMOS is much more suited for a project like this than a Mega, mostly thanks to its built-in WiFi connectivity and web server.

Thanks, Just to understand. This web server runs on the Arduino I suppose?

It runs on the ESP8266 processor - that's not an Arduino, most of which are based on ATmega processors.

So I have to upload HTML code on ESP? And hit the address (?), IP (?) of the Web Server in order to get the results to my browser?

Start here. Ch.9 and ch.10 handle the web server part. It's very much about using the ESP-12E module, a development board makes it a lot easier but the rest of the info is just as valid for both options.

So I have to upload HTML code on ESP? And hit the address (?), IP (?) of the Web Server in order to get the results to my browser?

Essentially, yes.

Here's another good link on setting up a local wifi webserver.

http://www.martyncurrey.com/esp8266-and-the-arduino-ide/

If you want global access, then another alternative to Blynk and Thingspeak is Adafruit IO

wvmarle:
It runs on the ESP8266 processor - that's not an Arduino, most of which are based on ATmega processors.

IMHO, the term "Arduino" is defined as whatever chip or platform you are running that uses the Arduino IDE.

Arduino seems to be more of a generic idea than any exact parts. the 328 is not an arduino, but once loaded with the Arduino software, it becomes an Arduino.
I submit that the Teensy, the ESP8266 and things like the Maple/Bobdino (with 1248p) are every bit as much an arduino that an MRK1000 or YUN or Lillypad is.

dave-in-nj:
IMHO, the term "Arduino" is defined as whatever chip or platform you are running that uses the Arduino IDE.

For me Arduino is Uno or equivalent (or Mega even), beyond that the hardware differences become quiet noticeable. Particularly as you're so close to the hardware, and things like timers and even interrupts work quite differently between AVR and ESP processors.

wvmarle:
For me Arduino is Uno or equivalent (or Mega even), beyond that the hardware differences become quiet noticeable. Particularly as you're so close to the hardware, and things like timers and even interrupts work quite differently between AVR and ESP processors.

Reading the functionality of the software interface. the arduino IDE 'directly' addresses the pins, one does not need to use AT commands to talk to the ESP8266 so, I lump anything that is in the IDE software of which you can select as a target board. as an Arduino
Maybe it would be more correct to say that it is recognized as being on the Arduino platform.
...being able to share libraries for many things. but it gets into a grey area really quick !
Moving your sketch from an UNO to a Leonardo to a NANO to a ProMini... all require tiny changes as the chip on the boards include or exclude pins.
One has to make some simple changes to move to a MEGA as some of the pins are moved.
for most of my stuff, moving from the UNO to a ESP8266 requires the addition of a library and re-naming pins to D1 and D2...
The concept I am pushing is that a beginner can do some simple things to swap boards. It is that reason I consider chips/boards listed in the IDE and that can be programmed with the Arduino IDE to be Arduinos, or on the Arduino platform.

As regards this thread, the OP can get an ESP8266, and if he is not using analog in's, may be able to move the sketch over to the ESP8266 with some minor alterations. if he has too many pins, or uses more than 1 Analog in, then there is more work, or he uses the ESP8266 as a WiFi device and calls it from his UNO.
but, since the ESP8266 is on the Arduino platform, he can program that with the Arduino IDE. so the ESP8266 is a very easy way to add WiFi to any Arduino project.

dave-in-nj:
moving from the UNO to a ESP8266 requires the addition of a library and re-naming pins to D1 and D2...

Those D1, D2 are NodeMCU (and/or WeMOS) specific. The numbering has no obvious relationship to the GPIO numbering of the chip itself... Very irritating. I normally use the GPIO numbers, as I'm mostly using ESP-12E modules, but sometimes do experiments using NodeMCU and I need a look-up table to know which D numbers correspond to GPIO0, 2 and 15 - with the wrong connections on those pins your device won't even boot up!

There's more difference than just those pin numbers and the workings of the analog port, but in general indeed Arduino libraries work out of the box on ESP8266, and I suppose ESP32 as well. They're indeed perfect for any WiFi enabled projects, or IoT type projects.