Adding a keypad to your uBITx
Arv K7HKL asked whether anybody was interested in adding a keypad to their µBITx and got quite a few responses. It seems that there are a few interested in the same idea!
Jack W8TEE says he would use an analogue approach but this requires lots of spare digital I/O ports that simply don’t exist on a standard µBItx. So what choices are there on a standard µBITx with just one spare analogue port available (A7) on the raduino board?
The choices are simple, you could use:
- An i2c expander port (we’ll ignore this suggestion for now)
- A matrix keypad with resistor array fed into the single analogue port on A7 (a bit like how the keying is done on the µBITx)
- An i2c keypad.
Matrix keypads with resistor arrays
In terms of matrix keypads there are plenty of choices from simple “rubber” keypads, through to expensive and solid keypads. With a choice of 12 or 16 keypads, you may want to think about the options carefully.
Some only have numbers, others have blank keys that allow for customisation. For example, you can replace the blue bits of paper on the Robotdyn keypad with your own printed symbols or numbers:
The keypad illustrated above does not require a resistor matrix as it is built in to the module.
As it happens Robotdyn also make a handy capacitive i2c encoder board that has a matching capacitive keyboard. If you do decide to use an encoder board with the TTP229 chip on board (like the Robotdyn board below), then you should note that there is a hacked sketch that directly works with the board via any 2 ports using bit-banging, as well as a sketch that uses the Wire (i2c) library. A useful reference article can be found here.
[ubitx.net has no interests in Robotdyn!]
Probably the i2c approach would be the preferred approach for most constructors as it does not require using up the last available analogue port on the Raduino. Constructors generally like to save this port for essential analogue functions like a digital S-meter and Power Meter. Regardless of which method you use, you will need to leave aside clock cycles to montior keys being depressed.
Both approaches will require some simple coding changes to be made to the firmware. We will be waiting to see the firmware release from Arv!
By the way, here at ubitx.net we won’t be installing a keypad. There is a very nice and practical virtual keypad (thanks to Ian KD8CEC) provided for free in his Nextion display code. A frequency can be easily dialled up or you can switch to another band, right there on the Nextion screen.