ST AN839 APPLICATION NOTE

AN839 application note introduces a technique for decoding multiple keys using only one I/O port pin. The technique is based on connecting the keys by a resistive voltage divider to the ADC input.


ST AN839 APPLICATION NOTE - cover page
Brand
STMicroelectronics
Category
microcontrollers
Document type
Application Note
Language
English
Pages
7
File format
PDF
File size
53 KB
Published
07 August, 2012
Updated
30 September, 2023
MD5 checksum
42511258B723863C14C0395AC0E7D2CC

About this manual

This document details a practical application for decoding multiple keys using the ST6 family's on-chip Analog to Digital Converter (ADC). The technique involves connecting keys to a single I/O port pin through a resistive voltage divider, allowing the system to identify pressed keys based on the resulting voltage levels. This approach reduces the number of required I/O pins compared to traditional matrix keyboards.

What's inside

  • Introduction
  • Principle of Operation
  • Keyboard Hardware Description
  • Software Generation
  • Possible Improvements
  • Revision History

Specifications

Maximum number of keys10
Supply voltage for conversion results5V
ADC resolution8-bit

Frequently asked questions

How many keys can be decoded with this method?

The practical maximum number of keys is limited by the precision of the resistors, but the document provides a specific example for a 10-key system.

What happens if more than one key is pressed simultaneously?

The system detects the key in the chain closest to the ADC input, allowing keys to be prioritized.

Download PDF (53 KB)

More STMicroelectronics Manuals


View all STMicroelectronics manuals →