Ninebot Scooter / BLE?

Hey folks,

anyone got a clue on how o integrate or read the Ninebot Scooters? They have bluetooth. I would love to couple those with a raspi or esp32/arduino to get a read on charge level. I could then check if it needs charging (say <60) and stop charging if 80<.

Combined with my solar production this would net a nice little greet mobility solution :slight_smile:

The only thing(s) I could find are either years old, no longer or not working,

Any clues are greatly appreciated!
-Chris.

1 Like

With the recent improvements in Bluetooth support within Home Assistant, I’m keeping my fingers crossed that someone will add support for this (similar to the Oral-B integration).

2 Likes

I would love to be able to read my scooters battery percentage in Home Assistant. Anyone had any luck with this?

Hi, has anyone already tested this:
ownbee/ninebot-integration: Ninebot Scooter integration for Home Assistant (github.com)

I’m also waiting eagerly for this moment :stuck_out_tongue:

I had a Niu before, and just managed to get the integration working weeks before getting the Segway (my fault).

Does anyone know if this is either legit or official?

It seems quite robust

Maybe this one is also worth checking

Hi everyone, wanted to share my progress which isn’t perfect but good enough for what I need.

Ownbee’s integration was foked by JoeyGE0 GitHub - JoeyGE0/ninebot-integration: Ninebot Scooter integration for Home Assistant and it works. Unfortunately it doesn’t update the values, but if you disable the integration and re-enable it, it will update the values 1 time. Spook integration from HACS allows for these actions.

Played with this for a bit and came up with the following integration. The premise is this - my scooter is hooked up to a smart plug with power monitoring capability. When the plug turns on (at a specific time in a separate automation), every 20 minutes (not the most efficient code) that the voltage is higher than a specific amount my automation gets triggered. The automation disabled the integration, re-enables it and checks the battery %. If its over 85% it turns off the smart plug. The thing that seems to make this work is when the charger turns on by the smart plug, the scooter connects automatically to BLE, I don’t need to manually turn on the scooter for the integration to connect.

alias: scooter integration charge
description: ""
triggers:
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 20
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 40
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 60
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 80
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 100
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 120
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 140
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 160
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 180
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 200
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 0
      minutes: 220
      seconds: 0
    above: 39.4
    trigger: numeric_state
  - entity_id:
      - sensor.hive_2_power
    for:
      hours: 4
      minutes: 0
      seconds: 0
    above: 39.4
    trigger: numeric_state
conditions: []
actions:
  - action: homeassistant.disable_config_entry
    target: {}
    data:
      config_entry_id: 01JVQV2CB2NHM7S9G4MNW4HYH0
  - delay:
      hours: 0
      minutes: 0
      seconds: 30
      milliseconds: 0
  - action: homeassistant.enable_config_entry
    target: {}
    data:
      config_entry_id: 01JVQV2CB2NHM7S9G4MNW4HYH0
  - delay:
      hours: 0
      minutes: 0
      seconds: 30
      milliseconds: 0
  - choose:
      - conditions:
          - type: is_battery_level
            condition: device
            device_id: 07b5cf786e5672f078b804bf8a90c872
            entity_id: 57f527b8399e253ad7fd73706344503d
            domain: sensor
            above: 85
        sequence:
          - action: switch.turn_off
            metadata: {}
            data: {}
            target:
              entity_id: switch.hive_2
      - conditions:
          - type: is_battery_level
            condition: device
            device_id: 07b5cf786e5672f078b804bf8a90c872
            entity_id: 57f527b8399e253ad7fd73706344503d
            domain: sensor
            below: 85
        sequence: []
mode: single
1 Like

nice!
to update the battery status you need to run homeassistant.disable_config_entry and then homeassistant.enable_config_entry?

how did you get the id? config_entry_id: 01JVQV2CB2NHM7S9G4MNW4HYH0

I use smart plug with power monitoring. When Wattage dropps under ~5W ( scooter is charged ) it will turn the switch off ( turns off the charger ). Then I have a smart button on the wall next to the scooters to turn the switch ON on demand when charging is required.

I want to read the battery status when I arrive home ( my kids mainly ) to send some notification like: Hey your scooter is low, charge it etc…

Using the spook integration. If you go to dev tools and actions and then via the gui when you put in the action to disable integration you can choose the right integration (NB1234) and it will populate the ID for you. You do need to set it up manually the first time by adding the integration and then it should detect your scooter automatically.

1 Like

worked, learned something new today

I am seeing that my battery % seems to update more regularly than my integration disable/enable cycle which is good. I think 20 min cycle is too infrequent to get charging where I want it. And I’m sure there is a better way to have my automation but it seems to work at least.