[CNLohr] has made a habit of using ATtiny microcontrollers for everything, and one of his most popular projects is using an ATTiny85 to generate NTSC video. With a $2 microcontroller and eight pins, [CNLohr] can put text and simple graphics on any TV. He’s back at it again, only this time the microcontroller isn’t plugged into the TV.
The ATtiny in this project is overclocked to 30MHz or so using the on-chip PLL. That, plus a few wires of sufficient length means this chip can generate and broadcast NTSC video.
[CNLohr] mentions that it should be possible to use this board to transmit closed captioning directly to a TV. If you’re looking for the simplest way to display text on a monitor with an AVR, there ‘ya go: a microcontroller and two wires. He’s unable to actually test this, as he lost the remote for his tiny TV from the turn of the millennium. Because there’s no way for [CNLohr] to enable closed captioning on his TV, he can’t build the obvious application for this circuit – a closed caption Twitter bot. That doesn’t mean you can’t.
Video below.
Wouldn’t a cheap universal remote have a CC button?
Or even a modern smartphone.
” has made a habit of using ATtiny microcontrollers for everything”
So you mean :”why doesn’t he connect an IR LED to an attiny”
Well, the answer is in the link ” It would be several hours for me to try to get my AVR with IR LED to do all the menus and everything to get closed captioning on :(”
He was just too eager to publish already.
wouldn’t it be less than an hour to write the code for the few buttons needed to navigate the menus?
ugh why doesn’t HaD let people edit posts. what I mean is wouldn’t it be as simple as tying the arrow, menu, and enter/ok buttons to some tact switches?
All this would be wonderful, except none of the online databases have my TV in them. Symphonic TVCR9F1.
[Charles Lohr], here’s a RC64 universal remote. Programming codes for Symphonic TVCR9F1 are 10171, 10180. $19.95, free shipping, 30-day no questions guarantee with no restocking fee here:
http://www.emtcompany.com/symphonic-tvcr9f1-remote/rc64.html
Buy, rip IR signals, publish to online code database(s), return. If you consider that unethical or risky, check thrift stores; being a common DirectTV remote, I’ve seen these in bins of assorted electronic bits for $2-3. Or grab one on Ebay for $5 shipped.
Never heard of a brand called Symphonic before. You do know how to pick them.
Possible to get PAL?
As it is Black and White only, it’s not excatly NTSC, so just change the Picture-Frequency to 50Hz, and its PAL-Compatible.
You would want to have the better/compatible resolution too though
You’d also have to change the line widths and carrier frequency for europe, but it would not be difficult!
If it is so easy for you, please explain because I don’t understand how.
Not to be the Debbie Downer in the comments section, but this is far from new.
The Parallax Propeller was doing this as one of its examples right after it was introduced in 2006. I had it set up to transmit to the TV across my office, and it was color as well.
Now if the gist is that it was done with a relatively underpowered microcontroller I could see where this would be considered news worthy.
It’s more newsworthy to generate broadcast video with a underpowered microcontroller than with hardware that was designed to do that job.
What about with a $2 pro micro instead?
What’s a $2 pro micro ?
Only pro micro I can think of is from sparkfun for 20 bucks. So was that a typo and is it $20?
Actually, I see you can get them for $7 elsewhere.
Anyways, it’s a small arduino.
“The Pro Micro is a great little Arduino-Compatible board. The small form factor makes it perfect for use in projects where space is a concern.
The Pro Micro is similar to the Pro Mini, but uses the ATmega32U4, which allows USB connectivity to be added on-board. The Pro Micro is considered to be the replacement for the Pro Mini, but costs slightly more.”
Check ebay. They are Chinese made, probably knockoffs.
Well there’s a Cypress board with Arm cortex M0 for $4 on Mouser: CY8CKIT-049-42XX
3298 can ship immediately.
My mind was blown when I saw this… trying not to buy it “just because”.
Also there are plenty of STM32F103C8T6 (Cortex M3/64kB/20kB) on eBay for about $4 SHIPPED and they’re compatible with open-source tools (openocd/gcc/gdb). We be livin’ in the future.
I don’t know how you would modulate NTSC on one of them without an external clock reference. Do you know if it has the capability of producing the clocking and output necessary via pwm?
Not sure where you got the idea that the Propeller was designed for broadcast TV, it is just a general purpose microcontroller with 8 cores. The example came about through the experimentation with the advanced timers in each core. Chip Gracey, the designer of the chip, wanted to see how far they could be pushed. He was first able to synthesis the TV signals, including color chroma to output on a standard RCA video plug, then he used another to broadcast the signal.
Also the performance comparison is misleading, the ATTiny85 is a single cycle instruction chip that he overclocked to 30MHz = 30 MIPS. The Propeller is a 4 cycles/instruction chip that is clocked at 80MHz = 20MIPS.
So you could say that the Propeller is the under-powered one. Granted there are 8 cores on the Propeller which is why it is 4x the price of the ATTiny85, but if memory serves correctly only 1 core was used to generate the signalling.
I got the idea from the datasheet, where it says: Each cog has a video generator module that facilitates transmitting video image data at a constant rate. There are two registers and one instruction which provide control and access to the video generator. Counter A of the cog must be running in a PLL mode and is used to generate the timing signal for the Video Generator. The Video Scale Register specifies the number of Counter A PLL (PLLA) clock cycles for each pixel and number of clock cycles before fetching another frame of data provided by the WAITVID instruction which is executed within the cog. The Video Configuration Register establishes the mode the Video Generator should operate, and can generate VGA or composite video (NTSC or PAL)
Fair enough, its been a quite a while since I read the datasheet. But having seen the actual internals of the counters, there is nothing special there. It is essentially a DMA system coupled with a mux to drive the GPIO. But sometimes even simple structures in silicon can vastly improve the software efficiency so you have a valid point.
That sounded interesting, so I googled it. I found this
http://www.gadgetgangster.com/news/45-designer-news/348-kprop.html
Not to be the asshole in the comments section, but it seems in your rush to be negative, you’ve overlooked the fact that this is broadcast NTSC, not composite NTSC.
There are myriad projects for AVRs, Arduinos, Propellers, and nearly any other reasonably competent microcontroller out there that can output composite NTSC. By contrast, the signal transport for this is over-the-air, not via a direct connection by wire.
While the actual signal spec is largely the same between composite NTSC and broadcast NTSC, there are a few important differences. For example, given enough CPU time to sling around, it should be possible to modulate audio onto the signal and have it come through the TV’s speaker. With composite NTSC, you would need a separate RCA connector and a DAC in order to have any sort of audio.
Nice work. Looks like there’s even some dead code that can be removed (void delay_ms).
Would it be possible to use a better mcu to inject video into the signal stream? Im thinking like a scraper that can display data overtop on the video. Imagine a dumb TV turning into a smart TV. You could overlay internet based info like a twitter feed. I dont see why it would need to use the closed captioning system but I believe thats what he would be required to do since the attiny85 has limited memory.
You’d be better of with a device that could generate a HDMI signal, and stick that in your TV, rather than 80’s quality broadcast TV.
You probably didn’t get his point.
To overlay one composite video signal on another, they both have to by synchronised. You can’t have one signal sending the “start horizontal line” pulse, then the other sending it again a moment later. Same with the vertical sync signal, you’d have the TV trying to start a new picture in the middle of the first one. You’d either get rolling and flickering, or more likely just no picture.
Synching two video sources together is called genlocking. A genlocker is traditionally an expensive piece of hardware, but if you’re making both, or at least one, of the signals from scratch, it’s not as hard.
So the mcu would have to sync to the incoming video signal’s timing pulses. Not impossible. But generating graphics in software on an mcu is limited anyway, as well as hard work and a bit unreliable by nature. So there’s probably a better way. Just buying the smart TV, is one. Or using a computer, maybe a Pi, that can generate video, HDMI is better than composite, the resolution is much higher for just one thing. Then to get the TV signal in, maybe a USB TV dongle.
As a little hack with a tiny mcu, though, probably not. Maybe if you were a real video timing / assembly whizz. Like CNLohr is.
Great video. LOVE the T-shirt! Right on, brother!
excellent work i would like to see more projects like this in the future
very nice with tiny85, I like Avr attiny85
I wonder if the remote control problem got solved. An internet search indicates that some people tried codes for FUNAI, Emerson and Sylvannia and got lucky.