byte_array

baseband.base.utils.byte_array(pattern)[source] [edit on github]

Convert the pattern to a byte array.

Parameters:
pattern~numpy.ndarray, bytes, int, or iterable of int

Pattern to convert. If a ndarray or bytes instance, a byte array view is taken. If an (iterable of) int, the integers need to be unsigned 32 bit and will be interpreted as little-endian.

Returns:
byte_arrayndarray of byte

With any elements of pattern stored in little-endian order.