›› 'The McHugh Patch'›› Split Baud Rates With Any› Atari RS232 Interface›› By Geoff McHugh››› Did you know that it is›possible, despite what the›'experts' say, to obtain split baud›rates on the Atari 850 (or›similar- including P:R connection)›RS232 interface? No, neither did I,›until very recently.››› It all started when I received›a copy of the source code for the›RS232 handler which I use with my›Datatari interface. While I was›looking through the listing, It›dawned on me that it should be›possible to get the handler to›operate at split rates (which it›was not originally intended to do)›by using a few direct POKEs from›within a terminal program. Since at›the time the expert opinion was›that the 850 interface was›totally incapable of split baud›rates, I naturally assumed that this›would only work with the Datatari›interface, so I constructed some›program PATCHes for two versions of› the Amodem terminal program›(Amodem4 and Amodem7), labelled›them as being for use with the›Datatari interface and the RHAND›RS232 handler (which I use) and›uploaded them to my favourite BBS,› The ARK. I was naturally›curious as to whether this WOULD›work with the 850 interface, so I›asked the sysop to try it out, and›thought no more about it, until›I noticed a message from a fellow›user to the sysop claiming that the›patched program had worked with›his P:R Connection (supposedly›more-or-less identical to the 850›interface).›› I was, of course, very›interested by this, so I again asked›the sysop if he would try again›with his 850 interface. Imagine my›surprise when I next logged-on to›find that my patch was being›hailed as the greatest discovery›in Atari 8-bit communications!›Apparently, the patch had worked on›the 850, and the sysop (James›Bastable) was quite understandably›excited. I hardly need to tell you›that I was just as excited as him!›The repercussions of this›discovery should strike far into›the world of Atari 8-bit comms.›Anyone James contacted about this›still said it was impossible,›until he proved them wrong. As far›as I can tell, even Atari themselves›do not know about this, otherwise›they surely would have capitalized on›it! Maybe now the Atari will benefit›from a widely available ViewData›compatible terminal program.›› Now, I think I have waffled›on far too long, so I will get down› to the nitty-gritty of explaining to› you how to obtain split baud rates›on your humble Atari 850 Interface›Module!›› How To Do It Yourself›› Ok, where should I start?›I suppose a very basic explanation›of what happens in your interface›handler is as good as any.›› Basically, the handler sets›up the baud rates using the›POKEY hardware timers, which are›stored in the Audio Frequency›registers AUDF1 - AUDF4 (locations›$D200, $D202, $D204, $D206) What I› discovered was that AUDF1 & AUDF2›store the timer value which›represents the transmitting baud rate›(ie the speed at which your Atari›sends data out), and that AUDF3›& AUDF4 store the timer value›which represents the receiving baud›rate (ie the speed at which your›Atari reads data in).›› The timer values are stored›as two-byte integers (ie have a value› of between 0 & 65535) and the›values corresponding to each baud›rate are shown in the table below:›› ----------------------------› Timer Value Baud Rate› 2976 300 Baud› 19661 45.5 Baud› 17891 50 Baud› 15727 56.875 Baud› 11925 75 Baud› 8128 110 Baud› 6646 134.5 Baud› 5958 150 Baud› 2976 300 Baud› 1484 600 Baud› 739 1200 Baud› 490 1800 Baud› 366 2400 Baud› 179 4800 Baud› 86 9600 Baud› ----------------------------› Table of timer values for› specific baud rates› ----------------------------››› Let's take an example. Say›you wanted 1200/75 split baud›rates to access your favourite›Bulletin Board (obviously The›ARK). So, your transmission›speed is 75 baud, and your›receiving speed is 1200 baud.›Look at the table above. The›timer value corresponding to 75›baud is 11925, and the timer value›corresponding to 1200 baud is 739.›› First, set your other parameters,›parity, translation mode, word›ength, etc. When you use the XIO 36›command (or if you are using m/c then›when you call CIO with the cmdno 36)›then treat the baud value as 0 (300›baud - this is simply for›convenience). After you have entered›CONCURRENT I/O mode (XIO 40) then› POKE (or equivalent, depending› on your programming language)›the timer values into the POKEY›registers AUDF1-4.›› In this example, the addresses›and values to be stored in them are›as follows:›› Memory Location Byte Stored› 53760 ($D200) 149 ($95)› 53762 ($D202) 46 ($2E)›› 53764 ($D204) 227 ($E3)› 53766 ($D206) 2 ($02)››› The values can be explained›like this:›› Tx rate:149+256*49 = 11925 (75 baud)› Rx rate:227+256*2 = 739 (1200 baud)›››› Well, that's about it! I›would just like to make it clear that›I have made this important discovery,›and it would be a sad reflection on›any Atari owner if he tried to claim›otherwise.›What the Atari 8-bit needs now›are friends. It has enough enemies›already, with Atari seeming to be›one of them (I won't complain if›anyone at Atari wants to prove me›wrong, but I doubt if anyone will)›› I would like to thank some›people for their help and›inspiration. This may seem trivial,›but it means a lot to me to know›they are there to help if I need›them.›› First of all, I would like›to thank James Bastable, and his›Bulletin Board, The ARK. If it were› not for both James and The ARK›BBS, I would never have made this›discovery, for it was from this›source that I obtained the Source›listing for the RS232 handler.›› I would also like to thank an›ARK user who I know only as NITRAM› (or Martin), who convinced James›to try the patch out on his 850›interface.›› Last, but certainly not least,›I must thank Page 6 magazine, who›have REALLY supported the Atari›8-bits, when others have only›pretended. If it were not for Page 6,›I would not even have found The›ARK BBS, which has featured so›prominently in this breakthrough.››› So remember, even you are›told something is impossible, the›chances are that it's not!››Geoff McHugh,› Co. Armagh››9th October, 1988››