Kontron KTA55-pITX Manual do Utilizador Página 18

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 25
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 17
KTD-S0043-A Page 15 GPIO Interface
KTA55/pITX Software Guide
7 GPIO Interface
The GPIO part is a component of the AMD
®
Hudson-E1 Controller Hub. Each GPIO pin has its own control
register (memory-mapped, memory base address 0xFED80100). For customer usage only GPIO0 to GPIO7
are available - access to other GPIO pins is forbidden and can damage the board. Under a 16 bit environ-
ment register access is possible but very complex except you use the free Open Watcom C/C++ compiler
(example compiled with version 1.9).
The following picture shows the register structure (8 bit wide):
Open Watcom C/C++ compiler settings:
Target Environment: DOS - 32-bit
Image Type: PMODE/W Executable [.exe]
7.1 DOS Example
#include <stdio.h>
#include <conio.h>
#define u8 unsigned char
#define GPIO_BASE_ADDR 0xFED80100
#define MAX_GPIO 8
#define PU_SHIFT 3
#define PD_SHIFT 4
#define DIR_SHIFT 5
#define OUT_SHIFT 6
#define IN_SHIFT 7
Vista de página 17
1 2 ... 13 14 15 16 17 18 19 20 21 22 23 24 25

Comentários a estes Manuais

Sem comentários