NervesTime.RealTimeClock.BCD (nerves_time v0.4.9)
View SourceConvert between integers and binary-coded decimals (BCD)
BCD is commonly used in Real-time clock chips for historical reasons. See wikipedia.org/wiki/Binary-coded_decimal for a good background on BCD. The BCD implementation here is referred to as "Packed BCD" in the article.
Summary
Functions
Convert a 8 bit integer value to a BCD binary
Convert an 8 bit bcd-encoded value to an integer