summaryrefslogtreecommitdiff
path: root/lib/fatfs/integer.h
diff options
context:
space:
mode:
authorhathach <[email protected]>2018-05-17 15:55:41 +0700
committerhathach <[email protected]>2018-05-17 16:04:15 +0700
commit7030d64a95138482c2537f3a1280c94ce36a3c10 (patch)
tree2ad27bd8d1e3a009adc70db7ccb424bf1311ec9d /lib/fatfs/integer.h
parentb5de2595d3765681a0ad7758758468878f1c3854 (diff)
rename vendor to lib
Diffstat (limited to 'lib/fatfs/integer.h')
-rw-r--r--lib/fatfs/integer.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/lib/fatfs/integer.h b/lib/fatfs/integer.h
new file mode 100644
index 000000000..f34f56d92
--- /dev/null
+++ b/lib/fatfs/integer.h
@@ -0,0 +1,36 @@
+/*-------------------------------------------*/
+/* Integer type definitions for FatFs module */
+/*-------------------------------------------*/
+
+#ifndef _INTEGER
+#define _INTEGER
+
+#ifdef _WIN32 /* FatFs development platform */
+
+#include <windows.h>
+#include <tchar.h>
+
+#else /* Embedded platform */
+
+/* These types must be 16-bit, 32-bit or larger integer */
+typedef int INT;
+typedef unsigned int UINT;
+
+/* These types must be 8-bit integer */
+typedef unsigned char UCHAR;
+typedef unsigned char BYTE;
+
+/* These types must be 16-bit integer */
+typedef short SHORT;
+typedef unsigned short USHORT;
+typedef unsigned short WORD;
+typedef unsigned short WCHAR;
+
+/* These types must be 32-bit integer */
+typedef long LONG;
+typedef unsigned long ULONG;
+typedef unsigned long DWORD;
+
+#endif
+
+#endif