37 Commits

Author SHA1 Message Date
Stefan Thoss
4f04516323 Use ESP_LOGCONFIG (#2) 2024-01-09 16:01:45 -08:00
Stefan Thoss
469b50b607 Add battery charging state and voltage (#1) 2023-12-22 21:22:26 -08:00
Stefan Thoss
a477785a34 Add XPowersLib 2023-12-21 21:02:44 -08:00
Stefan Thoss
89adb157fa First working version 2023-12-21 20:51:50 -08:00
Stefan Thoss
f215521303 Change to AXP2102 2023-12-21 20:50:53 -08:00
Daniel
56e649bd4e Replace tabs with four spaces. Remove trailing whitespace. 2023-05-16 04:50:38 -07:00
Daniel
58998da466 Add breaks to switch/case statements. 2023-05-16 04:36:45 -07:00
paulchilton
6d87e2c74d Changed brightness log so it only logs when the value is changed 2023-01-01 10:00:49 +00:00
paulchilton
97b6f0115f Moved restart code to the correct place for the M5Tough 2022-12-31 20:51:02 +00:00
paulchilton
25fcd23de9 Removed log entry 2022-12-31 20:48:08 +00:00
paulchilton
cb8a0e8364 Update axp192.cpp 2022-12-31 20:47:27 +00:00
paulchilton
3e3ec2366c Added GetStartupReason method header 2022-12-31 20:47:16 +00:00
paulchilton
21078e5565 Update axp192.cpp 2022-12-31 20:45:39 +00:00
paulchilton
4c91690d8d Update axp192.cpp 2022-12-31 20:41:23 +00:00
paulchilton
253aaccfa7 Update axp192.cpp 2022-12-31 20:34:23 +00:00
paulchilton
93a89eb95d Testing different placement of auto-restart 2022-12-31 20:19:45 +00:00
paulchilton
fe779b8631 Update axp192.cpp 2022-12-31 20:13:15 +00:00
paulchilton
a6ea145770 Added check for first power on and reset so the display properly initialises 2022-12-31 20:08:15 +00:00
paulchilton
fc022332b3 Added M5Tough Option 2022-12-31 17:06:46 +00:00
paulchilton
89bda5a501 Added M5 Tough Option 2022-12-31 17:05:29 +00:00
paulchilton
a1d5441cda Added M5 Tough option 2022-12-31 17:04:51 +00:00
Chris Metcalfe
35e0c12938 fix brightness of m5core2 screen
m5core2 uses DC-DC3 to control brightness rather than using LDO2. DC-DC3 is controlled by the 7 least significant bits in the 0x27 register; the most significant bit is reserved. As a result the brightness value shifts left 3 places rather than 4. in order to set the register I read the entire byte, logical AND with 0x80 to clear all bits except the reserved bit, logical OR with the shifted brightness value.

added brightness to the sample m5core2 config
2022-10-10 19:05:18 -05:00
marty@dingo.sh
401605df03 initial commit 2022-09-03 17:13:33 +01:00
Gonzalo Paniagua Javier
f0c48216fd Fixes compilation in with esphome > 2022.2.6.
esphome versions after 2022.2.6 fail to compile axp192 with the
following error:

  File "/home/test/esphome/custom_components/axp192/sensor.py", line 16, in <module>
    sensor.sensor_schema(UNIT_PERCENT, ICON_BATTERY, 1).extend({
  TypeError: sensor_schema() takes from 0 to 1 positional arguments but 3 were given
2022-03-29 10:29:34 -04:00
Shish
1a46c6e86d Use uint8_t for byte data 2022-01-05 22:01:14 +00:00
Gonzalo Paniagua Javier
2f9a66b23e Fix compilation with current esphome code
Fixes errors including:
src/esphome/components/axp192/axp192.cpp: In member function 'void esphome::axp192::AXP192Component::DeepSleep(uint64_t)':
src/esphome/components/axp192/axp192.cpp:355:35: error: 'gpio_num_t' was not declared in this scope
     esp_sleep_enable_ext0_wakeup((gpio_num_t)37, LOW);
                                   ^
src/esphome/components/axp192/axp192.cpp:355:50: error: 'LOW' was not declared in this scope
     esp_sleep_enable_ext0_wakeup((gpio_num_t)37, LOW);
                                                  ^
2021-12-30 16:53:01 -05:00
Airy André
b9d955732c Make colors great again 2020-10-20 11:32:39 +02:00
Airy André
8c301f300c Merge branch 'master' into master 2020-10-20 11:19:58 +02:00
Ian Geiser
5e31e93afa make colors compat again 2020-09-15 13:51:37 -04:00
Ian Geiser
7e4c5cbf6a Merge branch '1_15_changes' of github.com:geiseri/esphome-m5stickC 2020-09-15 11:39:35 -04:00
Ian Geiser
5d2419b4ad use Color class from upstream 2020-09-15 11:38:33 -04:00
Ian Geiser
d10ff6262e add upstream for #998 2020-09-15 08:18:27 -04:00
Ian Geiser
7976e97046 add more colors from upstream 2020-09-13 08:37:48 -04:00
Ian Geiser
f0b67875a9 support page operations on display 2020-09-13 08:18:23 -04:00
abmantis
6a77ae993a Add brightness config support
This is far from perfect, but its a start. Ideally, the value would be
set in the display component instead.
2020-03-07 00:37:57 +00:00
Airy André
5b6660dbbf Better battery level - still wrong but at least that's some sample sensor for this component... 2020-02-09 11:15:53 +01:00
Airy André
18b807347d First version of components 2020-02-09 10:06:06 +01:00