Happy Holidays! (W/ binary for your ESP32!)

ESP_Sprite
Posts: 1567
Joined: Thu Nov 26, 2015 4:08 am

Happy Holidays! (W/ binary for your ESP32!)

Postby ESP_Sprite » Wed Dec 27, 2017 5:54 am

So, the (Western) holidays came around again, and even while they're celebrated not nearly as much as e.g. the Chinese new year around here, we still want to wish everyone a happy 2018... and what better way to do this using an ESP32?

For this, you need:
  • An ESP32 board. Most of them will do, although it's important they have >=4MByte of flash which can be addressed using QIO at 80MHz. If you have an ESP-Wroom or -Wrover, or a devboard with one of these on them, they'll work. GPIO25 and 26 must be available; we need those later. For now, the ESP32 needs to be a Rev1, as the current binary seems to have issues with Rev0 silicon. We're looking into this.
  • A TV (or other display device) with composite input that can display PAL. Most TVs are capable of PAL and NTSC now, so if you don't know, just try and it probably will work.
  • A cable to hook the ESP32 up to an audio and composite video input on said TV
  • Some resistors
With those, please build up the following schematic

Code: Select all

 ESP32                     TV                       
                                                   
                                                   
GPIO25 ----[150R]-------- Composite jack center     
                                                   
GPIO26 ----[ 1K ]--+----- Audio jack center         
                   |                               
                  ---                               
                   1                               
                   K                               
                  ---                               
                   |   -- Audio jack GND           
Gnd    ------------+-- +- Composite jack GND


Also, you need to flash the ESP32 with the attached binary, like e.g. this:

Code: Select all

python ${IDF_PATH}/components/esptool_py/esptool/esptool.py --port /dev/ttyUSB0 --baud $((115200*4)) write_flash 0 holidays2017.bin


Solder everything together, attach the flashed ESP32 board to your TV, power on the TV and select the composite input, power on the ESP32, enjoy!

(Also, I hope this works for most people... I've only been able to test this on two devices up to now. You have no idea how scarce TVs/monitors with composite input are around the ESP32 offices. On that note, while I'm pretty sure this device is harmless, Espressif takes no responsibility if you happen to blow up anything with this.)
Attachments
holidays2017.zip
(1.73 MiB) Downloaded 206 times

ESP_Sprite
Posts: 1567
Joined: Thu Nov 26, 2015 4:08 am

Happy Holidays! (W/ binary for your ESP32!)

Postby ESP_Sprite » Wed Dec 27, 2017 5:57 am

