-
1Hardware set-up
Option 1: Using breadboard circuit
You can use your own modules with some components as shown in breadboard cricuit below.
NB: This circuit has no power management, so you need to be carefull with voltage levels: don't put power simultaneously from minitel and usb port.Option 2: Using ESP Minitel devboard
If you don't want to bother with modules and wiring, or if you want to have a more "end product" looking for your application, you can purchase a devboard for around 46 EUR excl. shipping, depending on some options.
Just send an email at contact@iodeo.fr for more information.Or you can get it on Tindie
-
2Get started with Arduino IDE
- Install software Arduino IDE
- Add Arduino-ESP32 core to the IDE as described here
- install Minitel1b library as follows
- download Minitel 1b library as ZIP file
- in Arduino IDE, go to Sketch / Include Library / Add .ZIP Library and select your ZIP file
- Connect your device using USB-C cable
- In Arduino IDE, select the corresponding serial port in Menu Tools/Port
! If you have difficulties with usb driver, check this sparkfun article - Select ESP32 Dev Module in Tools/Board type/ESP32 Arduino
Done!
You can already start programming with the default settings You can also custom the board settings to set correct flash size and partitionning if needed
As a starting point, you can run the example codes from Minitel1b library (File/Example/Minitel1b ...), by changing port to Serial2.
#include <Minitel1B_Hard.h> Minitel minitel(Serial2);
You will find examples dedicated to ESP32 in Minitel-ESP32 repository
-
3Get started with Thonny IDE
This section is about programming ESP32 in micropython which can be very usefull to explore ideas quickly using interactive prompts (even wirelessly !) and to port some python applications.
There are several ways to do it, but Thonny IDE has built-in functionnalities that makes it quick and easy.Here are some guidelines to get started.
Install software on your computer
Simply download and Install from Thonny IDE website
Flash micropython firmware to your ESP32 device
- Download latest stable micropython firmware for ESP32
- Connect your ESP32 device to your computer via USB
- Open Thonny IDE
- In menu, Go to Tools / Options
- In Options window, go to Interpreter tab select ESP32 and click Install or update firmware
- Select the serial port corresponding to your ESP32
(see Arduino section if you have difficulties) - Select the firmware downloaded in step 1.
- Choose keep flash mode
- Check erase flash option
- Click install
Done!
Start using the shell
When you open Thonny IDE, make sure it is set to run your device in micropython:
- Connect your ESP32 device on usb port
- Go to Interpreter tab of Options window (menu Tool/Options)
- Set the interpreter to MicroPython (ESP32)
- Set the serial port corresponding to your ESP32 device
- Click OK
Done!
You can already try some command in the shell, such as
print('hello world')
This seems nothing, but it is actually your ESP32 printing to the shell in real time without compiling.
Starting application development
- As a starting point you can download upynitel example from Minitel-ESP32 repo
- Copy folder to your computer to a known location
- Open Thonny IDE and navigate to this location in Files view tab
- To upload the files to your ESP32, simply right click on the files and click Upload to /
You wil see it appear in MycroPython device tab - Now, you need to know that micropython programs are written in boot.py and main.py which are run automatically at boot, similar to setup and loop in Arduino.
- After uploading your files, simply reboot your device to run your application
Some Tips
- in File window, you can upload / download files between computer and ESP32 using right clicks. You can also delete files easilly
- in Shell window, the following shortcut are usefull
- CTRL+D to soft reboot your device
- CTRL+C to interrupt execution
This is handy when you want to stop your main loop to regain shell interactive prompts
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.