Files
nibbles/nibble.h
2017-07-24 17:13:16 -04:00

16 lines
331 B
C

#include <stdint.h>
#include <stdlib.h>
#include <string.h>
// struct for sizeof info
typedef struct { short internal[10]; } bcd;
bcd bcd_zeros();
bcd bcd_from_8(uint8_t);
bcd bcd_from_16(uint16_t);
bcd bcd_from_32(uint32_t);
bcd bcd_from_64(uint64_t);
uint8_t bcd_digits(bcd);
uint64_t bcd_to_64(bcd);
char* bcd_to_string(bcd);