Omniwheel robot rolling down an inclined plane

Typically: "How do I... ", "How can I... " questions
Post Reply
lshachar
Posts: 12
Joined: 01 Aug 2015, 18:00

Omniwheel robot rolling down an inclined plane

Post by lshachar » 03 Aug 2015, 21:14

Hi,

This is related to my previous post:
viewtopic.php?f=9&t=4045

I am trying to get a three-wheel omnidirectional robot to roll down an inclined plane.
Image

I set all three motors with zero speed and zero torque, to make the main axis of the omnidirectional wheel (the rolling axis) free.
Image

I also commented out the main robot's script, not to set any target velocites to the omnidirectional wheels.
The robot rolls down very, very slowly. And I can't figure out why.
(as can be seen in the simulation, the robot on the right)

I then proceeded to make a simplified platform, with one omnidirectional wheel replaced with a frictionless caster, and the two remaining omni wheels in parallel to each other. (in the simulation seen on the right)
-The robot is still considerably slower than the modeled rolling sphere.

Why so? what can I do to fix this behavior?

Thank you for your help! :)

https://dl.dropboxusercontent.com/u/256 ... 20roll.ttt

lshachar
Posts: 12
Joined: 01 Aug 2015, 18:00

Re: Omniwheel robot rolling down an inclined plane

Post by lshachar » 04 Aug 2015, 00:42

I think that the issue is the joints being reset in every step of the simulation, meaning that they don't carry their velocity while spinning. This also explains why when I made the base plate much heavier, the effect was reduced. I wonder if this is really the problem and whether there are other common ways to model an omni wheel.

coppelia
Site Admin
Posts: 7441
Joined: 14 Dec 2012, 00:25

Re: Omniwheel robot rolling down an inclined plane

Post by coppelia » 04 Aug 2015, 09:13

Hello,

you are right, one element in each wheel is always reset, thus always starts at linear/rotational velocity zero. The construction is more meant to be used in an active way (with the main axis driving the wheel). You can improve this in several ways:
  • Reduce the mass/inertia of the wheels that get reset
  • Apply an initial linear/angular velocity to the wheels that get reset
Your code is based on an old V-REP version (and had a bug), use following instead:

Code: Select all

if (sim_call_type==sim_childscriptcall_initialization) then 
	rolling=simGetObjectAssociatedWithScript(sim_handle_self)
	slipping=simGetObjectHandle('OmniWheel_freeJoint')
	wheel=simGetObjectHandle('OmniWheel_respondableWheel')
end 

if (sim_call_type==sim_childscriptcall_actuation) then 
	if (simGetObjectParent(rolling)~=-1) then
		local linVel,angVel=simGetVelocity(wheel)
		simResetDynamicObject(wheel)
		simSetObjectFloatParameter(wheel,3000,linVel[1])
		simSetObjectFloatParameter(wheel,3001,linVel[2])
		simSetObjectFloatParameter(wheel,3002,linVel[3])
		simSetObjectFloatParameter(wheel,3020,angVel[1])
		simSetObjectFloatParameter(wheel,3021,angVel[2])
		simSetObjectFloatParameter(wheel,3022,angVel[3])
		simSetObjectPosition(slipping,rolling,{0,0,0})
		simSetObjectOrientation(slipping,rolling,{0,math.pi/2,0})
		simSetObjectPosition(wheel,rolling,{0,0,0})
		simSetObjectOrientation(wheel,rolling,{0,0,0})
	end
end 
In above code, an initial linear/angular velocity is applied to your wheels.

Then: the free joints should be in force/torque mode, but the motor NOT enabled. If the motor is enabled, a physics engine will often still apply a force/torque to such a joint when the target velocity is zero, which can be used to simulate friction, but which is of no interest in your situation.

Cheers

lshachar
Posts: 12
Joined: 01 Aug 2015, 18:00

Re: Omniwheel robot rolling down an inclined plane

Post by lshachar » 10 Aug 2015, 16:27

Thank you very much! I would never have figured out by myself how to save the linear / angular velocities before resetting the wheel, and applying them back afterwards. I ended up modeling the omniwheels differently, Changing materials with different coefficient of friction from 0 to 1, and reapplying the velocities is a necessary step.

thank you

Post Reply