# WifInfo
## Overview
A few months ago, I came across a project called Wifinfo. It's a small board, based on an ESP8266, which retrieves information from the French power meters and displays them, or sends them across the network. The PCB was cheap, and I though I could use one, so I built some boards ! Turns out, I can't use them: the telemetry option is disabled in my power meter…
## Hardware
### PCB
I uploaded the files on OSHPark and also shared them, so anyone can easily order them: [OSH Park](https://oshpark.com/shared_projects/Rjzd7tY7)
### BoM
Part(s) ref on design | Qty | Name | Doc | Supplier | SupplierRef |
---|---|---|---|---|---|
Resistors | |||||
R1, R2, R4, R5, R6, R7, R8 | 7 | 10K 0603 SMD Resistor | N/A | Mouser | 667-ERJ-3GEYJ103V |
R3, R11, R12 | 3 | 4.7K 0603 SMD Resistor | N/A | Mouser | 667-ERJ-3GEYJ472V |
R9 | 1 | 100K 0603 SMD Resistor | N/A | Mouser | 667-ERJ-3EKF1003V |
R10 | 1 | 470R 0603 SMD Resistor | N/A | Mouser | 71-CRCW0603J-470-E3 |
Capacitors | |||||
C3, C4, C5 | 3 | 100nF 0603 SMD Capacitor | N/A | Mouser | 80-C0603C104K4R |
C1, C2 | 2 | 10uF 0805 SMD Capacitor | N/A | Mouser | 81-GRM21BC81C106KE5L |
LED | |||||
LED | 1 | Red 0603 SMD LED 20mA | N/A | eBay | 20x 0603 R,G,B,Y,O,W |
Power & Signal | |||||
D1, D2, D3, D4, D5 | 5 | Diodes schottky 1A 20V | N/A | Mouser | 511-STPS140Z |
U1 | 1 | 3.3V 800mA LDO Regulator | Link | Mouser | 621-AZ1117CR-3.3TRG1 |
OK1 | 1 | Phototransistor | Link | Mouser | 859-LTV-814S |
Q1 | 1 | Mosfet Channel N | Link | Mouser | 512-BSS138 |
Headers & Sockets & Switchs | |||||
Flash, Reset | 2 | SMD Tactile switch | N/A | Mouser | 611-KMR211NGLFS |
PWR,TINFO | 2 | 3.5mm Screw header 1×2 | N/A | eBay | |
uC | |||||
ESP | 1 | ESP07 or ESP12 module | Link | Aliexpress |
### Tools
You need:
- A decent (250mA) 5v PSU, like a phone charger, or a battery. - An USB-Serial adapter, which can easily be sourced from eBay.
## Software
### Tools
The firmware is an Arduino sketch, so you will need:
- The Arduino IDE. I used v1.6.7, from [the Arduino website](https://www.arduino.cc/en/Main/Software) - The ESP8266 _extension_ for the Arduino IDE, from [Github](https://github.com/esp8266/Arduino) - The “ESP8266 Sketch data upload” tool for the Arduino IDE, from [Github](https://github.com/esp8266/arduino-esp8266fs-plugin/releases/) - Some libraries such as:
I took a “random” one, and it compiles fine, but the LED doesn't work properly…
### Firmware
Grab the firmware from the LibTeleinfo Github project, in the `examples/Wifinfo`folder.
There's currently a bug in the index.html file: the [issue](https://github.com/hallard/LibTeleinfo/issues/3) with a _fix_, on Github.
### Upload
#### Wiring and process
You need to put a jumper on the board between the TX and TX1 pins, on the three pin header on the right.
Connect your serial Adapter to the board (on the six pins header on the right): RX on TX, TX on RX, GND on GND. I used an external power supply but you can also probably use the 5v pin to power the board.
To put the ESP8266 in _Flash mode_, press the Flash switch, hold it, press the Reset switch, relase Reset, release Flash. Should be ok.
Select the good board type and options (the default ones are usually okay).
#### Upload the data
* Load the Wifinfo sketch * Put the ESP266 in _Flash mode_ * Tools > ESP8266 Sketch Data upload
#### Upload the firmware
* Load the Wifinfo sketch * Put the ESP266 in _Flash mode_ * Upload sketch
## Links
* [Github project](https://github.com/hallard/WifInfo) Schematic and PCB files * [LibTeleinfo](https://github.com/hallard/LibTeleinfo) Firmware * [Wifinfo-related message board](https://community.hallard.me/category/16/wifinfo)