[Robotgroup] DaVinci code and it's inspiration

Paul Atkinson pmatkinson at gmail.com
Thu Dec 13 14:40:54 PST 2007


The code I used for the da Vinci awards is based on the work of Pete
Griffiths.
I made a few minor changes to the code, primarily to have the slow fade
across
Red, Green, and Blue be the default after power-up. I also simplified the
hardware
to drive a single RGB LED and eliminated some transistors and a mode switch.

The short time frame for making the award encouraged a simple hardware
design.
This worked out fine until we had our first case of feature creep.
Originally the
awards were going to run a single fade pattern, but someone hacked them to
include the afore-mentioned mode switch.

The mode switch (push button) does several things. If pressed for ~0.5
seconds
or less, it will increment to the next mode. If pressed for ~1.5 seconds it
will put
the PIC in low power mode, essentially off, but not quite. (The slide switch
dis-
connects the battery = really off.) If in low power mode, pressing the push
button
for ~2 seconds will turn it back on. Turning it on with the slide switch
will return
to the mode that was programmed initially or to the mode that existed before
low
power mode was entered.

The original PIC code can be down-loaded here:
http://picprojects.org.uk/projects/rgb/index.htm#Code%20Download

Paul


More information about the Robotgroup mailing list