elevator makes things on it get stuck

I have a simple platform that goes up and down. I have rolling balls in my game and when the ball rolls on it, most of the time its ok. However sometimes the ball sorta gets stuck and very slowly slides to the right instead of rolling to the right.
Does anyone know what might cause something like this?

The platform is a simple box polygon, body is kinematic and given a fixed velocity that only changes when it reaches the top or bottom of its up-down cycle.

The ball is a circle shape with high friction, 5 density, no bounciness and has no external forces applied to it outside of the physics engine.
Maybe it has something to do with the simulation. You may need to add more position or velocity iterations or change the time step. From the Box2D manual:
Quote:
The world class is used to drive the simulation. You specify a time step and a velocity and position iteration count. For example:

float32 timeStep = 1.0f / 60.f;
int32 velocityIterations = 10;
int32 positionIterations = 8;
myWorld->Step(timeStep, velocityIterations, positionIterations);

...you should use a fixed time step. By using a larger time step you can improve performance in low frame rate scenarios. But generally you should use a time step no larger than 1/30 seconds. A time step of 1/60 seconds will usually deliver a high quality simulation.

The iteration count controls how many times the constraint solver sweeps over all the contacts and joints in the world. More iteration always yields a better simulation. But don't trade a small time step for a large iteration count. 60Hz and 10 iterations is far better than 30Hz and 20 iterations.


Another option is that the platform is too thin so you may need to change its dimensions so that the ball won't accidentally go through it.
My itterations are the ones given in that suggestion. The platform itself is .5 thick. The ball sits on it nicely but just seems to have some strange force applied that sticks it to the platform.

Original thread: https://box2d.org/forum/viewtopic.php?t=6787