VGA Without A Microcontroller

One of the most challenging projects you could ever do with an 8-bit microcontroller is generating VGA signals. Sending pixels to a screen requires a lot of bandwidth, and despite thousands of hackers working for decades, generating VGA on an 8-bit microcontroller is rarely as good as a low-end video card from twenty years ago.

Instead of futzing around with microcontrollers, [Marcel] had a better idea: why not skip the microcontroller entirely? He’s generating VGA frames from standard logic chips and big ‘ol EEPROMs. It works, and it looks good, too.

VGA signals are just lines and frames, with RGB pixel values stuffed in between horizontal sync pulses, and frames stuffed between vertical sync pulses. If you already know what you want to display, all you have to do is pump the right bits out through a VGA connector fast enough. [Marcel] is doing this by saving images on two parallel EEPROMs, sending the output through a buffer, through a simple resistor DAC, and out through a VGA connector. The timing is handled by a few 74-series four-bit counters, and the clock is a standard 25.175 MHz crystal.

There’s not much to this build, and the entire circuit was assembled on a breadboard. Still, with the clever application of Python to generate the contents of the ROM, [Marcel] was able to build something that displays eight separate images without using a microcontroller.


Microchip Launches New Family Of PICs

Over the last few years, we’ve seen projects and products slowly move from 8-bit microcontrollers to more powerful ARM microcontrollers. The reason for this is simple — if you want to do more stuff, like an Internet-connected toaster, you need more bits, more Flash, and more processing power. This doesn’t mean 8-bit microcontrollers are dead, though. Eight bit micros are still going strong, and this week Microchip announced their latest family of 8-bit microcontrollers.

The PIC16F15386 family of microcontrollers is Microchip’s latest addition to their portfolio of 8-bit chips. This family of microcontrollers is Microchip’s ‘everything and the kitchen sink’ 8-bit offering. Other families of PICs have included features such as a complementary waveform generator, numerically controlled oscillator, a configurable logic controller, power saving functionality and the extreme low power features, but never before in one piece of silicon.

This feature-packed 8-bit includes a few new tricks not seen before in previous Microchip offerings. Of note are power management features (IDLE and DOZE modes), and a Device Information Area on the chip that contains factory-calibrated data (ADC voltage calibration and a fixed voltage reference) and an ID unique to each individual chip.

As you would expect from a new family of PICs, the 16F15386 is compatible with the MPLAB Xpress IDE and the MPLAB Code Configurator, a graphical programming environment. The products in the family range from 8-pin packages (including DIP!) with 3.5kB of program Flash to 48-pin QFPs with 28kB of program Flash. The goal for Microchip is to provide a wide offering, allowing designers to expand their builds without having to change microcontroller families.

All of these chips can be sampled now, although the lower pin count devices won’t be available through normal means until next month.

Does This Demo Remind You of Mario Kart? It Should!

Here’s a slick-looking VGA demo written in assembly by [Yianni Kostaris]; it’s VGA output from an otherwise stock ATmega2560 at 16MHz with no external chips involved. If you’re getting some Super Mario Kart vibes from how it looks, there’s a good reason for that. The demo implements a form of the Super Nintendo’s Mode 7 graphics, which allowed for a background to be efficiently texture-mapped, rotated, and scaled for a 3D effect. It was used in racing games (such as Super Mario Kart) but also in many others. A video of the demo is embedded below.

[Yianni] posted the original demo a year earlier, but just recently added detailed technical information on how it was all accomplished. The AVR outputs VGA signals directly, resulting in 100×120 resolution with 256 colors, zipping along at 60 fps. The AVR itself is not modified or overclocked in any way — it runs at an entirely normal 16MHz and spends 93% of its time handling interrupts. Despite sharing details for how this is done, [Yianni] hasn’t released any code, but told us this demo is an offshoot from another project that is still in progress. It’s worth staying tuned because it’s clear [Yianni] knows his stuff.

Continue reading “Does This Demo Remind You of Mario Kart? It Should!”

Programming the Open-V Open Source CPU on the Web

