Move all include files to src/include

- 86Box's own headers go to /86box
- munt's public interface goes to /mt32emu
- all slirp headers go to /slirp (might want to consider using only its public inteface)
- single file headers from other projects go in include root
This commit is contained in:
David Hrdlička
2020-03-29 14:24:42 +02:00
parent ef84f51bb1
commit a505894a10
508 changed files with 8394 additions and 3820 deletions

View File

@@ -24,17 +24,17 @@
#include <stdarg.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "device.h"
#include <86box/86box.h>
#include <86box/device.h>
#include "cpu.h"
#include "machine.h"
#include "86box_io.h"
#include "dma.h"
#include "pic.h"
#include "timer.h"
#include "ui.h"
#include "fdd.h"
#include "fdc.h"
#include <86box/machine.h>
#include <86box/io.h>
#include <86box/dma.h>
#include <86box/pic.h>
#include <86box/timer.h>
#include <86box/ui.h>
#include <86box/fdd.h>
#include <86box/fdc.h>
extern uint64_t motoron[FDD_NUM];

View File

@@ -1,184 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Implementation of the NEC uPD-765 and compatible floppy disk
* controller.
*
*
*
* Authors: Sarah Walker, <tommowalker@tommowalker.co.uk>
* Miran Grca, <mgrca8@gmail.com>
* Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2008-2020 Sarah Walker.
* Copyright 2016-2020 Miran Grca.
* Copyright 2018-2020 Fred N. van Kempen.
*/
#ifndef EMU_FDC_H
# define EMU_FDC_H
#define FDC_FLAG_PCJR 0x01 /* PCjr */
#define FDC_FLAG_DISKCHG_ACTLOW 0x02 /* Amstrad, PS/1, PS/2 ISA */
#define FDC_FLAG_AT 0x04 /* AT+, PS/x */
#define FDC_FLAG_PS1 0x08 /* PS/1, PS/2 ISA */
#define FDC_FLAG_SUPERIO 0x10 /* Super I/O chips */
#define FDC_FLAG_START_RWC_1 0x20 /* W83877F, W83977F */
#define FDC_FLAG_MORE_TRACKS 0x40 /* W83877F, W83977F, PC87306, PC87309 */
#define FDC_FLAG_NSC 0x80 /* PC87306, PC87309 */
#define FDC_FLAG_TOSHIBA 0x100 /* T1000, T1200 */
#define FDC_FLAG_AMSTRAD 0x200 /* Non-AT Amstrad machines */
typedef struct {
uint8_t dor, stat, command, processed_cmd, dat, st0, swap;
uint8_t swwp, disable_write;
uint8_t params[256], res[256];
uint8_t specify[256], format_dat[256];
uint8_t config, pretrk;
uint8_t fifobuf[16];
uint16_t base_address;
int head, sector, drive, lastdrive;
int pcn[4], eot[256];
int rw_track, pos;
int pnum, ptot;
int rate, reset_stat;
int lock, perp;
int abort;
int format_state, format_n;
int tc, written;
int step, seek_dir;
int noprec;
int data_ready, inread;
int bitcell_period, enh_mode;
int rwc[4], drvrate[4];
int boot_drive, dma;
int densel_polarity, densel_force;
int fifo, tfifo;
int fifobufpos, drv2en;
int gap, dtl;
int enable_3f1, format_sectors;
int max_track, mfm;
int deleted, wrong_am;
int sc, satisfying_sectors;
int fintr, rw_drive;
int flags, interrupt;
int irq; /* Should be 6 by default. */
int dma_ch; /* Should be 2 by default. */
int bit_rate; /* Should be 250 at start. */
int paramstogo;
sector_id_t read_track_sector;
uint64_t watchdog_count;
pc_timer_t timer, watchdog_timer;
} fdc_t;
extern void fdc_remove(fdc_t *fdc);
extern void fdc_poll(fdc_t *fdc);
extern void fdc_abort(fdc_t *fdc);
extern void fdc_set_dskchg_activelow(fdc_t *fdc);
extern void fdc_3f1_enable(fdc_t *fdc, int enable);
extern int fdc_get_bit_rate(fdc_t *fdc);
extern int fdc_get_bitcell_period(fdc_t *fdc);
/* A few functions to communicate between Super I/O chips and the FDC. */
extern void fdc_update_enh_mode(fdc_t *fdc, int enh_mode);
extern int fdc_get_rwc(fdc_t *fdc, int drive);
extern void fdc_update_rwc(fdc_t *fdc, int drive, int rwc);
extern int fdc_get_boot_drive(fdc_t *fdc);
extern void fdc_update_boot_drive(fdc_t *fdc, int boot_drive);
extern void fdc_update_densel_polarity(fdc_t *fdc, int densel_polarity);
extern uint8_t fdc_get_densel_polarity(fdc_t *fdc);
extern void fdc_update_densel_force(fdc_t *fdc, int densel_force);
extern void fdc_update_drvrate(fdc_t *fdc, int drive, int drvrate);
extern void fdc_update_drv2en(fdc_t *fdc, int drv2en);
extern void fdc_noidam(fdc_t *fdc);
extern void fdc_nosector(fdc_t *fdc);
extern void fdc_nodataam(fdc_t *fdc);
extern void fdc_cannotformat(fdc_t *fdc);
extern void fdc_wrongcylinder(fdc_t *fdc);
extern void fdc_badcylinder(fdc_t *fdc);
extern void fdc_writeprotect(fdc_t *fdc);
extern void fdc_datacrcerror(fdc_t *fdc);
extern void fdc_headercrcerror(fdc_t *fdc);
extern void fdc_nosector(fdc_t *fdc);
extern int real_drive(fdc_t *fdc, int drive);
extern sector_id_t fdc_get_read_track_sector(fdc_t *fdc);
extern int fdc_get_compare_condition(fdc_t *fdc);
extern int fdc_is_deleted(fdc_t *fdc);
extern int fdc_is_sk(fdc_t *fdc);
extern void fdc_set_wrong_am(fdc_t *fdc);
extern int fdc_get_drive(fdc_t *fdc);
extern int fdc_get_perp(fdc_t *fdc);
extern int fdc_get_format_n(fdc_t *fdc);
extern int fdc_is_mfm(fdc_t *fdc);
extern double fdc_get_hut(fdc_t *fdc);
extern double fdc_get_hlt(fdc_t *fdc);
extern void fdc_request_next_sector_id(fdc_t *fdc);
extern void fdc_stop_id_request(fdc_t *fdc);
extern int fdc_get_gap(fdc_t *fdc);
extern int fdc_get_gap2(fdc_t *fdc, int drive);
extern int fdc_get_dtl(fdc_t *fdc);
extern int fdc_get_format_sectors(fdc_t *fdc);
extern uint8_t fdc_get_swwp(fdc_t *fdc);
extern void fdc_set_swwp(fdc_t *fdc, uint8_t swwp);
extern uint8_t fdc_get_diswr(fdc_t *fdc);
extern void fdc_set_diswr(fdc_t *fdc, uint8_t diswr);
extern uint8_t fdc_get_swap(fdc_t *fdc);
extern void fdc_set_swap(fdc_t *fdc, uint8_t swap);
extern void fdc_finishcompare(fdc_t *fdc, int satisfying);
extern void fdc_finishread(fdc_t *fdc);
extern void fdc_sector_finishcompare(fdc_t *fdc, int satisfying);
extern void fdc_sector_finishread(fdc_t *fdc);
extern void fdc_track_finishread(fdc_t *fdc, int condition);
extern int fdc_is_verify(fdc_t *fdc);
extern void fdc_overrun(fdc_t *fdc);
extern void fdc_set_base(fdc_t *fdc, int base);
extern void fdc_set_irq(fdc_t *fdc, int irq);
extern int fdc_getdata(fdc_t *fdc, int last);
extern int fdc_data(fdc_t *fdc, uint8_t data);
extern void fdc_sectorid(fdc_t *fdc, uint8_t track, uint8_t side,
uint8_t sector, uint8_t size, uint8_t crc1,
uint8_t crc2);
extern uint8_t fdc_read(uint16_t addr, void *priv);
extern void fdc_reset(void *priv);
extern uint8_t fdc_get_current_drive(void);
#ifdef EMU_DEVICE_H
extern const device_t fdc_xt_device;
extern const device_t fdc_xt_t1x00_device;
extern const device_t fdc_xt_amstrad_device;
extern const device_t fdc_pcjr_device;
extern const device_t fdc_at_device;
extern const device_t fdc_at_actlow_device;
extern const device_t fdc_at_ps1_device;
extern const device_t fdc_at_smc_device;
extern const device_t fdc_at_winbond_device;
extern const device_t fdc_at_nsc_device;
#endif
#endif /*EMU_FDC_H*/

