The M-series PLC does not automatically queries the ADC ports unless you program it specifically to do so. So in order read an ADC value from AD input #n, you need to execute the ADC(n) function periodically to retrieve the readings. That can be easily achieved using a clock pulse and execute the ADC(n) function periodicaly.
Once the ADC(n) function is executed, you can then use the "RVS0Bnn" command to read the ADC data from its internal registers. Alternatively, if you have read the values into DM
- variable by executing e.g.
DM[10] = ADC(1)
then you can use the host link command "RVDxxxx" to read the value from the DM.
We have a sample VB6 program that you can download from our website to assist you in writing your comm routine with work with the PLC, as follow:
http://www.tri-plc.com/applications/VBsample.htm