Community collaboration is a great thing. Take the Arduino PWM library for shift registers. Some folks at the Arduino forum pitched in and helped [Elco] trim off a bunch of clock cycles by using the Rotate Over Carry instruction. Now he’s reduced the overhead per shift-register from 108 down to just 43. So far this doesn’t mean more possible outputs – 768 is still quite a lot – but does it means better precision when max outputs are used. This effectively doubles the brightness levels for 768 LEDs from 16 up to 32.
We’re at a loss for what to link to here. [Elco] has a new page for the library. There’s the original forums thread but we didn’t see much of interest there. We found some stuff in the comments of this Reddit post. And of course, if you have no idea what we’re talking about go back and read the original feature.
Interrupts are the name of the game for more functional microcontroller firmware. [Rajendra] just posted a tutorial covering all of the interrupt types for the PIC 16F688 microcontroller. He gives an overview of all of the major points: what an interrupt is, what causes interrupts, how to read the datasheet (often overlooked) to set up interrupts, and finally he applies it to a test platform and a bit of code.
We’ve been playing around with an Arduino again over the weekend and are a bit frustrated with the restricted access to interrupts. That issue deals with AVR interrupts, a topic with which we’re already well acquainted. But we work with PIC hardware much less often and it’s fun to explore how the other half does things, both in hardware and in code.
A few years back Atmel announced a new line of chips, the XMega series. We see the name bouncing around here and there, but when [Michael Kleinigger] mentioned that he’s seen very few project using these chips we realized that not only is he right, but we know next to nothing about them. Just give his XMega review post a whirl and you’ll be up to speed in no time.
He compares an XMega128A1 side-by-side with an ATmega1280. For those that abhor reading paragraphs full of words, there’s a table that can give you the quick facts like how the XMega costs less and runs faster. But we know from past discussions (like the one on PWM) that [Mike] knows his stuff so the whole thing’s worth a read. He’ll lead you through the programming tool chain (which hasn’t changed), a bit about the new event system, and then finish with a demo program on the Xplained development board.