• Skip to main content
  • Skip to primary sidebar

RNTLab.com

The Ultimate Shortcut to Learn Electronics and Programming with Open Source Hardware and Software

  • Courses
  • Forum
    • Forum
    • Ask Question
  • Shop
  • Account
  • Blog
  • Login

AsyncMqttClient library issue

Q&A Forum › Category: ESP32 › AsyncMqttClient library issue
0 Vote Up Vote Down
Charles Merkel asked 11 months ago

https://imgur.com/4L4A4LY
This error is from an attempt to move a working sketch from an older win10 machine to a newer win11 machine. I am using v2.5.3 of the IDE. I have tried to find the library AsyncMqttClient on the new machine but can’t seem to find it. I find variations of the name but nothing that seems to work. I tried to copy and paste the library from the older machine, however that did not work either. The sketch is one from your ebook “Smart Home etc” . The system is one with an esp32 , a bme280 sensor and I have added a SSD display. I use this device to monitor the conditions in a 3D filament storage unit. I also use the mqtt/node-red to monitor the results remotely on a pc or phone. I moved the sketch to the win11 machine as it is much faster and I want to add some more features. The device works well when it is uploaded from the win10 machine.
Do you have any idea as to what is going on here?
regards,KentM
 

Question Tags: AsyncMqttClient
9 Answers
0 Vote Up Vote Down
Sara Santos Staff answered 11 months ago

Hi.
Install the library the way it is mentioned in the Smart Home Course.
Download the .zip folder and then include the .zip.
It’s explained in the course.
Regards,
Sara

0 Vote Up Vote Down
Sara Santos Staff answered 11 months ago

Let me know if you need further help.
Regards,
Sara

0 Vote Up Vote Down
Charles Merkel answered 11 months ago

Sara, Thank you for the reply. That is exactly what I did with all the libraries in that sketch as soon as I fixed one, the next one failed. 
I then proceeded on and got a new error that I have no idea about. I am reluctant to change things in the sketch because it still works on the older computer. But here is the error msg.
https://imgur.com/O23P4md

0 Vote Up Vote Down
Sara Santos Staff answered 11 months ago

Hi.
That error is because you’re using the latest version of the ESP32 core (version 3). There were some breaking changes from version 2 to 3 (https://randomnerdtutorials.com/esp32-migrating-version-2-to-3-arduino/).

We still didn’t have the time to update all our codes to the newest version.
The codes in the Smart Home eBook were created for version 2.
To make things work, you can do one of the following options:

1) downgrade your ESP32 boards installation. Go tom Tools > Boards > Boards Manager, search for ESP32 and downgrade to version 2.

or

2) Update the code to be compatible with version 3.

Replace the following Wi-Fi events:

SYSTEM_EVENT_STA_GOT_IP
SYSTEM_EVENT_STA_DISCONNECTED

with

ARDUINO_EVENT_WIFI_STA_GOT_IP
ARDUINO_EVENT_WIFI_STA_DISCONNECTED

If you’re using a code that uses PWM, the functions were also updated. You can see this updated guide:
https://randomnerdtutorials.com/esp32-pwm-arduino-ide/

If you have doubts, just let me know. I can fix the code for you.

Regards,
sara

0 Vote Up Vote Down
Charles Merkel answered 11 months ago

Thank you, Sara. If I can’t make it work , I will get back with you
KentM

0 Vote Up Vote Down
Sara Santos Staff answered 11 months ago

Ok. Then, let me know.

0 Vote Up Vote Down
Charles Merkel answered 11 months ago

Another error >>>>>>>
Platform ‘esp32:esp32’ not found: platform not installed
 
Compilation error: Platform ‘esp32:esp32’ not found: platform not installed
<<<<<<<<

0 Vote Up Vote Down
Charles Merkel answered 11 months ago

Sara, problem solved. The new computer did not have the right boards installed. I got them installed and now the sketch has compiled.
Thanks for your help
KentM

0 Vote Up Vote Down
Sara Santos Staff answered 11 months ago

Great.
I’ll mark this issue as resolved. If you need further help, you just need to open a new question in our forum.
Regards,
Sara

Primary Sidebar

Login to Ask or Answer Questions

This Forum is private and it’s only available for members enrolled in our Courses.

Login »

Latest Course Updates

  • [New Edition] Build ESP32-CAM Projects eBook – 2nd Edition April 16, 2025
  • [eBook Updated] Learn ESP32 with Arduino IDE eBook – Version 3.2 April 16, 2025

You must be logged in to view this content.

Contact Support - Refunds - Privacy - Terms - MakerAdvisor.com - Member Login

Copyright © 2013-2025 · RandomNerdTutorials.com · All Rights Reserved

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.