Skip to content

Commit cdfe116

Browse files
committed
Add support for lolin c3 mini on a airgradient-pro
1 parent 43aa1d6 commit cdfe116

2 files changed

Lines changed: 55 additions & 0 deletions

File tree

airgradient-pro.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ dashboard_import:
2121

2222
packages:
2323
board: github://MallocArray/airgradient_esphome/packages/airgradient_d1_mini_board.yaml
24+
# board: github://MallocArray/airgradient_esphome/packages/airgradient_lolin-c3-mini_board.yaml
2425
captive_portal: github://MallocArray/airgradient_esphome/packages/captive_portal.yaml
2526
pm_2.5: github://MallocArray/airgradient_esphome/packages/sensor_pms5003.yaml
2627
co2: github://MallocArray/airgradient_esphome/packages/sensor_s8.yaml
@@ -33,7 +34,13 @@ packages:
3334
wifi: github://MallocArray/airgradient_esphome/packages/sensor_wifi.yaml
3435
uptime: github://MallocArray/airgradient_esphome/packages/sensor_uptime.yaml
3536

37+
# For use with the D1 Board
3638
binary_sensor:
3739
- id: !extend config_button
3840
pin:
3941
number: D7
42+
43+
# For use with the Lolin C3 Mini Board
44+
# binary_sensor:
45+
# - id: !extend config_button
46+
# pin: 4
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# This is for use with the AirGradient Pro replacing the default
2+
# D1 Mini esp8266 board with a Lolin C3 Mini esp32 board
3+
4+
substitutions:
5+
config_version: 5.3.2
6+
7+
esphome:
8+
name: "${name}"
9+
friendly_name: "${friendly_name}"
10+
name_add_mac_suffix: ${name_add_mac_suffix} # Set to false if you don't want part of the MAC address in the name
11+
platform: ESP32
12+
13+
project:
14+
name: mallocarray.airgradient
15+
version: "$config_version"
16+
min_version: 2025.5.0
17+
18+
esp32:
19+
board: lolin_c3_mini
20+
variant: esp32c3
21+
framework:
22+
type: esp-idf
23+
24+
# Enable logging
25+
# https://esphome.io/components/logger.html
26+
logger:
27+
28+
uart:
29+
- rx_pin: 1
30+
tx_pin: 0
31+
baud_rate: 9600
32+
id: pms5003_uart
33+
34+
- rx_pin: 6
35+
tx_pin: 7
36+
baud_rate: 9600
37+
id: senseair_co2_uart
38+
39+
i2c:
40+
# https://esphome.io/components/i2c.html
41+
sda:
42+
number: 8
43+
# Acknowledging that this is a strapping pin and should not have external pullup/down resistors
44+
# https://esphome.io/guides/faq.html#why-am-i-getting-a-warning-about-strapping-pins
45+
ignore_strapping_warning: true
46+
scl: 10
47+
# 400kHz eliminates warnings about components taking a long time other than SGP40 component: https://github.com/esphome/issues/issues/4717
48+
frequency: 400kHz

0 commit comments

Comments
 (0)