ESP8266 wifi module purchased from Ebay

Hi everyone nice to meet you all
This will be my very first post here so please be nice.
Hopefully i am in the correct place or forum to post such a question.
Just wanting to know if someone could please lead me in the right direction so i may ask some basic general question with my very first purchase of the module from ebay ESP8266 5V 10A DC 7-30V Input WIFI Wireless Network Smart Relay Module Board.

What's your question? :slight_smile:
Could you post a link to the specific board?

Maybe this helps: a Beginner's guide to the ESP8266.

Pieter

Oh hi thanks for the reply
the link you supplied yes well thats a good place to start, excellent i will read a bit more.

1: Im not sure if you read my question but i asked if i was in the correct forum or post to ask this question here, obviously i think i am.

With referance to the board i purchasd from ebay i have a link for you to see.
http://www.ebay.com.au/itm/1x-ESP8266-5V-10A-DC-7-30V-Input-WIFI-Wireless-Network-Smart-Relay-Module-Board-/311822456668?hash=item489a11175c:g:Ae0AAOSw2gxYxm0D

2: I was wondering is there a link to pre load the software in my IDE file so that i can start inputting my setting of my router or will i still need some sort of third part software/ hardware to get this to interact with my pc like some sort of serial or usb cable>

( So eager and excited to start my project, until i blow it up!.....lol )

Regards

