Extensions.conf
Incoming Autopatch CallerID to APRS Text Message.
exten=NodeNumber,n,System(sh /usr/local/sbin/aprs.sh ${CALLERID(num)} ${NODE})
#!/bin/bash function tune() { echo "Phone Number $1" SEQ=`cat /tmp/seq 2>/dev/null` SEQ=$(expr \( $SEQ + 1 \) % 1000) echo "ACK" $SEQ | tee /tmp/seq # sh /usr/local/sbin/speaktext.sh $1 NodeNumber python2 - <<END #!/usr/bin/env python from socket import * import time # APRS-IS login info serverHost = 'theconnectdesk.com' serverPort = 14580 aprsUser = 'CallSign' aprsPass = 'Passcode' # APRS packet callsign = 'ToCallSign' btext = ':ToCallSign :Call From: $1{M$SEQ' # create socket & connect to server sSock = socket(AF_INET, SOCK_STREAM) sSock.connect((serverHost, serverPort)) # logon sSock.send('user %s pass %s vers NA7Q-Python 0.1\n' % (aprsUser, aprsPass) ) # send packet sSock.send('%s>APRS:%s\n' % (callsign, btext) ) # close socket sSock.shutdown(0) sSock.close() END } tune $1
There is NO ACK to confirm the receipt of the APRS messages.