You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

209 lines
8.5 KiB
Plaintext

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:
EEPROM Support out of beta. Added hardware interrupt routine for it.
Using the EEPROM is now the default action for the software, meaning the beta version
has gone away. This sketch absolutely makes use of the EEPROM as part of it's boot
routine. It will overwrite data on first boot and loads the "default" input every
boot. The update is done via an interrupt. More on that will be explained later as
it will require some power-supply hacking I'll have to design.
Version 0.1.9:
Software:
PROGMEM now stores the input name table.
I moved the input table to program space. This saves some ram I might need later.
EEPROM Code Commented Out In Non-Beta
The EEPROM beta code now exists in the non-beta; but it comes commented out. This
is done for the lazy people that don't like/want/know-how to edit code.
Hardware:
Power-On Reset circuit on 595 removed.
The POR circuit originally held the shift-register reset low long for a brief second
to clear the random start-up state. This was because the old method of controlling the
outputs on the chip resulted in the outputs turning on during the ATMega's initalization.
(They go from high-impedance to low before the code takes over.) But with the new blanking
circuit that's not a problem; it keeps both the 2003 and 595's outputs off untill it goes
logic high in the software. The three components from the POR are now gone, the pull-up on
the 595's enable line changed to a 1k, and the transistor and additional resistor added for
the switch/inverter. It basically reduces overall count by just one component; but it makes
the thing behave better than I expected.
I'm sure in a lot of situtations this is a bad idea; but since the 595 doesn't seem to care
if it has the reset circuit and the rest of our circuit doesn't care what or if the 595 boots
in a scrambled state...why have it? Since we clock data in to it before pulling blanking high
it won't output incorrect data.
Version 0.1.8:
Software:
No longer clear the shift register.
Originally I did this to make sure the register was cleared...because I honestly wasn't 100% sure what was
going on. I looked at some examples...did some things...and got excited when it worked. In complete total
hindsight....I actually didn't need to do this. Originally I did it "just to be sure" it got cleared...and
for a while since I wasn't exactly sure what the shift-register functions fully did; I just left it. The
change I made in 0.1.6 of adding arguments to DontCrossTheStreams seemed to make a lot of things fall in to
place...and it turns out that when I finally got to the point of deciding to try adding EEPROM support..that
change made the entire thing easier to implement. 0.1.7 practically rewrote the whole loop, which lead to me
doing it to the rest of the code.
Three functions removed.
clearShiftRegister was removed to already mentioned redundancy. updateShiftRegister had it's few lines of
code moved to DontCrossTheStreams. logo() had it's code moved from it's own function to just directly into
the setup function. With this change, DontCrossTheStreams has morphed from it's original function of just
setting the shift register to all 0, in to being the entire process of changing inputs. Though I did figure
out that functions really didn't add much bloat. Between 0.1.7 and 0.1.8 I only shaved 22 bytes off the
original compile size.
I have no clue what it takes to optimize C. I barely know it.
srEnable renamed to blanking.
This better represents what it does. While this is probably more notoriously known in regards to CRT
operation; I'm a pinball guy by trade and the term is used quite a bit on the solid-state/digital
machines.
EEPROM Beta:
Remember how I said someday the default boot wouldn't be static? Well, I've done it. This beta version uses
3 bytes of EEPROM space to store the last used input as well as one additional byte to indicate if default
information exists and to load if it it does, or write it if it doesn't. It currently uses bytes 1020 - 1023,
the end of the EEROM on my ATMega 328. 1020 stores the byte for the shift register, 1021 stores the x offset
for the display, 1022 stores the index pointer to the name, and 1023 stores a "T" if it's written settings.
Right now, it will update those addresses on each input change; and read those settings on boot to pass to
DontTouchTheStreams.
While I toyed around with the idea of something like FRAM to avoid the lifetime limitations and just write
each source change; I've decided I'm going to give the Arduino a lot of capacitance on it's power supply,
attach a sense circuit to the main power supply, and just write those values when it detects a power-off.
The code only updates if necessary; so if you power it off on the same input it was powered-up at, it won't
write. In theory...if you write to this thing twice a day it will take close to 100 years to hit the write
limit.
But I haven't implemented that in hardware...though I have some ideas. Until I do this is considered a beta
version that won't burn the EEPROM out like writing to it in loop; but still does so every single input
change.
It is written off the 0.1.8 code.
Hardware:
No changes; but eliminating the reset circuit on the dev prototype has caused zero ill effects with the blanking.
Version 0.1.7:
Main:
Decided to try and comment changes better.
This at least gives a minor insight in to why I did it. I'll mark comments added later with an asterisk.
Software:
Practically rewrote the main loop.
Instead of all the switch/case bullshit, I just dump to a variable and make that part of the
conditional IF statements.
Bitmapped the logo.
Fonts are large. The 98x24 bitmap was smaller.
Version 0.1.6:
Software:
Removed a bunch of functions in favor of passing arguments to function.
The indvidual functions for setting each input and setting the LCD have largely been combined
in to one since I figured out how to use arguments. Additional stuff changed/added to accomodate
this.*
Version 0.1.5:
Hardware
Removed 2003 ground from 595 enable line. (That was a stupid idea that thankfully didn't blow up.)
I calculated the relays to be 40mA each. Sinking that much current from an IO pin is pushing it, let alone
the fact I need two relays for phono inputs.
Added logic invterter to drive the 595 enable and 2003 ground. (Transistor can sink more current).
The 2N2222 is rated for like...800mA or something; wayyyy more than I need. In retrospect, this would have been
a better solution overall than the reset circuit on the 595. Will I change it? I'll have to play with it.
Software:
Flipped srEnable logic to drive logic inveter added to board.
Version 0.1.4:
Main:
Project is now called HiFiLOGIX
Hardware:
Tied ULN2003/2803 ground to 595's enable line
Even with the shift register quiet during boot, the darlington array isn't; and pull-down
resistors don't seem to help. But I soon realize this is a stupid idea.
Replaced 1602 display with SSD1306 128x32 OLED
Software:
Added code to drive OLED display.
Removed 1602 display code.
Version 0.1.3:
Hardware:
Added power-on reset RC circuit to control 595 master reset.
Removed 595 master reset from Arduino control.
Software:
Removed 595 master reset commands.
Version 0.1.2:
Hardware:
Wired 595 output enable and reset to Arduino control.
Software:
Added output and reset commands for 595.
Version 0.1.1:
Hardware:
Added KY-022 IR module (1838 IR sensor with integrated resistor+led)
Software:
Added basic support for IR remote control.
Version 0.1
Hardware:
Added I2C 16x2 LCD Display
Software:
Added support for display.
Version Alpha2.1
Software:
Created routine to shift all 0s to 595.
Added two-relay switching for Phono-1
Added Phono-2 routine.
Version Alpha2
Software:
Fixed shift register bug from Alpha1.
Removed serial monitor debugging.
Cleaned up main loop if statement.
Version Alpha1
Hardware:
Initial build. Just switches and LEDs on a 595.
Software:
Initial offical release. Totally broken.