PDA

Просмотр полной версии : TR-DOS with ramdisc for all 1MB ZX clones



VELESOFT
14.01.2013, 22:12
My idea is modify any new tr-dos 6.xx for use on other zx clones than only Pentagon 1024. For example tr-dos 6.11E exist in version for Pentagon 1024 and can be compiled also for ATM TURBO computer. Also exist tr-dos 6.11P for ZXM PHOENIX using paging ports 7FFD and 1FFD.

Can anyone help me with modification one of this versions (ideal 6.11P) for ZX PROFI 1024 or SCORPION 1024 memory paging ports ? I see in tr-dos 6.11P table of values for paging ports then modification for other clones can be easy = only rewrite values in table and ram paging ports. Which routines I must modify in source code ?

source code of tr-dos 6.11P (ZXM PHOENIX):
http://micklab.narod.ru/file/trdos6_11p.rar

I also need change size of ramdisc to 640kB after format.

VELESOFT
15.01.2013, 22:06
And what about this routine ?



LD BC,#EFF7
LD D,CMOS_F_PAGE
LD A,#80
OUT (C),A
LD B,#DF
OUT (C),D
LD B,#BF
IN E,(C)
XOR A
LD B,#EF
OUT (C),A
LD D,A
LD HL,PG_TAB
ADD HL,DE
LD BC,#1FFD
LD A,(HL)
OUT (C),A
INC HL
LD A,(HL)
LD B,#7F
OUT (C),A
POP IX
EI
RET

VELESOFT
16.01.2013, 00:06
Hmm, your source is bad:


SjASMPlus Z80 Cross-Assembler v1.07 RC7 (build 02-04-2008)
Pass 1 complete (0 errors)
Pass 2 complete (0 errors)
> Free space at 0x0031: 7 byte(s)
trdos611p.asm(376): error: Label not found: TfndRD
> Free space at 0x083F: 193 byte(s)
> Free space at 0x0B01: 1303 byte(s)
> Free space at 0x1788: 29 byte(s)
> Free space at 0x1F00: 22 byte(s)
trdos611p.asm(4977): error: Label not found: MAGICER
trdos611p.asm(4994): error: Label not found: MAGSTOPDISK
trdos611p.asm(5598): error: Label not found: MAGregR
trdos611p.asm(5639): error: Label not found: MAGsetR
> Free space at 0x3215: 7 byte(s)
> Free space at 0x377E: 1202 byte(s)
> Free space at 0x3CAD: 77 byte(s)
> Free space at 0x3FF6: 10 byte(s)
trdos611p.asm(7337): error: Error opening file: out\TR-DOS 6.11P.ROM

VELESOFT
16.01.2013, 00:51
Compiled ok :-) I go test it

VELESOFT
16.01.2013, 01:29
Tr-dos 6.11p now work with ZX PROFI 1024 :-)

My idea is : same ramdisc layout in 1MB memory for Pentagon 1024, Scorpion 1024, ZX PROFI 1024. I must make also version for Scorpion 1024.

My PROFI interface(for ZX128+2) support Pentagon memory, Scorpion memory and ZX Profi memory paging. All three modes use full 1MB (same ram). I can switch between memory modes + roms and ramdisc will always usable :-)

---------- Post added at 19:29 ---------- Previous post was at 19:27 ----------


Are you sure? :)

Sorry, my bug. SJASMPLUS compile ok :-)

VELESOFT
16.01.2013, 02:15
Awesome! Also you can take trdos from attached file and add some more configuration options. That was planned some time ago but something goes wrong in my head... :) And everything should be checked twice, cos sources were built in 2010, so some issues could be forgotten... :v2_dizzy_vodka:

Yes, new source contain config at begin. Is possible select computer type, ramdisc drive, etc...

I have one universal source code of tr-dos for 4 memory models : ZX PROFI 1024, PENTAGON 1024, SCORPION 1024, ZXM PHOENIX 1024/2048.
I test all 4 tr-dos versions in unrealspeccy emulator and work correct :-)

