Advertisement

Cryptocurrencies and crypto mining has, once again, been all the rage for the last couple of years. Thus, it should come as no surprise that Thomas Prior has developed a custom integration for Home Assistant that pulls information from the Ethereum mining pool ethermine.org and exposes it as a sensor to our favourite home automation tool. Ever wanted to recreate Gilfoyle’s alert for when it isn’t profitable to mine crypto, while simultaneously driving your co-workers mad? Now you can.

YouTube video

While I do consider myself technically well-versed, I can’t claim to know much about cryptocurrencies. Mainly because I am firmly in the anti-crypto camp. While I favour the decentralized aspect, I do not appreciate the killing the planet part of crypto mining (before you even think about it, there is no way of convincing me otherwise using dodgy statistics).

Advertisement

Installing the EthermineInfo custom integration

As with most other custom integration, and I’m starting to sound a lot like a broken record at this point, the EthermineInfo Home Assistant integration is best installed using HACS (Home Assistant Community Store). If you haven’t added it to your Home Assistant yet, I highly suggest you do so by following the steps described on the website. Especially, if you are using any custom integration, unofficial Lovelace cards, or themes. HACS will take care of keeping everything up to date. Simply add the following repository to HACS and you are ready to go:

https://github.com/ThomasPrior/EthermineInfo

Configuring the EthermineInfo custom integration

Once installed, you can enter the following YAML to set up a new sensor using the EthermineInfo custom integration:

sensor:
  - platform: ethermineinfo
    miner_address:
    currency_name:
    name_override:

The miner address, which is the address of your ethermine.org miner, is a string of 42 characters (beginning with 0x) or 40 characters (with the 0x removed). The currency name dictates the currency you would like your unpaid balance to be converted to. This can be ETH (Etherium), USD (United States Dollar), BTC (Bitcoin), EUR (Euro), CNY (Chinese Yuan), or RUB (Russian Ruble). The final parameter, which is optional, can be set to override the miner’s address with any string, for easy identification.

Advertisement

What the EthermineInfo custom integration tracks

Ther EthermineInfo custom integration can track the following data using the etherinfo.org API: Unpaid balance, unconfirmed balance, reported hash rate, average hash rate, current hash rate, valid shares, invalid shares, stale shares, active workers, and balance in local currency. It also monitors the following data on payouts: Paid on, amount, transaction hash, value in local currency.

The ApexCharts Card being used to display Etherium information from ethermine.org
Various graphs created using the ApexCharts Card
The Mini Graph Card being used to display Etherium information from ethermine.org
Various graphs created using the Mini Graph Card

This data is, in my opinion, best displayed in the form of a graph. You could use the default History Graph Card, but if you have any sense of style, you will want to configure your Home Assistant dashboard using the Mini Graph Card or ApexCharts Card.

Advertisement
Liam Alexander Colman, the author and maintainer of Home Assistant Guides.

About Liam Alexander Colman

Liam Alexander Colman has been using Home Assistant for various projects for quite some time. What started of with a Raspberry Pi quickly became three Raspberry Pis and eventually a full-blown server. I now use Unraid as my operating system and Home Assistant happily runs in a Docker container. My personal setup includes many Zigbee devices as well as integrations with existing products such as my Android TV box. Read on to find out more on how I got started with Home Assistant.

Leave a comment

Advertisement