Giter Site home page Giter Site logo

caprice32's People

Contributors

bignaux avatar colinpitrat avatar cormacj avatar cpcitor avatar devnexen avatar martiangirl avatar mrk421 avatar nudgegoonies avatar pvaret avatar sebhz avatar zackizacki avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

caprice32's Issues

Opening Menu makes caprice crash when video mode is OpenGL

With caprice using OpenGL mode, pressing F1 to open the menu makes caprice crash.

Stack is the following:

#0  0xb7ace693 in _int_malloc () from /usr/lib/libc.so.6
#1  0xb7acf8f5 in malloc () from /usr/lib/libc.so.6
#2  0xb7f22be7 in SDL_CreateRGBSurface () from /usr/lib/libSDL-1.2.so.0
#3  0x080e236f in wGui::CWindow::CWindow(wGui::CRect const&, wGui::CWindow*) ()
#4  0x080de2b8 in wGui::CView::CView (this=0xbffff778, surface=0x86cb080, backSurface=0x840bd48, WindowRect=...) at gui/src/wg_view.cpp:77
#5  0x08086d12 in CapriceGuiView::CapriceGuiView (this=0xbffff778, surface=0x86cb080, backSurface=0x840bd48, WindowRect=...) at gui/src/CapriceGuiView.cpp:175
#6  0x08057326 in main (argc=1, argv=0xbffffa84) at cap32.cpp:4662

There's no direct call to SDL_CreateRGBSurface in CWindow::CWindow, but CWindow::CWindow calls CWindow::SetWindowRect that calls SDL_CreateRGBSurface.

MS Windows compilation painful

