Author Topic: Emulator that works with US keyboard  (Read 1560 times)

0 Members and 1 Guest are viewing this topic.

Offline RobertM

  • CPC664
  • ***
  • Posts: 132
  • Country: au
  • CPC6128
  • Liked: 14
  • Likes Given: 0
Emulator that works with US keyboard
« on: 09:01, 11 February 16 »
Hi,
    I tried several emulators a long time ago and I couldn't find one that can match the keys on my keyboard.

Is there one that matches a US sytle keyboard or one that can be re-mapped to match a US style keyboard????

The other thing that I need is to be able to get data into the emulator somehow - copy / paste - editing files ???

Offline arnoldemu

  • Supporter
  • 6128 Plus
  • *
  • Posts: 5.335
  • Country: gb
    • Unofficial Amstrad WWW Resource
  • Liked: 2260
  • Likes Given: 3478
Re: Emulator that works with US keyboard
« Reply #1 on: 09:10, 11 February 16 »
Hi,
    I tried several emulators a long time ago and I couldn't find one that can match the keys on my keyboard.

Is there one that matches a US sytle keyboard or one that can be re-mapped to match a US style keyboard? ???

The other thing that I need is to be able to get data into the emulator somehow - copy / paste - editing files ???
winape can be configured I believe.

Arnold has a US like positional layout but is not yet configurable, but it has a translated mode where you can type keys normally and it works out which CPC keys to press to make that character making typing really easy.
You will need to do some work to set them up.

Arnold and winape also have autotype windows where you can paste your text into a window and then let it type it into the cpc.


Arnold can load binaries with headers and run them, in winape load them via the debugger and run from basic.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Offline TFM

  • Visit the mysteries of the CPC at www.futureos.de
  • Supporter
  • 6128 Plus
  • *
  • Posts: 9.899
  • Country: aq
  • Space Chicken for FutureOS is free!
    • index.php?action=treasury
    • FutureOS - The revolution on CPC!
  • Liked: 1976
  • Likes Given: 4650
Re: Emulator that works with US keyboard
« Reply #2 on: 20:37, 11 February 16 »
JavaCPC can do it. Other maybe, never found the option, never searched.  ;) :)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

Offline RobertM

  • CPC664
  • ***
  • Posts: 132
  • Country: au
  • CPC6128
  • Liked: 14
  • Likes Given: 0
Re: Emulator that works with US keyboard
« Reply #3 on: 04:39, 15 February 16 »
OK,

I tried the Arnold Emulator and it's like an old Flash game - it has gotten smaller as screen resolutions have gotten bigger. It looks great but that one aspect is a deal breaker for me - my old eyes can read the small box and I can't use the full screen as it makes it more frustrating moving back and forth to other applications.

I also tried WinAPE and it looks like the go - the window is large enough for me to see and the external text box is perfect for typing without worrying about where where the keys have shifted to.

But I can't seem to get WinAPE to emulation a plain old classic CPC6128!!!

Do I need to import ROM files or something?

I will go and load some hex editors etc and see how easy it is to import into the emulator using it's files.

Offline Executioner

  • Supporter
  • 6128 Plus
  • *
  • Posts: 783
  • Country: au
  • WinAPE Developer
    • WinAPE
  • Liked: 391
  • Likes Given: 60
Re: Emulator that works with US keyboard
« Reply #4 on: 07:09, 15 February 16 »
But I can't seem to get WinAPE to emulation a plain old classic CPC6128!!!

From the settings screen, select "CPC6128" as the profile. Once back in the emulator, press CTRL-F9 to reset.

Offline arnoldemu

  • Supporter
  • 6128 Plus
  • *
  • Posts: 5.335
  • Country: gb
    • Unofficial Amstrad WWW Resource
  • Liked: 2260
  • Likes Given: 3478
Re: Emulator that works with US keyboard
« Reply #5 on: 11:12, 15 February 16 »
OK,

I tried the Arnold Emulator and it's like an old Flash game - it has gotten smaller as screen resolutions have gotten bigger. It looks great but that one aspect is a deal breaker for me - my old eyes can read the small box and I can't use the full screen as it makes it more frustrating moving back and forth to other applications.
Old one or wip one.? I assume also you are using fullscreen mode?

Thankyou for the feedback. I'll fix that in the version after next.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Offline ZbyniuR

  • 464 Plus
  • *****
  • Posts: 319
  • Country: pl
  • 6128 A1230 PSX Win7
    • Jedyne polskie forum o CPC. :)
  • Liked: 342
  • Likes Given: 145
