TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: Raspberry Pi Zero W Simultaneous AP and Managed (Client) Mode WiFi

101 pointsby albeec13over 7 years ago

10 comments

albeec13over 7 years ago
I've had a hard time finding resources on getting a Raspberry Pi Zero W to operate simultaneously as and AP and WiFi client. I pooled together whatever resources I found that failed me, but got part of the way there, and figured out the rest on my own. I figured it would be a good thing to share, since there appear to be a lot of people asking how to do it, and not a lot of solutions out there.
评论 #15351879 未加载
emjover 7 years ago
When doing assigning you own fictional MAC I would recommend using locally administered addresses. It&#x27;s basically just one bit flip: <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;MAC_address#Universal_vs._local" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;MAC_address#Universal_vs._loca...</a><p><pre><code> x2-xx-xx-xx-xx-xx x6-xx-xx-xx-xx-xx (... etc) </code></pre> And a question do you know why ap0 doesn&#x27;t show up in you iw dev command? It seems you are only changing the addr not the device name.
评论 #15357770 未加载
bjpirtover 7 years ago
I recently did the same thing and have packaged it all up as an Ansible setup script [1]. We&#x27;re using it for a Pi based robot arm [2], so having a built-in access point and a web interface to use for configuring the WiFi means you don&#x27;t need to rely on the user plugging in any peripherals. Works well!<p>Incidentally, the framework (headlessPi [3]) we use to run &quot;apps&quot; in the browser and configure the system is all open source and easy to configure for your own use.<p>[1] <a href="https:&#x2F;&#x2F;github.com&#x2F;headlessPi&#x2F;headlessPi-setup" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;headlessPi&#x2F;headlessPi-setup</a> [2] <a href="https:&#x2F;&#x2F;mime.co.uk&#x2F;products&#x2F;mearm-pi&#x2F;" rel="nofollow">https:&#x2F;&#x2F;mime.co.uk&#x2F;products&#x2F;mearm-pi&#x2F;</a> [3] <a href="https:&#x2F;&#x2F;github.com&#x2F;headlessPi&#x2F;headlessPi" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;headlessPi&#x2F;headlessPi</a>
评论 #15358052 未加载
nathan_f77over 7 years ago
That&#x27;s great! One thing I&#x27;ve always wanted to build is an open source project to manage wifi on Raspberry Pis, with a similar user experience to Chromecast. It would be really useful as a base for hobby projects, as well as real products.<p>The idea is that if wifi is not configured or can&#x27;t connect, then the Raspberry Pi would switch to AP mode. When you connect to the SSID, you would see a web page where you can configure your home wifi SSID and password, or choose a network from a list.<p>Does something like this already exist? I think it could be used in a lot of different projects, including RasPlex [1] and RetroPie [2]. I haven&#x27;t looked at those projects for a while though, so maybe they already have that feature.<p>[1] <a href="http:&#x2F;&#x2F;www.rasplex.com&#x2F;" rel="nofollow">http:&#x2F;&#x2F;www.rasplex.com&#x2F;</a><p>[2] <a href="https:&#x2F;&#x2F;retropie.org.uk&#x2F;" rel="nofollow">https:&#x2F;&#x2F;retropie.org.uk&#x2F;</a>
评论 #15357080 未加载
评论 #15357268 未加载
qwert12355over 7 years ago
Very nice work! Just curious what the range is like (client and AP) and if you have noticed any performance decrease vs your normal internet connection.
评论 #15357740 未加载
serfover 7 years ago
does this behave sanely if the pi-zero is taken out of range of the AP it&#x27;s connected to? Are the connections between the pi-zero and its&#x27; clients preserved in that case?<p>I&#x27;m just now finding this when i&#x27;m about to hit the hay -- so I lack the cognition to go through it -- but i&#x27;d like something like this for a project of mine that involves a pi-zero-w that needs to maintain a connection with my cellphone while on the go -- and dump data when within range of a known AP.
评论 #15357685 未加载
wslhover 7 years ago
I am curious about the existing issue when running these two modes simultaneously. Is this related to the network chipset that makes it harder vs a common PC card?
评论 #15357800 未加载
mmanulisover 7 years ago
This is fantastic! Thank you for sharing. I was going to start looking into this for IoT applications myself.<p>I need to have a fail-safe where one device will usually be connected to WiFi and other devices may not for a myriad of reasons.
评论 #15354230 未加载
cryoover 7 years ago
Thanks for the article this is <i>very</i> useful will try later on with Raspberry Pi 3 and the Raspberry Zero Zero W.
评论 #15357813 未加载
epalmerover 7 years ago
This is fantastic and well documented.
评论 #15357802 未加载