Skip to content

Releases: TomHarte/CLK

2020-03-21

21 Mar 19:47
75f2b04
Compare
Choose a tag to compare

This release:

  • corrects potential crashes in macOS when: (i) switching a machine between monitors; or (ii) closing a machine; and
  • nearly completely rejigs the manner of command-line options provision for SDL/command-line users:
    • who can now create a new machine without providing a piece of media, or override any settings the emulator picks for itself if providing a piece of media; but
    • this is achieved by directly exposing various internal controls, replacing the old system of more complicated redeclaration, with the side effect that a few options have changed name or value, and some might need renaming in the future for better command-line sense.

2020-03-10

10 Mar 16:35
9668ec7
Compare
Choose a tag to compare

This is a minor bugfix release for SDL users only; it partially unwinds the recent keyboard handling changes in order to restore classic behaviour for users not using the new --logical-keyboard.

The specific underlying issue is this emulator's attempt to correlate text entry and key presses. SDL 2.x provides those things as distinct streams since text entry may come from a wide variety of things other than key presses, may require multiple key presses, etc. What this emulator wants to be able to do is, sometimes, check whether a key press it can't otherwise forward also produced SDL text entry. It tries to do that by timestamp primarily, but that's somewhat empirical and experimental. If and when I'm more confident in that, I can go back to something more like 2020-03-07 attempted.

macOS binaries are attached for visibility but are unchanged from the previous release and named accordingly.

2020-03-07

07 Mar 23:28
2ee24d2
Compare
Choose a tag to compare

Primarily keyboard input changes:

Adds a 'logical' keyboard mode, which is implemented as an extension of the existing text paste functionality, acting as if you pasted each letter that you type — it therefore work correctly with any keyboard layout your host OS supports.

Also adds a few convenience key mappings, regardless of logical/physical keyboard mode:

  • for the ZX80 and ZX81: backspace (produces shift+0), break (shift+space; mapped to escape);
  • for the Vic-20: cursor left (shift+right) and up (shift+down) and F2, F4, F6 and F8 (shift+F1,F3,F5,F7 respectively);
  • for the Electron: F1... F0 (func+1... 0).

Miscellany:

  • corrects obscure Z80 flag behaviour, meaning that the emulator now passes Zexall, all of Patrik Rak's tests, etc. No real software is known to rely on this behaviour, but other emulators have been doing it correctly for years.

2020-02-16

17 Feb 02:27
2e1b245
Compare
Choose a tag to compare

This release:

  • fixes a potential crash on macOS if the user were to select File -> New... and then cancel the resulting dialogue;
  • fixes fullscreen for SDL users — alt+enter should once again toggle back and forth;
  • adjusts the function used for the AY's [non-linear] volume levels better to match real hardware, with the effect that lower volumes are further apart and higher volumes are closer together;
  • introduces stereo output for the Amstrad CPC, to match that machine's optional stereo output; and
  • fixes Oric Jasmin drive selection logic, and brings the Byte Drive implementation up to the relevant latest revelations.

2020-02-12

13 Feb 05:04
5f661ad
Compare
Choose a tag to compare

This release rethinks the means by which emulation is scheduled:

  • machines that are running close to an integer multiple of your display's native output rate are now run very slightly too quickly or very slightly too slowly to bring them into sync, thereby eliminating tearing artefacts;
    • this is evaluated dynamically, so is fully compatible with machines such as the Atari 2600, ZX80/81 and Amstrad CPC which have variable frame timings;
  • machine update periods are now more granular, lowering input latency and improving parallelisation;
  • a further frame's length of output latency has been eliminated on macOS, where vsync frame output delays have been eliminated; and
  • on the Mac, where joystick input is polled, polling now occurs at a fixed 200 checks/second, independent of your display.

Unfortunately it has still not proven possible to bring the SDL build up to parity with macOS builds in latency terms — SDL's built-in timer is low precision†, and it offers no means to observe vertical sync events without double buffering.

