From 0977dfd8943b7d615f9f9719472c76fff0143016 Mon Sep 17 00:00:00 2001 From: Jm Casler Date: Sat, 16 Jan 2021 14:49:58 -0800 Subject: [PATCH] #615 - Allow rate for tbeam battery charger to be configurable --- mesh.proto | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/mesh.proto b/mesh.proto index 5bb080a..21fd8f3 100644 --- a/mesh.proto +++ b/mesh.proto @@ -482,6 +482,30 @@ enum RegionCode { // Add new regions here } +/** + Sets the charge control current of devices with a battery charger that can be + configured. This is passed into the axp power management chip like on the tbeam. +*/ +enum ChargeCurrent { + Unset = 0; + 100MA = 1; + 190MA = 2; + 280MA = 3; + 360MA = 4; + 450MA = 5; + 550MA = 6; + 630MA = 7; + 700MA = 8; + 780MA = 9; + 880MA = 10; + 960MA = 11; + 1000MA = 12; + 1080MA = 13; + 1160MA = 14; + 1240MA = 15; + 1320MA = 16; +} + /** How the GPS hardware in this unit is operated. @@ -565,6 +589,9 @@ message RadioConfig { /// The region code for my radio (US, CN, EU433, etc...) RegionCode region = 15; + /** Sets the current of the battery charger */ + ChargeCurrent charge_current = 16; + /** Are we operating as a router. Changes behavior in the following ways: The device will only sleep for critically low battery level (i.e. always tries to stay alive for the mesh)