Not content with the 12 LEDs of my first Netzlupe I decided to upgrade to 24 LEDs. Most of the display work already had been done so what remained was reworking an existing LED PPM board and the netzlupe board itself. Of course I would want the same nice traffic light colors for the LEDs:
Now this is a very early design. The final version is flipped as LED24 is to the left and the frequency starts at 49.89 Hz. This is the full circuit:
As I found the display still was quite jittery I put a bandpass filter in front of the PIC RB0 input. This worked beautifully so while the accuracy has increased the display is now very smooth.
As said above, the LED display has been reused from the LED PPM design. I had made a PCB for it (not yet online) from which I removed the PIC, the AD8307 and their associated components. The netzlupe board was stripped and the subboard for the filter was added:
The solder pins and jumper are used to insert the 50 Hz test signal generated by my trusty test jig.
The code (asm) is a mash-up of the LED PPM and original Netzlupe programs. After declarations it starts with the RB0 INT interrupt. It then shows the backlight and the previously calculated average value stored in the HEF registers of the PIC. Then the average is recalculated with the new value from TIMER1. The DISPLAY part decodes the average value into the HEF registers for clocking out the next RB0 interrupt.
In the START part the PIC is initialized. The subroutines are last. "Backlight" just switches on all LEDs and then waits a short time. "Show" clocks out the contents of the HEF registers (LED1...24) into the actual chips. Because the layout is fucked up due to the pinout of the HEF4094Bs the LEDs jump back and forth. Then there is the obligatory lamp test which switches each LED on and off. The LTWAIT bit slows down the lamp test to be able to enjoy it some more. The OE line (output enable) for the HEF chips is not really needed because the STROE (strobe) line takes care of it but I used it just in case. Note that during lamp test the backlight is disabled. Nice touch if I may say so myself!
A propos backlight, isn't it just übercool?!?!?
Back to the homepage
Date: 16 January 2023
This software is licensed under the CC-GNU
GPL.