• Stars
    star
    164
  • Rank 222,748 (Top 5 %)
  • Language
    C
  • License
    MIT License
  • Created almost 4 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A library to read QR Codes using an ESP32 with a camera module.

ESP32 QR Code Reader

This library provides a interface to read QR Codes using an ESP32 with a camera.

Internally this lib uses a slight modified version of the Quirc library and some code from OpenMV port on the MaixPy project.

Demos

Usage

Is recommended to use PlatformIO to install this lib. Add ESP32QRCodeReader to your platformio.ini file.

From PlatformIO library:

lib_deps=
  ESP32QRCodeReader

Directly from Github:

lib_deps =
  alvarowolfx/ESP32QRCodeReader

Examples

This library comes with a number of example sketches. See File > Examples > ESP32QRCodeReader within the Arduino application. You can see them on the examples folder on this repository.

Basic example:

#include <ESP32QRCodeReader.h>

// See available models on README.md or ESP32CameraPins.h
ESP32QRCodeReader reader(CAMERA_MODEL_AI_THINKER);

void onQrCodeTask(void *pvParameters)
{
  struct QRCodeData qrCodeData;

  while (true)
  {
    if (reader.receiveQrCode(&qrCodeData, 100))
    {
      Serial.println("Found QRCode");
      if (qrCodeData.valid)
      {
        Serial.print("Payload: ");
        Serial.println((const char *)qrCodeData.payload);
      }
      else
      {
        Serial.print("Invalid: ");
        Serial.println((const char *)qrCodeData.payload);
      }
    }
    vTaskDelay(100 / portTICK_PERIOD_MS);
  }
}

void setup()
{
  Serial.begin(115200);
  Serial.println();

  reader.setup();
  reader.beginOnCore(1);
  xTaskCreate(onQrCodeTask, "onQrCode", 4 * 1024, NULL, 4, NULL);
}

Limitations

  • Need an ESP32 module with PSRAM - See below.

Compatible Hardware

The QR Code recognition lib required a lot of memory, so I was only able to get this to work with an ESP32 that has PSRRAM available and also the Quirc library is modified to use that directly.

  • ESP32 module
  • PSRAM Available
  • Camera module - Tested with OV2640

ESP32 modules with camera that have PSRAM and should work:

  • CAMERA_MODEL_WROVER_KIT
  • CAMERA_MODEL_ESP_EYE
  • CAMERA_MODEL_M5STACK_PSRAM
  • CAMERA_MODEL_M5STACK_V2_PSRAM
  • CAMERA_MODEL_M5STACK_WIDE
  • CAMERA_MODEL_AI_THINKER

ESP32 modules without PSRAM that will not work:

  • CAMERA_MODEL_M5STACK_ESP32CAM
  • CAMERA_MODEL_TTGO_T_JOURNAL

License

This code is released under the MIT License.

References

More Repositories

1

asset-tracker-gcp-mongoose-os

🚧 An Asset Tracker made with an ESP32 running MongooseOS + GPS and GPRS Module, sending data through Google Cloud IoT Core
JavaScript
72
star
2

wasm-arduino-wifi

Running TinyGo/Rust/Assemblyscript on an ESP32 using WebAssembly.
C++
67
star
3

weather-station-gcp-mongoose-os

A Weather station made with an ESP32, sending data through Google Cloud IoT Core and storing in BigQuery
JavaScript
48
star
4

gcloud-dota-app

Dota 2 App using Firebase and Google Cloud
JavaScript
38
star
5

ai-candy-dispenser

A Candy Dispenser using Android Things + TensorFlow Lite + Mobilenet
Kotlin
36
star
6

gcloud-iot-edge-tensorflow

Asset Tracking using Edge Computing and Computer Vision.
Jupyter Notebook
34
star
7

GifPartyReactNative

React native demo project used on FrontInCuiabá 2016
JavaScript
29
star
8

firebase-sensoriamento

[🔥] Código do Tutorial de Sensoriamento Realtime com Firebase e ESP8266
HTML
28
star
9

botanika

A Offline App using Ionic and PouchDB
CSS
26
star
10

gcloud-lora-ttn

Integration between Google Cloud and The Things Network
Go
25
star
11

ble-rgb-light-flutter

Control a RGB Led Light over Bluetooth LE using a Flutter app
C
20
star
12

gcloud-ota-arduino-update

Serverless Continuous Integration and OTA update flow using Google Cloud Build and Arduino
C++
20
star
13

xinga.me

Go
19
star
14

bad-smell-detector-gcloud-iot-flutter

C++
19
star
15

esp32-youtube-display

Display Youtube metrics using Google API and MicroPython
Jupyter Notebook
17
star
16

gcloud-iot-core-device-provisioning

This repository show an end to end onboarding flow of an IoT Device using an ESP32 with an BLE interface, a Flutter App using that BLE interface, a backend to talk IoT Core to provision and send commands and a Cloud Function to ingest data from IoT Core to Firebase.
C++
14
star
17

physical-cube-imu-web-bluetooth-esp32

Physical Cube using ESP32, Acc+Gyro and Bluetooth LE displayed in a Browser - A WebBluetooth experiment
C++
12
star
18

physical-led-ring-webusb-arduino

Physical Led Ring controlled via a Browser - A WebUSB and Arduino experiment
C++
12
star
19

