Arduino Data Communications Learn How to Configure Databases, MQTT, REST APIs, and Store Data over LoRaWAN, HC-12, and GSM
Build real-world, scalable, and fault-tolerant IoT systems using Arduino MKR boards that collect, transmit, and store data on a massive scale in a structured database Key Features Set up databases to store and retrieve information collected from various sensors Ingest your data into your database fo...
Otros Autores: | |
---|---|
Formato: | Libro electrónico |
Idioma: | Inglés |
Publicado: |
Birmingham, England :
Packt Publishing Ltd
[2023]
|
Edición: | First edition |
Materias: | |
Ver en Biblioteca Universitat Ramon Llull: | https://discovery.url.edu/permalink/34CSUC_URL/1im36ta/alma991009785406206719 |
Tabla de Contenidos:
- Cover
- Title Page
- Copyright and Credits
- Dedication
- Contributors
- Table of Contents
- Preface
- Part 1: Introduction to Arduino and Sensor Data
- Chapter 1: Getting Started with Arduino
- Technical requirements
- Learning about Arduino - The company
- Learning about Arduino - The hardware
- Choosing your board - The Arduino MKR family
- Learning about the Arduino IDE
- Arduino Cloud IDE
- Arduino Desktop IDE
- Learning about the Arduino programming language
- Getting started with Arduino
- General purpose input and output
- Writing the first lines of code - Hello World
- Installing the board
- Blinking the onboard LED
- Summary
- Chapter 2: Leveraging Various Sensors for Data Acquisition
- Technical requirements
- Learning about input and output pins
- UART
- SPI
- I2C
- Discovering sensors
- Motion sensors
- Acoustic sensors
- Environmental sensors
- Vision sensors
- Biometric sensors
- Force
- Rotation
- Summary
- Further reading
- Chapter 3: Prototyping with Shields
- Technical requirements
- What is a shield?
- What are carriers?
- Working with sensor shields
- Project 1 - Working with the MKR ENV Shield R2
- Discovering other types of shields
- Communicating with automobiles
- Outputting information
- Providing expansion
- Motion sensing
- Geolocation
- Working with the MKR IoT Carrier
- Project 2 - Collecting sensor data with the Arduino MKR IoT Carrier
- Summary
- Further reading
- Chapter 4: Storing Data Collected from Sensors
- Technical requirements
- Storing data
- Project 1 - Storing temperature and humidity in a file
- Analyzing the .ino file
- Analyzing the MyEnv.hpp file
- Analyzing MyEnv.cpp
- Understanding flat files
- Getting to know the TXT file format
- Getting to know the CSV file format
- Getting to know the TSV file format.
- Getting to know the JSON file format
- Working with databases
- Flat-file databases
- Relational (SQL) databases
- Project 2 - Configuring a MySQL database server
- Document-oriented databases
- Time series databases
- Project 3 - Configuring an InfluxDB server
- Summary
- Further reading
- Chapter 5: Implementing REST and MQTT Protocols for Communication
- Technical requirements
- Working with REST
- Project 1 - Defining tables within MySQL
- Working with SQL
- Project 2 - Inserting data into a MySQL table
- Project 3 - Retrieving data from a MySQL table
- Project 4 - Updating data in a MySQL table
- Project 5 - Deleting data from a MySQL table
- Implementing a REST API using JavaScript
- Installing Node.js
- Setting up an application structure
- Understanding routes and routing
- Project 6 - Defining a route
- Implementing a REST API using Python
- Installing dependencies
- Creating the application structure
- REST API for InfluxDB
- Getting sample data into InfluxDB
- Generating an API token
- Making an API call
- Working with MQTT
- Installing the Mosquitto MQTT broker
- Installing the Telegraf agent
- Summary
- Further reading
- Part 2: Sending Data
- Chapter 6: Utilizing Various Communication Technologies
- Technical requirements
- Utilizing short-range communications
- Bluetooth
- Zigbee
- Wi-Fi
- Utilizing medium-range communications
- RS-485
- HC-12
- Utilizing long-range communications
- LoRaWAN
- SigFox
- Cellular communication
- Communicating with REST APIs
- Testing the API endpoint using Postman
- Project 1 - Send sensor readings to the REST API
- Summary
- Chapter 7: Communicating with LoRaWAN
- Technical requirements
- Introduction to LoRa and LoRaWAN
- Installing a board driver for the Portenta H7
- Installing the LoRa library
- Using point-to-point communication.
- Using star networks
- Working with The Things Network
- Understanding gateways on TTN
- Understanding applications on TTN
- Purchasing and setting up radios and gateways
- Buying LoRaWAN-certified gateways
- Buying LoRaWAN-certified microcontrollers
- Getting the microcontroller's EUI
- Summary
- Further reading
- Chapter 8: Working with Ethernet
- Technical requirements
- Introduction to Ethernet
- Arduino devices that support Ethernet
- Installing Arduino Portenta board drivers
- Communicating over Ethernet
- Creating an AccuWeather app
- Getting your API key
- Getting your location key
- Getting the weather conditions
- Project 1 - Setting the onboard LED's intensity based on the temperature
- Summary
- Chapter 9: Leveraging Cellular Communication Technology
- Technical requirements
- Learning about cellular connectivity
- Choosing cellular radios
- Deployments in North America
- Deployments in EMEA
- Blues Wireless
- Arduino cellular options
- Making phone calls
- Project 1 - Making a call with the MKR GSM
- Working with SMS
- Project 2 - Receiving an SMS
- Project 3 - Sending temperature and humidity data via SMS
- Working with GPRS
- Project 4 - sending temperature and humidity data over GPRS
- Summary
- Further reading
- Chapter 10: Communicating via HC-12
- Technical requirements
- Learning about HC-12
- Acquiring HC-12 modules
- Setting up the hardware
- Configuring the HC-12 module
- Sending and receiving data
- Exercise 10.1 - displaying whatever the HC-12 module receives
- Sending temperature and humidity over HC-12
- Summary
- Further reading
- Chapter 11: Managing Communication with RS-485
- Technical requirements
- Introducing RS-485
- Benefits of RS-485
- Cons of RS-485
- RS-485 hardware
- Introducing Modbus
- Modbus pros
- Modbus cons
- Modbus hardware.
- Connecting peripherals
- Modbus messaging
- Reading data from a peripheral
- Summary
- Further reading
- Part 3: Miscellaneous Topics
- Chapter 12: Enhancing Security for Reducing Risk
- Learning about the threat landscape
- Encryption algorithms
- Data backup
- Multi-factor authentication
- Password managers
- Embracing cloud security
- Multi-factor authentication
- Identity and access management
- Key Management Service
- Secrets Manager
- Storage buckets
- Managed databases
- Virtual machines
- Shielded VMs
- DoS protection
- Virtual private networks
- Bastion hosts
- Firewalls
- Enforcing edge security
- Operating system
- Login and access control
- Over-the-air updates
- Backups
- Physical ports
- Firewalls
- Learning about certificate authorities
- Let's Encrypt
- Certificate Authority Service
- Summary
- Chapter 13: Scaling for High Availability
- Understanding high availability
- Power outage
- Network outages
- Hardware failure
- Hardware upgrades
- Increased demand
- Understanding load balancing
- Implementing HA for databases
- Implementing HA for RESTful servers
- Summary
- Further reading
- Chapter 14: Building and Manufacturing Hardware
- Designing more compact hardware
- Proof-of-concept (PoC) prototypes
- Microcontrollers
- Preliminary production design
- PCB prototyping
- Schematic design
- PCB design
- Bill of Materials
- Designing printed circuit boards
- Manufacturing hardware
- PCB fabrication
- Enclosures
- Understanding the need for certification
- Summary
- Further reading
- Index
- About Packt
- Other Books You May Enjoy.