Author Topic: Pi Zero W and FPP 2.0 - Wifi setup on first boot  (Read 590 times)

Online dkulp

  • Moderator
  • *****
  • Join Date: Sep 2013
  • Location: Framingham, MA
  • Posts: 1,055
  • Kudos: 50
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #15 on: September 14, 2018, 12:22:49 PM »



I think I have the auto-tether mode stuff working on master.    It turns out, I have to turn on tethering AFTER connman starts.  That greatly simplifies thing.   Thus, what it does now is if there is a valid IPv4 address, it leaves everything alone.   Otherwise, it will turn on tethering.   Thus, if wlan0 or eth0 has a valid IP, nothing happens.  If not, you get the tethering.


It does NOT turn off tethering.   Thus, if it auto-turns on, and you go to the networks settings and setup the wlan0 and don't turn off tethering, it will stay on.   


Would be great if folks could test it.   :)     If it works, this WILL warrant new images for 2.1.  No real OS or kernel updates, really just a git pull on the /opt/fpp to pick this up.   Thus, you wouldn't need to re-image anything.
Dan Kulp

Offline Gilmax

  • Newbie
  • *
  • Join Date: Jan 2015
  • Location:
  • Posts: 9
  • Kudos: 0
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #16 on: September 14, 2018, 12:30:37 PM »
Thanks, I will test this out and let you know.

Offline Gilmax

  • Newbie
  • *
  • Join Date: Jan 2015
  • Location:
  • Posts: 9
  • Kudos: 0
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #17 on: September 14, 2018, 01:19:56 PM »
Just tested it out, and on first boot it starts up in Tethered mode.  I connected and configured my SSID and PSK, rebooted, and it went into Tethering mode again.  It never tries to connect to my network now.

Offline Gilmax

  • Newbie
  • *
  • Join Date: Jan 2015
  • Location:
  • Posts: 9
  • Kudos: 0
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #18 on: September 14, 2018, 01:34:43 PM »
Looks like the EnableTethering value is never being reset back to 0 unless you turn it on and then off again in the network settings.  Once I cycled that setting and rebooted I joined my network.

Online pixelpuppy

  • Hero Member
  • *****
  • Join Date: Aug 2015
  • Location: Dallas, TX
  • Posts: 1,073
  • Kudos: 33
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #19 on: September 14, 2018, 02:51:35 PM »
Looks like the EnableTethering value is never being reset back to 0 unless you turn it on and then off again in the network settings.  Once I cycled that setting and rebooted I joined my network.
I'm seeing the same thing.


The UI shows the Enable Tethering checkbox as UN-checked but tethering is still enabled.   
xLights and Vixen3 for sequencing / FPP for scheduling and playing / Falcon controllers for pixels / homemade controllers for everything else

Online dkulp

  • Moderator
  • *****
  • Join Date: Sep 2013
  • Location: Framingham, MA
  • Posts: 1,055
  • Kudos: 50
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #20 on: September 16, 2018, 07:50:20 PM »
I changed the Tether option to a 3 state - Enable/Disable/If no IP.  That changes the setup a little bit, but I think it helps.

Online JonB256

  • Supporting Member
  • ******
  • Join Date: Mar 2013
  • Location: Granbury, Texas
  • Posts: 4,686
  • Kudos: 106
    • Granbury Christmas Lights
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #21 on: September 18, 2018, 06:51:43 AM »
I think I have the auto-tether mode stuff working on master.    It turns out, I have to turn on tethering AFTER connman starts.  That greatly simplifies thing.   Thus, what it does now is if there is a valid IPv4 address, it leaves everything alone.   Otherwise, it will turn on tethering.   Thus, if wlan0 or eth0 has a valid IP, nothing happens.  If not, you get the tethering.


It does NOT turn off tethering.   Thus, if it auto-turns on, and you go to the networks settings and setup the wlan0 and don't turn off tethering, it will stay on.   


Would be great if folks could test it.   :)     If it works, this WILL warrant new images for 2.1.  No real OS or kernel updates, really just a git pull on the /opt/fpp to pick this up.   Thus, you wouldn't need to re-image anything.

Dan, testing on a BBG with Edimax dongle, on an updated uSD card (to v2.x-master-683, started from the Beta ext4 image) it does boot and eventually broadcasts the FPP SSID.
But, when I enter the password Christmas, it never issues an IP address.
I've tried on two Samsung Smartphones and on a Chromebook. None will give me a usable connection.
Will try a few other devices.
And will try on a RasPi.
« Last Edit: September 18, 2018, 07:01:12 AM by JonB256 »

Online dkulp

  • Moderator
  • *****
  • Join Date: Sep 2013
  • Location: Framingham, MA
  • Posts: 1,055
  • Kudos: 50
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #22 on: September 18, 2018, 07:44:19 AM »





Looks like the BBB's are going to be tough.  It seems that we EITHER get the tether mode or we get the ability to connect via the USB cable, not both.  :(


