Posts Tagged ‘esp32’

ESP32-PICO-KIT v4 Board Based on ESP32-PICO-D4 SiP Now Available for $10

December 7th, 2017 2 comments

A little while ago, I received a bunch of ESP32 PICO Core development boards which were based on Espressif Systems ESP32-PICO-D4 system-in-package with ESP32, 4MB SPI Flash, and other components. The advantage of such chip is that is requires less external component, and allows for smaller designs. For example, the boards I received would leave two row of pin on each side of the board, while most other ESP32 boards will only expose one row on each side.

I used the board to play with Micropython ESP32 port, and later-on when I launched a giveaway of 8 of the boards, I found out the name had changed to ESP32-PICO Kit, with the documentation listing v3 with all pins connected to male headers, and v4 with 6-pin not connected to a male header as shown in the photo below. Both versions of the board also have a different pin layout. But you don’t need to care since AFAIK v3 was never up for sale.

ESP32-PICO-KIT v4 however has now just launched, and Electrodragon offers it for $10 plus shipping.

Board specifications:

  • SiP – ESP32-PICO-D4 802.11 b/g/n WiFi + Bluetooth LE system-in-package
  • 3D antenna
  • USB – 1x micro USB port for power and programming;  CP2102 USB-TTL Serial Bridge
  • Expansion – 2x 20-pin headers with I/O and power signals. 2x 17-pin male headers soldered
  • Misc – EN and Boot buttons, on board power indicator LED.
  • Power regulator – AMS1117 3.3V regulator
  • Auto reset circuit
  • Dimensions – 51 x 20 mm

This board can be used like any other ESP32 board with ESP32 IDF SDK, Arduino Core, Micropython, and so on, it’s just narrower than most.

Other ESP32-PICO-D4 based boards have been launched such ESP32-PICO motherboard sold for $16 on Tindie, or TTGO T7, recently discovered by Time4EE, that can be purchased for $8.50 plus shipping on Aliexpress. The latter is however quite wider than the official Espressif devkit (estimated dimensions: 50×30 mm), but does provide a battery connector


Standard ESP32 boards can now be purchased for as low as $5, so boards based on the SiP are currently a little bit more expensive, but I’d expect the price difference to come down overtime.

A Day at Chiang Mai Maker Party 4.0

December 6th, 2017 6 comments

The Chiang Mai Maker Party 4.0 is now taking place until December 9, and I went there today, as I was especially interested in the scheduled NB-IoT talk and workshop to find out what was the status about LPWA in Thailand. But there are many other activities planned, and if you happen to be in Chiang Main in the next few days, you may want to check out the schedule on the event page or Facebook.

I’m going to go though what I’ve done today to give you a better idea about the event, or even the maker movement in Thailand.

Click to Enlarge

Booth and activity area should be the same over the 4 days, but the talks, open activity, and workshop will be different each day. Today, people could learn how to solder in the activity area.
The even was not really big with manufacturers/sellers like ThaiEasyElec, INEX, or Gravitech closer to the entrance…

… and slighter higher up in a different zone, companies and makers were showcasing their products or projects. I still managed to spent 5 interesting hours at the event attending to talks and checking out the various projects.

I started my day with a talk entitled “Maker Movement in South East Asia” presented by William Hooi, previously a teacher, who found One Maker Group and setup the first MakerSpace in Singapore, as well as helped introduce the Maker Faire in Singapore in 2012 onwards.

There was three parts to talk with an history of the Maker movement (worldwide), the maker movement in Singapore, and whether Making should be integrated into school curriculum.
He explained at first the government who not know about makers, so it was difficult to get funding, but eventually they jump on the bandwagon, and are now puring money on maker initiative. One thing that surprised me in the talk is that before makers were hidden their hobby, for fear of being mocked by other, for one for one person doing an LED jacket, and another working on an Iron Man suit. The people around them would not understand why they would waste their time on such endeavors, but the Maker Space and Faire helped finding like minded people. Some of the micro:bit boards apparently ended in Singapore, and when I say some, I mean 100,000 units. Another thing that I learned is the concept of “digital retreat for kids” where parents send kids to make things with their hands – for example soldering -, and not use smartphone or tablets at all, since they are already so accustomed to those devices.

