Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AP SSID not showing up #26

Open
adilberrada opened this issue Sep 15, 2017 · 17 comments
Open

AP SSID not showing up #26

adilberrada opened this issue Sep 15, 2017 · 17 comments

Comments

@adilberrada
Copy link

adilberrada commented Sep 15, 2017

Hi,

I did follow correctly your tutorial. First time I tried, I could see from my iPhone the rpi SSID in wifi list. Once I added the line "denyinterfaces wlan0", I could not make it work. The script goes well but I can't see the rpi in wifi list... don't know what I did wrong ...

Now my pi has 192.168.44.1 address but it does not show up and I can't get my pi to connect to a wifi. Any idea ?

Thank you very much !

@sabhiram
Copy link
Owner

Pi3 or Pi2? What OS?

@adilberrada
Copy link
Author

Pi3. After a fresh reinstall I got it work but have another bug (#24), once I open the web page after connecting to pi's ip, there is no scan, I only get {{ cell.ssid }} {{

@shawnipoo
Copy link

cell.ssid went away after reinstalling. Do not know why I had it too... Thing is that it still does not broadcast!
@sabhiram , what is the ideal OS to install on a Pi3?

@sabhiram
Copy link
Owner

I think it should just be whatever latest raspbian - but there have been network utility changes that are messing with this tool. Not sure I can reproduce what you are seeing on my Pi3 either...

@shawnipoo
Copy link

@sabhiram , what OS do you have it operational on? I do not need the latest version of raspbian, but id really love to get this working. I've literally tried installing it 10 times in many different ways (different order of installing things) to no avail... Would you kindly be able to help out?

@sabhiram
Copy link
Owner

sabhiram commented Sep 28, 2017

Dang, maybe we should hop on a hangout / call so I can see your screen and try and walk through things. I think I just used the latest version of raspbian from the raspberry pi website.

I apologize for the lag in delay, we are trying to form a new startup and it has been taking up quite a bit of my time lately.

@shawnipoo
Copy link

I'd love that! Maybe this weekend? Let me know when you are available.
Thank you!

@adilberrada
Copy link
Author

It did not work for me as well... even after reinstall. If you figure out what is wrong, could please post here what you did it would help a lot!
On the other side, I did try this http://andrewnicolaou.co.uk/posts/2015/resin-wifi-connect-without-docker and it works well.

Thank you guys!

@shawnipoo
Copy link

Hey @sabhiram , any luck? Thank you!

@shawnipoo
Copy link

@adilberrada , how did you install resin-wifi-connect? The automatic way or manually?

@shawnipoo
Copy link

@adilberrada any news? @sabhiram any news? Thank you!

@adilberrada
Copy link
Author

adilberrada commented Oct 23, 2017

@shawnipoo I installed it in the manually way.

@shawnipoo
Copy link

Did not work for me @adilberrada .. Did you encounter any issues? When installing it cannot install wireless-tools. Did you use the latest version of Raspbian stretch?

@adilberrada
Copy link
Author

No, I had no problem installing it ... what is the error you get?

@sabhiram
Copy link
Owner

Would appreciate if this thread is used to troubleshoot problems with this repo.

With that said, I was able to get my AP to show up but I noticed that there might have been an issue with the AP not showing up on my PI3 like stated. Can someone confirm by manually running the app - getting to the point where it says AP Enable Success and have it not show the AP? At this point, re-starting the app seemed to get the AP listed.

If this is reproducible, it would help in finding the right solution. I will see if I can put a hack in place to debug this problem.

@gregoryz7
Copy link

gregoryz7 commented May 11, 2018

  1. Fresh Install of latest raspbian on a PI3B:
    RASPBIAN STRETCH WITH DESKTOP
    Image with desktop based on Debian Stretch
    Version:April 2018
    Release date:2018-04-18
    Kernel version:4.14
  2. First i ran instructions per the readme (including setting it up as a service). Restarted. Got the access point to show. But after navigating to 192.168.44.1:88 no page would load.
  3. I turned my pi on today. It didnt even broadcast the network :(
  4. I read another issue thread that you had posted. Stopped the service and launched the project manually. First it popped up with a port 88 already in use error so i killed the app using the port with
    sudo fuser -k 88/tcp . I'm not sure why it was in use. Maybe the stop service isn't cleanly stopping this app or this app is competing on launch for 88?
  5. sudo npm start gives
> node server.js
Wifi is not enabled, Enabling AP for self-configure

Force reconfigure enabled - reset AP
... dhcp server failed! -
ifdown wlan0 successful...
ifup wlan0 successful...
... hostapd restarted!
... AP Enable Success!

HTTP server running...

But on loading the page I get "{{ cell.ssid }}" issue

issue
EDIT-
the "{{cell.ssid}}" issue was an oversight in my install script. I sudo npm install bower -g but didnt bower install. After reinstalling things in order everything works up until I reboot the pi3.

Everything meaning:

  1. I enter my credentials into the pi.
  2. The pi connects to my network.
    But.. Then after rebooting the system I cant ping anything external like ping www.google.com
    but I can ping 192.168.44.1:88
    Although I can ping it, the access point is not broadcasting.
    I can open a browser(on the pi3), navigate to the 192.168.44.1:88 and then enter my credentials again to connect to my network. But that isn't all that helpful

@gregoryz7
Copy link

I think I have made some progress on dissecting your code.

I made a few changes:
1.

var ifconfig_fields = {
        "hw_addr":         /HWaddr\s([^\s]+)/,
        "inet_addr":       /inet ([^\s]+)/,   // WAS /inet addr:([^\s]+)/,
    },  iwconfig_fields = {
        "ap_addr":         /Access Point:\s([^\s]+)/,
        "ap_ssid":         /ESSID:\"([^\"]+)\"/,
        "unassociated":    /(unassociated)\s+Nick/,
    },  last_wifi_info = null;

Because the formatting of ifconfig's output has changed (ex. below)
From:
capture1
To:
capture2
has anyone else seen this?

2.
I also switched over the access point detection to use Mode: Managed vs Mode:Master for the iwconfig as it seems to be a reliable way to detect the mode. Did you run into issues using this?
3.
I think sometimes service hostapd restart is silently failing so I put in place a check after to see if it has switched modes and to retry 10 times (hackish) before quiting and this usually does the trick. Sometimes it takes 3 tries before it switches. I might need to put a delay on the detection to make sure im not rechecking for no good reason.
Still Working On:
1.
I still have issues on restart using both rc.local and the startup script. The changes I have made work and it switches over to Master Mode on the detect state (according to my log) but by the time the system has finished starting its no longer broadcasting. I have a feeling some other startup process is reverting wlan0 back / restarting something. Has anybody else had this happen? I can try setting a late priority for it but I am not sure which other processes should be started prior?
2.
isc-dhcp-server restart still fails from time to time. More details on that later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants