ODROID ESP12E Smart Power 2 with 15V 4A Adapter Instruction Manual
- June 5, 2024
- ODROID
Table of Contents
ESP12E Smart Power 2 with 15V 4A Adapter
Instruction Manual
Android Smart Power 2 – How to use
Connect the included 15V/4A adapter and plug the output cable into the
terminal block.
Ensure the DC plug cable is properly connected to the negative(black) and
positive (red).
Caution! if you plug it the other way, your board will be seriously
damaged.
Without WiFi (Standalone mode)
-
Output Power ON/OFF
You can turn the output power on/off using the tact switch on SmartPower2 -
Power monitoring with 16×2 LCD
We recommend connecting the LCD after disconnecting the main power source.
With WiFi (Connected mode)
The webpage supports IE 11+, Edge 13+, Firefox 47+, Chrome 49+, Safari 9.1+,
Opera 41+, IOS Safari 9.3+, Android Browser 4.4+, Chrome for Android 53+
-
WiFi Connection
Default SSID: smartpower2, Password: 12345678 -
Access Web UI
Default web server IP: 192.168.4.1 -
Home
• Seven Segments: voltage, ampere, watt, watt-hour.
• ON/OFF slide: Output power ON/OFF.
• Start/Stop slide: Watt-hour measurement Start/Stop.
• Voltage slider: Change output voltage.
• Save Default Voltage button: Set default voltage. -
Settings
• AutoRun checkbox – Output power ON/OFF automatically when you power on the SmartPower2.
• Save Button – Save Network Configuration (SSID, IP Address, Password).
• Reset Button – Initialize User Network Configuration (Factory reset)
With Telnet (Connected mode)
After connection with
WiFi, you
can get power data via telnet.
[Voltage],[Ampere],[Power],[Watt hour] $ telnet 192.168.4.1
5.255,0.451,2.374,0.000
5.256,0.451,2.374,0.000
Receiving Power Data via micro USB cable
This feature is available in F/W v1.4 or later.
You can receive power data(current, voltage, power, watt-hour) from your
SmartPower2 to your PC or ODROIDs through serial.
The serial output is available only when the output power is enabled.
Requirement Parameters
• 115200bps 8N1
• no-flow-control
- Connect your SmartPower2 to your PC via micro USB cable
- Run Serial serial console programs like putty or minicom
- Enable power-on
LED State
LED | State | Description |
---|---|---|
PWR(D1) | off | Input power off |
on | Input power on | |
blink | Output power on | |
WiFi Status | off | no WiFi connection |
on | WiFi connected | |
blink | Webpage loaded |
System Reset
After boot, press the ON/OFF switch for 5 seconds to reset all settings
including WiFi.
Hardware
Documentation
Schematic
Data Sheet
- MCU – ESP8266 Espressif low power 32-bit MCU
- USB to UART – CP2104 single-chip USB-to-UART bridge
- 3A 16V Stepdown – MP1495S High-Efficiency 3A, 16V, 500kHz Synchronous Step Down Converter
- Digital Potential Meter – MCP4652 7/8-Bit Single/Dual I2C Digital POT with Volatile Memory
- Current/Power Monitor – ina231 High- or Low-Side Measurement, Bidirectional CURRENT/POWER MONITOR with 1.8-V I2C Interface
- 10A 18V Stepdown – MP8762 High Efficiency, 10A, 18V Synchronous Step-down converter
Software
Framework – Arduino, Jquery
Build Platform – Platform, Arduino IDE
Upload the Firmware
Simple instruction for Firmware upload.
Linux
-
Install the requirements
$ Sudo apt install python-pip git
$ Sudo pip install esptool -
Get the binaries about firmware and web source
$ git clone https://github.com/hardkernel/smartpower2.git
$ cd smartpower2 -
Upload
You should check your esp8266 serial number like “/dev/ttyUSB0” or “/dev/ttyUSB1”
$ sudo esptool.py –chip esp8266 –port /dev/ttyUSB0 –baud 921600 write_flash 0x00000 prebuilt/firmware.bin 0x100000 prebuilt/spiffs.bin
Windows
The instructions were tested on Windows 10.
- Get the binaries about firmware and web source from this link https://github.com/hardkernel/smartpower2/releases then, you need to extract the zip file from your work folder.
- Download and extract the flash tool flash_download_tools_v3.6.6_0.zip
- Run the exe file into the folder
- Select ESP8266
- Start upload
You have to input binaries and other parameters as shown below picture. COM port is variable depending on your PC environment.
Build Firmware
This guide is working with x86 platforms only. The development tools are not
available for ARM platforms.
You can use Arduino IDE or PlatformIO to build the platform.
Arduino IDE
-
Install Arduino IDE for ESP8266
Download the Arduino IDE via this link
https://www.arduino.cc/en/Main/Software
Run Arduino IDE and open “File → Preferences” on the menu bar Add https://arduino.esp8266.com/stable/package_esp8266com_index.json into “Additional Boards Manager URLs” After adding the URL, you are able to search “esp8266” in “Tools → Board → Boards Manager”.
Install the esp8266 Android version 2.4.2!
Currently, Smartpower2 is not compatible with version esp8266 Android v2.5.0 or higher. Select “Tools → board” to “NodeMCU 1.0 (ESP-12E Module)” -
Get source code
Download the latest source code.
v1.6-arduino.zip
Unpack and open the “smartpower2.ino” in Arduino Configure your Sketchbook location to your project root folder. (In my case $HOME/Downloads/smartpower2-1.4) Restart Arduino IDE. Then, you can see “ESP8266 Sketch Data Upload” on the tools menu bar. -
Compile and upload
Run upload! Run “ESP8266 Sketch Data Upload” on the tools menu bar.
**PlatformIO
**
Linux
-
Install PlatformIO
sudo apt-get install python-pip
sudo pip install -U platformio
platformio –version
If you have any issues while installing it, refer to this guide.
http://docs.platformio.org/en/stable/installation.html -
Get source code
Sudo apt-get install git
git clone https://github.com/hardkernel/smartpower2.git -b v1.6-platformio -
Build & Upload Connect MicroUSB to Host PC.
You can see the list of USB drivers “CP210x UART Bridge” by lsusb in the terminal.
cd smartpower2
sudo platformio run
Sudo platformio run –target upload
sudo platformio run –target uploads
Windows
-
Install platformIO
http://docs.platformio.org/en/stable/installation.html -
Get source code
v1.6-platformio.zip -
Build & Upload
Run CMD and move to the smartpower2 folder and Connect MicroUSB to Host PC.
You can see the list of USB drivers “CP210x USB to UART Bridge(COMx)” on the Device Manager.
cd /path/to/dir/smartpower2
platformio run
platformio run –target upload
platformio run –target uploads
Troubleshooting
“undefined reference to sqrt” error
If you have any errors such as the following.
/home/kyle/.platformio/packages/toolchain-xtensa/bin/../lib/gcc/xtensa-
lx106-elf/4.8. 2/../../../../xtensa-lx106-elf/lib/libm.a(lib_a-
w_sqrt.o):(.literal+0x8): undefined r eference to __ieee754_sqrt’= /home/kyle/.platformio/packages/toolchain-xtensa/bin/../lib/gcc/xtensa- lx106-elf/4.8. 2/../../../../xtensa-lx106-elf/lib/libm.a(lib_a-w_sqrt.o): In function
sqrt’:
/xtensa/esp-open-sdk/crosstool-
NG/.build/src/newlib-2.0.0/newlib/libm/math/w_sqrt.c:6 9: undefined reference
to `__ieee754_sqrt’
collect2: error: ld returned 1 exit status
*** [.pioenvs/esp12e/firmware.elf] Error 1
Please try to replace the
libm.a file in the
“.platformio/packages/toolchain-xtensa/xtensa-lx106elf/lib/” after extract.
Refer to: https://github.com/esp8266/Arduino/issues/612
F/W Version History
Release Date
| Version| Description|
Git
---|---|---|---
Oct 11
2019|
v1.6
| Fix the “ISR, not in IRAM” error| https://github.com/hardkernel/smartpower2/tree/v1.6-arduino
May 17
2019|
v1.5
| Add Arduino branch| https://github.com/hardkernel/smartpower2/tree/v1.5-arduino
May 28
2018|
v1.4
| Add receiving power data function through serial| https://github.com/hardkemel/smartpower2/tree/v1.4
February
12 2018| v1.3| Fix compile errors|
March 27
2017| v1.2| Fix the LCD display of watt-hours, display volts, and amps to
three decimal places on the web interface.|
January
22 2017|
v1.1
| Add console logging with telnet and make SSID unique to each device| https://github.com/hardkernel/smartpower2/tree/v1.1
F/W upload
tutorials
Release Note of F/W v1.6
- Fix the “ISR, not in IRAM” error: https://github.com/hardkernel/smartpower2/commit/03741a6fb96f5e2b64f3f342e8ed324136e78ea3
Release Note of F/W v1.5
- Add the Arduino branch
- Fix build flags on the platform: https://github.com/hardkernel/smartpower2/commit/998e002d1c4520b54701307dd60f841c9bf58f63
Release Note of F/W v1.4
-
You can receive power data(current, voltage, power, watt-hour) from your SmartPower2
through serial
Release Note of F/W v1.1
Thanks to https://github.com/OtherCrashOverride
New features
- console logging with telnet
- Assign a Unique SSID on each device for using multiple SmartPower2s simultaneously.
References
- Redirecting...
- arduino.esp8266.com/stable/package_esp8266com_index.json
- files.gitter.im/esp8266/Arduino/Abqa/libm.a.tbz
- Stable version libm.a compilation error · Issue #612 · esp8266/Arduino · GitHub
- GitHub - hardkernel/smartpower2
- fix the error "ISR not in IRAM" · hardkernel/smartpower2@03741a6 · GitHub
- fix the error "ISR not in IRAM" · hardkernel/smartpower2@03741a6 · GitHub
- update to v1.5 · hardkernel/smartpower2@998e002 · GitHub
- update to v1.5 · hardkernel/smartpower2@998e002 · GitHub
- Releases · hardkernel/smartpower2 · GitHub
- GitHub - hardkernel/smartpower2 at v1.1
- GitHub - hardkernel/smartpower2 at v1.4
- GitHub - hardkernel/smartpower2 at v1.5-arduino
- GitHub - hardkernel/smartpower2 at v1.6-arduino
- OtherCrashOverride · GitHub
- accessory:power_supply_battery:arduino_board_manager_url.png [ODROID Wiki]
- accessory:power_supply_battery:arduino_board_nodemcu.png [ODROID Wiki]
- accessory:power_supply_battery:arduino_ide.png [ODROID Wiki]
- accessory:power_supply_battery:arduino_open_project.png [ODROID Wiki]
- accessory:power_supply_battery:arduino_sketchbook_location.png [ODROID Wiki]
- accessory:power_supply_battery:arduino_upload.png [ODROID Wiki]
- accessory:power_supply_battery:arduino_uploadfs.png [ODROID Wiki]
- accessory:power_supply_battery:board_manater_esp8266.png [ODROID Wiki]
- accessory:power_supply_battery:ipsetting.png [ODROID Wiki]
- en:acc:sp2:block.png [ODROID Wiki]
- en:acc:sp2:board_onoff.png [ODROID Wiki]
- en:acc:sp2:board.jpg [ODROID Wiki]
- en:acc:sp2:home.png [ODROID Wiki]
- en:acc:sp2:hwblock.png [ODROID Wiki]
- en:acc:sp2:ip.png [ODROID Wiki]
- en:acc:sp2:lcd_bottom.jpg [ODROID Wiki]
- en:acc:sp2:lcd_top.jpg [ODROID Wiki]
- en:acc:sp2:led.png [ODROID Wiki]
- en:acc:sp2:run.png [ODROID Wiki]
- en:acc:sp2:select_esp8266.png [ODROID Wiki]
Read User Manual Online (PDF format)
Read User Manual Online (PDF format) >>