PCBmedo/ESP8266

From: ANT_THOMAS14 Mar 2016 22:34
To: Chris (CHRISSS) 47 of 111
Once I figured out how to program it, wiring etc, it is now fairly easy.

I'll build a programming board at some point so I can just plug in the USB serial adapter and an esp8266 module.



Once it's programmed you can just power it up without all the buttons and adapters.
From: ANT_THOMAS16 Mar 2016 00:03
To: ALL48 of 111
Made a quick test setup to see how well my new sketch works.



Pretty simple setup which I might solder to a protoboard

esp8266
ams1117-3.3 regulator module
ds18b20 temp sensor module

Rather than running a webserver on the esp8266 and another system requesting the data, the esp8266 now uses a http get command to send the data itself. This will mean once I tidy up the code I can have it deep sleeping when it's not needed, rather than being awake and ready to send.
From: ANT_THOMAS17 Mar 2016 23:16
To: ALL49 of 111
Made a programming board



And made a temperature sensor board to play with

 
From: ANT_THOMAS20 Mar 2016 14:24
To: Chris (CHRISSS) 50 of 111
Turns out the ESP8266 can run off 4.2V so you can connect a lithium battery direct without a regulator to waste energy. 3x rechargeable AAs work well direct. Next step is to sort the deep sleep code.

I've bought some lithium charging boards to use to protect against over discharge. Another few weeks to wait!
EDITED: 20 Mar 2016 14:26 by ANT_THOMAS
From: Chris (CHRISSS)21 Mar 2016 10:08
To: ANT_THOMAS 51 of 111
Interesting. I didn't realise they could be run on their own. I assumed they needed an Arduino to connect up to. I wonder how well they run in sleep mode compared to an Atmega with RF24 radio connected.
From: ANT_THOMAS21 Mar 2016 10:29
To: Chris (CHRISSS) 52 of 111
The ESP-01 model (which I have) has 2 GPIO pins that are useful for stuff. The other models (eg ESP-12F) which have more pins available are a bit larger and look to be more fiddly to use, but I still might buy a couple since they're less than £1.50 each, you can get a mounting board for about 10p anyway.

ESP-01


ESP-12F


To use deep sleep you need access to GPIO 16, which isn't normally available on the ESP-01 (only GPIO 0 and 2). You need to do this...
(and my soldering iron tip is too fat :C )

From: Chris Cooper (DEATHTERRAPIN)21 Mar 2016 18:28
To: ANT_THOMAS 53 of 111
I just got an esp-12f, not sure what I'm going to do with it, but for £1.57 including the adapter board it was hard to resist.
Soldering it onto the board was a bit of a pain though, and its too wide to use on a single breadboard.
Attachments:
From: ANT_THOMAS21 Mar 2016 19:20
To: Chris Cooper (DEATHTERRAPIN) 54 of 111
Nice, you'll definitely be able to deep sleep with that then.

In deep sleep I think it's in the microamp range for power consumption.

I've read various reports of it now always waking from deep sleep which doesn't sound promising.
From: Chris Cooper (DEATHTERRAPIN)21 Mar 2016 20:52
To: ANT_THOMAS 55 of 111
Yeah, I think I saw something about that as well. Doesn't really bother me at the moment, need to think of something to use it for first!
From: ANT_THOMAS21 Mar 2016 20:59
To: Chris Cooper (DEATHTERRAPIN) 56 of 111
I actually thought you were the other Chris earlier :$

Sensors, switches, stuff to remotely control
From: Chris Cooper (DEATHTERRAPIN)21 Mar 2016 22:17
To: ANT_THOMAS 57 of 111
Haha!
My next project is actually an 8x8x8 LED cube, just ordered the esp on a whim alongside the bits for that. Still waiting for my LEDs to turn up though.
From: Chris (CHRISSS)21 Mar 2016 23:40
To: ANT_THOMAS 58 of 111
Haha. I read your post and thought that was to me and got very confused :)

I'll stick to my RF24 radios for now, at least for my temp sensors because I've got them working nicely. I'll definitely consider them for other things though.

What you got planned for them?
From: ANT_THOMAS22 Mar 2016 00:10
To: Chris (CHRISSS) 59 of 111
My RF24 temp sensors are working well, but for some reason I don't like them. Range is ok but not as good as I expected, the kitchen one occasionally drops out (and that's got a proper antenna rather than an onboard one), even the bedroom one isn't always 100% and that's in the room above the RPi. It's easier to extend a WiFi network than an RF24 network - I've already got an AP at either sides of the house.
From: Chris (CHRISSS)22 Mar 2016 00:44
To: ANT_THOMAS 60 of 111
That's a good point about the range. I didn't think about that. I don't have any problems where mine are at the mo but last year when I put one outside for a bit it was tricky getting it to connect to my Pi.
From: ANT_THOMAS22 Mar 2016 00:52
To: Chris (CHRISSS) 61 of 111
If I ignore the deep sleep and running them off batteries, I now have a nice working setup for a plugged in sensor. I think I'll tweak/redesign the PCB now I know what components are sensible and needed and order some.

I'll probably change a few bits to enable multiple power options, maybe add a few jumper points for various options like disconnecting the regulator.

I'm also wondering how easy it would be to add some dip switches to give each module its own unique id rather than programming each one specifically.
From: ANT_THOMAS24 Mar 2016 10:45
To: ALL62 of 111
It was only the other week that I got my AliExpress "Awaiting Delivery" list down to 0, it is now 20 (fail)

I need to stop buying cheap electronics.
From: koswix25 Mar 2016 00:16
To: ANT_THOMAS 63 of 111
I placed my first aliexpress order yesterday - a lvds cable for my laptop (the one ordered previously rather unsurprisingly didn't turn up and has been refunded via paypal).

I keep adding things to my basket but then chickening out on ordering stuff. So much stuff I want.
From: ANT_THOMAS26 Mar 2016 00:21
To: ALL64 of 111
Deep sleep now working. Bought a very sharp tip for my soldering iron and managed to get the wire attached.
From: ANT_THOMAS28 Mar 2016 21:58
To: ALL65 of 111
I've been doing some more testing on batteries to see how long they last in various setups. All submit a temperature every minute(ish).

3xAA NiMH (no regulator)
No sleep modes
27 hours

4xAA NiMH with AMS1117-3v3 regulator
Small solar panel to attempt to charge the batteries
No sleep modes
58 hours

3xAA NiMH (no regulator)
Deep sleep for around 50-55 seconds (can't remember exactly)
Still alive and approaching 72 hours

Next will be deep sleep + solar panel, and possibly remove the power LED.
From: Chris (CHRISSS)29 Mar 2016 11:12
To: ANT_THOMAS 66 of 111
Definitely cut the power LED. That alone will probably run the batteries flat fairly quickly. How reliable is it waking from sleep?

Probably not an issue for you if you're going to switch to WiFi sensors but with the RF24s you can route the signal through another close radio to get better range. Not if the middle one is sleeping though.