View File

@@ -24,19 +24,19 @@
#include <string.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "timer.h"
#include "plat.h"
#include "ui.h"
#include "fdd.h"
#include "fdd_86f.h"
#include "fdd_fdi.h"
#include "fdd_imd.h"
#include "fdd_img.h"
#include "fdd_json.h"
#include "fdd_mfm.h"
#include "fdd_td0.h"
#include "fdc.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/plat.h>
#include <86box/ui.h>
#include <86box/fdd.h>
#include <86box/fdd_86f.h>
#include <86box/fdd_fdi.h>
#include <86box/fdd_imd.h>
#include <86box/fdd_img.h>
#include <86box/fdd_json.h>
#include <86box/fdd_mfm.h>
#include <86box/fdd_td0.h>
#include <86box/fdc.h>
/* Flags:

View File

@@ -1,206 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Definitions for the floppy drive emulation.
*
*
*
* Authors: Sarah Walker, <tommowalker@tommowalker.co.uk>
* Miran Grca, <mgrca8@gmail.com>
* Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2008-2018 Sarah Walker.
* Copyright 2016-2018 Miran Grca.
* Copyright 2018 Fred N. van Kempen.
*/
#ifndef EMU_FDD_H
# define EMU_FDD_H
#define FDD_NUM 4
#define SEEK_RECALIBRATE -999
#ifdef __cplusplus
extern "C" {
#endif
extern int fdd_swap;
extern void fdd_set_motor_enable(int drive, int motor_enable);
extern void fdd_do_seek(int drive, int track);
extern void fdd_forced_seek(int drive, int track_diff);
extern void fdd_seek(int drive, int track_diff);
extern int fdd_track0(int drive);
extern int fdd_getrpm(int drive);
extern void fdd_set_densel(int densel);
extern int fdd_can_read_medium(int drive);
extern int fdd_doublestep_40(int drive);
extern int fdd_is_525(int drive);
extern int fdd_is_dd(int drive);
extern int fdd_is_ed(int drive);
extern int fdd_is_double_sided(int drive);
extern void fdd_set_head(int drive, int head);
extern int fdd_get_head(int drive);
extern void fdd_set_turbo(int drive, int turbo);
extern int fdd_get_turbo(int drive);
extern void fdd_set_check_bpb(int drive, int check_bpb);
extern int fdd_get_check_bpb(int drive);
extern void fdd_set_type(int drive, int type);
extern int fdd_get_type(int drive);
extern int fdd_get_flags(int drive);
extern int fdd_get_densel(int drive);
extern char *fdd_getname(int type);
extern char *fdd_get_internal_name(int type);
extern int fdd_get_from_internal_name(char *s);
extern int fdd_current_track(int drive);
typedef struct {
int id;
void (*seek)(int drive, int track);
void (*readsector)(int drive, int sector, int track, int side,
int density, int sector_size);
void (*writesector)(int drive, int sector, int track, int side,
int density, int sector_size);
void (*comparesector)(int drive, int sector, int track, int side,
int density, int sector_size);
void (*readaddress)(int drive, int side, int density);
void (*format)(int drive, int side, int density, uint8_t fill);
int (*hole)(int drive);
uint64_t (*byteperiod)(int drive);
void (*stop)(int drive);
void (*poll)(int drive);
} DRIVE;
extern DRIVE drives[FDD_NUM];
extern wchar_t floppyfns[FDD_NUM][512];
extern pc_timer_t fdd_poll_time[FDD_NUM];
extern int ui_writeprot[FDD_NUM];
extern int curdrive;
extern int fdd_time;
extern int64_t floppytime;
extern void fdd_load(int drive, wchar_t *fn);
extern void fdd_new(int drive, char *fn);
extern void fdd_close(int drive);
extern void fdd_init(void);
extern void fdd_reset(void);
extern void fdd_seek(int drive, int track);
extern void fdd_readsector(int drive, int sector, int track,
int side, int density, int sector_size);
extern void fdd_writesector(int drive, int sector, int track,
int side, int density, int sector_size);
extern void fdd_comparesector(int drive, int sector, int track,
int side, int density, int sector_size);
extern void fdd_readaddress(int drive, int side, int density);
extern void fdd_format(int drive, int side, int density, uint8_t fill);
extern int fdd_hole(int drive);
extern void fdd_stop(int drive);
extern int motorspin;
extern uint64_t motoron[FDD_NUM];
extern int swwp;
extern int disable_write;
extern int defaultwriteprot;
extern int writeprot[FDD_NUM], fwriteprot[FDD_NUM];
extern int fdd_changed[FDD_NUM];
extern int drive_empty[FDD_NUM];
/*Used in the Read A Track command. Only valid for fdd_readsector(). */
#define SECTOR_FIRST -2
#define SECTOR_NEXT -1
typedef union {
uint16_t word;
uint8_t bytes[2];
} crc_t;
void fdd_calccrc(uint8_t byte, crc_t *crc_var);
typedef struct {
uint16_t (*disk_flags)(int drive);
uint16_t (*side_flags)(int drive);
void (*writeback)(int drive);
void (*set_sector)(int drive, int side, uint8_t c, uint8_t h,
uint8_t r, uint8_t n);
uint8_t (*read_data)(int drive, int side, uint16_t pos);
void (*write_data)(int drive, int side, uint16_t pos,
uint8_t data);
int (*format_conditions)(int drive);
int32_t (*extra_bit_cells)(int drive, int side);
uint16_t* (*encoded_data)(int drive, int side);
void (*read_revolution)(int drive);
uint32_t (*index_hole_pos)(int drive, int side);
uint32_t (*get_raw_size)(int drive, int side);
uint8_t check_crc;
} d86f_handler_t;
extern const int gap3_sizes[5][8][48];
extern const uint8_t dmf_r[21];
extern const uint8_t xdf_physical_sectors[2][2];
extern const uint8_t xdf_gap3_sizes[2][2];
extern const uint16_t xdf_trackx_spos[2][8];
typedef struct {
uint8_t h;
uint8_t r;
} xdf_id_t;
typedef union {
uint16_t word;
xdf_id_t id;
} xdf_sector_t;
extern const xdf_sector_t xdf_img_layout[2][2][46];
extern const xdf_sector_t xdf_disk_layout[2][2][38];
typedef struct {
uint8_t c;
uint8_t h;
uint8_t r;
uint8_t n;
} sector_id_fields_t;
typedef union {
uint32_t dword;
uint8_t byte_array[4];
sector_id_fields_t id;
} sector_id_t;
void d86f_set_fdc(void *fdc);
void fdi_set_fdc(void *fdc);
void fdd_set_fdc(void *fdc);
void imd_set_fdc(void *fdc);
void img_set_fdc(void *fdc);
void mfm_set_fdc(void *fdc);
#ifdef __cplusplus
}
#endif
#endif /*EMU_FDD_H*/

