CoCo-Flash can work on a Dragon/Tano

A place to discuss everything Dragon related that doesn't fall into the other categories.

CoCo-Flash can work on a Dragon/Tano

Postby pser1 » Tue Feb 20, 2018 9:51 pm

Hello,
I just wanted to share with you a program I have developped to help use the CoCo-Flash module (Retroinnovations - Jim Brain) that
contains 8 Mytes of FLASH memory, 64k of SPI EEPROM and as a bonus it has a full compatible Orchestra 90CC double DAC incorporated.

I'll be commenting on upcoming messages
By now, you might have a look at a few screenshots of the program

Screenshot-01.jpg
Screenshot-01.jpg (42.14 KiB) Viewed 277 times
screenshot-05.jpg
screenshot-05.jpg (42.05 KiB) Viewed 277 times

screenshot-15.jpg
screenshot-15.jpg (46.43 KiB) Viewed 277 times
screenshot-21.jpg
screenshot-21.jpg (41.44 KiB) Viewed 277 times

screenshot-22.jpg
screenshot-22.jpg (34.51 KiB) Viewed 277 times

I am attaching here a zip file containing some utilities and a test version of the program that will run on XRoar (to practice a little)
It contains a folder with the name Docs where you will find the User's Guide and an overall program description that I will put here
in next messages for people that won't download the package

cheers
pere
DFEM14U-Distribution.zip
(1.26 MiB) Downloaded 15 times
pser1
 
Posts: 942
Joined: Sun Mar 25, 2012 7:32 pm
Location: Barcelona (SPAIN)

Re: CoCo-Flash can work on a Dragon/Tano

Postby Go4Retro » Fri Feb 23, 2018 2:48 am

Yay!

I am happy this is working.

JIm
Go4Retro
 
Posts: 1
Joined: Thu Feb 22, 2018 12:47 pm

Re: CoCo-Flash can work on a Dragon/Tano

Postby pser1 » Fri Feb 23, 2018 12:40 pm

Hello,
The flash memory in this module is maped to $c000-$feff (16k-256 bytes) so it can contain any Dragon-CoCo2 ROM we have.
Moving that 'visible' window along the FLASH contents we can store/read bigger programs (BIN or BAS files)
You will find info about that module here:
http://www.go4retro.com/products/cocoflash/

I named the program 'DFEM' that stands for "Dragon Flash Eeprom Manager"
The program will 'flash' programs in chunks of 16k, from $3000-6fff and later you could start them from the program list.
I decided to allow Binary and Basic programs besides the normal ROMs, so I added some code to copy those programs to RAM
and execute/run them. These loaders are part of the Program Manager, so there is no need to add them at the beginning of
the programs we want to store in Flash.

To make it easy for the user, the module should contain a customized version of my DosPlus5.0 extended (DP50E from now on)
on bank zero. We will flash it here if it isn't yet there.
This DP50E customized version will copy some code into RAM and start it.
The copied code will switch the bank on the flash module so that it can copy the Program Manager and in turn, start it.
The only thing that the user has to do is press the button on the flash module that prevents the ROM from autostarting.
The DOS must be called by the Basic after it has initialized the Dragon. If you don't press that button, the Dragon will simply hang :-(

I have used the SPI EEPROM included in the module as a database where the relevant data for each program is stored.
The idea was given to me by Jim Brain.
The programs are always shown in alpha order. Basically the EEPROM contains records that point to the next one, so it is a simple linked list.

To get an idea about the capacity of that module, let's assume that all programs (Binaries/Basic/Rom) will have a mean length of 16k,
then as it has 8 Mbytes, we could add (8Mb/16k) -> 500 programs, but if they are smaller then we could add a lot more.
The limit imposed by the EEPROM database is 1600 entries, so it seems that we will not have problems for that reason.

I have created two tables into the EEPROM to help work with these program entries
- One that contains 26 Categories that can be assigned to any program
- Another for HotKeys that admits 26 entries too.
The Category can be shared by many programs, while the HotKey will point to only one program.

regards
pere
pser1
 
Posts: 942
Joined: Sun Mar 25, 2012 7:32 pm
Location: Barcelona (SPAIN)

