GBDK 2020 Docs 4.4.0 API Documentation for GBDK 2020

Data Structures | Macros | Typedefs
types.h File Reference
`#include <asm/sm83/types.h>`

Go to the source code of this file.

## Data Structures
union | _fixed

## Macros
#define | OLDCALL
#define | PRESERVES_REGS(...)
#define | NAKED
#define | SFR
#define | AT(A)
#define | NORETURN
#define | NONBANKED
#define | BANKED
#define | CRITICAL
#define | INTERRUPT

## Typedefs
typedef INT8 | BOOLEAN
typedef INT8 | BYTE
typedef UINT8 | UBYTE
typedef INT16 | WORD
typedef UINT16 | UWORD
typedef INT32 | LWORD
typedef UINT32 | ULWORD
typedef INT32 | DWORD
typedef UINT32 | UDWORD
typedef union _fixed | fixed

## Detailed Description

Shared types definitions.

## Macro Definition Documentation

## ◆ OLDCALL

#define OLDCALL

## ◆ PRESERVES_REGS

#define PRESERVES_REGS | ( |  | ... | ) |

## ◆ NAKED

#define NAKED

## ◆ SFR

#define SFR

## ◆ AT

#define AT | ( |  | A | ) |

## ◆ NORETURN

#define NORETURN

## ◆ NONBANKED

#define NONBANKED

## ◆ BANKED

#define BANKED

## ◆ CRITICAL

#define CRITICAL

## ◆ INTERRUPT

#define INTERRUPT

## Typedef Documentation

## ◆ BOOLEAN

typedef INT8 BOOLEAN

TRUE or FALSE.

## ◆ BYTE

typedef INT8 BYTE

Signed 8 bit.

## ◆ UBYTE

typedef UINT8 UBYTE

Unsigned 8 bit.

## ◆ WORD

typedef INT16 WORD

Signed 16 bit

## ◆ UWORD

typedef UINT16 UWORD

Unsigned 16 bit

## ◆ LWORD

typedef INT32 LWORD

Signed 32 bit

## ◆ ULWORD

typedef UINT32 ULWORD

Unsigned 32 bit

## ◆ DWORD

typedef INT32 DWORD

Signed 32 bit

## ◆ UDWORD

typedef UINT32 UDWORD

Unsigned 32 bit

## ◆ fixed

typedef union _fixed fixed

Useful definition for working with 8 bit + 8 bit fixed point values

Use `.w` to access the variable as unsigned 16 bit type.

Use `.b.h` and `.b.l` (or just `.h` and `.l`) to directly access it's high and low unsigned 8 bit values.