Hello everyone. My team is using a raspberry pi 3 for vision processing. Our vision processing works correctly and we send the data to the Roborio using the networktables. The problem we are having is that the rpi sometimes doesn’t connect to the modem. We have tried using mdns for the ip of the rpi and Roborio and static ips, but in both cases the rpi sometimes fails to connect to the modem.
When it doesn’t connect the only solution is to turn off the modem and turn it on again. If we turn of the rpi without turning off the modem the rpi never connects so we believe it might be a problem with the modem.
Does anybody know what could be causing this behavior?
davidzz123:
Hello everyone. My team is using a raspberry pi 3 for vision processing. Our vision processing works correctly and we send the data to the Roborio using the networktables. The problem we are having is that the rpi sometimes doesn’t connect to the modem. We have tried using mdns for the ip of the rpi and Roborio and static ips, but in both cases the rpi sometimes fails to connect to the modem.
When it doesn’t connect the only solution is to turn off the modem and turn it on again. If we turn of the rpi without turning off the modem the rpi never connects so we believe it might be a problem with the modem.
Does anybody know what could be causing this behavior?
We had a very similar issue. What we did to fix it was to replace our 2017 router with a 2016 router. It really was that simple for us.
Cabey4
March 9, 2017, 11:36pm
3
Have you set your network devices to a static configuration? That generally helps. Here’s a copy-paste answer from what I wrote for someone else with network troubles.
Hi. We had a slightly similar issue last year.
The networking configuration is different between home, pits and on the field. The following articles can help explain how they are set up - This one on networking basics: https://wpilib.screenstepslive.com/s/4485/m/13503/l/696075-networking-basics and this one on the configurations at competition: https://wpilib.screenstepslive.com/s/4485/m/24193/l/319135?data-resolve-url=true&data-manual-id=24193 .
Personally, I think that teams should set everything to static if their network set up is anything more than the minimum (a RoboRIO and the driver station).
I would set up your network according to how the “IP Networking at the Event” suggests for the static configuration. i.e.
Static (workaround configuration)
It is also possible to configure static IPs on your devices to accommodate devices or software which do not support mDNS. When doing so you want to make sure to avoid addresses that will be in use when the robot is on the field network. These addresses are 10.TE.AM.1 and 10.TE.AM.4 for the OpenMesh radio and the field access point and anything 10.TE.AM.20 and up which may be assigned to a device still configured for DHCP. The roboRIO network configuration can be set from the webdashboard.
OpenMesh radio - Static 10.TE.AM.1 programmed by Kiosk
roboRIO - Static 10.TE.AM.2 would be a reasonable choice, subnet mask of 255.255.255.0 (default)
Driver Station - Static 10.TE.AM.5 would be a reasonable choice, subnet mask must be 255.0.0.0
IP Camera (if used) - Static 10.TE.AM.11 would be a reasonable choice, subnet 255.255.255.0 should be fine
Other devices - Static 10.TE.AM.6-.10 or .12-.19 (.11 if camera not present) subnet 255.255.255.0
.
If you do make your devices static, everything must be made static or else you will have problems (i.e. the RoboRIO, the Driver Station and the RPI).
If you do make things static, you will have to use their static IP’s rather than their mDNS names, so “roboRIO-TEAM-FRC.local” will become “10.TE.AM.2”
Note: A guide to setting static IP’s on RPI’s can be found at https://www.modmypi.com/blog/how-to-give-your-raspberry-pi-a-static-ip-address-update
Setting a static IP on the RoboRIO is done through the web dashboard (click on the blue Ethernet cable icon.)
To set a static IP on the driver station, right click on the WIFI symbol in the task bar, go “Open Network & sharing center” then “Change adapter settings”, right-click on the adapter (i.e. Ethernet) then Proprieties and double click “Internet Protocol Version 4 (TCP/IPv4)” then select “Use the following IP address” and set it to what the ScreenSteps guide says to. Post-competition to access the internet, set it back to “Obtain an IP address automatically”.