cloud-run-django-rest-iot

Let’s create a farm tank monitoring solution using Django Rest Framework as our base for the project. Saving farms, tanks and devices associations data on Cloud SQL and the device telemetry on BigQuery.
Python
12
star
20

talking-plant-aog

How to talk with plants using IoT and Actions on Google.
JavaScript
10
star
21

poketrainers

Source code of the poketrainers.co website
JavaScript
10
star
22

esp32cam-totp-qrcode-auth

Access/Auth system using ESP32 with camera, QR Codes and 2FA
Go
10
star
23

wasm-ble-edge-filter

Using WASM as a Rules Engine for IoT
C++
10
star
24

tinyml-smart-tennis-sensor

Run Machine learning on a microcontroller with an accelerometer sensor to classify different moves with the racket - Forehand, Backhand, Serve, and Idle.
C
10
star
25

codelab-actions-on-google

Codelab de Actions on Google
JavaScript
9
star
26

facebook-followers-counter-esp8266

Facebook Followers Counter with ESP8266
Arduino
9
star
27

smart-home-mqtt

Experimental and WIP - Bridge between Google Smart Home and MQTT
JavaScript
9
star
28

twitch-bot-home-assistant

My personal Twitch channel bot to interact with my Home Assistant instance
JavaScript
8
star
29

iconik

CLI tool for generating icons for iOS and Android apps.
JavaScript
8
star
30

gcloud-ci-cd-demo

CI/CD Demo used on some personal talks
Go
7
star
31

go-grpc-rest-api-demo

Demo for my talk about building REST APIs using gRPC with Go
Go
7
star
32

onion-golang-blink

Onion Omega 2 + Golang = ❤️ Code for the tutorial on how to get started with Golang and Onion Omega
Go
7
star
33

golang-voice-iot

Controlling a MeArm robot arm using Golang and Google Assistant
Go
6
star
34

esp8266-telegram-bot

Arduino
6
star
35

wasm-pipes

Build flexible and easy to use pipelines using Web Assembly
WebAssembly
5
star
36

mearm-web-bluetooth

🤖💪 MeArm + Arduino + Web-Bluetooth = 🎉
JavaScript
5
star
37

lalg

Compiler and Virtual Machine to execute the academic language LALG
Java
4
star
38

gps

C
4
star
39

streamdeck-ble-diy

DIY Version of the Streamdeck device using ESP32
Objective-C
4
star
40

ng-pokedex

A pokedex web app using AngularJS and Pokeapi.co
JavaScript
4
star
41

ng-step

A step by step progress component build with angular.js
JavaScript
4
star
42

bh1750-androidthings

Android Things driver for BH1750 ambient light sensor
Java
4
star
43

ng-keypad

A customizable keypad made with Angular.js
CSS
4
star
44

personal-site

Personal site source
HTML
3
star
45

go-coap-iot-demo

Go
3
star
46

front-in-cuiaba-app

App developed for demo purposes for the talk that I gave at Front In Cuiaba event at 2015
JavaScript
3
star
47

friendlychat-react

JavaScript
3
star
48

carshop-grpc-sqlc-go-demo

Go
3
star
49

arena-rpg.go

Arena-RPG feito em Go
Go
3
star
50

packtpub-notifier-gcp

Application that notifies when a new book is free on PacktPub. Backend in NodeJS, Apps in React Native and Alexa integration. All running on google cloud platform.
JavaScript
2
star
51

golang-iot-weather-station

Go
2
star
52

codelab-iot-cloud

Codelab - Google Cloud IoT Core e MongooseOS - I/O Extended Cuiabá 2018
JavaScript
2
star
53

shopping-list-app

Example application using AngularJS
HTML
2
star
54

onion-golamp

Onion Omega 2 + Golang + Homekit Demo
Go
2
star
55

dojo-s01e02-escrevendo-no-celular.go

Implementação em Go do problema proposto no dojo S01E02 do DevMT
Go
2
star
56

codelab-esp

C++
1
star
57

iot-chair-sensor

Sensor de presença em cadeira ( Demo na apresentação de IoT)
Arduino
1
star
58

dojo-s01e01-cheque-por-extenso.clj

Implementação do problema proposto no dojo S01E01 do DevMT
Clojure
1
star
59

ItinerarioCuiabaServer

Server side do app de itinerarios de Cuiabá
Ruby
1
star
60

nrf52-wifi-zephyr

C
1
star
61

codelab-mba-big-data

Python
1
star
62

gcp_mkr1010

C++
1
star
63

SupernaturalChannel

Discipline project of Advanced Databases in the course of Computer Science at UFMT. We used the database Neo4j with some data gattered from Twitter about the Supernatural series.
JavaScript
1
star
64

weathernet

Leverege Coding Test
JavaScript
1
star
65

elixir_ceps

An Elixir experiment to read a list of Brazilian Zipcodes
Elixir
1
star
66

dojo-s01e01-cheque-por-extenso.scala

Implementação do problema proposto no dojo S01E01 do DevMT
Scala
1
star
67

react-hacker-news

Tutorial usando create-react-app usando dados de feeds do Hacker News
JavaScript
1
star
68

RU-UFMT

Aplicativo para iOS para visualizar o cardápio do Restaurante Universitário da UFMT
Objective-C
1
star