Pulse Width Modulation is a topic that tends to give a lot of beginners trouble. [Daqq], whose nixie plasma ball we covered a few days ago, has a simple but effective PWM project that you should take a look at. The circuit used 9 LEDs clustered together into 3 sets of RGB modules and connected them to an AVR ATtiny2313 through some current limiting resistors. Most of the time the PWM function of the AVR’s timers would be used to generate the signal but this application calls for 9 signals which is more than can be produced by this chip. The workaround is to generate the signals using software PWM. Continue reading “Software Pulse Width Modulation”
pwm142 Articles
AVR Boost Converter
Over at SpriteMods, [sprite_tm] realized that a microcontroller could be used as a boost converter to power itself. A boost converter steps up voltage from a battery by switching the output of a coil. First, it is tied to ground so a magnetic field can build up in the coil. It is then released as a higher voltage than the input. Normally dedicated chips do this at an incredibly high frequency, but the PWM signal from an AVR works well enough. This can be used in low-power situations where space is an issue.
[via EMSL]
Motors And Microcontrollers 101
[youtube=http://www.youtube.com/watch?v=WnWJki-zwsE]
[Humberto] from NerdKits sends in the newest addition to their excellent collection of videos. This video goes over the basics of DC motor control with microcontrollers. They begin by showing nine experiments and observations that can be done by the average hacker with a multimeter, motor, LED, and jumperwire. Using the results from these they show how to model and calculate the properties of a motor. Lastly, it shows how to control a motor using PWM. They have supplemental text and demonstration code for an ATmega168 on their website.
RGBike POV
[Hazard] wanted a full color POV display for his bike wheel. Adafruit’s SpokePOV is single color and Monkeylectric’s original version didn’t display images. He also balked at the cost and decided to manufacture his own version. It uses 16 RGB LEDs on a single layer board he manufactured himself. It’s an entirely through-hole design to make assembly easy. It uses a hall effect sensor to synchronize the image display. The two main components are an ATmega328p microcontroller, which should make it Arduino compatible, and a TLC5940 PWM LED driver. It’s a very well documented build and certainly a good looking effect.
[via adafruit]
USB Servo Squirter
Here is a great project for learning how to control servos. They’ve made a USB controlled squirt gun using the USB NerdKit, a pump and a servo. This is a great tutorial to learn about PWM and controlling servos. The tutorial is very thorough, with great pictures and a video of it all , which you can see after the break.
Simple Servo Bot Plans
oomlout has posted some interesting plans for a simple robot. It’s based around an Arduino and is a platform similar to the Parallax Boe-Bot. The Arduino sends PWM signals to continuos rotation servos that drive the two main wheels. All of the structural components are laser cut from acrylic with slots to hold standard hex nuts. It’s an interesting technique, but the design has a lot of potential for improvement. Right now it uses two different power supplies and a breadboard for simple connections. From the video below, you can see that the balance could be improved as well. Continue reading “Simple Servo Bot Plans”
Simple PWM
We mentioned Pulse Width Modulation (PWM) when talking about [sprite_tm]’s marquee control. It’s a method of power control. While [sprite_tm] did it in software, [Afroman] sent along a very straight forward introduction to PWM using just a 555. Check out his video for coverage of this fundamental electrical design technique.