Parsing Data From an API using ArduinoJSON (ESP8266/ESP32)

Brian Lough May 23, 2021
Video Thumbnail
Brian Lough Logo

Brian Lough

View Channel

About

Hello! My Name is Brian from Ireland and I make videos mainly on Arduino Projects and libraries. I do a lot of work with the ESP8266 and ESP32

Video Description

In this video we will look at using ArduinoJSON to parse data that we get back from APIs. Arduino JSON is a really great piece of software but there are a few caveats that are important to know when you are using it. Outro Remix by @Davedarko --------------------------------- Timestamps: --------------------------------- 00:00 - Intro 00:34 - ArduinoJSON library overview 01:54 - ArduinoJSON Assistant 04:44 - Dynamic versus Static 05:35 - Handling errors and extracting data 06:41 - Variable Types 06:55 - Warning about char * and memory 08:27 - Parsing the data from the API 09:13 - ArduinoJSON Book 09:48 - Filtering 11:18 - Outro 11:37 - "covered in dog hair" remix by Dave Darko --------------------------------- Links: --------------------------------- Original API request video: https://www.youtube.com/watch?v=HUjFMVOpXBM Some links about memory on ESP8266: https://gist.github.com/witnessmenow/8155c74d5599bfd1c4b1f6e813b1f490 ArduinoJSON: https://arduinojson.org/ ArduinoJSON Assistant: https://arduinojson.org/v6/assistant/ ArduinoJSON Book (help support the author!): https://arduinojson.org/book/ --------------------------------- Code: --------------------------------- Sample API code (both original and new one with JSON): https://github.com/witnessmenow/arduino-sample-api-request --------------------------------- My Discord: --------------------------------- Come hang out and talk about this video or any project you are working on! https://discord.gg/nnezpvq --------------------------------- Github Sponsorship: --------------------------------- I have set up a Github Sponsorship page, it's similar style thing to patreon. Github sponsorships help support videos like these plus the open source projects I create. https://github.com/sponsors/witnessmenow/ Some people have said they would prefer a once off way of supporting the channel, here is a Paypal link if you would prefer that! https://www.paypal.me/bloughyt --------------------------------- My Tindie Store: --------------------------------- My tindie store is currently on vacation mode, it will re-open shortly. https://www.tindie.com/stores/brianlough/ --------------------------------- Other Platforms: --------------------------------- Twitter: @witnessmenow - https://twitter.com/witnessmenow Instagram - https://www.instagram.com/brian_lough/ Instructables: witnessmenow - https://www.instructables.com/member/witnessmenow/ --------------------------------- My Tools & Kit*: --------------------------------- Ender 3 Pro 3d Printer - I got one of these recently and I love it! - UK : https://amzn.to/31bebXT - US : https://amzn.to/2IlSLid Ts-100 Soldering Iron - I have this a couple of years and I love it, I thinking about getting a second! - UK : http://amzn.to/2nlOF23 - US : http://amzn.to/2jDcyxl Lumix GH7 Camera - Camera I used in this video - UK : https://amzn.to/3fCdejn - US: https://amzn.to/3oJk0Yx Logitech C920 HD 1080p Pro webcam - I use one of these for my videos - UK: http://amzn.to/2pnxk9Z - US: http://amzn.to/2BsLMiF *= Affiliate Links

You May Also Like

Essential Gaming PC Build

AI-recommended products based on this video

Loading...
acer Aspire 3 A315-24P-R7VH, 15.6" FHD 1920x1080 Laptop, AMD Ryzen 3 7320U, Radeon Graphics, 8GB RAM, 128G SSD, Windows 11 in S Mode
Best Seller

acer Aspire 3 A315-24P-R7VH, 15.6" FHD 1920x1080 Laptop, AMD Ryzen 3 7320U, Radeon Graphics, 8GB RAM, 128G SSD, Windows 11 in S Mode

(3,603)
$529.99$489.99
FREE delivery Tue, Jun 17
500+ bought in past month
Loading...
Corsair Vengeance LPX 32GB (2 X 16GB) DDR4 3200 (PC4-25600) C16 1.35V Desktop Memory - Black
Best Seller

Corsair Vengeance LPX 32GB (2 X 16GB) DDR4 3200 (PC4-25600) C16 1.35V Desktop Memory - Black

(16,675)
$112.99$101.69
FREE delivery Sun, Aug 10
500+ bought in past month
Loading...
Beelink Mini PC, Intel 12th Gen Alder Lake- N100(up to 3.4GHz), 16GB DDR4 RAM 500GB M.2 SSD, Mini S12 Desktop Computers, USB3.2/WiFi 5/BT4.2 for Home/Office

Beelink Mini PC, Intel 12th Gen Alder Lake- N100(up to 3.4GHz), 16GB DDR4 RAM 500GB M.2 SSD, Mini S12 Desktop Computers, USB3.2/WiFi 5/BT4.2 for Home/Office

(204)
$219.00
PrimeFREE delivery Sat, Jun 14
Loading...
Beelink Mini S13 Mini PC,Intel 13th Twin Lake N150(Upgraded N100, 4C/4T),Mini Computer 16GB RAM 500GB M.2 SSD, W-11 Pro Gigabit Ethernet, 4K UHD, WiFi6, BT5.2 Home/Business Mini Desktop Computer

Beelink Mini S13 Mini PC,Intel 13th Twin Lake N150(Upgraded N100, 4C/4T),Mini Computer 16GB RAM 500GB M.2 SSD, W-11 Pro Gigabit Ethernet, 4K UHD, WiFi6, BT5.2 Home/Business Mini Desktop Computer

