I've had the aircraft in slew mode and lifted it off the ground. Forgot to mention this.
With the spoilers armed (keypress on the keyboard) on touchdown the spoiler handle in the sim will not go to the UP position without interruption because the TQ spoiler handle/potmeter continously sends input to the sim about its posision, just like any other joystick. Then the input from the TQ will fight aginst the aircraft logic that tries to get the handle to UP (0BD0 = 16384) because the TQ handle is delayed. If the servo for the TQ handle were not delayed the sim would constantly get interruption from input TQ/joystick/potmeter every millisecond.
If I look at the spoiler handle in the sim on touchdown it goes to UP, but when the delay time (say 200ms) for the TQservo is over and the TQservo starts to move towards UP the potmeter sends a new command to the sim about its position. The handle in the sim (PMDG737NGX) obey the signal and goes back to match the TQhandle position. The sim logic again commands UP and the TQservo moves a little more towards UP then the potmeter sends its command again and so on. It results in "Spoilers do not arm" caution indicator in the cockpit as the spoiler deploy did not go as expected by the aircraft logic.
And on the ground with spoilers in UP and if you increase throttle the spoilers should go to the DOWN position and they do, but not without interruption from the input from TQ/joystick as potmeter and sim logic gets their wish fullfilled in turns. (Sorry my english is not the best). To explain better first the sim gets its wish fullfilled then the potmeter gets its wish then comes the sim again and then the potmeter. There is no winner in the fight before I manually move the handle the last part of the trip to DOWN :).
Connection is spoiler handle -> potmeter -> BU0836 -> FSUIPC. No other software in between. The servos are controlled by Phidgets Servo Controller card and FS2Phidgets but no input to the simulator from here.
I know about nothing about LUA-scripting yet. But if I can remove the spoiler assignment from FSUIPC and LUA can do the whole job with the spoiler axis with calibration, arming, ignore input if the sim sends a command for spoiler movement. If it can do all this I will certainly look into this scripting.