One I was done with the talk, I walked around, so I’ll report about some of the interesting project I came across. I may write more detailed posts for some of the items lateron.

Click to Enlarge

Falling object detection demo using OpenCV on the software side, a webcam connected to…

Click to Enlarge

ASUS Tinker board to handle fall detection, and an NVIDIA Jetson board for artificial intelligence. If fall is detection an alert to send to the tablet, and the system also interfaces with Xiaomi Mi band 2.

Katunyou has also made a more compact product, still based on Tinker Board, for nursing home, or private home where an elderly may live alone. The person at the stand also organizes Raspberry Pi 3 workshops in Chiang Mai.

I found yet another product based on Raspberry Pi 3 board. SRAN is a network security device made by Global Tech that report threats from devices accessing your network using machine learning.

Click to Enlarge

Nordic Technology House showcased a magic mirror based on Raspberry Pi 3, and a webcam to detect your dance move, but their actual product shown above is a real-time indoor air monitoring system that report temperature, humidity, CO2 level, and PM 2.5 levels, and come sent alerts via LINE if thresholds are exceeded.

One booth had some drones including the larger one above spraying insecticides for the agriculture market.

Click to Enlarge

There was also a large about sewing machines, including some smarter one where you can design embroidery in a table before sewing.

There were also a few custom ESP8266 or ESP32 boards, but I forgot to take photos.

The Maker Party is also a good place to go with your want to buy some board or smart home devices.

Click to Enlarge

Beside Raspberry Pi Zero W / 3, ESP8266 boards and Asus Tinker board seem to be popular items in Thailand. I could also spot Sonoff wireless switch, and an Amazon Dot, although I could confirm only English is supported, no Thai language.

BBC Micro:bit board and accessories can also be bought at the event.

M5Stack modules, and Raspberry Pi 3 Voice Kit were also for sale.

Click to Enlarge

Books are also available for ESP32, Raspberry Pi 3, IoT, etc… in Thai language.

Click to Enlarge

But if you can’t read Thai there was also a choice of book in English about RPi, Arduino, Linux for Makers, IoT and so on. I then attended the second talk of the day: “NB-IoT” by AIS, one of the top telco company in Thailand. Speakers included Phuchong Charoensub, IoT Marketing Specialist, and Pornsak Hanvoravongchai, Device Innovation Manager, among others. They went through various part include a presentation of AIS current M2M business, what IoT will change (e.g. brings in statups and makers), some technical details about NB-IoT, and the company offering for makers.

I’ll go into more details in a separate post tomorrow, but if you want to get started the good news is that it’s now possible to pre-order a 1,990 THB Arduino Shield ($61) between December 6-9, and get it shipped on February 14, 2018. NB-IoT connectivity is free for one year, and will then cost 350 Baht (around $10) per year per device. However, there’s a cost to enable NB-IoT on LTE base stations, so AIS will only enable NB-IoT at some universities, and maker spaces, meaning for example, I would most certainly be able to use such kit from home. An AIS representative told me their no roadmap for deployment, it will depend on the business demand for such services.

If you are lucky you may even spot one or two dancing dinosaurs at the event.

Xiaomi Unveils Their Very Own ESP32 Development Board, Module & SDK

November 28th, 2017 11 comments

We now have plenty of modules and board based on Espressif System ESP32 dual core wireless SoC, and a fairly good software support with ESP IDF SDK, Arduino CoreMicroPython, Espruino and other solutions.

So I was surprised when I saw Teo Swee Ann, Espressif CEO, posted photos about an event – Xiaomi IoT Developer Conference – where Xiaomi apparently introduced their own ESP32 development board, together their own SDK (still empty right now) compatible with the company’s Mijia ecosystem, as part of their “Open IoT platform”

