diff --git a/CHANGELOG b/CHANGELOG index 58fc181..2be6e16 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,5 +1,10 @@ CHANGELOG: +PCB Information: + HiFiLOGIX has progressed to a point where the development of a least a prototype PCB is possible. + I am currently playing around with KiCAD and when I'm happy with a design, will send it out to be + made and will begin doing any additional needed development on that board. + Version 0.2.0: Software: diff --git a/README.md b/README.md index ec11660..c764f3e 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,17 @@ Arduino Control for Your Vintage Stereo +# HiFiLOGIX Is Still Active! + +HiFiLOGIX has progressed to the PCB engineering phase. I am currently working on a PCB design as well as some +minor changes to how it works due to the inclusion of the ATMega on the board. During this phase there won't be +any real updates to the software nor will I publish the actual schematic used to create the PCB until I feel it's +ready. The major change is the ATMega328 is now integrated to the board and there is some thought as to dropping +the analog matrix for discreet digital switches. + +Please do not be discouraged by an apparent lack of activity. It's kind of like a space mission; the exciting part +of watching the rocket launch is over...but the mission is far from complete. I hope to have PCBs in my hand by summer. + # History ``` @@ -18,6 +29,7 @@ Arduino Control for Your Vintage Stereo 09-Jan-2020: Version 0.1.8 - Code consolidation. Additional beta version with EEPROM support. Added utilities. 10-Jan-2020: Version 0.1.9 - Moved input name table to program space. 11-Jan-2020: Version 0.2.0 - EEPROM code now out of beta. Writes with hardware interrupt now. +08-Feb-2020: Long-delayed Update ```` @@ -93,6 +105,11 @@ but it's possible I may wind up writing a routine for "self-programming". As of Version 0.1.4 we now support the SSD1306 based 128x32 OLED Display. +Despite the incorrect relays; I decided to build a version on some protoboard as a throwback to the old microcontroller demo +units. It is literally just a board that contains the same relays driving LEDs as the breadboard version; except everything +is soldered together and the ATMega has been liberated from the Uno board and integrated. This ATMega also runs on the internal +8MHz clock. + # EEPROM Usage Version 0.2.0 brought the EEPROM code out of beta. It is now a default feature of the main version. @@ -130,6 +147,7 @@ Please install them via Library Manager or however you install libaries. Check i # Media +[![Protoboard Version](/images/proto2.jpg "Protoboard Version")*Protoboard Version*][/images/proto2full.jpg] ![Picture of prototype rig](/images/prototype.jpg "Prototype")*Prototype & Development Build* More recent prototype build. diff --git a/hifilogix.ino b/hifilogix.ino index c0dd603..880731c 100644 --- a/hifilogix.ino +++ b/hifilogix.ino @@ -42,13 +42,14 @@ const char in4[] PROGMEM = "PHONO-1"; const char in5[] PROGMEM = "PHONO-2"; const char * const inputs[] PROGMEM ={in0,in1,in2,in3,in4,in5}; - -int latchPin = 11; -int clockPin = 9; -int dataPin = 12; -int IRin = 7; -int blanking = 5; -int matrix = A0; +// scl to pin 28 +// sdl pin 27 +int latchPin = 11; // 328 pin 17 - 595 pin 12 +int clockPin = 9; // 15 - pin 11 +int dataPin = 12; // 18 - 14 +int IRin = 7; //13 +int blanking = 5; // 11 +int matrix = A1; // 23 byte eop = 0; byte ex = 0; byte ei = 0; @@ -67,28 +68,42 @@ void DontCrossTheStreams(byte op, byte x, byte i) // There's something u8g2.sendBuffer(); // your body exploding eop = op; ex = x; ei = i; // at the speed of light. // Total protonic reversal. // That's bad. + //lastbreath(); }// Important safety tip, thanks Egon. void eeprominit() { // This checks the EEPROM to see if it's // been initialized by the code before. -if (EEPROM.read(dt) == 'T') { // Check address 1023 for init flag "T" +if (EEPROM.read(dt) == 'F') { // Check address 1023 for init flag "T" return; } else { EEPROM.write(db, 16); EEPROM.write(dx, 32); EEPROM.write(di, 2); - EEPROM.write(dt, 'T'); + EEPROM.write(dt, 'F'); } } void lastbreath() { // The idea here is to throw a large capacitor on to the voltage rail - EEPROM.update(db, eop); // powering the Arduino; but keep it from powering anything else. - EEPROM.update(dx, ex); // Monitor the "other" 5V rail with pin 2 and trigger an interrupt - EEPROM.update(di, ei); // and rely on the caps charge to keep charge long enough to write. + EEPROM.write(db, eop); // powering the Arduino; but keep it from powering anything else. + EEPROM.write(dx, ex); // Monitor the "other" 5V rail with pin 2 and trigger an interrupt + EEPROM.write(di, ei); // and rely on the caps charge to keep charge long enough to write. } +void annoyingtrick() { + u8g2.clearBuffer(); // it stopping instaneously + u8g2.drawStr(22,30,"RAVE"); // and every molecule in + u8g2.sendBuffer(); + for (int b = 0; b <=20000; b++){ + byte trick = 0; + trick = random(1,127); + digitalWrite(latchPin, LOW); // It would be bad. + shiftOut(dataPin, clockPin, LSBFIRST, trick); // What do you mean, bad? + digitalWrite(latchPin, HIGH); + delay(25);} + DontCrossTheStreams(16,32,2); +} void setup() { pinMode(latchPin, OUTPUT); @@ -107,6 +122,8 @@ void setup() DontCrossTheStreams(EEPROM.read(db),EEPROM.read(dx),EEPROM.read(di)); // Read settings stored in EEPROM. digitalWrite(blanking,HIGH); // Now drives a logic inverter. attachInterrupt (digitalPinToInterrupt(2), lastbreath, FALLING); // Write the values before your cap discharges! + attachInterrupt (digitalPinToInterrupt(2), lastbreath, CHANGE); // Write the values before your cap discharges! + attachInterrupt (digitalPinToInterrupt(2), lastbreath, LOW); } void loop() @@ -117,12 +134,13 @@ if (remote.decode(&ircode)) { icode = ircode.value; remote.resume(); } -// I don't know if it improves things, but I sure like how much smaller this section is. -if ((mx > 100 && mx < 200) || (icode == 0x97)) DontCrossTheStreams(64,10,0); // The code I originally used to figure out my -if ((mx > 500 && mx < 600) || (icode == 0x67)) DontCrossTheStreams(32,10,1); // remote codes returned 3 bytes in hex. I can't -if ((mx > 900 && mx < 950) || (icode == 0x4F)) DontCrossTheStreams(16,32,2); // remember what that code was, but I only need -if ((mx > 1000) || (icode == 0xCF)) DontCrossTheStreams(8,18,3); // the last bit with the remote I'm using. -if ((mx > 820 && mx < 899) || (icode == 0xE7)) DontCrossTheStreams(6,1,4); // I'm working on making the bare-bones utility I -if ((mx > 700 && mx < 800) || (icode == 0x85)) DontCrossTheStreams(5,1,5); // wrote a bit more user-friendly. +// I don't know if it improves things, but I sure like how much smaller this section is. +if ((mx > 850 && mx < 860) || (icode == 0x97)) DontCrossTheStreams(64,10,0); // The code I originally used to figure out my +if ((mx > 2 && mx < 5) || (icode == 0x67)) DontCrossTheStreams(32,10,1); // remote codes returned 3 bytes in hex. I can't +if ((mx > 45 && mx < 50) || (icode == 0x4F)) DontCrossTheStreams(16,32,2); // remember what that code was, but I only need +if ((mx > 950 && mx < 970) || (icode == 0xCF)) DontCrossTheStreams(8,18,3); // the last bit with the remote I'm using. +if ((mx > 22 && mx < 30) || (icode == 0xE7)) DontCrossTheStreams(6,1,4); // I'm working on making the bare-bones utility I +if ((mx > 990 && mx < 1010) || (icode == 0x85)) DontCrossTheStreams(5,1,5); // wrote a bit more user-friendly. +if (icode == 0xAD) annoyingtrick(); delay(200); -} \ No newline at end of file +} diff --git a/images/proto2.jpg b/images/proto2.jpg new file mode 100644 index 0000000..b480d61 Binary files /dev/null and b/images/proto2.jpg differ diff --git a/images/proto2full.jpg b/images/proto2full.jpg new file mode 100644 index 0000000..0f79144 Binary files /dev/null and b/images/proto2full.jpg differ