Specifying IP parameters from the script

Give it a try, it costs you nothing !
Post Reply
User avatar
Posts: 179
Joined: Mon Feb 08, 2021 6:22 pm
Has thanked: 40 times
Been thanked: 102 times

Specifying IP parameters from the script

Post by Electroguard »

Perhaps the existing Wifi.Connect command might be extended to optionally allow specifying static IP parameters rather than the router always defaulting to dhcp, eg:
WIFI.CONNECT SSID$, password$ [, BSSID$] [,Static_IP$, SubnetMask$, DefaultGateway$]
Posts: 9
Joined: Tue Feb 09, 2021 7:01 pm
Location: Budapest, Hungary
Has thanked: 26 times
Been thanked: 2 times

Re: Specifying IP parameters from the script

Post by nedudgi »

I highly agree this idea. As an addition, I recommend some modification, to add time server, and the time zone into the script, autorun program too.
Without any knowledge, I tried to understand the internals of the installation procedure. I checked the contents of data-min.zip, and created my special version.
I have more locations, where my ESP-s will located, so I wrote tiny program, that (at the first run) scans the accessable AP-s, and connects the best fitting one. It would make integration easier, to define the autorun program, and the default time zone plus time server in config.ini - that should be stored seperately on the PC, outside of the data-min.zip and flashed into each module. Before flashing, the Annex Toolkit extracts data-min.zip, just insert/overwrite into the newly created compressed file to be flashed.
Post Reply