Angular velocity problem

Hello, colleagues!
I'm not long ago began to use box2d and had to face with the strange behavior.
My physic body is composed of a square, circle and joint.

I'm trying to move body, set him angular velocity.

Code:
circleBody.SetAngularVelocity(10);


Then, after a certain number of ticks, I set angular velocity to 0

Code:
if(inMove) {
    moveTicks++;
    if(moveTicks > 5) {
        circleBody.SetAngularVelocity(0);
        inMove = false;
    }
}


but body continues to move for some time

move end x:14.543830584751184 y:4.377520613939759
x:14.543830584751184 y:4.377520613939759
x:14.618724863714549 y:4.329811074307625
x:14.651468509634544 y:4.308911111115183
x:14.651435642383928 y:4.308859421664197
x:14.651405666799585 y:4.308812279859859
x:14.651378328472227 y:4.308769285599449
x:14.651353395375539 y:4.308730073981348
x:14.651330655896919 y:4.308694312208046
x:14.651309917041477 y:4.308661696761613
x:14.651291002794048 y:4.30863195082768
x:14.651273752625311 y:4.30860482194605
x:14.651258020129339 y:4.308580079868018
x:14.651243671781026 y:4.3085575146021995


Question:
What should I do than body becomes completely immobile after end of motion?
Code here

Compiled swf here
i think damping might help
These look like infinitesimal changes after you try to stop the angular velocity. Perhaps try...
Code:
circleBody.SetAwake(false);

  ...or depending on your Box2D version,

circleBody.PutToSleep();
Things don't move instantaneously in physics. Within 3 ticks the position is stabilized to 4dp, which is smaller than a pixel. I don't see how this can be a problem. If you truly want a dead stop, you should set linear and angular friction to zero, rather than relying on friction.
satarupa wrote:
i think damping might help

Please, explain you tip. i'm a noob in box2d 😉
BorisTheBrave wrote:
Things don't move instantaneously in physics. Within 3 ticks the position is stabilized to 4dp, which is smaller than a pixel. I don't see how this can be a problem.

the fact that it's network game and position's fluctuation desynchronize
players
BorisTheBrave wrote:
If you truly want a dead stop, you should set linear and angular friction to zero, rather than relying on friction.

i think about it, please, help me to make it.
try this
if(moveTicks > 10) {


circleBody.m_angularDamping=10
inMove = false;
trace('move end x:' + String(circleBody.GetPosition().x) + " y:" + String(circleBody.GetPosition().y));
}
satarupa wrote:
try this
if(moveTicks > 10) {


circleBody.m_angularDamping=10
inMove = false;
trace('move end x:' + String(circleBody.GetPosition().x) + " y:" + String(circleBody.GetPosition().y));
}

Don't work 🙁
Barliesque wrote:
These look like infinitesimal changes after you try to stop the angular velocity. Perhaps try...
Code:
circleBody.SetAwake(false);

  ...or depending on your Box2D version,

circleBody.PutToSleep();

Don't work 🙁

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