
Page 11 MSI-P604 User Manual
IV. SAMPLE BASIC LANGUAGE TEST PROGRAM
The BASIC language program below illustrates software sequences
for the NMEA protocol that are displayed on the video monitor.
Also provided are simple routines for inputting the /IN1 thru /
IN4 digital inputs and writing to the /OUT1_BUFFERED output.
The program can be run under DOS using a BASIC interpreter
such as QBASIC by Microsoft Corporation. An interpreter can be
provided at no charge upon request.
‘GPS terminal program for MSI-P604 with Condor C2626 module.
‘Written by J. L. Hilburn, Microcomputer Systems, Inc. - 07/31/2012.
‘UART (U5) Port at 9600 BAUD (default mode)
COM1 = &H3F8: COM2 = &H2F8: COM3 = &H3E8: COM4 = &H2E8
PRIMARY = COM1
OFFSET = 0
BAUD = 12 ‘9600 BAUD divisor
CLS
PRINT “”
PRINT “Default address is COM1. No address jumper for JP2 should be
installed.”
PRINT “”: PRINT “Strike any key to continue!”
WHILE INKEY$ = “”: WEND
GOSUB init
begin:
CLS
PRINT “”
PRINT “(1) Display NMEA Protocol.”
PRINT “(2) Set digital output of J1 to hexadecimal 5 (&H5).”
PRINT “(3) Set digital output of J1 to hexadecimal A (&HA).”
PRINT “(4) Display digital inputs of J1 /IN1 thru /IN4.”
PRINT “(5) Set UART (U5) port address.”
PRINT “(6) Enable Interrupts.”
PRINT “(7) Set NMEA Protocol to Factory Default.”
PRINT “(8) Send NMEA Message to Condor C2626.”
PRINT “(9) Set address to COMx + &H800.”
PRINT “(10) Display UART (U5) address.”
PRINT “(11) Exit program”
PRINT “”
INPUT “Enter selection - “, GP$
SELECT CASE GP$
CASE “1”
GOSUB init:
GOTO start
Comentarios a estos manuales