General Category > LisaList2
MacWorks XL ROM serial drivers
D.Finni:
I'm writing an application that uses the Macintosh ROM serial drivers, following Inside Macintosh volume II. Anyone know if there are any gotchas to using these drivers in MacWorks? Do they actually exist in the 64K ROM image that MacWorks provides?
I know about SERD, the RAM-based serial drivers, but would prefer to use the ROM drivers if possible.
sigma7:
From memory...
Yes, the SERD is available in the MW/MW+/MW+II ROM.
It is patched to make it work with the (slightly) different Lisa hardware.
IIRC, the later versions of MW+/II had updated SERD in ROM, as they couldn't rely on being able to patch a disk based SERD at runtime to work with the Lisa hardware. ie. they would prevent a disk based SERD from replacing the ROM version (but the ROM version wasn't as old as the one in the MacPlus ROM, so no real need to load a disk based version).
As for gotcha's, I think things like external clocking and directly accessing the serial hardware to do handshaking won't work without special-casing the Lisa hardware. Handshaking through the SERD does work.
Also note that the Lisa can't process data as quickly as the MacPlus, so a performance intensive test suite that runs on the Plus and fails on the Lisa doesn't necessarily indicate a bug.
HTH
rayarachelian:
So a note of clarification for other readers who may not understand how MacWorks functions, when you guys say in ROM, you really mean the ROM Toolbox from the point of view of the macos old world ROMs on 68k machines.
The ROM toolbox ships as part of the first MacWorks disk (boot) and is mapped by MacWorks using the Lisa's MMU to the same space as the ROM toolbox on an actual Mac Plus/512K(e), but physically lives in the Lisa's RAM and isn't actually in the Lisa Boot ROM. (And of course has been modified so that the I/O drivers in it account for the Lisa's actual hardware rather than the Mac's and QuickDraw has been updated to support the Lisa's larger display size)
There are good resources about MacWorks here:
* http://ruby.he.net/~sigma/mwplus2.html
* http://lisa.sunder.net/MacWorks_Plus_Technical_Overview_by_Chuck_Lukaszewski3.pdf
* http://lisa.sunder.net/Mac_128K_ROM_Globals_Index_compiled_by_Chuck_Lukaszewski.pdf
* https://en.wikipedia.org/wiki/MacWorks_XL
* https://en.wikipedia.org/wiki/MacWorks_Plus
* https://en.wikipedia.org/wiki/Macintosh_Toolbox
* https://en.wikipedia.org/wiki/Old_World_ROM
D.Finni:
Thanks, both of you. Yes, I realize that in MacWorks, ROM is in RAM. And Ray you are correct in that I am referring to the serial drivers which are in ROM in a conventional Macintosh (512K, Plus, etc).
I am writing a networking application that targets the Mac 128K, 512K, and Macintosh XL, so I want to keep RAM usage to a minimum for the Mac 128K. This means I want to use the built-in serial driver on that Mac.
I've read over a handful of documents, including Software Supplements from 1985, and haven't found anything that explicitly says that there are no ROM serial drivers under MacWorks. But the problem may actually be Printer vs Modem port. I'm using the Modem port, but on a Mac XL the ports are not the same.
(Actually, they're not the same on a conventional Macintosh, as Modem port has a higher interrupt priority than Printer, but I understand that the two ports are more similar than on a Mac XL)
sigma7:
--- Quote ---they're not the same on a conventional Macintosh, as Modem port has a higher interrupt priority than Printer, but I understand that the two ports are more similar than on a Mac XL
--- End quote ---
This is also true under MacWorks. In particular, during floppy disk access, the floppy driver disables interrupts and polls (only) the modem port for data. Incoming data on the printer port can be lost. This feature was/is quite evident when downloading a file from the printer port to a floppy disk.
Rick recently asked me if the PFG can affect the modem port when using an environment other than MW+II (currently the only environment that recognizes the PFG)... and yes it does, breaking the baud rate setting. So if you have a PFG installed (in the SCC socket on the I/O Board) and are trying to use the Modem Port under eg. MacWorks XL, it probably doesn't work.
See this thread for details...
Serial A Baud Rate correction when PFG installed but NOT using MacWorks Plus II
It would certainly be nice if your software could compensate for the PFG when using a non MW+II environment. I think this would be relatively straightforward in that you would need to directly access the hardware to determine if the PFG is there, and over-ride the baud rate generator time constant accordingly (by writing your own value after the SERD sets it). Let me know if you'd like me to document how to do this. (In the meantime, probably wise to get it working without the PFG first rather than waiting for me.)
Navigation
[0] Message Index
[#] Next page
Go to full version