sio_adam6060 module

filename:sio_adam6060.py
author:roar@tordivel.no
requirements:Scorpion 10.2
copyright:2000-2015 Tordivel AS
license:Tordivel AS’ Scorpion Python Module License

Standard Scorpion IO interface implementation for ADAM-6060

1.0.0.7, 23nov2015, RL:
  std autodoc header
1.0.0.6, 10sep2015, RL:
  doWriteByte handles 6..8 bits
1.0.0.5, 10jun2015, RL:
  added ADAM-6000 driver
1.0.0.4, 08may2014, RL:
  handles range(8,8) DO/DI
1.0.0.3, 06jun2013, RL:
  added configurable timeout
  added reconnect
1.0.0.2, 09apr2012, RL:
  fixed doWriteByte - WriteRelay return
1.0.0.1, 27mar2012, RL:
  improved error handling
1.0.0.0, 25mar2012, RL:
  initial
class sio_adam6060.ADAM6060(hWnd, name, ip='10.0.0.1')

Bases: object

ADAM 6060 SIO interface

getCaps()

get capabilities tuple (nDI,nDO)

connect()
reconnect()
diReadBit(byteno, bitno)

read input bit - return (errcode,value)

doWriteBit(byteno, bitno, value)

write output bit - return errcode

doReadBit(byteno, bitno)

read output bit - return (errcode,value)

diReadByte(byteno)

read input byte - return (errcode,value)

doWriteByte(byteno, value)

write output byte - return errcode

doReadByte(byteno)

read output byte - return (success,value)

getConfig()

return config as string - optional

setConfig(value)

set config from string - optional

configure()

launch configuration dialog if any. hWnd is parent window handle - optional

sio_adam6060.CreatePlugin(hWnd, name='')

Scorpion Plugin Stub - Required