Re: Emulator that works with US keyboard
« Reply #6 on: 19:08, 15 February 16 »
Try this OS6128US.ROM for emulator with keys map like in PC.
As usual in emulator disappears 2 key from CPC. I mean [clr] and key on left from [right shift], so on CLR is code 16, the same like on Ctrl+P, and in my version it is on SHIFT+DEL too.
On second key normally is \ and ` with shift, not so important signs, but in US version there is \ and | which is quite usefull in CPC, so I put | with ctrl on right from P, where it is normally in CPC but with shift. On <>? with ctrl added some too.

I hope you like it. UK version is there too. If someone need 32K ROM for Caprice32 let me know. :)

PS.: On function keys with shift will be frames if you type FOR a=144 to 159:KEY a,CHR$(a):NEXT  I don't know how to put it in ROM.
In STARS, TREK is better than WARS.

Offline RobertM

  • CPC664
  • ***
  • Posts: 132
  • Country: au
  • CPC6128
  • Liked: 14
  • Likes Given: 0
Re: Emulator that works with US keyboard
« Reply #7 on: 06:08, 20 February 16 »
Old one or wip one.? I assume also you are using fullscreen mode?

Thankyou for the feedback. I'll fix that in the version after next.

I did actually try your emulator a long time ago but the post here is about a version I downloaded in the past week or so. Ver 04012004

Your version is better except that the windowed interface is far too small for me to read. My screen resolution (Laptop) is 1680x945 18 inch. I use Windows 7 Home premium x64 with the system fonts enlarged by 125%. My eyeballs are over 50 years and the resolution has dropped to about hqvga lol.

The other (winape) version has errors and locks up a lot, the sound breaks and there is popping sounds all the time so I turn the sound off.

And while I have your attention lol - I have a question and you are the perfect person to ask.

I have been looking at the CPC6128 port map. And it seem that most if not all of the ports are used in 16 bit mode ie OUT(c),n where register B is placed on the other 8 bits of the address bus. There does however seem to be some ports that are addressed in 8 bit mode or at least decoded that way.

so question 1 is "does the CPC firmware exclusively use 16 bit address space for port access?"

The other thing is about what if they use 8 bit addressing space for ports like OUT (A), n

The NMOS and CMOS versions do this differently from memory - one places 0xFF on the other half of the address bus and the other places 0x00. How can that be dealt with in hardware?




Offline arnoldemu

  • Supporter
  • 6128 Plus
  • *
  • Posts: 5.335
  • Country: gb
    • Unofficial Amstrad WWW Resource
  • Liked: 2260
  • Likes Given: 3478
Re: Emulator that works with US keyboard
« Reply #8 on: 11:34, 20 February 16 »
I did actually try your emulator a long time ago but the post here is about a version I downloaded in the past week or so. Ver 04012004

Your version is better except that the windowed interface is far too small for me to read. My screen resolution (Laptop) is 1680x945 18 inch. I use Windows 7 Home premium x64 with the system fonts enlarged by 125%. My eyeballs are over 50 years and the resolution has dropped to about hqvga lol.
The old version is no longer being developed. I am working on the new one now. I also have my system fonts at 125% because it's easier for my eyes too.


The other (winape) version has errors and locks up a lot, the sound breaks and there is popping sounds all the time so I turn the sound off.
I think you mean the wip (work in progress). Yes the sound breaks up and it's the next thing to look at after fixing the crtc emulation. I don't see lock ups and errors.

winape is an emulator by Richard (Executioner).

And while I have your attention lol - I have a question and you are the perfect person to ask.

I have been looking at the CPC6128 port map. And it seem that most if not all of the ports are used in 16 bit mode ie OUT(c),n where register B is placed on the other 8 bits of the address bus. There does however seem to be some ports that are addressed in 8 bit mode or at least decoded that way.

so question 1 is "does the CPC firmware exclusively use 16 bit address space for port access?"

The other thing is about what if they use 8 bit addressing space for ports like OUT (A), n

The NMOS and CMOS versions do this differently from memory - one places 0xFF on the other half of the address bus and the other places 0x00. How can that be dealt with in hardware?
All ports on CPC should be treated as 16-bit.

For OUT (C),r instructions, such as OUT (C),E, OUT (C),D etc the port address is defined by BC (B upper 8 bits, C lower 8 bits). The data is defined here by the register, in this case E. Sometimes OUT (C),C is used which means the data is both the lower 8 bits of the I/O address and the data. (e.g.

LD BC,&7F8C
OUT (C),C

port is 7F8C, data is 8C.

Many devices inside the CPC do not decode the address completely. They decode a few address bits and ignore the others. This means it sometimes looks like 8-bit I/O address but it's not, and it also means more than 1 I/O address can be used to access the same hardware.

For example, the Gate-Array decodes A15 and A14 of the I/O address only. A15=0 and A14=1.
In the above example all other bits of 7F8C are ignored, so it's ok to use OUT (C),C. The Gate-Array then decodes the data fully.

OUT (n),A can be used for 16-bit I/O too. N is the lower 8-bits of the I/O address. A is the upper 8-bits of the I/O address and also the data. This works fine on CPC with it's partial decoding of I/O.

LD A,&7F
OUT (&8c),a

is valid and similar to the example above.

INIR, OUTR, OTIR use B as both a counter and also as the upper 8-bits of the I/O address. These don't work well on the CPC because it decodes bits 8-15. If it chose to ignore bits 8-15 of the I/O port and only decode bits 7..0 (e.g. like PCW or MSX or Enterprise) then this would work fine because the upper bits would be ignored. The lower bits then define the port.

Generally these instructions don't work well on the CPC because of the partial port decoding and that I/O ports are 16-bit. I think it *is* possible to use them with certain I/O address ranges but in a limited way. So repeating I/O instructions like this should be avoided.

INI,OUTI, OUTD, IND can be used because they do 1 iteration and you can control the i/o port before the instruction is executed.

With NMOS and CMOS this actually only affects the undocumented "OUT (C),0" instruction. On NMOS the data is 0, on CMOS the data is 0x0ff. The I/O port in both cases is from BC. Quite a lot of demos rely on OUT (C),0 outputting 0 for the data so will not work on CMOS Z80 (OUT (C),0 can be used in keyboard reading for example). The CPC however seems to always use NMOS Z80 in it's design so 0 has been expected, but if you're repairing one, put in a NMOS replacement.


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