Friday, 12 May 2017

PPSS:6 - Another update

Another update on my switching system named PPSS:6. The first prototype was successful but a pain to build so I've redesigned it. Spent a fair amount of time redesigning the PCBs to be more modular. Went away from using the LED driver chip and used only 74hc595 shift register ICs. Made a main board with box style connectors for pre-made leads. Made a Relay/Jack PCB to board mount all the jacks and relays. This allows for much faster and easier assembly. Also made a LED PCB module for the same reason. Also made a faceplate panel and badge. This is all on a 100mm x 100mm PCB from Dirty PCBs (great cheap amazing service)

The PCB panel
Making sure it all fits together
All soldered up and ready to go

It all fits
To avoid the wonky holes that I had last time I used my CNC mill to pilot drill
all the holes in the front panel
Pilot holes nice and straight
More drilling completed and faceplate in place
All the LEDs lined up

3D printed brackets that mount the PCB to one of the switches

This all fits!! Amazingly
Fitting stuff in. The premade leads I have wouldn't take any solder.
I had to crimp connectors on the ends of the leads so I could solder them onto
the switches
All mounted in and it all fits so well.
Pretty much the finished product
All LEDs and relays operational
I had to re-write all the code because of the removal of the LED driver IC and switched to 74hc595 shift register ICs. All the outputs and inputs have changed too. So to test the functionality of all the LEDs and relays I wrote a small bit of code and uploaded it to the Arduino NANO

#include <Shifter.h>
#define SER_Pin 4 //SER_IN
#define RCLK_Pin 6 //L_CLOCK
#define SRCLK_Pin 5 //CLOCK
#define NUM_REGISTERS 3 //how many registers are in the chain
byte x;
//initaize shifter using the Shifter library
Shifter shifter(SER_Pin, RCLK_Pin, SRCLK_Pin, NUM_REGISTERS);
void setup() {
  Serial.begin(9600);  // Used to type in characters
} //Setup Loop
void loop() {
  if (Serial.available()) {
    while (Serial.available() > 0) {
      x = Serial.parseInt();
      shifter.setPin(x, HIGH);
      Serial.print (x);
    if (x == 99) {
} //Main Loop

Basically this bit of code allows me to have the PPSS:6 connected to my PC and I can use the serial plotter to send a number to it. It then takes that number and fires the output on the 74hc595 shift register IC. If I send "99" it turns all the outputs off.

I wrote a similar bit of code to test the inputs. In doing so I found that the two analogue inputs A6 & A7 that I was using as digitals don't work as digitals highlighted in this article. A couple of hack wires later and some code changes and I had all the inputs running.

I have a pretty solid version of the code running but it still needs small changes. Thinking of adding a few extra things to the PPSS:6. I have 2 spare relay outputs so I think I'll use one as an amp switch and the other as a mute switch. I'll make up another PCB with these things mounted on it as well as the input buffer and tuner send jack. Thinking of using switch hold to turn on these features. Press and hold switch 1 for mute press and hold switch 6 for amp switch.

That's pretty much where I'm up to with the project. I have a friend using the first prototype to see if there are any issues or bugs.