fit-0.5: FIT file decoder

Safe HaskellNone
LanguageHaskell2010

Fit.Internal.Numbers

Contents

Description

Little-endian and big-endian parsers for signed and unsigned integers, and for single-precision and double-precision floating point numbers.

The parsers are tagged for endianness using the tools in Fit.Internal.Architecture.

Synopsis

Little-endian parsers

Big-endian parsers

Helpers

nByteIntLe :: (Integral a, Bits a) => Int -> Parser a Source

Parse n bytes and interpret them as a little-endian integer. The caller must ensure that the returned type is the correct size for the number of bytes parsed.

nByteIntBe :: (Integral a, Bits a) => Int -> Parser a Source

Parse n bytes and interpret them as a big-endian integer. The caller must ensure that the returned type is the correct size for the number of bytes parsed.