Pepper-computer Modular Computers RS485 Uživatelský manuál Strana 173

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 320
  • Tabulka s obsahem
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků
Zobrazit stránku 172
SMART I/O Users Manual
©1996 PEP Modular Computers GmbHMarch 12, 1996 Page 5 - 17
5
Chapter 5 Analog Modules
5.1.8.2 SMDAD1Init
Syntax
error_code SMDAD1Init(u_int8 PortNr);
Description
This function initializes the resources needed to use the SM-DAD1 on port
PortNr, including:
- testing of the SM-Module ID;
- reading the factory-set conversion table held in the EEPROM;
- setting the ADC to bipolar mode and the DAC to unipolar mode;
- fetching the resources.
Input
u_int8 PortNr
SM-Port number to initialize
(from 0 to 10)
Output
error_code SUCCESS or
E_BMODE if wrong or no module
E_MEMFUL if no memory resources available
or standard OS-9 error code (refer to the OS-9
Technical Manual Error Codes Section).
Example
RetVal = SMDAD1Init(0);
Note
If the same SM-DAD1 Module is to be accessed from different tasks, the
user must make sure that the actual output status is ensured by using for
example, semaphores within OS-9.
Zobrazit stránku 172
1 2 ... 168 169 170 171 172 173 174 175 176 177 178 ... 319 320

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

Žádné komentáře