| Byte 1 | Byte 0 | Bytes +-------------------------------+-------------------------------+ | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | Bits +---------------------------------------------------------------+ <-----------Year-----------> <----Month----> <-------Day-------> Date
| 149 | // +---------------------------------------------------------------+ |
| 150 | // <-----------Year-----------> <----Month----> <-------Day-------> Date |
| 151 | uint16_t ProDOS_PackDate ( int year, int month, int day ) |
| 152 | { |
| 153 | uint16_t date = 0 |
| 154 | | ((year & 0x7F) << 9) |
| 155 | | ((month & 0x0F) << 5) |
| 156 | | ((day & 0x1F) << 0) |
| 157 | ; |
| 158 | return date; |
| 159 | } |
| 160 | |
| 161 | // | Byte 1 | Byte 0 | Bytes |
| 162 | // +---------------------------------------------------------------+ |
no outgoing calls
no test coverage detected