Documentation
¶
Index ¶
- Variables
- func RequestBatteryCharge(ctx context.Context, requester tetra.Requester) (int, error)
- func RequestGPSPosition(ctx context.Context, requester tetra.Requester) (float64, float64, int, time.Time, error)
- func RequestSignalStrength(ctx context.Context, requester tetra.Requester) (int, error)
- func RequestTalkgroup(ctx context.Context, requester tetra.Requester) (string, error)
- func SetOperatingMode(mode AIMode) string
- func SetTalkgroup(gtsi string) string
- type AIMode
- type TalkgroupInfo
- type TalkgroupKind
- type TalkgroupRange
Constants ¶
This section is empty.
Variables ¶
var AIModesByName = map[string]AIMode{ "TMO": TMO, "DMO": DMO, }
AIModesByName maps all supported operating modes by their string representation
Functions ¶
func RequestBatteryCharge ¶
RequestBatteryCharge reads the current battery charge status according to [PEI] 6.9
func RequestGPSPosition ¶
func RequestGPSPosition(ctx context.Context, requester tetra.Requester) (float64, float64, int, time.Time, error)
RequestGPSPosition reads the current GPS position, number of satellites, and time in UTC
func RequestSignalStrength ¶
RequestSignalStrength reads the current signal strength in dBm according to [PEI] 6.9
func RequestTalkgroup ¶
RequestTalkgroup reads the current talkgroup according to [PEI] 6.15.6.4
func SetOperatingMode ¶
SetOperatingMode according to [PEI] 6.14.7.2
Types ¶
type AIMode ¶
type AIMode byte
AIMode represents an operating mode according to [PEI] 6.17.4
func AIModeByName ¶
AIModeByName returns the AIMode with the given name
func RequestOperatingMode ¶
RequestOperatingMode reads the current operating mode according to [PEI] 6.14.7.4
type TalkgroupInfo ¶ added in v1.2.0
func RequestTalkgroups ¶ added in v1.2.0
func RequestTalkgroups(ctx context.Context, requester tetra.Requester, kind TalkgroupKind, result []TalkgroupInfo) ([]TalkgroupInfo, error)
RequestTalkgroups reads all available static talkgroups from the device, see [PEI] 6.11.5.2
type TalkgroupKind ¶ added in v1.2.0
type TalkgroupKind string
const ( TalkgroupFixed TalkgroupKind = "F" TalkgroupStatic TalkgroupKind = "S" TalkgroupDynamic TalkgroupKind = "D" )
type TalkgroupRange ¶ added in v1.2.0
func RequestTalkgroupRange ¶ added in v1.2.0
func RequestTalkgroupRange(ctx context.Context, requester tetra.Requester, kind TalkgroupKind) (TalkgroupRange, error)