BlockDifficultyEpochHashpriceHalving

Mining coins

Section 2 of 11·6 min read

A mining coin is an ERC-20 token with 18 decimals whose price tracks one unit of Bitcoin's production economy. Every market on hashpad.fun is paired against one of them, and every holder reward is paid in one of them.

The catalogue

Symbol Name One unit = Reference price Source Staleness
HASH Hashprice 1 PH/s of SHA-256 hashing for 1 day btcUsd × 144 × (subsidy + avgFeeBtc) / networkPH Coinbase BTC/USD, mempool.space difficulty and fees 6 h
BTC Bitcoin 1 BTC BTC/USD spot Coinbase primary, Kraken or CoinGecko secondary, two-source divergence check 6 h
BLOCK Block reward one block's subsidy + fees btcUsd × (subsidy + avgFeeBtc) Coinbase, mempool.space 6 h
TH ASIC terahash 1 TH/s of current-generation ASIC capacity Hashrate Index ASIC price, $/TH, ≤ 21 J/TH tier curated by the operator 72 h
S21 Antminer S21 Pro one machine, 234 TH/s TH × 234, or the listed unit price if available curated by the operator 72 h
MWH Megawatt-hour 1 MWh, ERCOT North hub day-ahead ERCOT day-ahead settlement curated by the operator 72 h
SATVB Fee rate 1 sat/vB across 1,000,000 vB, i.e. 0.01 BTC per sat/vB of fee rate fastestFee × 1,000,000 sat → USD mempool.space recommended fees 6 h

Coins whose source is curated are priced from a file maintained by the operator that records a source and an as-of date for every figure. The coins page shows a manual badge on them and the API exposes both fields. Prices are stored on-chain as USD × 10^18 per whole coin, under a feed ID of keccak256(symbol).

How the peg holds

Each mining coin has one Uniswap V3 pool against USDG on the 0.30% fee tier with a tick spacing of 60. The PegManager contract owns all of the pool's liquidity and places it in exactly two ranges.

Let t be the feed price expressed as a tick, rounded down to a multiple of 60.

  • Ask: coin only, in the range [t + 60, t + 120). This is where buyers take coin.
  • Bid: USDG only, in the range [t − 60, t). This is where sellers give coin back.

The pool is initialised at tick t itself, so the current price sits in the gap between the two ranges. One tick spacing is about 0.60% of price, so a buy clears at least 0.60% above the rounded feed price before the 0.30% pool fee, and a sell clears at or below the feed price. Nothing trades through the reference.

Seeding. When a coin is registered, the manager mints coin worth $100,000 at the feed price and places all of it in the ask. At a hashprice of $57.97 that is about 1,725 HASH. The bid starts empty because nobody has paid any dollars in yet.

Repricing. The keeper checks every coin every 60 seconds. When the feed tick rounds to a different multiple of 60 than the one the ranges were placed around, or when either side is empty, the keeper calls reprice. The manager burns both ranges, collects whatever they hold, and re-places them around the new t. Every unit of coin the manager holds goes into the new ask. Every dollar the manager holds for that coin goes into the new bid.

Refilling. Buyers drain the ask. When the ask holds less than 50% of the seed amount, the keeper calls refill and the manager mints coin back up to the full seed and re-places the ask.

Dollars are ring-fenced per coin. The manager keeps a usdReserve for each coin, credited only from that coin's bid. HASH sellers are paid from dollars HASH buyers paid in, never from BTC buyers' dollars, and vice versa.

Nothing else supports the price. There is no reserve behind the ask and no redemption. The bid holds only dollars that buyers have already paid in, so a seller is paid only while that bid has depth. Risks covers what this means in practice.

Where prices come from

The keeper computes every catalogue price off-chain once a minute and pushes any price that has moved more than 0.05% to the PriceFeed contract. Feeds are stored as USD × 10^18 per coin.

Hashprice

HASH is the dollar revenue that one PH/s earns in a day at the current difficulty, subsidy, and fee level.

networkPH  = difficulty × 2^32 / 600 / 1e15          # PH/s implied by difficulty at a 600 s block interval
hashprice  = btcUsd × 144 × (subsidy + avgFeeBtc) / networkPH

144 is blocks per day. subsidy is the current block subsidy in BTC, derived from block height. avgFeeBtc is the trailing 144-block mean of total fees per block.

Worked example with representative 2026 inputs:

Input Value
btcUsd $118,000
difficulty 130,000,000,000,000 (130 T)
subsidy 3.125 BTC
avgFeeBtc 0.05 BTC
networkPH = 130e12 × 4,294,967,296 / 600 / 1e15
          = 930,576.25 PH/s                       (≈ 930.6 EH/s)

hashprice = 118,000 × 144 × (3.125 + 0.05) / 930,576.25
          = 53,949,600 / 930,576.25
          = $57.97 per PH/s per day

With those inputs, one HASH is priced at $57.97 and the feed stores 57.97 × 10^18.

The other coins

  • BLOCK = btcUsd × (subsidy + avgFeeBtc). With the inputs above, 118,000 × 3.175 = $374,650.
  • BTC = BTC/USD spot. Coinbase is primary; Kraken or CoinGecko is the independent second source used for the divergence check.
  • SATVB = fastestFee × 1,000,000 sat, converted at spot. At 5 sat/vB and $118,000, 5 × 0.01 BTC × 118,000 = $5,900.
  • TH = the curated $/TH figure for current-generation ASICs at or below 21 J/TH.
  • S21 = TH × 234, unless a listed machine price is available. At $18/TH, 18 × 234 = $4,212.
  • MWH = the ERCOT North hub day-ahead price.

Sanity bound

There is no Chainlink feed on Robinhood Chain. The keeper instead reads BTC/USD from two independent off-chain sources, Coinbase as primary and Kraken or CoinGecko as secondary, and compares them. If they diverge by more than 2%, the keeper halts pushes for HASH, BTC, and BLOCK until they agree again. The check runs inside the keeper, not on-chain.

Halving

The subsidy is never hardcoded. The keeper reads the chain tip height and derives it: 50 BTC halved once per 210,000 blocks. Today that is 3.125 BTC. At height 1,050,000 it becomes 1.5625 BTC, and HASH and BLOCK fall by roughly half in the same minute, since the subsidy is most of what they measure. With the example inputs above and everything else unchanged, hashprice moves from $57.97 to $29.44. This is by design: the coins track what a unit of mining earns, and a halving halves it.

Staleness

Every feed has a staleness limit: 6 hours for HASH, BTC, BLOCK, and SATVB; 72 hours for TH, S21, and MWH. If the keeper has not pushed a price within that window, the feed is stale.

A stale feed makes getPrice revert. Anything that needs the feed price stops: the keeper cannot reprice or refill that coin's peg, and no market can be launched against that coin, because the launch converts its $5,000 and $35,000 caps into coin at the feed. The peg pool itself does not move. It stays where it was last placed and keeps trading at that level, so during a stale window the on-chain price can drift from reality by the full extent of whatever the feed missed. The coins page shows freshness for every coin, and the GET /api/prices endpoint returns a fresh flag.