News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

X-MASS, a mass-storage expansion for all CPC.

Started by TotO, 18:32, 14 December 14

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

SOS

Quote from: TFM on 23:45, 27 January 16
The problem is here the BDOS, the other 'COPY' ROMs use standard file-I/O and they work with all other DOS. The best is to be patient and wait for ACMEDOS.  :)
ACMEDOS didnt support Cas-in-Char and maybe other problems will occur (e.g. Read-Sector is not supported and Cas-Catalog on a FAT-Drive with Directorys may be
different to the standard Cas-Catalog, ...).

HAL6128

Quote from: SOS on 06:47, 28 January 16
ACMEDOS didnt support Cas-in-Char and maybe other problems will occur (e.g. Read-Sector is not supported and Cas-Catalog on a FAT-Drive with Directorys may be
different to the standard Cas-Catalog, ...).
Just wait. Cas-in-Char and Read-Sectors are generally possible. I' m convinced that ACMEDOS will provide more than only a plain user's DOS. :)
...proudly supported Schnapps Demo, Pentomino and NQ-Music-Disc with GFX

TFM

Quote from: SOS on 06:47, 28 January 16
ACMEDOS didnt support Cas-in-Char and maybe other problems will occur (e.g. Read-Sector is not supported and Cas-Catalog on a FAT-Drive with Directorys may be
different to the standard Cas-Catalog, ...).


How can you know? It's not released yet!  :laugh:
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

SOS

#353
Quote from: TFM on 17:00, 28 January 16

How can you know? It's not released yet!  :laugh:
SyX wrote it:
"There is a few amsdos calls not implemented yet, CAS_IN_CHAR and CAS_OUT_CHAR. And the low level amsdos routines for Read/Write sectors and format tracks."
(see reply 245 in this thread)
And the part with the directory, i added 1+1 .....

(Added: 18:30):
And not to forget the handling of the DPB and maybe other things ...

TFM

That's snow from last year. Let him finish in peace and then we see what we get.  :)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

netmercer

Hi,
I'm playing a little bit around with CF-card, 44-pin adaptor, X-MASS and CP/M+. Basically it runs very well.  :D
But because of the bank switching of CP/M I needed some place in common RAM for a part of the X-MASS driver. Actually I put it in a RSX, which I had to load after booting CP/M. :(
See pictures below.
[attach=2]
[attach=3]
A disadvantage of this method is, that I lost at least 1K of TPA and I had to load the RSX after booting from disk (the picture shows programm B:CFM.COM, which does this). Booting alone from CF-card without disk drive is not possible.
Does someone know a small safe place in common area (address above F600h) for ca. 43 Bytes?
How about placing this bytes in upper ROM? But what to do with RST7 Interrupt, which aims
into common RAM ? Would be a simple "DI" instruction enough? ::)

Kind regards
netmercer

Fessor

What about using Dobbertins CP/M / CP/M+ and modifying their HD-drivers or using their mechanism?


HAL6128

Good point!

I want to dare (maybe a silly) question because I have no clue about modifying existing software:

Dobbertin is using following ports for their harddisc:
 #FBE0  Dobbertin Harddisc Data Port (read/write)
#FBE1  Dobbertin Harddisc Status (read), Reset (write)
#FBE2  Dobbertin Harddisc Select (write), Configuration (read)
#FBE3  Dobbertin Harddisc DMA, Interrupt (Used on CPC???)
#FBE4  Dobbertin Harddisc Reset (read or write will reset)

The Symbiface or X-Mass allow following I/O ports:

#FD08    IDE Data Register    IDE Data Register
#FD09    IDE Error Register    IDE Features Register (Write Precomp Reg.)
#FD0A    IDE Sector Count    IDE Sector Count
#FD0B    IDE Sector Number    IDE Sector Number
#FD0C    IDE Cylinder Low    IDE Cylinder Low
#FD0D    IDE Cylinder High    IDE Cylinder High
#FD0E    IDE Device/Head Register    IDE Device/Head Register
#FD0F    IDE Status Register    IDE Command Register

