WiFi manager with BlynkEdgent for OTA

Hello, and thank you for sharing ideas and solutions.

I was wondering if it’s possible to pass the WiFiManager credentials (SSID and password) directly to the WiFi management of BlynkEdgent. To clarify:

After downgrading the ESP32 Espressif library to v2.x.x as suggested by Pete, I would like to configure my device locally through a collaborator (for instance, in Dubai) using WiFiManager. Now, since the OTA mechanism requires the BlynkEdgent configuration, I want to pass the WiFiManager credentials directly into BlynkEdgent to avoid setting up WiFi again, which would be redundant alongside WFM, using the Blynk mobile app.
This method will enable me to upload a new sketch remotely.

Is there a workaround for this scenario?

Thank you in advance.

P.S.: Removing the WiFi manager and using the Blynk mobile app is indeed possible, but for an inexperienced person, utilizing WiFiManager might be easier.

I’ve re-read your post several times, and I’m still not clear about exactly what you’re trying to achieve.

Attempting to use WiFi Manager and Edgent alongside each other won’t work, and you need to forget that idea.

I don’t really understand why you’re unhappy with the functionality of Edgent when it comes to provisioning devices with WiFi credentials and dynamic auth tokens. Maybe you can elaborate on that?

Blynk.Air OTA shipments don’t overwrite the provisioned credentials, which is what you seem to imply in part of your post, but I might be misunderstanding what you’re saying there.

There are ways to do Blynk.Air OTA shipments without using Edgent, but I still don’t understand why Edgent doesn’t meet your needs.

Maybe you could clarify.

Pete.

First of all, thank you for your quick response.

In my opinion, and this is my opinion, using the WiFi manager is much simpler and more fluid for a user who is not used to using Blynk. In my code, I implemented a physical button to reset the WFmanager credentials. However, in the case of Blynk, since resetting the credentials requires a manual reset directly on the ESP32 board… no big deal (maybe it is possible to do the same)…

  1. I don’t really understand why you’re unhappy with the functionality of Edgent when it comes to provisioning devices with WiFi credentials and dynamic auth tokens. Maybe you can elaborate on that?

That said, the discussion could end here. But just to quote since I feel good :slight_smile: I’ll proceed… (we are a bit joking, aren’t we?)

  1. I don’t really understand why you’re unhappy with the functionality of Edgent when it comes to provisioning devices with WiFi credentials and dynamic auth tokens. Maybe you can elaborate on that?

The famous collaborating user who is not very experienced should first be instructed on how to reset the flash memory to delete the wifi credentials managed by BlynEdgent, then he should open the app (so this requires the developer to manage a user with specific credential - ok doable from Blynk console), then he should select the device (if already present otherwise associate it) but if already present because provided by the developer he must navigate in a couple of menus until he gets to the “Reconfigure” item and thus associate the new wifi credentials. Does the answer provide sufficient elaboration? :sweat_smile:

  1. Blynk.Air OTA shipments don’t overwrite the provisioned credentials, which is what you seem to imply in part of your post, but I might be misunderstanding what you’re saying there.

I have never supported this and I am aware of it, and it is the reason why I am deleting the WFM from code because while my procedure reset the WFM credentials, the BlynkEdgent ones remained in memory creating a double assignment of credentials uselessly (where in the previous message I write about redundancy). That said, I am happy with the OTA management with BlynkEdgent and BlynkAIR.

  1. There are ways to do Blynk.Air OTA shipments without using Edgent, but I still don’t understand why Edgent doesn’t meet your needs.

As for what was said in point 3) it goes without saying that the answer has already been given, dispelling your fear since I have never shown my dissatisfaction with the OTA management.

Finally :slight_smile: I think I will switch to the Maker subscription to satisfy my client’s development needs.

Then I will return to the forum to disturb the community again …promise :sweat_smile:.

I’m guessing you haven’t done much testing with Blynk Edgent?

