1
0
mirror of https://github.com/livingcomputermuseum/ContrAlto.git synced 2026-05-05 07:24:36 +00:00

Initial implementation of Trident controller and drives (supporting T-80 and T-300 packs). TFU works and can certify, erase, exercise and manipulate files on Trident packs. TriEx doesn't quite work properly yet. Still some issues to iron out.

Added file-backed disk image implementation for use with Trident disk images, did some basic refactoring of disk load/unload logic, added support for creating new (empty) disk images for both Trident and Diablo disks.

Added UI for loading/unloading/creating up to 8 trident packs; added blank Diablo pack creation UI.  (Both Windows and *nix interfaces.)

Added configuration support for same (both Windows and *nix.)

Small correction to Print output path browsing logic.

Fixed Windows installer, now places the right ROMs for Alto I configurations in the right place.

Fixed issue when starting up with corrupted configuration.  Corrupted configuration is ignored and ContrAlto will run with default config.
This commit is contained in:
Josh Dersch
2017-08-22 13:18:31 -07:00
parent bfcce44a8f
commit 523a4bb27f
30 changed files with 2969 additions and 406 deletions

View File

@@ -187,11 +187,8 @@ namespace Contralto.SdlUI
throw new InvalidOperationException("Drive specification out of range.");
}
// Save current drive contents.
_system.CommitDiskPack(drive);
// Load the new pack.
_system.LoadDrive(drive, path);
_system.LoadDiabloDrive(drive, path, false);
Console.WriteLine("Drive {0} loaded.", drive);
return CommandResult.Normal;
@@ -205,11 +202,8 @@ namespace Contralto.SdlUI
throw new InvalidOperationException("Drive specification out of range.");
}
// Save current drive contents.
_system.CommitDiskPack(drive);
// Unload the current pack.
_system.UnloadDrive(drive);
_system.UnloadDiabloDrive(drive);
Console.WriteLine("Drive {0} unloaded.", drive);
return CommandResult.Normal;
@@ -236,7 +230,60 @@ namespace Contralto.SdlUI
}
return CommandResult.Normal;
}
}
[DebuggerFunction("load trident", "Loads the specified trident drive with the requested disk image.", "<drive> <path>")]
private CommandResult LoadTrident(ushort drive, string path)
{
if (drive > 7)
{
throw new InvalidOperationException("Drive specification out of range.");
}
// Load the new pack.
_system.LoadTridentDrive(drive, path, false);
Console.WriteLine("Trident {0} loaded.", drive);
return CommandResult.Normal;
}
[DebuggerFunction("unload trident", "Unloads the specified trident drive.", "<drive>")]
private CommandResult UnloadTrident(ushort drive)
{
if (drive > 7)
{
throw new InvalidOperationException("Drive specification out of range.");
}
// Unload the current pack.
_system.UnloadTridentDrive(drive);
Console.WriteLine("Trident {0} unloaded.", drive);
return CommandResult.Normal;
}
[DebuggerFunction("show trident", "Displays the contents of the specified trident drive.", "<drive>")]
private CommandResult ShowTrident(ushort drive)
{
if (drive > 7)
{
throw new InvalidOperationException("Drive specification out of range.");
}
// Save current drive contents.
if (_system.TridentController.Drives[drive].IsLoaded)
{
Console.WriteLine("Trident {0} contains image {1}",
drive,
_system.TridentController.Drives[drive].Pack.PackName);
}
else
{
Console.WriteLine("Trident {0} is not loaded.", drive);
}
return CommandResult.Normal;
}
[DebuggerFunction("show system type", "Displays the Alto system type.")]
private CommandResult ShowSystemType()