Back to godoc.org

Package src

v0.5.0
Latest Go to latest

The highest tagged major version is .

Published: Feb 3, 2020 | License: MIT | Module: github.com/pegnet/pegnet

Index

Variables

var HashRateLimit ratelimit.Limiter

func DifficultyAtFromList

func DifficultyAtFromList(spot int, list []*opr.UniqueOPRData) (index int, diff uint64)

DifficultyAt will return the difficulty at the spot or the closest spot to it if we don't have enough. So if you target 50, and we only have 4, it will return the 4th.

func Execute

func Execute()

func RandomDifficulty

func RandomDifficulty() uint64

func UpdateHashRate

func UpdateHashRate(cmd *cobra.Command, args []string)

type PerBlock

type PerBlock struct {
	Height          int
	Duration        time.Duration
	TotalHashes     uint64
	NonceAggregator *opr.NonceRanking
}

func (*PerBlock) CsvHeader

func (b *PerBlock) CsvHeader() []string

func (*PerBlock) DifficultyAt

func (b *PerBlock) DifficultyAt(spot int) (index int, diff uint64)

DifficultyAt will return the difficulty at the spot or the closest spot to it if we don't have enough. So if you target 50, and we only have 4, it will return the 4th.

func (*PerBlock) Records

func (b *PerBlock) Records(target int, minDiff uint64) []string

func (*PerBlock) String

func (b *PerBlock) String() string

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier