[chbot] Engineers assistant 'screen shots'

Chris Hellyar chris at trash.co.nz
Sun Mar 2 11:26:09 GMT 2008


Due to an overwhelming request for screenshots from the wee gadget..
(Overwhelming = 2 :-) ).

One long email follows:

The 'setup' shot:
http://cpix.co.nz/myio/ea1.jpg

Bottom LCD is a serial LCD I use for testing/debugging, plugged into the
top right board which is updating the text on the single line LCD every
second.  The serial demo data came from that board.

The 'Engineers Assistant' is The two line LCD in the middle, with the
opening screen for the serial mode, I changed the text to 'Serial
Snoop', cause I can. :-).  The two buttons are mode/submode and start
capture (Depending on mode etc).  All three LED's are lit there as the
logic probe function works in all modes apart from frequency counter.

Top left is my test board for the gcbasic/bootloader setup (Which is
working really well) which I used to create the test signals for the
'logic analyser' and frequency counter bits.  (more on that later)

Frequency counter mode:
http://cpix.co.nz/myio/ea2.jpg
The input is hung across one pin on the PIC on my boot loader board
which is running this magnificent program:
<Code snippet>
#chip 16F876A, 20
#option bootloader
#define LED PORTC.5
Start:
        set LED on
        set LED off
        goto Start
</Code snippet>
Doing some empirical testing against known accurate stuff it's pretty
close, but my actual frequency counter is on the fritz after an
encounter with back emf off a large DC servo, so I can't vouch for it.

I used a 10Mhz crystal (not a resonator) for the PIC so the timebase for
the PIC is pretty close at least.

FYI, top range is 40Mhz with 32hz resolution, the other steps are in the
PDF.

You can tell this is a 'junk box' LCD, look at the state of that
thing....

'Logic Analyser' mode:
http://cpix.co.nz/myio/ea3.jpg
Now, I know that a logic analyser with one input seems to be really
pointless, and well, it is.  But I'm sure this will come in handy at
some stage.

This would be quite handy for analysing dallas one-wire interface timing
I suppose. :-).

The code was:
<Code snippet>
#chip 16F876A, 20
#option bootloader
#define LED PORTC.5
Start:
        set LED on
        set LED off
        wait 1 ms
        set LED on
        wait 3 ms
        set LED off
        wait 5 ms
        set LED on
        wait 5 ms
        set LED off
        wait 2 ms
        set LED on
        wait 1 ms
        set LED off
        wait 4 ms
        set LED on
        wait 2 ms
        set LED off
        wait 6 ms
        set LED on
        wait 2 ms
        set LED off
        wait 1 s
        goto Start
</Code snippet>

It takes 301 samples (you could extend that in the PIC16F628, but can't
be bothered..) at up to 1Mhz/1us resolution.  It shows 60 samples per
'page', and you can page through the data. Some of the
frequency/resolution steps are odd, and would do your head in trying to
work out timing on the fly.

The bottom line in this case shows the resolution, and that I was
starting on a rising edge, and it's page 1 of the data.
("..|" = rising edge, "|.." = falling edge)

This is really clever use of a limited UI IMHO, but if you want a logic
analyser there are much better cheap options, which will do 8+ channels,
much more useful!

Serial Snoop mode:
http://cpix.co.nz/myio/ea4.jpg

The bottom LCD is the output from the serial line I monitored, the
output shows the hex data along the top line and the first 7 characters
of the bottom line are the ASCII characters, reflecting the lower
screen. 2.4 is the baudrate, R8 means inverted (reverse) 8bit's no
parity, * is the start 'button' and this is the first page of the data.

I don't think I'll get all excited and stick this wee thing in a fancy
plastic case, but it's a handy-dandy little gadget.

If nothing else, it is a pretty good high/low/pulsing logic probe, which
is an essential tool for digital work...  My existing logic probe misses
short pulses, this goes down to 10ns (the spec for the timer input on
the PIC).

Given that I had to buy no components to make it, it's certainly the
best value test equipment on my bench now anyway you look at it!

Cheers, Me.




More information about the Chchrobotics mailing list