Input Devices

Input devices are often refer to as sensors. Sensors play a critical role in embedded systems by detecting and measuring physical phenomena, converting them into electrical signals that can be processed by the microcontroller.

Group Assignment

The Kannai team as usual was divided into two and i worked with Ahmad Tijjani Ishaq The task is to probe an input device’s analog levels and digital signals.
Our documentation can be found on Our group assignment page

Individual Assignment

All source files can be found Here at the side bar.

Assignment for the week is to measure something: add a sensor to a microcontroller board that you have designed and read it

Some examples of Input devices are as follows:

  • Temperature Sensor: These sensors measure temperature and are widely used in applications such as climate control, industrial processes, and consumer electronics. Thermistors and temperature-dependent resistors (such as LM35) are commonly used temperature sensors interfaced with microcontrollers.
  • Light Sensor: Light sensors, also known as photodetectors or photoresistors, detect light levels in their surroundings. They are used in automatic lighting systems, ambient light sensing in displays, and in applications where adjusting brightness based on ambient light conditions is necessary.
  • Proximity Sensor: Proximity sensors detect the presence or absence of nearby objects without physical contact. They are used in applications such as obstacle detection in robotics, touchless faucets, and smartphones for detecting when the device is held close to the user's ear during a call.
  • Accelerometer and Gyroscope: These sensors measure acceleration and rotational motion, respectively. They are commonly found in smartphones, game controllers, and wearable devices for tasks such as screen orientation detection, motion tracking, and gesture recognition.
  • Pressure Sensor: Pressure sensors measure pressure levels in gases or liquids and are used in applications such as altimeters, barometers, and tire pressure monitoring systems. Microelectromechanical systems (MEMS) pressure sensors are often integrated into microcontroller-based systems due to their small size and low power consumption.
  • Humidity Sensor: Humidity sensors measure the moisture content in the air and are used in weather monitoring systems, HVAC (heating, ventilation, and air conditioning) systems, and industrial processes where controlling humidity levels is crucial.
  • Gas Sensor: Gas sensors detect the presence of specific gases in the environment and are used in applications such as air quality monitoring, industrial safety, and gas leak detection.
  • Biometric Sensors: Biometric sensors, such as fingerprint scanners and iris scanners, measure unique biological traits for authentication and security purposes. They are increasingly integrated into microcontroller-based systems for access control, identity verification, and payment systems.
For my assignment i work with the keypad module and the Thumbprint sensor.

Keypad

Keypads are frequently utilized in applications where users need to input numerical or limited alphanumeric data, such as security systems, industrial control panels, and consumer electronics like remote controls and digital calculators.

When interfaced with a microcontroller, keypads are usually connected through digital input/output pins. The microcontroller scans the rows and columns of the keypad to determine which button is pressed. This scanning process is typically done through a technique called matrix scanning, where the microcontroller sequentially activates each row and reads the corresponding columns to detect button presses.

Once a button press is detected, the microcontroller can interpret the input and perform the desired actions based on the programmed logic. For example, in a security system, pressing a specific sequence of buttons on a keypad might arm or disarm the system.

Keypads offer a simple and cost-effective input solution for many microcontroller-based projects, providing tactile feedback and ease of use for users interacting with the system.

Interfacing keypad

I used my final project board 2 that i made in my Electronics design week. I connected the seven (7) pins of my keypad to pin gp6 through gp12 of the raspberry pi pico development board.

When using the generally used keypad.h library on my pico, the keypad module misbehaved and did not respond as it does when using the arduino boards so i decided to work with chat gpt and made my own custom keypad library. the code i used is Keypad code arduino and it contains the library.


fingerprint/thumbprint sensor

Thumbprint sensors, also known as fingerprint scanners or biometric sensors, are advanced input devices that capture and analyze fingerprints for authentication and identification purposes. These sensors are designed to recognize the unique patterns and ridges present in an individual's fingerprint, providing a highly secure method of access control.

Thumbprint sensors are commonly used in various applications where secure authentication is essential, such as unlocking smartphones, accessing secure facilities, and logging into computer systems. They offer a convenient and reliable alternative to traditional password-based authentication methods, enhancing security and user experience.

When integrated with a microcontroller-based system, thumbprint sensors typically communicate through interfaces such as SPI (Serial Peripheral Interface) or UART (Universal Asynchronous Receiver-Transmitter). The sensor captures the fingerprint image, processes it using algorithms to extract unique features, and compares it with stored templates to authenticate the user.

Thumbprint sensors employ sophisticated technology, including optical, capacitive, or ultrasonic methods, to capture high-resolution images of fingerprints accurately. These sensors often feature additional security measures to prevent spoofing and unauthorized access, such as liveness detection and encryption of fingerprint data.

By leveraging thumbprint sensors in microcontroller-based projects, developers can implement robust and user-friendly biometric authentication systems, enhancing security while ensuring seamless user interaction.

Interfacing Thumbprint sensor

The sensor is serial based and uses the software serial library to communicate with the pico. It has six pins but i use four(4) pins/wires as follows:

  • GND connected to ground of pico
  • Vcc connected to 3.3v pin of my pico
  • RX to TX(0) of pico
  • TX to RX(1) of pico

I uploaded Thumbprint code arduinoand it works well. I had an issue earlier on when designing my board, i found out that despite having so many serial pins on my pico only the default pins 0 and 1 works with the software serial library. I tried gp16 and gp17 but nothing worked and i had to stick to gp0 and gp1.


All source files can be found Here at the side bar.


Contact Me

Phone: Email: Address: Repository:
+2348132166281 mjidda@nitda.gov.ng No.3 Alimoh Abu street, wuye districs.Abuja Nigeria. Gitlab Repo