WiFi for existing Arduino - Page 1
Forum section: electronics / beginners

author: ziplock9000
author_rank: Regular Contributor
timestamp: July 02, 2018, 09:19:33 pm
content: I've been looking for a cheap and easy to use way to add WiFi capability to my Arduino UNO and then potentially a stand alone pro mini solution. After lots of Googling I keep finding the fabled ESP8266 solution in all of it's forms. The only "problem" is that every solution I find has a module that also includes its own MCU which is programmed separately from the host Arduino. Short of using the WiFi chip directly, are there no WiFi modules that plug into an existing Arduino and allow you to program that instead.. with all of the functionality you'd expect, ease of use etc?

author: rstofer
author_rank: Super Contributor
timestamp: July 02, 2018, 10:03:07 pm
content: https://www.adafruit.com/product/3653This device apparently has some firmware but the majority of the code is in a provided library. But the library is huge; it can not be used if the SD card library is in use. Let's face it, the Arduino UNO is a tiny little CPU with an insignificant amount of memory.Nevertheless, this gadget will work in some cases. Or you can use a better board.

author: malagas_on_fire
author_rank: Frequent Contributor
timestamp: July 02, 2018, 10:07:17 pm
content: There are always possibilities but they not present the cheapest :Arduino SPI WiFi Modulehttps://www.emartee.com/product/41983/Arduino-WiFi-Wireless-ModuleKeep in mind that the processing headup in this scenario adds up to the Arduino and the ESP solution has it's 32bit microcontroller which can manage better the TCP/ IP packetshttp://www.mpja.com/TTL-WiFi-Serial-Module-with-Passthrough-for-Arduino/productinfo/32692+MP/

