#pir2Data.py A45

import pir2A

#pir2A.g_ioDeviceArray

#id: id number beginning with 0 (unique)
#ioCode: AorC followed by 3 digits (unique)
#nameDevice: PiR2 device name (unique)
#ACU: Acquire/Control/Undefined
#enabledCode: E if enabled, otherwise Null string
#presentUsable: P if present, otherwise Null string
#IXD: Internal, External, Data (software)
#unitsUsed: for this device (Value is always a number)
#valuePrevious: value previously read (or written)
#sensorInterval: number (in milliseconds) time between readings
#logInterval: number (in milliseconds) time between successive logs
#atTime: time of the subsequent reading (when supplied by the owner)
#KER: time period to Keep Event Records (some records are valuable)

pir2A.g_numioDevices=24

#define g_ioDeviceArray initially and its elements but does not say "global"
pir2A.g_ioDeviceArray=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23]
i="|id|0000| |ioCode|A001| |nameDevice|procTemp| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|I| |unitsUsed| C|"
i=i+" |valuePrevious|33.4| |sensorInterval|1000| |logInterval|60000| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[0]=i
i="|id|0001| |ioCode|A002| |nameDevice|pushButton| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|X| |unitsUsed| 0/1|"
i=i+" |valuePrevious| Down| |sensorInterval|1000| |logInterval|60000| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[1]=i
i="|id|0002| |ioCode|A003| |nameDevice|pir2OnLine| |ACU|A|"
i=i+" |enabledCode|| |presentUsable|P| |IXD|D| |unitsUsed| msec|"
i=i+" |valuePrevious|60000| |sensorInterval|3600000| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[2]=i
i="|id|0003| |ioCode|A004| |nameDevice|piArea| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|D| |unitsUsed|na|"
i=i+" |valuePrevious|This_Room| |sensorInterval|3600000| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[3]=i
i="|id|0004| |ioCode|C001| |nameDevice|redLED| |ACU|C|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|X| |unitsUsed| On|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|60000| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[4]=i
i="|id|0005| |ioCode|A005| |nameDevice|fromOwner| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|D| |unitsUsed|na|"
i=i+" |valuePrevious|piRoom:any_Room| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[5]=i
i="|id|0006| |ioCode|A006| |nameDevice|piIP| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|D| |unitsUsed|na|"
i=i+" |valuePrevious|This_Room| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[6]=i
i="|id|0007| |ioCode|A007| |nameDevice|audioTV| |ACU|C|"
i=i+" |enabledCode|E| |presentUsable|N| |IXD|X| |unitsUsed|na|"
i=i+" |valuePrevious|Warning.wav| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[7]=i
i="|id|0008| |ioCode|A008| |nameDevice|logLength| |ACU|A|"
i=i+" |enabledCode|| |presentUsable|N| |IXD|D| |unitsUsed|bytes|"
i=i+" |valuePrevious|5000| |sensorInterval|na| |logInterval|3600000| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[8]=i
i="|id|0009| |ioCode|A009| |nameDevice|readingsDt| |ACU|A|"
i=i+" |enabledCode|| |presentUsable|N| |IXD|D| |unitsUsed|msec|"
i=i+" |valuePrevious|10000| |sensorInterval|na| |logInterval|10000| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[9]=i
i="|id|0010| |ioCode|C002| |nameDevice|toOwner| |ACU|C|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|D| |unitsUsed|na|"
i=i+" |valuePrevious|na| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[10]=i
i="|id|0011| |ioCode|A010| |nameDevice|piSN| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|| |IXD|I| |unitsUsed|na|"
i=i+" |valuePrevious|na| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[11]=i
i="|id|0012| |ioCode|A011| |nameDevice|taskSleepDt| |ACU|A|"
i=i+" |enabledCode|| |presentUsable|| |IXD|D| |unitsUsed|msec|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[12]=i
i="|id|0013| |ioCode|A012| |nameDevice|taskSleepToday| |ACU|A|"
i=i+" |enabledCode|| |presentUsable|| |IXD|D| |unitsUsed|msec|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[13]=i
i="|id|0014| |ioCode|A013| |nameDevice|taskSleepPC| |ACU|A|"
i=i+" |enabledCode|| |presentUsable|| |IXD|D| |unitsUsed| PC|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[14]=i
i="|id|0015| |ioCode|A014| |nameDevice|ambTemp| |ACU|A|"
i=i+" |enabledCode|| |presentUsable|| |IXD|X| |unitsUsed| C|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[15]=i
i="|id|0016| |ioCode|C003| |nameDevice|ambHeat| |ACU|C|"
i=i+" |enabledCode|| |presentUsable|| |IXD|X| |unitsUsed| 0/1|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[16]=i
i="|id|0017| |ioCode|A015| |nameDevice|lastRecId| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|D| |unitsUsed|na|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[17]=i
i="|id|0018| |ioCode|A016| |nameDevice|logA| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|D| |unitsUsed|na|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[18]=i
i="|id|0019| |ioCode|A017| |nameDevice|piOS| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|D| |unitsUsed|na|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[19]=i
i="|id|0020| |ioCode|A018| |nameDevice|digIn0| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|I| |unitsUsed| 0/1|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[20]=i
i="|id|0021| |ioCode|C0004| |nameDevice|digOut0| |ACU|C|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|I| |unitsUsed| 0/1|"
i=i+" |valuePrevious|0| |sensorInterval|na| |logInterval|0| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[21]=i
i="|id|0022| |ioCode|A0019| |nameDevice|tempId00| |ACU|A|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|X| |unitsUsed| C|"
i=i+" |valuePrevious|0| |sensorInterval|120000| |logInterval|120000| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[22]=i
i="|id|0023| |ioCode|C0005| |nameDevice|imageTV| |ACU|C|"
i=i+" |enabledCode|E| |presentUsable|P| |IXD|I| |unitsUsed| na|"
i=i+" |valuePrevious|0| |sensorInterval|120000| |logInterval|120000| |atTime|| |KER|0|"
pir2A.g_ioDeviceArray[23]=i
#define global fileArray initially and its elements but does not say "global"

pir2A.g_fileArray=[0,1,2,3,4,5]
pir2A.g_fileArray[0]="/home/pi/Desktop/PiR2/files/PiR2_Log"
pir2A.g_fileArray[1]="/home/pi/Desktop/PiR2/files/PiR2_Log.txt"
pir2A.g_fileArray[2]="/home/pi/Desktop/PiR2/files/commandResult.txt"
pir2A.g_fileArray[3]="/home/pi/Desktop/PiR2/audio/"
pir2A.g_fileArray[4]="/home/pi/Downloads/PiR2_Control_"
#                                +piSN+"_txt.html"
pir2A.g_fileArray[5]="/home/pi/Desktop/PiR2/images/"


#end pir2Data.py A44