| | |
| | | import com.ard.work.domain.dto.control.AngleControlDTO; |
| | | import com.ard.work.domain.dto.control.SpeedControlDTO; |
| | | import com.ard.work.service.ITyService; |
| | | import com.ard.work.service.impl.GimbalSpeedService; |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | |
| | | |
| | | @Resource |
| | | private ITyService tyService; |
| | | @Resource |
| | | private GimbalSpeedService gimbalSpeedService; |
| | | |
| | | |
| | | @ApiOperation(value = "云台转动(基于角度)", notes = "actionCode值:0-回中,1-上,2-右上,3-右,4-右下,5-下,6-左下,7-左,8-左上,254-停止 \r\n rotationAngle值:取值范围:0~255【云台实际转动角度= 转动角度/100+2.5 单位:度】") |
| | |
| | | return AjaxResult.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "云台速度控制(开始/停止统一接口)") |
| | | @ApiOperationSupport(order = 4) |
| | | @PostMapping("/speedControlSimple") |
| | | public AjaxResult speedControlSimple(@RequestBody @Validated SpeedControlDTO speedControlDto) { |
| | | if (speedControlDto.isStart()) { |
| | | gimbalSpeedService.startControl(speedControlDto); |
| | | } else { |
| | | gimbalSpeedService.stopControl(speedControlDto.getBoxSn()); |
| | | } |
| | | return AjaxResult.success(); |
| | | } |
| | | } |