author: ziplock9000
author_rank: Regular Contributor
timestamp: July 03, 2018, 09:15:14 am
content: Thanks. So you recommend I should persevere with ESP8266 with onboard MCUs to handle the I/O and TCP/IP stack.. then have the host just perform the business logic? If this is the case, do you (or anyone else) know tutorials where a host arduino talks to the ESP8266 MCU in this way (again, I can't find any)Thanks.

author: cyclin_al
author_rank: Frequent Contributor
timestamp: July 03, 2018, 01:39:57 pm
content: If you are not fixed to the ESP8266, there are some other options.For example, with a STM32F205 with WiFi and a Cloud service, there is the Particle Photon.See particle.io.It uses 3.3V logic, is mostly Arduino compatible (most Arduino libraries can be used directly without having to port them) and comes with a Cloud service to get up and running quickly.I am not associated with Particle, just a happy user.

author: rstofer
author_rank: Super Contributor
timestamp: July 03, 2018, 02:46:20 pm
content: Quote from: ziplock9000 on July 03, 2018, 09:15:14 amSure, you leave the TCP/IP stack and protocol handling to the ESP8266Google is your friend: search for 'esp8266 arduino tutorial' Projects are all over the place. 1,920,000 hits...

author: malagas_on_fire
author_rank: Frequent Contributor
timestamp: July 03, 2018, 11:28:09 pm
content: Hi thereI didn't mean that you're not restricted to the ESP chipset, but in many applications it is seen in a 32 / 64 bit cpu implementation and the ESP has massiveHere is a cheap module from Microchip :http://www.microchip.com/developmenttools/ProductDetails/atwilc1000-sdIt uses SDIO and SPI , so it is suitable for Linux Embedded CPU or 8 bit microcontroller. its works great

author: tpowell1830
author_rank: Frequent Contributor
timestamp: July 03, 2018, 11:49:17 pm
content: Hmmm, raspberry PI?

author: rstofer
author_rank: Super Contributor
timestamp: July 04, 2018, 12:02:06 am
content: Quote from: tpowell1830 on July 03, 2018, 11:49:17 pmAlways a better option for the networking aspects but not for any real-time considerations. We don't have any information on the application.

author: ziplock9000
author_rank: Regular Contributor
timestamp: July 04, 2018, 09:42:21 am
content: Quote from: rstofer on July 03, 2018, 02:46:20 pmI already mentioned in my OP that I tried Google and got no clear answers that addressed my specific query. No need for sarcasm.

author: NivagSwerdna
author_rank: Super Contributor
timestamp: July 04, 2018, 10:21:54 am
content: Quote from: ziplock9000 on July 02, 2018, 09:19:33 pmI have a number of Arduino based clocks (of strange designs) around my house and wanted to keep them synchronised. My partially complete solution is to use a ESP8266 with a minimal program that allows me to connect to the arduinos via their UARTS to configure them. i,e, the ESP8266 is merely a serial bridge. There already exists code out there to do the annoying bits like configuring the WiFi access point parameters etc. (It might have beenhttps://github.com/tzapu/WiFiManagerwill have to check my notes)I bought a few ESP-01 and a programmer adapter from EBAY on the slow boat from China. I think they were <£1 each and seem to work.

author: ziplock9000
author_rank: Regular Contributor
timestamp: July 04, 2018, 11:28:28 am
content: Brilliant thanks. This could be what I'm looking for.

author: NivagSwerdna
author_rank: Super Contributor
timestamp: July 04, 2018, 12:35:54 pm
content: Quote from: ziplock9000 on July 04, 2018, 11:28:28 amnp. Live long and prosper

author: Sudo_apt-get_install_yum
author_rank: Regular Contributor
timestamp: July 05, 2018, 08:19:18 am
content: The ESP8266, 85 and 32 are all µC that have a core for handling the wireless communication, you can program it just like a Arduino UNO since it’s a µC. what many people did in the beginning of the release of this chip (before the dev tools were released) they used it as a serial bridge and sending "AT" commands to it to connect to WIFI. If that’s what you want you could just buy an ESP and load the AT command firmware on it and then just send the commands from the UNO.Or you can skip the UNO and program everything directly on the ESP. it’s even compatible with the Arduino IDE and has a ton of community support!

author: ziplock9000
author_rank: Regular Contributor
timestamp: July 05, 2018, 12:27:35 pm
content: I may end up using different combinations of the above depending on the application. Thanks

author: C
author_rank: Super Contributor
timestamp: July 05, 2018, 12:53:28 pm
content: If a little more money or a little more power use in not a problem, start with the ESP32 over the ESP8266You gain a lot here on hardware pins and included hardware.Better sleep mode and ADC are some.In addition to this the Software side as the WIFI does not use the same CPU making your software easer to create.The ESP32 is just better all around making it easer for you.C

author: ziplock9000
author_rank: Regular Contributor
timestamp: July 05, 2018, 01:17:40 pm
content: Quote from: C on July 05, 2018, 12:53:28 pmThat looks like a fantastic piece of kit. Very powerful in many ways. Many come with several sensors already installed. I'm just worried that if I keep going up modularity tree I'll end up just buying a complete weather station kit or whatever the project is.

author: C
author_rank: Super Contributor
timestamp: July 05, 2018, 02:57:12 pm
content: You can get a simple ESP32 mounted on a Dip PC board at not bad price. This is just ESP32, small power supply from 5V, some buttons and often a usb to serial connection.Thing to think about is difference from,trying to stuff things in small space like a Arduino UNOOrUsing something less limited and not using it all.Makes it very easy for a future expansion.Something like a graphic LCD is then do I what one here and not a case of can hardware talk and can I fit in the software & will it be fast.You can buy a complete weather station kit or whateverBut this often leads to a bunch of separate things that will not work together.But how great is it? Will it tell you temperature in the sun and shade?Think of building a simple clock using an Arduino. You would need to add a real time clock with battery backup for when power failed. You end up with a bunch of pain in the ___ clocks that are not the same or have to be set often.That WIFI will let you get time from the others and master time from the internet. Simple and automaticIf you keep it simple, powerful CPU like this can do a lot with out requiring a lot of hardware.And once programed you can have access to over the air software updates.Think of building little things that can work together.When you want to link two or more micro-controllers with wire, Think you will find that CAN bus is often the best option. There is great reasons industry uses it and not UART, SPI or I2C.So a better foundation now is better for future as you now have option to change or notC

author: Naguissa
author_rank: Regular Contributor
timestamp: July 06, 2018, 01:13:10 pm
content: I created a ESP8266-oriented library for Arduino for this, using AT commands:https://github.com/Naguissa/WiFiLibAlso an SD card version with cooperative multitasking-like system (a state machine...) more focused on serving web pages and resources from SD (also AT commands):https://github.com/Naguissa/WiFiSDCoopLibBoth versions works with standard ESP8266 firmware. If you have trouble or you flashed with your own incompatible one you can use this one:https://github.com/Naguissa/WiFiSDCoopLib/tree/master/firmware%20-%20optional/ESP8266%20with%20512K%20FlashBut, for more reliable and complete solution it would be better to develop a program for the ESP8266 and use any kind of protocol to integrate it with your existing Arduino.