Now, Dear Reader; that was the sound of a single, solitary penny dropping.

That was the sound (…in my head of course.  Where most of the voices come from these days…) I heard as I realised that I hadn’t set the PIC up properly!

Before you start any fun stuff with a PIC microcontroller, you have to set it up so it knows which pins are mean’t to be doing what.

In this case, because I hadn’t read the manual properly, I’d forgotten all about the two comparator circuits built into these things.  Before you use the standard input/output (I/O) pins, you first have to turn off the comparators, and tell the chip that you’ll be using digital I/O’s.

Then, just to be on the safe side, you should always clear the pins.  -Reset them to zero.  Its good practise, and only takes a couple of instructions.

D’ Oh!

So, my prophecies this morning were right.  A little Plot Work really is good for the body and soul.

Tomorrow, I’m hoping to get a full day at this (…after Blogging some photos on the main Blog of today’s efforts…), so I’ll be sure to tell you all about it tomorrow evening.

p.s. Oh, and on my way out this morning, I happened to meet the postman.  I asked if he had anything for me, and yes, he had!  Two of your finest PIC16F684 microcontrollers, so that now gives me four in total.  Fun!