It is still beta-code, but the keypad is now able to remember your favorite frequencies rather than offer you my factory programmed presets.
The ATtiny2313 has 2kB of program memory, 128bytes of RAM for program volatile variables and 128bytes of EEPROM for long term variables.
In the latter memory space, a program can write data that will survive power off of the microcontroller. This means the program can read something and store it for future use.
In the keypad application, the beta code allows to read the currently selected VFO frequency/mode and write it to a long-term memory area. Then with two keystrokes you can QSY back there. Even days or months after the keypad has not been in use.
Freq/mode information take 5 bytes, so we could store up to 128/5 = 25 memories. Since key combinations are limited and managing them "costs" code memory, I will probably implement these sequences:
- # followed by * followed by any other key assigns current freq/mode to that key
- # followed by any key recalls the assigned freq/mode, except for "#*"
So 15 custom memories will be available. Please note that only frequency and mode will be stored, nothing more. Not even the narrow filter setting.
One thing I noticed. In the BCB band (88-108 MHz) where WFM is the only allowed mode, recalling a memory will hang the radio requiring removal of power (not power-off, total unplug even from internal batteries). This is because I first set the mode, then the frequency. Doing viceversa might result in a different frequency if a change from SSB to CW is performed. Should be worth spending some code to set frequency, mode and then frequency again to avoid these situations, shouldn't it?
[that's why it is still beta code...]