ATARI ASPI PAGE
Go to my ...
Home page
MyDOS page - All kinds of stuff about and for MyDOS.
BlackBox page - with information on FlashROM upgrade.
Special stuff page - these are mainly utilities and text files.
Wishlist page - my personal Dream Street.
Atari 8 bit boot CD/DVD page - create your own Atari 8 bit boot CD or DVD.
Atari 8 bit meetings page - some information about the Atari 8 bit meetings I visite.
Docs page - Files describing peripheral hardware.
Site map - What's on my site and where can you find it.
Cookie statement - My cookie statement.
What is ASPI?
Maybe some of you know ASPI from the PC. Well, since a couple of years, ASPI is available to the Atari 8 bit world too.
What's ASPI in the Atari 8 bit world?
Up till now, you had software that works with the BlackBox or the MIO-interface or the Supra-hard disk-interface (also known as the KPI-interface) or the MSC-IDE controller or some other hard disk interface. Maybe even software that worked on two different interfaces. But never on all of them.
Meaning each programmer working on software for a specific hard disk interface had to basically do the same as his or her colleague working on a similar piece of software for another hard disk interface.
That was until now.
With (AT)ASPI you only need a different version of the ASPI manager if you want to use a different interface. You just load the ASPI manager for your specific hard disk interface (whether it's SCSI or IDE) and then load the tool you want to use. These tools, which DO have to be written specially for the ASPI manager, are totally hard disk interface independent. Meaning they do not know or even care which hard disk interface you are using. For some things though, like CD-ROM control, your hard disk interface needs to support 16 bit access.
One could compare this with the way telecom software for the 8 bit Atari works. You can use 850 Express or BobTerm with a lot of interfaces. This is only possible because:
- the driver is auto-loaded from your interface (e.g. 850, MIO, BlackBox), or
- the right driver has to be selected by the user. A selection of drivers is usually included with the telecom software.
Nowadays, a similar approach is used in the PC scene. Each new piece of hardware comes with a floppy, CD or even a DVD that has a bunch of drivers on it.
ASPI is just like that. Each hard diks interface would come with it's ASPI manager. It could be included in the ROM of your interface or used as a separate file. Including it in the ROM has the advantages that you always have the right ASPI manager for your interface. After loading the right ASPI manager for your interface, you'd load the tool you want to use. This tool would run on ANY interface that is ASPI compatible. Just like BobTerm runs with each modem interface that you can find a driver for.
ASPI for the 8 bit ATARI
Unfortunately the only version of the ASPI manager available at the moment is the BlackBox version.
- BBAS040.COM - The original version by Matthias will load from $8000 to $8800.
Here's the source code in ATMAS II and ASCII format. (ATMAS II is an assembler language just like MAC65, SynAssembler, etc.)
- BBAS041.COM - Lee's first version will load from $8000 to $8800.
A small bug in BBAS040.com has been killed. Since Lee doesn't speak ATMAS II, he translated everything to Mac65 first. Here's the source in .ASM and .M65 format.
- BBAS042.COM - Lee's second version will load from $A000 to $A800.
Here is the source as an ASM file. And here it is as an M65 file.
So all you programmers out there can now create different versions for different interfaces. For that you might need this file BBDOKU.TXT too, to see which addresses the Blackbox uses.
Here's what Matthias Belitz (who came up with the idea and turned it into reality) wants you to know about ATASPI in english and german.
Matthias Belitz' utilities:
Matthias wrote two utilities to show you what ATASPI can do.
Both files are described in Matthias' ASPI text file. The sources in ATMAS II and ASCII hardly differ at all. Apparently, not everybody can read the code in ATMAS II format.
- CD Audio Player or CDAP. CDAP will let you play Audio CD's. It's based on
CDPL020 but has more features.
- CD/DVD Data Reader or DATA (for now). DATA will let you read Data CD's and DVD's. At the moment you can check out every directory on a CD or DVD. I hope to expand DATA to where you can look at and even copy each file on the CD or DVD to (hard/zip/floppy)disk.
- an Atari 8 bit computer with parallel bus interface.
- TurboBASIC.
- the CD audio player.
- a CD-ROM drive (SCSI).
- at least one audio CD.
- the BlackBox.
- the BlackBox ASPI manager.
As soon as other versions of the ASPI manager become available, different
interfaces can be used. These interfaces should support 16 bit access. The
source code is available a bit higher up on this page. If your interface supports SCSI, the CD-ROM drive should be SCSI too. If
it's IDE, so should the CD-ROM drive be.
This is the latest version (147) of my CD audio player (CDAP).
The latest version of CDAP
The listed version of CDAP
The docs to CDAP.146
You need one version of the ASPI manager, not both.
Line 80 in CDAP will load the ASPI manager. Change it so it will look in the right place.
- April 8th 2002:
- I temporarily took out the HELP routines (I keep bumping into the ASPI
manager with my code, so I had to do something). So don't press HELP, H or ?
for the time being. With the HELP routines, I seem to have removed the 'freeze
up after a CD change' bug. I've included the listed version so that even those
without a BlackBox or CD-ROM drive can have a look. On CD's with more then 48
tracks, only 36 tracks are shown at a time. CDAP will always start with the
screen that contains the current track. Pressing Q or W will move you back and
forth between screens. Should I make the screen change when the current track
moves 'off screen'? If everything went OK, pressing O should always get you
what you expect it to do. On CD-ROM mechanisms with trays as well as those
with caddy's or slot-in mechs. Even if you close the tray via the button.
Please read the accompanying text file (CDAP146.TXT).
It explains which bugs are still to be solved and what key to press (remember,
the HELP screens have temporarily been removed). You need a version of the
ASPI manager for the 8 bit Atari. Unfortunately, the only version available is
the BlackBox version. Until this changes you will only be able to use CDAP
(or any other ASPI Tools for the 8 bit Atari) with the BlackBox.
- May 3th 2002:
I am proud to announce that CDAP has been successfully
tested with a CD.
I would like to thank:
- My brother Frank, who sells CD's for a living and didn't wanna believe my
Atari would play these CD's. I asked him to lend me a CD that has the above
mentioned warning on it's cover, so that I could test it.
- Celine Dion, for recording the album "A new day has come", which I used
for testing.
After inserting the CD, you can hear the CD get up to
speed, like a data CD does. CDAP tells me track 18 is a data track. When a CD is
inserted into a CD-ROM mechanism, the CD-ROM mechanism will check what kind of
CD is inserted. If it contains audio tracks only, the CD will be spun at
'normal' speed. If the disk contains data (It tests sector 16 to see what kind
of CD-ROM is inserted), the CD will be spun at maximum speed. The fact that the
Celine Dion CD speeds up and tells me there is an 18th track containing data
instead of sound, tells me some code is auto-loaded (CD's can be boot-CD's. Or
maybe Windows or the MAC OS is to blame for this), that will prevent the CD from
being played on PC's and MAC's. There seem to be special pieces of software for
the PC and MAC that do make it possible to play these CD's on these computers
too. This reminds me of 'the good old days' when software pirating was a hot
topic. Software developers at some point in time learned that heavy copy
protection didn't work. Now the music industry is making the same mistake the
software industry made 15 to 20 years earlier. Maybe one day the'll learn
too.
In a recent newspaper article SONY has confirmed that a file is
loaded to make it impossible to play these CD's on either a MAC or a PC.
- an Atari 8 bit computer with parallel bus interface.
- TurboBASIC.
- the CD/DVD Data Reader.
- a CD-ROM or DVD-ROM drive or burner (SCSI).
- atleast one Data CD or DVD (ISO9660).
- the BlackBox.
- the BlackBox ASPI manager.
From here on, if you see "CD-ROM drive", it also means "DVD-ROM" drive, "CD Burner" or "DVD Burner". But remember, you can only READ these disks. Burning them on an Atari 8 bit computer would need lots of time and lots of memory. And the burners would have to REALLY be underrun proof and I'm not convinced yet that they can handle the relatively slow speed at which the 8 bit Atari can shovel in the bytes.
As soon as other versions of the ASPI manager become available, different interfaces can be used. These interfaces should support 16 bit access. The source code is available a bit higher up on this page. If your interface supports SCSI, the CD- ROM drive should be SCSI too. If it's IDE, so should the CD-ROM drive be.
This is the latest version (69) of my CD/DVD Data Reader (DATA).
The latest version of DATA
The listed version of DATA (temporarily removed)
The docs to DATA.69
You need one version of the ASPI manager, not both.
The LST and TXT files have been converted so that you can view them online.
Line 1000 in DATA will load the ASPI manager. Change it so it will look in the right place.
DATA version 69 will not yet let you read/view or copy files from a CD ROM. It will however let you have a look at the path table (a list of all the (sub)directories on that CD ROM) or any (sub)directory. You can even have a look at what a sector on a CD ROM looks like. Somebody is working on a menu/selector/viewer subroutine for me.
If you have more then one CD ROM drive, DATA will let you choose which one you want to use.
Special thanks to Larry White, without whom's help, I never would have stumbled onto a fairly big bug that I didn't see because of the way my SCSI devices are numbered.
- October 2004:
- To my great pleasure, I can now announce that CD Data Reader will also read ISO 9660 DVD's. Matthias Reichl has informed me, that DVD's can also use the UDF standard. CD Data Reader will only read ISO 9660 disks.
- December 2004:
- CD Data Reader has been officially renamed to CD/DVD Data Reader.
Accessing a data CD actually is easier then accessing an audio CD as there is basically only one command you have to issue, which is the READ sector command. Everything concerning positions and lengths of directories, files, etc. is on the data CD in both low/high and high/low format.
You bet! With just a few minor additions to CD/DVD Data Reader, I have been able to view sectors on my ZIPdrive and my hard disk. On a sector level. Ever had a look at sector number zero of your hard disk? Where the BlackBox saves it's configuration? Check out my BlackBox page!
| A shortcut into programming for the ASPI manager: | |
|
This applies to ALL programming languages, be it (Turbo)BASIC, Assembler, etc. You just have to translate the following into code for the respective languages.
If you read the following and get the impression that it looks familiar, you may not be very far from the truth. Let's start:
LOAD the manager.
Declare the following constants:
DDEVIC=768
DUNIT=769
DCOMND=770
DSTATS=771
DBUFLO=772
DBUFHI=773
DTIMO=774
DBYTLO=776
DBYTHI=777
DAUX1=778
DAUX2=779
Set up the command descriptor block:
- Store/poke 112 in DDEVIC.
This points to ASPI.
- Store/poke 1 in DUNIT.
This points to the number of the ASPI manager. If there would be more than one ASPI manager (the one for the BlackBox), you could use more than one ASPI manager at the same time. This selects which one to use for this operation.
- Store/poke 2 in DCOMND.
2 means execute SCSI command.
- DSTATS is used as the direction byte. $40(64) means read, $80(128) means write. After the command is executed, you can find the error code here.
- DBUFLO and DBUFHI are the two byte address for the data buffer. If for instance you are using the READ command, the data that is read gets stuffed into this location.
- DTIMO is the time out value. 31 will work just fine here.
- DBYTLO and DBYTHI represent the amount of data to be sent. With the READ command, this would be the amount of data that is read into the computer.
- DAUX1 and DAUX2 are the low and high byte address of the location where the SCSI commands are stored.
From here one:
- DBUFLO and DBUFHI are replaced by DBUFR.
- DAUX1 and DAUX2 are replaced by DAUX.
- DBYTLO and DBYTHI are replaced by DBYTE.
A SCSI command looks like this:
- We start with the SCSI ID number. This can be any number from 0 to 7.
- The following is the length of the actual SCSI command. This can be 6, 10 or 12.
- The actual SCSI command. The first byte is the number of the command, the rest is data needed to execute the command.
The are two commands that you absolutely need to use:
INQUIRY looks like this:
x,6,18,0,0,0,36,0
x is the SCSI ID number.
6 is the length (18,0,0,0,36,0 is six numbers).
18 is the code for the INQUIRY command.
The rest is explained in the SCSI standard.
You need this command to ask which SCSI ID's are used and by what devices:
- Set SCSI ID to zero ("x" in the line above)
- Set DAUX to where the above 8 bytes are stored
- Set DBYTE to 36 (this command returns 36 bytes)
- Jump into the ASPI manager using the following routine:
In assembler: JMP ($0002)
In (Turbo)BASIC: store the numbers 104,108,2,0,96 into a string and USR(ADR(string)).
- Then check DSTATS.
Let's assume DSTATS returns a value of one (read: this number is used).
The first byte tells you what kind of a device is found. Bytes 9 through 32 contain (an abbreviation of) the name of the manufacturer and the name of the device.
[The ASPI manager tells you the same thing when it's loaded, but doesn't store this information.]
- Repeat this for all possible SCSI ID numbers.
Now that we know what devices are present, we can start using other SCSI commands. Make sure you set up the command descriptor block for each command (the Atari will reset it, if it needs the same addresses), making sure that you set the DAUX addresses for each command.
After each command, you need to check DSTATS. If it returns a value that's greater than 127, you need to send the REQUEST SENSE command. This asks the device, what error occurred. Kinda like the GET STATUS command. There are so many combinations of error codes that can be returned, that I need to ask you to look at the pages mentioned on my homepage. Maybe at a later date, I can put up a list of these codes.
In short you need to:
- Set up command descriptor block for the command you want to use.
- Jump to ASPI.
- Check DSTATS.
- If DSTATS is 1 everything went OK. The command has been processed by the device.
- If DSTATS >127 something went wrong. Use the REQUEST SENSE command.
The first command used should always be the INQUIRY command. Start at ID zero, then one, etc. I've heard it's save to stop a 6, but in my software I also ask if device 7 is present.
| |
Here are some links to useful sites when it comes to CD-ROM format's/structures/commands:
CD Roller has nice pictures
to show structure of Data CD's.
ECMA the ISO 9660 standard and lot's of others.
Singlix site, more stuff on
CD's and CD-ROMs.
CDRecord, will burn just about any image to your CD. In German!
All the books, (red, yellow, etc.) explained here. (won't work. If you know of a good replacement....)
Seagate's FTP site It contains all kinds of stuff. Look for the file INF8090.PDF. This contains commands for both DVD and CD players and recorders.
Special thanks to Matthias Belitz for coming up with the idea to develop ASPI for the Atari 8 bit computer, for helping me develop CD audio player and for giving me permission to publish his work on the internet.
Try English
|
| oder Deutsch
|
of Nederlands
| of Heljes/Dörps.
|
Please use "Feedback from my ASPI Page" as the subject.
|
|
Go to my ...
Home page
MyDOS page - All kinds of stuff about and for MyDOS.
BlackBox page - with information on FlashROM upgrade.
Special stuff page - these are mainly utilities and text files.
Wishlist page - my personal Dream Street.
Atari 8 bit boot CD/DVD page - create your own Atari 8 bit boot CD or DVD.
Atari 8 bit meetings page - some information about the Atari 8 bit meetings I visite.
Docs page - Files describing peripheral hardware.
Site map - What's on my site and where can you find it.
Cookie statement - My cookie statement.