Click to Enlarge

The slide below translates as “WIFI module –  Automated manufacturing / 4-fold foolproof mechanism / whole process tracing / cost price (about 15 RMB)” and “Open source SDK”, with the price likely the price of Xiaomi ESP32 module (ESP-WROOM-32C) shown on board above (Thank to hm for translation).

Click to Enlarge

I could not find much information at this early stage, except new partnership between Baidu and Xiaomi for A.I. and IoT which does not mention the board. I’ll update this post, once more details are available.

Giveaway Week Winners – November 2017

November 9th, 2017 15 comments

Like every year, I’ve organized a giveaway week to send some of the items I’ve reviewed in the past year or so. There was a good mix of devices this year starting with a mini Linux NAS kit, following by some ESP32 boards, and Amlogic development boards among others.

The results are in, and instead of 10 winners, I actually have 11 winners due a “timing issue”, and to make for one missing ESP32 board, a LinkIt Smart 7688 Duo board was also given away.

Click to Enlarge

While it started strongly for Eastern Europe, We have winners from 3 continents this year:

  • NanoPi NEO2 NAS Kit – Hap Hapablap, Serbia
  • Muses Beta DVB Encoder and Modulator Board – Luka, Slovenia
  • ESP32 PICO Kit v3 boards (5 Winners):
    • Andrius Kurtinaitis, Lithuania (2x ESP32 boards)
    • Kebab, Turkey (2x ESP32 boards)
    • Zoobab, Belgium (2x ESP32 boards)
    • Sollie, Germany (2x ESP32 boards)
    • BobR, USA (1x ESP32 PICO Kit + LinkIt Smart 7688 Duo)
  • NanoPi K2 board – ml, Sweden
  • Wio GPS Tracker – Tumpang L., Malaysia
  • Nextion Enhanced 7″ Display – Ved Vernekar, USA
  • Khadas VIM Pro board – gleveque, France

I’ve just send all 11 packages earlier this afternoon.

I hope the winners will enjoy their prizes, and thank you to everyone who played. Let’s do it again next year.

Giveaway Week – ESP32 PICO Kit v3 Boards

November 1st, 2017 240 comments

I don’t have one, but eight boards to give away to four winners (2 each) with Espressif Systems ESP32 PICO Kit v3 board based on ESP32-PICO-D4 SIP, an all-in one package with ESP32, 4MB SPI flash, crystal oscillator, and passive components, which allows for smaller boards.

Click to Enlarge

The board is very similar to any other ESP32 boards, and software compatible, but it’s just quite thinner, and easier to work with on breadboards. Since I had already played with Arduino Core and Espruino (JavaScript) on other boards, I used one of the 10 boards provided by Espressif to play with Micropyhon on ESP32.

Each winner will get two ESP32 PICO Core board in order to make it worthwhile with regards to shipping costs.

To enter the draw simply leave a comment below. Other rules are as follows:

  • Only one entry per contest. I will filter out entries with the same IP and/or email address.
  • Contests are open for 48 hours starting at 10am (Bangkok time) every day. Comments will be closed after 48 hours.
  • Winners will be selected with, and announced in the comments section of each giveaway.
  • I’ll contact the winners by email, and I’ll expect an answer within 24 hours, or I’ll pick another winner.
  • Shipping
    • $4 for registered airmail small packet for oversea shipping payable via Paypal within 48 hours once the contest (for a given product) is complete.
    • If Paypal is not available in your country, you can still play, and I’ll cover the cost of sending the parcel by Sea and Land (SAL) without registration if you win.
  • I’ll post all 10 prizes at the same time, around the 8th of November
  • I’ll make sure we have 10 different winners, so if you have already won a device during this giveaway week, I’ll draw another person.

Good luck!

The boards above are not for sale yet, but the similar ESP32-PICO motherboard is sold for $16 on Tindie. Alternatively, you could contact Espressif Systems, if you are interested in getting ESP32 PICO Core samples.

