-
Notifications
You must be signed in to change notification settings - Fork 1
/
echo_aprsis_traffic.robot
50 lines (38 loc) · 1.48 KB
/
echo_aprsis_traffic.robot
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# This is a simple robot which captures up to 10 APRS 'message' type messages and
# logs their raw messages to the console. Then terminate the test
# Author: Joerg Schultze-Lutter, DF1JSL
# https://www.github.com/joergschultzelutter/robotframework/aprslib
*** Settings ***
Library AprsLibrary
Suite Setup Open APRS-IS Connection
Suite Teardown Close APRS-IS Connection
*** Variables ***
# This is your APRS-IS call sign. Replace this value with your personal call sign
${callsign} YOURCALLSIGN
# APRS-IS server filter, see http://www.aprs-is.net/javAPRSFilter.aspx
${filter} t/m
*** Test Cases ***
Echo APRS-IS Raw Traffic to Console
[Documentation] Capture up to 10 APRS messages and display them on the console
# Robot has no WHILE loop. Therefore, we need to use a FOR loop.
FOR ${i} IN RANGE 10
Receive Packet From APRS-IS
END
*** Keywords ***
Open APRS-IS Connection
${passcode}= Calculate APRS-IS Passcode ${callsign}
Set APRS-IS Callsign ${callsign}
Set APRS-IS Passcode ${passcode}
Set APRS-IS Filter ${filter}
Log Connecting to APRS-IS
Connect to APRS-IS
Close APRS-IS Connection
Log Disconnect from APRS-IS
Disconnect from APRS-IS
Receive packet from APRS-IS
# Receive the package. By default, aprslib decodes it ...
${packet} = Receive APRS Packet
# ... but for now, let's get the raw message from that decode packet
# and display it on the console
${packet} = Get Raw Message Value From APRS Packet ${packet}
Log To Console ${packet}