Gyro tutorials (#930)

* gyro tutorials

* tutorials

* fix gyro simulator

* images

* updated image

* fix svg errors
This commit is contained in:
Peli de Halleux
2019-09-30 22:43:50 -07:00
committed by GitHub
parent cb816c91ad
commit 80b9c715b2
12 changed files with 175 additions and 8 deletions

View File

@ -1,5 +1,5 @@
namespace pxsim {
const enum GyroSensorMode {
export const enum GyroSensorMode {
None = -1,
Angle = 0,
Rate = 1,
@ -20,6 +20,7 @@ namespace pxsim {
}
setAngle(angle: number) {
angle = angle | 0;
if (this.angle != angle) {
this.angle = angle;
this.setChangedState();
@ -27,6 +28,7 @@ namespace pxsim {
}
setRate(rate: number) {
rate = rate | 0;
if (this.rate != rate) {
this.rate = rate;
this.setChangedState();