Getting Started with MicroPython on ESP32 – Hello World, GPIO, and WiFi

October 16th, 2017 13 comments

I’ve been playing with several ESP32 boards over the months, and tried several firmware images. I started with a tutorial for Arduino Core on ESP32, a few month later I tested ESP32 JavaScript programming with Espruino on ESPino32 board, and recently Espressif Systems sent me ESP32 PICO core development board powered by their ESP32-PICO-D4 SiP, and while I took some pretty photos, I had not used it so far.

So I decided to go with yet another firmware, and this time, I played with MicroPython on ESP32, and will report my experience with basic commands, controlling GPIOs, and WiFi in this getting started post.

Flashing Micropython Firmware to ESP32 Board

Source code is available on Github, as a fork of MicroPython repo as ESP32 support has not been upstreamed yet. We could built the firmware from source, but there’s also a pre-built binary which you can download on MicroPython website.

I’ll be using Ubuntu 16.04 for the instructions, which should be pretty similar for other Linux distributions, especially the ones based on Debian, and if you’re using Windows 10, you should be able to follow the same instructions after installing Windows Subsystem for Linux with Ubuntu on your computer.

Let’s open a terminal, to download the firmware (October 14):

If you have not done so already, install the latest version of esptool:

Now connect the board via a micro USB to USB cable to your computer. The log should like like:

In my case, the device is ttyUSB0, but it may vary depending on the board used. We can now erase the flash, and copy the firmware to the board:

If the last step is successfull,  the output should be similar to the one below:

As a side note, version 2.1 of esptool does not know about ESP32-PICO-D4, but it can still detect an ESP32 device, and the update went through normally.

Hello World Sample / Boot Log with MicroPython

We can test the firmware, by connecting to the board using minicom, screen, putty, or whatever software you feel most comfortable with. I went with minicom, setup a connection to /dev/ttyUSB0 device with 115200 bps baudrate. I immediately tested the print function, and made an hard reset to check out the boot log:

The reset command will first generate some errors message, before rebooting the board:

We can type help function to get some more help:

I also often refered to MicroPython 1.9.2 documentation to write this quick start guide.

LED Blink Sample with MicroPython

The easiest way to test GPIOs is to connect an LED, since the board does not have any user LED, only the power LED. So I connected an LED to pin 21 via a transistor to ensure enough current passes through it.

Controlling the LED in the command line interface is easy. Import the machine library, set the pin to output, and change the pin level as needed:

Success! But what about doing a proper blink sample? MicroPython developers’ official PyBoard would show as a USB mass storage drive in you computer, where can copy Python files like and files, but in the case of ESP32 PICO core, it appears the only option is to use the serial console for programming, as we can’t simply copy files to the board from the host computer.

I  found a solution on Techtutorialsx – which also has plenty of articles about MicroPython on ESP32/ESP8266. We need ampy script that can be install from our Linux terminal:

However, the first time I tried it I got an error:

I installed files module, but the error remained. So instead I installed it for Python 3:

I then created on my computer to blink the LED every 500 ms:

Before uploading the file to the board, you can try to run it as follow:

If you have plenty of errors here, that’s probably because your code is incorrect. Since I’m not very familiar with Python, it happened to me a couple of times, until I got the code right, and the LED was blinking as expected.

Now that we’ve made sure the code works, we can now copy our sample to the board…

… reconnect to the serial console, and verify the file is there:

To run the program type the following:

The LED should blink again. You can interrupt the program with Ctrl+C, and if you want to soft reset the board, press Ctrl+D.

In order to automatically start the blink program at each boot, rename to, delete, and copy instead:

Power cycle the board, and the LED should start blinking almost immediately.

ESP32 WiFi with MicroPython (Station and AP modes)

We’ve got GPIOs working, but one of the most important feature of ESP32 is obvisouly WiFi. I’ll start by configuring the board in station mode. First import the network library, set the board to station mode, and scan access points:

