## Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo

 Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo From: Jonas Lanvers - 2007-11-01 15:03:59 ```Well, as far as I can see GetAngularVelocity returns something, but nothin= g I can use. In the end I just used the global pose to calculate the angular velocity. = I should have done this earlier, it's three lines of code ;-) If anyone is interested in the gyro plugin, just ask me. Thanks at all for your help! > -----Urspr=FCngliche Nachricht----- > Von: Gazebo developers > Gesendet: 30.10.07 09:17:59 > An: Gazebo developers > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo >=20 > I am using a simple cylinder and the function GetAngularVelocity from th= e body (not from the cylinder geom): > GzQuatern angVel=3D this->body->GetAngularVel(); > GzVector eulers =3D GzQuaternToEuler(angVel); > printf("%f \n", eulers.z); returns values from -3.14 to +3.14 and they c= hange in this spectrum even on a constant turning speed. > I don't set the angular velocity, because it's the global variable. I th= ink this is set automatically. >=20 > The body is initialized like this: > this->body =3D new Body( this->world ); > this->AddBody(this->body, true); >=20 > Jonas >=20 > > -----Urspr=FCngliche Nachricht----- > > Von: Gazebo developers > > Gesendet: 29.10.07 19:06:14 > > An: "Gazebo developers" > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo >=20 >=20 > >=20 > > Can you provide some more information=3F What type of geometry are your > > using=3F And exactly what function are you using to get/set the angular > > velocity=3F > >=20 > > -nate > >=20 > > On 10/29/07, Jonas Lanvers wrote: > > > I tried this, but it didn't work. > > > With a constant turning speed (that should propably result in a more= or less constant angular velocity) I get values from -2 over 0 to 2. > > > In my opinion angular velocity is, how much the angle on a specific = axis changes in time. So the vaules should raise and then, stay constant. > > > The values I get are sinus-like. > > > > > > Jonas > > > - > > > -----Urspr=FCngliche Nachricht----- > > > Von: Gazebo developers > > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > > > > > > > > Hello, > > > > > > There is a function in gazebo's quaternion class to convert to Euler= > > > angles. It might be easier to work with. > > > > > > -nate > > > > > > On 10/29/07, Jonas Lanvers wrote: > > > > Hello again :-) > > > > My quaternion to angle conversion seemed to be completely wrong. > > > > Does anybody know how to convert the Quaternion from Body->GetAngu= larVel() to degrees / second=3F > > > > I tried a lot of formulas, but they all don't work. The output bec= omes smaller and bigger although I run it with a constant rotation speed. > > > > So the angular velocity also has to be more or less constant, does= n't it=3F > > > > > > > > Thanks in advance > > > > > > > > Jonas > > > > -----Urspr=FCngliche Nachricht----- > > > > Von: Gazebo developers > > > > Gesendet: 23.10.07 19:46:05 > > > > An: "Gazebo developers" = > > > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > > > > > > > > > > > Yeah, the drift does seem to be a problem. Are there any mathemati= cal > > > > models for drift, or simple ways to estimate it=3F If all else fails= , > > > > maybe adding a little gaussian noise will do the trick. However, t= ake > > > > that with a grain of salt, I'm no expert on gyroscopes. > > > > > > > > -nate > > > > > > > > On 10/23/07, Jonas Lanvers wrote: > > > > > Hi, > > > > > > > > > > The object does not have to spin. I only need orientation and dr= ift. > > > > > Orientation seems to be no problem, I got this by converting the= Global Pose Quaternion. > > > > > But drift seems to be a problem, doesn't it=3F > > > > > > > > > > Jonas > > > > > > > > > > -----Urspr=FCngliche Nachricht----- > > > > > Von: Gazebo developers > > > > > Gesendet: 22.10.07 23:59:05 > > > > > > > > > > > > > > > A gyroscope might be possible. Do you want an actively spinning > > > > > object, or just a sensor that measures/maintains orientation=3F > > > > > > > > > > -nate > > > > > > > > > > On 10/18/07, Jonas Lanvers wrote: > > > > > > Is there any way (or better a plugin ) to simulate a gyroscope= in gazebo=3F > > > > > > > > > > > > Jonas =5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F Der WEB.DE SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! http://smartsurfer.web.de/=3Fmc=3D100071&distributionid=3D000000000066 ```

 [PlayerStage-Gazebo] Simulate gyroscope in gazebo From: Jonas Lanvers - 2007-10-18 07:41:04 ```Is there any way (or better a plugin ) to simulate a gyroscope in gazebo? Jonas _____________________________________________________________________ Der WEB.DE SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! http://smartsurfer.web.de/?mc=100071&distributionid=000000000066 ```
 Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo From: Nate Koenig - 2007-10-22 21:58:50 ```A gyroscope might be possible. Do you want an actively spinning object, or just a sensor that measures/maintains orientation? -nate On 10/18/07, Jonas Lanvers wrote: > Is there any way (or better a plugin ) to simulate a gyroscope in gazebo? > > Jonas > _____________________________________________________________________ > Der WEB.DE SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! > http://smartsurfer.web.de/?mc=100071&distributionid=000000000066 > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ > Playerstage-gazebo mailing list > Playerstage-gazebo@... > https://lists.sourceforge.net/lists/listinfo/playerstage-gazebo > ```
 Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo From: Jonas Lanvers - 2007-11-01 15:03:59 ```Well, as far as I can see GetAngularVelocity returns something, but nothin= g I can use. In the end I just used the global pose to calculate the angular velocity. = I should have done this earlier, it's three lines of code ;-) If anyone is interested in the gyro plugin, just ask me. Thanks at all for your help! > -----Urspr=FCngliche Nachricht----- > Von: Gazebo developers > Gesendet: 30.10.07 09:17:59 > An: Gazebo developers > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo >=20 > I am using a simple cylinder and the function GetAngularVelocity from th= e body (not from the cylinder geom): > GzQuatern angVel=3D this->body->GetAngularVel(); > GzVector eulers =3D GzQuaternToEuler(angVel); > printf("%f \n", eulers.z); returns values from -3.14 to +3.14 and they c= hange in this spectrum even on a constant turning speed. > I don't set the angular velocity, because it's the global variable. I th= ink this is set automatically. >=20 > The body is initialized like this: > this->body =3D new Body( this->world ); > this->AddBody(this->body, true); >=20 > Jonas >=20 > > -----Urspr=FCngliche Nachricht----- > > Von: Gazebo developers > > Gesendet: 29.10.07 19:06:14 > > An: "Gazebo developers" > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo >=20 >=20 > >=20 > > Can you provide some more information=3F What type of geometry are your > > using=3F And exactly what function are you using to get/set the angular > > velocity=3F > >=20 > > -nate > >=20 > > On 10/29/07, Jonas Lanvers wrote: > > > I tried this, but it didn't work. > > > With a constant turning speed (that should propably result in a more= or less constant angular velocity) I get values from -2 over 0 to 2. > > > In my opinion angular velocity is, how much the angle on a specific = axis changes in time. So the vaules should raise and then, stay constant. > > > The values I get are sinus-like. > > > > > > Jonas > > > - > > > -----Urspr=FCngliche Nachricht----- > > > Von: Gazebo developers > > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > > > > > > > > Hello, > > > > > > There is a function in gazebo's quaternion class to convert to Euler= > > > angles. It might be easier to work with. > > > > > > -nate > > > > > > On 10/29/07, Jonas Lanvers wrote: > > > > Hello again :-) > > > > My quaternion to angle conversion seemed to be completely wrong. > > > > Does anybody know how to convert the Quaternion from Body->GetAngu= larVel() to degrees / second=3F > > > > I tried a lot of formulas, but they all don't work. The output bec= omes smaller and bigger although I run it with a constant rotation speed. > > > > So the angular velocity also has to be more or less constant, does= n't it=3F > > > > > > > > Thanks in advance > > > > > > > > Jonas > > > > -----Urspr=FCngliche Nachricht----- > > > > Von: Gazebo developers > > > > Gesendet: 23.10.07 19:46:05 > > > > An: "Gazebo developers" = > > > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > > > > > > > > > > > Yeah, the drift does seem to be a problem. Are there any mathemati= cal > > > > models for drift, or simple ways to estimate it=3F If all else fails= , > > > > maybe adding a little gaussian noise will do the trick. However, t= ake > > > > that with a grain of salt, I'm no expert on gyroscopes. > > > > > > > > -nate > > > > > > > > On 10/23/07, Jonas Lanvers wrote: > > > > > Hi, > > > > > > > > > > The object does not have to spin. I only need orientation and dr= ift. > > > > > Orientation seems to be no problem, I got this by converting the= Global Pose Quaternion. > > > > > But drift seems to be a problem, doesn't it=3F > > > > > > > > > > Jonas > > > > > > > > > > -----Urspr=FCngliche Nachricht----- > > > > > Von: Gazebo developers > > > > > Gesendet: 22.10.07 23:59:05 > > > > > > > > > > > > > > > A gyroscope might be possible. Do you want an actively spinning > > > > > object, or just a sensor that measures/maintains orientation=3F > > > > > > > > > > -nate > > > > > > > > > > On 10/18/07, Jonas Lanvers wrote: > > > > > > Is there any way (or better a plugin ) to simulate a gyroscope= in gazebo=3F > > > > > > > > > > > > Jonas =5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F=5F Der WEB.DE SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! http://smartsurfer.web.de/=3Fmc=3D100071&distributionid=3D000000000066 ```
 Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo From: Nate Koenig - 2007-11-02 17:53:42 ```Hi, Yes, I would be interested. Could you submit a patch? Thanks for all the work. -nate On 11/1/07, Jonas Lanvers wrote: > Well, as far as I can see GetAngularVelocity returns something, but nothi= ng I can use. > In the end I just used the global pose to calculate the angular velocity.= I should have done this earlier, it's three lines of code ;-) > If anyone is interested in the gyro plugin, just ask me. > Thanks at all for your help! > > -----Urspr=FCngliche Nachricht----- > > Von: Gazebo developers > > Gesendet: 30.10.07 09:17:59 > > An: Gazebo developers > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > > > > > I am using a simple cylinder and the function GetAngularVelocity from t= he body (not from the cylinder geom): > > GzQuatern angVel=3D this->body->GetAngularVel(); > > GzVector eulers =3D GzQuaternToEuler(angVel); > > printf("%f \n", eulers.z); returns values from -3.14 to +3.14 and they = change in this spectrum even on a constant turning speed. > > I don't set the angular velocity, because it's the global variable. I t= hink this is set automatically. > > > > The body is initialized like this: > > this->body =3D new Body( this->world ); > > this->AddBody(this->body, true); > > > > Jonas > > > > > -----Urspr=FCngliche Nachricht----- > > > Von: Gazebo developers > > > Gesendet: 29.10.07 19:06:14 > > > An: "Gazebo developers" > > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > > > > > > > > > Can you provide some more information? What type of geometry are your > > > using? And exactly what function are you using to get/set the angular > > > velocity? > > > > > > -nate > > > > > > On 10/29/07, Jonas Lanvers wrote: > > > > I tried this, but it didn't work. > > > > With a constant turning speed (that should propably result in a mor= e or less constant angular velocity) I get values from -2 over 0 to 2. > > > > In my opinion angular velocity is, how much the angle on a specific= axis changes in time. So the vaules should raise and then, stay constant. > > > > The values I get are sinus-like. > > > > > > > > Jonas > > > > - > > > > -----Urspr=FCngliche Nachricht----- > > > > Von: Gazebo developers > > > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > > > > > > > > > > > Hello, > > > > > > > > There is a function in gazebo's quaternion class to convert to Eule= r > > > > angles. It might be easier to work with. > > > > > > > > -nate > > > > > > > > On 10/29/07, Jonas Lanvers wrote: > > > > > Hello again :-) > > > > > My quaternion to angle conversion seemed to be completely wrong. > > > > > Does anybody know how to convert the Quaternion from Body->GetAng= ularVel() to degrees / second? > > > > > I tried a lot of formulas, but they all don't work. The output be= comes smaller and bigger although I run it with a constant rotation speed. > > > > > So the angular velocity also has to be more or less constant, doe= sn't it? > > > > > > > > > > Thanks in advance > > > > > > > > > > Jonas > > > > > -----Urspr=FCngliche Nachricht----- > > > > > Von: Gazebo developers > > > > > Gesendet: 23.10.07 19:46:05 > > > > > An: "Gazebo developers" > > > > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > > > > > > > > > > > > > > Yeah, the drift does seem to be a problem. Are there any mathemat= ical > > > > > models for drift, or simple ways to estimate it? If all else fail= s, > > > > > maybe adding a little gaussian noise will do the trick. However, = take > > > > > that with a grain of salt, I'm no expert on gyroscopes. > > > > > > > > > > -nate > > > > > > > > > > On 10/23/07, Jonas Lanvers wrote: > > > > > > Hi, > > > > > > > > > > > > The object does not have to spin. I only need orientation and d= rift. > > > > > > Orientation seems to be no problem, I got this by converting th= e Global Pose Quaternion. > > > > > > But drift seems to be a problem, doesn't it? > > > > > > > > > > > > Jonas > > > > > > > > > > > > -----Urspr=FCngliche Nachricht----- > > > > > > Von: Gazebo developers > > > > > > Gesendet: 22.10.07 23:59:05 > > > > > > > > > > > > > > > > > > A gyroscope might be possible. Do you want an actively spinning > > > > > > object, or just a sensor that measures/maintains orientation? > > > > > > > > > > > > -nate > > > > > > > > > > > > On 10/18/07, Jonas Lanvers wrote: > > > > > > > Is there any way (or better a plugin ) to simulate a gyroscop= e in gazebo? > > > > > > > > > > > > > > Jonas > > _____________________________________________________________________ > Der WEB.DE SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! > http://smartsurfer.web.de/?mc=3D100071&distributionid=3D000000000066 > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ > Playerstage-gazebo mailing list > Playerstage-gazebo@... > https://lists.sourceforge.net/lists/listinfo/playerstage-gazebo > ```
 Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo From: morrowsend - 2010-10-26 21:17:32 ```I realize this thread is ancient, but I'm very interested in seeing the code used here. I can't seem to find if it was ever added to the CVS. jonasl wrote: > > Well, as far as I can see GetAngularVelocity returns something, but > nothing I can use. > In the end I just used the global pose to calculate the angular velocity. > I should have done this earlier, it's three lines of code ;-) > If anyone is interested in the gyro plugin, just ask me. > Thanks at all for your help! >> -----Ursprüngliche Nachricht----- >> Von: Gazebo developers >> Gesendet: 30.10.07 09:17:59 >> An: Gazebo developers >> Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo > > >> >> I am using a simple cylinder and the function GetAngularVelocity from the >> body (not from the cylinder geom): >> GzQuatern angVel= this->body->GetAngularVel(); >> GzVector eulers = GzQuaternToEuler(angVel); >> printf("%f \n", eulers.z); returns values from -3.14 to +3.14 and they >> change in this spectrum even on a constant turning speed. >> I don't set the angular velocity, because it's the global variable. I >> think this is set automatically. >> >> The body is initialized like this: >> this->body = new Body( this->world ); >> this->AddBody(this->body, true); >> >> Jonas >> >> > -----Ursprüngliche Nachricht----- >> > Von: Gazebo developers >> > Gesendet: 29.10.07 19:06:14 >> > An: "Gazebo developers" >> > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo >> >> >> > >> > Can you provide some more information? What type of geometry are your >> > using? And exactly what function are you using to get/set the angular >> > velocity? >> > >> > -nate >> > >> > On 10/29/07, Jonas Lanvers wrote: >> > > I tried this, but it didn't work. >> > > With a constant turning speed (that should propably result in a more >> or less constant angular velocity) I get values from -2 over 0 to 2. >> > > In my opinion angular velocity is, how much the angle on a specific >> axis changes in time. So the vaules should raise and then, stay constant. >> > > The values I get are sinus-like. >> > > >> > > Jonas >> > > - >> > > -----Ursprüngliche Nachricht----- >> > > Von: Gazebo developers >> > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo >> > > >> > > >> > > Hello, >> > > >> > > There is a function in gazebo's quaternion class to convert to Euler >> > > angles. It might be easier to work with. >> > > >> > > -nate >> > > >> > > On 10/29/07, Jonas Lanvers wrote: >> > > > Hello again :-) >> > > > My quaternion to angle conversion seemed to be completely wrong. >> > > > Does anybody know how to convert the Quaternion from >> Body->GetAngularVel() to degrees / second? >> > > > I tried a lot of formulas, but they all don't work. The output >> becomes smaller and bigger although I run it with a constant rotation >> speed. >> > > > So the angular velocity also has to be more or less constant, >> doesn't it? >> > > > >> > > > Thanks in advance >> > > > >> > > > Jonas >> > > > -----Ursprüngliche Nachricht----- >> > > > Von: Gazebo developers >> > > > Gesendet: 23.10.07 19:46:05 >> > > > An: "Gazebo developers" >> > > > Betreff: Re: [PlayerStage-Gazebo] Simulate gyroscope in gazebo >> > > > >> > > > >> > > > Yeah, the drift does seem to be a problem. Are there any >> mathematical >> > > > models for drift, or simple ways to estimate it? If all else fails, >> > > > maybe adding a little gaussian noise will do the trick. However, >> take >> > > > that with a grain of salt, I'm no expert on gyroscopes. >> > > > >> > > > -nate >> > > > >> > > > On 10/23/07, Jonas Lanvers wrote: >> > > > > Hi, >> > > > > >> > > > > The object does not have to spin. I only need orientation and >> drift. >> > > > > Orientation seems to be no problem, I got this by converting the >> Global Pose Quaternion. >> > > > > But drift seems to be a problem, doesn't it? >> > > > > >> > > > > Jonas >> > > > > >> > > > > -----Ursprüngliche Nachricht----- >> > > > > Von: Gazebo developers >> > > > > Gesendet: 22.10.07 23:59:05 >> > > > > >> > > > > >> > > > > A gyroscope might be possible. Do you want an actively spinning >> > > > > object, or just a sensor that measures/maintains orientation? >> > > > > >> > > > > -nate >> > > > > >> > > > > On 10/18/07, Jonas Lanvers wrote: >> > > > > > Is there any way (or better a plugin ) to simulate a gyroscope >> in gazebo? >> > > > > > >> > > > > > Jonas > > _____________________________________________________________________ > Der WEB.DE SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! > http://smartsurfer.web.de/?mc=100071&distributionid=000000000066 > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ > Playerstage-gazebo mailing list > Playerstage-gazebo@... > https://lists.sourceforge.net/lists/listinfo/playerstage-gazebo > > -- View this message in context: http://old.nabble.com/Simulate-gyroscope-in-gazebo-tp13269627p30061816.html Sent from the playerstage-gazebo mailing list archive at Nabble.com. ```