Zilog Z80380 Instrukcja Użytkownika Strona 38

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 116
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 37
I/O ADDRESS SPACES C-Compiler Overview
2–4 UM004001-COR1103
ACCCESING I/O ADDRESS SPACE
The Z380 instruction set does not allow indirect acess of the internal I/O address space
through a register.
To acess the I/O adress space use the on-chip peripheral-addresses as operands to the
IN0/OUT0 machine instructions. Variable pointers can not be used to access the internal I/O
address space and address constants must be used.
The recommended usage the I/O adress space is hown in the below example.
typedef volatile unsigned char __INTIO *PBINTIO;
#defineIO_ADDR((PBINTIO)0x0002)
// …
unsigned char ch;
// …
IO_ADDR[0] = ch;// store to I/O address 2
// …
ch = IO_ADDR[0];// load from I/O address 2
// …
Przeglądanie stron 37
1 2 ... 33 34 35 36 37 38 39 40 41 42 43 ... 115 116

Komentarze do niniejszej Instrukcji

Brak uwag