Saturn: initial support. (#612)

This commit is contained in:
Sergey Dvodnenko
2022-05-22 15:09:13 +03:00
committed by GitHub
parent e1a58541c0
commit 2bc233b851
9 changed files with 1326 additions and 2 deletions

8
cd.h
View File

@@ -39,7 +39,15 @@ typedef struct
uint8_t f;
} msf_t;
#define BCD(v) ((uint8_t)((((v)/10) << 4) | ((v)%10)))
typedef int (*SendDataFunc) (uint8_t* buf, int len, uint8_t index);
inline int FindIndexInTOC(toc_t* toc, int lba)
{
int index = 0;
while ((toc->tracks[index].end <= lba) && (index < toc->last)) index++;
return index;
}
#endif