VELESOFT
16.01.2013, 21:40
This "state of the art" version of trdos I want to be destroyed everywhere on the internet :) I will ask Mick to delete it later. Here is the right version for ZXM-Phoenix...

Next bug in your TR-DOS 6.11P - bad text on screen (show "BETA2048s" instead "BETA2048"):
http://velesoft.speccy.cz/other/trdos611p_text_error.png

BUG detected: in your source code absent data of text (from label TfndRD) :

Actual bad source:

DISPLAY "Free space at ",$,": ",/D,#1018-$," byte(s)"
DS #1018-$,#FF

And here is correct code (used from original trdos 6.11E):

DISPLAY "Free space at ",$,": ",/D,#1000-$," byte(s)"
DS #1000-$,#FF

TfndRD DB #16,9,5
DB "Found RAMDISK memory",0

VELESOFT
17.01.2013, 03:03
TR-DOS 6.11Q for Pentagon 1024, ZX Profi 1024, Scorpion 1024, ZXM Phoenix 1024/2048

http://velesoft.speccy.cz/other/TR-DOS_6.11Q_PENTAGON1024.png http://velesoft.speccy.cz/other/TR-DOS_6.11Q_ZX_PROFI1024.png
http://velesoft.speccy.cz/other/TR-DOS_6.11Q_SCORPION1024.png http://velesoft.speccy.cz/other/TR-DOS_6.11Q_ZXM_PHOENIX.png

First betaversion of TR-DOS roms:
http://velesoft.speccy.cz/other/TRDOS-6.11Q_BETAVERSION.zip

source code of TR-DOS 6.11Q (this is only beta version !!!):
http://velesoft.speccy.cz/other/trdos611q-betaversion1.zip

Source contain full NMI support from tr-dos 6.11e and table for memory paging ports is moved to free space in trdos rom.

VELESOFT
18.01.2013, 02:08
This "state of the art" version of trdos I want to be destroyed everywhere on the internet :) I will ask Mick to delete it later. Here is the right version for ZXM-Phoenix...

What changes are in your tr-dos 6.11p ? (from original 6.11e)

NMI routines you replace with paging table, RST0 is different (why ?), RTC support removed (why ?), any other changes ?

In TR-DOS6.11Q I refresh original NMI code and paging table is moved to free (unused) memory. Now is assembly without errors. But I need know if exist other modifications than only NMI and RAMDISC routines.

solegstar
19.01.2013, 19:23
VELESOFT , is possible to integrate a token/command which changes the letter RAM-DISK instead of "D" for "A" into TR-DOS6.11Q? there are programs with "drive A only" problem.

---------- Post added at 17:23 ---------- Previous post was at 17:19 ----------

and back on "D". value of a variable can be stored in GLUK CMOS.

VELESOFT
19.01.2013, 19:42
VELESOFT , is possible to integrate a token/command which changes the letter RAM-DISK instead of "D" for "A" into TR-DOS6.11Q? there are programs with "drive A only" problem.

---------- Post added at 17:23 ---------- Previous post was at 17:19 ----------

and back on "D". value of a variable can be stored in GLUK CMOS.

CMOS is usable only on some clones. I use this trdos without real FDD and ramdrive is "A". And work more programs with access only to "A" drive :-)
I can add CMOS support from orig. version 6.11E...
Make new command for change RAMDRIVE number is possible, but I don't know this routines in tr-dos. If anyone can help with this feature.... This command must write one byte with ramdisc drive number to system variables in zx ram(we must find one free/unused byte), but if any software rewrite this byte, trdos can see incorrect ramdisc drive number... :-(

One idea: we can save tr-dos setup also to 1MB ram. For example at begin of 16th ram page = first 256kB ram(ram pages 0-15) is full usable for ZX software with 256kB support. Next page(page 16) at begin contain setup = word "cfg:"+bytes with ramdrive and similar setup. If this "cfg:" text are not detected then tr-dos can use default tr-dos setup (ramdisc on drive "D")

