Report comment

Hi Marc, The wpassid line will return a single string containing all ssids in wpa_supplicant with a comma between each entry. With these two lines
IFS=","
ssids=($wpassid)
ssids gets a list of each ssid from the string.

There will be an issue if in the wpa_supplicant file the ssid has no quote marks
ie ssid=myssid rather than ssid="myssid"
which will return a blank string. Also does your ssid have any other characters other than spaces letters and numbers?

some users have not had the correct wpa_supplicant file which has caused similar issues. Does your /etc/wpa_supplicant/wpa_supplicant.conf file start with
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=GB

with country as your country if not GB.

to see what is being returned from wpa_supplicant after IFS=$IFSdef #reset back to defaults
enter this line

echo "wpassid returns " $wpassid

then when you run the autohotspot script manually you can see what it picks up.

Let me know how you get on.