Would it be possible to change "old-Dobbertin" ports to new port addresses? (I don't know how sector addressing will happens at Doppertins HD.)

...proudly supported Schnapps Demo, Pentomino and NQ-Music-Disc with GFX

netmercer

Hi,
thank you for your hints.
Unfortunately I have no knowledge at all about Dobbertins CP/M.
I tried another solution this weekend and used the buffer of BIOS function "Interbankmove" for temporary storage of the relevant part of the X-Mass driver. It runs very good so far. I will do more tests.

Kind regards
netmercer

HAL6128

Hi, a short and general question for the X-MASS developers: does ACMEDOS expect a partition table (MBR) at sector 0 or a non-partitioned environment with a plain FAT16 boot sector (BS) at sector 0?
Just because of my observation: formatting the X-Mass (DiscModul) from Windows/Linux OS has passed in creating a partition table (MBR) at sector 0 and a FAT16-BS at sector 156 (Windows) or sector 2048 (Linux).
...proudly supported Schnapps Demo, Pentomino and NQ-Music-Disc with GFX

TotO

A non-partitioned environment with a plain FAT16 boot sector at sector 0.
SyX actually encounter problems to release the final version... A format command is include to do that.
(windows is able to read/write this format, but not to create it)
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

arnoldemu

Quote from: HAL 6128 on 21:22, 30 January 16
Good point!

I want to dare (maybe a silly) question because I have no clue about modifying existing software:

Dobbertin is using following ports for their harddisc:
 #FBE0  Dobbertin Harddisc Data Port (read/write)
#FBE1  Dobbertin Harddisc Status (read), Reset (write)
#FBE2  Dobbertin Harddisc Select (write), Configuration (read)
#FBE3  Dobbertin Harddisc DMA, Interrupt (Used on CPC???)
#FBE4  Dobbertin Harddisc Reset (read or write will reset)

The Symbiface or X-Mass allow following I/O ports:

#FD08    IDE Data Register    IDE Data Register
#FD09    IDE Error Register    IDE Features Register (Write Precomp Reg.)
#FD0A    IDE Sector Count    IDE Sector Count
#FD0B    IDE Sector Number    IDE Sector Number
#FD0C    IDE Cylinder Low    IDE Cylinder Low
#FD0D    IDE Cylinder High    IDE Cylinder High
#FD0E    IDE Device/Head Register    IDE Device/Head Register
#FD0F    IDE Status Register    IDE Command Register

Would it be possible to change "old-Dobbertin" ports to new port addresses? (I don't know how sector addressing will happens at Doppertins HD.)


You can't change the ports directly because Dobbertin HD is not an IDE device.
I'm not sure exactly what it is, but it's closer to SASI (precursor to SCSI).
Dobbertin uses cylinders, heads and sector addressing. Some older IDE drives will still support this.

If the read/write code in the xddos rom was re-written to use IDE and these ports then yes you could use it on symbos/x-mass.

Another difference is that it didn't use FAT, it formatted it as CPM, so you could not use the drives directly from x-mass/symbiface 2 - but then is is this a problem? BonnyDOS uses it's own disc structure too and so does the vortex hd.


My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

TotO

The ports are not compatible, because the Dobbertin drive use the old CHS method instead of LBA.
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

arnoldemu

Quote from: TotO on 15:15, 08 February 16
The ports are not compatible, because the Dobbertin drive use the old CHS method instead of LBA.
Old IDE drives can use CHS ;)

The ports are not compatible because the dobbertin is not IDE!
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Prodatron

Quote from: TotO on 13:12, 08 February 16
A non-partitioned environment with a plain FAT16 boot sector at sector 0.
Adding MBR support is quite easy as you only have to do one additional sector read (the MBR itself) and grab one of the four entries at the end of the sector, which contains the offsets of the 4 primary partitions. (This could be a cool feature for the future, maybe for the first version you just leave it.)

CU,
Prodatron

GRAPHICAL Z80 MULTITASKING OPERATING SYSTEM

TotO

Yes. Just, it was expected to add only one drive letter to the BASIC for now.  8)
The more problematic look to be a persistent bug for handling folders/path that remain since months...
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

Dizrythmia

Just ordered the X-MEM & X-MASS with a Mother 4X, the winning combination!


I'm hoping to install the 2 boards inside my 464 at some point, but have the Mother 4X to use on my 6128.


Thought I would try & also buy a DD3 to complete the set but it looks like after that review was posted Zaxon sold out. Half my luck!


I guess I'll keep going on my Gotek in an FD-1 project. Just waiting on a friend to help with my cable issue. I had a go but I'm a real novice at this stuff :(


Trying to learn though :)

TFM

Quote from: Dizrythmia on 12:29, 12 February 16
I'm hoping to install the 2 boards inside my 464 at some point, but have the Mother 4X to use on my 6128.


IMHO it's better to leave it "outside". Some software working with an 6128 will not run with an 464, but will use the expansions. So it's better to keep it connectable to the 6128.  :)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

Ast

Quote from: HAL 6128 on 21:22, 30 January 16The Symbiface or X-Mass allow following I/O ports:

#FD08    IDE Data Register    IDE Data Register
#FD09    IDE Error Register    IDE Features Register (Write Precomp Reg.)
#FD0A    IDE Sector Count    IDE Sector Count
#FD0B    IDE Sector Number    IDE Sector Number
#FD0C    IDE Cylinder Low    IDE Cylinder Low
#FD0D    IDE Cylinder High    IDE Cylinder High
#FD0E    IDE Device/Head Register    IDE Device/Head Register
#FD0F    IDE Status Register    IDE Command Register



Can someone explain me how to use this ? Examples are welcome...
_____________________

Ast/iMP4CT. "By the power of Grayskull, i've the power"

http://amstradplus.forumforever.com/index.php
http://impdos.wikidot.com/
http://impdraw.wikidot.com/

