add debug logs
This commit is contained in:
parent
f1261819f6
commit
a78bedd598
@ -186,6 +186,7 @@ func (c *Controller) onTFSteering(_ mqtt.Client, message mqtt.Message) {
|
|||||||
func (c *Controller) adjustSteering(evt *events.SteeringMessage) ([]byte, error) {
|
func (c *Controller) adjustSteering(evt *events.SteeringMessage) ([]byte, error) {
|
||||||
steering := float64(evt.GetSteering())
|
steering := float64(evt.GetSteering())
|
||||||
steering = c.corrector.AdjustFromObjectPosition(steering, c.Objects())
|
steering = c.corrector.AdjustFromObjectPosition(steering, c.Objects())
|
||||||
|
zap.S().Debugf("adjust steering to avoid objects: %v -> %v", evt.GetSteering(), steering)
|
||||||
evt.Steering = float32(steering)
|
evt.Steering = float32(steering)
|
||||||
// override payload content
|
// override payload content
|
||||||
payload, err := proto.Marshal(evt)
|
payload, err := proto.Marshal(evt)
|
||||||
|
Loading…
Reference in New Issue
Block a user