S/PDIF has been round for a very long time; it’s nonetheless a extremely nice technique to ship streams of digital audio from system A to system B. [Nathan Ladwig] has acquired the ESP32 decoding SPDIF fairly successfully, utilizing an onboard peripheral outdoors its conventional remit.
On the ESP32, the Distant Management Transceiver (RMT) peripheral was meant to be used with infrared transceivers—assume TV remotes and the like. Nevertheless, this peripheral is definitely fairly versatile, and can be utilized for sending and receiving a variety of various alerts. [Nathan] was in a position to get it to work with S/PDIF fairly successfully. Notably, it has no outlined bitrate, which permits it to work with alerts of various pattern charges fairly simply. As an alternative, it makes use of biphase mark code to ship knowledge. With one or two transitions for every transmitted bit, it’s doable to seize the timing and decide the right clock from the sign itself.
[Nathan] achieved this feat as a part of his work to create an ESP32-based RTP streaming system. The venture permits an ESP32 to work as a USB audio system or take an S/PDIF sign as enter, after which transmitting that audio stream over RTP to a receiver which delivers the audio on the different finish by way of USB audio or as an SPDIF output. It’s a nifty venture that has functions for anybody that usually finds themselves needing to get digital audio from as soon as place to a different. It might probably additionally run a easy visualizer, too, with some hooked up LEDs.
It’s not the primary time we’ve seen S/PDIF decoded on a microcontroller; it’s fairly achievable if you understand what you’re doing. In the meantime, if you happen to’re cooking up your individual digital audio hacks, we’d love to listen to about it. Digitally, in fact, as a result of we don’t settle for analog telephone calls right here at Hackaday. Video after the break.