133134135136137138139140141142
setYawAndTrust(e.getYaw(), e.getTrust()); setRollAndPitch(e.getRoll(), e.getPitch()); return; } if (event instanceof AltHoldEvent) { AltHoldEvent e = (AltHoldEvent) event; xyColor = e.isHold() ? Color.RED : Color.BLACK; return; } }
157158159160161162163164165166167168169
} } return; } if (event instanceof AltHoldEvent) { AltHoldEvent e = (AltHoldEvent) event; log.info("AltHold: " + e.isHold()); crazyflie.setAltHold(e.isHold()); return; } if (event instanceof StartEvent) { on = ((StartEvent) event).isOn();