+#define CH_ESC 27
+
+
+
+/*****************************************************************************/
+/* Definitions for directory reading functions */
+/*****************************************************************************/
+
+
+
+/* CBM FILE TYPES */
+#define CBM_T_DEL 0
+#define CBM_T_SEQ 1
+#define CBM_T_PRG 2
+#define CBM_T_USR 3
+#define CBM_T_REL 4
+#define CBM_T_CBM 5 /* 1581 sub-partition */
+#define CBM_T_DIR 6 /* IDE64 and CMD sub-directory */
+#define CBM_T_VRP 8 /* Vorpal fast-loadable format */
+#define CBM_T_OTHER 5 /* Other file-types not yet defined */
+
+/* CBM FILE ACCESS */
+#define CBM_A_RO 1 /* Read only */
+#define CBM_A_RW 3 /* Read, Write */
+
+struct cbm_dirent {
+ char name[17]; /* File name in PETSCII, limited to 16 chars */
+ unsigned int size; /* Size in 256B blocks */
+ unsigned char type;
+ unsigned char access;
+};