now?
This commit is contained in:
parent
fe0a870f6c
commit
bf3f376f5a
2 changed files with 5 additions and 0 deletions
|
@ -62,6 +62,10 @@ func SetSpeedConfig(speed int, minDistance, maxDistance, minSpeed, maxSpeed, tri
|
|||
if err != nil {
|
||||
log.Printf("%v", err)
|
||||
}
|
||||
err = r.SetEventConfig(1, triggerDistance*2, triggerDistance*2+20, speed, 240, int(radar_lib.DirectionIncoming), radar_lib.TargetStateExit)
|
||||
if err != nil {
|
||||
log.Printf("%v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func SetCommunicationConfig(speedOutput, targetOutput, triggerOutput int) {
|
||||
|
|
|
@ -38,6 +38,7 @@ func HandleSetupSave(ctx *gin.Context) {
|
|||
logrus.Error(err)
|
||||
}
|
||||
radar.SetConfig(cfg.RadarHeight, cfg.RadarAngle, cfg.RadarWaveform)
|
||||
radar.SetSpeedConfig(cfg.TriggerSpeed, cfg.RadarMinDistance, cfg.RadarMaxDistance, cfg.RadarMinSpeed, cfg.RadarMaxSpeed, cfg.TriggerDistance)
|
||||
}
|
||||
|
||||
type SetupCommunicationForm struct {
|
||||
|
|
Loading…
Add table
Reference in a new issue