HardwareX (Apr 2019)

A novel analogue keyboard for embedded applications, based on integer division truncation

  • M. Mariola,
  • C. Bemont,
  • F. Petruccione

Journal volume & issue
Vol. 5

Abstract

Read online

Modern micro-controllers are powerful control devices available in a range of packages with a variable number of input/output pins. Smaller microcontrollers, for example the Attiny45, have only six available pins for input/output but relatively powerful performance in terms of processing. However, it is often not possible to exploit the resources of such a microcontroller due to the limited number of pins available. Using an analogue keyboard only one pin of a microcontroller is required. In other analogue keyboards, each character or command corresponds to an analogue value produced on the nodes of a voltage divider composed of several resistors. The principle difference between the system proposed here and previous analogue keyboards is in the algorithm. Because no resistor has zero tolerance, the voltage drop across the voltage divider nodes in a standard analogue keyboard is never precisely as expected. Thus, in order to function correctly, the microcontroller must be programmed for such a system so as to recognise that each analogue value lies between two particular fixed values. In the proposed system, the discretisation is instead entrusted to an approximation from an integer division. Using the same approach, it is also possible to easily convert a standard potentiometer into a discrete switching device. This keyboard is not intended to replace a standard alphanumeric computer keyboard, rather it is an alternative for any case where a cheap, compact micro-controller based device requires control, particularly when a microcontroller has limited input/output pins. Lastly it can be implemented as an analogue rotating selector, and is adaptable because the number of selection steps/keys is set purely as a software parameter. Keywords: Microcontroller, Arduino, Controls, Keyboard