Pepper Computer RS232 SMADC1Init Syntax, Input Port number of module to initialise, From 0 to

Models: RS485 RS232

1 320
Download 320 pages 36.43 Kb
Page 251
Image 251
E_BMODE
SUCCESS or

Chapter 5 Analog Modules

SMART I/O User’s Manual

 

 

 

 

 

 

 

 

 

 

5.4.8.2SMADC1Init Syntax

error_code SMADC1Init(u_int8 PortNr);

Description

This function initialises the SM-ADC1 Module on port PortNr, and: - tests the module’s ID

- test the module’s sub-ID for the determination of bipolar or unipolar operation (voltage/current input)

- reads the conversion table held in EEPROM - allocates space for the fetched resources

Input

Port number of module to initialise

u_int8 PortNr

 

(from 0 to 10)

Output

 

5

error_code

Example

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).

RetVal = SMADC1Init(0);

 

 

 

 

October 01, 1996

©1996 PEP Modular Computers GmbH

Page 5 - 95

 

 

Page 251
Image 251
Pepper Computer RS232, RS485 user manual SMADC1Init Syntax, Input Port number of module to initialise, From 0 to