I tried compiling Caprice32 under MS Windows (Win8 laptop) yesterday night. The experience was far from pleasant :-(
I first tried and install the latest MSYS2 environment from http://www.msys2.org/, install all the relevant packages (gcc, SDL 1.2.15, freetype, zlib, libpng, git make), clone the the git repo and try a plain "make windows". Looks like the WINCXX variable is incorrect and msys2 uses g++ as a compiler. After fixing this, the compilation starts then miserably fail because z80.c redefines _A, _B, etc. which seem to be used by C++ system libraries under MSYS (?).
I then used an old mingw + msys install I had on the same laptop, and could finally build a windows executable after pretty heavy changes to the makefile. My mingw install by itself is a mess with dependencies installed all over the place, and a mix of libraries recompiled from source and binaries fetched from who knows where.
Do you have a working MS Windows compilation environment setup ? If yes could you share it (Cygwin? mingw? msys? msys2?).
We could move away the compilation instructions from the README.md to an INSTALL file - the way it is done in most projects - and make the INSTALL file more verbose about the environment ?

Possible Menu Enhancements

Would it be too much of a hassle if the F1 menu contained an option to enable or disable the joystick via a checkbox?

By default, cap32.cfg, has the joystick enabled and you have to manually edit the cfg file to disable it. This result in multiple arrow characters when the emulator loads since the mouse movements are considered as joystick key presses.

It would also be nice to include a choice of the plus series from the menu (not sure whether this has been implemented yet since I cannot test right now but just got the idea in mind)

Thanks

Support loading cartridges

Currently the only way to load a cartridge is to pass it on the command line.
This should be added to the load/save menu.

caprice32 - debian 8 - Segmentation Fault

When pressing F1 to adjust any settings and pressing Save, caprice32 exits with Segmentation Fault and settings are not saved.

Logs:

segfault at 816b000 ip 080f278f sp bfe97d0c error 4
segfault at 816b000 ip 080f278f sp bfe25f5c error 4

Support the plus range (6128+, 464+, GX4000)

Is there a way to make the 6128 plus ROM to work in caprice32?

I gave a look at winape and there is a file called CPC_PLUS.CPR along with the ROM file.

The AMSTRAD computer I had way back was a 6128 Plus version and it started with a small menu choice:

f1 - Amstrad Basic
f2 - Burnin' Rubber <--- this was a game

Kindly advise.

Support taking screenshots

This would need a screenshot directory to be configured and to exist.
Taking multiple screenshots should be possible.
We have a key free for this: F3
Supporting various file format could be interesting too but we shouldn't had too much dependencies for this.

However, this is low priority because there are other options to take screenshots, I'm not sure having it integrated to the emulator brings a huge benefit.

Improve default configuration handling

As stated in #35

There are issues with the configfile. Users have to copy /etc/cap32.cfg to ~/.cap32.cfg first until they can make changes from the ui. Without the .cap32.cfg the emulator does not start. Also a default directory for the caprice snaptshots, etc. files is needed. I created a quilt patch to patch the debian package only to use ~./caprice and subdirectories. But they have to be created manually by the users. Starting caprice does not create them automatically.

  1. Using a common ~/caprice parent directory for disk, tape, snapshots, roms ... by default makes sense
  2. Emulator should start with default parameters if no config file is found
  3. Emulator should write to ~/.cap32.cfg if no config file (or only /etc/cap32.cfg) exists
  4. Emulator should create missing directories if it needs to save something into it (shouldn't be needed in other cases)
  5. Load/save dialog should behave well if directory specified in configuration is missing (currently impossible to "get out" of it)

Make joystick emulation configurable

Would be nice to:

  • support two joysticks (no obstacle for now, just no buttons defined)
  • be able to choose which key to use for each button (in a convenient way, allowing space, control, left/right shift ...)

Wrong keyboard mapping

On my french laptop (french keyboard) under MS windows (French keyboard declared in Windows): keyboard mapping is correct. Using an external English keyboard with under an English MS Windows (and setting proper mapping in Caprice32 -> kbd_layout = 0), keys are all wrong, and even the virtual keyboard seems t output wrong characters.

Bug in F1 Menu

I set model=3 and the cartridge loads correctly.

However, I pressed the drop down from the menu to select a cpc model and then DID NOT select one (just clicked somewhere else) and closed the menu.

Pressed F10 to restart and the normal 128K Basic 1.1 screen loaded.

Took a look at cap32.cfg to find model set to -1.

Buggy sound on windows 7

Previously discussed in issue #11.

In Fruity Frank, the sound behaves strangely on my wife windows. The sound when eating a fruit is monotonic and doesn't stop until another sound (other than the music, usually the purple monster falling) occurs. The sound of the purple monster is also monotonic but does stop when it reaches the ground.

Load/save menu doesn't support zip files

The load/save menu only supports loading .sna for snapshots, .dsk for disks, .cdt for tapes. It doesn't support loading .zip for all these kinds. It doesn't support loading .voc either for tapes.

Moreover, when giving a zip file on the command line, the load menu is broken for the corresponding file type due to xxxx_path being set to the zip file.

RAM test failing

The RAM test of Arnold 5 diagnostic ROM is failing with the following message:

RAM ERROR on wave down,
checking normal pattern

Block = C0
Offset = 2C0F
Failing Bit = 07

Ability to flip disk

Is it possible to include the option to flip a disk?

I recently downloaded Untouchables 2 and at one point the game prompted to flip the disk to side B.

Early emulators like CPCE have this option. Was wondering whether it is possible to include it (if not already there and I overlooked it) in caprice32?

Allow mapping physical joysticks to logical ones

Allow user to configure the joysticks from GUI:

  • choosing which physical button corresponds to which CPC button or emulator function
  • choosing which physical joystick maps to which CPC joystick (especially useful to mix a real joystick with joystick emulation which is not possible currently)

Cannot compile on Debian 8 Jessie

Installed SDL2.0.4 from website.
Installed libfreetype6 and zlib
When executing make, I get the following errors... shown in the attached files...

Errors starting to appear as shown below
error1

They continue to appear as above and end up like below
error2

Keyboard Layout

There is a problem (maybe?) with the keyboard layout.

In order to type the pipe symbol (|), I have to select English CPC in the Input section. However then all the other keys are badly mapped. Ex: when I press 1, the ! comes and so on.

Then if I select French CPC, the keyboard mappings are ok but the pipe symbol is lost...

Also, I downloaded the Fruity Frank dsk file. Game runs perfectly. However, with the joystick disabled, the keys are mapped to something like the below:

Left: X
Right: W
Up: M
Down: ?

Can the default key mappings be changed when joystick is disabled please?

Thanks

Enable joystick from caprice32 options menu

Can there be an option added to enable and disable the joystick from the F1 options menu?

Right now there isn't one (I couldn't find it) and to enable and disable the joystick you have to manually edit cap32.cfg.

I am working to produce a live cd to resemble the Amstrad functionality as much as possible (will keep you posted on this) and I am planning to include caprice32 as an emulator and obviously give you the credit you truly deserve. Like that the novice user would not need to edit config files manually.

Do I have your permission to use caprice32 for this project please? :-)

