An APRS-IS passcode generator and type.
Usage
The Callpass type is used for representing an APRS-IS passcode.
It will transform a callsign into a passcode, and can be used in
place of integers where expecting a callpass.
let given_callsign = "x2yz";
let given_callpass = 29322i64;
We can generate a Callpass like so, using the From trait:
# use Callpass;
# let given_callsign = "x2yz";
// This step will generate an APRS-IS passcode.
let callpass: Callpass = given_callsign.into;
If we already have an APRS-IS passcode as an integer, we can
make a Callpass from that as well to gain the benefits of type
checking:
# use Callpass;
# let given_callpass = 29322i64;
let their_callpass: Callpass = given_callpass.into;
assert!;