Skip to main content
Home Forums 68kMLA MS Basic 2.0 Help — #3
Post #3 by Aoresteen
Source Forum68kMLA
CategoryDevelopment
Post DateSun, 23 Mar 2008 - 13:05
Original URLhttps://68kmla.org/bb/threads/ms-basic-2-0-help.12500/
Post
I'm doing this off the top of my head. And I used Zbasic far more than MS Basic.

You need to use the OPEN command and treat the serial port as a sequential file.

OPEN "COM1" FOR INPUT AS #1

GET #1, variable1 ect

OPEN "COM1" FOR OUTPUT AS #1

PRINT #1, varible1 etc

In a statement before you need to set up the COM1 or COM2 port:

"COM1:9600,N,8,1"

I don't remember the exact syntax.

You will need a book for all the verbs and syntax.

Is there a help file?

I used to test my serial ports by hooking up ImageWriter and sendint text to it. If it prints you are doing things right.

I don't have any of my old ZBASIC source code here but I'm sure the syntax was very close if not the same.

open "COM1:1200,N,8,1" for output as #1

open "COM1:1200,N,8,1" for input as #2

This might work as well

mp.ls