Emulator speed limit bug

If sound is disabled, speed limit is also disabled. Culprit code seems to be around line 2423 in cap32.cpp.
Easy to reproduce - launch cap32 with sound disabled.

Problem with zip file handling when compiling under MSYS2/mingw64

MS Windows binaries compiled with windows under MSYS2/mingw64 cannot open zipped disk files.
After some investigation, it turns out the zip::extract method creates corrupted files (duplicated bytes here and there in the decompressed file vs the original .dsk).
The exact same routine works just fine under Linux, and probably fine when cross-compiling for Windows under Linux. This is not a big problem, but something that needs a bit of investigation.

Add OSD messages for user actions

User actions that have no immediate visible effect (contrary GUI, fullscreen, exit, reset ...) should display an OSD message.

This concerns:

  • joystick emulation (f7)
  • tape play (f4)
  • limit speed (f9)

Core dump at exit after switching from HWaccel to OpenGL

Starting caprice32 with video driver 'Double size with hardware flip' and switching with the GUI to 'Open GL scaling' on my X1 Carbon, it works but at exit of Caprice32, I have the following core:

(gdb) bt
#0  0x00007ffff6b21735 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#1  0x00007ffff6b2245d in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#2  0x00007fffed0e02aa in ?? () from /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
#3  0x00007fffed3b6ffe in ?? () from /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
#4  0x00007fffed369763 in ?? () from /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
#5  0x00007ffff07aa50f in ?? () from /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1
#6  0x00007ffff0786bb9 in glXDestroyContext () from /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1
#7  0x00007ffff7b7d1d2 in ?? () from /usr/lib/x86_64-linux-gnu/libSDL-1.2.so.0
#8  0x00007ffff7b80ffe in ?? () from /usr/lib/x86_64-linux-gnu/libSDL-1.2.so.0
#9  0x00007ffff7b8120e in ?? () from /usr/lib/x86_64-linux-gnu/libSDL-1.2.so.0
#10 0x00007ffff7b7395e in SDL_VideoQuit () from /usr/lib/x86_64-linux-gnu/libSDL-1.2.so.0
#11 0x00007ffff7b4df75 in SDL_QuitSubSystem () from /usr/lib/x86_64-linux-gnu/libSDL-1.2.so.0
#12 0x00007ffff7b4e01e in SDL_Quit () from /usr/lib/x86_64-linux-gnu/libSDL-1.2.so.0
#13 0x00007ffff6adf1a9 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#14 0x00007ffff6adf1f5 in exit () from /lib/x86_64-linux-gnu/libc.so.6
#15 0x000000000046e7fa in wGui::CapriceMenu::HandleMessage (this=0xba8b60, pMessage=0xb404e0) at src/gui/src/CapriceMenu.cpp:171
#16 0x00000000004ad431 in wGui::CMessageServer::DeliverMessage (this=0x7b3200) at src/gui/src/wg_message_server.cpp:147
#17 0x000000000049d86d in wGui::CApplication::Exec (this=0x7fffffffdd30) at src/gui/src/wg_application.cpp:311
#18 0x00000000004534db in showGui () at src/cap32.cpp:3030
#19 0x00000000004543b2 in cap32_main (argc=1, argv=0x7fffffffe0c8) at src/cap32.cpp:3318
#20 0x00000000004c1025 in main (argc=1, argv=0x7fffffffe0c8) at main.cpp:5