Re: CoCo-Flash can work on a Dragon/Tano

Postby pser1 » Fri Feb 23, 2018 1:01 pm

3rd part

HOW TO CONFIGURE THE FLASH MODULE TO WORK ON THE DRAGON
==========================================================
Most probably the flash will arrive to us with software for the CoCo, so we need to erase it.
The procedure we shoud apply, using some tools I included in the pack, is this
1) We CLOADM"FERASALL.WAV" or DWLOAD"FERASALL.BIN", it will ask you for the slot number where the Flash module is,
you can answer 0 (for no MPI) or 1-2-3-4
Once selected, the chip will be fully erased. Don't worry if it lasts some time. The program sends only one command to
the chip but it takes long to do the task.
2) We need to flash the Program Manager, I call it DFEM (Dragon Flash Eeprom Manager), we will use CLOADM"F16KFM.WAV"
or DWLOAD"F16KFM.BIN", again it will ask where the module is.
3) Finally we will flash a customized version of the DP50E that will start the DFEM, for this step we CLOADM"F16KDP.WAV" or DWLOAD"F16KDP.BIN"

From that point on, we may start/restart the Dragon/Tano while pressing the button on the flash module.
The Basic will call the DP50E and this will exec the DFEM so the main menu will be displayed.
On entering the program, it verifies if the EEPROM database exists, and if it is not yet created, it will create/format the EEPROM as needed.


POSSIBLE HARDWARE SETUPS
=========================
Apart from our Dragon and the Flash Module, we need some way to access/load program files to RAM from some external hardware
in oder to flash them into the module with the DFEM

These are the choices I have tested
- A drivewire serial to USB converter, conected to a PC(Mac) where we are running a Drivewire server (DW4)
This is my preferred setup! Alternative: any small Arduino/R-Pi that does the same function.
By the way, here you can see one adapter for that setup
http://tormod.me/products.html

- A Tandy Multi-Pack (MPI) or a mini-MPI, together with a CoCo-SDC
This one has the advantage of enabling us to use the Orchestra 90CC from the flash module to access the score-disks
from the CoCo-SDC, despite the procedure is a bit tricky. I explain it below

Someone could also try to replace the CoCo-SDC in this last setup with a drive controller but this has not been tested by me.

HOW TO PLAY ORCHESTRA 90CC SCORES FROM THE COCO-SDC USING THE COCO-FLASH
==========================================================================
- Set the MPI to the slot where we have the CoCo-Flash module
- Start the Dragon/Tano while pressing the button on the module
- Exit the program with '3'
- DWLOAD"SWMAP1.BIN" or CLOADM"SWMAP1":EXEC so that the DP50E gets copied into RAM (MAP1)
- SDRIVE1,"MUSICA" ... assuming that MUSICA is a folder where we have up to ten VDK with ORC90 scores.
This changes to the slot where the SDC is
If you don't remember the folder name, you can use SDIR to find it out as usual with the CoCo-SDC
- SLOTN4 (or the number where we have the flash), to set the MPI switch back to where the Flash is.
Use the number 1-2-3-4 upon where you have the Flash module
- POKE&HFFDE,0 to switch to MAP0 because programs reside in ROM (Flash)
- EXEC&H1400 to enter the DFEM
- '1' to go to Program Management
- Search for the Orchestra90cc and press 'S' to start it
- Press Shift-Enter on the credits screen (recommended to be able to play at double speed)
- Now we need to change 'internally' to the slot where the SDC is
In my case is slot #1, so I enter command '0' and enter in Orchestra (commands 0-1-2-3 switch to slots 1-2-3-4)
- Now you can work with Orchestra using the contents of the selected disk in drive 1.
Remember that pressing the button on the SDC changes to the next numbered disk in that folder (only works on drive 1)

As I want to listen to all of the scores in the disk, I do enter
- Y * (and shift Enter)
You can connect the stereo audio jack output on the Flash module to any amplifier to listen to the music.
Enjoy!
pere
pser1
 
Posts: 942
Joined: Sun Mar 25, 2012 7:32 pm
Location: Barcelona (SPAIN)


Return to Dragon General

Who is online

Users browsing this forum: Bing [Bot] and 1 guest