Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
syssi committed Jul 28, 2024
1 parent abdc1b0 commit d6e6288
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions components/jbd_bms_ble/button/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import esphome.config_validation as cv
from esphome.const import CONF_FACTORY_RESET, CONF_ICON, CONF_ID

from .. import CONF_JBD_BMS_BLE_BLE_ID, JBD_BMS_BLE_BLE_COMPONENT_SCHEMA, jbd_bms_ble_ns
from .. import CONF_JBD_BMS_BLE_ID, JBD_BMS_BLE_COMPONENT_SCHEMA, jbd_bms_ble_ns

DEPENDENCIES = ["jbd_bms_ble"]

Expand All @@ -19,7 +19,7 @@

JbdButton = jbd_bms_ble_ns.class_("JbdButton", button.Button, cg.Component)

CONFIG_SCHEMA = JBD_BMS_BLE_BLE_COMPONENT_SCHEMA.extend(
CONFIG_SCHEMA = JBD_BMS_BLE_COMPONENT_SCHEMA.extend(
{
cv.Optional(CONF_RETRIEVE_HARDWARE_VERSION): button.BUTTON_SCHEMA.extend(
{
Expand All @@ -34,7 +34,7 @@


async def to_code(config):
hub = await cg.get_variable(config[CONF_JBD_BMS_BLE_BLE_ID])
hub = await cg.get_variable(config[CONF_JBD_BMS_BLE_ID])
for key, address in BUTTONS.items():
if key in config:
conf = config[key]
Expand Down
2 changes: 1 addition & 1 deletion esp32-ble-example.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ jbd_bms_ble:
update_interval: 2s

button:
- platform: jbd_bms
- platform: jbd_bms_ble
jbd_bms_ble_id: bms0
retrieve_hardware_version:
name: "${name} retrieve hardware version"
Expand Down

0 comments on commit d6e6288

Please sign in to comment.