Author Topic: 60 hz frequency and voltage sensing  (Read 7506 times)

cdenk

  • Full Member
  • Posts: 161
  • newbie
    • View Profile
60 hz frequency and voltage sensing
« on: March 15, 2005, 02:50:48 PM »
On a T100MD888, how would I measure the frequency and voltage of 120/240 volt 60 HZ power using the pulse width and ADC features of the PLC. Object would be to set alarms if out of range.  :)

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3171
    • View Profile
    • Internet Programmable PLCs
Re:60 hz frequency and voltage sensing
« Reply #1 on: March 15, 2005, 08:42:45 PM »
You will have to use a 9V AC transformer to lower the voltage to about  9V AC and provide the isolation from the AC supply, then rectify the 9VAC it to give  a DC pulse voltage to feed to the PM1 or PM2 in order to measure the period of the pulses (down to 1 microsecond resolution). Inverse the period value to give very accurate frequency reading.

For the voltage measurement, you will have to feed the rectified DC via a diode to a capacitor to obtain the average voltage, a voltage divider formed by two resistor can be used to divide the voltage down  to 0-5V which can be connected to the PLC analog input for measurement of the voltage.

You do need to calibrate the system to obtain a gain factor that you can use to compute the actual RMS voltage from the analog reading.
Email: support@triplc.com
Tel: 1-877-TRI-PLCS

cdenk

  • Full Member
  • Posts: 161
  • newbie
    • View Profile
Re:60 hz frequency and voltage sensing
« Reply #2 on: July 07, 2005, 05:27:56 AM »
The implementaion of the frequency and voltage sensing individually was stright forward as described, but trying to combine the 2 circuits from one 9 vac (wall wart) and rectifier bridge power supply created a problem, that probably requires an opto-isolator on the frequency side. The frequency side requires the rectifier bridge "+" output to go to the PLC's power in (12 VDC in my case). For voltage side, I prefered the bridge "-" output go to the PLC's ground terminal, assuming the ADC voltage in/output reading is fairly close to linear, then calibration only requires one voltage (120 VAC) checked with a voltmeter, and a simple equation in Basic to correct the readings. Then we have the rectified 9 VAC connected across 12 VDC which just doesn't work.  I have stock of a TIL 111 opto isolator that will try to interface.

support

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3171
    • View Profile
    • Internet Programmable PLCs
Re:60 hz frequency and voltage sensing
« Reply #3 on: July 07, 2005, 08:56:08 AM »
Using an optoisolator is always a good idea when you are interfacing two discretely different power sources.  As long as the optoisolator output is capable of sinking at least 5mA of current it is relatively simple matter to use it to turn on the PLC output. Just connect the collector of the optoisolator's receiver to the PLC's input, and the emitter to the PLC's 0V, and feed the rectified DC voltage to the transmitter side of optoisolator via a current limiting resistor and that's it.
Email: support@triplc.com
Tel: 1-877-TRI-PLCS