type.h 434 B

12345678910111213141516
  1. #ifndef TYPE_H
  2. #define TYPE_H
  3. /* Instead of using 'chars' to allocate non-character bytes,
  4. * we will use these new type with no semantic meaning */
  5. typedef unsigned int u32;
  6. typedef int s32;
  7. typedef unsigned short u16;
  8. typedef short s16;
  9. typedef unsigned char u8;
  10. typedef char s8;
  11. #define low_16(address) (u16)((address) & 0xFFFF)
  12. #define high_16(address) (u16)(((address) >> 16) & 0xFFFF)
  13. #endif