To be noted that the reverse (going from OpenGL to Double HW) results in having only the left half of the screen visible, the right half being black. Not sure if it's related or a separate issue.

Possible F1 Menu Update

It is a minor issue but, for example, while I was in the Input tab with the joystick emulation option ticked and I pressed F7, the checkbox remained ticked but the emulation was disabled as it should.

My point is: Can the menu options be updated in real time so that, for example, in the above scenario the checkbox ticks and unticks if the menu is open?

The system works though. In fact if I close the menu and open it again, the checkbox is unticked then.

Hope I am not asking too much but I am putting myself in the shoes of a noob...

Copy files from/to emulator to/from filesystem

Provide ability to copy files:

  • from emulator to host filesystem
  • from host filesystem to emulator

Tools like iDSK provide such feature but having it integrated in the emulator would make it easier to use.

Black screen on emulator reset (F5)

It does not happen all the time but sometimes I press F5 and I get a black screen.

The emulator is there but nothing is shown. I know the emulator has loaded since when I press F10, it quits successfully.

Cannot tell what is wrong and have no idea in mind how to, sort of, debug it...

Sometimes also the emulator displays a black screen immediately and does not load. I cannot press F10 to quit which means it is not responding and I am forced to kill it from another terminal...

CPU usage is also high all the time when it is running...

capture

Poor performances

From issue 39:
Hello! First of all thanks a lot for this fine emulator! The CPC Schneider was the very first computer (& gaming device) I had as a kid and seeing that green screen and hearing the Nemesis soundtrack today brings back warm memories ^_^

I'm very sorry I'm writing this here because it doesn't really belong here... though maybe it kinda does because I could really not find any place on the net where there was discussion about this emulator (apart from very outdated ones); there doesn't seem to any forum or discord or any other place to ask questions.

What I wanted to ask is if it's normal that I'm only getting around 17 FPS (34%), even when not running a game. Disabling sound seems to double that but nothing else brings emulation to 100%. Maybe there's some kind of setting I missed or something? (My PC is quite strong).
I actually used Caprice32 one or two years ago and I think I remember that I didn't have any speed issues back then. Now that I found more of my old games I'd love to play them but yeah, the speed kinda kills the fun.
Sorry again for posting this here, thanks a lot and it would be great if you could help me a little here :)

Instructions on how to use Caprice32

Hello Mr. Colin,

Your fork of Caprice32 has recently been accepted and added to the repositories of Solus OS, due to being the only Linux Amstrad CPC emulator that is actively maintained.

I've been trying it out for the first time, and I must admit it's rather arcane to use from a novice's standpoint.

Would it be possible for a short guide to be written on how Caprice32 is used? For instance, I cannot for the life of me figure out how to type a " in it, which from what I gather is needed to run Disk games.

And if this guide is written, would it also be possible to add it as a menu entry in the menu dialog from pressing F1?

Thank you for your time, and for maintaining this emulator! ^_^

Options modified from the GUI are not persistent

The only way to modify settings persistently is to edit cap32.cfg

It would be expected that settings updated from the GUI are kept persistently or at least that there's a way to overwrite the cap32.cfg with it.

make DEBUG should be sticky

Building a first time with DEBUG=1 should ensure the next build are also in DEBUG even without the flag provided.
Only a make clean should revert to the normal build mode.

Reduce Caprice32 CPU usage

