Microchip Technology Inc

PIC16F18345 Internet of Things (IoT) Sensor Demo

Summary

The number of connected applications is growing rapidly, along with the need to handle multiple functions and reduce power consumption. There are many communication protocols used with different characteristics such as wired, wireless, low-energy and long-range connectivity. These applications range from reading remote sensors and sending the data to the cloud, to enabling remote-boot loader capability for functionality and software updates.

Offering an array of Core Independent Peripherals (CIPs), Microchip's 8-bit PIC® microcontrollers provide the capabilities to handle multiple functions without the core for low-power consumption. The integrated analog, digital and communication peripherals perform functions autonomously, with the ability to alter system performance based on feedback or other application needs. The multiple on-board communication peripherals can be used with external modules to enable Ethernet, Wi-fi, Bluetooth and long-range communications such as LoRa.

The 20-pin PIC16F18345-based IoT sensor badge demonstrates this concept by interfacing with multiple sensors, sound buzzer, communication module and RGB (red, green,blue) light-emitting diodes (LEDs) to perform various application functions, including communication with a smartphone application, via Bluetooth.

For more information on the PIC16F18345, visit www.microchip.com/pic16f18345.

Smartphone/Tablet Application

  • View real time tilt angle of the badge
  • View real time status of each RGB LED
  • View real time temperature data
  • Change operation mode of badge
  • Check battery voltage

Product Highlights

PIC16F18345
  • 17 channel 10-bit ADC
  • 5-bit DAC
  • 2x comparators
  • 2x 10-bit PWMS
  • Complementary Waveform Generator
  • 4x Capture, Compare, PWMs (CCP)
  • Numerically Controlled Oscillator
  • Data Signal Modulator (DSM)
  • 4x Configurable Logic Cells
  • EUSART
  • 2x (I2C/SPI)
  • Peripheral pin select
  • IDLE and DOZE low-power modes
  • Peripheral module disable
MCP16252
  • Synchronous boost DC/DC regulator for single cell operation
MCP9701
  • Analog temperature sensor
RN4020
  • Low-energy Bluetooth module

Demonstration Highlights

The PIC16F18345 manages:

  • Badge tilt angle
  • Badge temperature
  • Color mix and pattern for RGB LEDs
  • Buzzer drive and tone control
  • Bluetooth LE Module
  • Remote control via smartphone/tablet application

Four Modes of Operation:

Mode 1: PIC16F18345 with 3-axis accelerometer and RGB LEDs

  • The RGB LEDs light up based on the accelerometer data. The LEDs on the axis with the most measure force will light up. The center LEDs turns off when the badge is tilted beyond 45 degrees.

Mode 2: PIC16F18345 with RGB LEDs

  • The RGB LEDs will light up based on a predetermined pattern with color dimming

Mode 3: PIC16F18345 with 3-axis accelerometer, RGB LEDs and Buzzer

  • The buzzer and LEDs are driven based on the magnitude of the force sensed by the accelerometer. The higher the force, the higher the pitch of sound and the longer the LEDs light up.

Block Diagram

Mode 4: PIC16F18345 with 3-axis accelerometer, RGB LEDs and Buzzer

  • Following a double tap on the badge, the buzzer sounds and the LEDs light up in a pattern.