Also, we will release the sources and a writeup for this somewhere in the new year. For now, feel free to speculate how this works. (And no, we didn't use any undocumented features in the ESP32... okay, maybe one, but that was to work around an also undocumented limitation in a peripheral.)

permal
Posts: 207
Joined: Sun May 14, 2017 5:36 pm

Re: Happy Holidays! (W/ binary for your ESP32!)

Postby permal » Wed Dec 27, 2017 12:04 pm

I won't be doing this, but I appreciate the effort :)

Happy Holidays to you and yours, @ESP_Sprite!

ESP_Sprite
Posts: 1567
Joined: Thu Nov 26, 2015 4:08 am

Re: Happy Holidays! (W/ binary for your ESP32!)

Postby ESP_Sprite » Sat Dec 30, 2017 9:36 am

Subtle kick: no one tried this yet?

JimmyPedersen
Posts: 13
Joined: Sun Nov 15, 2015 4:14 am

Re: Happy Holidays! (W/ binary for your ESP32!)

Postby JimmyPedersen » Sat Dec 30, 2017 1:35 pm

Hi
Tried it with an LOLIN32 v.1.0.0 board but I got no signal on the outputs (Checked with oscilloscope).

Here's the output from the flashing:
c:\Users\Jimmy\OneDrive\holidays2017>python c:\esp-idf\components\esptool_py\esptool\esptool.py --port com7 --baud 230400 write_flash 0 holidays2017.bin
esptool.py v2.1
Connecting....
Detecting chip type... ESP32
Chip is ESP32D0WDQ6 (revision 0)
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 230400
Changed.
Configuring flash size...
Auto-detected Flash size: 4MB
Compressed 3145728 bytes to 1802179...
Wrote 3145728 bytes (1802179 compressed) at 0x00000000 in 80.7 seconds (effective 311.8 kbit/s)...
Hash of data verified.

Leaving...
Hard resetting...

Can't find anything strange in that.
Here's is a picture from my quick-and-dirty build:
20171230_142756.jpg
20171230_142756.jpg (3 MiB) Viewed 2161 times


Any ideas?


Edit:
Looks like I keep getting watchdog resets, this keeps repeating in the terminal window:

rst:0x8 (TG1WDT_SYS_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0018,len:4
load:0x3fff001c,len:6088
load:0x40078000,len:0
ho 12 tail 0 room 4
load:0x40078000,len:15588
entry 0x4007907c
I (352) boot: Detected ESP32
W (101) boot: PRO CPU has been reset by WDT.
W (102) boot: WDT reset info: PRO CPU PC=0x40082822
W (102) boot: WDT reset info: APP CPU PC=0x400d121a (waiti mode)
I (109) boot: ESP-IDF v3.1-dev-35-g9922172e1 2nd stage bootloader
I (116) boot: compile time 12:27:48
I (120) boot: Enabling RNG early entropy source...
I (126) qio_mode: Enabling default flash chip QIO
I (131) boot: SPI Speed : 80MHz
I (135) boot: SPI Mode : QIO
I (139) boot: SPI Flash Size : 4MB
I (143) boot: Partition Table:
I (147) boot: ## Label Usage Type ST Offset Length
I (155) boot: 0 nvs WiFi data 01 02 00009000 00006000
I (162) boot: 1 phy_init RF data 01 01 0000f000 00001000
I (170) boot: 2 factory factory app 00 00 00010000 00300000
I (177) boot: End of partition table
I (181) esp_image: segment 0: paddr=0x00010020 vaddr=0x3f400020 size=0x1b3088 (1781896) map
I (388) esp_image: segment 1: paddr=0x001c30b0 vaddr=0x3ffb0000 size=0x02e00 ( 11776) load
I (390) esp_image: segment 2: paddr=0x001c5eb8 vaddr=0x40080000 size=0x00400 ( 1024) load
I (395) esp_image: segment 3: paddr=0x001c62c0 vaddr=0x40080400 size=0x0879c ( 34716) load
I (408) esp_image: segment 4: paddr=0x001cea64 vaddr=0x400c0000 size=0x00000 ( 0) load
I (413) esp_image: segment 5: paddr=0x001cea6c vaddr=0x00000000 size=0x015a4 ( 5540)
I (422) esp_image: segment 6: paddr=0x001d0018 vaddr=0x400d0018 size=0x1e8f4 (125172) map
I (446) boot: Loaded app from partition at offset 0x10000
I (446) boot: Disabling RNG early entropy source...
I (446) cpu_start: Pro cpu up.
I (450) cpu_start: Starting app cpu, entry point is 0x40080e78
I (0) cpu_start: App cpu up.
I (460) heap_init: Initializing. RAM available for dynamic allocation:
I (467) heap_init: At 3FFAE6E0 len 00001920 (6 KiB): DRAM
I (473) heap_init: At 3FFB6720 len 000298E0 (166 KiB): DRAM
I (480) heap_init: At 3FFE0440 len 00003BC0 (14 KiB): D/IRAM
I (486) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM
I (492) heap_init: At 40088B9C len 00017464 (93 KiB): IRAM
I (498) cpu_start: Pro cpu start user code
I (68) cpu_start: Starting scheduler on PRO CPU.
I (0) cpu_start: Starting scheduler on APP CPU.


Any ideas?

Kind regards
Jimmy

ESP_Sprite
Posts: 1567
Joined: Thu Nov 26, 2015 4:08 am

Re: Happy Holidays! (W/ binary for your ESP32!)

Postby ESP_Sprite » Sat Dec 30, 2017 2:29 pm

Huh, I can replicate this... I have one DevkitC with a rev0 ESP32, but also different flash; it also crashes. My rev1 DevkitC with stock flashchip just works. Will see if I can fix this.

Edit: Looks like I broke the rev0 compatibility with a last-minute modification... not sure if I'm going to be able to code rev0 compatibility in there again, although I'll surely try.

ta-mat
Posts: 12
Joined: Thu Dec 21, 2017 4:07 pm

Re: Happy Holidays! (W/ binary for your ESP32!)

Postby ta-mat » Sat Dec 30, 2017 3:24 pm

Hey, videos and sounds are working fine here :)
Happy Holidays!

P.S. Scrollers and Trackers forever!!

User avatar
rudi ;-)
Posts: 1209
Joined: Fri Nov 13, 2015 3:25 pm

Re: Happy Holidays! (W/ binary for your ESP32!)

Postby rudi ;-) » Tue Jan 09, 2018 3:17 am

xmas-s-composite.gif
xmas-s-composite.gif (7.96 MiB) Viewed 1528 times



:roll:

why only DOS 3.3 and not PCDOS 7.0 or Rom-DOS eMbedded ?
( fun )

good work!

best wishes
rudi ;-)
-------------------------------------
love it, change it or leave it.
-------------------------------------
問候飛出去的朋友遍全球魯迪

Sergionn
Posts: 2
Joined: Fri Feb 23, 2018 9:14 am

Re: Happy Holidays! (W/ binary for your ESP32!)

Postby Sergionn » Fri Feb 23, 2018 9:23 am

Hi Esp_Sprite! Could you post sources for tweaks made possible to output composite video on ESP32, please!

ESP_Sprite
Posts: 1567
Joined: Thu Nov 26, 2015 4:08 am

Re: Happy Holidays! (W/ binary for your ESP32!)

Postby ESP_Sprite » Sat Feb 24, 2018 3:59 am

Yes. Plan withing Espressif is to actually start up a company blog, we'll be having the explanation of how this works as one of the first posts.

Who is online

Users browsing this forum: kolban and 4 guests