The latter should return a list of access points with ssid, bssid, channel, RSSI, authmode, and hidden status as explained here.

I can then connect the board to one of the access points with:

The log above with IP address should give  a clue, but you can check connection status with the following function:

and use ifconfig to get the IP info:

Switching to AP mode is easy with the three commands below configuring the board with ESP32-PICO-CNX SSID:

At this stage I can see ESP32-PICO-CNX on my phone, but it’s an open connection. We can change that with authmode option that can take 5 values:

  • 0 – open
  • 1 – WEP
  • 2 – WPA-PSK
  • 3 – WPA2-PSK
  • 4 – WPA/WPA2-PSK

I’ll use WPA2-PSK and define the password with the config function.

Working as planned…

ESP32 Web Server with Micropython

Many ESP32 project will require a web interface for monitoring or configuration. Let’s first setup the board as an access point using the command we’ve used above:

Now create file based on Python code found here that’s supposed to return the status of some GPIO pins in an HTML table:

Copy the file to the board:

Start the serial console again, import/run the python sample we’ve copied, and connect to the board (in my case


It works as expected, but we wrote the HTML code inside the Python file, and you need to handle socket programming by yourself. To further simply the task, some MicroPython web servers such as MicroWebSrv, and Picoweb are available.

MicroWebSrv (Not working yet for me)

I tried to install MicroWebSrv first, but never managed to make it work. I still reproduce the step I followed in case somebody finds out what I did wrong. I got the code, and copied files from the Linux terminal:

We can check the files are where they are supposed to be:

Go into the terminal (aka REPL console) to start a basic example, after setting up a connection:

I could connect to the server, but I would always get 404 error.


So instead I switched to picoweb, adapting the instructions here and there. It’s very easy to install.  First make sure you have a working Internet connection in your board (i.e. set station mode), and install the web server with upip:

That’s the output if everything goes according to plans:

Now let’s go back to the host computer to create an html document, for example index.html:

as well as sample file that will request the HTML page from the board, and return it to the client.

You’ll need to change “” by the IP address of your board.

Let’s copy both files to the board…

… go back to the serial console, connect in station mode, and run the sample:

Type or copy/paste the URL in the last line into a web browser, and you should get the output below.

ESP32 Bluetooth with MicroPython

There’s no Bluetooth support in the official MicroPython documentation, because it’s work in progress, and for the most adventurous MrSulry released an alpha version  a few days ago. The Bluetooth API is also in flux, but the basic code to enable Bluetooth should look like:

I’ll update that section once Bluetooth makes it to the stable release, and/or when I’m sure the API is frozen.

Other ESP32 (Micro)Python Resources

I’ve just covered a few things that can be done with MicroPyhon on ESP32, and beside the official documentation, you can also check the various MicroPython ESP32 tutoral on techtutorialsx blog. Loboris also made another MicroPython ESP32 firmware that supports pSRAM as MicroPython may use a lot of RAM. If you’re interested in Python for ESP32, but Zerynth is another option for Python on ESP32 that works with an IDE/GUI available for Windows, Linux and MAC OS X. [Update: Yet other options are Pumbaa a port of MicroPython running on top of Simba, and Pycom version of MicroPython]

This TTGO Board Combines ESP32, LoRa Radio, and OLED Display for just $10

October 13th, 2017 12 comments

Just one year ago, it would cost around $15 to $20+ to get an ESP32 board, that is if you were lucky/fast enough to order one one before it went out of stock. Since then, availability is no longer an issue, and you now can get an ESP32 development board for as low as about $7, or even around $4 during promotions.

Today, I was made aware of another board sold under the “TTGO” brand, that includes not only ESP32 WiFi and Bluetooth SoC, but also a (433 MHz) LoRa radio, and an OLED display. Price? Just $10 plus shipping ($1.75 here).

Battery not Included – Click to Enlarge

TTGO ESP32/LoRa board specifications:

  • WiSoC – Espressif ESP32
  • Storage – 32MB on-board flash (or maybe just 16MB?)
  • LoRa
    • Semtech SX1278 with u.FL connector + 433MHz antenna (N.B.: Antenna must be connected during use or the Semtech chip could be damaged)
    • Sensitivity” ~ -148dBm; output power: +20dBm
  • Display – 0.96″ blue OLED display
  • USB – 1x micro USB port for debugging (CP2102) and power
  • Expansion – 2x 18-pin headers with GPIOs, UART, ADC, Touch, SPI, power signals… (See pinout diagram)
  • Misc – Charging Status LED
  • Power Supply – 5V via micro USB port, 2-pin battery header, 5V Pin. (Operating voltage: 3.3V to 7V)

The board can be programmed with the Arduino IDE after downloading and installing the TTGO folder in arduino/hardware. After selecting “WiFi_LoRa_32” board, you should be able to load various samples to play with the board.

Click to Enlarge

The board is sold with a 433MHz antenna, and two male headers. You’ll save a little bit on shipping if you purchase two kits instead.  The board can also be found on eBay and Banggood.

Thanks to Mpampis for the tip.

HeartyPatch is an Open Source Wireless ECG Patch Powered by ESP32 WiSoC (Crowdfunding)

October 2nd, 2017 No comments

Smart health gadgets will soon have a bigger part to play in our lives, especially for health monitoring. It mainly started with fitness trackers, but now we are starting to see connected devices such as blood pressure monitors, including the upcoming watch like Omron HeartVue, thermometer, scales, vital sign monitoring systems, certified medical SBC‘s to allow engineers to developer their own medical applications, and even open source surgical robots.

HeartPatch is one of those medical board that specifically aims at measuring ECG data, and sent it over Bluetooth or WiFi thanks to Espressif ESP32 WiSoC.

HeartPatch specifications:

  • SoC – Espressif Systems ESP32 dual core Tensilica LX6 processor with Wi-Fi/Bluetooth
  • ECG Chip – Maxim MAX30003 analog front-end
  • USB – 1x micro USB connector for programming, data, power, and battery charging
  • Debugging – USB-UART bridge based on CP2104
  • Misc – Onboard Snap-on Buttons for disposable electrode pads, RGB LED,
  • Battery – 450 mAH LiPo battery
  • Dimensions – 65 mm x 42 mm x 4 mm without battery; Dimensions with Case: ~70 mm x 46 mm x 12.7 mm

Basic Kit with Battery and Electrodes

The developers explain that HeartyPatch has several advantages over other low-price heart monitors:

  • ECG-based R-R Interval Measurement is more accurate than optical heart-rate measurement
  • Wide Dynamic Range for robust functioning during movement (not available in traditional ECG monitors)
  • Mathematical and Machine Learning Algorithms for automatic detection of arrhythmia, stress, and several other physiological conditions (not available with regular heart-rate patches)
  • Small, Wearable Form-factor with snap connectors for disposable, pre-gelled ECG electrodes.
  • Open Source and Non-proprietary – can be used with any software or algorithm

HealthyPatch is fully open source hardware with all files available on Github. The current GUI can support three modes:  beat-to-beat, Arrhythmia detection, and Heart-rate variability. If you have the required skills, you’d be able to add other modes to the user interface, or even roll your own. Note that ESP32 currently supports all BLE profiles, but the baseband works only in Bluetooth Classic mode. It will not affect the function, but battery life will be shorter than normal. Espressif Systems claims this will be fixed in the next release (SDK or Silicon?). If you want to follow the project’s progress over time, you may want to visit the page.

HeartyPatch has just been launched on CrowdSupply, where you can get the basic kit with the board, a 450 mAh Li-Ion battery (soldered to the board), and a set of 10 disposable electrode pads with a $87 or more pledge. You can also add a case for $15, and shipping is free to the US, $15 to the rest of the world. Delivery is scheduled for December 14, 2017.