Path: utzoo!attcan!uunet!lll-winken!ames!amdahl!dlb!netcom!chiesa From: chiesa@netcom.UUCP (15) Newsgroups: comp.sys.atari.8bit Subject: Re: One last Spartados x questin.. Summary: XIO 36 details Message-ID: <22@netcom.UUCP> Date: 19 Mar 89 19:37:38 GMT References: <8903172225.AA26233@ucbvax.Berkeley.EDU> Organization: NetCom Services - Public Access Unix System (408) 997-9175 guest Lines: 149 In article <8903172225.AA26233@ucbvax.Berkeley.EDU>, BIW109@URIMVS.BITNET writes: > [ questions about SpartaDOS deleted ] > On an unrelated note, could anyone give me the correct parameters > for the xio command #36 (set baud rate/parity/wordsize for the > rs232 interface)? All of the doccumentation that came with the > drivers I have (they were included with the r-verter interface) just > refer me to the atari 850 manual (not good advice, since I would not > have baught an r-verter if I had an 850...) I have before me Atari's "850 Interface Module Technical Manual" -- which, believe it or not, documents more than you could ever possibly want to know about that beast, and which CAME WITH the 850 when I bought it back in '82. I've never seen anyone else with a copy of it, even among my friends who also have 850's. I guess I "lucked out," as my mother would say... The writeup on the XIO 36 command is a good two and a half pages of small type, but that includes a lot of stuff we all already know (or at least, work with enough to know "intuitively") -- what "baud" means, and so on... Suitably edited, then, here's the scoop: ---- The CONFIGURE BAUD RATE command allows you to set the Baud rate, "word" size, number of stop bits to transmit, and enable or disable checking of DSR, CTS, and CRX. The command may be issued through an open IOCB to the RS-232-C SERIAL INTERFACE port, or through an IOCB which isn't being used. If you have opened an IOCB to the port you are configuring, you must use that IOCB. You cannot configure any port if a Concurrent Mode I/O operation is active. The CONFIGURE BAUD RATE command looks like this in BASIC: XIO 36,#iocb,aux1,aux2,"Rn:" ... the IOCB should either be open to the port you are configuring, or should not be open at all. No Concurrent Mode I/O should be active when you issue this command. Aux1 ... specifies the Baud rate, "word" size, and number of stop bits... For each of these, pick a number from tables B-1, B-2, and B-3 (see below - CFC), then add the nummbers together to form Aux1. Aux2 ... specifies whether or not the Interface Module should check Data Set Ready (DSR), Clear To send (CTS), and/or Carrier Detect (CRX) when a Block Mode output or START CONCURRENT MODE I/O operation is performed. If you ask to have the Interface Module check one or more of these, the interface module will return error status if the line check(s) is not ON. The error status is returned from the Block Mode output attempt or from the START CONCURRENT MODE I/O attempt. The condition of the line(s) being checked does not matter at the time you do the CONFIGURE BAUD RATE command to turn on the checking... See Table B-4 (below - CFC) for values of Aux2. Note that the preset values of Aux1 and Aux2 ... are zero, corresponding to 300 baud, 8-bit words, one stop bit, and no checking of DSR, CTS, or CRX. The configured parameters will stay as you set them until you either reset them or until you reboot the system (turn the power off and back on). The SYSTEM RESET key will not reset any of these parameters. (Remember, this is for the 850 -- may or may not hold for later devices that merely "emulate" it. Included "for completeness." -- CFC) You may configure each... (serial) port independently. If you specify 8-bit words, there are no restrictions on operation of the port. However, the following restrictions apply to 7-, 6-, and 5-bit words: * Full-duplex is not allowed * Half-duplex input can be in Concurrent Mode I/O only * Half-duplex output can be in Block Mode only * Input and output can be only 300 Baud or less (The implication is that today's modem communications are all done with 8-bit words; and you are using Concurrent Mode I/O for all such communications as well, if it wasn't clear... - CFC) (more stuff on 7-, 6-, and 5-bit words, deleted. Do you want it? - CFC) (more on checking DSR etc... want that? - CFC) ------ Okay, enough of that; that should cover what you need. The tables of values from Appendix B are reproduced below. Tables B-1, B-2, and B-3 list values (really "bit settings," but they don't tell you that) to be "added together" (or OR'ed into the bit mask) to form Aux1. Table B-4 lists values for Aux2. You should be able to easily determine the specific Bit Mask func- tions by examining these tables... B-1: Baud Rate Specifiers to add to Aux1: ADD BAUD RATE (bits per second) 0 300 1 45.5 (for Baudot teletypes; usu. referred to as 60 words/min) 2 50 ( " " " ; " " " " 67 words/min) 3 56.875 ( " " " ; " " " " 75 " / " ) 4 75 (sometimes for ASCII, sometimes for 5-bit RTTY. 100 WPM) 5 110 6 134.5 (used by IBM systems) ( ??? -- CFC) 7 150 8 300 9 600 10 1200 11 1800 12 2400 13 4800 14 9600 15 9600 B-2: Word Size Specifiers to add to Aux1: ADD WORD SIZE (bits) 0 8 16 7 32 6 48 5 B-3: Specifier for Two Stop Bits to add to Aux1: ADD STOP BITS SENT WITH EACH WORD 0 1 128 2 ----- B-4: Aux2 Specifications to check DSR, CTS, CRX: ADD TO MONITOR 0 None 1 CRX 2 CTS 3 CTS,CRX 4 DSR 5 DSR,CRX 6 DSR,CTS 7 DSR,CTS,CRX ----- Th-th-th-that's all, folks! Enjoy.