-
-
Notifications
You must be signed in to change notification settings - Fork 70
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
Feature proposal: gps shutdown - wakeup #160
Comments
this is ment to replace the current "gpsEcoMode" ? or to add this to boards without AXP2101/AXP192??? |
I've missed the reading of the code who uses the PMU to cut the power to the gps chip, ok, just read it, and yes, well done. Adding this feature in boards where PMU isn't present could be a great improvement, really, i think that the wast majority of us out there are using a cheapo uBlox chip (mostly in the neo6 version, is the cheapest..). |
it would be awesome to get the exacto lines/commands to make it sleep and wake as needed without turning it of could not find both, just one, but could not test it now |
This is the part of code from the link in the previous post (edited, was broken, sorry): void setup() { Serial.begin(9600); // gpsPort.begin(9600); Serial.println( F("") ); delay(10000); //GPS.send_P( &gpsPort, F("P") ); // wake module send a byte (current = 21.9MA) it uses the neogps library, as this commands work only for the uBlox chips, but the commands can be sent over the gps erial as well. Don't worry, i know , the most precious resource is the time, you will add this feature if you want and if you have enough time, there's no problem at all, it's only ideas to improve this already great piece of code. I've not enough time to help you in writing code, otherwise I would have helped you for sure...so sorry about that :-( |
I really want to test this, do you know which library was used for this? |
NeoGPS library for what i remember... |
For handcrafted trackers that haven't APX chips, another solution could be to connect gps module Vcc to a free GPIO of choice on the board, usually gps draw around 20-30mA and you don't risk to burn the digital input. If you need to power off completely the module, in this way you can do it with a simple digitalWrite(GPIO,0) and with "1" you can poweron the module. |
well I manage to test all modes:
some were the same as Continuous (which is the default) and the PowerSaveMode was not that good as it sleep but uses then again much current to get again gps fix. So it seems I can get a good results out of this test |
Backup Mode is the best available for this purpose for what i've read around, the power consumption in mA is in the 1 to 20 order and you have the list of the sats available at wakeup for a fast tracking, i think you should go for this mode. This could be the mode to use in lowbattery state too, and i was thinking if, for emergency purpose, could be useful to have the tracker that send a single packet every hour or so, a sort of real "emergency" mode if someone needs to be rescued when hiking or walking in remote areas...could be a switchable option to choose in case of lowBattery, completely shutdown the whole system OR keep the system in extremely low consumption mode and send a beacon every hour...aprs was born mainly for this kind of use after all... :-) |
Hi Ricardo, first of all thank you for the lowBatteryVoltage settings, very useful indeed. This isn't an issue, i have another proposal, why not send the shutdown command to the gps module to improve the sleepmode? Ublox gps chips can be put in a "backup mode" where it consume very little current, stated below 200uA, not bad at all. Can be also waked up from this state simply writing some chars over the serial, it needs only some form of "activity" to wake up and do an hot start, so it could retrieve and track satellites from the "backup" mode very quickly...i've see you are using TinyGPS++ as gps library, that is a generic gps library, but you can use simple serial communication to send the "sleep" command to the gps chip, i've read this many years ago...i'll try to retrieve where....here it is:
ArduinoForum Thread about gps commands
as you can read is simply matter to send an array of byte, and all the uBlox chips are compatible with this command.
Hope this can help, thank you for your time, have a nice day!
The text was updated successfully, but these errors were encountered: