Motor and sensor

Swaggydogy:
first of all I really sorry Robin2, i have make all clear to the original topic and it's make all the other comment useless...

What is worse: I for one, subscribed to this topic already, DIDN'T EVEN NOTICE THIS until it was mentioned in the comments.

So you're providing new information, but quite a few of the people that actually try to offer help simply won't see it this way. I'm reading NEW replies which is where I expect to find new information, not going back in threads to see whether there happens to be changes to those posts.

OK now I've read the OP again, and it raises indeed more questions than it answers.
What is this sensor, really? Code suggests PIR sensor but those won't detect a metal pillar, they detect movement of warm objects such as people and other warm-blooded animals, cars, etc.
How do you stop (and hold) the motor and platform at the correct point? Just cutting power won't make it stop there and then, just slow down gradually until it comes to a stop.