I am not finding this question in SF history, which was a surprise, so I'll go ahead and ask it.
I am working on an IoT Raspberry Pi project with Windows 10 and need to connect it to the internet via an Ethernet/USB adapter. The adapter itself is made by Belkin. Using this, I can see an ip of 169.stuff get generated for my Pi, which is a private ip. I can deploy code to that from my connected box, however other devices are not able to reach it, and it is not able to make connections out to any servers.
I'm wondering if anybody knows how to bridge the connection.
I am attempting to use the new Azure IoT Hub and the SDK with this in case that makes any differences as that is not a simple rest interface and I believe is some form of socket connection.
Additional Notes: I have installed a DCHP Server and the Pi gets the ip address: 192.168.0.3 assigned to it. Unfortunately the Pi still can not ping external sites, such as google.com
Latest Discoveries: I am on a corporate box, which has internet sharing disabled by the system admin. Following these instructions: http://zizhujy.com/blog/post/2013/07/07/Solved-Internet-Connection-Sharing-has-been-disabled-by-the-Network-Administrator.aspx Fails. It shuts down all connectivity to my box and I cannot ping anything or reach the internet or anything.
Thanks, ~David
A Raspberry Pi WiFi bridge is one of the best ways of providing internet access to a device that only supports an Ethernet connection. In this tutorial, we will show you how to setup a WiFi bridge, and how to setup dnsmasq correctly to allow any device to connect through your Pi without issues.
The way the bridging works is that you create a virtual interface (the "bridge", usually called br0) and give it an IP address. Then you add interfaces to the bridge. The order isn't important. So you don't "bridge eth0 to wlan0" or "bridge wlan0 to eth0" as such, you just "add wlan0 and eth0 to the bridge".
The computer can be connected to the router using an Ethernet cable as well, or using wireless. To physically connect the Pi to the router you'll need an Ethernet cable that has male RJ45 connectors on both ends. Plug one end into the computer and the other end into the Pi. Ethernet cable with male RJ45 connectors.
The 169 address means it isn’t getting a DHCP address assigned.
Since you don't have a router for the Ethernet, you can use Internet Connection Sharing, however we will need to run the following commands against the Pi to set a static IP, gateway, and dns server, since internet connection sharing botches this up a bit at times:
Set-Item WSMan:\localhost\Client\TrustedHosts -Value 192.168.137.2
Enter-PSSession -ComputerName 192.168.137.2 -Credential 192.168.137.2\Administrator
set-executionpolicy unrestricted
netsh int ip set address "Ethernet" static 192.168.137.2 255.255.255.0 192.168.137.1
netsh int ip set dns "Ethernet" static 8.8.8.8
netsh interface ipv4 show config
set-executionpolicy remotesigned
You may need to reboot the Pi at this point then test pinging 8.8.8.8 and google.com to make sure resolution is working. You should be all set!
One other thing, if you have a group policy on the machine that is restricting Internet Connection Sharing then take a look at this article to fix the issue. Note if your organization is constantly sending down the policy then you may have to re-enable Internet Connection Sharing often which is aggravating but at least it will work. http://zizhujy.com/blog/post/2013/07/07/Solved-Internet-Connection-Sharing-has-been-disabled-by-the-Network-Administrator.aspx
I do this by creating a DHCP server on my laptop and connecting the Pi directly to it. I followed these instructions to get it working:
Hope this works!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With