View File

@@ -26,18 +26,18 @@
#include <assert.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "timer.h"
#include "dma.h"
#include "nvr.h"
#include "random.h"
#include "plat.h"
#include "ui.h"
#include "fdd.h"
#include "fdc.h"
#include "fdd_86f.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/dma.h>
#include <86box/nvr.h>
#include <86box/random.h>
#include <86box/plat.h>
#include <86box/ui.h>
#include <86box/fdd.h>
#include <86box/fdc.h>
#include <86box/fdd_86f.h>
#ifdef D86F_COMPRESS
#include "lzf/lzf.h"
#include <lzf.h>
#endif

View File

@@ -1,110 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Definitions for the 86F floppy image format.
*
*
*
* Authors: Miran Grca, <mgrca8@gmail.com>
* Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2016-2019 Miran Grca.
* Copyright 2018,2019 Fred N. van Kempen.
*/
#ifndef EMU_FLOPPY_86F_H
# define EMU_FLOPPY_86F_H
#define D86FVER 0x020C
/* Thesere were borrowed from TeleDisk. */
#define SECTOR_DUPLICATED 0x01
#define SECTOR_CRC_ERROR 0x02
#define SECTOR_DELETED_DATA 0x04
#define SECTOR_DATA_SKIPPED 0x10
#define SECTOR_NO_DATA 0x20
#define SECTOR_NO_ID 0x40
#define length_gap0 80
#define length_gap1 50
#define length_sync 12
#define length_am 4
#define length_crc 2
#define IBM
#define MFM
#ifdef IBM
#define pre_gap1 length_gap0 + length_sync + length_am
#else
#define pre_gap1 0
#endif
#define pre_track pre_gap1 + length_gap1
#define pre_gap length_sync + length_am + 4 + length_crc
#define pre_data length_sync + length_am
#define post_gap length_crc
extern d86f_handler_t d86f_handler[FDD_NUM];
extern void d86f_init(void);
extern void d86f_load(int drive, wchar_t *fn);
extern void d86f_close(int drive);
extern void d86f_seek(int drive, int track);
extern int d86f_hole(int drive);
extern uint64_t d86f_byteperiod(int drive);
extern void d86f_stop(int drive);
extern void d86f_poll(int drive);
extern int d86f_realtrack(int track, int drive);
extern void d86f_reset(int drive, int side);
extern void d86f_readsector(int drive, int sector, int track, int side, int density, int sector_size);
extern void d86f_writesector(int drive, int sector, int track, int side, int density, int sector_size);
extern void d86f_comparesector(int drive, int sector, int track, int side, int rate, int sector_size);
extern void d86f_readaddress(int drive, int side, int density);
extern void d86f_format(int drive, int side, int density, uint8_t fill);
extern void d86f_prepare_track_layout(int drive, int side);
extern void d86f_set_version(int drive, uint16_t version);
extern uint16_t d86f_side_flags(int drive);
extern uint16_t d86f_track_flags(int drive);
extern void d86f_initialize_last_sector_id(int drive, int c, int h, int r, int n);
extern void d86f_initialize_linked_lists(int drive);
extern void d86f_destroy_linked_lists(int drive, int side);
extern uint16_t d86f_prepare_sector(int drive, int side, int prev_pos, uint8_t *id_buf, uint8_t *data_buf,
int data_len, int gap2, int gap3, int flags);
extern void d86f_setup(int drive);
extern void d86f_destroy(int drive);
extern int d86f_export(int drive, wchar_t *fn);
extern void d86f_unregister(int drive);
extern void d86f_common_handlers(int drive);
extern void d86f_set_version(int drive, uint16_t version);
extern int d86f_is_40_track(int drive);
extern void d86f_reset_index_hole_pos(int drive, int side);
extern uint16_t d86f_prepare_pretrack(int drive, int side, int iso);
extern void d86f_set_track_pos(int drive, uint32_t track_pos);
extern void d86f_set_cur_track(int drive, int track);
extern void d86f_zero_track(int drive);
extern void d86f_initialize_last_sector_id(int drive, int c, int h, int r, int n);
extern void d86f_initialize_linked_lists(int drive);
extern void d86f_destroy_linked_lists(int drive, int side);
extern uint16_t *common_encoded_data(int drive, int side);
extern void common_read_revolution(int drive);
extern uint32_t common_get_raw_size(int drive, int side);
extern void null_writeback(int drive);
extern void null_write_data(int drive, int side, uint16_t pos, uint8_t data);
extern int null_format_conditions(int drive);
extern int32_t null_extra_bit_cells(int drive, int side);
extern void null_set_sector(int drive, int side, uint8_t c, uint8_t h, uint8_t r, uint8_t n);
extern uint32_t null_index_hole_pos(int drive, int side);
#endif /*EMU_FLOPPY_86F_H*/

