PixelRadio is a FM Radio Transmitter with RDS (Radio Data System) capabilities. It was developed for holiday "Pixel" displays (e.g., animated Christmas lights) and house projection installations.
This is an open source project. So all firmware source code is available to download.
Programming experience will be needed if you intend to make improvements to the code. The target device is a LilyGO TTGO-T8 ESP32 microcontroller.
Compiling the source code requires VSCode with the PlatformIO IDE extension. Current release compiles on PlatformIO Core 6.1.4, Home 3.4.3.
The software is written in C and requires PlatformIO's Espressif32 board platform and Arduino framework. Current release was built using Espressif32 5.2.0.
This project uses open source ESP32 Arduino Libraries. However, the source code will not successfully compile with the Arduino IDE. Please use PlatformIO.
The firmware can be installed two ways.
The recommended method uses the PlatformIO IDE.
But an alternate method is to use the uploader program that is provided by Espressif
.
Both methods are discussed below.
The firmware can be uploaded directly from the PlatformIO Build Environment. Begin by launching PlatformIO and open the PixelRadio Folder.
- Edit the
platformio_user.ini
file and change the COM Port numbers to match your TTGO ESP32 device. - Make a duplicate of the
credentials_user.h
file. Rename the new filecredentials.h
and add your WiFi settings to it. - Advanced users can edit
config.h
to alter the features; first time users should use the file as-is.
- Disconnect PixelRadio's 12VDC power supply.
Using a USB cable, connect the TTGO ESP32 to your PC.
Remove the MicroSD Card (if installed) from the ESP32.
IMPORTANT: The MicroSD Card MUST be removed before flashing!
-
Select PlatformIO's Upload function. It will appear in the
Project Tasks
menu after clicking the PlatformIO Icon (Ant Head) on the left side of the screen. Click the Upload function to build the firmware and perform the Upload. -
Initial Uploads may fail due to missing libraries. Simply repeat the Upload and the missing dependencies will be added to the project so it can be built. A successful build will automatically launch the file uploader and Flash the ESP32 device.
-
After a successful Upload, execute PlatformIO's
Upload Filesystem Image
function. This will Flash the data files needed by PixelRadio.
It's not necessary to use PlatformIO to Build and Upload the firmware.
That's because a compiled binary file is provided in the zip download.
The binary can be Flashed onto the ESP32 microcontroller using espressif Flash Download Tool
.
Espressif's software utility runs on the Windows platform. For other operating systems please do a web search for a ESP32 Flash Tool that is compatible with your PC environment.
The Flashing Tool is available here: DOWNLOAD FLASH TOOL
-
Install the Flash Download Tool.
-
At the Flash Download Tool's root folder, create a sub-folder named
/bin
.
Copy the following PixelRadio files to the sub-folder:
boot_app0.bin
bootloader_dout_40m.bin
partitions.bin
pixelradio.bin -
Launch the Flash Download Tool.
ChooseESP32
for chipType.
Choosedevelop
for the workMode.
Chooseuart
for the loadMode.
PressOK
. -
On the SPIDownload Tab, add the four bin files (see screenshot for example).
Important: The file paths must match your/bin
folder location.
Confirm the bin offsets are correctly entered, as follows:
bootloader_dout_40m.bin @ 0x1000
partitions.bin @ 0x8000
boot_app0.bin @ 0xe000
pixelradio.bin @ 0x10000 -
Enable all the settings shown in the screenshot.
Important: TheCOM
entry must match your ESP32's USB COM port. -
Disconnect PixelRadio's 12VDC power supply.
Using a USB cable, connect the TTGO ESP32 to your PC.
Remove the MicroSD Card (if installed) from the ESP32.
IMPORTANT: The MicroSD Card MUST be removed before flashing!
-
Press Start (located at the lower left corner of Flashing Tool).
Flashing takes about a minute. If the upload fails then check your settings and try again.
Unplug the ESP32 after the upload is successful. -
One support file must be manually added using a microSD card.
The microSD Card (32GB or less) must be formatted as FAT32.
Copy theRadioLogo225x75_base64.gif
file from the project data folder to the SD Card.
Do NOT rename the file. -
Insert the SD Card into the ESP32 and apply power.
Wait one minute then remove the SD card. -
PixelRadio is now ready to use.
Now that PixelRadio is programmed it's a good time to review the instruction manual. Start here: User Manual.