All friends are welcome !

arnoldemu

Quote from: Ast on 11:20, 20 February 16

Can someone explain me how to use this ? Examples are welcome...
The ATA specification describes the registers, the list of commands, the results etc.

http://www.t13.org/documents/UploadedDocuments/project/d1153r18-ATA-ATAPI-4.pdf

(This doc is ATA specification 4).

Example for writing "identify device", command ec.
(8.12 in the doc above)

in 8.12.4 inputs says "na" for most registers which means: do not need this register/bit.

we set DEV for master/slave and write ech (&ec) into command register.


ld a,0
ld bc,&fd0e ;; set which drive (master/slave)
out (c),a

;; we don't need to set cylinder, sector count etc. Specification says this is not required for this command.

ld a,&ec        ;; identify device
ld bc,&fd0f
out (c),a

;; command execution begins.



When data is ready:

;; command returns 512 bytes with device information.
ld de,512
ld hl,buffer
ld bc,&fd08
read_data:
in a,(c)
ld (hl),a
inc hl
dec de
ld a,d
or e
jr nz,read_data


When command is complete we can also read the status register, see if there is an error then read the error register.

the result of the commands really does depend on the ide device connected and not the symbiface 2 or x-mass.

If you plug in an old ide harddisc it will support a different ata version to a modern one.

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Ast

Very interresting... Thanks ArnoldEmu!
_____________________

Ast/iMP4CT. "By the power of Grayskull, i've the power"

http://amstradplus.forumforever.com/index.php
http://impdos.wikidot.com/
http://impdraw.wikidot.com/

All friends are welcome !

Ast

Don't know where you took "&ec" for the device ???
_____________________

Ast/iMP4CT. "By the power of Grayskull, i've the power"

http://amstradplus.forumforever.com/index.php
http://impdos.wikidot.com/
http://impdraw.wikidot.com/

All friends are welcome !

Prodatron


GRAPHICAL Z80 MULTITASKING OPERATING SYSTEM

arnoldemu

#373
From the pdf.

page 77 describes the command in detail.

page 319 has a list of all the commands in this version of ATA.

table e.2 commands sorted by command value:

NOP
00h
CFA REQUEST EXTENDED ERROR CODE
03h
DEVICE RESET
08h
READ SECTOR(S)
20h-21h
WRITE SECTOR(S)
30h-31h
CFA WRITE SECTORS WITHOUT ERASE
38h
READ VERIFY SECTOR(S)
40h-41h
SEEK
70h
CFA TRANSLATE SECTOR
87h
EXECUTE DEVICE DIAGNOSTIC
90h
INITIALIZE DEVICE PARAMETERS
91h
DOWNLOAD MICROCODE
92h
PACKET
A0h
IDENTIFY PACKET DEVICE
A1h
SERVICE
A2h
SMART
B0h
CFA ERASE SECTORS
C0h
READ MULTIPLE
C4h
WRITE MULTIPLE
C5h
SET MULTIPLE MODE
C6h
READ DMA QUEUED
C7h
READ DMA
C8h-C9h
WRITE DMA
CAh-CBh
WRITE DMA QUEUED
CCh
CFA WRITE MULTIPLE WITHOUT ERASE
CDh
GET MEDIA STATUS
DAh
MEDIA LOCK
DEh
MEDIA UNLOCK
DFh
STANDBY IMMEDIATE
E0h
IDLE IMMEDIATE
E1h
STANDBY
E2h
IDLE
E3h
READ BUFFER
E4h
CHECK POWER MODE
E5h
SLEEP
E6h
FLUSH CACHE
E7h
WRITE BUFFER
E8h
IDENTIFY DEVICE
ECh
MEDIA EJECT
EDh
SET FEATURES
EFh
SECURITY SET PASSWORD
F1h
SECURITY UNLOCK
F2h
SECURITY ERASE PREPARE
F3h
SECURITY ERASE UNIT
F4h
SECURITY FREEZE LOCK
F5h
SECURITY DISABLE PASSWORD
F6h
READ NATIVE MAX ADDRESS
F8h

SET MAX ADDRESS F9h
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

arnoldemu

in the pdf, page 48. section 7.15 describes the status register.

The "address" part is decoded by symbiface 2/x-mass into the i/o ports above (fd08-fd0f). The symbiface 2/x-mass pass the data through to the hard disc and disc-on-module, but they also do a little more to make it easy for cpc:

The commands and results come from the hard disc or disc-on-module. So test with different hard discs to ensure your code works well and consider that drives have various capabilities and support different versions of the ATA spec.

The symbiface 2 and x-mass I think do these things (but correct me if I am wrong):
1. i/o port decode to map onto the "address" part in the document. (cs1/cs0/da2/da1/da0).
2. buffer the 16-bit data from the device so we can do 8-bit reads on cpc.
3. reset the hard disc/disc-on-module to a default state.

@ToTO what does the x-mass do in the hardware?

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Powered by SMFPacks Menu Editor Mod