(82)
$308.00
FREE delivery Sun, Aug 10
Loading...
OUMAX N150 Dual LAN Mini PC, Intel 13th Gen Twin Lake N150 (Up to 3.6GHz), 16GB DDR4 500GB M.2 SSD, Mini Computer Support 4K Dual HDMI, WiFi5/BT5.0/USB3.2, Built-in 45W Power Supply Office Desktop PC

OUMAX N150 Dual LAN Mini PC, Intel 13th Gen Twin Lake N150 (Up to 3.6GHz), 16GB DDR4 500GB M.2 SSD, Mini Computer Support 4K Dual HDMI, WiFi5/BT5.0/USB3.2, Built-in 45W Power Supply Office Desktop PC

(0)
$299.00
PrimeFREE delivery Sat, Jun 14
Loading...
GIGABYTE - AORUS Elite 16 Gaming Laptop - 165Hz 2560x1600 WQXGA - NVIDIA GeForce RTX 5070 - Intel Core Ultra 9 275HX - 1TB SSD with 32GB DDR5 RAM - Windows 11 Home AD (AORUS Elite 16 BWHC3USC64SH)

GIGABYTE - AORUS Elite 16 Gaming Laptop - 165Hz 2560x1600 WQXGA - NVIDIA GeForce RTX 5070 - Intel Core Ultra 9 275HX - 1TB SSD with 32GB DDR5 RAM - Windows 11 Home AD (AORUS Elite 16 BWHC3USC64SH)

(0)
$9,050.69
FREE delivery Aug 28 - Sep 8Only 3 left in stock.
Loading...
Gigabyte AERO 16 Gaming & Entertainment Laptop (Intel i7-12700H 14-Core, 16.0" 60Hz 4K (3840x2400), GeForce RTX 3070 Ti, 32GB RAM, 4TB PCIe SSD, Backlit KB, WiFi, USB 3.2, Win 11 Pro)

Gigabyte AERO 16 Gaming & Entertainment Laptop (Intel i7-12700H 14-Core, 16.0" 60Hz 4K (3840x2400), GeForce RTX 3070 Ti, 32GB RAM, 4TB PCIe SSD, Backlit KB, WiFi, USB 3.2, Win 11 Pro)

(0)
$11,403.11
FREE delivery Jun 23 - Jul 3
Loading...
Portable Air Conditioners, wobuzhi Evaporative Air Cooler with LCD Screen, Fan Speed&Spray, 7 RGB Lights,USB Powered,1-8H Timer, Personal Air Conditioners, Portable Air Conditioners for Home Office

Portable Air Conditioners, wobuzhi Evaporative Air Cooler with LCD Screen, Fan Speed&Spray, 7 RGB Lights,USB Powered,1-8H Timer, Personal Air Conditioners, Portable Air Conditioners for Home Office

(32)
$39.99
FREE delivery Sun, Aug 10
200+ bought in past month
Loading...
llano RGB Laptop Cooling Pad with Powerful Turbofan Gaming Cooler Radiator with Infinitely Variable Speed, Touch Control, LCD Screen, 3-Port USB Hub, Seal Foam for Notebook Computer 15-19in

llano RGB Laptop Cooling Pad with Powerful Turbofan Gaming Cooler Radiator with Infinitely Variable Speed, Touch Control, LCD Screen, 3-Port USB Hub, Seal Foam for Notebook Computer 15-19in

(1,404)
$129.99
Prime
200+ bought in past month
Loading...
EVGA 1000 GQ, 80+ GOLD 1000W, Semi Modular, EVGA ECO Mode, 5 Year Warranty, Power Supply 210-GQ-1000-V1,Black

EVGA 1000 GQ, 80+ GOLD 1000W, Semi Modular, EVGA ECO Mode, 5 Year Warranty, Power Supply 210-GQ-1000-V1,Black

(396)
$199.95
FREE delivery Tue, Oct 14
Loading...
Logitech G203 Wired Gaming Mouse, 8,000 DPI, Rainbow Optical Effect LIGHTSYNC RGB, 6 Programmable Buttons, On-Board Memory, Screen Mapping, PC/Mac Computer and Laptop Compatible - Black
Best Seller

Logitech G203 Wired Gaming Mouse, 8,000 DPI, Rainbow Optical Effect LIGHTSYNC RGB, 6 Programmable Buttons, On-Board Memory, Screen Mapping, PC/Mac Computer and Laptop Compatible - Black

(17,871)
$27.98$22.38
FREE delivery Tue, Oct 14 on your first order
500+ bought in past month
Loading...
Redragon M612 Predator RGB Gaming Mouse, 8000 DPI Wired Optical Mouse with 11 Programmable Buttons & 5 Backlit Modes, Software Supports DIY Keybinds Rapid Fire Button

Redragon M612 Predator RGB Gaming Mouse, 8000 DPI Wired Optical Mouse with 11 Programmable Buttons & 5 Backlit Modes, Software Supports DIY Keybinds Rapid Fire Button

(8,052)
$22.49
FREE delivery Thu, Aug 21 on your first order
500+ bought in past month
Loading...
NEW SteelSeries Arctis Nova 3 Multi-Platform Gaming Headset - Signature Arctis Sound - ClearCast Gen 2 Mic - PC, PS5/PS4, Xbox Series X|S, Switch, Mobile

NEW SteelSeries Arctis Nova 3 Multi-Platform Gaming Headset - Signature Arctis Sound - ClearCast Gen 2 Mic - PC, PS5/PS4, Xbox Series X|S, Switch, Mobile

(9,500)
$99.98$67.37
PrimeFREE delivery Sat, Jun 14
100+ bought in past month