View File

@@ -19,10 +19,10 @@
#include <string.h>
#include <stdlib.h>
#include <wchar.h>
#include "86box.h"
#include "timer.h"
#include "fdd.h"
#include "fdd_common.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/fdd.h>
#include <86box/fdd_common.h>
const uint8_t fdd_holes[6] = { 0, 0, 0, 1, 1, 2 };

View File

@@ -1,35 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Shared code for all the floppy modules.
*
*
*
* Author: Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2017,2018 Fred N. van Kempen.
*/
#ifndef FDD_COMMON_H
# define FDD_COMMON_H
extern const uint8_t fdd_holes[6];
extern const uint8_t fdd_rates[6];
extern const double fdd_bit_rates_300[6];
extern const uint8_t fdd_max_sectors[8][6];
extern const uint8_t fdd_dmf_r[21];
extern int fdd_get_gap3_size(int rate, int size, int sector);
extern uint8_t fdd_sector_size_code(int size);
extern int fdd_sector_code_size(uint8_t code);
extern int fdd_bps_valid(uint16_t bps);
extern int fdd_interleave(int sector, int skew, int spt);
#endif /*FDD_COMMON_H*/

View File

@@ -26,15 +26,15 @@
#include <stdlib.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "timer.h"
#include "plat.h"
#include "fdd.h"
#include "fdd_86f.h"
#include "fdd_img.h"
#include "fdd_fdi.h"
#include "fdc.h"
#include "fdi2raw.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/plat.h>
#include <86box/fdd.h>
#include <86box/fdd_86f.h>
#include <86box/fdd_img.h>
#include <86box/fdd_fdi.h>
#include <86box/fdc.h>
#include <fdi2raw.h>
typedef struct {

View File

@@ -1,31 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Implementation of the FDI floppy stream image format
* interface to the FDI2RAW module.
*
*
*
* Authors: Sarah Walker, <tommowalker@tommowalker.co.uk>
* Miran Grca, <mgrca8@gmail.com>
* Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2008-2018 Sarah Walker.
* Copyright 2016-2018 Miran Grca.
* Copyright 2018 Fred N. van Kempen.
*/
#ifndef EMU_FLOPPY_FDI_H
# define EMU_FLOPPY_FDI_H
extern void fdi_seek(int drive, int track);
extern void fdi_load(int drive, wchar_t *fn);
extern void fdi_close(int drive);
#endif /*EMU_FLOPPY_FDI_H*/

View File

@@ -23,13 +23,13 @@
#include <stdlib.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "timer.h"
#include "plat.h"
#include "fdd.h"
#include "fdd_86f.h"
#include "fdd_imd.h"
#include "fdc.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/plat.h>
#include <86box/fdd.h>
#include <86box/fdd_86f.h>
#include <86box/fdd_imd.h>
#include <86box/fdc.h>
typedef struct {

View File

@@ -1,46 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Definitions for the IMD floppy image format.
*
*
*
* Authors: Miran Grca, <mgrca8@gmail.com>
* Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2016-2018 Miran Grca.
* Copyright 2018 Fred N. van Kempen.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the:
*
* Free Software Foundation, Inc.
* 59 Temple Place - Suite 330
* Boston, MA 02111-1307
* USA.
*/
#ifndef EMU_FLOPPY_IMD_H
# define EMU_FLOPPY_IMD_H
extern void imd_init(void);
extern void imd_load(int drive, wchar_t *fn);
extern void imd_close(int drive);
#endif /*EMU_FLOPPY_IMD_H*/

View File

@@ -30,14 +30,14 @@
#include <stdlib.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "timer.h"
#include "config.h"
#include "plat.h"
#include "fdd.h"
#include "fdd_86f.h"
#include "fdd_img.h"
#include "fdc.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/config.h>
#include <86box/plat.h>
#include <86box/fdd.h>
#include <86box/fdd_86f.h>
#include <86box/fdd_img.h>
#include <86box/fdc.h>
typedef struct {

View File

@@ -1,31 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Implementation of the raw sector-based floppy image format,
* as well as the Japanese FDI, CopyQM, and FDF formats.
*
*
*
* Authors: Sarah Walker, <tommowalker@tommowalker.co.uk>
* Miran Grca, <mgrca8@gmail.com>
* Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2008-2018 Sarah Walker.
* Copyright 2016-2018 Miran Grca.
* Copyright 2018 Fred N. van Kempen.
*/
#ifndef EMU_FLOPPY_IMG_H
# define EMU_FLOPPY_IMG_H
extern void img_init(void);
extern void img_load(int drive, wchar_t *fn);
extern void img_close(int drive);
#endif /*EMU_FLOPPY_IMG_H*/

View File

@@ -51,14 +51,14 @@
#include <stdlib.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "timer.h"
#include "plat.h"
#include "fdd.h"
#include "fdd_86f.h"
#include "fdc.h"
#include "fdd_common.h"
#include "fdd_json.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/plat.h>
#include <86box/fdd.h>
#include <86box/fdd_86f.h>
#include <86box/fdc.h>
#include <86box/fdd_common.h>
#include <86box/fdd_json.h>
#define NTRACKS 256

View File

@@ -1,56 +0,0 @@
/*
* VARCem Virtual ARchaeological Computer EMulator.
* An emulator of (mostly) x86-based PC systems and devices,
* using the ISA,EISA,VLB,MCA and PCI system buses, roughly
* spanning the era between 1981 and 1995.
*
* This file is part of the VARCem Project.
*
* Definitions for the PCjs JSON floppy image format.
*
*
*
* Author: Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2017,2018 Fred N. van Kempen.
*
* Redistribution and use in source and binary forms, with
* or without modification, are permitted provided that the
* following conditions are met:
*
* 1. Redistributions of source code must retain the entire
* above notice, this list of conditions and the following
* disclaimer.
*
* 2. Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the
* following disclaimer in the documentation and/or other
* materials provided with the distribution.
*
* 3. Neither the name of the copyright holder nor the names
* of its contributors may be used to endorse or promote
* products derived from this software without specific
* prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef EMU_FLOPPY_JSON_H
# define EMU_FLOPPY_JSON_H
extern void json_init(void);
extern void json_load(int drive, wchar_t *fn);
extern void json_close(int drive);
#endif /*EMU_FLOPPY_JSON_H*/

View File

@@ -22,14 +22,14 @@
#include <string.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "timer.h"
#include "plat.h"
#include "fdd.h"
#include "fdd_86f.h"
#include "fdd_img.h"
#include "fdd_mfm.h"
#include "fdc.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/plat.h>
#include <86box/fdd.h>
#include <86box/fdd_86f.h>
#include <86box/fdd_img.h>
#include <86box/fdd_mfm.h>
#include <86box/fdc.h>
#pragma pack(push,1)

View File

@@ -1,26 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Implementation of the HxC MFM image format.
*
*
*
* Authors: Miran Grca, <mgrca8@gmail.com>
*
* Copyright 2018 Miran Grca.
*/
#ifndef EMU_FLOPPY_MFM_H
# define EMU_FLOPPY_MFM_H
extern void mfm_seek(int drive, int track);
extern void mfm_load(int drive, wchar_t *fn);
extern void mfm_close(int drive);
#endif /*EMU_FLOPPY_MFM_H*/

View File

@@ -35,13 +35,13 @@
#include <stdlib.h>
#include <wchar.h>
#define HAVE_STDARG_H
#include "86box.h"
#include "timer.h"
#include "plat.h"
#include "fdd.h"
#include "fdd_86f.h"
#include "fdd_td0.h"
#include "fdc.h"
#include <86box/86box.h>
#include <86box/timer.h>
#include <86box/plat.h>
#include <86box/fdd.h>
#include <86box/fdd_86f.h>
#include <86box/fdd_td0.h>
#include <86box/fdc.h>
#define BUFSZ 512 /* new input buffer */

View File

@@ -1,28 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Definitions for the Teledisk floppy image format.
*
*
*
* Authors: Miran Grca, <mgrca8@gmail.com>
* Fred N. van Kempen, <decwiz@yahoo.com>
*
* Copyright 2016-2018 Miran Grca.
* Copyright 2017,2018 Fred N. van Kempen.
*/
#ifndef EMU_FLOPPY_TD0_H
# define EMU_FLOPPY_TD0_H
extern void td0_init(void);
extern void td0_load(int drive, wchar_t *fn);
extern void td0_close(int drive);
#endif /*EMU_FLOPPY_TD0_H*/

View File

@@ -37,8 +37,8 @@
/* ELSE */
#define xmalloc malloc
#define HAVE_STDARG_H
#include "86box.h"
#include "fdi2raw.h"
#include <86box/86box.h>
#include <fdi2raw.h>
#undef DEBUG

View File

@@ -1,54 +0,0 @@
/*
* 86Box A hypervisor and IBM PC system emulator that specializes in
* running old operating systems and software designed for IBM
* PC systems and compatibles from 1981 through fairly recent
* system designs based on the PCI bus.
*
* This file is part of the 86Box distribution.
*
* Definitions for the FDI floppy file format.
*
*
*
* Authors: Toni Wilen, <twilen@arabuusimiehet.com>
* and Vincent Joguin,
* Thomas Harte, <T.Harte@excite.co.uk>
*
* Copyright 2001-2004 Toni Wilen.
* Copyright 2001-2004 Vincent Joguin.
* Copyright 2001 Thomas Harte.
*/
#ifndef __FDI2RAW_H
#define __FDI2RAW_H
#define uae_u8 uint8_t
#define uae_u16 uint16_t
#define uae_u32 uint32_t
#include <stdio.h>
typedef struct fdi FDI;
#ifdef __cplusplus
extern "C" {
#endif
extern int fdi2raw_loadtrack (FDI*, uae_u16 *mfmbuf, uae_u16 *tracktiming, int track, int *tracklength, int *indexoffset, int *multirev, int mfm);
extern int fdi2raw_loadrevolution (FDI*, uae_u16 *mfmbuf, uae_u16 *tracktiming, int track, int *tracklength, int mfm);
extern FDI *fdi2raw_header(FILE *f);
extern void fdi2raw_header_free (FDI *);
extern int fdi2raw_get_last_track(FDI *);
extern int fdi2raw_get_num_sector (FDI *);
extern int fdi2raw_get_last_head(FDI *);
extern int fdi2raw_get_type (FDI *);
extern int fdi2raw_get_bit_rate (FDI *);
extern int fdi2raw_get_rotation (FDI *);
extern int fdi2raw_get_write_protect (FDI *);
extern int fdi2raw_get_tpi (FDI *);
#ifdef __cplusplus
}
#endif
#endif