PIC Programming & Design


The source code is provided for each project. The code is for EDUCATIONAL purposes ONLY. There is no warranty and no support. All these projects are a result of my hobby, so I don't necessarily know what I'm doing! Also note that all code available here carries the MIT License.
avr

VE3LNY's PIC projects

I was introduced to the world of PIC microcontroller programming by AmQRP, the American QRP Club. They had an inexpensive project board called the PIC-EL, or PIC Elmer (photo left). They also provide an excellent PIC programming tutorial. I had a lot of fun doing the tutorial, then developed a few projects of my own. (Latest: the Pic-EL III).

By the way, PICs are manufactured by Microchip Technology Inc. Analog Devices in a vast number of models from tiny and simple to huge and complex. The one used in my PIC-EL is a PIC16F84A, available from Digi-Key for around $8.70 Canadian. It has 1024 words of program memory, 68 bytes of data RAM, 64 bytes of EEPROM, and 13 I/O pins that can be used for various purposes. (The latest PIC-EL uses a PIC16F628.)

Apologies for all the obsolete links, it's impossible to keep up with the changes in the industry.


PIC Programmers

When I started working with PICs, I used the PIC-EL to program the PIC16F84A. When I wanted to try other PICs, I soon learned that the PIC-EL would not program them, and I looked around for a programmer. I decided to try a DIY Electronics Kitsrus kit #128. To make a long story short, I had many hassles with this kit and do not recommend it.
pickit2
Next I purchased an inexpensive in-circuit programmer from Microchip, the PICkit 2, which solved my problems for a while. The PICkit 2 Starter Kit is was available from DigiKey for around C$34.

UPDATE 2013-02 My "old" Pickit2 no longer works with the current software and Windows 7. I get the
"unrecognized device" USB error, even though the device is present in device manager. Microchip suggests I open the unit up and solder in a resistor, see this link. I don't really want to do this (and I doubt it will work) so this may be the end of my development with PICs.

To make a long story short, PICKIT2 only works on 32-bit Windows. Not recognized error on 64-bit systems.

Update 2014-09 the Pickit2 is no longer be available, and has been replaced by the Pickit3.



Thermometer

Thermometer

A thermometer interfaced to either an LED or LCD display, using a PIC16F684.
sourceboost logo

SourceBoost C Compiler

Just a word on the source code. Like everyone else I started out programming PICs in assembler. Since I had learned other assembler languages in the past, this was not a problem for me, and I was doing fine for smaller programs. When I tackled a larger program, the tedium of the language plus the peculiarities of the PIC processor (multiple code pages and data banks) drove me crazy to look for a C compiler. I decided on the  SourceBoost BoostC compiler (I have no association with the company), because of its features and friendly pricing policy for hobbyists. The following projects are all programmed with this compiler.

hi-tech logo

HI-Tech C Compiler

HI-Tech had a nice free lite version which is no longer available.

cc5x logo

CC5X C Compiler

Another PIC C Compiler with a limited-function free version.

counter

Frequency Counter

An audio frequency counter using a PIC16F684 and either an LED or LCD display.
Humidity meter

Humidity Meter

PIC16F684 Based Humidity Meter with LED readout.
Ham Radio Clock

Ham Radio Clock

A dual time zone PIC16F685 LCD clock.
Cable Tester

Cable Tester

PIC16F877A 8 conductor cable tester.
Line Monitor

PC Power Monitor

Monitors the power line and shuts down your computer when the power fails.



Back to VE3LNY's Home Page