fix: bug on the antenna genius

This commit is contained in:
2026-06-22 19:48:29 +02:00
parent 60bcd2422d
commit 824971d0a1
+5 -1
View File
@@ -116,7 +116,11 @@ func (c *Client) Activate(port, antenna int) error {
if antenna < 0 { if antenna < 0 {
return fmt.Errorf("antgenius: invalid antenna %d", antenna) return fmt.Errorf("antgenius: invalid antenna %d", antenna)
} }
if err := c.send(fmt.Sprintf("port set %d rxant=%d txant=%d", port, antenna, antenna)); err != nil { // Set only rxant (like the reference ShackMaster client): the AG mirrors it
// to the TX antenna automatically. Forcing txant too can be rejected on the
// 8x2 (an antenna can't be TX on both ports at once), which broke port-B
// selection and deselection.
if err := c.send(fmt.Sprintf("port set %d rxant=%d", port, antenna)); err != nil {
return err return err
} }
// Ask for the new port state so the snapshot reflects it promptly (the // Ask for the new port state so the snapshot reflects it promptly (the