Struct stm32_hal2::crc::Polynomial [−][src]
pub struct Polynomial(_);
Expand description
A CRC polynomial.
The STM32H7 CRC unit only supports odd polynomials, and the constructors
will check to ensure the polynomial is odd unless the _unchecked
variants
are used.
Even polynomials are essentially never used in CRCs, so you most likely don’t need to worry about this if you aren’t creating your own algorithm.
A polynomial being even means that the least significant bit is 0
in the polynomial’s normal representation.
Implementations
Create a 7-bit polynomial. Returns an error if the polynomial passed has the MSB set or is even.
Create an 8-bit polynomial. Returns an error if the polynomial passed is even.
Create a 16-bit polynomial. Returns an error if the polynomial passed is even.
Create a 32-bit polynomial. Returns an error if the polynomial passed is even.
Create a 7-bit polynomial. If the polynomial passed is even the CRC unit will give incorrect results.
Create an 8-bit polynomial. If the polynomial passed is even the CRC unit will give incorrect results.
Create a 16-bit polynomial. If the polynomial passed is even the CRC unit will give incorrect results.
Create a 32-bit polynomial. If the polynomial passed is even the CRC unit will give incorrect results.
Trait Implementations
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.