lewisxhe / AXP202_PythonLibrary

MicroPython axp202
11 stars 11 forks source link

AXP192 Support on T22_V1.0 #1

Closed gampam2000 closed 4 years ago

gampam2000 commented 5 years ago

Hi,

i got it running on the TTGO T-Beam T22_V1.0 but i need to enable all the powers to get the GPS Module working. If i only enable

a.enablePower(axp202.AXP192_LDO3) #LDO3 = GPS

it does not work, why?

lewisxhe commented 5 years ago

This is written for AXP202. It was not tested on 192. Some of them are wrong. I didn't have time to update it, but it is OK to turn on the power. You can use the voltmeter to measure whether the GPS power pin has voltage.

gampam2000 commented 5 years ago

i got the GPS running, but if I operate it on battery i can not shut it of, it seem that the PWR button is connected to the APX192 and i have no clue how to configure it. Any suggestions?

Better support for AXP192 for the TTGO T-Beam T22_V1.0 would be really great, i hope you can find some time.

lewisxhe commented 5 years ago

The PWR button only controls the AXP192 switch. If you don't want to use GPS, you can turn off the gps channel power.

a.disablePower(axp202.AXP192_LDO3) #LDO3 = GPS

gampam2000 commented 5 years ago

Thanks, that works fine. But when I insert a Battery the whole Device is always on and the PWR Button does nothing. My Question was if i can configure the PWR Button (axp192 powerkey) to shut the board completely off and on? If yes how?

lewisxhe commented 5 years ago

By default, the battery will not turn on automatically, but you need to press the PWR button for two seconds to start it. Press and hold for 6 seconds to enter the shutdown. Refer to my Arduino library for the function of configuring the PWR button