I was going through some tapes that got with a system a while back and noticed one that I can’t find in the Archives, Logo Pack by ADAMagic.
Keno, Bandit, Lfiler, Menu, Hangman, Stars, Draw, Flite, Boogie, Nerds, Jump and Lander.
I can not figure out how to load the files in SMART Logo when Logo is in disk drive 1 and the games are in disk drive 2 when in the emulator so if you know, let me know.
Logo Pack – ADAMagic disk image
I am proud to announce the first of many new software titles available for the Coleco Adam computer:
For more details and to preorder visit: Retro System Rescue
If you are going to be doing any serious z80 programming then you will quickly find a need for this program. It is code that you can include at the end of your z80 source code and then call it with a simple JP CodeDump command. When you do this it will show you the values of all the registers when it was called and let you move around memory starting at the value you put in the source code at CD_CurLoc. The only caveat is that you need to be in 32 column mode when you enter it. Any other mode will be hard if not impossible to read.
(I want to apologize in advance, I am not a fantastic writer)
I like to code in machine language. Using ML you have (almost) complete control over the Adam and can make it do things as fast as it is possible for it to do it.
Writing ML code on the actual Adam for me is hard because I have been been using modern computers for so long I am used to being able to cut and paste, have multiple files, compile fast etc. So I like to create my code in Windows, compile it and then transfer it to a disk image for testing in the AdamEM emulator and if I want moving it to the real hardware.
Doing so has involved using my editor of choice (ConTEXT), and then using DosBox to emulate a DOS machine and compiling the code using the TeleMark cross-assembler. On a 32 bit machine I could have eliminated DosBox and just used the Command prompt in Windows, but with a 64 bit machine DosBox is required because TeleMark is a 16 bit program. Once I compiled the program I would then use various methods to get it into an image, mostly WRDISK and sometimes TDOS if I was programming for a CP/M environment but I always felt these were cumbersome so I have been working on a method of creating a disk (or tape) image of the compiled program I am working on and have it just load when I start the emulator (or real hardware). After disassembling the Smart Basic Loader, studying the EOS programmers Guide and banging my head against the wall with disk interleaving I finally was able to create a “simple” process to take my machine language source code, compile it and create a working disk image using just one command.
At some point every programmer has made a “Hello World” program. In Smart Basic this is as simple as:
10 PRINT “Hello World”
Writing one in machine language to use under EOS is a little more convoluted to get started as you have to initialize the Video Display Processor to even see anything. Once you get that setup then you can print to the screen. (Click here to view the source code).
Compiling the Code
To compile the code use the Assemble batch file. If all goes well and there are no errors you will have a usable disk (and tape) image. If you look at the assemble.bat file you will see how it works:
rem This batch file will assemble the source code file
rem passed on the command line for example: assemble filename
rem where filename is the name of z80 code you wish to
rem assemble and has the extension of .asm. Do not add an
rem extension. The batch file will use filename for the
rem name of the resulting disk and tape images it creates
rem Did they pass a filename to assemble? If not then exit
if "%1"=="" goto NoFileName
rem Do some clean up of old .obj, .lst, .dsk and .ddp files
if exist %1.obj del %1.obj
if exist %1.lst del %1.lst
if exist %1.dsk del %1.dsk
if exist %1.ddp del %1.ddp
rem Now to assemble the file passed TASM will return an error if
rem we could not assemble it and if that happens we will exit
tasm -80 -b %1.asm
if ERRORLEVEL 1 goto AsmError
rem The code assembled ok so now we need to put it in the disk
rem image for use with the emulator and a real Adam. If you are
rem curious how ImageMkr works just run type imagemkr at the prompt
imagemkr %1.obj %1
rem We are all done so lets exit
echo No file name was passed to assemble
echo Error while assembling
if exist %1.obj del %1.obj
if exist %1.lst del %1.lst
rem All done so exit
Can you do the following and let me know your results:
- Download this zip file
- Unzip it and start AdamEm with File Manager as disk 1 and the image called Heather as disk 2
- Press F5 to switch to disk 2, F2 for Media Functions and F4 for edit
- Press F3 for Block Number and type in a 2 and hit enter.
- Press Enter again
- Now you are looking at Block 2 Sector 0. On a real Adam press Home and Up arrow until you are looking at Sector 4. In the emulator press the “5” on the keypad and the up Arrow (at same time)
- Does it look like the screen shot to the right? All zeros?
- If it doesn’t let me know
- If it does then humor me and go to Hex Edit and upload the file called HEATHER.DSK and then scroll down till you get to the section starting with 00000A00
- You will see that there is code there, but the same corresponding bytes in the image are zeros. You can verify this by scrolling up a to sector 3 in the image on the emulator and seeing the last of the code that loads
Please let me know your results – either here or on Facebook
Thanks to the information from Eric I was able to determine that I was not taking into account the interleaving of the data on a disk image. The tape images do not use that so it confused me when I started working with disk images. If you are curious how it works here it is where the first number is a 256 byte sector and the second number is the actual sector it should go in. This is using 4kb blocks:
0 -> 0
1 -> 1
2 -> 10
3 -> 11
4 -> 4
5 -> 5
6 -> 14
7 -> 15
8 -> 8
9 -> 9
10 -> 2
11 -> 3
12 -> 12
13 -> 13
14 -> 6
15 -> 7
I have disassembled and commented the Smart Basic (SB) Loader. This is the 1kb block that is loaded when you have a SB tape or disk in a drive and you pull Reset. It is an interesting bit of code.
Smart Basic Loader.pdf
I have uploaded 1800+ disk and tape images that have been archived by James Notini (THANK YOU!) and you can access them at:
Coleco Adam Disk and Tape Images
There was a request on Facebook for a copy of DBase II that could be used on the ADAM so I created 3 disk images from the Kaypro distribution on Retro Archive. I had to split it up over 3 disk images.
Based on a conversation I had on FaceBook and after reviewing the disassembly of the program written by Stephen Munnings in 1985 called GameSave that would dump the contents of a cartridge plugged into the Adam to a file in CP/M that you could then execute I have created a newer hybrid version of this: MakeRRom.
MakeRRom (Make Run-able ROM) is a program written in Turbo Basic, an old MS-DOS compiler created by Borland that I have been using for almost 30 years. MakeRRom will take a PC file that contains a ROM cartridge dump and create a CP/M (or TDOS) compatible program that you can then import into a disk image for use in the ADAMEm emulator or copy over to your real Adam. Unlike GameSave you do not have to have the cartridge and you create your files on your PC.
How it works:
The heart of MakeRRom is a 32 byte Z80 assembler routine that handles setting up the Adam to execute the file as if it was a ROM cartridge:
The program MakeRRom then takes this code, appends the code for the ROM cartridge and then saves it as a .COM file to be used in CP/M or TDOS.
When you run the created file the Z80 code will copy the appended ROM data to 8000H (the upper 32KB bank of RAM) and then copy the small loader called JumpCode to the top of memory and execute it. JumpCode in turn sets up the Colecovision OS7 Rom in the lower 32K bank and jumps to the cartridge start point.
How to use MakeRRom
MakeRRom.exe is a 16 bit program so you may need to run this either in DosBox or on an older PC. To use it, copy MakeRRom.exe and the ROM file you want to work with into the same folder. Then at the dos prompt type:
C:\> makerrom filename.ext
And after a few moments it will create a file called filename.com that is your ROM file and the loader. Then you can use the process I described here to import it into TDOS or CP/M.
In the download below I have included a copy of the Cabbage Patch Kids Adventure ROM called patch.rom and the resulting patch.com file. If you use Debug to view the ROM file and the .COM file you will see how the first 32 bytes of the .COM file are the Z80 loader.
Cool – but why do it?
The simple answer is because I can. The more complex one? I can download all the Colecovision ROMs online, batch convert them into .COM files, import them all into a TDOS IDE image, copy the image to compact flash and now have all of them available to run at anytime on my Adam 🙂
I mentioned in a previous post about Adult software for the Adam – here is a disk image of the Strip Poker game from Adam Zap. It is in Smart Basic so if you don’t want to try and beat the game, press ctrl-c to exit the game and use goto 2000 at the Basic prompt to cycle through the various erotic pictures.