Incorrect. Credentials can be set in three ways - via a physical button that is held for 10 seconds, via the Blynk app, and via the web console.

The rest of your comments seems to relate to a scenario where a board has previously used for a different purpose, then repurposed for use with Edgent. I guess it may be worthwhile Blynk flagging-up the fact that you’d need to fully reset the board by clearing all flash memory before installing Blynk Edgent or the first time, but the experienced developer would probably do this anyway.

I’m currently unsure how you’re planning to proceed, but I’d suggest you do more Edgent testing to fully familiarise yourself with its features and functionality.

Pete.

Thank for the prompt answer.

To clarify, when I mention “resetting the credentials requires a manual reset directly on the ESP32 board,” it involves pressing and holding the reset button for 10 seconds on the board itself, without the need for any additional physical interrupt buttons.

Correct, through the Blynk APP, setting up WiFi credentials is a task that only an Admin account can perform. It has been established that a User account does not have the permission to execute this action.

Please can you clarify this point?
Thank you in advance!

To clarify my basic idea…
P.S.: The scenario I envision is:

  1. An admin configures the sketch and uploads it while the device is physically connected to his PC;
  2. A collaborator takes the device with him, to Japan for example;
  3. The collaborator is required to enter the Wi-Fi credentials into the device while in Japan.
  4. Option A - The admin provides his credentials so the collaborator can access the Blynk App (mobile), reset the device if necessary as previously indicated, and enter new credentials;
  5. Option B - This isn’t a viable solution because if the collaborator uses his own account on the Blynk App (mobile), which the admin has set as “User,” the device will appear offline… which is a failure.
  6. Assuming the only solution is A, the admin, who may be in Rome, can then initiate any device updates via OTA (BlynkAIR).

I just hate sharing the Admin credentials… :face_with_raised_eyebrow:
This is what I’ve managed to do after three to four days of coding.

Apologies for the lengthy explanation.

Incorrect. It depends what type of subscription you have, and the permissions allocated to the user.

You really ought to read the documentation regarding dynamic provisioning.

Pete.

Thanks for the answer,

To be clear Pete, when I text “User” I am not referring to a Blynk subscription user, but an organization user profile that one that has a lot of credential limitations.

I have a Maker subscription, and I can’t find any info (until now) on how a “User” can add a device (I succeeded in doing it only with the “device transfer” option) so the user can only see the device, but I couldn’t find any other way to add or modify the device credentials from the “User” account by Blynk APP. (maybe “Staff”?)

It is more likely that you are also referring to the PRO subscription and even the solution provided through sub-organizations… but definitely, it is not my case.

For instance, here:


That is exactly what I have done (and the way I am using the device/Blynk APP) and exactly the workaround I cited here:

I believe that the topic that you suggested I read here does not mention a User profile (that is one of my organization) abilities.

After reading many comments on this forum, it seems hard to find a clear solution to some topics/tasks, but maybe it’s just my impression…incorrect?

Can you, please share with me a link where is a description of the “User” profile (that one I have settled in my organization) workaround about how he can add a device or change wifi credentials? This is the topic of the sentence you cited from my message and more likely part of the topic discussed here where I wrote.

I would appreciate it. thank you

[SOLVED] Ok you already answered me in this thread I need a PRO subscription.
Thanks again! :slight_smile:

With the Free and Maker subscriptions you can’t edit the user permissions.
If the default user permissions don’t allow provisioning of owned devices (I’d need to see your permissions table to confirm that this is the case) then you’ll need a PRO subscription.
If this is a commercial application then you should be using the PRO subscription anyway, as the Maker subscription is for “personal projects” and I fail to see how the scenario you’re describing fits into that category.

Pete.

1 Like

This is not for commercial use, but rather for academic research. Simple. :slightly_smiling_face:

Is there an educational plan available for Blynk subscriptions?

Thank you for clarifying everything. :+1:

No.

Pete.