Tony

  1. No worries, this is probably the right forum for your question.
  2. There's two possible approaches: A) using the ESP8266 as a standalone microcontroller, meaning that all code runs on the processor of the ESP. This is what's explained in the article I linked to earlier. B) Using the ESP as a WiFi to Serial bridge, to connect to an Arduino board. You can then send AT-commands to the ESP to perform some network tasks, like connecting to a network, downloading a webpage, etc...
    In my opinion, approach B is a waste of resources, and it's much harder to program. An ESP8266 is many times faster, and has much more memory than most Arduino boards, so why not use the ESP as your main microcontroller?
    The only downside is that you need access to the Reset and GPIO0 pins to use approache A, which means you have to disconnect the ESP from the relay module.
    You'll also need a USB-to-Serial converter, preferably one that let's you switch between 5V and 3.3V (because I'm not sure if the relay board has level shifters on the Serial data lines). You can use the 3.3V regulator on the relay board to power the ESP.
    My guide contains the necessary information on how to connect the hardware.

If you want to go with approach B you'll need an Arduino, preferably one with more than one hardware UART (serial port) like the Mega, or with one USB "Serial" port and a hardware UART, like the Leonardo and most Teensies. The advantage of a Teensy over a Leonardo is that it operates at 3.3V, so no level shifting required, and it has much more RAM and processing power.

Pieter

Ok great thanks for that explanation.
I will choose option A and go with the standalone method.
I will order this FTDI FT232RL serial converter adapter hopefully this should do what i need.

http://www.ebay.com.au/itm/FTDI-FT232RL-USB-to-TTL-Serial-Converter-Adapter-5V-and-3-3V-For-Arduino-GO-/371474451179?hash=item567d9a4aeb:g:tdkAAOSw5VFWMM31

Regards

Tony

PieterP:
Maybe this helps: a Beginner's guide to the ESP8266.

It certainly does, and I have just ordered a NodeMCU. Thanks for your comprehensive work.

That link also gave me a push in the right direction.
And the ESP examples in the IDE.

I curently use an UNO (clone) to power (yes, I know) and program a bare ESP-12.
I have first loaded an empty sketch in the UNO, so the MCU isn't using the TX/RX lines.

The 3.3volt power supply of the UNO (rated for 150mA) keeps up 24/7 with the ~75-80mA idle current.
I have added a 220uF cap to the 3.3volt rail to cope with transmit current spikes.

RX (pin0) of the Uno is connected to RX of the ESP with a 1k:2k divider.
TX (pin1) of the UNO is directly connected to TX of the ESP.
Other connections and reset/program buttons as in the link.
Leo..

Hi again
I’m back with my project, this time with my USB to serial converter that I have ordered on line through ebay.

Although I have wired up both units and paired them correctly and that all seems to be working fine and without any issues and read the documentation to the link provided here and other references given to me and on the internet, it appears I might have an issues that I just can’t seem to work out.

I am not really sure of what to make of this but it appears although I am able to load a program ( upload the script ) through the IDE interface and all seems to be working as should resetting and programming my ESP8266 but when it comes to the call AT commands my device does not seem to want to communicate.

I have checked my ports and all seems to be working fine as would be expected because the program seems to load fine.
What I have is COM port 3 set connected and a baud rate showing 19200 but no matter what other baud rates

I try I still have this issue that it does not seem to want to execute the AT command.

Although the programs loads correctly and I am able to view this through my LAN ip address set at 192.168.1.128 through my web browser wirelessly or wired as a web server as it was quiet simple to set up the parameters of my SSID and password without any issues, this just doesn’t seem to want to respond when I try and write the AT command line.

Nothing happens

I have even also tried using another program Putty and set this up manually in a bid to get this to communicate but still there is little joy and it just sits there and hang.

So i have been researching and looking this up this on the internet but I have not been able to find anything.

Just wondering as I am still fairly new to these micro-controller if one of you tech experts with more experienced than myself could please explain what I am doing wrong or what I can do to get this to work, unless there is something wrong with my project altogether.

From my perspective, it looks to be ok, but is it ok?

Any assistance would be greatly appreciated.

Sorry if this happens to be so long.

Thanks

Programming it with the Arduino IDE overwrites the AT firmware. So it's normal that it doesn't respond to AT commands.

If you want to use AT to communicate (which I don't recommend), you have to flash the AT fw again.
IMHO, there's no good reason to use AT commands, just handle all WiFi and TCP/IP stuff on the ESP itself, parse data it receives from the web and send only the relevant data over serial to the Arduino. Or if you have to send data, send the relevant data to the ESP, and let the ESP construct the HTTP request.

Pieter

Ok thank you so much for you explanation.

This would explain it.

Assuming now its ok and my mind is at ease.

And i dont have any plans to flash out this unit, not with my experience not at this stage.

Still i was wondering and if you dont mind me asking you this Mr Pieter could you please recommend to me or have you seen the version of the micro controller unit i have ( as i havent been able to get any documentation of the unit i have tried to ask the seller but have been unsuccessful in any reply ) and the best place to obtain some code for an on /off switch as i would like to toggle my on board relays wirelessly.

Regards

Tony

The specific version of your ESP8266 is the ESP-01 by AI Thinker. I don't know what the pinout of the relay board is, but the relay is probably connected to GPIO0 or GPIO2.
You can find an example in my beginner's guide. Take a look at Turning on and off an LED over Wi-Fi.

Pieter

ok thank you for the assistance i will look through this beginners guide

I just got to now, brush up on my PHP coding skills.

Its been a while. lol

Tonymura:
I just got to now, brush up on my PHP coding skills.

Keep in mind that the server side scripting is done in Arduino C++, not PHP.

Pieter

oops yes i gather that.

hmm this will be a challenge.

However what i have done so far is to add a delay code to my script for the led light on the board to reduce the blink time.
Works great.

Also just wanting to know with regards to this forum as to why i cant add images here.

Or do i require more karma points

I suppose there are some advantage as to not allow this feature due to incorrect images being displayed or circuitry not working correctly and could be miss leading to some enthusiast or hobbyist
Also would help reduce server space i guess but then again......it would be great to have to show and tell.

ok back

It seems i can add an image here.

Latest I have managed to use some code form the ide program but still no success in toggling the relays.

Hopefully this image will give some in site if someone here in this forum has used this sort of device before.
ESP8266 5V 10A DC 7-30V Network Relay WIFI Module NEW U8