kamran,
I don't know of any software for detecting loose connections at the plc. On the input side you could easily write your own. SET a minimum value timer to detect an input rising ( say use pulse rising realy) If the input is lees than minimum time flag it to check the cct.
Have a play with this concept and you'll be able to refine it to filter all sorts of issues
Let us know how you go
Don