solegstar
19.01.2013, 20:00
I use this trdos without real FDD and ramdrive is "A". And work more programs with access only to "A" drive :-)

how it is possible if the letter RAM-DISK is set as "D"?

VELESOFT
19.01.2013, 21:04
how it is possible if the letter RAM-DISK is set as "D"?

Source code of this tr-dos version contain at begin small config:


;========== SETUP ==========

;------- select only one memory model ------
DEFINE RAM_ZX_PROFI_1024
; DEFINE RAM_PENTAGON_1024
; DEFINE RAM_SCORPION_1024
; DEFINE RAM_ZXM_PHOENIX

;------- select for autoboot tr-dos ------
; DEFINE RUN_BOOT_B_ON_DOS_START
; BOOT_ON_CMD_8

;------- select for enable testing drives -------
; DEFINE TEST_DRIVES

;------- select for madrom support -------
; DEFINE COMPILE_FOR_MADROM

;------- select for active patch for fix HL' register -------
DEFINE FIX_HL

;------- select for enable NMI code -------
; DEFINE NMI_ENABLE

;------- number of ramdisc drive -------
RMD_DRIVE EQU #03 ;ramdisc on drive A(#00),B(#01),C(#02),D(#03)

;------- ramdisc size (free space) --------
RMD_SIZE EQU #09F0 ;ramdisc size(only free sectors = full capacity - 16 sectors)
;( #0DF0=896kB / #0BF0=768kB / #09F0=640kB / #07F0=512kB / #05F0=384kB / #03F0=256kB / #01F0=128kB )


You can change ramdisc drive on this lines to value #00:
;------- number of ramdisc drive -------
RMD_DRIVE EQU #03 ;ramdisc on drive A(#00),B(#01),C(#02),D(#03)

I can send you trdos compiled with ramdisc drive on "A" :-)
I use WDC in service rom(start after reset/power on ZX) and this tr-dos with ramdisc on "A". WDC after start show FAT32 + drive "A". Problems is with some booters (ofter use custom loaders and work only with real FDD).

---------- Post added at 15:04 ---------- Previous post was at 14:17 ----------

Here is screenshot of same trdos 6.11q compiled with ramdisc on drive "A":
http://velesoft.speccy.cz/other/TR-DOS_6.11Q_ZX_PROFI1024_RMD_A.png

And here you can download all 4 ROM images with trdos 6.11q with ramdisc on drive A:
http://velesoft.speccy.cz/other/TRDOS-6.11Q_RMD_A_BETAVERSION.zip

VELESOFT
19.01.2013, 21:44
VELESOFT, you can use command "4" or "8" for changing ram-disk drive letter, in addition to CMOS support.

Yes, but I need know way :-(

VELESOFT
20.01.2013, 00:36
Feel free to use "*" command as working example ;) Also you should notice that NVRAM implementation on ZXM-Phoenix is soooo sloooow:

Take a look into FORMAT command for example how to notify user about performed actions, e.g. "Saving to GLUK CMOS". For example, we are choosing "4" command for setting ram-disk drive letter, something like: 4"B:"<enter>
What we need to do when enter key pressed:
1. PRINT "Saving to GLUK CMOS"
2. Disable interrupts
3. Save to GLUK CMOS
4. Enable interrupts
5. Return with OK.

I can use this syntax:
*"rmd a" - *"rmd d" for change ramdisc drive. OK ?
Save to CMOS is good feature, but must exist autodetection ? This device is unknown for me.

If I will save info about ramdics drive to extra ram page then will usable on all computers with 1MB memory and without cmos chip. After poweron will set default ramdisc drive "D" and in any time can user mount ramdisc to any other drive. After reset are 1MB memory not erased, yes ? Then trdos after restart/reset can detect if exist ramdisc setup in higher memory and change always ramdisc drive from "D" to custom value from setup. Problem can be on computers where reset button disable refresh for dram chips and can destroy ram data.

VELESOFT
21.01.2013, 03:18
I can use this syntax:
*"rmd a" - *"rmd d" for change ramdisc drive. OK ?
Save to CMOS is good feature, but must exist autodetection ? This device is unknown for me.

