Adlink AmITX-IB-I Uživatelský manuál Strana 69

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 82
  • Tabulka s obsahem
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků
Zobrazit stránku 68
Super IO Programming Guide 57
AmITX-IB-I
A.2 Program GPIO Function to Input
// before SIO programming, must enter config mode. //
SIOEnterConfig(); Enter SIO configure mode.
// bIndex = 07h as logical device selection register.
// bValue = 07h as logical device number (QM67 uses
GPIO 6)
SIOWrite(0x07, 0x07); Select to Logical Device 7
// bIndex = F4h as control register
// bValue = FFh as input enabled.
SIOWrite(0xF4, 0xFF); set all GPI/O to input
Read back GPIO Input Status
// bIndex = F5h as input register.
bValue = SIORead(0xF5); read back input register
// bValue = GPI/O input status.
// after SIO programming, must exit config mode. //
SIOExitConfig(); Exit SIO configure mode.
Zobrazit stránku 68
1 2 ... 64 65 66 67 68 69 70 71 72 73 74 ... 81 82

Komentáře k této Příručce

Žádné komentáře