Project
After reset initialization, execution enters the controlling code section.
parity, and 1 stop bit. Note that this still lets the UART properly receive characters with 2 stop bits. The subroutine then configures the 8250 to generate an interrupt (to the 8748) whenever it receives a character, and it enables the handshaking lines.
After SETURT configures the handshaking lines, it sets the baud rate by reading in the DIP switch settings for switches 2-4 and using the complemented binary value (shifted left one bit position) as an offset to the baud rate divider table, BAUDTB. SETURT then sends the appropriate divider bytes to the 8250. As a final step before exiting the subroutine, SETURT reads in the value of switch 4 and puts it into a special flag register (R4), with all other bits in the byte clcared.
If R4 is zero (switch closed), the routine selects software handshaking. Otherwise, it establishes hardware handshaking. Note that the baud rate and handshaking modes are selected during system reset processing. If you change the DIP switch setting, the changes have no effect until the next board reset.
After SETURT sets up the UART, the final initialization step sets up registers R1-R3 and R5 for their respective special purposes, enables printer characters to come in from the computer, and enables interrupts.
When reset initialization is complete, execution enters the main controlling code section. Main. This section works according to the flowchart in Fig. 11. It first checks to see if the converter has buffered any characters. If so, it checks to see if it is OK to send a character. If yes again, the program transmits the next character from the buffer out the serial port. If a character isn't available or it can't be sent out. execution moves to the CKCHIN section.
CKCHIN first checks to see if any room exists on the buffer. If not, it goes back to the start of Main. Otherwise, it then checks to see if CKCHIN has received a character from the computer. If not, execution goes back to Main. If so, CKCHIN reads in the character and stores it in the buffer. Execution then returns to the start of Main.
PRCURT is the interrupt service routine to service serial charactcrs the 8250
UART receives. If it gets an XOFF character, it sets the XOFF FLAG (R5) with a OFFH value to indicate transmitting should halt. If PRCURT receives an XON character, it clears the XOFF FLAG. It ignores all other characters.
Using the Parallel-to-Serial Converter Board
To use the parallel-to-serial converter board, connect the power supply, RS-232C, and parallel printer cables to the appropriate systems, and configure the DIP switch according to the handshaking protocol and baud rate desired. You can apply the power to the board before or along with the power to the computer and printer. The board will require one to 1.5 seconds for power-up initialization before it can accept characters from the host computer.
Conclusion
I used Mumford Micro Systems' 8048 assembler for these last two projects. Mumford has agreed to offer the assembler to Project 80 readers for S50 during the months the 8748-related projects run (it normally costs $125). The assembled source code is also available on Load 80. This is a good assembler and I recommend it to anyone interested in the 8048 family of processors. The assembler is available for Models I and III only (I run mine in Model III mode on my 4P). Contact Mumford Micro Systems at Box 400, Summerland, CA 93067 (805-969-4557).;$
Write to Roger Alford at P.O. Box 2014. Ann Arbor, MI 48106. Please enclose a self-addressed, stamped envelope for a reply.
References
RS-232C Interface Standard (SI3): Electronics Industries Association Engineering Department 2001 Eye Street, N.W. Washington, D.C. 20006
8748 Microcomputer Data Book: MCS-48 Family of Single Chip Microcomputers User's Manual Intel Corporation Literature Department 3065 Bowers Avenue Santa Clara, CA 95051
8250 UART Data Sheet: INS8250-B Asynchronous Communications Element Data Sheet National Semiconductor Corporation
2900 Semiconductor Drive Santa Clara, CA 95051
tion by calling our new toll free number:
between 9 a.m. and 5 p.m. EST"! Monday-Friday. If possible, pleasenave your mailing label in front of you as well as your cancelled check are having problems with payment. If your old and new addresses.

Remember to mention thai you saw their ad in 80 Micro
Now Presenting... The New, Improved DOS
As of this month, I'm using the Tandy 1000's new DOS and Basic. You should, too. Tandy has increased IBM compatibility and added some useful enhancements. And fixed-up GW-Ba-sic works as the manual promises. I'll go over the changes, new features, and bugs (there are a few). Of course, I have suggestions—like hang on to a copy of the old DOS.
The upgrade to MS-DOS 2.11.22 (and Microsoft's GW-Basic, Tandy version 1.01.00) is mandatory; Radio Shack no longer supports the old versions. If you're using an outdated DOS, take the original master disk to a Radio Shack Computer Center and they'll copy the free upgrade onto it (the stock number is 700-2604). If you weren't notified of the upgrade, write to Radio Shack Software Registration, Dept. 7879, 400 Atrium, One Tandy Center. Fort Worth, TX 76102.
DOS Details
Using the DOS file-compare program (FC.COM), I found that 12 DOS files have changed in addition to Basic. There are also some new names in the directory. Peruse the README.DOC file using the Type command (TYPE README.DOC) or print it out using the DOS Print command (PRINT README.DOC). This newly added file details the changes, but not all of them. I've found some surprises—mostly good ones—and a few bad ones.
Only one MS-DOS system file changed. IO.SYS, invisible on your DOS disk and always present in your computer's memory, has grown slightly. Changing this file had made the new DOS incompatible with Microsoft's QuickBasic compiler on 1000s with hard drives (see p.29 for information and a fix). Tandy will correct this problem. MSDOS.SYS, the other invisible system file, and Command.COM, the DOS command processor, are unchanged.
The Mode command has two important enhancements. First, you can change your display colors with Mode's
System Requirements
Model 1000
new Colormap option. If you map black to blue, blue will show where black is supposed to be. I was relieved to discover this feature, because the new ANSI.SYS no longer clears the screen to a color as it did under the old DOS (see my November 1985 column, p. 94). Unlike the ANSI method of coloring the screen, Mode's colormapping carries over to all your application programs.
I added two lines to my AUTOEXEC. BAT file to change the screen colors to bright white on blue when I power up: MODE COLORMAP BLACK.BLUE and MODE COLORMAP GRAY,WHITE. I also have a batch file to load Basic after changing to Basic's subdirectory. That batch file changes the colors back to black and gray (MODE COLORMAP returns to default colors), because Mode af-
Program Listing 1. Disable control-break.
10 KEY (19) ON:ON KEY(19) G0SUB 500 2.0 KEY (20) ON:ON KEY (20) G0SUB 500 30 KEY 19,CHR$(&H4)+CHR$(&H54) 40 KEY 20,CHR$(&H44)+CHR$(&H54) 50 A$=INKEY$
60 IF A$="l" THEN END ELSE GOTO 50 500 PRINT "BREAK":RETURN
'Press 1 to end program.
Program Listing 2. Random Circles.
10 CLEAR ,,,32768!:CLS:KEY OFF:SCREEN 6
11 RANDOMIZE VAL(RIGHT$(TIME$,2))
15 PALETTE 0,5:PALETTE 1,11:PALETTE 2,15:PALETTE 3,
50 GOTO 20
Post a comment