Caprice32 currently burns 100% CPU, whatever the host machine. Most of those CPU cycles are wasted in the main loop waiting for the emulated CPU to do something.
Besides optimizing CPU usage in general, this is actually required if one wants to usie Caprice32 as a screensaver.

Embedded debugger

Provide a tool allowing to:

  • examine registers
  • disassemble code
  • modify code and memory.

Update and validate build for windows

Currently, the build for windows is not maintained and is probably not working anymore.
The windows makefile should be removed and the build for windows should be done from the main makefile using cross-compilation.
Validation for it should be added on travis

Make GUI more usable without mouse

The GUI (and caprice in general) should be fully usable without mouse.

After all, the best platform ever (the CPC) didn't require a mouse.

The first (and maybe only) step is to implement proper focus handling (tab and shift-tab).

Autorun

Hi

Is that possible to add autorun ?

Ex : ./cap32 'renegade.dsk' to play directly.

Thank.

ALSA message in terminal

I played a bit Fruity Frank and when I quit the emulator, in the terminal there were a lot of messages like the below:

ALSA lib pcm.c:7963:(snd_pcm_recover ) underrun occurred

Is that something that can be fixed from caprice32 or shall we just ignore it since it is something ALSA related?

Slots handling needs to be redesigned

The way Caprice32 handles dsk/cpr and friends is... strange.
We seem to derive drvXXX_path from the arguments (if any), then reuse it. And the code is pretty redundant here - as indicated in the comments !
We could handle it more sensibly, the way other emulators do it:

  • specify xxx_path in the configuration file ("the directories where disks / cartridge / tapes / whatever are stored") - drvA and drvB path would be the same and become "dsk_path" or something like this.
  • keep the xxx_file in the configuration file, in case some people want to have some disk/cartridges installed by default.
  • get rid of the xxxx_zip in the conf file (useful internally but no need to expose it as we can detect the extension).
  • get rid of the xxxx_format in the conf file (mostly unused anyway)
  • one can invoke 'cap32 toto.dsk' -> caprice32 will look for disk/toto.dsk and load it in the first free disk drive.
  • optionally, maybe, one can invoke 'cap32 /home/mycpr/truc.cpr. In this case we would detect a full path and try and load it as is, without using the xxxx_path (as the user made it clear he/she wants to load an alternate path). This would be nice to have only though... forcing the user to put all images in the same directory seems OK to me. This is the Mame way, isn't it ?

Document joystick emulation

In VirtualBox, loading the cartridge (model=3) with joystick enabled results in a series of continuous beeps as if I am pressing the joystick buttons. The beeps are gone once the joystick is disabled (hence my suggestion earlier to be able to disable the joystick via the menu)

Also, having no joystick and operating a laptop, I could not find a way to play Burnin' Rubber. Only F and G keys work and I have no joystick controls. It would be nice if there was a way to map arrow keys to joystick directional controls and any other 2 keys to joystick buttons. I think this is doable since I saw another other emulator (I guess it was WinAPE) that managed to achieve such an option. What do you think?

Is it too much of a problem? Hope I am not bugging with all these issues but I am being your personal tester :-)

Permit disabling libcaca/aalib SDL drivers

Before pulling the recent update (about the support for the plus versions), I was able to run the emulator without the X server running.

The emulator would load and display as the below. (Note the error at the top).

error2

This did not happen with previous versions. It would quit with a message that no display was found (along those lines).

Kindly advise.

Automatically pause when loosing focus

This is the auto_pause option that is currently unimplemented.
I guess this may have some value but unless someone asks for it, this is low priority ...

Modifying screen style at runtime screw-up the display

When modifying the screen style from the option menu (Options->Video->Video plugin->Half size/Double size) the display is screwed-up.

Two issues in one:

  • the emulator display is scrambled
  • the GUI stays tuned for the previous screen size

Arrow characters on mouse move

I noticed that when the mouse pointer is moved and caprice32 is open, arrow characters are typed as shown below. Not sure if it is a Virtualbox related issue though.

capture

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.