mirror of
https://github.com/AppleWin/AppleWin.git
synced 2024-12-22 09:30:15 +00:00
b371e3436f
Added new SmartPort Harddisk Controller (HDC) firmware for Enhanced //e. (@burniouf) . remove the old DOSMaster entrypoints. . firmware ID byte (at $FE) defaults to 4 ProDOS block devices (was 2 with older v2 f/w). Enhanced //e defaults to using SP f/w, and older Apple II's still use the older v2 f/w. Support up to 8 units per HDC (currently limited to 4GiB capacity for each unit). Save-state: save HDC firmware in state file. New slot-specific switches to configure each HDC's firmware: -s<N> -hdc-[sp|bm2|bm4]. New switch to select old non-SP firmware for all HDCs: -hdc-firmware-v2.
69 lines
2.2 KiB
C++
69 lines
2.2 KiB
C++
#pragma once
|
|
|
|
#include "Card.h"
|
|
|
|
class ParallelPrinterCard : public Card
|
|
{
|
|
public:
|
|
ParallelPrinterCard(UINT slot) :
|
|
Card(CT_GenericPrinter, slot)
|
|
{
|
|
m_inactivity = 0;
|
|
m_printerIdleLimit = 10;
|
|
m_file = NULL;
|
|
|
|
m_bDumpToPrinter = false;
|
|
m_bConvertEncoding = false;
|
|
m_bFilterUnprintable = false;
|
|
m_bPrinterAppend = false;
|
|
m_bEnableDumpToRealPrinter = false;
|
|
}
|
|
virtual ~ParallelPrinterCard(void) {}
|
|
|
|
virtual void Destroy(void);
|
|
virtual void Reset(const bool powerCycle);
|
|
virtual void Update(const ULONG nExecutedCycles);
|
|
virtual void InitializeIO(LPBYTE pCxRomPeripheral);
|
|
|
|
static BYTE __stdcall IORead(WORD pc, WORD addr, BYTE bWrite, BYTE value, ULONG nExecutedCycles);
|
|
static BYTE __stdcall IOWrite(WORD pc, WORD addr, BYTE bWrite, BYTE value, ULONG nExecutedCycles);
|
|
|
|
static const std::string& GetSnapshotCardName(void);
|
|
virtual void SaveSnapshot(YamlSaveHelper& yamlSaveHelper);
|
|
virtual bool LoadSnapshot(YamlLoadHelper& yamlLoadHelper, UINT version);
|
|
|
|
const std::string& GetFilename(void);
|
|
void SetFilename(const std::string& prtFilename);
|
|
UINT GetIdleLimit(void);
|
|
void SetIdleLimit(UINT Duration);
|
|
|
|
bool GetDumpToPrinter(void) { return m_bDumpToPrinter; }
|
|
void SetDumpToPrinter(bool value) { m_bDumpToPrinter = value; }
|
|
bool GetConvertEncoding(void) { return m_bConvertEncoding; }
|
|
void SetConvertEncoding(bool value) { m_bConvertEncoding = value; }
|
|
bool GetFilterUnprintable(void) { return m_bFilterUnprintable; }
|
|
void SetFilterUnprintable(bool value) { m_bFilterUnprintable = value; }
|
|
bool GetPrinterAppend(void) { return m_bPrinterAppend; }
|
|
void SetPrinterAppend(bool value) { m_bPrinterAppend = value; }
|
|
bool GetEnableDumpToRealPrinter(void) { return m_bEnableDumpToRealPrinter; }
|
|
void SetEnableDumpToRealPrinter(bool value) { m_bEnableDumpToRealPrinter = value; }
|
|
|
|
void GetRegistryConfig(void);
|
|
void SetRegistryConfig(void);
|
|
|
|
private:
|
|
bool CheckPrint(void);
|
|
void ClosePrint(void);
|
|
|
|
DWORD m_inactivity;
|
|
UINT m_printerIdleLimit;
|
|
FILE* m_file;
|
|
std::string m_szPrintFilename;
|
|
|
|
bool m_bDumpToPrinter;
|
|
bool m_bConvertEncoding;
|
|
bool m_bFilterUnprintable;
|
|
bool m_bPrinterAppend;
|
|
bool m_bEnableDumpToRealPrinter; // Set by cmd-line: -printer-real
|
|
};
|