// SPDX-License-Identifier: MIT pragma solidity ^0.8.20; /// @title Tenhertz HertzMiner, the calls a miner, relayer or reader needs. /// @notice One round per Elysium block (ArbSys(100).arbBlockNumber()). A solution for round r is a nonce with /// uint256(keccak256(abi.encode(seed, miner, r, nonce))) < target, submitted while r <= block <= r + 32. /// Practice Field on Elysium (99901): 0x1CC87a4D72500EF0E30957e75f7fd5837B361a01 interface IHertzMiner { event Improved(uint256 indexed round, address indexed miner, uint256 hash); event Settled(uint256 indexed round, address indexed winner, uint256 hash, uint256 reward); // reads function currentRound() external view returns (uint256); function challengeFor(uint256 round) external view returns (bytes32 seed, uint256 target); function bestOf(uint256 round) external view returns (address winner, uint256 best, bool closed, bool settled); function reward(uint256 round) external view returns (uint256); function genesisRound() external view returns (uint256); function epoch() external view returns (uint256); function epochOf(uint256 round) external view returns (uint256); function target() external view returns (uint256); function seed() external view returns (bytes32); function mined(address miner) external view returns (uint256); function roundsWon(address miner) external view returns (uint256); function totalMined() external view returns (uint256); function totalOwed() external view returns (uint256); function token() external view returns (address); // writes function submit(address miner, uint256 round, uint256 nonce) external returns (uint256 hash); function submitMany(address[] calldata miners, uint256[] calldata rounds, uint256[] calldata nonces) external returns (uint256 accepted); function settle(uint256[] calldata rounds) external; function claim(address to) external returns (uint256 amount); function claimWithSig(address miner, address to, uint256 deadline, bytes calldata sig) external returns (uint256 amount); }