If I will save info about ramdics drive to extra ram page then will usable on all computers with 1MB memory and without cmos chip. After poweron will set default ramdisc drive "D" and in any time can user mount ramdisc to any other drive. After reset are 1MB memory not erased, yes ? Then trdos after restart/reset can detect if exist ramdisc setup in higher memory and change always ramdisc drive from "D" to custom value from setup. Problem can be on computers where reset button disable refresh for dram chips and can destroy ram data.

Ramdisc drive switching work perfect, but I support this feature only on my PROFI interface ( *"RMD A" - *"RMD D" ). Save setup in extra memory is hard because this code need often test 128kB ram pages. Save to CMOS can be implement only if anyone send me code for it (write one byte to CMOS memory and read this byte from CMOS memory). I will also add possibility disable ramdisc via *"RMD OFF"...

alvis
21.01.2013, 03:43
I can use this syntax:
*"rmd a" - *"rmd d" for change ramdisc drive. OK ?
Save to CMOS is good feature, but must exist autodetection ? This device is unknown for me.

Может глупость скажу, но почему бы не использовать стандартный синтаксис комманды Subst ?

VELESOFT
21.01.2013, 04:20
Может глупость скажу, но почему бы не использовать стандартный синтаксис комманды Subst ?

*"A" - *"D" = select drive

Ramdisc emulate one of four drives and you can set number of drive which is emulated with ramdisc.

For example:

*"RMD A" = ramdisc(fdd emulation in 1MB ram) are instead drive A and drives B,C,D are used as FDD.

*"RMD D" = ramdisc(fdd emulation in 1MB ram) are instead drive D and drives A,B,C are used as FDD.

*"RMD OFF" = disable ramdisc, all 4 drives are used as FDD

solegstar
21.01.2013, 14:46
It is possible to store ram-disk drive letter and/or other configuration params in RAM if you will prohibit writes to sectors 9-F of the track 0.

да, но ведь при сохранении рамдиска в образ TRD, этот параметр таки запишется... есть еще, кстати, командеры, которые вписывают себя в это место...

VELESOFT
21.01.2013, 19:30
я думаю что там компромисс можно найти...

I need know one unused byte in zx ram (system variables/tr-dos variables) for save info about current ram page = during testing drive number tr-dos rewrite this byte. If you know this adress, then setup in extra ram is no problem.
In TR-DOS source configuration I can add three ways for save setup:
- save to CMOS
- save to 1MB memory (zx ram)
- save to PROFI INTERFACE port
- autodetection....
Setup in 1MB ram can be at end of ram page 16. First 256kB(ram pages 0-15) can be used for software/games, next ram page 16 used for save setup, pages 63-17 reserved for ramdisc.

---------- Post added at 13:30 ---------- Previous post was at 13:27 ----------

What CMOS memory adress are free and what space is used/reserved on ZX clones ? Exist any info ?

VELESOFT
22.01.2013, 02:11
I can on Pentagon 1024kB support "128kB only" mode for software (if user need). Access to higher (>128kB) ram will enable on port EFF7(reset bit D2) only in TR-DOS = only trdos can work with ramdisc. Out of TR-DOS rom will Pentagon visible as true Pentagon 128 = better compatibility with 128kB software and ramdisc data are protected.

alone
22.01.2013, 15:46
There are a lot of software supporting more than 128KB on Pentagon - BGE, Lara Croft, Melon, Walker demo, Imperia 2, Homer Simpson in Russia 1-2, Crime Santa Claus Deja Vu, copiers, zines etc.

VELESOFT
22.01.2013, 20:38
There are a lot of software supporting more than 128KB on Pentagon - BGE, Lara Croft, Melon, Walker demo, Imperia 2, Homer Simpson in Russia 1-2, Crime Santa Claus Deja Vu, copiers, zines etc.

I know. Memory 1MB can be enable or disable with new commands in TR-DOS (selectable feature). :-)