Under macOS, SDL gets vertical sync events wrong — e.g. it offers them at a rate of 59.97Hz on my monitor, despite the fact that I'm running it at 30Hz non-interlaced — but your mileage may vary elsewhere. I test the Linux build under virtualisation so was not able to evaluate this factor there.

Otherwise, it:

  • adds initial support for the Atari ST's .STX file format;
  • in support of which, system-wide improvements for 'fuzzy' disk bits are also of benefit to CPC .DSK support;
  • adds multi-sync output support for the Oric, so 60Hz mode is now useable;
  • corrects a handful of potential thread safety errors in SDL/kiosk mode;
  • SDL/kiosk users can now specify a machine speed multiplier, e.g. --speed=0.75 to run at 75% of original speed, or --speed=2.5 to run at 250% speed;
  • on macOS, resolves an issue that would lead to window contents being mis-scaled when dragging the window between Retina and non-Retina displays (in either direction);
  • also on macOS, resolves an issue where sound output could fail to recover from an ephemeral audio drop-out, leading to a permanent loss of audio;
  • attempts to resolve the problem of drive activity lights sometimes staying permanently on, that arrived in the previous release (and, indirectly, with disk drives having something sort-of momentum-esque, ish);
  • slightly extends Byte Drive 500 emulation to support four drives in principle; and
  • corrects a potential undefined-behaviour causing random memory write shortly after Oric startup.

† for the record, I found the native macOS timer to be over 1,000,000 times as precise as SDL's — its jitter at its specified resolution of nanoseconds was better than SDL's at its specified resolution of milliseconds.

2020-01-16

17 Jan 03:35
1422f8a
Compare
Choose a tag to compare

Modifies the type of RDY signal offered by the Byte Drive 500 interface, to avoid loading issues once the drive has initially spun down.

2020-01-15

16 Jan 05:10
9bb294a
Compare
Choose a tag to compare

This release adds a first guess at implementation of the Oric's Byte Drive 500 disk interface. Which seems to work with the only known surviving Byte Drive 500 disk image, but that could be luck.

2020-01-06

06 Jan 04:03
cdb31b1
Compare
Choose a tag to compare

After a more productive Sunday than expected, this release:

  • adds emulation of the Oric's Jasmin interface; and
  • corrects an issue with AY- and YM-based machines in which channels were never quite fully off.

2020-01-05

05 Jan 19:50
20b25ce
Compare
Choose a tag to compare

This release:

  • implements more of Atari's Intelligent Keyboard protocol, particularly with regard to joysticks — Turrican should now work correctly, amongst others;
  • adds in the ST's mirrored audio registers, causing many demos that were previously silent now to play music; and
  • continues improving the 68000, for the ST and Macintosh:
    • improves flag accuracy of DIVU and DIVS (although some unknowns still dangle);
    • corrects JSR target calculation when it's relative to A7; and
    • fixes access address field and read/write flag in stack frame from a bus or address error.

2020-01-01

02 Jan 01:21
ea45ae7
Compare
Choose a tag to compare

Improves the Atari ST:

  • the emulator's high-level implementation of the IntelligentKeyboard protocol now supports absolute mouse positioning and inverted scales;
    • known fixed titles: Lemmings, Gridrunner;
  • I've made a new guess at the mechanism behind the vertical/horizontal interrupts, preventing multiple firings;
    • known fixed titles: Cisco Heat, E-Motion; and
  • a potential buffer overrun in the emulated graphics subsystem has been fixed.

Also continues the whipping of my 68000 into shape, currently to benefit the Atari ST and the Macintosh:

  • further CHK fixes:
    • N is now set correctly where the destination value is both < 0 and greater than the effective address;
    • a previously missing prefetch cycle has been added to the (xxx).l/w, d(An/PC) and d(An/PC, Xn) address modes; and
  • the processor no longer returns to a STOP it was already at after an interrupt.