congratulations ... your setup isn't bad at all as far as the general layout and scaling goes ...
(1) first problem, Ladder File #13 isn't being executed – so add a JSR rung in Ladder File #2 to take care of that ...
(2) change the Time Mode setting to TIMED – since you're not currently using an STI arrangement ...
(3) set the RG bit to 1 ... that will give you an extra decimal place of resolution for your Kc setting and your Ti setting ...
(4) set the Loop Update for 0.50 ... this means that your PID will automatically execute once each half second ... that's usually plenty fast enough for most applications ... note that your present setting of 10.23 seconds is WAY TOO LONG between executions to control most systems ...
(5) set the Output Max for 100 ... since you've got "Limit Output CV" set to NO, your current 0 setting for the Output Max won't be an issue – but it "looks funny" unless you set it to 100 ... plus the "alarm status" bits will come on and give confusing signals if anybody happens to notice them ...
(6) set the "Reset Ti" setting for 0.00 to begin with ... leave this Integral setting turned off until after you make sure that the field output device (the "valve", etc.) is moving in the correct direction (opening or closing) to match the physical setup of your system ... then change the "Reset Ti" setting gradually as you tune the loop ... note that a setting of 0.00 will turn the Integral action OFF ... from there on out, a LARGER value will give LESS Integral action ... a SMALLER value will give MORE Integral action ...
(7) set the "Controller Gain Kc" (the Proportional action) setting for 1.00 to begin with ... your current setting of 3276.7 setting is "wide open" and cannot possibly work correctly that way ... the initial setting of 1.00 should give you a one-to-one relationship between the system's error (how far off target you are) and the output signal (the CV) ... specifically, suppose that you have a 50% setpoint (N50:2 data reading = 8192) - and a 10% input signal (I:7.2 data reading = 1638) ... that means you will have an error of 40% ... with the "getting started" Kc setting of 1.00, the output (CV) should go to 40% (N7:0 data reading = 6553) ... use this experimental method to make sure that the output device is tracking in the proper direction (opening or closing) for your system (and to double-check your scaling) ... if the direction is backwards change the Control Mode setting from "E=SP-PV" to "E=PV-SP" ... that will reverse the direction of the PID's output – and move the output field device in the opposite direction ...
(8) you currently have the "Setpoint MAX" setting at 0 ... that means that you are NOT letting the PID perform "setpoint scaling" ... that is PERFECTLY OK – since your input module is already set up for "Scaled for PID" operation ... also the rest of your code seems to accurately take your "non-setpoint-scaling" approach into consideration ... specifically, you're using SCPs to properly scale the operator's setpoint entries into a range of 0 to 16383 before presenting the value to the PID at N50:2 ... feel free to leave the Setpoint MAX setting at 0 ... just be aware that many (most?) other people who come behind you are going to have to "read up" on that method – because it's not all that common ...
the steps listed above should get the PID "operating" ... in other words, it should start looking at the input signal - and looking at the setpoint value – and then calculating an output signal once each half second ... specifically, a changing input signal should cause the PID to drive the output field device in the proper direction ... this (in and of itself) is a cause for celebration ...
now for the hard part – the tuning ...
set up a Trend to graph the PV, the SP, and the CV signals ... and then start tweaking the values of Kc and Ti ... personally I've got NOTHING against using some Derivative action if it will help – but it's hard to tell you how to proceed with that particular setting without knowing a LOT more about the characteristics of your system – and the "tuning goals" you're trying to achieve ... survival tip: just leave the "Rate Td" setting at 0.00 – the way most other people do – and get on with your life ...
if you've never tried tuning a PID loop before, the best I can do for you from where I sit is to recommend that you read the following old thread just FOR STARTERS ... my distinguished colleague Peter Nachtwey will undoubtedly be along soon and give you some more detailed pointers ... he's a lot better than I am at mathematically calculating which component (P, I, or D) to change - based on what you can tell him about the characteristics of your system ... hopefully the material I've linked below will at least give you a starting point ... note that both of the posts are in the same thread - but be sure to read them both ...
http://www.plctalk.net/qanda/showthread.php?postid=11761#post11761
http://www.plctalk.net/qanda/showthread.php?p=11874&postcount=9
if you're patient and the system is safe to experiment with, you'll eventually get the hang of it ... if it fights you, do a screen dump of the Trend graph and post it here ... we'll see if we can help you along ...
disclaimer: I'm writing this in between other projects – and I wouldn't be at all surprised if I've made a few typographical errors along the way ... if so, I apologize in advance ... please post again and ask about anything that looks completely crazy ... I'll be glad to try again ...
I wish you success with your project – and peace for you and the good people in your part of the world ...