Monthly Archives: April 2012

CommandCam now published under the GPL

The title pretty much says it all. Following some requests from users, my command line webcam image grabber, CommandCam, is now published under the GNU General Public License version 3. Is it just me or is software licensing very confusing?!

Posted in Uncategorized | Leave a comment

How a console application can set the size of its window

This is an example of a Win32 console application that sets the size of the window it’s running in. When you run it, it sets the size of the console window to 640 x 400 pixels. It actually seems to … Continue reading

Posted in Uncategorized | Tagged , , , , , , , , | 2 Comments

Simulating a keystroke in Win32 (C or C++) using SendInput

This program is a simple example of using the Win32 SendInput function to generate a simulated keystroke. When you run this program, it simply waits 5 seconds and then simulates a press and release of the “A” key on the … Continue reading

Posted in Uncategorized | Tagged , , , , , , | 83 Comments

Simple Timer 1 interrupt example for the dsPIC30F4011

This is a minimal example of a Timer 1 interrupt in a dsPIC30F4011 program. I compiled it with Microchip’s C30 compiler. The main loop of the program simply flashes an LED on RD0 (pin23) at approximately 2 Hz. Meanwhile, Timer 1 … Continue reading

Posted in Uncategorized | 14 Comments

Stepper motion control from signals on SD card (co-author: Mark Flanagan)

Note: This post is co-authored by Mark Flanagan. Mark is blogging about his final-year project here and has also posted a really interesting account of his preliminary investigative work here. Mark’s project concerns the development of a fascinating robotic simulator … Continue reading

Posted in PIC, Uncategorized | Tagged , , , , , , , , | Leave a comment

procoach code sketch

Posted in Uncategorized | Leave a comment

PWM output on 2 channels of the dsPIC30F4011 with equal duty cycle and 180 degrees out of phase

Reader Mo Hsen wrote in with an interesting query about generating PWM output from the dsPIC30F4011 on two channels with equal duty cycle but 180 degrees out of phase (see the waveforms below for an example). I’ve created a short … Continue reading

Posted in Uncategorized | Tagged , , , , , , , , , , , , , , , | 50 Comments