News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

Emulating an Amstrad CPC 6128-style disk drive for an emulated IBM PC

Started by PortoManc, 23:47, 23 April 25

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

PortoManc

I don't know if this is possible, but I'd be interested to know if anyone has ever tried this and if so, how successful it was.
1. I have a basic CP/M system (CP/M-86 for IBM PC) running on a basic emulated IBM PC (within Oracle VM Virtualbox)
2. I have some Amstrad CPC6128 disk images (the 100kb system disks) that I can run in an emulated CPC6128
3.  VM Virtualbox can add additional emulated peripherals via emulated serial ports.
4. I believe some years ago, it was possible to buy external Amstrad 100kb floppy drives that could be connected to a serial port on the Amstrad CPC6128

I would be interested to know if there is such an emulated external drive that can be connected to my emulated IBM PC.
Yes, I understand that the IBM AT/XT PC was an 8086/8088 processor and the CPC6128 was a Z80 processor, so there could be incompatibility there.
Yes, I also understand that there were many, many formats of CP/M disks, many of which were specific to particular machines (and therefore the IBM might not be able to 'read' the Amstrad disk anyway).
But there's no harm trying, and if I can 'connect' the 'emulated' external drive to the 'emulated' PC, and can transfer data between the two, it might open up the possibility of running some Amstrad software on the PC (for instance, I did run the NewWord word processor on a genuine Amstrad in the '80s, and do have some Amstrad software in disk image form, taken from sites such as this. One of my friends in the '90s, did suggest that he could copy the NewWord documents I'd made into his PC at the time, and then we could transfer those files to IBM 3.5" floppy disks).
Thanks for any comments, thoughts and/or experiences.     

andycadley

All you would really need to transfer data is to extract files with something like CPCDiskXP (or quite a few emulators) and then just put them somewhere the emulated PC can read. CP/M programs shouldn't care about the actual disk structure itself.

However I can flat out tell you now that programs written for Z80 CP/M will absolutely not run on the x86 version. It's just a fundamental binary incompatibility.

eto

I never heard of a 100K disk format or floppy drive and the CPC does not have a serial port. Are you sure about that format?

There is the CP/M format with 169K and the IBM format with (I think) 155K. The latter one is probably the one that was used to exchange data with an IBM PC. But I have never actually seen anyone doing that. 


An interesting project to emulate the process of e.g. doing cross compiling on a 8086 and move compiled stuff over to the CPC as if it was done in the 80s - but you won't be able to run the applications on the 8086 as Andycadley already explained unless your emulated 8086 has a Z80 emulator ;-) 

McArti0

Recently I read that x86 is 100% compatible with 8080 at the assembler level (not to be confused with machine level) Which means that every 8080 instruction has its analogue in x86.

I also remember that in the virtualizer you can pass a physical device from the host to the quest.
CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
One chip drver for 512kB extRAM 6128
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

andycadley

Quote from: McArti0 on 09:34, 24 April 25Recently I read that x86 is 100% compatible with 8080 at the assembler level (not to be confused with machine level) Which means that every 8080 instruction has its analogue in x86.

Kind of. It's source level compatible, in that every 8080 instruction can be assembled into an 8086 instruction and the program should still work. That makes some big assumptions about the memory model you're using though (because 8086 memory is segmented and the program may not work if it makes assumptions about addressing that the segment arrangement doesn't reflect)

Z80 code obviously won't assemble using a 8086 assembler because, in addition to all the new instructions it has, the mnemonics for every instruction are different. Theoretically you could probably write a compiler that takes Z80 source and spits out 8086 code without too much difficulty though that'd work for most cases (I.e. not self modifying code etc). Doesn't really help when you only have Z80 binaries though as you'd have to reverse engineer the source code first (at which point just emulating the whole thing is probably easier).

McArti0

CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
One chip drver for 512kB extRAM 6128
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

Powered by SMFPacks Menu Editor Mod