
clintard
USA
Asked
— Edited

Is there a way to set the ez-b to automatically reconnect to wifi after the wifi drops out itself?
For example, im using my 4GLTE hotspot from my phone for internet on my laptop and i have the Ez-b connected in client mode. When a call comes in or i turn the wifi off and then back on, i regain connection to my laptop but i have to cycle the ez-b to get it to reconnect again.
Hopefully this is simple as i plan to use 4GLTE connection primarily with my rover
But that of course requires the WiFi connection to be up, and this discussion is how to re-initialize when WiFi has been lost. The idea of using the Raspberry Pi that he will already have on board and that will automatically re-establish its WiFi to physically reset the EZ-B so that it regains WiFi is a good one if we can't figure out how to modify the reset behavior in bgscript (although it looks like @PTP is already there, and I am close to having it figured out).
My idea of controlling power to the EZ-B with a relay driven by the RPI could also allow for shutdown when the battery is low, important for an unattended robot running LiPos that you don't want to ever run out. You could use the UART to have the EZ-B tell the RPI that the battery is dangerously low, have the RPI shut off the EZ-B and then power itself down (actually, the RPI can just safely halt the operating system, but will still be drawing power. Unattended robots probably should not use LiPos....).
Alan
The Pi is a pretty power hungry beast. Consider an $5 cheap small Arduino with around 12 lines of code...
The loop checks the battery voltage on an ADC port and disables a relay when the power is below the threshold
The loop checks the status of the green pin of the ez-b to see if wifi is connected - if not, cycle the power via the relay. Use one of those 2 or 4 pack relay pcb's that we used for Bimbo The Clown - jeremie posted the link to the relay in one of the threads.
All:
Firmware source & download page:
https://github.com/ppedro74/ez-robot-bluegiga-firmware
@Ptp nice work!
@alan, you can also look at this thread which rich had created a real simple circuit if you don't want to bother with an arduino, to save even more energy: https://synthiam.com/Community/Questions/3415
@DJ, well that is easy...
Alan
@PTP, excellent. Exactly what I was thinking, I'll give it a try this week on one of my EZ-B's.
@Clintart_Leanard Where are you located? If you are in the DC/Baltimore megalopolis you can borrow my PIKIT if you don't want to wait for yours to arrive.
Alan
You guys are great! I live in Illinois but the PIKIT3 should be here wednesday and then i will try out PTP's firmware.
When i start putting this thing together i will start a Robot Showcase to show my trial and error, and i may make some youtube videos as well. I have all the parts, just need to find the time to sit down and do it, so be patient with me
Here is the robotic arm i purchased, if you were interested in learning more about it