obspy.io.rg16.util._read_bcd

_read_bcd(fi, length, left_part)[source]

Interprets a byte string as binary coded decimals.

See: https://en.wikipedia.org/wiki/Binary-coded_decimal#Basics

Parameters:
  • fi A buffer containing the bytes to read.
  • length (int or float) number of bytes to read.
  • left_part (bool) If True, start the reading from the first half part of the first byte. If False, start the reading from the second half part of the first byte.