|
|
|
@ -1,7 +1,7 @@
|
|
|
|
|
/*
|
|
|
|
|
HiFiLOGIX 0.2.0
|
|
|
|
|
HiFiLOGIX 0.2.0 (Fix 1)
|
|
|
|
|
|
|
|
|
|
dewdude@gmail.com - 09-JAN-2019
|
|
|
|
|
dewdude@gmail.com - 12-JAN-2019
|
|
|
|
|
|
|
|
|
|
!!! IMPORTANT NOTICE !!!
|
|
|
|
|
|
|
|
|
@ -17,7 +17,7 @@
|
|
|
|
|
Pin 2 is used for the hardware interrupt trigger that writes the data. It's
|
|
|
|
|
set to run fall. This will be done in hardware by isolating a capacitor for
|
|
|
|
|
the Arduino and tying pin 2 to the part of the power supply that will drop
|
|
|
|
|
first. The reserve current should last long enough to update the falues before
|
|
|
|
|
first. The reserve current should last long enough to update the values before
|
|
|
|
|
draining.
|
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
@ -57,7 +57,7 @@ decode_results ircode;
|
|
|
|
|
char txt[8];
|
|
|
|
|
|
|
|
|
|
void DontCrossTheStreams(byte op, byte x, byte i) // There's something very important I forgot to tell you.
|
|
|
|
|
{ // Don't cross the streams.
|
|
|
|
|
{ // Don't cross the streams.
|
|
|
|
|
strcpy_P(txt, (char*)pgm_read_word(&(inputs[i]))); // Why?
|
|
|
|
|
digitalWrite(latchPin, LOW); // It would be bad.
|
|
|
|
|
shiftOut(dataPin, clockPin, LSBFIRST, op); // What do you mean, bad?
|
|
|
|
@ -83,10 +83,10 @@ if (EEPROM.read(dt) == 'T') { // Check address 102
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void lastbreath() { // The idea here is to throw a large capacitor on to the voltage rail
|
|
|
|
|
EEPROM.write(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.
|
|
|
|
|
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.
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void setup()
|
|
|
|
|