PrbsConfiguration constructor
- required BinaryPolynomial polynomial,
- BigInt? seed,
Creates a custom PRBS configuration.
Implementation
PrbsConfiguration({
required BinaryPolynomial polynomial,
BigInt? seed,
}) : lfsrDescriptor = LfsrDescriptor(polynomial),
seed = seed ?? ((BigInt.one << polynomial.degree) - BigInt.one) {
if (this.seed <= BigInt.zero ||
this.seed >= (BigInt.one << lfsrDescriptor.width)) {
throw RohdHclException('PRBS seed ${this.seed} must be non-zero and fit '
'in ${lfsrDescriptor.width} bits.');
}
}