openriscv_webYou can now program the Open-V on the web, and see the results in real time. The code is compiled in the web IDE and then flashed to a microcontroller which is connected to a live YouTube live stream. It’s pretty neat to flash firmware on a microcontroller thousands of miles away and see the development board blink in response.

We’ve covered the Open-V before, and the crowd funding campaign they have going. The Open-V is an open hardware implementation of the RISC-V standard. And is designed to offer Cortex M0-class capabilities.

This feels like a create way to play around with some real hardware and get a taste of what a future where we can expect Arduino-like boards, open source down to the transistor level.

For a closer look at why open silicon matters, check out [Brian Benchoff’s] hands-on review of the HiFive, an Arduino form-factor board built around an open hardware RISC-V microcontroller.

Cornell Students Have Your Back

Back problems are some of the most common injuries among office workers and other jobs of a white-collar nature. These are injuries that develop over a long period of time and are often caused by poor posture or bad ergonomics. Some of the electrical engineering students at Cornell recognized this problem and used their senior design project to address this issue. [Rohit Jha], [Amanda Pustis], and [Erissa Irani] designed and built a posture correcting device that alerts the wearer whenever their spine isn’t in the ideal position.

The device fits into a tight-fitting shirt. The sensor itself is a flex sensor from Sparkfun which can detect deflections. This data is then read by a PIC32 microcontroller. Feedback for the wearer is done by a vibration motor and a TFT display with a push button. Of course, they didn’t just wire everything up and call it a day; there was a lot of biology research that went into this. The students worked to determine the most ideal posture for a typical person, the best place to put the sensor, and the best type of feedback to send out for a comfortable user experience.

We’re always excited to see the senior design projects from university students. They often push the boundaries of conventional thinking, and that’s exactly the skill that next generation of engineers will need. Be sure to check out the video of the project below, and if you want to see more of this semester’s other projects, we have you covered there tooContinue reading “Cornell Students Have Your Back”

Tiny Tunes On An ATtiny13

When you take a microcontroller class in university, one of the early labs they have you drudge through on your way to, promised, mastery over all things embedded, is a tiny music generator.

It’s a more challenging lab than one would expect. It takes understanding the clock of the microcontroller and its sometimes temperamental nature. It takes a clear mental picture of interrupts, and is likely one of the first experiences a burgeoning designer will have worrying about the execution time of one of their loops. Also tables, data structures, and more. It even requires them to go out of their comfort zone a learn about an unrelated field, a challenge often faced in practicing engineering.

Luckily [Łukasz Podkalicki] has done a great job of documenting the adventure. He’s got everything from the schematic and code to the PWM traces on the oscilloscope.

It’s also worth mentioning that he’s got a few other really nice tutorials for the ATtiny13 microcontroller on his blog. A tiny party light generator and a IR receiver among them.

Only One Button? No Problem!

Sometimes less is more. This is especially true when dealing with microcontrollers with limited I/O pins. Even if you have lots of I/O, sometimes you are need to pack a lot into a little space. [Hugatry] was inspired by the simple interface found on a lot of flashlights: one button. Push it and it turns on. Push it again, and it switches modes. You cycle through the modes until you finally turn it back off. One button provides mutliple functions. The question is how can you use a power switch as an I/O device? After all, when you turn the power off, the microprocessor stops operating, right?

[Hugatry’s] answer is quite simple. He connects a resistor/capacitor network to an I/O pin (or multiple pins). When the processor turns on initially, the pin will read low and the capacitor will charge up. If you turn the power off, the CPU voltage will fall rapidly to zero, but the voltage on the capacitor will discharge slower. If you wait long enough and turn the power on, there’s no difference from that first power on event. But if you turn the power on quickly, the capacitor voltage will still be high enough to read as a logic one.

What that means is that the processor as part of its start up can detect that it was recently turned off and take some action. If it remembers the previous state in nonvolatile memory, you can have the code cycle through multiple states, just like a flashlight. You can see a video of the setup, below.

Continue reading “Only One Button? No Problem!”