summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/formats (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Got rid of global_alloc/global_free. Vas Crabb2020-10-034-40/+46
| | | | | | | | | | | | | | | | | | | | | | | | | The global_alloc/global_free functions have outlived their usefulness. They don't allow consistently overriding the default memory allocation behaviour because they aren't used consistently, and we don't have standard library allocator wrappers for them that we'd need to use them consistently with all the standard library containers we're using. If you need to change the default allocator behaviour, you can override the new/delete operators, and there are ways to get more fine-grained control that way. We're already doing that to pre-fill memory in debug builds. Code was already starting to depend on global_alloc/global_free wrapping new/delete. For example some parts of the code (including the UI and Windows debugger) was putting the result of global_alloc in a std::unique_ptr wrappers without custom deleters, and the SPU sound device was assuming it could use global_free to release memory allocated with operator new. There was also code misunderstanding the behaviour of global_alloc, for example the GROM port cartridge code was checking for nullptr when a failure will actually throw std::bad_alloc. As well as substituting new/delete, I've made several things use smart pointers to reduce the chance of leaks, and fixed a couple of leaks, too.
* formats/cassimg.cpp: Finish encapsulation of cassette_image class. Vas Crabb2020-10-028-218/+218
|
* -imagedev/cassimg.cpp: Make the interface look something like C++. Vas Crabb2020-10-0253-1150/+1025
| | | | -sound/tiasound.cpp: Use some vaguely C++-like code internally.
* Disable SOUND_DEBUG for non-debug builds, and srcclean Vas Crabb2020-09-272-32/+32
|
* imd_dsk: Fix bug when changing IMD image [lfantoniosi] (#7289) lfantoniosi2020-09-251-0/+6
| | | | | * Fix bug when changing IMD image These arrays weren't zeroed when changing a IMD disk for saving.
* Add MDCR support for P2000t (#7215) Erwin Jansen2020-09-172-0/+340
| | | | | | | This adds support for the mini digital cassette recorder that can be found inside a P2000t. This implementation is based on documentation that can be found in https://github.com/p2000t/documentation. In memory of NPM Jansen, who taught me all the magic of bits and bytes.
* VG5000µ updates: Sylvain Glaize2020-08-311-0/+1
| | | | | | - Add wavfile support for reading/writing tapes, for more accuracy. The currently supported K7 file type misses timing data. - VG5000µ adds a wait cycle after the second T state of the M1 cycle of the Z80. Because it was not emulated, the timings were off, especially in the sensible cassette read/write routines. - With wavfile support added and timings fixed, the emulation can now read/write cassette at 1200 and 2400 bauds. - Still keeping the MACHINE_NOT_WORKING flag, as real hardware tests need to be complete.
* formats/flopimg.cpp: Use appropriate standard exceptions for reporting ↵ Vas Crabb2020-08-301-11/+13
| | | | errors, allowing libemu to be removed from imgtool and floptool.
* formats: Get rid of more inappropriate use of emu_fatalerror (and fix some ↵ Vas Crabb2020-08-306-32/+39
| | | | spelling issues, etc. while I'm at it)
* pc_dsk: Ignore 84-byte Disk Copy 4.2 header [Justin Kerk] Justin Kerk2020-08-291-0/+5
|
* formats: Removed some inappropriate uses of emu_fatalerror and stderr. Vas Crabb2020-08-233-29/+42
|
* *atom: cleanup Robbbert2020-08-171-2/+2
|
* acorn_dsk: Added support for Kenda formatted SSD images. Nigel Barnes2020-08-161-2/+14
|
* Revert "mdos dsk: support legacy floppy images, add XDOS support" Vas Crabb2020-08-042-346/+102
| | | | | | This reverts commit 8ada258ec7f74ed37945d91467e3827e2f4fbc63. We are not accepting further legacy floppy formats.
* mdos dsk: support legacy floppy images, add XDOS support 68bit2020-07-292-102/+346
| | | | | | | | | | | | | Add legacy floppy image support which is currently required for the mc6843 FDC emulator and used by the EXORset which run XDOS a variant of MDOS. Add support for 5.25 inch XDOS floppy drive formats as used by the EXORset. Make some of the identity tests more permissive to work with observer disks. The date day and month are reversed on some disks, and the boot rib cluster is lower.
* srcclean for 0.223 Vas Crabb2020-07-263-3/+3
|
* spectrum: implemented Swift Disc and Swift Disc II interfaces MetalliC2020-07-172-0/+84
|
* trd_dsk.cpp add more formats, improve image type detection MetalliC2020-07-142-1/+57
|
* spectrum: add Logitek Proceed 1 C1541 disk interface (not fully working yet) MetalliC2020-07-121-0/+4
|
* spectrum: implemented Speccy-DOS and FloppyOne DOS interfaces, add "IC-DOS" ↵ MetalliC2020-07-114-0/+182
| | | | Beta Plus clone
* mdos dsk: fix the cells size and gaps, make clear its Motorola MDOS 68bit2020-07-042-6/+40
|
* Merge pull request #6896 from 68bit/os9-8inch-16sectors ajrhacker2020-07-021-12/+24
|\ | | | | os9 dsk: add 8 inch, 16 sector, single density formats
| * os9 dsk: add 8 inch, 16 sector, single density formats 68bit2020-07-031-12/+24
| | | | | | | | These formats were by OS9 L1 on the Motorola EXORciser.
* | Merge pull request #6897 from 68bit/motorola-mdos-dsk ajrhacker2020-07-022-0/+295
|\ \ | | | | | | MDOS disk format support
| * | MDOS disk format support 68bit2020-07-032-0/+295
| |/ | | | | | | Motorola DOS, used on the EXORciser etc.
* / wd177x dsk: be permissive of some missing sectors in later tracks 68bit2020-07-031-1/+6
|/ | | | | | A single missing sector was causing it to give up on an images, as incompatible. Being a little more permissive here helps working with some old recovered disk images with some lost sectors.
* this format was redundant (nw) MetalliC2020-06-222-77/+0
|
* srcclean and cleanup (nw) Vas Crabb2020-06-211-2/+2
|
* spectrum.cpp: add Didaktik D40/D80 disk interface MetalliC2020-06-212-0/+77
|
* Add ImageDisk IMD save support lfantoniosi2020-06-132-37/+158
| | | | Allow to save IMD floppy image disk. Tested on Zorba and Kaypro II
* forgot this one (nw) MetalliC2020-05-311-7/+12
|
* dsk_dsk.cpp: be nice and allow to use DS images with SS drives (nw) MetalliC2020-05-261-2/+2
|
* ZX-Spectrum Beta-disc FDCs: modernize/fix FDD motor control MetalliC2020-05-261-1/+6
|
* fix HFE disk write Klaus Kämpf2020-05-071-5/+0
| | | | this fixes https://mametesters.org/view.php?id=7526
* formats: permission from Nigel Barnes to relicense Acorn and AFS disk ↵ Vas Crabb2020-04-135-7/+5
| | | | handlers as BSD-3-Clause (nw)
* (nw) formats: reduce dependencies on libemu Vas Crabb2020-04-1327-79/+103
| | | | | | | | | | | The only link dependency left is emu_fatalerror. The format handlers really shouldn't be throwing fatal errors at all - they should just fail to load an image they can't handle. Maybe the interface should be enhanced to allow better propagation of errors up from the format handlers so they can be displayed in a UI rather than just logged. The only other two dependencies are on logmacro.h (pure macros) and the PAIR type from emucore.h (possibly worth moving to util).
* formats/apridisk.cpp: fixed compile Ivan Vangelista2020-04-131-0/+1
| | | | | ../../../../../src/lib/formats/apridisk.cpp: In member function 'virtual bool apridisk_format::load(io_generic*, uint32_t, floppy_image*)': ../../../../../src/lib/formats/apridisk.cpp:99:7: error: 'fatalerror' was not declared in this scope; did you mean 'strerror'?
* With permission from Dirk Best, apply 3-clause BSD license to common devices ↵ Vas Crabb2020-04-1326-27/+26
| | | | | | and image handling (nw) Note that this does not apply to machine drivers or device implementations for a single machine family (e.g. Amiga chips or VTech expansion bus)
* H8: added support for H8T tapes. Robbbert2020-04-062-0/+168
|
* srcclean (nw) Vas Crabb2020-03-221-17/+17
|
* ibmxdf_dsk: IBM Extended Disk Format support (nw) Sergey Svishchev2020-03-022-0/+307
|
* flex_dsk: include an identify() method. 68bit2020-02-092-0/+10
| | | | | | It is necessary to return a higher score on success, higher than returned by the default method, in order for a general 'identify' to succeed over competitive matches.
* wd177x_dsk: generalize to allow custom track format variations 68bit2020-02-086-324/+1744
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a get_track_format() method that can be overridden to supply format variations for any track and head. The code is generalised to account for such variations. The default method returns the passed format, so this change is neutral for existing formats. Simplify the FLEX DSK format code. There are now simply format variation descriptions for the second track that have the sector ID continuing in sequence from the first track, rather than specialized code. Extend the FLEX format to support variations in the sectors ID of the first two sectors. The FLEX 6800 boot sectors have IDs based at zero rather than one. Extend the FLEX format to support variations for which the first track, on both sides, is single density on an otherwise double density disk which was historically a common format. Extend the OS9 disk format to support variations for which the first track, on only the first side, is single density on an otherwise double density disk. OS9 for the SWTPC and Gimix typically used such formats. Extend the OS9 disk format to support variations with a base sector ID of zero in contrast to the existing COCO OS9 format which uses a based sector ID of one. The OS9 format identification code is extended to rely on the optional information stored in the OS9 LSN0 header to identify COCO format disks, and all COCO format disks appear to have this optional information in a regular enough format.
* Merge pull request #6245 from shattered/_27394e2f097 R. Belmont2020-02-051-5/+29
|\ | | | | aim_dsk: use splice position recorded in the image, if available (nw)
| * aim_dsk: use splice position recorded in the image, if available (nw) Sergey Svishchev2020-01-311-5/+29
| |
* | more debug logging left on, few small cleanups (nw) Vas Crabb2020-02-022-26/+26
|/
* Merge pull request #6195 from firewave/includes R. Belmont2020-01-22127-160/+160
|\ | | | | use C++ library includes (nw)
| * use C++ library includes (nw) firewave2020-01-22127-160/+160
| |
* | Merge pull request #6187 from 68bit/apple2-floppy-options-track-count R. Belmont2020-01-221-3/+3
|\ \ | | | | | | apply2 floppy format: bake in the track count
| * | apply2 floppy format: bake in the track count 68bit2020-01-201-3/+3
| |/ | | | | | | | | | | | | | | The APPLE2_TRACK_COUNT macro was not being expanded here, at least on gcc8. This resulted in the string "APPLE2_TRACK_COUNT" being within the specification and that in turn broke option_resolution::lookup_in_specification leading to an assertion fail with the debug checks enabled. So bake in the numeric constant to at least get things working again.