Still investigating to see what might be possible.   Problem is that as soon as I mess something up, nothing works and I have no way to get in and investigate.  :(

Online JonB256

  • Supporting Member
  • ******
  • Join Date: Mar 2013
  • Location: Granbury, Texas
  • Posts: 4,686
  • Kudos: 106
    • Granbury Christmas Lights
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #23 on: September 18, 2018, 08:03:28 AM »

Looks like the BBB's are going to be tough.  It seems that we EITHER get the tether mode or we get the ability to connect via the USB cable, not both.  :(

Still investigating to see what might be possible.   Problem is that as soon as I mess something up, nothing works and I have no way to get in and investigate.  :(

Worked great on a RasPi3b+
Booted from a v2.x-master-612 image (20180709), with CAT5 connected so it could update to 683.
Then rebooted without the CAT5
Eventually, it came up with the FPP ssid
Using Fing, I verified that it was 192.168.0.1 (and my phone was 192.168.0.2) and could browse to it perfectly.

For those folks determined to use a USB drive, how will they do this?

btw, I'm fine with the BBB using a computer USB connection to power and connect. It is very handy and very reliable.

Online dkulp

  • Moderator
  • *****
  • Join Date: Sep 2013
  • Location: Framingham, MA
  • Posts: 1,055
  • Kudos: 50
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #24 on: September 18, 2018, 10:11:31 AM »



Looks like on the BBB, it REALLY depends on the Wifi adapter.  I have tried 5 different wifi adapters that I have on my desk.  2 of them work ok, one will connect and get the 192.168.0.2 IP, but then disconnects 15 seconds later.   If I'm quick I can configure the wlan0.   The other 2 I cannot connect via the tether at all.  :(    This is all the exact some config, just swapping out the wlan0 card and rebooting so nothing changed.


In all cases, with the tethering enabled, the USB connection doesn't work.  I'm definitely going to have the auto-tethering disabled by default on the BeagleBones.   As you said, the USB is rock solid.   I don't want to lose that for something that only works 1/2 the time.




Online pixelpuppy

  • Hero Member
  • *****
  • Join Date: Aug 2015
  • Location: Dallas, TX
  • Posts: 1,073
  • Kudos: 33
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #25 on: September 18, 2018, 10:15:05 AM »
Looks like on the BBB, it REALLY depends on the Wifi adapter.  I have tried 5 different wifi adapters that I have on my desk.  2 of them work ok,


Different Brands, or different units of the same brand?    I have all EDIMAX and haven't been able to get it to work on BBB ... but I haven't tried swapping them with others units that are the same brand


Which brand works?

Online dkulp

  • Moderator
  • *****
  • Join Date: Sep 2013
  • Location: Framingham, MA
  • Posts: 1,055
  • Kudos: 50
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #26 on: September 18, 2018, 10:21:35 AM »
Different Brands, or different units of the same brand?    I have all EDIMAX and haven't been able to get it to work on BBB ... but I haven't tried swapping them with others units that are the same brand

Which brand works?


I think the two that worked were based on Ralink chips instead of RealTek chips.  That does bring up another possibility, the ralink's use the in-kernel drivers by default whereas on the BBB, we use external drivers for the RealTeks.   Probably should try tethering with the kernel drivers.   That said, switching drivers isn't something that can be done if we don't detect a link.   That requires a reboot.

Online pixelpuppy

  • Hero Member
  • *****
  • Join Date: Aug 2015
  • Location: Dallas, TX
  • Posts: 1,073
  • Kudos: 33
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #27 on: September 18, 2018, 10:33:45 AM »
I think the two that worked were based on Ralink chips instead of RealTek chips.  That does bring up another possibility, the ralink's use the in-kernel drivers by default whereas on the BBB, we use external drivers for the RealTeks.   Probably should try tethering with the kernel drivers.   That said, switching drivers isn't something that can be done if we don't detect a link.   That requires a reboot.
Well there ya go!


I switched to Linux Kernel drivers and now my iPad successfully *associates* (i.e. WiFi link established) but I'm now getting the same problem Jon reported with the client not getting the 192.168.0.2 address.   (it comes up with a 169.254.x.x autoconfigured address)
 

Offline mararunr

  • Hero Member
  • *****
  • Join Date: Dec 2013
  • Location:
  • Posts: 541
  • Kudos: 12
    • Bentonville Heart Lites
Re: Pi Zero W and FPP 2.0 - Wifi setup on first boot
« Reply #28 on: November 07, 2018, 12:08:45 PM »
Thank you.  Needed this to get my PiZero W running.  Could not get to web UI by restarting apache and appears tethering doesn't work on Pi Zero W (or maybe still disabled by default).  Anyway, thanks again - have my first 2.0 device running now - a Pi Zero (yes I know I'm not on the cutting edge but I'm just not willing to put my show on 2.x just yet but wanted to test with one of my bench Pis).


If you are wanting to do a static IP, you need to use the following in the interface.wlan0 file

Code: [Select]
INTERFACE="wlan0"
PROTO="static"
ADDRESS="YOUR_STATIC_IP"
NETMASK="YOUR_NETMASK"
GATEWAY="YOUR_GATEWAY"
SSID='YOUR_SSID'
PSK='YOUR_PSK'

Please note that the Interface/Proto/Address/Netmask/Gateway are using ", while the SSID and PSK are using a '.
Bentonville Heart Lites (www.facebook.com/bheartlites)
 This is just my opinion/suggestion/viewpoint.  Others with other viewpoints/experiences may have different advice.  I am a hobbyist with a couple years real world experience, not an expert.

 

Back to top