Helium Blockchain custom component

Thanks for this! I came here to link to your forum post on reddit about phone notifications and after I posted it I saw you already shared how to do it. It’s working great.

I’m looking to try to do the same thing, have you had any luck with this?

I couldn’t seem to make this work adding file to automations.yaml via file editor. Then once inside the automations UI and edit YAML from there it worked. << posting this in case anyone has similar issue.

Thanks for this component!

This is awesome. Thanks so much.

Thanks for this brilliant custom component!

Although I have to say that I’m now obsessing at looking at my Apple Watch all the time :laughing:

See the bottom left complication showing Wallet total and Wallet today. I set the limit to 10 HNT as I stake it when it reaches 10.

Watch Face

4 Likes

thx for the tutorial :slight_smile:

Awesome example of showing on Apple Watch!

2 Likes

I’m unable to get more decimals for my wallet.

This configuration create a sensor (wallet) with only 2 decimals:

sensor:

  • platform: helium
    wallets:
    • 14MR1uu8vJERJs32UTRe6Y3TCyFRecTgAiVkkc5aLxeNJmRx9C1

How can I get more decimals?

thank you

The helium_wallet_today sensor didn’t seem to be returning the correct value (either were the weekly or monthly), so I switched the automation to just use the wallet. I also changed to look at the from and to state values to determine what the reward amount was and it displays that in the notification. You just have to update your wallet Id and device Id for your phone. And when you click the notification, it takes you to heliumtracker.io, you can change this to whatever you want. Works great (when I’m getting rewards, which has been infrequent lately). Thanks @kaylasiemon!

alias: New Helium Rewards
description: ''
trigger:
  - platform: state
    entity_id: sensor.helium_wallet_[WALLET ID GOES HERE]
condition:
  - condition: template
    value_template: '{{ trigger.to_state.state | float > trigger.from_state.state | float }}'
action:
  - device_id: [PHONE DEVICE ID GOES HERE]
    domain: mobile_app
    type: notify
    title: >-
      New Helium Reward {{ ((trigger.to_state.state | float) -
      (trigger.from_state.state | float))|round(5) }} HNT
    message: >-
      Wallet Total: {{
      states('sensor.helium_wallet_[WALLET ID GOES HERE]')
      }} HNT   ${{
      ((states('sensor.helium_wallet_[WALLET ID GOES HERE]')|float)
      * (states('sensor.helium_hnt_oracle_price')|float)) |round(2) }} USD
    data:
      clickAction: https://heliumtracker.io/dashboard
mode: single

If you open up the sensor.py file, you can find the round call and increase from 2 to whatever you want. Just make the change, save the file and restart HA.

/config/custom_components/helium/sensor.py

Line 210, it’s the last parameter of the round function.

Any suggestions on the default precision for rounding of this value (if not 2)…3? 4?

I changed mine to 6.

Hey, just wondering if anybody can help with the utility meter helper?
I have set the 3 entities in my configuration.yml file for today, week and month, however I am unsure how to configure these in the actual utility meter?
Many thanks!



Just wondering if this looks right?

Did you add your wallet in to the configuration as well, example titled “Configure sensors for Helium wallets:”?

1 Like

Yes, like this:-


(sorry I blanked those out, not sure if they are sensitive.)

Does that look ok?

Is there only one section starting with “sensor:”? I added my helium wallet to an existing sensor section.

I think it checks every 15 minutes. Maybe it needs some activity on the wallet also.

Do you see any numbers in Developer > States > filter entities using “wallet”?

Hi,
yes only one sensor section.
I checked the states, (good shout) see below, nothing much showing?
I mean I only have like 0.3 HNT collected over about 4 days, so maybe that is something to do with it?

You may have to wait for a day before daily weekly and monthly shooting to life.

Do you get other values. For example sensor.helium_hnt_oracle_price gives me 9.16.

1 Like