diff --git a/ASR33/ASR33.h b/ASR33/ASR33.h new file mode 100644 index 0000000..4cb7598 --- /dev/null +++ b/ASR33/ASR33.h @@ -0,0 +1,83 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33.h - ASR 33 Teletype for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define KBB_CHANGED_NOTIFICATION @"asr33KeyboardBufferChangedNotification" +#define TTO_CHANGED_NOTIFICATION @"asr33TeletypeOutputChangedNotification" +#define TTY_ONLINE_CHANGED_NOTIFICATION @"asr33TTYOnlineChangedNotification" + + +@class NSCondition, PaperTapeController, ASR33TextView, ASR33WindowController, TypeaheadBuffer; + + +@interface ASR33 : PDP8Plugin +{ +@public +/* The attributes are public, so the C functions implementing the PDP-8 instructions can + access them directly. No other Cocoa code should use them directly. To ensure this, + the register names are mapped to dummy names with the #defines below. In the source + codes files with the instruction C functions, #define USE_ASR33_REGISTERS_DIRECTLY + to make the registers available. */ + unsigned short KBB; + unsigned long inflag; + unsigned long outflag; + unsigned short output; +@private + unsigned short TTO; // private: not accessed by IOTs + short int input; // int: can be EOF == -1 + unsigned short inAddress; + unsigned short outAddress; + unsigned short punchMask; + IBOutlet PaperTapeController *reader; + IBOutlet PaperTapeController *punch; + IBOutlet ASR33TextView *textview; + IBOutlet ASR33WindowController *windowController; + IBOutlet TypeaheadBuffer *typeaheadBuffer; + BOOL online; + NSConditionLock *inputLock; + NSConditionLock *outputLock; + NSCondition *outputOnline; + BOOL runWithRealtimeSpeed; + BOOL playSound; + float soundVolume; + BOOL isConsoleTTY; +} + +- (unsigned short) getKBB; +- (void) setKBB:(unsigned short)kbb; +- (unsigned short) getTTO; +- (void) setTTO:(unsigned short)tto; +- (BOOL) getOnline; +- (void) setOnline:(BOOL)onlineOffline; +- (void) canContinueOutput; + +@end + + +#if ! USE_ASR33_REGISTERS_DIRECTLY +#define KBB __dont_use_KBB__ +#define inflag __dont_use_inflag__ +#define outflag __dont_use_outflag__ +#define input __dont_use_input__ +#define output __dont_use_output__ +#endif diff --git a/ASR33/ASR33.m b/ASR33/ASR33.m new file mode 100644 index 0000000..f1198fe --- /dev/null +++ b/ASR33/ASR33.m @@ -0,0 +1,484 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33.m - ASR 33 Teletype for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" +#import "PluginFramework/Utilities.h" +#import "PluginFramework/FileDropControlTargetProtocol.h" +#import "PluginFramework/PaperTapeController.h" +#import "PluginFramework/InputConsumerProtocol.h" +#import "PluginFramework/NSThread+MainThread.h" + +#define USE_ASR33_REGISTERS_DIRECTLY 1 + +#import "ASR33.h" +#import "ASR33TextView.h" +#import "ASR33WindowController.h" +#import "ASR33iot.h" +#import "ASR33Preferences.h" +#import "TypeaheadBuffer.h" + + +#define ASR33_CONTTY_PLUGIN_NAME NSLocalizedStringFromTableInBundle( \ + @"ASR 33 Console Teletype.pdp8Plugin", nil, [self bundle], @"") +#define ASR33_AUXTTY_IO_INFO_FILENAME @"auxtty-io-info" + +#define CODER_KEY_KBB @"kbb" +#define CODER_KEY_TTO @"tto" +#define CODER_KEY_INFLAG @"inflag" +#define CODER_KEY_INMASK @"inmask" +#define CODER_KEY_OUTFLAG @"outflag" +#define CODER_KEY_OUTMASK @"outmask" +#define CODER_KEY_ONLINE @"online" + +#define NO_OUTPUT 0 +#define OUTPUT 1 +#define NO_INPUT 0 +#define INPUT 1 + +#define TELETYPE_DELAY 100000 // 100.000 microseconds = 0.1 second + +#define SOUND_BACKSPACE @"tty-backspace" +#define SOUND_BELL @"tty-bell" +#define SOUND_CARRIAGE_RETURN @"tty-carriage-return" +#define SOUND_KEYSTROKE1 @"tty-keystroke1" +#define SOUND_KEYSTROKE2 @"tty-keystroke2" +#define SOUND_KEYSTROKE3 @"tty-keystroke3" +#define SOUND_KEYSTROKE4 @"tty-keystroke4" +#define SOUND_SPACE @"tty-space" +#define SOUND_TYPE @"mp3" + + +@interface NSSound (SetVolume) + +- (void) setVolume:(float)volume; // this is a Leopard method, not available with Tiger + +@end + + +@implementation ASR33 + + +API_VERSION + + +#pragma mark Plugin Methods + + +- (NSString *) ioInformationPlistName +{ + isConsoleTTY = [[self pluginName] isEqualToString:ASR33_CONTTY_PLUGIN_NAME]; + return isConsoleTTY ? [super ioInformationPlistName] : ASR33_AUXTTY_IO_INFO_FILENAME; +} + + +- (NSArray *) iotsForAddress:(int)ioAddress +{ + if (inAddress == 0) { + inAddress = ioAddress; + return [NSArray arrayWithObjects: + [NSValue valueWithPointer:i6030], + [NSValue valueWithPointer:i6031], + [NSValue valueWithPointer:i6032], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:i6034], + [NSValue valueWithPointer:i6035], + [NSValue valueWithPointer:i6036], + [NSValue valueWithPointer:nil], + nil]; + } else { + outAddress = ioAddress; + return [NSArray arrayWithObjects: + [NSValue valueWithPointer:i6040], + [NSValue valueWithPointer:i6041], + [NSValue valueWithPointer:i6042], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:i6044], + [NSValue valueWithPointer:i6045], + [NSValue valueWithPointer:i6046], + [NSValue valueWithPointer:nil], + nil]; + } +} + + +- (NSArray *) skiptestsForAddress:(int)ioAddress +{ + return ioAddress == inAddress ? + [NSArray arrayWithObjects: + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6031], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + nil] : + [NSArray arrayWithObjects: + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6041], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6045], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + nil]; +} + + +- (void) setIOFlag:(unsigned long)flag forIOFlagName:(NSString *)name; +{ + if (inflag) + outflag = flag; + else + inflag = flag; +} + + +- (void) CAF:(int)ioAddress +{ + if (ioAddress == inAddress) { // CAF is called twice, ignore second call + KBB = 0; + TTO = 0; + [pdp8 setInterruptMaskBits:inflag | outflag]; + [pdp8 clearIOFlagBits:inflag | outflag]; + } +} + + +- (void) clearAllFlags:(int)ioAddress +{ +/* Don't modify the online state - software can't turn the TTY power knob. + Don't modify the on/off state of the reader/punch (else the user cannot + load BIN tapes as described in the Small Computer Systems Handbook, + where he must operate CLEAR/CONT *after* turning on the reader). */ + if (ioAddress == inAddress) { // CAF is called twice, ignore second call + [self setKBB:0]; + [self setTTO:0]; + [pdp8 setInterruptMaskBits:inflag | outflag]; + [pdp8 clearIOFlagBits:inflag | outflag]; + } +} + + +- (void) resetDevice +{ + [typeaheadBuffer flush:self]; + [self setKBB:0]; + [self setTTO:0]; + [pdp8 setInterruptMaskBits:inflag | outflag]; + [pdp8 clearIOFlagBits:inflag | outflag]; + [self setOnline:YES]; +} + + +#pragma mark Thread Handling + + +- (void) playSound:(unsigned short)key +{ + NSString *soundname; + + NSAssertRunningOnMainThread (); + key &= 0177; + if (playSound || key == '\a') { + if (isblank(key)) + soundname = SOUND_SPACE; + else if (key == '\b') + soundname = SOUND_BACKSPACE; + else if (key == '\a') + soundname = SOUND_BELL; + else if (key == '\r') + soundname = SOUND_CARRIAGE_RETURN; + else if (isupper(key)) + soundname = SOUND_KEYSTROKE1; + else if (islower(key)) + soundname = SOUND_KEYSTROKE2; + else if (isdigit(key)) + soundname = SOUND_KEYSTROKE3; + else + soundname = SOUND_KEYSTROKE4; + NSSound *sound = [[NSSound alloc] initWithContentsOfFile: + [[self bundle] pathForResource:soundname ofType:SOUND_TYPE] byReference:YES]; + [sound autorelease]; + if ([sound respondsToSelector:@selector(setVolume:)]) + [sound setVolume:soundVolume]; + [sound play]; + } +} + + +- (void) canContinueInput +{ + if ([inputLock tryLockWhenCondition:NO_INPUT]) + [inputLock unlockWithCondition:INPUT]; + /* else + User typed so fast that input would be lost, but the typeahead buffer keeps this input. */ +} + + +- (void) canContinueOutput +{ + if ([outputLock tryLockWhenCondition:NO_OUTPUT]) + [outputLock unlockWithCondition:OUTPUT]; +#if ! defined(NS_BLOCK_ASSERTIONS) + else + NSLog (@"PDP-8 software bug: TPC or TLS executed before preceding TTY output finished"); +#endif +} + + +- (void) setTeletypeOutputFlag +{ + NSAssertRunningOnMainThread (); + [pdp8 setIOFlagBits:outflag]; +} + + +- (void) processInput +{ + NSAssertRunningOnMainThread (); + input &= 0377; // strip off Unicode characters etc. + if (online) { + [self setKBB:input]; + [pdp8 setIOFlagBits:inflag]; + } else { + [self playSound:input]; + [punch putChar:input & punchMask handleBackspace:YES]; + [textview putChar:input & 0177]; + } +} + + +- (void) processOutput +{ + NSAssertRunningOnMainThread (); + [self playSound:output]; + [self setTTO:output]; + [punch putChar:output & punchMask handleBackspace:NO]; + [textview putChar:output & 0177]; +} + + +- (void) getReaderChar +{ + NSAssertRunningOnMainThread (); + input = [reader getChar]; +} + + +- (uint64_t) realtimeDelay:(uint64_t)maTime +{ + if (runWithRealtimeSpeed) { + uint64_t us = absolute2nanoseconds(mach_absolute_time() - maTime) / 1000; + if (us < TELETYPE_DELAY) + usleep (TELETYPE_DELAY - us); + maTime = mach_absolute_time(); + } + return maTime; +} + + +- (void) asr33InputThread:(id)object +{ + [[NSAutoreleasePool alloc] init]; + for (;;) { + [inputLock lockWhenCondition:INPUT]; + uint64_t maTime = mach_absolute_time(); + while ((! online || [pdp8 getIOFlagBits:inflag] == 0) && + ([self performSelectorOnMainThread:@selector(getReaderChar) + withObject:nil waitUntilDone:YES], input != EOF)) { + maTime = [self realtimeDelay:maTime]; + [self performSelectorOnMainThread:@selector(processInput) + withObject:nil waitUntilDone:YES]; + } + while ([typeaheadBuffer hasCharacters] && + (! online || [pdp8 isStopped] || [pdp8 getIOFlagBits:inflag] == 0)) { + input = [typeaheadBuffer getNextChar] | 0200; + maTime = [self realtimeDelay:maTime]; + [self performSelectorOnMainThread:@selector(processInput) + withObject:nil waitUntilDone:YES]; + } + [inputLock unlockWithCondition:NO_INPUT]; + } +} + + +- (void) asr33OutputThread:(id)object +{ + [[NSAutoreleasePool alloc] init]; + [outputOnline lock]; + for (;;) { + if (! online) + [outputOnline wait]; + [outputLock lockWhenCondition:OUTPUT]; + uint64_t maTime = mach_absolute_time(); + [self performSelectorOnMainThread:@selector(processOutput) + withObject:nil waitUntilDone:YES]; + [self realtimeDelay:maTime]; + [outputLock unlockWithCondition:NO_OUTPUT]; + [self performSelectorOnMainThread:@selector(setTeletypeOutputFlag) + withObject:nil waitUntilDone:YES]; + } +} + + +#pragma mark Register Access + + +- (unsigned short) getKBB +{ + return KBB; +} + + +- (void) setKBB:(unsigned short)kbb +{ + NSAssert1 ((kbb & ~0377) == 0, @"Bad KBB: 0%o", kbb); + KBB = kbb; + [[NSNotificationCenter defaultCenter] postNotificationName:KBB_CHANGED_NOTIFICATION object:self]; +} + + +- (unsigned short) getTTO +{ + return TTO; +} + + +- (void) setTTO:(unsigned short)tto +{ + NSAssert1 ((tto & ~0377) == 0, @"Bad TTO: 0%o", tto); + TTO = tto; + [[NSNotificationCenter defaultCenter] postNotificationName:TTO_CHANGED_NOTIFICATION object:self]; +} + + +- (BOOL) getOnline +{ + return online; +} + + +- (void) setOnline:(BOOL)onlineOffline +{ + online = onlineOffline; + [outputOnline signal]; + if (! online) + [self canContinueInput]; + [[NSNotificationCenter defaultCenter] + postNotificationName:TTY_ONLINE_CHANGED_NOTIFICATION object:self]; +} + + +#pragma mark Initialization + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + [self setKBB:[coder decodeIntForKey:CODER_KEY_KBB]]; + [self setTTO:[coder decodeIntForKey:CODER_KEY_TTO]]; + [coder decodeBoolForKey:CODER_KEY_INFLAG] ? + [pdp8 setIOFlagBits:inflag] : [pdp8 clearIOFlagBits:inflag]; + [coder decodeBoolForKey:CODER_KEY_INMASK] ? + [pdp8 setInterruptMaskBits:inflag] : [pdp8 clearInterruptMaskBits:inflag]; + [coder decodeBoolForKey:CODER_KEY_OUTFLAG] ? + [pdp8 setIOFlagBits:outflag] : [pdp8 clearIOFlagBits:outflag]; + [coder decodeBoolForKey:CODER_KEY_OUTMASK] ? + [pdp8 setInterruptMaskBits:outflag] : [pdp8 clearInterruptMaskBits:outflag]; + [self setOnline:[coder decodeBoolForKey:CODER_KEY_ONLINE]]; + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + [coder encodeInt:[self getKBB] forKey:CODER_KEY_KBB]; + [coder encodeInt:[self getTTO] forKey:CODER_KEY_TTO]; + [coder encodeBool:[pdp8 getIOFlagBits:inflag] ? YES : NO forKey:CODER_KEY_INFLAG]; + [coder encodeBool:[pdp8 getInterruptMaskBits:inflag] ? YES : NO forKey:CODER_KEY_INMASK]; + [coder encodeBool:[pdp8 getIOFlagBits:outflag] ? YES : NO forKey:CODER_KEY_OUTFLAG]; + [coder encodeBool:[pdp8 getInterruptMaskBits:outflag] ? YES : NO forKey:CODER_KEY_OUTMASK]; + [coder encodeBool:[self getOnline] forKey:CODER_KEY_ONLINE]; +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"ASR33 notifyApplicationWillTerminate"); + [[NSNotificationCenter defaultCenter] removeObserver:self name:NSUserDefaultsDidChangeNotification + object:nil]; + NSMutableData *data = [NSMutableData data]; + NSKeyedArchiver *archiver = [[NSKeyedArchiver alloc] initForWritingWithMutableData:data]; + [self encodeWithCoder:archiver]; + [archiver finishEncoding]; + [archiver release]; + [[NSUserDefaults standardUserDefaults] setObject:data forKey:[self pluginName]]; +} + + +- (void) notifyPreferencesChanged:(NSNotification *)notification +{ + // NSLog (@"ASR33 notifyPreferencesChanged"); + NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; + runWithRealtimeSpeed = [defaults integerForKey:ASR33_PREFS_SPEED_KEY]; + playSound = runWithRealtimeSpeed && [defaults boolForKey:ASR33_PREFS_PLAY_SOUND]; + soundVolume = [defaults objectForKey:ASR33_PREFS_SOUND_VOLUME] ? + [defaults floatForKey:ASR33_PREFS_SOUND_VOLUME] : 0.5f; + punchMask = [defaults boolForKey:ASR33_PREFS_MASK_HIGHBIT_KEY] ? 0177 : 0377; +} + + +- (void) pluginDidLoad +{ + NSData *data = [[NSUserDefaults standardUserDefaults] dataForKey:[self pluginName]]; + if (data) { + NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data]; + self = [self initWithCoder:unarchiver]; + [unarchiver finishDecoding]; + [unarchiver release]; + } else + [self setOnline:YES]; + inputLock = [[NSConditionLock alloc] initWithCondition:NO_INPUT]; + outputLock = [[NSConditionLock alloc] initWithCondition:NO_OUTPUT]; + outputOnline = [[NSCondition alloc] init]; + [NSThread detachNewThreadSelector:@selector(asr33InputThread:) toTarget:self withObject:nil]; + [NSThread detachNewThreadSelector:@selector(asr33OutputThread:) toTarget:self withObject:nil]; + [windowController setWindowTitle:[[self pluginName] stringByDeletingPathExtension]]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPreferencesChanged:) + name:NSUserDefaultsDidChangeNotification object:nil]; + [self notifyPreferencesChanged:nil]; +} + + +@end diff --git a/ASR33/ASR33TextView.h b/ASR33/ASR33TextView.h new file mode 100644 index 0000000..d6a4b91 --- /dev/null +++ b/ASR33/ASR33TextView.h @@ -0,0 +1,35 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33TextView.h - NSTextView for the ASR 33 Teletype + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class TypeaheadBuffer; + + +@interface ASR33TextView : NSTextView { +@private + IBOutlet TypeaheadBuffer *typeaheadBuffer; +} + +- (void) putChar:(unichar)c; + +@end diff --git a/ASR33/ASR33TextView.m b/ASR33/ASR33TextView.m new file mode 100644 index 0000000..817140f --- /dev/null +++ b/ASR33/ASR33TextView.m @@ -0,0 +1,161 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33TextView.m - NSTextView for the ASR 33 Teletype + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "ASR33TextView.h" +#import "TypeaheadBuffer.h" + + +@implementation ASR33TextView + + +- (BOOL) validateUserInterfaceItem:(id )item +{ + SEL action = [item action]; + return (action == @selector(copy:) || + action == @selector(paste:) || + action == @selector(selectAll:) || + action == @selector(_learnSpellingFromMenu:) || + action == @selector(spotlight:) || + action == @selector(_searchWithGoogleFromMenu:) || + action == @selector(_lookUpIndefiniteRangeInDictionaryFromMenu:) || + action == @selector(startSpeaking:) || + action == @selector(stopSpeaking:)) ? + [super validateUserInterfaceItem:item] : FALSE; +} + + +- (void) doCommandBySelector:(SEL)selector +{ + NSString *selectorName = NSStringFromSelector(selector); + // NSLog (@"doCommandByselector %@", selectorName); + if (selector == @selector(insertNewline:)) + [typeaheadBuffer typeahead:@"\r"]; + else if (selector == @selector(deleteBackward:)) + [typeaheadBuffer typeahead:@"\b"]; + else if (selector == @selector(deleteForward:)) + [typeaheadBuffer typeahead:@"\177"]; // Rubout + else if (selector == @selector(cancelOperation:)) + [typeaheadBuffer typeahead:@"\033"]; // Escape + else if (selector == @selector(centerSelectionInVisibleArea:)) + [typeaheadBuffer typeahead:@"\f"]; // Ctrl-L + else if (selector == @selector(pageDown:)) + [typeaheadBuffer typeahead:@"\026"]; // Ctrl-V + else if (selector == @selector(noop:)) { + NSEvent *currentEvent = [NSApp currentEvent]; + unsigned modifierFlags = [currentEvent modifierFlags]; + unsigned c = [[currentEvent charactersIgnoringModifiers] characterAtIndex:0]; + if (modifierFlags & NSControlKeyMask) { + switch (c) { + case 'c' : + case 'C' : + [typeaheadBuffer typeahead:@"\003"]; // Ctrl-C + break; + case 'z' : + case 'Z' : + [typeaheadBuffer typeahead:@"\032"]; // Ctrl-Z + break; + default : + NSLog (@"character %c (%o) ignored", c, c); + break; + } + } else if (modifierFlags & NSFunctionKeyMask) { + if (c == 0xf739) // fn-6 = forward delete on notebook keyboards + [typeaheadBuffer typeahead:@"\177"]; // Rubout + } + } else if (selector != @selector(complete:) && + ! [selectorName hasPrefix:@"delete"]) // ignore all delete* selectors + [super doCommandBySelector:selector]; +} + + +- (BOOL) readSelectionFromPasteboard:(NSPasteboard *)pasteboard type:(NSString *)type +{ + [pasteboard types]; // required before accessing the pasteboards data + if ([type isEqualToString:NSStringPboardType]) { + [typeaheadBuffer typeahead:[pasteboard stringForType:type]]; + return YES; + } + return NO; +} + + +- (void) insertText:(NSString *)string +{ + [typeaheadBuffer typeahead:string]; +} + + +- (void) putChar:(unichar)c +{ + NSTextStorage *storage = [self textStorage]; + int length = [storage length]; + NSRange endOfText = NSMakeRange(length, 0); + [self scrollRangeToVisible:endOfText]; + [self setSelectedRange:endOfText]; + switch (c) { + case '\a' : + // NSBeep (); // handled by the ASR33 method playSound: + break; + case '\b' : + if (length && [[storage string] characterAtIndex:length - 1] != '\n') + [super deleteBackward:self]; + break; + default : + [super insertText:[NSString stringWithCharacters:&c length:1]]; + break; + } +} + + +- (void) awakeFromNib +{ + // set size of container - to make horizontal scroller appear + NSTextContainer *container = [self textContainer]; + NSSize size = [container containerSize]; + size.width = UINT_MAX; + [container setContainerSize:size]; + [container setWidthTracksTextView:NO]; + + // set default font + NSFont *font = [NSFont userFixedPitchFontOfSize:11]; + [self setFont:font]; + + // set tabstop every 8 character + NSMutableParagraphStyle *style = [[[NSParagraphStyle defaultParagraphStyle] mutableCopy] autorelease]; + [style setTabStops:[NSArray array]]; + NSDictionary *attrs = [NSDictionary dictionaryWithObjectsAndKeys:font, NSFontAttributeName, nil]; + NSAttributedString *str = + [[[NSAttributedString alloc] initWithString:@" " attributes:attrs] autorelease]; + [style setDefaultTabInterval:8 * [str size].width /* == 7 */]; + [self setTypingAttributes:[NSDictionary dictionaryWithObjectsAndKeys: + style, NSParagraphStyleAttributeName, font, NSFontAttributeName, nil]]; + if ([self respondsToSelector:@selector(setAutomaticTextReplacementEnabled:)]) + [self performSelector:@selector(setAutomaticTextReplacementEnabled:) + withObject:(NSObject *) NO]; +} + + +@end diff --git a/ASR33/ASR33WindowController.h b/ASR33/ASR33WindowController.h new file mode 100644 index 0000000..3938059 --- /dev/null +++ b/ASR33/ASR33WindowController.h @@ -0,0 +1,46 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33WindowController.h - ASR 33 Teletype Window Controller + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class ASR33, PaperTapeController, ASR33TextView, RegisterFormCell, KeepInMenuWindow; + + +@interface ASR33WindowController : NSObject +{ +@private + IBOutlet ASR33 *asr33; + IBOutlet KeepInMenuWindow *window; + IBOutlet NSView *ttyToolbarView; + IBOutlet NSView *readerToolbarView; + IBOutlet NSView *punchToolbarView; + IBOutlet NSSegmentedControl *localOnline; + IBOutlet RegisterFormCell *kbb; + IBOutlet RegisterFormCell *tto; + IBOutlet PaperTapeController *readerController; + IBOutlet PaperTapeController *punchController; +} + +- (IBAction) localOnlineClicked:(id)sender; +- (void) setWindowTitle:(NSString *)title; + +@end diff --git a/ASR33/ASR33WindowController.m b/ASR33/ASR33WindowController.m new file mode 100644 index 0000000..a38be8d --- /dev/null +++ b/ASR33/ASR33WindowController.m @@ -0,0 +1,242 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33WindowController.h - ASR 33 Teletype Window Controller + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/KeepInMenuWindow.h" +#import "PluginFramework/Utilities.h" +#import "PluginFramework/InputConsumerProtocol.h" +#import "PluginFramework/RegisterFormCell.h" + +#import "ASR33WindowController.h" +#import "ASR33.h" + + +@implementation ASR33WindowController + + +#define TTY_TOOLBAR_ITEM_IDENTIFIER @"ttyTBItemIdentifier" +#define READER_TOOLBAR_ITEM_IDENTIFIER @"readerTBItemIdentifier" +#define PUNCH_TOOLBAR_ITEM_IDENTIFIER @"punchTBItemIdentifier" + + +#pragma mark Toolbar + + +- (void) setupToolbar +{ + NSToolbar *toolbar = [[[NSToolbar alloc] initWithIdentifier:@"ASR33WindowToolbar"] autorelease]; + [toolbar setAllowsUserCustomization:NO]; + [toolbar setAutosavesConfiguration:YES]; + [toolbar setDisplayMode:NSToolbarDisplayModeIconAndLabel]; + [toolbar setSizeMode:NSToolbarSizeModeDefault]; + [toolbar setDelegate:self]; + [window setToolbar:toolbar]; + [window setShowsToolbarButton:YES]; + adjustToolbarControlForTiger ([kbb controlView]); + adjustToolbarControlForTiger ([tto controlView]); +} + + +- (NSToolbarItem *) toolbar:(NSToolbar *)toolbar itemForItemIdentifier:(NSString *)itemIdent + willBeInsertedIntoToolbar:(BOOL)willBeInserted +{ + NSRect rect; + + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + NSToolbarItem *toolbarItem = [[[NSToolbarItem alloc] initWithItemIdentifier:itemIdent] autorelease]; + + if ([itemIdent isEqual:TTY_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedStringFromTableInBundle( + @"ASR 33 Teletype", nil, bundle, @"")]; + [toolbarItem setPaletteLabel:NSLocalizedStringFromTableInBundle( + @"ASR 33 Teletype", nil, bundle, @"")]; + [toolbarItem setToolTip:NSLocalizedStringFromTableInBundle( + @"This area contains the registers and switches of the ASR 33 teletype", + nil, bundle, @"")]; + [toolbarItem setView:ttyToolbarView]; + rect = [ttyToolbarView frame]; + [toolbarItem setMinSize:NSMakeSize(NSWidth(rect), NSHeight(rect))]; + [toolbarItem setMaxSize:NSMakeSize(NSWidth(rect), NSHeight(rect))]; + } else if ([itemIdent isEqual:READER_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedStringFromTableInBundle( + @"Low Speed Paper Tape Reader", nil, bundle, @"")]; + [toolbarItem setPaletteLabel:NSLocalizedStringFromTableInBundle( + @"Low Speed Paper Tape Reader", nil, bundle, @"")]; + [toolbarItem setToolTip:NSLocalizedStringFromTableInBundle( + @"This area displays the state of the low speed paper tape reader", + nil, bundle, @"")]; + [toolbarItem setView:readerToolbarView]; + rect = [readerToolbarView frame]; + [toolbarItem setMinSize:NSMakeSize(NSWidth(rect), NSHeight(rect))]; + [toolbarItem setMaxSize:NSMakeSize(NSWidth(rect), NSHeight(rect))]; + } else if ([itemIdent isEqual:PUNCH_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedStringFromTableInBundle( + @"Low Speed Paper Tape Punch", nil, bundle, @"")]; + [toolbarItem setPaletteLabel:NSLocalizedStringFromTableInBundle( + @"Low Speed Paper Tape Punch", nil, bundle, @"")]; + [toolbarItem setToolTip:NSLocalizedStringFromTableInBundle( + @"This area displays the state of the low speed paper tape punch", + nil, bundle, @"")]; + [toolbarItem setView:punchToolbarView]; + rect = [punchToolbarView frame]; + [toolbarItem setMinSize:NSMakeSize(NSWidth(rect), NSHeight(rect))]; + [toolbarItem setMaxSize:NSMakeSize(NSWidth(rect), NSHeight(rect))]; + } else + toolbarItem = nil; + return toolbarItem; +} + + +- (NSArray *) toolbarDefaultItemIdentifiers:(NSToolbar *)toolbar +{ + return [NSArray arrayWithObjects: + TTY_TOOLBAR_ITEM_IDENTIFIER, NSToolbarSeparatorItemIdentifier, + READER_TOOLBAR_ITEM_IDENTIFIER, NSToolbarSeparatorItemIdentifier, + PUNCH_TOOLBAR_ITEM_IDENTIFIER, + nil]; +} + + +- (NSArray *) toolbarAllowedItemIdentifiers:(NSToolbar *)toolbar +{ + return [NSArray arrayWithObjects: + TTY_TOOLBAR_ITEM_IDENTIFIER, READER_TOOLBAR_ITEM_IDENTIFIER, + PUNCH_TOOLBAR_ITEM_IDENTIFIER, NSToolbarSeparatorItemIdentifier, + nil]; +} + + +- (void) windowDidBecomeMain:(NSNotification *)notification +{ + if (runningOnLionOrNewer()) { + [kbb setEnabled:YES]; + [tto setEnabled:YES]; + [readerController setEnabled:YES]; + [punchController setEnabled:YES]; + } +} + + +- (void) windowDidResignMain:(NSNotification *)notification +{ + if (runningOnLionOrNewer()) { + [kbb setEnabled:NO]; + [tto setEnabled:NO]; + [readerController setEnabled:NO]; + [punchController setEnabled:NO]; + } +} + + +#pragma mark Notifications + + +- (void) windowWillBeginSheet:(NSNotification *)notification +{ + [localOnline setEnabled:NO]; + [kbb setEnabled:NO]; + [tto setEnabled:NO]; + [readerController setEnabled:NO]; + [punchController setEnabled:NO]; +} + + +- (void) windowDidEndSheet:(NSNotification *)notification; +{ + [localOnline setEnabled:YES]; + [kbb setEnabled:YES]; + [tto setEnabled:YES]; + [readerController setEnabled:YES]; + [punchController setEnabled:YES]; +} + + +- (void) notifyPluginsLoaded:(NSNotification *)notification +{ + [self windowDidResignMain:notification]; + [window orderBackFromDefaults:self]; +} + + +- (void) setupNotifications +{ + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + [defaultCenter addObserver:self + selector:@selector(notifyOnlineChanged:) name:TTY_ONLINE_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyPluginsLoaded:) + name:PLUGINS_LOADED_NOTIFICATION object:nil]; +} + + +#pragma mark Controls + + +- (IBAction) localOnlineClicked:(id)sender +{ + [asr33 setOnline:[sender selectedSegment]]; +} + + +- (void) notifyOnlineChanged:(NSNotification *)notification +{ + [localOnline setSelectedSegment:[asr33 getOnline]]; +} + + +#pragma mark Initialization + + +- (void) setWindowTitle:(NSString *)title +{ + BOOL isAuxTTY = ! [[window title] isEqualToString:title]; + NSRect oldFrame = [window frame]; + [window setTitle:title]; + [window setFrameAutosaveName:title]; + /* this is a hack to move the AuxTTY window away from the exact position of the ConTTY when the + simulator starts for the first time without existing preferences file */ + if (isAuxTTY && NSEqualRects(oldFrame, [window frame])) + [window setFrameOrigin:NSMakePoint(oldFrame.origin.x + 20, oldFrame.origin.y - 20)]; +} + + +- (void) setupRegisters +{ + [kbb setupRegisterFor:asr33 getRegisterValue:@selector(getKBB) setRegisterValue:@selector(setKBB:) + changedNotificationName:KBB_CHANGED_NOTIFICATION mask:0377 base:8]; + [tto setupRegisterFor:asr33 getRegisterValue:@selector(getTTO) setRegisterValue:@selector(setTTO:) + changedNotificationName:TTO_CHANGED_NOTIFICATION mask:0377 base:8]; +} + + +- (void) awakeFromNib +{ + [self setupToolbar]; + [self setupNotifications]; + [self setupRegisters]; +} + + +@end diff --git a/ASR33/ASR33iot.c b/ASR33/ASR33iot.c new file mode 100644 index 0000000..cab8f3b --- /dev/null +++ b/ASR33/ASR33iot.c @@ -0,0 +1,151 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33iot.c - ASR 33 Teletype IOTs + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#define USE_ASR33_REGISTERS_DIRECTLY 1 +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" +#import "PluginFramework/InputConsumerProtocol.h" + +#import "ASR33iot.h" +#import "ASR33.h" + + +void i6030 (void) /* KCF 6030 */ +{ + pdp8->IOFLAGS &= ~PLUGIN_POINTER(ASR33)->inflag; + EXECUTION_TIME (12); +} + + +void i6031 (void) /* KSF 6031 */ +{ + if (pdp8->IOFLAGS & PLUGIN_POINTER(ASR33)->inflag) + pdp8->PC++; + EXECUTION_TIME (12); +} + + +unsigned s6031 (void) /* KSF 6031 stiptest */ +{ + return pdp8->IOFLAGS & PLUGIN_POINTER(ASR33)->inflag; +} + + +void i6032 (void) /* KCC 6032 */ +{ + pdp8->IOFLAGS &= ~PLUGIN_POINTER(ASR33)->inflag; + pdp8->AC &= 010000; + [PLUGIN_POINTER(ASR33) canContinueInput]; + EXECUTION_TIME (12); +} + + +void i6034 (void) /* KRS 6034 */ +{ + pdp8->AC |= PLUGIN_POINTER(ASR33)->KBB; + EXECUTION_TIME (12); +} + + +void i6035 (void) /* KIE 6035 */ +{ + if (pdp8->AC & 1) + pdp8->IMASK |= PLUGIN_POINTER(ASR33)->inflag | PLUGIN_POINTER(ASR33)->outflag; + else + pdp8->IMASK &= ~(PLUGIN_POINTER(ASR33)->inflag | PLUGIN_POINTER(ASR33)->outflag); + EXECUTION_TIME (12); +} + + +void i6036 (void) /* KRB 6036 */ +{ + pdp8->AC = (pdp8->AC & 010000) | PLUGIN_POINTER(ASR33)->KBB; + pdp8->IOFLAGS &= ~PLUGIN_POINTER(ASR33)->inflag; + [PLUGIN_POINTER(ASR33) canContinueInput]; + EXECUTION_TIME (12); +} + + +void i6040 (void) /* TFL 6040 */ +{ + pdp8->IOFLAGS |= PLUGIN_POINTER(ASR33)->outflag; + EXECUTION_TIME (12); +} + + +void i6041 (void) /* TSF 6041 */ +{ + if (pdp8->IOFLAGS & PLUGIN_POINTER(ASR33)->outflag) + pdp8->PC++; + EXECUTION_TIME (12); +} + + +unsigned s6041 (void) /* TSF 6041 skiptest */ +{ + return pdp8->IOFLAGS & PLUGIN_POINTER(ASR33)->outflag; +} + + +void i6042 (void) /* TCF 6042 */ +{ + pdp8->IOFLAGS &= ~PLUGIN_POINTER(ASR33)->outflag; + EXECUTION_TIME (12); +} + + +void i6044 (void) /* TPC 6044 */ +{ + PLUGIN_POINTER(ASR33)->output = (pdp8->AC & 0377); + [PLUGIN_POINTER(ASR33) canContinueOutput]; + EXECUTION_TIME (12); +} + + +void i6045 (void) /* TSK 6045 */ +{ + + if (pdp8->IOFLAGS & pdp8->IMASK & (PLUGIN_POINTER(ASR33)->inflag | PLUGIN_POINTER(ASR33)->outflag)) + pdp8->PC++; + EXECUTION_TIME (12); +} + + +unsigned s6045 (void) /* TSK 6045 skiptest */ +{ + return pdp8->IOFLAGS & pdp8->IMASK & (PLUGIN_POINTER(ASR33)->inflag | PLUGIN_POINTER(ASR33)->outflag); +} + + +void i6046 (void) /* TLS 6046 */ +{ + PLUGIN_POINTER(ASR33)->output = (pdp8->AC & 0377); + pdp8->IOFLAGS &= ~PLUGIN_POINTER(ASR33)->outflag; + [PLUGIN_POINTER(ASR33) canContinueOutput]; + EXECUTION_TIME (12); +} diff --git a/ASR33/ASR33iot.h b/ASR33/ASR33iot.h new file mode 100644 index 0000000..119239c --- /dev/null +++ b/ASR33/ASR33iot.h @@ -0,0 +1,39 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33iot.h - ASR 33 Teletype IOTs + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +extern void i6030 (void); /* KCF 6030 */ +extern void i6031 (void); /* KSF 6031 */ +extern unsigned s6031 (void); /* KSF (skip test) */ +extern void i6032 (void); /* KCC 6032 */ +extern void i6034 (void); /* KRS 6034 */ +extern void i6035 (void); /* KIE 6035 */ +extern void i6036 (void); /* KRB 6036 */ +extern void i6040 (void); /* TFL 6040 */ +extern void i6041 (void); /* TSF 6041 */ +extern unsigned s6041 (void); /* TSF (skip test) */ +extern void i6042 (void); /* TCF 6042 */ +extern void i6044 (void); /* TPC 6044 */ +extern void i6045 (void); /* TSK 6045 */ +extern unsigned s6045 (void); /* TSK (skip test) */ +extern void i6046 (void); /* TLS 6046 */ diff --git a/ASR33/English.lproj/ASR33.nib/designable.nib b/ASR33/English.lproj/ASR33.nib/designable.nib new file mode 100644 index 0000000..5884fcf --- /dev/null +++ b/ASR33/English.lproj/ASR33.nib/designable.nib @@ -0,0 +1,1694 @@ + + + + 1040 + 13E28 + 851 + 1265.21 + 698.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + ASR33 + + + FirstResponder + + + NSApplication + + + 4111 + 2 + {{568, 392}, {562, 360}} + 1618477056 + ASR 33 Console Teletype + KeepInMenuWindow + + View + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + {562, 150} + + + 256 + + + + 274 + + + + 2304 + + + + 2325 + + Apple HTML pasteboard type + Apple PDF pasteboard type + Apple PICT pasteboard type + Apple PNG pasteboard type + Apple URL pasteboard type + CorePasteboardFlavorType 0x6D6F6F76 + CorePasteboardFlavorType 0x75726C20 + NSColor pasteboard type + NSFilenamesPboardType + NSStringPboardType + NeXT Encapsulated PostScript v1.2 pasteboard type + NeXT RTFD pasteboard type + NeXT Rich Text Format v1.0 pasteboard type + NeXT TIFF v4.0 pasteboard type + NeXT font pasteboard type + NeXT ruler pasteboard type + WebURLsWithTitlesPboardType + public.url + + {{0, 15}, {562, 360}} + + + + + + + + + + + + + + 6 + + + + 562 + 1 + + + 33556739 + 0 + + + 3 + MQA + + + + 6 + System + selectedTextBackgroundColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + selectedTextColor + + 3 + MAA + + + + + + + 1 + MCAwIDEAA + + + + + + 0 + + 7 + {10000000, 10000000} + + + + {{1, 1}, {562, 360}} + + + + + + {4, 5} + + 12582912 + + + + + + TU0AKgAAAHCAFUqgBVKsAAAAwdVQUqwaEQeIRGJRGFlYqwWLQ+JxuOQpVRmEx2RROKwOQyOUQSPyaUym +SxqWyKXyeYxyZzWbSuJTScRCbz2Nz+gRKhUOfTqeUai0OSxiWTiBQSHSGFquGwekxyAgAAAOAQAAAwAA +AAEAEAAAAQEAAwAAAAEAEAAAAQIAAwAAAAIACAAIAQMAAwAAAAEABQAAAQYAAwAAAAEAAQAAAREABAAA +AAEAAAAIARIAAwAAAAEAAQAAARUAAwAAAAEAAgAAARYAAwAAAAEAEAAAARcABAAAAAEAAABnARwAAwAA +AAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA + + + + + + 3 + MCAwAA + + + + 4 + + + + 256 + {{548, 1}, {15, 354}} + + NO + + _doScroller: + 0.93723851442337036 + + + + 256 + {{1, 346}, {556, 15}} + + + NO + 1 + + _doScroller: + 0.99454545974731445 + + + {{-1, -1}, {564, 362}} + + + 133170 + + + + 0.25 + 4 + 1 + + + {562, 360} + + + {{0, 0}, {1280, 778}} + {562, 172} + {1.7976931348623157e+308, 1.7976931348623157e+308} + + YES + + + ASR33WindowController + + + + 256 + + + + -2147482368 + {{0, 2}, {182, 12}} + + 16652 + 100 + + + + -2147483392 + {{0, 22}, {182, 19}} + + + YES + + 71303232 + 138545664 + Filename + + LucidaGrande + 11 + 3088 + + + 1 + + 2 + MC44NDcwNTg4OSAwLjg0NzA1ODg5IDAuODQ3MDU4ODkAA + + + 6 + System + controlTextColor + + + + NO + 1 + + + + 256 + {{0, 46}, {62, 20}} + + + YES + + 67108864 + 131072 + + + + + 56 + Load + 2 + + + -1 + 2 + + NO + + + + 256 + {{66, 46}, {120, 20}} + + + YES + + 603979776 + 131072 + + + + + 56.5 + On + 2 + + + 56.5 + Off + 1 + YES + 2 + + + 1 + + NO + + + {185, 66} + + + NSView + NSResponder + + + + 256 + + + + -2147482368 + {{0, 2}, {182, 12}} + + 16650 + 100 + + + + -2147483392 + {{0, 22}, {182, 19}} + + YES + + 608174144 + 138545664 + Filename + + + YES + 1 + + 6 + System + controlColor + + + + + NO + 1 + + + + 256 + {{0, 46}, {62, 20}} + + 1 + YES + + 67108864 + 131072 + + + + + 56 + Load + 2 + + + -1 + 2 + + NO + + + + 256 + {{66, 46}, {120, 20}} + + YES + + 603979776 + 131072 + + + + + 56.5 + On + 2 + + + 56.5 + Off + 1 + YES + 2 + + + 1 + + NO + + + {185, 66} + + + NSView + + NSResponder + + + + 256 + + + + 258 + {{0, 46}, {127, 20}} + + YES + + 67108864 + 131072 + + + + + 59 + Local + 2 + + + 61 + Online + 1 + 2 + + + -1 + + NO + + + + 256 + + {{-2, 22}, {57, 19}} + + YES + NO + 1 + 1 + + + -1804599231 + 205521920 + 000 + + + 23.83544921875 + + 67108864 + 67108864 + KBB + + + + + + {57, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 23.83544921875 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + LucidaGrande + 13 + 1040 + + + + + 256 + + {{63, 22}, {60, 19}} + + YES + NO + 1 + 1 + + + -1804599231 + 205521920 + 000 + + + 27 + + 67108864 + 67108864 + TTO + + + + + + {60, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 27 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + -2147483380 + {{1, -1}, {121, 17}} + + YES + + 67108864 + 134479872 + Flush Typeahead Buffer + + LucidaGrande + 9 + 3600 + + + -2036580352 + 45 + + 549650432 + {1, 1} + + + + + + TU0AKgAAAAoAAAANAQAAAwAAAAEAAQAAAQEAAwAAAAEAAQAAAQIAAwAAAAIACAAIAQMAAwAAAAEAAQAA +AQYAAwAAAAEAAQAAAREABAAAAAEAAAAIARIAAwAAAAEAAQAAARUAAwAAAAEAAgAAARYAAwAAAAEAAQAA +ARcABAAAAAEAAAACARwAAwAAAAEAAQAAAVIAAwAAAAEAAQAAAVMAAwAAAAIAAQABAAAAAA + + + + + + + + + 400 + 75 + + NO + + + {126, 66} + + + NSView + + NSResponder + + + PaperTapeController + + + PaperTapeController + + + TypeaheadBuffer + + + + + + + window + + + + 20 + + + + localOnline + + + + 83 + + + + kbb + + + + 84 + + + + tto + + + + 85 + + + + asr33 + + + + 106 + + + + localOnlineClicked: + + + + 107 + + + + readerToolbarView + + + + 108 + + + + punchToolbarView + + + + 109 + + + + ttyToolbarView + + + + 110 + + + + readerController + + + + 115 + + + + punchController + + + + 116 + + + + loadUnloadClicked: + + + + 127 + + + + onOffClicked: + + + + 128 + + + + loadUnloadClicked: + + + + 129 + + + + onOffClicked: + + + + 130 + + + + loadUnloadButton + + + + 133 + + + + onOffButton + + + + 134 + + + + progressIndicator + + + + 135 + + + + filenameField + + + + 136 + + + + loadUnloadButton + + + + 137 + + + + onOffButton + + + + 138 + + + + filenameField + + + + 139 + + + + progressIndicator + + + + 140 + + + + reader + + + + 144 + + + + punch + + + + 145 + + + + textview + + + + 264 + + + + delegate + + + + 329 + + + + windowController + + + + 347 + + + + flushTypeaheadBufferButton + + + + 350 + + + + typeaheadBuffer + + + + 390 + + + + typeaheadBuffer + + + + 392 + + + + inputConsumer + + + + 418 + + + + inputConsumer + + + + 419 + + + + inputConsumer + + + + 420 + + + + flush: + + + + 460 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 5 + + + + + + ASR33Window + + + 6 + + + + + + + + 247 + + + + + + + + + + 250 + + + + + 18 + + + ASR33WindowController + + + 49 + + + + + + + + + Reader + + + 52 + + + + + 56 + + + + + + + + 59 + + + + + + + + 60 + + + + + + + + 61 + + + + + + + + + Punch + + + 62 + + + + + + + + 63 + + + + + + + + 64 + + + + + + + + 65 + + + + + 66 + + + + + + + + + TTY + + + 68 + + + + + + + + 71 + + + + + + + + + 74 + + + + + 75 + + + + + + + + + 76 + + + + + 342 + + + + + + + + 112 + + + ReaderController + + + 113 + + + PunchController + + + 349 + + + TypeaheadBuffer + + + 475 + + + + + 476 + + + + + 477 + + + + + 478 + + + + + 479 + + + + + 480 + + + + + 481 + + + + + 482 + + + + + 483 + + + + + 484 + + + + + 485 + + + + + 486 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + ASR33TextView + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Click here to discard buffered input, e. g. after accidentally pasting a large amount of text. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{42, 633}, {185, 66}} + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + {{91, 133}, {562, 360}} + + {562, 150} + PaperTapeProgressIndicator + + ToolTip + + ToolTip + + Progress indicator for the paper tape reader + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Filename of the paper tape currently loaded into the reader + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + TG9hZHMgb3IgdW5sb2FkcyBhIHBhcGVyIHRhcGUgZm9yIHRoZSByZWFkZXIuCgpZb3UgYWxzbyBjYW4g +ZHJhZyBmaWxlcyBmcm9tIHRoZSBGaW5kZXIgdG8gdGhpcyBidXR0b24gdG8gbG9hZCB0aGVtLg + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Turns the paper tape reader on or off + + + com.apple.InterfaceBuilder.CocoaPlugin + {{259, 677}, {185, 66}} + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + TG9hZHMgb3IgdW5sb2FkcyBhIHBhcGVyIHRhcGUgZm9yIHRoZSBwdW5jaC4KCllvdSBhbHNvIGNhbiBk +cmFnIGZpbGVzIGZyb20gdGhlIEZpbmRlciB0byB0aGlzIGJ1dHRvbiB0byBsb2FkIHRoZW0uA + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Turns the paper tape punch on or off + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Filename of the paper tape currently loaded into the punch + + + com.apple.InterfaceBuilder.CocoaPlugin + PaperTapeProgressIndicator + + ToolTip + + ToolTip + + Progress indicator for the paper tape punch + + + com.apple.InterfaceBuilder.CocoaPlugin + {{579, 569}, {126, 66}} + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Toggles between local and online mode of the ASR 33. When the TTY is online, keystrokes or characters read from the tape are not printed or punched, but their ASCII value is loaded into KBB. When the TTY runs locally, keystrokes or characters read from the tape are printed or punched; KBB, TTO and the I/O flags are not affected. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + When the TTY in online, KBB (Keyboard Buffer) receives the characters typed at the keyboard or read from the paper tape. After putting a new value into KBB, the TTY raises its input flag. + + + com.apple.InterfaceBuilder.CocoaPlugin + RegisterFormCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + When the CPU initializes an output operation by loading a value from AC into TTO (Teletype Output Buffer), the TTY prints or punches the character and raises then its output flag. + + + com.apple.InterfaceBuilder.CocoaPlugin + RegisterFormCell + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + 489 + + + + + ASR33 + PDP8Plugin + + PaperTapeController + PaperTapeController + ASR33TextView + TypeaheadBuffer + ASR33WindowController + + + + punch + PaperTapeController + + + reader + PaperTapeController + + + textview + ASR33TextView + + + typeaheadBuffer + TypeaheadBuffer + + + windowController + ASR33WindowController + + + + IBProjectSource + ASR33/ASR33.h + + + + ASR33TextView + NSTextView + + typeaheadBuffer + TypeaheadBuffer + + + typeaheadBuffer + + typeaheadBuffer + TypeaheadBuffer + + + + IBProjectSource + ASR33/ASR33TextView.h + + + + ASR33WindowController + NSObject + + localOnlineClicked: + id + + + localOnlineClicked: + + localOnlineClicked: + id + + + + ASR33 + RegisterFormCell + NSSegmentedControl + PaperTapeController + NSView + PaperTapeController + NSView + RegisterFormCell + NSView + KeepInMenuWindow + + + + asr33 + ASR33 + + + kbb + RegisterFormCell + + + localOnline + NSSegmentedControl + + + punchController + PaperTapeController + + + punchToolbarView + NSView + + + readerController + PaperTapeController + + + readerToolbarView + NSView + + + tto + RegisterFormCell + + + ttyToolbarView + NSView + + + window + KeepInMenuWindow + + + + IBProjectSource + ASR33/ASR33WindowController.h + + + + FirstResponder + NSObject + + : + id + + + : + + : + id + + + + IBUserSource + + + + + KeepInMenuWindow + NSWindow + + id + id + + + + orderBackFromDefaults: + id + + + orderFrontFromDefaults: + id + + + + IBProjectSource + Utilities/KeepInMenuWindow.h + + + + NSControl + + IBProjectSource + Categories/NSControl+FileDrop.h + + + + PDP8Plugin + NSObject + + IBProjectSource + Plugins/PluginAPI.h + + + + PaperTapeController + NSObject + + id + id + + + + loadUnloadClicked: + id + + + onOffClicked: + id + + + + NSTextField + id + NSSegmentedControl + NSSegmentedControl + PaperTapeProgressIndicator + + + + filenameField + NSTextField + + + inputConsumer + id + + + loadUnloadButton + NSSegmentedControl + + + onOffButton + NSSegmentedControl + + + progressIndicator + PaperTapeProgressIndicator + + + + IBProjectSource + ASR33/PaperTapeController.h + + + + PaperTapeProgressIndicator + NSProgressIndicator + + IBProjectSource + ASR33/PaperTapeProgressIndicator.h + + + + RegisterFormCell + NSFormCell + + registerOwner + id + + + registerOwner + + registerOwner + id + + + + IBProjectSource + Utilities/RegisterFormCell.h + + + + TypeaheadBuffer + NSObject + + flush: + id + + + flush: + + flush: + id + + + + NSButton + id + + + + flushTypeaheadBufferButton + NSButton + + + inputConsumer + id + + + + IBProjectSource + ASR33/TypeaheadBuffer.h + + + + + + KeepInMenuWindow + NSWindow + + IBFrameworkSource + PluginFramework.framework/Headers/KeepInMenuWindow.h + + + + NSControl + + IBFrameworkSource + PluginFramework.framework/Headers/NSControl+FileDrop.h + + + + PDP8Plugin + NSObject + + IBFrameworkSource + PluginFramework.framework/Headers/PluginAPI.h + + + + RegisterFormCell + NSFormCell + + IBFrameworkSource + PluginFramework.framework/Headers/RegisterFormCell.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../../pdp8e-simulator.xcodeproj + 3 + + diff --git a/ASR33/English.lproj/ASR33.nib/keyedobjects.nib b/ASR33/English.lproj/ASR33.nib/keyedobjects.nib new file mode 100644 index 0000000..eeed418 Binary files /dev/null and b/ASR33/English.lproj/ASR33.nib/keyedobjects.nib differ diff --git a/ASR33/English.lproj/ASR33OnlineHelp/index.html b/ASR33/English.lproj/ASR33OnlineHelp/index.html new file mode 100644 index 0000000..c809b70 --- /dev/null +++ b/ASR33/English.lproj/ASR33OnlineHelp/index.html @@ -0,0 +1,307 @@ + + + + + + ASR 33 Teletype Help + + + + + + + +

ASR 33 Teletype Help

+ +

+The ASR 33 Teletype can operate under program control or independent of the PDP-8 unter manual +control. When operated in manual mode, characters typed at the keyboard are printed by the type +writer of the teletype. When additionally the paper tape punch is turned on, the typed +characters are punched on the papter tape, too. When a paper tape is loaded into the reader and +the reader is turned on, the teletype ignores the keyboard input and reads characters to print +or punch from the reader paper tape. +

+ +

+When the teletype is used in online mode, characters typed at the keyboard or read from the reader paper +tape are not printed or punched, but their ASCII value is transferred into the keyboard buffer register +KBB, from where the PDP-8 can read it into the accumulator AC. The PDP-8 then can use teletype output +IOTs to write the character to the teletype output buffer register TTO to initiate the printing or +punching of the character. +

+ +

+The teletypes of the PDP-8/E Simulator have the following improvements compared to hardware ASR 33 +Teletypes: +

+ +

    +
  • +Backspace handling: When the teletype is operated in local mode, typing the backspace key causes the +last character to be removed from the output display and — when the punch is turned on — +from the punch paper tape. The Macintosh clear key (at the top left of the numeric key pad or fn-6 on +notebook keyboards) has the function of the ASR 33 rubout key. +
  • +
  • +Tabulator handling: The teletype handles the output of tabulator characters with tabulator stops at every +8th column. (Tab characters are punched to paper tapes unaltered.) +
  • +
  • +Speed: The simulated teletype can run with the speed of a hardware ASR 33 teletype (about ten characters +per second) or as fast as possible. Use the ASR 33 preference pane to change the speed of the teletype. +
  • +
  • +High bit masking for the punch: When this feature is enabled (in the ASR 33 preference pane), the paper +tape punch masks the most significant bit of the punched characters. This is useful when you run PDP-8 +software that use the 8th bit as a checksum and save the output to a paper tape. When the MSB is +masked out, you can open and read the paper tape file with any Mac text editor. (When punching BIN or +RIM format paper tapes, you normally won't have to disable the MSB masking because these formats use +the 8th bit only for punching leaders or trailers, which are not needed with paper tapes stored in +files. One exception: BIN format with field settings uses values 3x0 (x=0,…,7) to signal that +the following code is to be loaded to memory field x.) +
  • +
  • +“Copy & Paste” and “Drag & Drop” is supported for the teletype: +When you paste text into the teletype window, the text is inserted into a typeahead buffer +from where the teletype reads it sccessively as if the characters were typed at the keyboard. +New keyboard input is appended at the end of the typeahead buffer. While the typeahead buffer is not +empty, a button “Flush Typeahead Buffer” appears in the toolbar of the ASR 33 window that +you can use to clear the buffer prematurely. +
  • +
+ +

Console Teletype

+ +

+The console teletype uses I/O address 03 for the keyboard and reader and 04 for the printer +and punch and supports the following IOTs: +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Mnemonic
Symbol
Octal
Code

Description
KCF6030 + Clear the keyboard/reader I/O flag (“Console TTY In” in the CPU window). + Do not start the reader to read the next tape character. +
KSF6031 + Skip the next instruction when the keyboard/reader I/O flag is raised, i. e. a new + character is loaded into the keyboard buffer register KBB. +
KCC6032 + Clear AC and the keyboard/reader I/O flag. When the paper tape reader is turned on, + start to read the next character from the tape. When a new value is loaded into KBB + (from the tape or — when the reader is turned off — because the user + typed a key), the flag is raised again. +
KRS6034 + Transfer KBB into AC(4–11) by performing a logical OR (“static” read). +
KIE6035 + Load the keyboard/reader and printer/punch interrupt enable flag from AC(11) to enable + or disable teletype interrupts. +
KRB6036 + Clear AC and the keyboard/reader I/O flag, then read KBB into AC(4–11). + Microprogrammed combination of KCC and KRS. +
TFL6040 + Set the printer/punch I/O flag (“Console TTY Out” in the CPU window). +
TSF6041 + Skip the next instruction when the printer/punch I/O flag is set. +
TCF6042 + Clear the printer/punch I/O flag. +
TPC6044 + Load the teletype output buffer register TTO with the contents of AC(4–11) and + start to print and, when the punch is turned on, to punch the character from TTO. + When the output is completed, the printer/punch I/O flag is raised. +
TSK6045 + Skip the next instruction when an interrupt was caused by the teletype, i. e. when + the interrupt mask flag for input or output and the corresponding I/O flag are both set. +
TLS6046 + Clear the printer/punch I/O flag, load TTO from AC(4–11) and start the output. + When the output is completed, the printer/punch I/O flag is raised again. + Microprogrammed combination of TCF and TPC. +
+ +

Remark

+ +

+Earlier PDP-8 models (PDP-8, -8/S, -8/I, -8/L) do not support the IOTs KCF (6030), KIE (6035), +TFL (6040), and TSK (6045). +

+ +

Auxiliary Teletype

+ +

+The PDP-8/E Simulator includes an Auxiliary Teletype that you can activate in the Finder information +window for the PDP-8/E Simulator application in the area “Plug-ins”. (With Mac OS X 10.6 +“Snow Leopard”, Apple has removed the Plug-ins section from the Finder information window, +and you must open the application package manually and move the Auxiliary Teletype from the folder +“Contents/PlugIns Disabled” to “Contents/PlugIns”.) +

+ +

+In the CPU window, +the flags for the Auxiliary Teletype are called “Auxiliary TTY In” and +“Auxiliary TTY Out”. It uses the I/O addressed 40 for input and 41 for output and +supports the following IOTs: +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Mnemonic
Symbol
Octal
Code
Corresponding
Console Teletype IOT
AKCF6400KCF (6030)
AKSF6401KSF (6031)
AKCC6402KCC (6032)
AKRS6404KRS (6034)
AKIE6405KIE (6035)
AKRB6406KRB (6036)
ATFL6410TFL (6040)
ATSF6411TSF (6041)
ATCF6412TCF (6042)
ATPC6414TPC (6044)
ATSK6415TSK (6045)
ATLS6416TLS (6046)
+ +

Additional Teletypes

+ +

+When you need additional teletypes, you can duplicate the Console or Auxiliary Teletype plugin and +then modify the property list that describes the I/O addresses and IOTs for the plugin. You find +this property list inside the plugin package at Contents/Resources/English.lproj/auxtty-io-info.plist. +

+ + + \ No newline at end of file diff --git a/ASR33/English.lproj/ASR33OnlineHelp/pdp8e.png b/ASR33/English.lproj/ASR33OnlineHelp/pdp8e.png new file mode 100644 index 0000000..2c0c485 Binary files /dev/null and b/ASR33/English.lproj/ASR33OnlineHelp/pdp8e.png differ diff --git a/ASR33/English.lproj/ASR33OnlineHelp/styles.css b/ASR33/English.lproj/ASR33OnlineHelp/styles.css new file mode 100644 index 0000000..c18751d --- /dev/null +++ b/ASR33/English.lproj/ASR33OnlineHelp/styles.css @@ -0,0 +1,239 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * styles.css - Online help - Style sheet + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +p { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +p.small { + font-size: 8pt; +} + +a { + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +a:hover { + text-decoration: underline +} + +ul { + margin-left: 1.25em; padding-left: 0em; +} + +li { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +#mainbox { + background-color: #fff; + margin-top: 30px; + margin-right: 26px; + margin-left: 18px; + position: absolute; + top: 10px +} + +#taskbox { + background-color: #eee; + list-style-type: decimal; + list-style-position: outside; + margin-top: 12px; + margin-bottom: 12px; + border: solid 1px #444 +} + +h1 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 6pt; +} + +h2 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 8pt; +} + +h3 { + font-size: 10pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 5pt; +} + +h4 { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 4pt; +} + +/* index.html */ + +table.index { + padding-top: 20px; + width: 100%; +} + +td.banner { + padding: 20px; +} + +td.toc { + padding-top: 10px; + padding-bottom: 10px; + padding-left: 20px; + padding-right:20px; + border-left: 1px solid darkgray; +} + +p.toc { + line-height: 40px; +} + +/* other pages */ + +table { + border-collapse: separate; + border-spacing: 0px; +} + +th { + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + font-style: bold; + border-bottom: 1px solid gray; + padding-left: 10px; + padding-right: 10px; +} + +th.left { + text-align: left; +} + +td { + text-align: center; + vertical-align: top; + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + padding-left: 10px; + padding-right: 10px; +} + +td.left { + text-align: left; +} + +td.right { + text-align: right; +} + +td.br { + border-right: 1px solid gray; +} + +td.bb { + border-bottom: 1px solid lightgray; +} + +td.bb_left { + text-align: left; + border-bottom: 1px solid lightgray; +} + +td.bbr { + border-bottom: 1px solid lightgray; + border-right: 1px solid gray; +} + +td.opcode { + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_right { + text-align: right; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_left { + text-align: left; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-left: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + border-right: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} diff --git a/ASR33/English.lproj/InfoPlist.strings b/ASR33/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..0eedff6 --- /dev/null +++ b/ASR33/English.lproj/InfoPlist.strings @@ -0,0 +1,28 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InfoPlist.strings - Localized strings for Info.plist + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +CFBundleName = "ASR 33 Teletype"; +CFBundleGetInfoString = "ASR 33 Teletype 2.0.2, Copyright © 1994-2015 Bernhard Baehr"; +NSHumanReadableCopyright = "Copyright © 1994-2015 Bernhard Baehr"; +CFBundleHelpBookName = "ASR 33 Teletype Help"; \ No newline at end of file diff --git a/ASR33/English.lproj/auxtty-io-info.plist b/ASR33/English.lproj/auxtty-io-info.plist new file mode 100644 index 0000000..0b86e48 --- /dev/null +++ b/ASR33/English.lproj/auxtty-io-info.plist @@ -0,0 +1,59 @@ + + + + + + ioflags + + Auxiliary TTY In + Auxiliary TTY Out + + ioaddresses + + 40 + 41 + + iots + + + AKCF + AKSF + AKCC + + AKRS + AKIE + AKRB + + + ATFL + ATSF + ATCF + + ATPC + ATSK + ATLS + + + + diff --git a/ASR33/English.lproj/io-info.plist b/ASR33/English.lproj/io-info.plist new file mode 100644 index 0000000..92af7f2 --- /dev/null +++ b/ASR33/English.lproj/io-info.plist @@ -0,0 +1,59 @@ + + + + + + ioflags + + Console TTY In + Console TTY Out + + ioaddresses + + 3 + 4 + + iots + + + KCF + KSF + KCC + + KRS + KIE + KRB + + + TFL + TSF + TCF + + TPC + TSK + TLS + + + + diff --git a/ASR33/Info.plist b/ASR33/Info.plist new file mode 100644 index 0000000..770ac76 --- /dev/null +++ b/ASR33/Info.plist @@ -0,0 +1,32 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleHelpBookFolder + ASR33OnlineHelp + CFBundleHelpBookName + ASR 33 Teletype Help + CFBundleIconFile + + CFBundleIdentifier + de.bernhard-baehr.pdp8e.ASR33 + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + ${PRODUCT_NAME} + CFBundlePackageType + BNDL + CFBundleShortVersionString + 2.0.2 + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + NSPrincipalClass + ASR33 + + diff --git a/ASR33/SpeakerLoud.png b/ASR33/SpeakerLoud.png new file mode 100644 index 0000000..3cce1a5 Binary files /dev/null and b/ASR33/SpeakerLoud.png differ diff --git a/ASR33/SpeakerQuiet.png b/ASR33/SpeakerQuiet.png new file mode 100644 index 0000000..41ecdce Binary files /dev/null and b/ASR33/SpeakerQuiet.png differ diff --git a/ASR33/TypeaheadBuffer.h b/ASR33/TypeaheadBuffer.h new file mode 100644 index 0000000..b8181b5 --- /dev/null +++ b/ASR33/TypeaheadBuffer.h @@ -0,0 +1,41 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * TypeaheadBuffer.h - Typeahead buffer for a keyboard input device + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@protocol InputConsumer; + + +@interface TypeaheadBuffer : NSObject { +@private + IBOutlet id inputConsumer; + IBOutlet NSButton *flushTypeaheadBufferButton; + NSMutableString *typeaheadBuffer; +} + +- (IBAction) flush:(id)sender; + +- (BOOL) hasCharacters; +- (signed short) getNextChar; +- (void) typeahead:(NSString *)string; + +@end diff --git a/ASR33/TypeaheadBuffer.m b/ASR33/TypeaheadBuffer.m new file mode 100644 index 0000000..fb3689c --- /dev/null +++ b/ASR33/TypeaheadBuffer.m @@ -0,0 +1,91 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * TypeaheadBuffer.m - Typeahead buffer for a keyboard input device + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/Utilities.h" +#import "PluginFramework/InputConsumerProtocol.h" + +#import "TypeaheadBuffer.h" + + +@implementation TypeaheadBuffer + + +#define MIN_LENGTH_TO_SHOW_FLUSH_TYPEAHEAD_BUTTON 5 + + +- (IBAction) flush:(id)sender +{ + [typeaheadBuffer deleteCharactersInRange:NSMakeRange(0, [typeaheadBuffer length])]; + [flushTypeaheadBufferButton setHidden:YES]; +} + + +- (BOOL) hasCharacters +{ + return [typeaheadBuffer length] > 0; +} + + +- (signed short) getNextChar +{ + signed short c = 0; + int length = [typeaheadBuffer length]; + if (length < MIN_LENGTH_TO_SHOW_FLUSH_TYPEAHEAD_BUTTON) + [flushTypeaheadBufferButton setHidden:YES]; + if (length > 0) { + c = [typeaheadBuffer characterAtIndex:0]; + [typeaheadBuffer deleteCharactersInRange:NSMakeRange(0, 1)]; + } + return c; +} + + +- (void) typeahead:(NSString *)string +{ + int length = [typeaheadBuffer length]; + [typeaheadBuffer appendString:string]; + if ([typeaheadBuffer length] >= MIN_LENGTH_TO_SHOW_FLUSH_TYPEAHEAD_BUTTON) + [flushTypeaheadBufferButton setHidden:NO]; + if (length == 0) + [inputConsumer canContinueInput]; +} + + +- (void) awakeFromNib +{ + if (runningOnTiger()) { + NSPoint p = [flushTypeaheadBufferButton frame].origin; + p.x += 2; p.y += 1; + [flushTypeaheadBufferButton setFrameOrigin:p]; + [flushTypeaheadBufferButton setBezelStyle:NSRoundRectBezelStyle]; + [flushTypeaheadBufferButton setShowsBorderOnlyWhileMouseInside:NO]; + [[flushTypeaheadBufferButton cell] setImagePosition:NSNoImage]; + } + typeaheadBuffer = [[NSMutableString stringWithCapacity:128] retain]; +} + + +@end diff --git a/ASR33/tty-backspace.mp3 b/ASR33/tty-backspace.mp3 new file mode 100644 index 0000000..1c4e904 Binary files /dev/null and b/ASR33/tty-backspace.mp3 differ diff --git a/ASR33/tty-bell.mp3 b/ASR33/tty-bell.mp3 new file mode 100644 index 0000000..ce92e98 Binary files /dev/null and b/ASR33/tty-bell.mp3 differ diff --git a/ASR33/tty-carriage-return.mp3 b/ASR33/tty-carriage-return.mp3 new file mode 100644 index 0000000..2ae3ee0 Binary files /dev/null and b/ASR33/tty-carriage-return.mp3 differ diff --git a/ASR33/tty-keystroke1.mp3 b/ASR33/tty-keystroke1.mp3 new file mode 100644 index 0000000..dcfe98a Binary files /dev/null and b/ASR33/tty-keystroke1.mp3 differ diff --git a/ASR33/tty-keystroke2.mp3 b/ASR33/tty-keystroke2.mp3 new file mode 100644 index 0000000..82af166 Binary files /dev/null and b/ASR33/tty-keystroke2.mp3 differ diff --git a/ASR33/tty-keystroke3.mp3 b/ASR33/tty-keystroke3.mp3 new file mode 100644 index 0000000..bcd351c Binary files /dev/null and b/ASR33/tty-keystroke3.mp3 differ diff --git a/ASR33/tty-keystroke4.mp3 b/ASR33/tty-keystroke4.mp3 new file mode 100644 index 0000000..5fcc2f3 Binary files /dev/null and b/ASR33/tty-keystroke4.mp3 differ diff --git a/ASR33/tty-space.mp3 b/ASR33/tty-space.mp3 new file mode 100644 index 0000000..bb03c4b Binary files /dev/null and b/ASR33/tty-space.mp3 differ diff --git a/ASR33Preferences/ASR33Preferences.h b/ASR33Preferences/ASR33Preferences.h new file mode 100644 index 0000000..70f1042 --- /dev/null +++ b/ASR33Preferences/ASR33Preferences.h @@ -0,0 +1,28 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33Preferences.h - ASR 33 Teletype Preferences Pane + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define ASR33_PREFS_SPEED_KEY @"ASR33RunWith10CharsPerSecond" +#define ASR33_PREFS_MASK_HIGHBIT_KEY @"ASR33MaskPunchedHighBit" +#define ASR33_PREFS_PLAY_SOUND @"ASR33PlaySound" +#define ASR33_PREFS_SOUND_VOLUME @"ASR33SoundVolume" diff --git a/ASR33Preferences/ASR33Preferences.m b/ASR33Preferences/ASR33Preferences.m new file mode 100644 index 0000000..90e6c24 --- /dev/null +++ b/ASR33Preferences/ASR33Preferences.m @@ -0,0 +1,41 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33Preferences.m - ASR 33 Teletype Preferences Pane + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "ASR33Preferences.h" + + +@interface ASR33Preferences : NSPreferencePane +{ +} + +@end + + +@implementation ASR33Preferences + +// empty class, otherwise the preference pane bundle has no loadable code and does not load + +@end diff --git a/ASR33Preferences/English.lproj/ASR33Preferences.nib/designable.nib b/ASR33Preferences/English.lproj/ASR33Preferences.nib/designable.nib new file mode 100644 index 0000000..64deac6 --- /dev/null +++ b/ASR33Preferences/English.lproj/ASR33Preferences.nib/designable.nib @@ -0,0 +1,884 @@ + + + + 1050 + 10D573 + 740 + 1038.29 + 460.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 740 + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + ASR33Preferences + + + FirstResponder + + + NSApplication + + + 15 + 2 + {{123, 459}, {500, 135}} + 1886912512 + ASR33Preferences + + NSWindow + + + View + + {1.79769e+308, 1.79769e+308} + {213, 107} + + + 256 + + + + 261 + + + + 268 + + Apple PDF pasteboard type + Apple PICT pasteboard type + Apple PNG pasteboard type + NSFilenamesPboardType + NeXT Encapsulated PostScript v1.2 pasteboard type + NeXT TIFF v4.0 pasteboard type + + {{436, 25}, {24, 24}} + + YES + + 130560 + 33554432 + + NSImage + SpeakerLoud + + 0 + 0 + 0 + NO + + YES + + + + 268 + + Apple PDF pasteboard type + Apple PICT pasteboard type + Apple PNG pasteboard type + NSFilenamesPboardType + NeXT Encapsulated PostScript v1.2 pasteboard type + NeXT TIFF v4.0 pasteboard type + + {{169, 25}, {24, 24}} + + YES + + 130560 + 33554432 + + NSImage + SpeakerQuiet + + 0 + 0 + 0 + NO + + YES + + + + 268 + {{201, 26}, {227, 21}} + + YES + + -2079981824 + 131072 + + + 1 + 0.0 + 0.5 + 0.0 + 0 + 0 + NO + NO + + + + + 268 + {{18, 28}, {145, 18}} + + YES + + 67239424 + 0 + Play teletype sound + + LucidaGrande + 13 + 1044 + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 268 + {{0, 57}, {251, 38}} + + YES + 2 + 1 + + + -2080244224 + 0 + Run as fast as possible + + + 1211912703 + 0 + + NSRadioButton + + + + 200 + 25 + + + 67239424 + 0 + Run with 10 characters per second + + + 1 + 1211912703 + 0 + + 549453824 + {18, 18} + + + + + + TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAADwRERGLJycnySsrK/A1NTXw +IyMjyRwcHIsJCQk8AAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFFRUVdVBQUOCoqKj/ +29vb//n5+f/6+vr/2tra/6qqqv9UVFTgHx8fdQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUZGRl5 +dXV198PDw//8/Pz////////////////////////////U1NT/fHx89yUlJXkAAAAFAAAAAAAAAAAAAAAA +AAAAAxEREUZqamrmtbW1/+3t7f/+/v7//v7+//7+/v/9/f3//f39//39/f/39/f/xMTE/3d3d+YZGRlG +AAAAAwAAAAAAAAAAAAAACkJCQqGtra3/xsbG/+vr6//y8vL/9fX1//X19f/z8/P/9fX1//Ly8v/u7u7/ +0tLS/6+vr/9KSkqhAAAACgAAAAAAAAAAAAAAF3h4eN2/v7//z8/P/93d3f/q6ur/7+/v/+/v7//w8PD/ +7e3t/+3t7f/i4uL/zs7O/8XFxf98fHzdAAAAFwAAAAAAAAADAAAAJKSkpPjOzs7/2dnZ/+Dg4P/i4uL/ +5eXl/+bm5v/n5+f/5eXl/+Li4v/e3t7/2tra/9DQ0P+srKz4AAAAJAAAAAMAAAADAAAALrCwsPrW1tb/ +3t7e/+Tk5P/p6en/6+vr/+zs7P/p6en/6+vr/+fn5//k5OT/4ODg/9nZ2f+zs7P6AAAALgAAAAMAAAAD +AAAALp2dnezg4OD/5eXl/+rq6v/u7u7/8PDw//Dw8P/x8fH/8PDw/+7u7v/q6ur/5ubm/+Hh4f+ZmZns +AAAALgAAAAMAAAADAAAAJG5ubs/l5eX/6enp/+/v7//y8vL/9vb2//r6+v/5+fn/9/f3//b29v/x8fH/ +6+vr/+Tk5P9ra2vPAAAAJAAAAAMAAAAAAAAAFy4uLpPCwsL67Ozs//Pz8//5+fn//v7+//7+/v/+/v7/ +/v7+//v7+//19fX/8PDw/8LCwvosLCyTAAAAFwAAAAAAAAAAAAAACgAAAENfX1/S5OTk/vn5+f/+/v7/ +///////////////////////////8/Pz/5ubm/l9fX9IAAABDAAAACgAAAAAAAAAAAAAAAwAAABcAAABl +YmJi3NLS0v3////////////////////////////////V1dX9ZGRk3AAAAGUAAAAXAAAAAwAAAAAAAAAA +AAAAAAAAAAUAAAAfAAAAZTMzM8KAgIDwv7+//O3t7f/t7e3/v7+//ICAgPAzMzPCAAAAZQAAAB8AAAAF +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAFwAAAEMAAAB3AAAAnwAAALMAAACzAAAAnwAAAHcAAABD +AAAAFwAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAoAAAAXAAAAJAAAAC4AAAAu +AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgEAAAMAAAABABIAAAEB +AAMAAAABABIAAAECAAMAAAAEAAAFxgEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAFTAAMAAAAEAAAFzodzAAcAAAwYAAAF1gAAAAAACAAIAAgACAABAAEAAQABAAAMGGFw +cGwCAAAAbW50clJHQiBYWVogB9YABAADABMALAASYWNzcEFQUEwAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAPbWAAEAAAAA0y1hcHBsAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAOclhZWgAAASwAAAAUZ1hZWgAAAUAAAAAUYlhZWgAAAVQAAAAUd3RwdAAAAWgAAAAUY2hhZAAA +AXwAAAAsclRSQwAAAagAAAAOZ1RSQwAAAbgAAAAOYlRSQwAAAcgAAAAOdmNndAAAAdgAAAMSbmRpbgAA +BOwAAAY+ZGVzYwAACywAAABkZHNjbQAAC5AAAAAubW1vZAAAC8AAAAAoY3BydAAAC+gAAAAtWFlaIAAA +AAAAAF1KAAA0kQAACCVYWVogAAAAAAAAdCAAALRgAAAjPVhZWiAAAAAAAAAlbAAAFyoAAKfDWFlaIAAA +AAAAAPNSAAEAAAABFs9zZjMyAAAAAAABDEIAAAXe///zJgAAB5IAAP2R///7ov///aMAAAPcAADAbGN1 +cnYAAAAAAAAAAQHNAABjdXJ2AAAAAAAAAAEBzQAAY3VydgAAAAAAAAABAc0AAHZjZ3QAAAAAAAAAAAAD +AQAAAQACBAUGBwkKCw0ODxASExQWFxgaGxweHyAiIyQmJygpKywtLzAxMjM1Njc4OTs8PT5AQUJDREZH +SElKS0xOT1BRUlNUVVZXWFlaW1xdXl9hYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ent8fX5/gIGCg4SF +hoeIiYqLjI2Oj5CRkpOUlZaXmJmam5ydnZ6foKGio6SlpqanqKmqq6ytra6vsLGysrO0tba3uLi5uru8 +vL2+v8DBwcLDxMXGxsfIycrKy8zNzs7P0NHS0tPU1dbW19jZ2drb3Nzd3t/g4eLi4+Tl5ufo6enq6+zt +7u/w8fHy8/T19vf4+fr7/P3+/v8AAgMEBQYHCAkKCwwNDg8QERITFBUWFxgZGhscHR8gISIjJCUnKCkq +Ky0uLzAxMzQ1Njc4OTo7PD0/QEFCQ0RFRkdISUpLTE1OT1BRUlNUVVZXWFlaWltcXV5fYGFiY2RlZmdo +aWprbG1ub3BxcnN0dXZ3d3h5ent8fH1+f4CBgoKDhIWGh4iIiYqLjI2Oj5CRkpOUlJWWl5iZmpucnZ2e +n6ChoqOkpaamp6ipqqusra6vsLCxsrO0tba3uLm5uru8vb6/wMHCw8TFx8jJysvMzc7P0NDR0tPU1dbX +2Nna29ze3+Dh4uPk5ebn6err7O3u7/Hy8/T19vf5+vv8/f7/AAIDAwQFBgcICQoKCwwNDg8QERITFBUW +FxgZGhscHR4fICEiIyQlJicoKSorLC0uLzAxMjM0NTY3ODg5Ojs8PT4+P0BBQkNDREVGR0hJSUpLTE1O +Tk9QUVJSU1RVVVZXWFhZWltbXF1eXl9gYWFiY2RkZWZnZ2hpaWprbGxtbm5vcHFxcnNzdHV1dnd4eHl6 +ent8fH1+fn+AgYGCg4SEhYaHiImJiouMjY6Oj5CRkpOTlJWWl5iZmZqbnJ2en6ChoqOkpaanqKmqq6yt +rq+xsrO0tba3uLq7vL2+wMHDxMbHycrMzs/R0tTW19nb3d7g4uTm6Ors7vDy9Pb4+vz+/wAAbmRpbgAA +AAAAAAY2AACXGgAAVjoAAFPKAACJ3gAAJ8IAABaoAABQDQAAVDkAAiuFAAIZmQABeFEAAwEAAAIAAAAA +AAEABgANABcAIwAxAEAAUgBlAHsAkwCrAMUA4gD/AR8BPwFhAYUBqgHQAfgCIAJLAncCpQLSAwIDMwNl +A5gDzgQFBD0EdQSvBOsFKQVnBacF6AYqBm4GtQb8B0UHkgfkCDkIkAjnCT4JmAn0ClAKrQsLC2sLygwq +DIwM8Q1XDcAOKA6SDv4PbA/bEE0QxBE7EbQSMRKwEzITuRREFNAVYBXxFocXHhfAGGIZBBmsGlQa+RuU +HC4czh1yHhQeux9jIA0gvCFoIhkizyOJJEEk+SW6JnknOygFKMspkypiKzIsASzXLawuhy9gMD4xGzH8 +MtszvzSgNYY2cjdcOEw5OTorOxs8CD0EPfU+6z/nQOFB2ELUQ9VE00XcRttH5EjxSgBLCUwdTTFOUE9v +UI9Rt1LdVAVVNlZsV6VY4FohW21ct135X09goGH0Y0tkqGYFZ19oxGova5ptCG54b/BxbnLsdG119Xd/ +eQh6knwqfcV/W4D4gpSEO4Xih4CJKorYjIqOOY/jkZuTWJUOlsyYiZpSnB6d4Z+soX+jWqUvpxOo+6rj +rMuuwLC4sra0rra0uL+60LzfvwDBHcLdxLXGhchYyi7MCs3lz7rRmtOA1WPXR9kq2xPc/97s4M/iveSn +5o3obupT7ELuLPAM8fLz0PW396H5f/tZ/T3//wAAAAEAAwALABYAJQA3AE0AZQCBAJ8AwQDlAQsBNQFh +AZABwQH1AisCZAKfAtwDHANfA6MD6gQ0BH8EzQT1BR0FcAXEBhsGdAbPBy0HXAeMB+4IUgi4CSAJVAmK +CfYKZArVC0cLgQu8DDIMqw0mDaIOIQ6hDyQPqRAvELgQ/RFDEc8SXRLuE4AUFRSrFUMV3RZ5FxcXthhY +GPwZoRpIGvEbnBxJHPgdqB5bHw8fxSB9ITch8iKwJDAk8yW3Jn4nRigQKNwpqSp5K0osHCzxLccuoC95 +MFUxMzISMvMz1TS5NaA2hzdxOFw5STo4Oyg8Gj4DPvs/9EDuQepD6ETpRexG8Uf3SP9LFEwhTTBOQE9S +UGZSklOrVMVV4Vb/WB5ZP1phW4Vcq13SXvthUmJ/Y69k4GYSZ0dofGm0au1tZG6ib+FxInJlc6l073Y2 +d396FXtjfLJ+A39VgKmB/4NWhK+GCYjCiiGLgYzjjkePrJESknuT5Ja8mCuZm5sMnH+d9J9qoOGiWqPV +pVGmz6eOqE6pzqtRrNSuWq/gsWmy8rR+tgu5Kbq6vE294b93wQ7Cp8RBxd3He8kZyrrLisxbzf/Po9FK +0vHUm9ZF1/HZn9tO3Cbc/96x4GTiGePQ5YjnQegf6Pzquex27jbv9/G583z0X/VC9wj40Pqa/GX+Mf// +AAAAAQADAAsAJQA3AE0AZQCBAJ8AwQELATUBYQGQAcEB9QIrAmQCnwLcAxwDXwOjA+oENAR/BM0FHQVw +BcQGGwZ0Bs8HLQeMB+4IUgi4CSAJign2CmQK1QtHC7wMMgyrDSYNog4hDqEPJA+pEC8QuBFDEl0S7hOA +FBUUqxVDFnkXFxe2GFgY/BpIGvEbnBxJHPgdqB8PH8UgfSE3IfIjbyQwJPMltydGKBAo3Cp5K0osHC3H +LqAveTEzMhIy8zS5NaA2hzhcOUk6ODwaPQ4+Az/0QO5C6EPoROlG8Uf3SglLFEwhTkBPUlF7UpJUxVXh +Vv9ZP1phXKtd0mAlYVJjr2TgZhJofGm0au1tZG6ib+FxInJldO92Nnd/eMl6FXyyfgN/VYCpgf+Er4YJ +h2WIwoohi4GOR4+skRKSe5PklVCWvJgrmZubDJx/nfSfaqDholqj1aVRps+oTqnOq1Gs1K2Xrlqv4LFp +svK0frYLt5m5Kbnxurq8Tb3hv3fBDsHawqfEQcUPxd3He8hKyRnKusuKzFvN/87Rz6PQdtFK0vHTxtSb +1kXXG9fx2MjZn9tO3Cbc/93Y3rHfiuBk4hni9ePQ5KzliOZk50HoH+j86drqueuX7HbtVu427xbv9/DX +8bnymvN89F/1QvYl9wj37PjQ+bX6mvt//GX9S/4x//8AAGRlc2MAAAAAAAAACkNvbG9yIExDRAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAABtbHVjAAAAAAAAAAEAAAAMZW5VUwAAABIAAAAcAEMAbwBsAG8AcgAgAEwAQwBE +AABtbW9kAAAAAAAABhAAAJxOAAAAAL5zkQAAAAAAAAAAAAAAAAAAAAAAdGV4dAAAAABDb3B5cmlnaHQg +QXBwbGUgQ29tcHV0ZXIsIEluYy4sIDIwMDUAAAAAA + + + + + + 3 + MCAwAA + + + + 400 + 75 + + + {251, 18} + {4, 2} + 1151868928 + NSActionCell + + 67239424 + 0 + Radio + + 1211912703 + 0 + + 549453824 + {18, 18} + + + + + + TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAADwRERGLJycnySsrK/A1NTXw +IyMjyRwcHIsJCQk8AAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFFRUVdVBQUOCoqKj/ +29vb//n5+f/6+vr/2tra/6qqqv9UVFTgHx8fdQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUZGRl5 +dXV198PDw//8/Pz////////////////////////////U1NT/fHx89yUlJXkAAAAFAAAAAAAAAAAAAAAA +AAAAAxEREUZqamrmtbW1/+3t7f/+/v7//v7+//7+/v/9/f3//f39//39/f/39/f/xMTE/3d3d+YZGRlG +AAAAAwAAAAAAAAAAAAAACkJCQqGtra3/xsbG/+vr6//y8vL/9fX1//X19f/z8/P/9fX1//Ly8v/u7u7/ +0tLS/6+vr/9KSkqhAAAACgAAAAAAAAAAAAAAF3h4eN2/v7//z8/P/93d3f/q6ur/7+/v/+/v7//w8PD/ +7e3t/+3t7f/i4uL/zs7O/8XFxf98fHzdAAAAFwAAAAAAAAADAAAAJKSkpPjOzs7/2dnZ/+Dg4P/i4uL/ +5eXl/+bm5v/n5+f/5eXl/+Li4v/e3t7/2tra/9DQ0P+srKz4AAAAJAAAAAMAAAADAAAALrCwsPrW1tb/ +3t7e/+Tk5P/p6en/6+vr/+zs7P/p6en/6+vr/+fn5//k5OT/4ODg/9nZ2f+zs7P6AAAALgAAAAMAAAAD +AAAALp2dnezg4OD/5eXl/+rq6v/u7u7/8PDw//Dw8P/x8fH/8PDw/+7u7v/q6ur/5ubm/+Hh4f+ZmZns +AAAALgAAAAMAAAADAAAAJG5ubs/l5eX/6enp/+/v7//y8vL/9vb2//r6+v/5+fn/9/f3//b29v/x8fH/ +6+vr/+Tk5P9ra2vPAAAAJAAAAAMAAAAAAAAAFy4uLpPCwsL67Ozs//Pz8//5+fn//v7+//7+/v/+/v7/ +/v7+//v7+//19fX/8PDw/8LCwvosLCyTAAAAFwAAAAAAAAAAAAAACgAAAENfX1/S5OTk/vn5+f/+/v7/ +///////////////////////////8/Pz/5ubm/l9fX9IAAABDAAAACgAAAAAAAAAAAAAAAwAAABcAAABl +YmJi3NLS0v3////////////////////////////////V1dX9ZGRk3AAAAGUAAAAXAAAAAwAAAAAAAAAA +AAAAAAAAAAUAAAAfAAAAZTMzM8KAgIDwv7+//O3t7f/t7e3/v7+//ICAgPAzMzPCAAAAZQAAAB8AAAAF +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAFwAAAEMAAAB3AAAAnwAAALMAAACzAAAAnwAAAHcAAABD +AAAAFwAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAoAAAAXAAAAJAAAAC4AAAAu +AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADQEAAAMAAAABABIAAAEB +AAMAAAABABIAAAECAAMAAAAEAAAFugEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAFTAAMAAAAEAAAFwgAAAAAACAAIAAgACAABAAEAAQABA + + + + + + + + 400 + 75 + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 3 + MQA + + + + + + 256 + {{0, -1}, {253, 18}} + + YES + + 67239424 + 0 + Mask high bit of punched characters + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{20, 20}, {460, 95}} + + NSView + NSResponder + + + {500, 135} + + + {{0, 0}, {1440, 878}} + {213, 129} + {1.79769e+308, 1.79769e+308} + + + YES + + + + + + + _window + + + + 8 + + + + value: values.ASR33MaskPunchedHighBit + + + + + + value: values.ASR33MaskPunchedHighBit + value + values.ASR33MaskPunchedHighBit + + + + + + + 2 + + + 164 + + + + selectedIndex: values.ASR33RunWith10CharsPerSecond + + + + + + selectedIndex: values.ASR33RunWith10CharsPerSecond + selectedIndex + values.ASR33RunWith10CharsPerSecond + + + + + + + + + + + + + 2 + + + 181 + + + + nextKeyView + + + + 186 + + + + _firstKeyView + + + + 190 + + + + _lastKeyView + + + + 191 + + + + _initialKeyView + + + + 192 + + + + nextKeyView + + + + 207 + + + + nextKeyView + + + + 208 + + + + nextKeyView + + + + 209 + + + + value: values.ASR33PlaySound + + + + + + value: values.ASR33PlaySound + value + values.ASR33PlaySound + + + + + + 2 + + + 231 + + + + enabled: values.ASR33RunWith10CharsPerSecond + + + + + + enabled: values.ASR33RunWith10CharsPerSecond + enabled + values.ASR33RunWith10CharsPerSecond + 2 + + + 235 + + + + enabled: values.ASR33RunWith10CharsPerSecond + + + + + + enabled: values.ASR33RunWith10CharsPerSecond + enabled + values.ASR33RunWith10CharsPerSecond + 2 + + + 238 + + + + value: values.ASR33SoundVolume + + + + + + value: values.ASR33SoundVolume + value + values.ASR33SoundVolume + + + 0.5 + + + 2 + + + 239 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 5 + + + + + + ASR33Preferences + + + 6 + + + + + + + + 46 + + + + + + + + + + + + + 124 + + + + + + + + + + 126 + + + + + 127 + + + + + 128 + + + + + + + + 144 + + + Shared User Defaults Controller + + + 195 + + + + + 196 + + + + + 197 + + + + + + + + 198 + + + + + 199 + + + + + + + + 200 + + + + + 203 + + + + + + + + 204 + + + + + 205 + + + + + + + + 206 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Setting the teletype volume individually does not work with Mac OS X 10.4. With “Tiger”, please use the system volume settings. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + {{74, 577}, {500, 135}} + com.apple.InterfaceBuilder.CocoaPlugin + {{74, 577}, {500, 135}} + + + {213, 107} + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 239 + + + + + ASR33Preferences + NSPreferencePane + + IBProjectSource + ASR33Preferences/ASR33Preferences.h + + + + ASR33Preferences + NSPreferencePane + + IBUserSource + + + + + FirstResponder + NSObject + + IBUserSource + + + + + NSControl + + IBProjectSource + Categories/NSControl+FileDrop.h + + + + NSControl + NSView + + IBUserSource + + + + + NSPreferencePane + NSObject + + IBUserSource + + + + + + + NSControl + + IBFrameworkSource + PluginFramework.framework/Headers/NSControl+FileDrop.h + + + + NSPreferencePane + NSObject + + NSView + NSView + NSView + NSWindow + + + IBFrameworkSource + PreferencePanes.framework/Headers/NSPreferencePane.h + + + + + 0 + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../../pdp8e-simulator.xcodeproj + 3 + + diff --git a/ASR33Preferences/English.lproj/ASR33Preferences.nib/keyedobjects.nib b/ASR33Preferences/English.lproj/ASR33Preferences.nib/keyedobjects.nib new file mode 100644 index 0000000..474e887 Binary files /dev/null and b/ASR33Preferences/English.lproj/ASR33Preferences.nib/keyedobjects.nib differ diff --git a/ASR33Preferences/English.lproj/InfoPlist.strings b/ASR33Preferences/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..a32cf22 --- /dev/null +++ b/ASR33Preferences/English.lproj/InfoPlist.strings @@ -0,0 +1,26 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InfoPlist.strings - Localized strings for CPU preference pane Info.plist + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +NSPrefPaneIconLabel = "ASR 33"; +PrefPaneWindowTitle = "ASR 33 Teletype Preferences"; diff --git a/ASR33Preferences/Info.plist b/ASR33Preferences/Info.plist new file mode 100644 index 0000000..aebef0f --- /dev/null +++ b/ASR33Preferences/Info.plist @@ -0,0 +1,56 @@ + + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleIdentifier + de.bernhard-baehr.pdp8e.ASR33Preferences + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + BNDL + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + CFBundleShortVersionString + 2.0.2 + NSMainNibFile + ASR33Preferences + NSPrefPaneIconFile + asr33PrefIcon.jpg + NSPrefPaneIconLabel + ASR 33 + NSPrincipalClass + ASR33Preferences + OrderInPreferencesPanelToolbar + 10 + PrefPaneWindowTitle + ASR 33 Teletype Preferences + + diff --git a/ASR33Preferences/asr33PrefIcon.jpg b/ASR33Preferences/asr33PrefIcon.jpg new file mode 100644 index 0000000..04e1ef6 Binary files /dev/null and b/ASR33Preferences/asr33PrefIcon.jpg differ diff --git a/CPUPreferences/CPUPreferences.h b/CPUPreferences/CPUPreferences.h new file mode 100644 index 0000000..0badaaf --- /dev/null +++ b/CPUPreferences/CPUPreferences.h @@ -0,0 +1,37 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * CPUPreferences.h - CPU Preferences Pane + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define CPU_PREFS_EAE_KEY @"KE8E" +#define CPU_PREFS_KM8E_KEY @"KM8E" +#define CPU_PREFS_TIMESHARING_KEY @"KM8ETimesharing" +#define CPU_PREFS_MEMORYSIZE_KEY @"MemorySize" + + +@interface CPUPreferences : NSPreferencePane +{ +} + +- (IBAction) km8eClick:(id)sender; + +@end diff --git a/CPUPreferences/CPUPreferences.m b/CPUPreferences/CPUPreferences.m new file mode 100644 index 0000000..e1348d4 --- /dev/null +++ b/CPUPreferences/CPUPreferences.m @@ -0,0 +1,43 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * CPUPreferences.m - CPU Preferences Pane + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "CPUPreferences.h" + + +@implementation CPUPreferences + + +// the rest is done via bindings and NSUserDefaultsController + + +- (IBAction) km8eClick:(id)sender; +{ + [[NSUserDefaults standardUserDefaults] setInteger: + ([sender state] == NSOnState) ? 020000 : 010000 forKey:CPU_PREFS_MEMORYSIZE_KEY]; +} + + +@end diff --git a/CPUPreferences/English.lproj/CPUPreferences.nib/designable.nib b/CPUPreferences/English.lproj/CPUPreferences.nib/designable.nib new file mode 100644 index 0000000..8c5eabb --- /dev/null +++ b/CPUPreferences/English.lproj/CPUPreferences.nib/designable.nib @@ -0,0 +1,1035 @@ + + + + 1050 + 11A511 + 1617 + 1138 + 566.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 1617 + + + NSView + NSMatrix + NSWindowTemplate + NSTextField + NSTextFieldCell + NSCustomView + NSButtonCell + NSButton + NSUserDefaultsController + NSCustomObject + + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + CPUPreferences + + + FirstResponder + + + NSApplication + + + 15 + 2 + {{123, 430}, {284, 164}} + 1886912512 + CPUPreferences + + NSWindow + + + View + + + {213, 107} + + + 256 + + + + 261 + + + + 256 + {{18, 0}, {228, 38}} + + + + 4096 + YES + 2 + 4 + + + -2080373760 + 0 + 4K + + LucidaGrande + 13 + 1044 + + + 4096 + 1211912703 + 0 + + NSRadioButton + + + + + + 200 + 25 + + + 67239424 + 0 + 8K + + + 8192 + 1211912703 + 0 + + + + 400 + 75 + + + 67239424 + 0 + 12K + + + 12288 + 1211912703 + 0 + + + + 400 + 75 + + + 67239424 + 0 + 16K + + + 16384 + 1211912703 + 0 + + + + 400 + 75 + + + 67239424 + 0 + 20K + + + 20480 + 1211912703 + 0 + + + + 200 + 25 + + + 67239424 + 0 + 24K + + + 24576 + 1211912703 + 0 + + + + 400 + 75 + + + 67239424 + 0 + 28K + + + 28672 + 1211912703 + 0 + + + + 400 + 75 + + + 67239424 + 0 + 32K + + + 32768 + 1211912703 + 0 + + + + 400 + 75 + + + {57, 18} + {0, 2} + 1143480320 + NSActionCell + + 67239424 + 0 + Radio + + 1211912703 + 0 + + 549453824 + {18, 18} + + + + + + TU0AKgAABRgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAMAAAADAAAAAwAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAADwRERGLJycnySsrK/A1NTXw +IyMjyRwcHIsJCQk8AAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFFRUVdVBQUOCoqKj/ +29vb//n5+f/6+vr/2tra/6qqqv9UVFTgHx8fdQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUZGRl5 +dXV198PDw//8/Pz////////////////////////////U1NT/fHx89yUlJXkAAAAFAAAAAAAAAAAAAAAA +AAAAAxEREUZqamrmtbW1/+3t7f/+/v7//v7+//7+/v/9/f3//f39//39/f/39/f/xMTE/3d3d+YZGRlG +AAAAAwAAAAAAAAAAAAAACkJCQqGtra3/xsbG/+vr6//y8vL/9fX1//X19f/z8/P/9fX1//Ly8v/u7u7/ +0tLS/6+vr/9KSkqhAAAACgAAAAAAAAAAAAAAF3h4eN2/v7//z8/P/93d3f/q6ur/7+/v/+/v7//w8PD/ +7e3t/+3t7f/i4uL/zs7O/8XFxf98fHzdAAAAFwAAAAAAAAADAAAAJKSkpPjOzs7/2dnZ/+Dg4P/i4uL/ +5eXl/+bm5v/n5+f/5eXl/+Li4v/e3t7/2tra/9DQ0P+srKz4AAAAJAAAAAMAAAADAAAALrCwsPrW1tb/ +3t7e/+Tk5P/p6en/6+vr/+zs7P/p6en/6+vr/+fn5//k5OT/4ODg/9nZ2f+zs7P6AAAALgAAAAMAAAAD +AAAALp2dnezg4OD/5eXl/+rq6v/u7u7/8PDw//Dw8P/x8fH/8PDw/+7u7v/q6ur/5ubm/+Hh4f+ZmZns +AAAALgAAAAMAAAADAAAAJG5ubs/l5eX/6enp/+/v7//y8vL/9vb2//r6+v/5+fn/9/f3//b29v/x8fH/ +6+vr/+Tk5P9ra2vPAAAAJAAAAAMAAAAAAAAAFy4uLpPCwsL67Ozs//Pz8//5+fn//v7+//7+/v/+/v7/ +/v7+//v7+//19fX/8PDw/8LCwvosLCyTAAAAFwAAAAAAAAAAAAAACgAAAENfX1/S5OTk/vn5+f/+/v7/ +///////////////////////////8/Pz/5ubm/l9fX9IAAABDAAAACgAAAAAAAAAAAAAAAwAAABcAAABl +YmJi3NLS0v3////////////////////////////////V1dX9ZGRk3AAAAGUAAAAXAAAAAwAAAAAAAAAA +AAAAAAAAAAUAAAAfAAAAZTMzM8KAgIDwv7+//O3t7f/t7e3/v7+//ICAgPAzMzPCAAAAZQAAAB8AAAAF +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAFwAAAEMAAAB3AAAAnwAAALMAAACzAAAAnwAAAHcAAABD +AAAAFwAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAAoAAAAXAAAAJAAAAC4AAAAu +AAAAJAAAABcAAAAKAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAwAAAAMAAAADAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgEAAAMAAAABABIAAAEB +AAMAAAABABIAAAECAAMAAAAEAAAFxgEDAAMAAAABAAEAAAEGAAMAAAABAAIAAAERAAQAAAABAAAACAES +AAMAAAABAAEAAAEVAAMAAAABAAQAAAEWAAMAAAABABIAAAEXAAQAAAABAAAFEAEcAAMAAAABAAEAAAFS +AAMAAAABAAEAAAFTAAMAAAAEAAAFzodzAAcAAANYAAAF1gAAAAAACAAIAAgACAABAAEAAQABAAADWGFw +cGwCAAAAbW50clJHQiBYWVogB9UABQAUABUAMwAUYWNzcEFQUEwAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAPbWAAEAAAAA0y1hcHBsEOtwy3GbVlOfBJHUHMDIsAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAOclhZWgAAASwAAAAUZ1hZWgAAAUAAAAAUYlhZWgAAAVQAAAAUd3RwdAAAAWgAAAAUY2hhZAAA +AXwAAAAsclRSQwAAAagAAAAOZ1RSQwAAAbgAAAAOYlRSQwAAAcgAAAAOdmNndAAAAdgAAAAwbmRpbgAA +AggAAAA4ZGVzYwAAAkAAAABvZHNjbQAAArAAAABQbW1vZAAAAwAAAAAoY3BydAAAAygAAAAtWFlaIAAA +AAAAAHDAAAA8EgAAAx9YWVogAAAAAAAAW8QAAK3BAAAXCFhZWiAAAAAAAAAqUgAAFl8AALj6WFlaIAAA +AAAAAPNpAAEAAAABaBRzZjMyAAAAAAABGV8AAAsd///pZAAADooAAP0W///4P///++0AAAaUAACUN2N1 +cnYAAAAAAAAAAQHNAABjdXJ2AAAAAAAAAAEBzQAAY3VydgAAAAAAAAABAc0AAHZjZ3QAAAAAAAAAAQAA +qqsAAAAAAAEAAAAAqqsAAAAAAAEAAAAAqqsAAAAAAAEAAG5kaW4AAAAAAAAAMAAAoEAAAFaAAABHQAAA +mcAAACcXAAASmwAASIAAAExAAAKzMwACszMAArMzZGVzYwAAAAAAAAAVQXBwbGUgU3R1ZGlvIERpc3Bs +YXkAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAG1sdWMAAAAAAAAAAgAAAAxlblVTAAAAKAAAAChkZURFAAAAKAAA +ACgAQQBwAHAAbABlACAAUwB0AHUAZABpAG8AIABEAGkAcwBwAGwAYQB5bW1vZAAAAAAAAAYQAACSEwIA +MsS0ibmAAAAAAAAAAAAAAAAAAAAAAHRleHQAAAAAQ29weXJpZ2h0IEFwcGxlIENvbXB1dGVyLCBJbmMu +LCAyMDA1AAAAAA + + + + + + 3 + MCAwAA + + + + 400 + 75 + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 3 + MQA + + + + + + 256 + {{17, 45}, {89, 17}} + + + + YES + + 67239424 + 272629760 + Memory Size: + + + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + 256 + {{18, 66}, {228, 18}} + + + + YES + + 67239424 + 0 + Enable Time Sharing Option + + + 1211912703 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + + + + 256 + {{-2, 88}, {248, 18}} + + + + YES + + 67239424 + 0 + KM8-E Memory Extension + + + 1211912703 + 2 + + + + + 200 + 25 + + + + + 256 + {{-2, 108}, {248, 18}} + + + + YES + + -2080244224 + 0 + KE8-E Extended Arithmetic Element + + + 1211912703 + 2 + + + + + 200 + 25 + + + + {{20, 20}, {244, 126}} + + + + NSView + NSResponder + + + {284, 164} + + + + + {{0, 0}, {1280, 778}} + {213, 129} + {10000000000000, 10000000000000} + YES + + + YES + + + + + + + _window + + + + 8 + + + + km8eClick: + + + + 103 + + + + nextKeyView + + + + 108 + + + + nextKeyView + + + + 109 + + + + nextKeyView + + + + 110 + + + + nextKeyView + + + + 111 + + + + _initialKeyView + + + + 113 + + + + _lastKeyView + + + + 114 + + + + _firstKeyView + + + + 115 + + + + initialFirstResponder + + + + 116 + + + + nextKeyView + + + + 117 + + + + value: values.KM8E + + + + + + value: values.KM8E + value + values.KM8E + + + + + + + + + + + + + 2 + + + 139 + + + + value: values.KE8E + + + + + + value: values.KE8E + value + values.KE8E + + + + + + + 2 + + + 140 + + + + value: values.KM8ETimesharing + + + + + + value: values.KM8ETimesharing + value + values.KM8ETimesharing + + + + + + + 2 + + + 141 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + 2 + + + 142 + + + + selectedTag: values.MemorySize + + + + + + selectedTag: values.MemorySize + selectedTag + values.MemorySize + + + + + + + + + + + + + 2 + + + 144 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + + + NSNegateBoolean + + 2 + + + 155 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + + + + 2 + + + 157 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + + + + 2 + + + 159 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + + + + 2 + + + 161 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + + + + 2 + + + 164 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + + + + 2 + + + 166 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + + + + 2 + + + 168 + + + + enabled: values.KM8E + + + + + + enabled: values.KM8E + enabled + values.KM8E + + + + + + + + 2 + + + 170 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 5 + + + + + + CPUPreferences + + + 6 + + + + + + + + 46 + + + + + + + + + + + + 80 + + + + + + + + + + + + + + + + 81 + + + + + 82 + + + + + 83 + + + + + 84 + + + + + 85 + + + + + 86 + + + + + 87 + + + + + 88 + + + + + 89 + + + + + + + + 90 + + + + + + + + 91 + + + + + + + + 92 + + + + + + + + 124 + + + Shared User Defaults Controller + + + 173 + + + + + 174 + + + + + 175 + + + + + 176 + + + + + 177 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + 177 + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + 3 + + NSSwitch + {15, 15} + + + diff --git a/CPUPreferences/English.lproj/CPUPreferences.nib/keyedobjects.nib b/CPUPreferences/English.lproj/CPUPreferences.nib/keyedobjects.nib new file mode 100644 index 0000000..14d1874 Binary files /dev/null and b/CPUPreferences/English.lproj/CPUPreferences.nib/keyedobjects.nib differ diff --git a/CPUPreferences/English.lproj/CPUPreferences~.nib/classes.nib b/CPUPreferences/English.lproj/CPUPreferences~.nib/classes.nib new file mode 100644 index 0000000..45fad94 --- /dev/null +++ b/CPUPreferences/English.lproj/CPUPreferences~.nib/classes.nib @@ -0,0 +1,34 @@ +{ + IBClasses = ( + { + ACTIONS = { + eaeClick = id; + km8eClick = id; + memSizeClick = id; + timeSharingOptionClick = id; + }; + CLASS = CPUPreferences; + LANGUAGE = ObjC; + OUTLETS = { + eaeCheckbox = NSButton; + km8eCheckbox = NSButton; + memSizeRadiobuttons = NSMatrix; + timeSharingOptionCheckbox = NSButton; + }; + SUPERCLASS = NSPreferencePane; + }, + {CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; }, + { + CLASS = NSPreferencePane; + LANGUAGE = ObjC; + OUTLETS = { + "_firstKeyView" = NSView; + "_initialKeyView" = NSView; + "_lastKeyView" = NSView; + "_window" = NSWindow; + }; + SUPERCLASS = NSObject; + } + ); + IBVersion = 1; +} \ No newline at end of file diff --git a/CPUPreferences/English.lproj/CPUPreferences~.nib/info.nib b/CPUPreferences/English.lproj/CPUPreferences~.nib/info.nib new file mode 100644 index 0000000..a718e51 --- /dev/null +++ b/CPUPreferences/English.lproj/CPUPreferences~.nib/info.nib @@ -0,0 +1,16 @@ + + + + + IBDocumentLocation + 135 64 356 240 0 0 1440 878 + IBFramework Version + 443.0 + IBOpenObjects + + 5 + + IBSystem Version + 8I1119 + + diff --git a/CPUPreferences/English.lproj/CPUPreferences~.nib/keyedobjects.nib b/CPUPreferences/English.lproj/CPUPreferences~.nib/keyedobjects.nib new file mode 100644 index 0000000..0545905 Binary files /dev/null and b/CPUPreferences/English.lproj/CPUPreferences~.nib/keyedobjects.nib differ diff --git a/CPUPreferences/English.lproj/InfoPlist.strings b/CPUPreferences/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..d2e13a6 --- /dev/null +++ b/CPUPreferences/English.lproj/InfoPlist.strings @@ -0,0 +1,26 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InfoPlist.strings - Localized strings for CPU preference pane Info.plist + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +NSPrefPaneIconLabel = "CPU"; +PrefPaneWindowTitle = "PDP-8/E CPU Preferences"; diff --git a/CPUPreferences/Info.plist b/CPUPreferences/Info.plist new file mode 100644 index 0000000..cb01b5c --- /dev/null +++ b/CPUPreferences/Info.plist @@ -0,0 +1,34 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleIdentifier + de.bernhard-baehr.pdp8e.CPUPreferences + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + BNDL + CFBundleShortVersionString + 2.0.2 + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + NSMainNibFile + CPUPreferences + NSPrefPaneIconFile + cpuPrefIcon.jpg + NSPrefPaneIconLabel + CPU + NSPrincipalClass + CPUPreferences + OrderInPreferencesPanelToolbar + 02 + PrefPaneWindowTitle + PDP-8/E CPU Preferences + + diff --git a/CPUPreferences/cpuPrefIcon.jpg b/CPUPreferences/cpuPrefIcon.jpg new file mode 100644 index 0000000..9cbdacf Binary files /dev/null and b/CPUPreferences/cpuPrefIcon.jpg differ diff --git a/CPUWindow/CPUMemoryViewController.h b/CPUWindow/CPUMemoryViewController.h new file mode 100644 index 0000000..364df09 --- /dev/null +++ b/CPUWindow/CPUMemoryViewController.h @@ -0,0 +1,44 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * CPUMemoryViewController.h - Controller for CPU window memory view + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class BreakpointArray, PDP8, CPUMemoryTableView; + + +@interface CPUMemoryViewController : NSObject +{ +@private + IBOutlet CPUMemoryTableView *memoryView; + IBOutlet BreakpointArray *breakpoints; + IBOutlet BreakpointArray *breakopcodes; + IBOutlet PDP8 *pdp8; + BOOL ignoreUpdateMemoryNotification; + BOOL ignorePCChangedNotification; + NSRange visibleMemoryRange; + unsigned pcDefaultRow; +} + +- (IBAction) handleContextMenu:(id)sender; +- (NSString *) operandInfoAtAddress:(int)addr; // private delegate method, declared here to avoid warning + +@end diff --git a/CPUWindow/CPUMemoryViewController.m b/CPUWindow/CPUMemoryViewController.m new file mode 100644 index 0000000..a08915a --- /dev/null +++ b/CPUWindow/CPUMemoryViewController.m @@ -0,0 +1,654 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * CPUMemoryViewController.m - Controller for the CPU window memory view + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import +#import // for Help Manger functions + +#import "CPUMemoryViewController.h" +#import "PDP8.h" +#import "Opcode.h" +#import "Breakpoint.h" +#import "BreakpointArray.h" +#import "NSTableView+Scrolling.h" +#import "NonWrappingTableView.h" +#import "OpcodeFormatter.h" +#import "Disassembler.h" +#import "Unicode.h" +#import "Utilities.h" + + +#define PC_ARROW_BLUE_IMAGE @"pcArrowBlue" +#define PC_ARROW_GRAPHITE_IMAGE @"pcArrowGraphite" +#define PC_ARROW_DRAG_TYPE @"pcArrowDragType" +#define UPDATE_MEMORY_NOTIFICATION @"UpdateMemoryNotification" + +#define PC_DEFAULT_ROW_PREFS_KEY @"DefaultPCRow" + +#define PC_DEFAULT_ROW 10 + +#define PC_COLUMN 0 +#define PC_COLUMN_STR @"0" +#define BP_COLUMN 1 +#define ADDR_COLUMN 2 +#define WORD_COLUMN 3 +#define OPCODE_COLUMN 4 + +#define CONTEXTMENU_SET_BREAKPOINT 0 +#define CONTEXTMENU_SET_BREAKOPCODE 1 +#define CONTEXTMENU_SET_SYSTEM_BREAKOPCODE 2 +#define CONTEXTMENU_SET_USER_BREAKOPCODE 3 +#define CONTEXTMENU_SET_PC 4 +#define CONTEXTMENU_GO_AND_STOP_HERE 5 +#define CONTEXTMENU_TRACE_AND_STOP_HERE 6 +#define CONTEXTMENU_SCROLL_TO_PC 7 +#define CONTEXTMENU_SET_DEFAULT_PC_ROW 8 + + +@interface CPUMemoryTableView : NonWrappingTableView +{ +} +@end + + +@implementation CPUMemoryTableView + + +- (BOOL) canDragRowsWithIndexes:(NSIndexSet *)rows atPoint:(NSPoint)mouseDownPoint +{ + // allow drag only for current PC row to avoid minor screen flicker with the clicked cell with Yosemite + return [rows count] == 1 && [[self delegate] tableView:self + objectValueForTableColumn:[self tableColumnWithIdentifier:PC_COLUMN_STR] row:[rows firstIndex]] + != nil; +} + + +- (NSImage *) dragImageForRowsWithIndexes:(NSIndexSet *)dragRows tableColumns:(NSArray *)tableColumns + event:(NSEvent*)dragEvent offset:(NSPointPointer)dragImageOffset +{ + return [NSImage imageNamed:[NSColor currentControlTint] == NSGraphiteControlTint ? + PC_ARROW_GRAPHITE_IMAGE : PC_ARROW_BLUE_IMAGE]; +} + + +- (NSMenu *) menuForEvent:(NSEvent *)event +{ + int row = [self rowAtPoint:[self convertPoint:[event locationInWindow] fromView:nil]]; + [self selectRowIndexes:[NSIndexSet indexSetWithIndex:row] byExtendingSelection:NO]; + return [self menu]; +} + + +- (void) mouseDown:(NSEvent *)event +{ + CFStringRef tipContent; + + NSPoint point = [self convertPoint:[event locationInWindow] fromView:nil]; + int row = [self rowAtPoint:point]; + [self selectRowIndexes:[NSIndexSet indexSetWithIndex:row] byExtendingSelection:NO]; + // why does [super mouseDown:event] not select the clicked row immediately? + if (([event modifierFlags] & NSShiftKeyMask) && [self columnAtPoint:point] == OPCODE_COLUMN && + (tipContent = (CFStringRef) [[self delegate] operandInfoAtAddress:row])) { + HMHelpContentRec tip; + tip.version = kMacHelpVersion; + NSRect rect = [self frameOfCellAtColumn:OPCODE_COLUMN row:row]; + rect.origin = [[self window] convertBaseToScreen: + [self convertPoint:rect.origin toView:nil]]; + float scale = [[self window] userSpaceScaleFactor]; + tip.absHotRect.left = rect.origin.x / scale + 33; + tip.absHotRect.right = (rect.origin.x + rect.size.width) / scale; + tip.absHotRect.top = + ([[[NSScreen screens] objectAtIndex:0] frame].size.height - rect.origin.y) / scale; + tip.absHotRect.bottom = tip.absHotRect.top + rect.size.height / scale; + tip.tagSide = kHMOutsideBottomLeftAligned; + tip.content[0].contentType = tip.content[1].contentType = kHMCFStringContent; + tip.content[0].u.tagCFString = tip.content[1].u.tagCFString = tipContent; + HMDisplayTag (&tip); + } + [super mouseDown:event]; + HMHideTag (); +} + + +- (void) selectRowIndexes:(NSIndexSet *)indexes byExtendingSelection:(BOOL)extend +{ + if ((int) [indexes firstIndex] != [self selectedRow]) + HMHideTag (); + [super selectRowIndexes:indexes byExtendingSelection:extend]; +} + + +- (int) getCurrentAddress // OpcodeFormatterAddressGetter protocol +{ + return [self selectedRow]; +} + + +@end + + +@implementation CPUMemoryViewController + + +- (void) setYosemiteTitleKerning:(NSCell *)cell +{ + // otherwise, the title of the PC and BP columns is clipped + // (capitals are longer with Helvetica Neue than with Lucida Grande + if (runningOnYosemiteOrNewer()) { + double kern = 0.4; + if (runningOnElCapitanOrNewer()) + kern = -0.5; + [cell setTitle:[[[NSAttributedString alloc] initWithString:[cell title] attributes: + [NSDictionary dictionaryWithObject:[NSNumber numberWithDouble:kern] forKey:NSKernAttributeName]] + autorelease]]; + } +} + + +- (void) awakeFromNib +{ + NSSize size; + + NSFont *font = [NSFont userFixedPitchFontOfSize:11]; + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + + [self setYosemiteTitleKerning:[[[memoryView tableColumns] objectAtIndex:PC_COLUMN] headerCell]]; + [self setYosemiteTitleKerning:[[[memoryView tableColumns] objectAtIndex:BP_COLUMN] headerCell]]; + adjustTableHeaderForElCapitan (memoryView); + size.width = 1; + size.height = [memoryView rowHeight] + 2; + [[memoryView window] setResizeIncrements:size]; + [[[[memoryView tableColumns] objectAtIndex:ADDR_COLUMN] dataCell] setFont:font]; + [[[[memoryView tableColumns] objectAtIndex:WORD_COLUMN] dataCell] setFont:font]; + [[[[memoryView tableColumns] objectAtIndex:OPCODE_COLUMN] dataCell] setFont:font]; + [[[[memoryView tableColumns] objectAtIndex:OPCODE_COLUMN] dataCell] setFormatter: + [OpcodeFormatter formatterWithPDP8:pdp8 addressGetter:memoryView]]; + [memoryView setTarget:self]; + [memoryView setDoubleAction:@selector(memoryViewDoubleClick:)]; + [memoryView registerForDraggedTypes:[NSArray arrayWithObject:PC_ARROW_DRAG_TYPE]]; + pcDefaultRow = [[NSUserDefaults standardUserDefaults] integerForKey:PC_DEFAULT_ROW_PREFS_KEY]; + if (pcDefaultRow == 0) + pcDefaultRow = PC_DEFAULT_ROW; + [memoryView scrollRowToTop:0200 + 1 - pcDefaultRow]; + // frame changed notification seems not work for the tableview itself + [[memoryView superview] setPostsFrameChangedNotifications:YES]; + // save the visible range now to be able to scroll to the correct location after "go" + visibleMemoryRange = [memoryView rowsInRect:[memoryView visibleRect]]; + ignoreUpdateMemoryNotification = NO; + ignorePCChangedNotification = NO; + [defaultCenter addObserver:self selector:@selector(notifyMemoryViewSizeChanged:) + name:NSViewFrameDidChangeNotification object:[memoryView superview]]; + [defaultCenter addObserver:self selector:@selector(notifyMemoryChanged:) + name:MEMORY_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyMemoryChanged:) + name:EAE_MODE_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyMemoryChanged:) + name:BREAKPOINTS_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyMemoryChanged:) + name:PROGRAM_COUNTER_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyMemoryChanged:) + name:DF_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyUpdateMemoryView:) + name:UPDATE_MEMORY_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyGoPDP8:) + name:PDP8_GO_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyStepPDP8:) + name:PDP8_STEP_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyStopPDP8:) + name:PDP8_STOP_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyPCChanged:) + name:PROGRAM_COUNTER_CHANGED_NOTIFICATION object:nil]; + if (runningOnYosemiteOrNewer()) { + [defaultCenter addObserver:self selector:@selector(notifyMainOrKeyWindowChanged:) + name:NSWindowDidBecomeMainNotification object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyMainOrKeyWindowChanged:) + name:NSWindowDidResignMainNotification object:nil]; + } else { + [defaultCenter addObserver:self selector:@selector(notifyMainOrKeyWindowChanged:) + name:NSWindowDidBecomeKeyNotification object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyMainOrKeyWindowChanged:) + name:NSWindowDidResignKeyNotification object:nil]; + } +} + + +- (void) updateVisibleMemoryRange +{ + // save the visible range now to be able to scroll to the correct location after "go" + // calculate number of rows manually because otherwise it is one to large when the view is not exactly aligned + // see also [MemoryInspectorController visibleRange] and [NSTableView(Scrolling) scrollRowToTop:] + NSRect rect = [memoryView visibleRect]; + if (rect.size.height > 0) { // zero immediately after "Stop" when the window is not yet enlarged + if (runningOnElCapitanOrNewer()) + rect.origin.y += [memoryView rectOfRow:0].size.height; + unsigned pixelPerRow = (unsigned) ([memoryView rowHeight] + [memoryView intercellSpacing].height); + visibleMemoryRange.location = [memoryView rowsInRect:rect].location; + visibleMemoryRange.length = rect.size.height / pixelPerRow; + } +} + + +- (BOOL) tableView:(NSTableView *)tableView shouldEditTableColumn:(NSTableColumn *)column row:(int)row +{ + return 0 <= row && row < [pdp8 memorySize]; +} + + +- (BOOL) tableView:(NSTableView *)tableView shouldSelectRow:(int)row +{ + return YES; +} + + +- (void) scrollToPC +{ + [self updateVisibleMemoryRange]; + [memoryView scrollRowToTop:max(0, min((int) (PDP8_MEMSIZE - visibleMemoryRange.length), + (int) ([pdp8 getProgramCounter] - pcDefaultRow + 1)))]; +} + + +- (BOOL) tableView:(NSTableView *)tableView shouldSelectTableColumn:(NSTableColumn *)column +{ + if ([[column identifier] intValue] == PC_COLUMN) + [self scrollToPC]; + return NO; +} + + +- (BOOL) tableView:(NSTableView *)tableView writeRowsWithIndexes:(NSIndexSet *)rows + toPasteboard:(NSPasteboard *)pboard +{ + if ([rows count] != 1 || [rows firstIndex] != [pdp8 getProgramCounter]) + return NO; + [pboard declareTypes:[NSArray arrayWithObject:PC_ARROW_DRAG_TYPE] owner:nil]; + return YES; +} + + +- (NSDragOperation) tableView:(NSTableView *)tableView validateDrop:(id )info + proposedRow:(int)row proposedDropOperation:(NSTableViewDropOperation)operation +{ + return operation == NSTableViewDropOn ? NSDragOperationPrivate : NSDragOperationNone; +} + + +- (BOOL) tableView:(NSTableView *)tableView acceptDrop:(id )info + row:(int)row dropOperation:(NSTableViewDropOperation)operation +{ + if ((row > 07777) & ! [pdp8 hasKM8E]) + return NO; + [pdp8 setProgramCounter:row]; + return YES; +} + + +- (int) numberOfRowsInTableView:(NSTableView *)tableView +{ + return PDP8_MEMSIZE; +} + + +- (id) tableView:(NSTableView *)tableView objectValueForTableColumn:(NSTableColumn *)column row:(int)row +{ + switch ([[column identifier] intValue]) { + case PC_COLUMN : + if (row == [pdp8 getProgramCounter]) + return [NSImage imageNamed:([NSColor currentControlTint] == NSBlueControlTint) + && (runningOnYosemiteOrNewer() ? + [[tableView window] isMainWindow] : [[tableView window] isKeyWindow]) ? + PC_ARROW_BLUE_IMAGE : PC_ARROW_GRAPHITE_IMAGE]; + break; + case BP_COLUMN : + if ([breakpoints valueForIdentifier:row]) + return [NSImage imageNamed:@"breakpoint"]; + switch ([breakopcodes valueForIdentifier:[pdp8 memoryAt:row]]) { + case BREAKOPCODE : + return [NSImage imageNamed:@"breakOpcode"]; + case USERMODE_BREAKOPCODE : + return [NSImage imageNamed:@"breakOpcodeU"]; + case SYSTEMMODE_BREAKOPCODE : + return [NSImage imageNamed:@"breakOpcodeS"]; + } + break; + case ADDR_COLUMN : + if ((row & 007770) == 000010) { // autoincrement locations are underlined + NSMutableParagraphStyle *style = + [[[NSMutableParagraphStyle alloc] init] autorelease]; + [style setAlignment:NSCenterTextAlignment]; + return [[[NSAttributedString alloc] + initWithString:[NSString stringWithFormat:@"%5.5o", row] + attributes:[NSDictionary dictionaryWithObjectsAndKeys: + [NSNumber numberWithInt:NSSingleUnderlineStyle], + NSUnderlineStyleAttributeName, + style, NSParagraphStyleAttributeName, + nil]] autorelease]; + } + return [NSString stringWithFormat:@"%5.5o", row]; + case WORD_COLUMN : + return [NSString stringWithFormat:@"%4.4o", [pdp8 memoryAt:row]]; + case OPCODE_COLUMN : + return [Opcode opcodeWithAddress:row value:[pdp8 memoryAt:row]]; + } + return nil; +} + + +- (NSString *) tableView:(NSTableView *)tableView toolTipForCell:(NSCell *)cell + rect:(NSRectPointer)rect tableColumn:(NSTableColumn *)column row:(int)row + mouseLocation:(NSPoint)mouseLocation +{ + switch ([[column identifier] intValue]) { + case PC_COLUMN : + return NSLocalizedString( + @"In this column, an arrow indicates the PDP-8/E program counter.\n\n" + "Drag the arrow or double-click a location to modify the program counter.\n\n" + "Click the column header to scroll to the current program counter location.", @""); + case BP_COLUMN : + return NSLocalizedString(@"This column shows breakpoints with a red dot. " + "Break opcodes are indicated with a yellow dot. " + "A small " UNICODE_LEFT_DOUBLEQUOTE_UTF8 "s" UNICODE_RIGHT_DOUBLEQUOTE_UTF8 " or " + UNICODE_LEFT_DOUBLEQUOTE_UTF8 "u" UNICODE_RIGHT_DOUBLEQUOTE_UTF8 " in the dot " + "indicate system or user mode break opcodes.\n\n" + "Double-click sets or clears a breakpoint.\n\n" + "Option-double-click and command-option-double-click toogles break opcodes.", @""); + case ADDR_COLUMN : + return NSLocalizedString(@"This column displays the memory adresses. " + "Adresses of autoincrement memory locations are underlined.", @""); + case WORD_COLUMN : + return NSLocalizedString(@"This column displays the octal memory content.", @""); + case OPCODE_COLUMN : + return NSLocalizedString(@"This column displays the disassembled PDP-8 instruction.\n\n" + "Shift-click to view the operands of MRIs.", @""); + } + return nil; +} + + +- (void) tableView:(NSTableView *)tableView setObjectValue:(Opcode *)opcode + forTableColumn:(NSTableColumn *)column row:(int)row +{ + // why do we get this setObjectValue message for read-only cells? + if (row < [pdp8 memorySize]) { + ignoreUpdateMemoryNotification = YES; + [pdp8 setMemoryAtAddress:row toValue:[opcode word0]]; + if ([opcode word1] >= 0) + [pdp8 setMemoryAtNextAddress:row toValue:[opcode word1]]; + } +} + + +- (BOOL) control:(NSControl *)control didFailToFormatString:(NSString *)string + errorDescription:(NSString *)error +{ + NSRange range; + + NSScanner *scanner = [NSScanner scannerWithString:error]; + NSAlert *alert = [[NSAlert alloc] init]; + [scanner scanInt:(signed *) &range.location]; + range.length = [string length] - range.location; + [[control currentEditor] setSelectedRange:range]; + [alert setMessageText:[error substringFromIndex:[scanner scanLocation] + 1]]; + [alert beginSheetModalForWindow:[control window] + modalDelegate:nil didEndSelector:nil contextInfo:nil]; + [alert release]; + return NO; +} + + +- (BOOL) control:(NSControl *)control textView:(NSTextView *)textView doCommandBySelector:(SEL)command +{ + if (command == @selector(cancelOperation:)) { + // ESC aborts editing of the current cell + [control abortEditing]; + return YES; + } + return NO; +} + + +- (void) memoryViewDoubleClick:(id)sender +{ + unsigned modifiers; + + int row = [sender clickedRow]; + if (row < 0 || [pdp8 isRunning]) + return; + switch ([sender clickedColumn]) { + case PC_COLUMN : + if ([pdp8 hasKM8E] || row < 010000) + [pdp8 setProgramCounter:row]; + break; + case BP_COLUMN : + case ADDR_COLUMN : + modifiers = [[NSApp currentEvent] modifierFlags]; + if (modifiers & NSAlternateKeyMask) { + unsigned opcode = [pdp8 memoryAt:row]; + unsigned value = [breakopcodes valueForIdentifier:opcode]; + if (modifiers & NSCommandKeyMask) + value = (value + BREAKOPCODE) & BREAKOPCODE; + else + value = value ? 0 : BREAKOPCODE; + [breakopcodes setBreakpointWithIdentifier:opcode value:value]; + } else + [breakpoints setBreakpointWithIdentifier:row + value:[breakpoints valueForIdentifier:row] ? 0 : BREAKPOINT]; + [sender reloadData]; + break; + case WORD_COLUMN : + break; + case OPCODE_COLUMN : + // with Leopard, this is required, don't know why: for editable cells, the + // double action should not be called, but the editing should start automatically + // (NSTableView documentation) + if (row < [pdp8 memorySize]) + [sender editColumn:OPCODE_COLUMN row:row withEvent:nil select:YES]; + break; + } +} + + +- (BOOL) validateMenuItem:(NSMenuItem *)menuItem +{ + if ([pdp8 isRunning]) + return FALSE; + int row = [memoryView selectedRow]; + unsigned breakop = [breakopcodes valueForIdentifier:[pdp8 memoryAt:row]]; + switch ([menuItem tag]) { + case CONTEXTMENU_SET_BREAKPOINT : + [menuItem setTitle:[breakpoints valueForIdentifier:row] ? + NSLocalizedString(@"Clear Breakpoint", @"") : + NSLocalizedString(@"Set Breakpoint", @"")]; + return TRUE; + case CONTEXTMENU_SET_BREAKOPCODE : + [menuItem setTitle:breakop == BREAKOPCODE ? + NSLocalizedString(@"Clear Break Opcode", @"") : + NSLocalizedString(@"Set Break Opcode", @"")]; + return breakop == BREAKOPCODE || breakop == 0; + case CONTEXTMENU_SET_SYSTEM_BREAKOPCODE : + [menuItem setTitle:(breakop & SYSTEMMODE_BREAKOPCODE) ? + NSLocalizedString(@"Clear System Mode Break Opcode", @"") : + NSLocalizedString(@"Set System Mode Break Opcode", @"")]; + return TRUE; + case CONTEXTMENU_SET_USER_BREAKOPCODE : + [menuItem setTitle:(breakop & USERMODE_BREAKOPCODE) ? + NSLocalizedString(@"Clear User Mode Break Opcode", @"") : + NSLocalizedString(@"Set User Mode Break Opcode", @"")]; + return TRUE; + case CONTEXTMENU_SET_PC : + case CONTEXTMENU_GO_AND_STOP_HERE : + case CONTEXTMENU_TRACE_AND_STOP_HERE : + return row < 010000 || [pdp8 hasKM8E]; + case CONTEXTMENU_SCROLL_TO_PC : + case CONTEXTMENU_SET_DEFAULT_PC_ROW : + return TRUE; + } + return FALSE; +} + + +- (IBAction) handleContextMenu:(id)sender +{ + int row = [memoryView selectedRow]; + unsigned opcode = [pdp8 memoryAt:row]; + unsigned breakop = [breakopcodes valueForIdentifier:opcode]; + switch ([sender tag]) { + case CONTEXTMENU_SET_BREAKPOINT : + [breakpoints setBreakpointWithIdentifier:row + value:[breakpoints valueForIdentifier:row] ? 0 : BREAKPOINT]; + break; + case CONTEXTMENU_SET_BREAKOPCODE : + [breakopcodes setBreakpointWithIdentifier:opcode value:breakop ? 0 : BREAKOPCODE]; + break; + case CONTEXTMENU_SET_SYSTEM_BREAKOPCODE : + [breakopcodes setBreakpointWithIdentifier:opcode value:breakop ^ SYSTEMMODE_BREAKOPCODE]; + break; + case CONTEXTMENU_SET_USER_BREAKOPCODE : + [breakopcodes setBreakpointWithIdentifier:opcode value:breakop ^ USERMODE_BREAKOPCODE]; + break; + case CONTEXTMENU_SET_PC : + if ([pdp8 hasKM8E] || row < 010000) + [pdp8 setProgramCounter:row]; + break; + case CONTEXTMENU_GO_AND_STOP_HERE : + [pdp8 go:row]; + break; + case CONTEXTMENU_TRACE_AND_STOP_HERE : + [pdp8 trace:row]; + break; + case CONTEXTMENU_SCROLL_TO_PC : + [self scrollToPC]; + break; + case CONTEXTMENU_SET_DEFAULT_PC_ROW : + [self updateVisibleMemoryRange]; + pcDefaultRow = row - visibleMemoryRange.location + 1; + [[NSUserDefaults standardUserDefaults] setInteger:pcDefaultRow + forKey:PC_DEFAULT_ROW_PREFS_KEY]; + [self scrollToPC]; + break; + } +} + + +- (NSString *) operandInfoAtAddress:(int)addr +{ + return [[Disassembler sharedDisassembler] operandInfoForPDP8:pdp8 atAddress:addr]; +} + + +#pragma mark Notifications + + +- (void) notifyMainOrKeyWindowChanged:(NSNotification *)notification +{ + // NSLog (@"CPUMemoryViewController notifyMainOrKeyWindowChanged"); + if ([[notification object] isEqual:[memoryView window]]) + [memoryView setNeedsDisplayInRect: + [memoryView frameOfCellAtColumn:PC_COLUMN row:[pdp8 getProgramCounter]]]; +} + + +- (void) notifyMemoryViewSizeChanged:(NSNotification *)notification +{ + // NSLog (@"CPUMemoryViewController notifyMemoryViewSizeChanged"); + [self updateVisibleMemoryRange]; + if (visibleMemoryRange.length < pcDefaultRow) { + pcDefaultRow = PC_DEFAULT_ROW; + [[NSUserDefaults standardUserDefaults] removeObjectForKey:PC_DEFAULT_ROW_PREFS_KEY]; + } +} + + +- (void) notifyMemoryChanged:(NSNotification *)notification +{ + /* coalesc the multiple MEMORY_CHANGED_NOTIFICATIONS (caused by the different register update + notifications) to one UPDATE_MEMORY_NOTIFICATION to avoid time consuming repeated memory + view updates */ + // NSLog (@"CPUMemoryViewController notifyMemoryChanged"); + [[NSNotificationQueue defaultQueue] enqueueNotification: + [NSNotification notificationWithName:UPDATE_MEMORY_NOTIFICATION object:self] + postingStyle:NSPostASAP coalesceMask:NSNotificationCoalescingOnName forModes:nil]; +} + + +- (void) notifyUpdateMemoryView:(NSNotification *)notification +{ + // NSLog (@"CPUMemoryViewController notifyUpdateMemoryView ign=%d", ignoreUpdateMemoryNotification); + if (ignoreUpdateMemoryNotification) + ignoreUpdateMemoryNotification = NO; + else + [memoryView reloadData]; +} + + +- (void) notifyGoPDP8:(NSNotification *)notification +{ + // NSLog (@"CPUMemoryViewController notifyGoPDP8"); + [self updateVisibleMemoryRange]; +} + + +- (void) notifyStepPDP8:(NSNotification *)notification +{ + // NSLog (@"CPUMemoryViewController notifyStepPDP8"); + [self updateVisibleMemoryRange]; + unsigned pc = [pdp8 getProgramCounter]; + if (visibleMemoryRange.location + visibleMemoryRange.length == pc) + [memoryView scrollRowToVisible:pc]; + else if (pc < visibleMemoryRange.location || visibleMemoryRange.location + visibleMemoryRange.length <= pc) + [memoryView scrollRowToTop: + max(0, min((int) (PDP8_MEMSIZE - visibleMemoryRange.length), (int) (pc - pcDefaultRow + 1)))]; + [memoryView reloadData]; + ignoreUpdateMemoryNotification = YES; + ignorePCChangedNotification = YES; +} + + +- (void) notifyStopPDP8:(NSNotification *)notification +{ + // NSLog (@"CPUMemoryViewController notifyStopPDP8"); + [self updateVisibleMemoryRange]; + unsigned pc = [pdp8 getProgramCounter]; + if (pc < visibleMemoryRange.location || visibleMemoryRange.location + visibleMemoryRange.length <= pc) + [memoryView scrollRowToTop: + max(0, min((int) (PDP8_MEMSIZE - visibleMemoryRange.length), (int) (pc - pcDefaultRow + 1)))]; + ignorePCChangedNotification = YES; +} + + +- (void) notifyPCChanged:(NSNotification *)notification +{ + // NSLog (@"CPUMemoryViewController notifyPCChanged %d", ignorePCChangedNotification); + if (ignorePCChangedNotification) { + ignorePCChangedNotification = NO; + return; + } + [self updateVisibleMemoryRange]; + unsigned pc = [pdp8 getProgramCounter]; + if (pc < visibleMemoryRange.location || visibleMemoryRange.location + visibleMemoryRange.length <= pc) + [memoryView scrollRowToTop: + max(0, min((int) (PDP8_MEMSIZE - visibleMemoryRange.length), (int) (pc - pcDefaultRow + 1)))]; +} + + +@end diff --git a/CPUWindow/CPUWindowController.h b/CPUWindow/CPUWindowController.h new file mode 100644 index 0000000..422f4a8 --- /dev/null +++ b/CPUWindow/CPUWindowController.h @@ -0,0 +1,60 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * CPUWindowController.h - Controller for the CPU window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class RegisterFormCell, EnableDisableTextField, PDP8; + + +@interface CPUWindowController : NSObject +{ +@private + IBOutlet NSWindow *window; + IBOutlet RegisterFormCell *sr; + IBOutlet RegisterFormCell *l; + IBOutlet RegisterFormCell *ac; + IBOutlet RegisterFormCell *pc; + IBOutlet RegisterFormCell *sc; + IBOutlet RegisterFormCell *gtf; + IBOutlet RegisterFormCell *mq; + IBOutlet EnableDisableTextField *mode; + IBOutlet NSButton *a; + IBOutlet NSButton *b; + IBOutlet RegisterFormCell *df; + IBOutlet RegisterFormCell *_if; + IBOutlet RegisterFormCell *ib; + IBOutlet RegisterFormCell *uf; + IBOutlet RegisterFormCell *ub; + IBOutlet RegisterFormCell *sf; + IBOutlet NSButton *enable; + IBOutlet NSButton *delay; + IBOutlet NSButton *inhibit; + IBOutlet PDP8 *pdp8; + float normalContentHeight; +} + +- (IBAction) eaeModeButtonClick:(id)sender; +- (IBAction) enableCheckboxClicked:(id)sender; +- (IBAction) delayCheckboxClicked:(id)sender; +- (IBAction) inhibitCheckboxClicked:(id)sender; + +@end diff --git a/CPUWindow/CPUWindowController.m b/CPUWindow/CPUWindowController.m new file mode 100644 index 0000000..6300f8a --- /dev/null +++ b/CPUWindow/CPUWindowController.m @@ -0,0 +1,461 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * CPUWindowController.m - Controller for the CPU window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "CPUWindowController.h" +#import "MainController.h" +#import "PDP8.h" +#import "RegisterFormCell.h" +#import "GeneralPreferences.h" +#import "Unicode.h" + + +@implementation CPUWindowController + + +#define STOP_TOOLBAR_ITEM_IDENTIFIER @"stopTBItemIdentifier" +#define GO_TOOLBAR_ITEM_IDENTIFIER @"goTBItemIdentifier" +#define TRACE_TOOLBAR_ITEM_IDENTIFIER @"traceTBItemIdentifier" +#define STEP_TOOLBAR_ITEM_IDENTIFIER @"stepTBItemIdentifier" +#define BREAKPOINT_TOOLBAR_ITEM_IDENTIFIER @"breakpointTBItemIdentifier" +#define BOOTSTRAP_TOOLBAR_ITEM_IDENTIFIER @"bootstrapTBItemIdentifier" +#define RESET_TOOLBAR_ITEM_IDENTIFIER @"resetTBItemIdentifier" +#define MEMORYINSPECTOR_TOOLBAR_ITEM_IDENTIFIER @"memoryInspectorTBItemIdentifier" + +#define RESIZE_WINDOW_ON_PDP8STOP_NOTIFICATION @"cpuwindowResizeOnPDP8StopNotification" +#define RESIZE_WINDOW_ON_PDP8GO_NOTIFICATION @"cpuwindowResizeOnPDP8GoNotification" + + +#pragma mark Toolbar + + +- (void) setupToolbar +{ + NSToolbar *toolbar = [[[NSToolbar alloc] initWithIdentifier:@"CPUWindowToolbar"] autorelease]; + [toolbar setAllowsUserCustomization:YES]; + [toolbar setAutosavesConfiguration:YES]; + [toolbar setDisplayMode: NSToolbarDisplayModeIconOnly]; + [toolbar setSizeMode:NSToolbarSizeModeSmall]; + [toolbar setDelegate:self]; + [window setToolbar:toolbar]; + [window setShowsToolbarButton:YES]; +} + + +- (NSToolbarItem *) toolbar:(NSToolbar *)toolbar itemForItemIdentifier:(NSString *)itemIdent + willBeInsertedIntoToolbar:(BOOL) willBeInserted +{ + NSToolbarItem *toolbarItem = [[[NSToolbarItem alloc] + initWithItemIdentifier:itemIdent] autorelease]; + + if ([itemIdent isEqual:STOP_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedString(@"Stop", @"")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Stop", @"")]; + [toolbarItem setToolTip:NSLocalizedString( + @"Stops the running PDP-8/E", @"")]; + [toolbarItem setImage:[NSImage imageNamed:@"stopToolbarIcon"]]; + [toolbarItem setTarget:[NSApp delegate]]; + [toolbarItem setAction:@selector(stop:)]; + } else if ([itemIdent isEqual:GO_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedString(@"Go", @"")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Go", @"")]; + [toolbarItem setToolTip:NSLocalizedString( + @"Starts the simulated PDP-8/E to run continuously", @"")]; + [toolbarItem setImage:[NSImage imageNamed:@"goToolbarIcon"]]; + [toolbarItem setTarget:[NSApp delegate]]; + [toolbarItem setAction:@selector(go:)]; + } else if ([itemIdent isEqual:TRACE_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedString(@"Trace", @"")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Trace", @"")]; + [toolbarItem setToolTip:NSLocalizedString( + @"Starts the simulated PDP-8/E to run in trace mode", @"")]; + [toolbarItem setImage:[NSImage imageNamed:@"traceToolbarIcon"]]; + [toolbarItem setTarget:[NSApp delegate]]; + [toolbarItem setAction:@selector(trace:)]; + } else if ([itemIdent isEqual:STEP_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedString(@"Step", @"")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Step", @"")]; + [toolbarItem setToolTip:NSLocalizedString( + @"Executes a single PDP-8/E instruction", @"")]; + [toolbarItem setImage:[NSImage imageNamed:@"stepToolbarIcon"]]; + [toolbarItem setTarget:[NSApp delegate]]; + [toolbarItem setAction:@selector(step:)]; + } else if ([itemIdent isEqual:BREAKPOINT_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedString(@"Breakpoints", @"")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Breakpoints", @"")]; + [toolbarItem setToolTip:NSLocalizedString( + @"Shows or hides the Breakpoints & Break Opcodes Panel", @"")]; + [toolbarItem setImage:[NSImage imageNamed:@"breakpointsToolbarIcon"]]; + [toolbarItem setTarget:[NSApp delegate]]; + [toolbarItem setAction:@selector(showHideBreakpointPanel:)]; + } else if ([itemIdent isEqual:BOOTSTRAP_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedString(@"Bootstrap Loader", @"")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Bootstrap Loader", @"")]; + [toolbarItem setToolTip:NSLocalizedString( + @"Shows or hides the Bootstrap Loader Panel", @"")]; + [toolbarItem setImage:[NSImage imageNamed:@"bootstrapToolbarIcon"]]; + [toolbarItem setTarget:[NSApp delegate]]; + [toolbarItem setAction:@selector(showHideBootstrapPanel:)]; + } else if ([itemIdent isEqual:RESET_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedString(@"Reset", @"")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Reset", @"")]; + [toolbarItem setToolTip:NSLocalizedString( + @"Resets registers and memory of the PDP-8/E", @"")]; + [toolbarItem setImage:[NSImage imageNamed:@"resetToolbarIcon"]]; + [toolbarItem setTarget:[NSApp delegate]]; + [toolbarItem setAction:@selector(reset:)]; + } else if ([itemIdent isEqual:MEMORYINSPECTOR_TOOLBAR_ITEM_IDENTIFIER]) { + [toolbarItem setLabel:NSLocalizedString(@"Memory Inspector", @"")]; + [toolbarItem setPaletteLabel:NSLocalizedString(@"Memory Inspector", @"")]; + [toolbarItem setToolTip:NSLocalizedString( + @"Shows or hides the memory inspector drawer", @"")]; + [toolbarItem setImage:[NSImage imageNamed:@"memoryInspectorToolbarIcon"]]; + [toolbarItem setTarget:[NSApp delegate]]; + [toolbarItem setAction:@selector(toggleMemoryInspectorDrawer:)]; + } else + toolbarItem = nil; + return toolbarItem; +} + + +- (NSArray *) toolbarDefaultItemIdentifiers:(NSToolbar *)toolbar +{ + return [NSArray arrayWithObjects: + NSToolbarFlexibleSpaceItemIdentifier, + RESET_TOOLBAR_ITEM_IDENTIFIER, + NSToolbarSpaceItemIdentifier, + BREAKPOINT_TOOLBAR_ITEM_IDENTIFIER, BOOTSTRAP_TOOLBAR_ITEM_IDENTIFIER, + NSToolbarSpaceItemIdentifier, + STOP_TOOLBAR_ITEM_IDENTIFIER, STEP_TOOLBAR_ITEM_IDENTIFIER, + TRACE_TOOLBAR_ITEM_IDENTIFIER, GO_TOOLBAR_ITEM_IDENTIFIER, + NSToolbarSpaceItemIdentifier, + MEMORYINSPECTOR_TOOLBAR_ITEM_IDENTIFIER, + nil]; +} + + +- (NSArray *) toolbarAllowedItemIdentifiers:(NSToolbar *)toolbar +{ + return [NSArray arrayWithObjects: + STOP_TOOLBAR_ITEM_IDENTIFIER, STEP_TOOLBAR_ITEM_IDENTIFIER, + TRACE_TOOLBAR_ITEM_IDENTIFIER, GO_TOOLBAR_ITEM_IDENTIFIER, + BREAKPOINT_TOOLBAR_ITEM_IDENTIFIER, BOOTSTRAP_TOOLBAR_ITEM_IDENTIFIER, + MEMORYINSPECTOR_TOOLBAR_ITEM_IDENTIFIER, RESET_TOOLBAR_ITEM_IDENTIFIER, + NSToolbarCustomizeToolbarItemIdentifier, NSToolbarSeparatorItemIdentifier, + NSToolbarFlexibleSpaceItemIdentifier, NSToolbarSpaceItemIdentifier, + nil]; +} + + +#pragma mark Notifications + + +- (void) setupNotifications +{ + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + + [defaultCenter addObserver:self + selector:@selector(notifyResizeWindowOnPDP8Stop:) + name:RESIZE_WINDOW_ON_PDP8STOP_NOTIFICATION object:nil]; + [defaultCenter addObserver:self + selector:@selector(notifyResizeWindowOnPDP8Go:) + name:RESIZE_WINDOW_ON_PDP8GO_NOTIFICATION object:nil]; + [defaultCenter addObserver:self + selector:@selector(notifyStopPDP8:) name:PDP8_STOP_NOTIFICATION object:nil]; + [defaultCenter addObserver:self + selector:@selector(notifyTracePDP8:) name:PDP8_TRACE_NOTIFICATION object:nil]; + [defaultCenter addObserver:self + selector:@selector(notifyGoPDP8:) name:PDP8_GO_NOTIFICATION object:nil]; + + [defaultCenter addObserver:self selector:@selector(notifyEnableChanged:) + name:ENABLE_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyDelayChanged:) + name:DELAY_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyInhibitChanged:) + name:INHIBIT_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyEAEModeChanged:) + name:EAE_MODE_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyEAEMount:) + name:EAE_MOUNT_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyKM8EMount:) + name:KM8E_MOUNT_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyPreferencesChanged:) + name:NSUserDefaultsDidChangeNotification object:nil]; + + [defaultCenter addObserver:self selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; +} + + +- (void) notifyResizeWindowOnPDP8Stop:(NSNotification *)notification +{ + // NSLog (@"CPUWindowController got a notifyResizeWindowOnPDP8Stop notification"); + NSRect rect = [window frame]; + rect.size.height += normalContentHeight; + rect.origin.y -= normalContentHeight; + normalContentHeight = 0; + [window setFrame:rect display:YES animate:YES]; + [window setTitle:NSLocalizedString(@"PDP-8/E CPU", @"")]; + [[window contentView] setAutoresizesSubviews:YES]; + [[window toolbar] validateVisibleItems]; +} + + +- (void) notifyStopPDP8:(NSNotification *)notification +{ + // NSLog (@"CPUWindowController got a STOP PDP8 notification"); + // delay the resizing until all GUI elements in the CPU window and other windows are updated + [[NSNotificationQueue defaultQueue] enqueueNotification: + [NSNotification notificationWithName:RESIZE_WINDOW_ON_PDP8STOP_NOTIFICATION object:self] + postingStyle:NSPostWhenIdle]; // don't use NSPostNow or NSPostASAP, that's too fast +} + + +- (void) setGoWindowTitle +{ + NSString *title; + + switch ([[NSUserDefaults standardUserDefaults] integerForKey:GENERAL_PREFS_GO_SPEED_KEY]) { + case GO_AS_FAST_AS_POSSIBLE : + title = NSLocalizedString( + @"PDP-8/E CPU " UNICODE_EM_DASH_UTF8 " running as fast as possible", @""); + break; + case GO_WITH_PDP8_SPEED : + title = NSLocalizedString( + @"PDP-8/E CPU " UNICODE_EM_DASH_UTF8 " running with real speed", @""); + break; + case GO_WITH_PDP8_SPEED_PRECISE : + title = NSLocalizedString( + @"PDP-8/E CPU " UNICODE_EM_DASH_UTF8 " running with precise timing", @""); + break; + default : + title = @""; + NSAssert (FALSE, @"Illegal go speed in the preferences"); + break; + } + [window setTitle:title]; +} + + +- (void) notifyPreferencesChanged:(NSNotification *)notification +{ + if ([pdp8 isGoing]) + [self setGoWindowTitle]; +} + + +- (void) notifyResizeWindowOnPDP8Go:(NSNotification *)notification +{ + // NSLog (@"CPUWindowController got a notifyResizeWindowOnPDP8Go notification"); + NSRect rect = [window frame]; + normalContentHeight = [[window contentView] frame].size.height; + rect.origin.y += normalContentHeight; + rect.size.height -= normalContentHeight; + [[window contentView] setAutoresizesSubviews:NO]; + [window setFrame:rect display:YES animate:YES]; + [self setGoWindowTitle]; + [[window toolbar] validateVisibleItems]; +} + + +- (void) notifyGoPDP8:(NSNotification *)notification +{ + // NSLog (@"CPUWindowController got a GO PDP8 notification"); + // delay the resizing until all GUI elements in the CPU window and other windows are in "Go" mode + // (the memory view needs the old size to remember the visible memory area) + [[NSNotificationQueue defaultQueue] enqueueNotification: + [NSNotification notificationWithName:RESIZE_WINDOW_ON_PDP8GO_NOTIFICATION object:self] + postingStyle:NSPostASAP]; + // don't use NSPostNow, that's too fast; don't use NSPostWhenIdle, that's too slow +} + + +- (void) notifyTracePDP8:(NSNotification *)notification +{ + // NSLog (@"CPUWindowController got a TRACE PDP8 notification"); + [[window toolbar] validateVisibleItems]; +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"CPUWindowController notifyApplicationWillTerminate"); + /* When the simulator quits while the PDP-8 is running, the CPU window is shrunk, and this size + is stored in the user defaults. On the next launch, it resizes to the default height at the top + of the screen and not to the last position/size. To avoid that, resize it before quitting. */ + if (normalContentHeight) { + [window orderOut:self]; + NSRect rect = [window frame]; + rect.size.height += normalContentHeight; + rect.origin.y -= normalContentHeight; + normalContentHeight = 0; + [window setFrame:rect display:NO]; + [window saveFrameUsingName:[window frameAutosaveName]]; + } +} + + +#pragma mark Delegate Methods + + +- (NSSize) windowWillResize:(NSWindow *)sender toSize:(NSSize)newSize +{ + return normalContentHeight ? [window frame].size : newSize; +} + + +- (BOOL) windowShouldZoom:(NSWindow *)sender toFrame:(NSRect)newFrame +{ + return normalContentHeight ? NO : YES; +} + + +#pragma mark Registers + + +- (void) notifyEAEMount:(NSNotification *)notification +{ + BOOL hasEAE = [pdp8 hasEAE]; + [sc setEnabled:hasEAE]; + [gtf setEnabled:hasEAE]; + [mode setEnabled:hasEAE]; + [a setEnabled:hasEAE]; + [b setEnabled:hasEAE]; +} + + +- (IBAction) eaeModeButtonClick:(id)sender +{ + [pdp8 setEAEmode:EAE_MODE_A + [sender tag]]; +} + + +- (void) notifyEAEModeChanged:(NSNotification *)notification +{ + [a setIntValue:EAE_MODE_B - [pdp8 getEAEmode]]; + [b setIntValue:[pdp8 getEAEmode] - EAE_MODE_A]; +} + + +- (void) notifyKM8EMount:(NSNotification *)notification +{ + BOOL hasKM8E = [pdp8 hasKM8E]; + [df setEnabled:hasKM8E]; + [_if setEnabled:hasKM8E]; + [ib setEnabled:hasKM8E]; + [uf setEnabled:hasKM8E]; + [ub setEnabled:hasKM8E]; + [sf setEnabled:hasKM8E]; + [inhibit setEnabled:hasKM8E]; +} + + +- (IBAction) enableCheckboxClicked:(id)sender +{ + [pdp8 setEnable:[sender intValue]]; +} + + +- (void) notifyEnableChanged:(NSNotification *)notification +{ + [enable setIntValue:[pdp8 getEnable]]; +} + + +- (IBAction) delayCheckboxClicked:(id)sender; +{ + [pdp8 setDelay:[sender intValue]]; +} + + +- (void) notifyDelayChanged:(NSNotification *)notification +{ + [delay setIntValue:[pdp8 getDelay]]; +} + + +- (IBAction) inhibitCheckboxClicked:(id)sender; +{ + [pdp8 setInhibit:[sender intValue]]; +} + + +- (void) notifyInhibitChanged:(NSNotification *)notification +{ + [inhibit setIntValue:[pdp8 getInhibit]]; +} + + +#pragma mark Initialization + + +- (void) setupRegisters +{ + // KK8-E CPU + [sr setupRegisterFor:pdp8 getRegisterValue:@selector(getSR) setRegisterValue:@selector(setSR:) + changedNotificationName:SR_CHANGED_NOTIFICATION mask:07777 base:8]; + [l setupRegisterFor:pdp8 getRegisterValue:@selector(getL) setRegisterValue:@selector(setL:) + changedNotificationName:ACCUMULATOR_CHANGED_NOTIFICATION mask:01 base:8]; + [ac setupRegisterFor:pdp8 getRegisterValue:@selector(getAC) setRegisterValue:@selector(setAC:) + changedNotificationName:ACCUMULATOR_CHANGED_NOTIFICATION mask:07777 base:8]; + [pc setupRegisterFor:pdp8 getRegisterValue:@selector(getPC) setRegisterValue:@selector(setPC:) + changedNotificationName:PROGRAM_COUNTER_CHANGED_NOTIFICATION mask:07777 base:8]; + // KE8-E EAE + [sc setupRegisterFor:pdp8 getRegisterValue:@selector(getSC) setRegisterValue:@selector(setSC:) + changedNotificationName:SC_CHANGED_NOTIFICATION mask:037 base:8]; + [gtf setupRegisterFor:pdp8 getRegisterValue:@selector(getGTF) setRegisterValue:@selector(setGTF:) + changedNotificationName:GTF_CHANGED_NOTIFICATION mask:01 base:8]; + [mq setupRegisterFor:pdp8 getRegisterValue:@selector(getMQ) setRegisterValue:@selector(setMQ:) + changedNotificationName:MQ_CHANGED_NOTIFICATION mask:07777 base:8]; + // KM8-E Memory Extension + [df setupRegisterFor:pdp8 getRegisterValue:@selector(getDF) setRegisterValue:@selector(setDF:) + changedNotificationName:DF_CHANGED_NOTIFICATION mask:07 base:8]; + [_if setupRegisterFor:pdp8 getRegisterValue:@selector(getIF) setRegisterValue:@selector(setIF:) + changedNotificationName:PROGRAM_COUNTER_CHANGED_NOTIFICATION mask:07 base:8]; + [ib setupRegisterFor:pdp8 getRegisterValue:@selector(getIB) setRegisterValue:@selector(setIB:) + changedNotificationName:PROGRAM_COUNTER_CHANGED_NOTIFICATION mask:07 base:8]; + [uf setupRegisterFor:pdp8 getRegisterValue:@selector(getUF) setRegisterValue:@selector(setUF:) + changedNotificationName:UF_CHANGED_NOTIFICATION mask:01 base:8]; + [ub setupRegisterFor:pdp8 getRegisterValue:@selector(getUB) setRegisterValue:@selector(setUB:) + changedNotificationName:UB_CHANGED_NOTIFICATION mask:01 base:8]; + [sf setupRegisterFor:pdp8 getRegisterValue:@selector(getSF) setRegisterValue:@selector(setSF:) + changedNotificationName:SF_CHANGED_NOTIFICATION mask:0177 base:8]; +} + + +- (void) awakeFromNib +{ + [self setupToolbar]; + [self setupNotifications]; + [self setupRegisters]; + /* set max width = min width of the panel: IB only allows max width one pixel more + than min width, so the user can resize the width for one pixel - bug in IB? */ + NSSize size = [window minSize]; + size.height = [window maxSize].height; + [window setMaxSize:size]; +} + + +@end diff --git a/CPUWindow/IOFlagController.h b/CPUWindow/IOFlagController.h new file mode 100644 index 0000000..b65ca29 --- /dev/null +++ b/CPUWindow/IOFlagController.h @@ -0,0 +1,42 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * IOFlagController.h - Controller for the I/O flags table view in the CPU window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class PDP8; + + +@interface IOFlagController : NSObject +{ +@private + IBOutlet NSTableView *ioFlagsView; + IBOutlet PDP8 *pdp8; + NSMutableArray *deviceNames; + unsigned long enabledFlags; +} + +- (unsigned) numberOfAvailableFlags; +- (unsigned long) addIODevice:(NSString *)name; // returns the I/O mask for the new device or 0 on error +- (void) disableIODevice:(unsigned long)ioflag; +- (void) enableIODevice:(unsigned long)ioflag; + +@end diff --git a/CPUWindow/IOFlagController.m b/CPUWindow/IOFlagController.m new file mode 100644 index 0000000..bb7a5e5 --- /dev/null +++ b/CPUWindow/IOFlagController.m @@ -0,0 +1,199 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * IOFlagController.m - Controller for the I/O flags table view in the CPU window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "IOFlagController.h" +#import "PDP8.h" + + +#define NAME_COLUMN 0 +#define IENABLE_COLUMN 1 +#define IOFLAG_COLUMN 2 + +#define USER_MODE_ROW 0 + + +@implementation IOFlagController + + +- (void) awakeFromNib +{ + adjustTableHeaderForElCapitan (ioFlagsView); + deviceNames = [[NSMutableArray alloc] init]; + [self addIODevice:NSLocalizedString(@"User Mode", @"")]; + [[[[ioFlagsView tableColumns] objectAtIndex:NAME_COLUMN] dataCell] + setFont:[NSFont userFontOfSize:11]]; + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + [defaultCenter addObserver:self selector:@selector(notifyIOFlagsChanged:) + name:IOFLAGS_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyKM8EMount:) + name:KM8E_MOUNT_NOTIFICATION object:nil]; + /* Under certain contitions, the checkboxes in the I/O column are not activated/deactivated + when the CPU window activates/deactivates. The notifyKeyWindowChanged notification is + a workaround. Maybe a Cocoa bug with 10.4 and 10.5 (it does not appear when the table + control has the 10.5 only hilight style "sourcelist"). */ + [defaultCenter addObserver:self selector:@selector(notifyMainWindowChanged:) + name:NSWindowDidResignMainNotification object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyMainWindowChanged:) + name:NSWindowDidBecomeMainNotification object:nil]; +} + + +- (void) notifyMainWindowChanged:(NSNotification *)notification +{ + if ([[notification object] isEqualTo:[ioFlagsView window]]) + [ioFlagsView reloadData]; +} + + +- (void) notifyIOFlagsChanged:(NSNotification *)notification +{ + [ioFlagsView reloadData]; +} + + +- (void) notifyKM8EMount:(NSNotification *)notification +{ + if ([pdp8 hasKM8E]) + [self enableIODevice:userFLAG]; + else + [self disableIODevice:userFLAG]; +} + + +- (unsigned) numberOfAvailableFlags +{ + return 8 * sizeof(enabledFlags) - [deviceNames count]; +} + + +- (unsigned long) addIODevice:(NSString *)name +{ + unsigned long ioflag; + + if ([deviceNames count] == 8 * sizeof(enabledFlags)) + return 0; // all flags already allocated + [deviceNames addObject:name]; + [ioFlagsView noteNumberOfRowsChanged]; + ioflag = 1 << ([deviceNames count] - 1); + enabledFlags |= ioflag; + return ioflag; +} + + +- (void) disableIODevice:(unsigned long)ioflag +{ + NSAssert1 ((((1 << [deviceNames count]) - 1) & ioflag) == ioflag, @"Invalid IO flag: %o", ioflag); + enabledFlags &= ~ioflag; + [pdp8 clearInterruptMaskBits:ioflag]; + [pdp8 clearIOFlagBits:ioflag]; + [ioFlagsView reloadData]; +} + + +- (void) enableIODevice:(unsigned long)ioflag +{ + NSAssert1 ((((1 << [deviceNames count]) - 1) & ioflag) == ioflag, @"Invalid IO flag: %o", ioflag); + enabledFlags |= ioflag; + [ioFlagsView reloadData]; +} + + +- (int) numberOfRowsInTableView:(NSTableView *)tableView +{ + return [deviceNames count]; +} + + +- (BOOL) tableView:(NSTableView *)tableView shouldSelectRow:(int)row +{ + return ((1 << row) & enabledFlags) != 0; +} + + +- (id) tableView:(NSTableView *)tableView + objectValueForTableColumn:(NSTableColumn *)column row:(int)row +{ + switch ([[column identifier] intValue]) { + case NAME_COLUMN : + if ((1 << row) & enabledFlags) + return [deviceNames objectAtIndex:row]; + // disabled devices are gray + return [[[NSAttributedString alloc] initWithString:[deviceNames objectAtIndex:row] + attributes:[NSDictionary dictionaryWithObject:[NSColor grayColor] + forKey:NSForegroundColorAttributeName]] autorelease]; + case IENABLE_COLUMN : + return [NSNumber numberWithBool:[pdp8 getInterruptMaskBits:1 << row] != 0]; + case IOFLAG_COLUMN : + return [NSNumber numberWithBool:[pdp8 getIOFlagBits:1 << row] != 0]; + } + return nil; +} + + +- (void) tableView:(NSTableView *)tableView setObjectValue:(id)val + forTableColumn:(NSTableColumn *)column row:(int)row +{ + // when the currently selected row becomes deactivated, the user can still click the check boxes + if (((1 << row) & enabledFlags) == 0) + return; + switch ([[column identifier] intValue]) { + case IENABLE_COLUMN : + if (row == USER_MODE_ROW) // can't clear or set this flag manually, + break; // it's set iff the KM8-E is present + if ([val intValue]) + [pdp8 setInterruptMaskBits:1 << row]; + else + [pdp8 clearInterruptMaskBits:1 << row]; + break; + case IOFLAG_COLUMN : + if ([val intValue]) + [pdp8 setIOFlagBits:1 << row]; + else + [pdp8 clearIOFlagBits:1 << row]; + break; + } +} + + +- (NSString *) tableView:(NSTableView *)tableView toolTipForCell:(NSCell *)cell + rect:(NSRectPointer)rect tableColumn:(NSTableColumn *)column row:(int)row + mouseLocation:(NSPoint)mouseLocation +{ + switch ([[column identifier] intValue]) { + case NAME_COLUMN : + break; + case IENABLE_COLUMN : + return NSLocalizedString(@"When the Interrupt Enable Flag is set, the " + @"corresponding device can cause interrupts.", @""); + case IOFLAG_COLUMN : + return NSLocalizedString(@"A device raises its I/O Flag to signal to the CPU " + @"that it has completed an I/O operation.", @""); + } + return nil; +} + + +@end diff --git a/CPUWindow/SkipController.h b/CPUWindow/SkipController.h new file mode 100644 index 0000000..c23eec4 --- /dev/null +++ b/CPUWindow/SkipController.h @@ -0,0 +1,38 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * SkipController.h - Controller for the skip indicator in the CPU window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class TableCornerView, PDP8; + + +@interface SkipController : NSObject +{ +@private + IBOutlet TableCornerView *view; + IBOutlet PDP8 *pdp8; + NSMutableDictionary *dictionary; +} + +- (void) addSkiptest:(NSValue *)skiptest forInstruction:(NSValue *)instruction; + +@end diff --git a/CPUWindow/SkipController.m b/CPUWindow/SkipController.m new file mode 100644 index 0000000..c416be4 --- /dev/null +++ b/CPUWindow/SkipController.m @@ -0,0 +1,174 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * SkipController.h - Controller for the skip indicator in the CPU window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "SkipController.h" +#import "TableCornerView.h" +#import "PDP8.h" +#import "mri.h" +#import "eae.h" +#import "iot.h" +#import "opr.h" + + +#define UPDATE_SKIPINDICATOR_NOTIFICATION @"updateSkipIndicatorNotification" + + +#define SKIP_IMAGE_NAME @"skipArrow" +#define INTERRUPT_IMAGE_NAME @"interruptArrow" + + +// Key Value pair for the skiptest dictionary initialization +#define KV(i, s) [NSValue valueWithPointer:s], [NSValue valueWithPointer:i] + + +typedef unsigned (*PDP8SkiptestFunctionPointer)(void); + + +@implementation SkipController + + +- (void) awakeFromNib +{ + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:MEMORY_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:PROGRAM_COUNTER_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:ACCUMULATOR_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:GTF_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:MQ_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:EAE_MODE_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:DF_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:UF_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:ENABLE_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:DELAY_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:INHIBIT_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:IOFLAGS_CHANGED_NOTIFICATION object:nil]; + [defaultCenter addObserver:self selector:@selector(notifySkipIndicator:) + name:SF_CHANGED_NOTIFICATION object:nil]; // required for TSC8 ESME + [defaultCenter addObserver:self selector:@selector(notifyUpdateSkipIndicator:) + name:UPDATE_SKIPINDICATOR_NOTIFICATION object:nil]; + /* PDP-8 notifications that probably can't change the skip/interrupt indicator: + SR_CHANGED_NOTIFICATION + SC_CHANGED_NOTIFICATION + UB_CHANGED_NOTIFICATION + SF_CHANGED_NOTIFICATION + */ + dictionary = [[NSMutableDictionary alloc] initWithObjectsAndKeys: + /* MRI skip instructions */ + KV(i2000, s2000), KV(i2200, s2200), KV(i2400, s2400), KV(i2410, s2410), + KV(i2600, s2600), KV(i2610, s2610), + /* EAE skip instructions */ + KV(i7451, s7451), + /* IOT skip instructions */ + KV(i6000, s6000), KV(i6003, s6003), KV(i6006, s6006), KV(i6254, s6254), + /* OPR skip instructions */ + KV(i7410, s7410), KV(i7412, s7410), KV(i7414, s7410), KV(i7416, s7410), + KV(i7420, s7420), KV(i7422, s7420), KV(i7424, s7420), KV(i7426, s7420), + KV(i7430, s7430), KV(i7432, s7430), KV(i7434, s7430), KV(i7436, s7430), + KV(i7440, s7440), KV(i7442, s7440), KV(i7444, s7440), KV(i7446, s7440), + KV(i7450, s7450), KV(i7452, s7450), KV(i7454, s7450), KV(i7456, s7450), + KV(i7460, s7460), KV(i7462, s7460), KV(i7464, s7460), KV(i7466, s7460), + KV(i7470, s7470), KV(i7472, s7470), KV(i7474, s7470), KV(i7476, s7470), + KV(i7500, s7500), KV(i7502, s7500), KV(i7504, s7500), KV(i7506, s7500), + KV(i7510, s7510), KV(i7512, s7510), KV(i7514, s7510), KV(i7516, s7510), + KV(i7520, s7520), KV(i7522, s7520), KV(i7524, s7520), KV(i7526, s7520), + KV(i7530, s7530), KV(i7532, s7530), KV(i7534, s7530), KV(i7536, s7530), + KV(i7540, s7540), KV(i7542, s7540), KV(i7544, s7540), KV(i7546, s7540), + KV(i7550, s7550), KV(i7552, s7550), KV(i7554, s7550), KV(i7556, s7550), + KV(i7610, s7410), KV(i7612, s7410), KV(i7614, s7410), KV(i7616, s7410), + KV(i7620, s7420), KV(i7622, s7420), KV(i7624, s7420), KV(i7626, s7420), + KV(i7630, s7430), KV(i7632, s7430), KV(i7634, s7430), KV(i7636, s7430), + KV(i7640, s7440), KV(i7642, s7440), KV(i7644, s7440), KV(i7646, s7440), + KV(i7650, s7450), KV(i7652, s7450), KV(i7654, s7450), KV(i7656, s7450), + KV(i7660, s7460), KV(i7662, s7460), KV(i7664, s7460), KV(i7666, s7460), + KV(i7670, s7470), KV(i7672, s7470), KV(i7674, s7470), KV(i7676, s7470), + KV(i7700, s7500), KV(i7702, s7500), KV(i7704, s7500), KV(i7706, s7500), + KV(i7710, s7510), KV(i7712, s7510), KV(i7714, s7510), KV(i7716, s7510), + KV(i7720, s7520), KV(i7722, s7520), KV(i7724, s7520), KV(i7726, s7520), + KV(i7730, s7530), KV(i7732, s7530), KV(i7734, s7530), KV(i7736, s7530), + KV(i7740, s7540), KV(i7742, s7540), KV(i7744, s7540), KV(i7746, s7540), + KV(i7750, s7550), KV(i7752, s7550), KV(i7754, s7550), KV(i7756, s7550), + KV(i7760, s7560), KV(i7762, s7560), KV(i7764, s7560), KV(i7766, s7560), + KV(i7770, s7570), KV(i7772, s7570), KV(i7774, s7570), KV(i7776, s7570), + nil + ]; +} + + +- (void) notifySkipIndicator:(NSNotification *)notification +{ + /* coalesc the multiple ..._CHANGED_NOTIFICATIONS to one UPDATE_SKIPINDICATOR_NOTIFICATION + to avoid time consuming repeated updates */ + // NSLog (@"notifySkipIndicator"); + [[NSNotificationQueue defaultQueue] enqueueNotification: + [NSNotification notificationWithName:UPDATE_SKIPINDICATOR_NOTIFICATION object:self] + postingStyle:NSPostASAP coalesceMask:NSNotificationCoalescingOnName forModes:nil]; +} + + +- (void) notifyUpdateSkipIndicator:(NSNotification *)notification +{ + // NSLog (@"SkipController notifyUpdateSkipIndicator"); + NSAssert (! [pdp8 isGoing], @"PDP-8 is running"); + if ([pdp8 getEnable] && ([pdp8 getIOFlagBits:~0] & [pdp8 getInterruptMaskBits:~0]) && + ! ([pdp8 getDelay] || [pdp8 getInhibit])) + [view setImageNamed:INTERRUPT_IMAGE_NAME toolTip: + NSLocalizedString(@"An interrupt is pending", @"")]; + else { + NSValue *skipfunc = [dictionary objectForKey: + [NSValue valueWithPointer:[pdp8 getNextInstruction]]]; + if (skipfunc) { + if (((PDP8SkiptestFunctionPointer)[skipfunc pointerValue])()) + [view setImageNamed:SKIP_IMAGE_NAME toolTip: + NSLocalizedString(@"The next instruction will be skipped", @"")]; + else + [view setImageNamed:nil toolTip:nil]; + } else + [view setImageNamed:nil toolTip:nil]; + } +} + + +- (void) addSkiptest:(NSValue *)skiptest forInstruction:(NSValue *)instruction +{ + if (skiptest && [skiptest pointerValue] && instruction && [instruction pointerValue]) + [dictionary setObject:skiptest forKey:instruction]; +} + + +@end diff --git a/Categories/FileDropControlTargetProtocol.h b/Categories/FileDropControlTargetProtocol.h new file mode 100644 index 0000000..361ad94 --- /dev/null +++ b/Categories/FileDropControlTargetProtocol.h @@ -0,0 +1,35 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * FileDropControlTargetProtocol.h - Protocol to support file drop controls + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +/* When a NSControl is registered as a file drop destination (via [FileDrop registerAsFileDropTarget:]), + the target of the control must implement the FileDragControlTarget protocol that is used to + communicate between the drag actions and the control target. */ + + +@protocol FileDropControlTarget + +- (BOOL) willAcceptFile:(NSString *)path; // check if file is allowed to be dropped +- (BOOL) acceptFile:(NSString *)path; // actually perform the drop action, return success status + +@end diff --git a/Categories/NSControl+FileDrop.h b/Categories/NSControl+FileDrop.h new file mode 100644 index 0000000..2a4b437 --- /dev/null +++ b/Categories/NSControl+FileDrop.h @@ -0,0 +1,30 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSControl+FileDrop.h - Category to support file drop for controls + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface NSControl (FileDrop) + +- (void) registerAsFileDropTarget; +- (void) unregisterAsFileDropTarget; + +@end diff --git a/Categories/NSControl+FileDrop.m b/Categories/NSControl+FileDrop.m new file mode 100644 index 0000000..b66b9e1 --- /dev/null +++ b/Categories/NSControl+FileDrop.m @@ -0,0 +1,71 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSControl+FileDrop.m - Category to support file drop for controls + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "NSControl+FileDrop.h" +#import "FileDropControlTargetProtocol.h" +#import "NSFileManager+Additions.h" + + +@implementation NSControl (FileDrop) + + +- (void) registerAsFileDropTarget +{ + [self registerForDraggedTypes:[NSArray arrayWithObject:NSFilenamesPboardType]]; +} + + +- (void) unregisterAsFileDropTarget +{ + [self unregisterDraggedTypes]; +} + + +- (NSDragOperation) draggingEntered:(id )sender +{ + NSAssert ([[self target] conformsToProtocol:@protocol(FileDropControlTarget)], + @"Control target does not conform to the DragDropControlTarget protocol"); + if (! [self isEnabled]) + return NSDragOperationNone; + if (([sender draggingSourceOperationMask] & NSDragOperationGeneric) != NSDragOperationGeneric) + return NSDragOperationNone; + NSArray *paths = [[sender draggingPasteboard] propertyListForType:NSFilenamesPboardType]; + if ([paths count] != 1) // HIG: don't accept a drag with more than one allowed item + return NSDragOperationNone; + if (! [[self target] willAcceptFile:[paths objectAtIndex:0]]) + return NSDragOperationNone; + return NSDragOperationCopy; +} + + +- (BOOL) performDragOperation:(id )sender +{ + return [[self target] acceptFile:[[NSFileManager defaultManager] resolveAliasPath: + [[[sender draggingPasteboard] propertyListForType:NSFilenamesPboardType] objectAtIndex:0]]]; +} + + +@end diff --git a/Categories/NSFileManager+Additions.h b/Categories/NSFileManager+Additions.h new file mode 100644 index 0000000..6e9653c --- /dev/null +++ b/Categories/NSFileManager+Additions.h @@ -0,0 +1,32 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSFileManager+Additions.h - Additional functions for file management + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface NSFileManager (Additions) + +- (BOOL) fsRef:(FSRef *)fsRef forPath:(NSString *)path; +- (NSString *) pathResolved:(NSString *)path; // resolved path, returns nil on failure +- (BOOL) isAliasPath:(NSString *)inPath; +- (NSString *) resolveAliasPath:(NSString *)path; // resolved path, returns original path on failure + +@end diff --git a/Categories/NSFileManager+Additions.m b/Categories/NSFileManager+Additions.m new file mode 100644 index 0000000..79fd46c --- /dev/null +++ b/Categories/NSFileManager+Additions.m @@ -0,0 +1,150 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSFileManager+Additions.h - Additional functions for file management + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "utilities.h" +#import "NSFileManager+Additions.h" + + +/* declarations from Mac OS X 10.6 CFURL.h to dynamically load und call new APIs while building + with the Mac OS X 10.4 SDK */ + +#import + +typedef struct __CFError *CFErrorRef; +typedef CFOptionFlags CFURLBookmarkResolutionOptions; + +enum { + kCFBookmarkResolutionWithoutUIMask = ( 1UL << 8 ), + // don't perform any UI during bookmark resolution + kCFBookmarkResolutionWithoutMountingMask = ( 1UL << 9 ), + // don't mount a volume during bookmark resolution +}; + +static CFDataRef (*CFURLCreateBookmarkDataFromFile) (CFAllocatorRef allocator, + CFURLRef fileURL, CFErrorRef *errorRef); +static CFURLRef (*CFURLCreateByResolvingBookmarkData) (CFAllocatorRef allocator, + CFDataRef bookmark, CFURLBookmarkResolutionOptions options, CFURLRef relativeToURL, + CFArrayRef resourcePropertiesToInclude, Boolean* isStale, CFErrorRef* error); + + +/* + NSFileManager: Resolve an alias + Original Source: + (See copyright notice at ) + + The old Alias Manager functions are depecated since Mac OS 10.8 and no longer work with OS X 10.10. + The CFURL Bookmark functions are available since Mac OS 10.6. Because we build against the + Mac OS X 10.4 SDK, we call them dynamically. For the new code, see + http://stackoverflow.com/questions/21244781 +*/ + + +@implementation NSFileManager (Additions) + + +- (BOOL) fsRef:(FSRef *)fsRef forPath:(NSString *)path +{ + BOOL ok = NO; + CFURLRef url = CFURLCreateWithFileSystemPath(NULL, (CFStringRef) path, kCFURLPOSIXPathStyle, NO); + if (url) { + ok = CFURLGetFSRef(url, fsRef); + CFRelease (url); + } + return ok; +} + + +- (NSString *) pathResolvedNew:(NSString *)path +// This code runs with Mac OS 10.6 and better; the dlsym() is only required until we build with newer SDKs +{ + if (CFURLCreateBookmarkDataFromFile == NULL) + CFURLCreateBookmarkDataFromFile = dlsym(RTLD_NEXT, "CFURLCreateBookmarkDataFromFile"); + if (CFURLCreateByResolvingBookmarkData == NULL) + CFURLCreateByResolvingBookmarkData = dlsym(RTLD_NEXT, "CFURLCreateByResolvingBookmarkData"); + CFStringRef resolvedPath = nil; + CFURLRef url = CFURLCreateWithFileSystemPath(NULL, (CFStringRef) path, kCFURLPOSIXPathStyle, NO); + if (url != NULL) { + CFErrorRef *err = nil; + CFDataRef bookmark = CFURLCreateBookmarkDataFromFile(NULL, url, err); + if (bookmark != NULL) { + CFURLRef resolvedurl = CFURLCreateByResolvingBookmarkData(NULL, bookmark, + kCFBookmarkResolutionWithoutUIMask, NULL, NULL, NO, err); + if (resolvedurl != NULL) { + resolvedPath = CFURLCopyFileSystemPath(resolvedurl, kCFURLPOSIXPathStyle); + CFRelease (resolvedurl); + } + } + CFRelease (url); + } + return [((NSString *) resolvedPath) autorelease]; +} + + +- (NSString *) pathResolvedOld:(NSString *)path +// This code runs with Mac OS 10.4 to 10.9, it is deprecated since Mac OS 10.8, it doesn't work with Yosemite +{ + CFStringRef resolvedPath = nil; + CFURLRef url = CFURLCreateWithFileSystemPath(NULL, (CFStringRef) path, kCFURLPOSIXPathStyle, NO); + if (url != NULL) { + FSRef fsRef; + if (CFURLGetFSRef(url, &fsRef)) { + Boolean targetIsFolder, wasAliased; + if (FSResolveAliasFile(&fsRef, true, &targetIsFolder, &wasAliased) == noErr && + wasAliased) { + CFURLRef resolvedurl = CFURLCreateFromFSRef(NULL, &fsRef); + if (resolvedurl != NULL) { + resolvedPath = CFURLCopyFileSystemPath(resolvedurl, + kCFURLPOSIXPathStyle); + CFRelease (resolvedurl); + } + } + } + CFRelease (url); + } + return [((NSString *) resolvedPath) autorelease]; +} + + +- (NSString *) pathResolved:(NSString *)path +{ + return runningOnSnowLeopardOrNewer() ? [self pathResolvedNew:path] : [self pathResolvedOld:path]; +} + + +- (BOOL) isAliasPath:(NSString *)path +{ + return [self pathResolved:path] != nil; +} + + +- (NSString *) resolveAliasPath:(NSString *)path +{ + NSString *resolved = [self pathResolved:path]; + return resolved ? resolved : path; +} + + +@end diff --git a/Categories/NSMutableArray+BinarySearch.h b/Categories/NSMutableArray+BinarySearch.h new file mode 100644 index 0000000..2b2d90b --- /dev/null +++ b/Categories/NSMutableArray+BinarySearch.h @@ -0,0 +1,30 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSMutableArray+BinarySearch.h - Category for binary search + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface NSMutableArray (BinarySearch) + +- (unsigned) addObject:(id)object toArraySortedBy:(SEL)compare replaceExistingObject:(BOOL)replace; +- (unsigned) indexOfObject:(id)object inArraySortedBy:(SEL)compare; + +@end diff --git a/Categories/NSMutableArray+BinarySearch.m b/Categories/NSMutableArray+BinarySearch.m new file mode 100644 index 0000000..e82343d --- /dev/null +++ b/Categories/NSMutableArray+BinarySearch.m @@ -0,0 +1,96 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSMutableArray+BinarySearch.m - Category for binary search + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "NSMutableArray+BinarySearch.h" + + +@implementation NSMutableArray (BinarySearch) + + +- (unsigned) addObject:(id)object toArraySortedBy:(SEL)compare replaceExistingObject:(BOOL)replace +{ + int n = [self count]; + if (n == 0) { + [self addObject:object]; + return 0; + } + NSRange range = NSMakeRange(0, n); + while (range.length > 0) { + unsigned m = range.location + range.length / 2; + switch ((NSComparisonResult) + [[self objectAtIndex:m] performSelector:compare withObject:object]) { + case NSOrderedAscending: + n = range.location + range.length; + range.location = m + 1; + range.length = n - range.location; + break; + case NSOrderedDescending: + range.length = m - range.location; + break; + case NSOrderedSame: + if (replace) + [self replaceObjectAtIndex:m withObject:object]; + return m; + default: + NSAssert (FALSE, @"Invalid comparison result"); + break; + } + } + [self insertObject:object atIndex:range.location]; + return range.location; +} + + +- (unsigned) indexOfObject:(id)object inArraySortedBy:(SEL)compare; +{ + int n = [self count]; + if (n == 0) + return NSNotFound; + NSRange range = NSMakeRange(0, n); + while (range.length > 0) { + unsigned m = range.location + range.length / 2; + switch ((NSComparisonResult) + [[self objectAtIndex:m] performSelector:compare withObject:object]) { + case NSOrderedAscending: + n = range.location + range.length; + range.location = m + 1; + range.length = n - range.location; + break; + case NSOrderedDescending: + range.length = m - range.location; + break; + case NSOrderedSame: + return m; + default: + NSAssert (FALSE, @"Invalid comparison result"); + break; + } + } + return NSNotFound; +} + + +@end diff --git a/Categories/NSTableView+Scrolling.h b/Categories/NSTableView+Scrolling.h new file mode 100644 index 0000000..fb216b8 --- /dev/null +++ b/Categories/NSTableView+Scrolling.h @@ -0,0 +1,29 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSTableView+Scrolling.m - Category with additional scrolling methods + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface NSTableView (Scrolling) + +- (void) scrollRowToTop:(int)row; + +@end diff --git a/Categories/NSTableView+Scrolling.m b/Categories/NSTableView+Scrolling.m new file mode 100644 index 0000000..3206f14 --- /dev/null +++ b/Categories/NSTableView+Scrolling.m @@ -0,0 +1,53 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSTableView+Scrolling.m - Category with additional scrolling methods + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "NSTableView+Scrolling.h" +#import "Utilities.h" + + +@implementation NSTableView (Scrolling) + + +- (void) scrollRowToTop:(int)row +{ + NSClipView *clipView = (NSClipView *) [self superview]; + if (clipView) { + NSRect rowRect = [self rectOfRow:row]; + if (runningOnElCapitanOrNewer()) + rowRect.origin.y -= rowRect.size.height; + NSPoint newOrigin = [self convertPoint:rowRect.origin toView:clipView]; + [clipView scrollToPoint:newOrigin]; + NSScrollView *scrollView = (NSScrollView *) [clipView superview]; + if (scrollView) + [scrollView reflectScrolledClipView:clipView]; + } +} + + +@end + + + diff --git a/Categories/NSThread+MainThread.h b/Categories/NSThread+MainThread.h new file mode 100644 index 0000000..e031f6d --- /dev/null +++ b/Categories/NSThread+MainThread.h @@ -0,0 +1,29 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSThread+MainThread.h - Category for [NSThread isMainThread], not available with the 10.4 SDK + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface NSThread (MainThread) + ++ (BOOL) isMainThread; + +@end diff --git a/Categories/NSThread+MainThread.m b/Categories/NSThread+MainThread.m new file mode 100644 index 0000000..9e2f5d6 --- /dev/null +++ b/Categories/NSThread+MainThread.m @@ -0,0 +1,39 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NSThread+MainThread.m - Category for [NSThread isMainThread], not available with the 10.4 SDK + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "NSThread+MainThread.h" + + +@implementation NSThread (MainThread) + + ++ (BOOL) isMainThread +{ + return (pthread_main_np() != 0); +} + + +@end diff --git a/Emulation/PDP8.h b/Emulation/PDP8.h new file mode 100644 index 0000000..fa28a0c --- /dev/null +++ b/Emulation/PDP8.h @@ -0,0 +1,316 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PDP8.h - The PDP-8/E Emulator Class + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class BreakpointArray; + + +#define MEMORY_CHANGED_NOTIFICATION @"pdp8MemoryChangedNotification" +#define PROGRAM_COUNTER_CHANGED_NOTIFICATION @"pdp8PCChangedNotification" +#define ACCUMULATOR_CHANGED_NOTIFICATION @"pdp8LACChangedNotification" +#define SR_CHANGED_NOTIFICATION @"pdp8SRChangedNotification" +#define SC_CHANGED_NOTIFICATION @"pdp8SCChangedNotification" +#define GTF_CHANGED_NOTIFICATION @"pdp8GTFChangedNotification" +#define MQ_CHANGED_NOTIFICATION @"pdp8MQChangedNotification" +#define EAE_MODE_CHANGED_NOTIFICATION @"pdp8EAEModeChangedNotification" +#define DF_CHANGED_NOTIFICATION @"pdp8DFChangedNotification" +#define UF_CHANGED_NOTIFICATION @"pdp8UFChangedNotification" +#define UB_CHANGED_NOTIFICATION @"pdp8UBChangedNotification" +#define SF_CHANGED_NOTIFICATION @"pdp8SFChangedNotification" +#define ENABLE_CHANGED_NOTIFICATION @"pdp8EnableChangedNotification" +#define DELAY_CHANGED_NOTIFICATION @"pdp8DelayChangedNotification" +#define INHIBIT_CHANGED_NOTIFICATION @"pdp8InhibitChangedNotification" +#define IOFLAGS_CHANGED_NOTIFICATION @"pdp8IOFlagsChangedNotification" + +#define EAE_MOUNT_NOTIFICATION @"pdp8EAEMountNotification" +#define KM8E_MOUNT_NOTIFICATION @"pdp8KM8EMountNotification" + +#define CLEAR_ALL_FLAGS_NOTIFICATION @"pdp8ClearAllFlagsNotification" + +#define PDP8_STEP_NOTIFICATION @"pdp8StepNotification" +#define PDP8_TRACE_NOTIFICATION @"pdp8TraceNotification" +#define PDP8_GO_NOTIFICATION @"pdp8GoNotification" +#define PDP8_STOP_NOTIFICATION @"pdp8StopNotification" + + +#define PDP8_FIELDSIZE 0010000 /* size of a 4K PDP-8 memory field */ +#define PDP8_MEMSIZE 0100000 /* maximal PDP-8 memory size is 32K */ +#define PDP8_IOADDRS 0100 /* number of I/O addresses: 6xx? */ + +#define EAE_MODE_A 'A' /* values for pdp8->eaeMode */ +#define EAE_MODE_B 'B' + +#define userFLAG 1ul /* hard coded user mode flag (see IOFlagController) */ + +#define STOPPED 0 /* for state.running */ +#define GOING 1 +#define TRACING 2 +#define RUNNING (GOING | TRACING) + +#define GO_AS_FAST_AS_POSSIBLE 0 /* for state.goSpeed, setGoSpeed: and getGoSpeed */ +#define GO_WITH_PDP8_SPEED 1 +#define GO_WITH_PDP8_SPEED_PRECISE 2 + +#define NO_STOP_ADDRESS -1 /* for trace: and go: without stop address */ + + +typedef unsigned long ulong; +typedef void (*PDP8InstructionFunctionPointer)(void); + + +/* Structure with information about the optional devices currently simulated */ +typedef struct { + ushort memsize; /* memory size in 12-bit words - Data Break I/O devices must know + this value to avoid writing into non-existing PDP-8 memory */ + BOOL hasEAE; /* the simulated hardware has an EAE */ + BOOL hasKM8E; /* the simulated hardware has an KM8-E */ + BOOL hasKM8Etimesharing; /* the time sharing jumper of the KM8-E is present */ +} HW; + + +/* Registers of the TSC8-75 board are kept within the PDP-8 class */ +typedef struct { + ulong flag; /* interrupt mask of the TSC8-75 (0 when TSC8-75 not present) */ + ushort eriot; /* last instruction (IOT, JMP, JMS) that caused an user mode trap */ + ushort ertb; /* address of last JMP or JMS that caused an user mode trap */ + ushort ecdf; /* set when a CDF is executed in user mode, cleared by ECDF or ESME */ + ushort esmeEnabled; /* TSC8-75 supports the ESME mode, i. e. the IOT 6365 */ +} TSC8_75; + + +/* Structure with information about the internal state of the PDP-8/E emulation */ +typedef struct { + ushort running; /* STOPPED, TRACING or GOING */ + BOOL halted; /* YES iff the HALT or SINGSTEP key of the KC8-EA console is pressed */ + ushort currInst; /* code of current PDP-8 instruction, the functions */ + /* implementing the PDP-8 instructions can inspect this */ + ulong executionTime; /* every PDP-8 instruction must add to this value the execution */ + /* time (in 0.1 microseconds) of the instruction */ + /* for IOTs of I/O devices implemented by plugins these are: */ + /* 12 (1.2 microseconds) for IOTs of devices directly attached to */ + /* the OMNIBUS; */ + /* for devices attached via the KA8-E Positive I/O Bus Interface: */ + /* 12 (1.2 microseconds) for IOTs ending in 0 */ + /* 26 (2.6 microseconds) for IOTs ending in 1, 2 or 4 */ + /* 36 (3.6 microseconds) for IOTs ending in 3, 5 or 6 */ + /* 46 (4.6 microseconds) for IOTs ending in 7 */ + /* use the macro EXECUTION_TIME() for this purpose */ + uint64_t absoluteTime; /* Mach kernel absolut time corresponding to PDP-8 executionTime */ + int goSpeed; /* GO_AS_FAST_AS_POSSIBLE, GO_WITH_PDP8_SPEED, GO_WITH_PDP8_SPEED_PRECISE */ + ulong usecTraceDelay; /* delay (in microseconds) between two instructions in trace mode */ + void *pluginPointer[PDP8_IOADDRS]; /* for each I/O address, a pointer pointing to the plugin */ +} STATE; + + +@interface PDP8 : NSObject { +@public +/* The attributes are public, so the C functions implementing the PDP-8 instructions can + access them directly. No other Cocoa code should use them directly. To ensure this, + the register names are mapped to dummy names with the #defines below. In the source + code files with the instruction C functions, #define USE_PDP8_REGISTERS_DIRECTLY + to make the registers available. */ + +/* Registers of the PDP-8/E CPU */ + ushort SR; + ushort AC; /* including L flag */ + ushort PC; + ushort SC; + ushort MQ; + ushort GTF; + ushort IF; /* W: for write access to nonexisting memory */ + ushort IB, W_IB; /* W_IB == IB when memory exists, */ + ushort DF, W_DF; /* W_IB == 0100000 when memory does not exist */ + /* write accesses to current IF are only by JMS, */ + /* but then IB is used, so no W_IF needed. */ + /* dto. for DF, W_DF */ + /* field registers are 0n0000 for field n (0 <= n <= 7) */ + ushort UF; + ushort UB; /* UF, UB is 000000 or 010000 */ + ushort SF; + ushort IENABLE; + ushort IINHIBIT; + ushort IDELAY; + ulong IMASK; + ulong IOFLAGS; + char eaeMode; /* 'A' - Mode A, 'B' - Mode B */ + ushort mem[PDP8_MEMSIZE + PDP8_FIELDSIZE]; /* 9th field for non-existing core */ + +/* additional attributes */ + TSC8_75 _tsc8; + HW _hw; + STATE _state; + +@private + IBOutlet BreakpointArray *breakpoints; + IBOutlet BreakpointArray *breakopcodes; + char bp[PDP8_MEMSIZE]; + NSMutableDictionary *saveopcodes; +} + + +- (void) mountEAE:(BOOL)mount; // mount or unmount +- (BOOL) hasEAE; + +- (void) mountKM8E:(BOOL)mount memorySize:(unsigned)memsize timesharingEnabled:(BOOL)timesharing; +- (BOOL) hasKM8E; +- (BOOL) isTimesharingEnabled; +- (ushort) memorySize; // memory size in 12-bit words, e. g. 010000 for a 4K machine + +- (BOOL) isIOAddressAvailable:(int)addr; +- (void) setIOT:(NSValue *)iot forOpcode:(int)opcode; +- (void) setPluginPointer:(void *)pointer forIOAddress:(int)addr; // see PLUGIN_POINTER macro below + +- (NSString *) loadPaperTape:(NSString *)filename toField:(ushort)field; +// returns an error message; nil == everything ok + +- (void) setTraceSpeed:(double)speed; // trace with frequency of 1/speed Hz +- (void) setGoSpeed:(int)goSpeed; // see state.goSpeed and the three GO_ macros +- (int) getGoSpeed; // may change with a NSUserDefaultsDidChangeNotification + +- (void) step; +- (void) trace:(int)stopAddress; // stopAddress == -1 for no stop address +- (void) go:(int)stopAddress; +- (void) stop; // stop the running or tracing PDP-8 + +- (void) clearAllFlags; +- (void) loadExtendedAddress; +- (void) reset; + +- (BOOL) isStopped; +- (BOOL) isTracing; +- (BOOL) isGoing; +- (BOOL) isRunning; // running in trace or go mode + +- (BOOL) isHalted; // restart is inhibited (HALT or SINGSTEP console key is up) +- (void) setHalt:(BOOL)halt; // stop and inhibit restart (for the HALT or SINGSTEP console keys) + +- (ushort) getPC; +- (void) setPC:(ushort)pc; +- (ushort) getProgramCounter; // returns IF | PC +- (void) setProgramCounter:(ushort)programCounter; // sets IB, IF and PC +- (ushort) getIF; +- (void) setIF:(ushort)_if; +- (ushort) getIB; +- (void) setIB:(ushort)ib; +- (ushort) getDF; +- (void) setDF:(ushort)df; +- (ushort) getUF; +- (void) setUF:(ushort)uf; +- (ushort) getUB; +- (void) setUB:(ushort)ub; +- (ushort) getSF; +- (void) setSF:(ushort)sf; +- (ushort) getSR; +- (void) setSR:(ushort)sr; +- (ushort) getL; +- (void) setL:(ushort)l; +- (ushort) getAC; +- (void) setAC:(ushort)ac; +- (ushort) getLAC; +- (void) setLAC:(ushort)lac; +- (ushort) getSC; +- (void) setSC:(ushort)sc; +- (ushort) getGTF; +- (void) setGTF:(ushort)gtf; +- (ushort) getMQ; +- (void) setMQ:(ushort)mq; +- (char) getEAEmode; +- (void) setEAEmode:(char)mode; +- (ushort) getEnable; +- (void) setEnable:(ushort)enable; +- (ushort) getDelay; +- (void) setDelay:(ushort)delay; +- (ushort) getInhibit; +- (void) setInhibit:(ushort)inhibit; +- (ulong) getInterruptMaskBits:(ulong)bitmask; +- (void) setInterruptMaskBits:(ulong)bitmask; +- (void) clearInterruptMaskBits:(ulong)bitmask; +- (ulong) getIOFlagBits:(ulong)bitmask; +- (void) setIOFlagBits:(ulong)bitmask; +- (void) clearIOFlagBits:(ulong)bitmask; +- (BOOL) interruptRequest; +- (ushort) memoryAt:(int)address; +- (ushort) memoryAtNext:(int)address; +- (ushort *) directMemoryAccess; // pointer to the PDP-8 memory, only for Data Break I/O devices +- (void) directMemoryWriteFinished; // call this method when the memory modifying Data Break is finished +- (void) setMemoryAtAddress:(int)address toValue:(int)value; +- (void) setMemoryAtNextAddress:(int)address toValue:(int)value; +- (void) setMemoryAtAddress:(int)address toValues:(NSArray *)values withMask:(BOOL)withMask; +- (void) clearMemory; + +- (ushort) getCurrentOpcode; +- (PDP8InstructionFunctionPointer) getNextInstruction; + +- (ushort) getTSC8ertb; +- (void) setTSC8ertb:(ushort)ertb; +- (ushort) getTSC8eriot; +- (void) setTSC8eriot:(ushort)eriot; +- (ushort) getTSC8ecdf; +- (void) setTSC8ecdf:(ushort)ecdf; +- (ulong) getTSC8flag; +- (void) setTSC8flag:(ulong)flag; +- (BOOL) getTSC8esmeEnabled; +- (void) setTSC8esmeEnabled:(BOOL)enabled; + + +#if ! defined(NS_BLOCK_ASSERTIONS) +- (id) pluginPointer:(Class)pluginClass; // with assertion; see PLUGIN_POINTER macro below +#endif + +@end + + +#if USE_PDP8_REGISTERS_DIRECTLY +extern PDP8 *pdp8; +#define EXECUTION_TIME(time) (pdp8->_state.executionTime += (time)) +#if defined(NS_BLOCK_ASSERTIONS) +#define PLUGIN_POINTER(plugin) ((plugin *) pdp8->_state.pluginPointer[(pdp8->_state.currInst >> 3) & 077]) +#else +#define PLUGIN_POINTER(plugin) ((plugin *) [pdp8 pluginPointer:[plugin class]]) +#endif +#else +#define SR __dont_use_SR__ +#define AC __dont_use_AC__ +#define PC __dont_use_PC__ +#define SC __dont_use_SC__ +#define MQ __dont_use_MQ__ +#define GTF __dont_use_GTF__ +#define IF __dont_use_IF__ +#define IB __dont_use_IB__ +#define W_IB __dont_use_W_IB__ +#define DF __dont_use_DF__ +#define W_DF __dont_use_W_DF__ +#define UF __dont_use_UF__ +#define UB __dont_use_UB__ +#define SF __dont_use_SF__ +#define IENABLE __dont_use_IENABLE__ +#define IINHIBIT __dont_use_IINHIBIT__ +#define IDELAY __dont_use_IDELAY__ +#define IMASK __dont_use_IMASK__ +#define IOFLAGS __dont_use_IOFLAGS__ +#define eaeMode __dont_use_eaeMode__ +#define mem __dont_use_mem__ +#define _tsc8 __dont_use_tsc8__ +#define _hw __dont_use_hw__ +#define _state __dont_use_state__ +#endif diff --git a/Emulation/PDP8.m b/Emulation/PDP8.m new file mode 100644 index 0000000..9aedbd3 --- /dev/null +++ b/Emulation/PDP8.m @@ -0,0 +1,1345 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PDP8.m - The PDP-8/E Emulator Class + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import +#import +#import + +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#import "PDP8.h" +#import "itab.h" +#import "eae.h" +#import "iot.h" +#import "opr.h" +#import "Breakpoint.h" +#import "BreakpointArray.h" +#import "Utilities.h" +#import "PluginAPI.h" +#import "NSThread+MainThread.h" + + +#define PDP8_PREFS_KEY @"PDP-8/E" + +#define CODER_KEY_HAS_EAE @"EAE" +#define CODER_KEY_HAS_KM8E @"KM8E" +#define CODER_KEY_MEMSIZE @"MEMSIZE" +#define CODER_KEY_TIMESHARING @"TIMESHARING" +#define CODER_KEY_SR @"SR" +#define CODER_KEY_LAC @"LAC" +#define CODER_KEY_PC @"PC" +#define CODER_KEY_SC @"SC" +#define CODER_KEY_MQ @"MQ" +#define CODER_KEY_GTF @"GTF" +#define CODER_KEY_IF @"IF" +#define CODER_KEY_IB @"IB" +#define CODER_KEY_DF @"DF" +#define CODER_KEY_UF @"UF" +#define CODER_KEY_UB @"UB" +#define CODER_KEY_SF @"SF" +#define CODER_KEY_ENABLE @"ENABLE" +#define CODER_KEY_INHIBIT @"INHIBIT" +#define CODER_KEY_DELAY @"DELAY" +#define CODER_KEY_USERMASK @"USERMASK" +#define CODER_KEY_USERFLAG @"USERFLAG" +#define CODER_KEY_EAEMODE @"EAEMODE" +#define CODER_KEY_MEMORY @"MEMORY" + + +PDP8 *pdp8; /* the one and only instance of the PDP8 class, only used by the opcode C functions */ + + +@implementation PDP8 + + +#pragma mark Hardware Configuration + + +- (void) mountEAEforced:(BOOL)mount // mount or unmount anyway (used only on startup) +{ + static void (*eaetab[])(void) = { + i7401, i7403, i7405, i7407, i7411, i7413, i7415, i7417, + i7421, i7423, i7425, i7427, i7431, i7433, i7435, i7437, + i7441, i7443, i7445, i7447, i7451, i7453, i7455, i7457, + i7461, i7463, i7465, i7467, i7471, i7473, i7475, i7477, + i7501, i7503, i7505, i7507, i7511, i7513, i7515, i7517, + i7521, i7523, i7525, i7527, i7531, i7533, i7535, i7537, + i7541, i7543, i7545, i7547, i7551, i7553, i7555, i7557, + i7561, i7563, i7565, i7567, i7571, i7573, i7575, i7577, + i7601, i7603, i7605, i7607, i7611, i7613, i7615, i7617, + i7621, i7623, i7625, i7627, i7631, i7633, i7635, i7637, + i7641, i7643, i7645, i7647, i7651, i7653, i7655, i7657, + i7661, i7663, i7665, i7667, i7671, i7673, i7675, i7677, + i7701, i7703, i7705, i7707, i7711, i7713, i7715, i7717, + i7721, i7723, i7725, i7727, i7731, i7733, i7735, i7737, + i7741, i7743, i7745, i7747, i7751, i7753, i7755, i7757, + i7761, i7763, i7765, i7767, i7771, i7773, i7775, i7777 + }; + static void (*noeaetab[])(void) = { + i7401, i7421, i7401, i7421, i7501, i7521, i7501, i7521, + i7601, i7621, i7601, i7621, i7701, i7721, i7701, i7721 + }; + + int i, j; + + _hw.hasEAE = mount; + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + if (mount) { + for (i = 07401, j = 0; i < 010000; i += 2) + itab[i] = eaetab[j++]; + for (i = 017401, j = 0; i < 020000; i += 2) + itab[i] = eaetab[j++]; + } else { + for (i = 07401, j = 0; i < 010000; i += 2) + itab[i] = noeaetab[j++ >> 3]; + for (i = 017401, j = 0; i < 020000; i += 2) + itab[i] = noeaetab[j++ >> 3]; + SC = 0; + GTF = 0; + eaeMode = EAE_MODE_A; + if (_state.running != GOING) { + [defaultCenter postNotificationName:SC_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:GTF_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:EAE_MODE_CHANGED_NOTIFICATION object:self]; + } + } + [defaultCenter postNotificationName:EAE_MOUNT_NOTIFICATION object:self]; +} + + +- (void) mountEAE:(BOOL)mount // mount only when needed (to avoid multiple executions due to notifications) +{ + if (_hw.hasEAE != mount) + [self mountEAEforced:mount];; +} + + +- (BOOL) hasEAE +{ + return _hw.hasEAE; +} + + +- (void) mountKM8Eforced:(BOOL)mount memorySize:(unsigned)memsize timesharingEnabled:(BOOL)timesharing +// mount or unmount anyway (used only on startup) +{ + static const struct { + ushort addr; + void (*inst)(void); + } km8etab[] = { + { 06201, i6201 }, { 06202, i6202 }, { 06203, i6203 }, { 06204, i6204 }, + { 06211, i6211 }, { 06212, i6212 }, { 06213, i6213 }, { 06214, i6214 }, + { 06221, i6221 }, { 06222, i6222 }, { 06223, i6223 }, { 06224, i6224 }, + { 06231, i6231 }, { 06232, i6232 }, { 06233, i6233 }, { 06234, i6234 }, + { 06241, i6241 }, { 06242, i6242 }, { 06243, i6243 }, { 06244, i6244 }, + { 06251, i6251 }, { 06252, i6252 }, { 06253, i6253 }, { 06254, i6254 }, + { 06261, i6261 }, { 06262, i6262 }, { 06263, i6263 }, { 06264, i6264 }, + { 06271, i6271 }, { 06272, i6272 }, { 06273, i6273 }, { 06274, i6274 }, + { 0, NULL } + }; + + int i; + + NSAssert ((memsize & ~0170000) == 0, @"Bad memory size"); + NSAssert ((mount && memsize > PDP8_FIELDSIZE) || memsize == PDP8_FIELDSIZE, + @"Memory size does not match KM8-E state"); + NSAssert (mount || ! timesharing, @"Timesharing option does not match KM8-E state"); + + _hw.hasKM8E = mount; + _hw.hasKM8Etimesharing = timesharing; + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + if (mount) { + for (i = 0; km8etab[i].addr; i++) + itab[km8etab[i].addr] = km8etab[i].inst; + IMASK |= userFLAG; + } else { + for (i = 0; km8etab[i].addr; i++) + itab[km8etab[i].addr] = i7000; + DF = W_DF = 0; + IF = IB = W_IB = 0; + UF = UB = 0; + SF = 0; + IINHIBIT = 0; + IMASK &= ~userFLAG; + IOFLAGS &= ~userFLAG; + if (_state.running != GOING) { + [defaultCenter postNotificationName:DF_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:PROGRAM_COUNTER_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:UF_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:UB_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:SF_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:INHIBIT_CHANGED_NOTIFICATION object:self]; + } + } + i = _hw.memsize = memsize; + W_DF = (DF < _hw.memsize) ? DF : 0100000; + W_IB = (IB < _hw.memsize) ? IB : 0100000; + while (i < 0100000) + mem[i++] = 0; + if (_state.running != GOING) { + [defaultCenter postNotificationName:IOFLAGS_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:MEMORY_CHANGED_NOTIFICATION object:self]; + } + [defaultCenter postNotificationName:KM8E_MOUNT_NOTIFICATION object:self]; +} + + +- (void) mountKM8E:(BOOL)mount memorySize:(unsigned)memsize timesharingEnabled:(BOOL)timesharing +// mount only when needed (to avoid multiple executions due to notifications) +{ + if (_hw.hasKM8E != mount || _hw.hasKM8Etimesharing != timesharing || _hw.memsize != memsize) + [self mountKM8Eforced:mount memorySize:memsize timesharingEnabled:timesharing]; +} + + +- (BOOL) hasKM8E +{ + return _hw.hasKM8E; +} + + +- (BOOL) isTimesharingEnabled +{ + return _hw.hasKM8Etimesharing; +} + + +- (ushort) memorySize +{ + return _hw.memsize; +} + + +- (BOOL) isIOAddressAvailable:(int)addr +{ + int i; + + NSAssert1 ((addr & ~077) == 0, @"Bad I/O address %o", addr); + addr = 06000 | (addr << 3); + for (i = 0; i < 8; i++) { + if (itab[addr | i] != i7000) + return NO; + } + return YES; +} + + +- (void) setIOT:(NSValue *)iot forOpcode:(int)opcode +{ + NSAssert1 ((opcode & ~0777) == 06000, @"Invalid IOT %o", opcode); + if (iot) { + PDP8InstructionFunctionPointer p = [iot pointerValue]; + if (p) + itab[opcode] = p; + } +} + + +- (void) setPluginPointer:(void *)pointer forIOAddress:(int)addr +{ + NSAssert1 ((addr & ~077) == 0, @"Bad I/O address %o", addr); + _state.pluginPointer[addr] = pointer; +} + + +#if ! defined(NS_BLOCK_ASSERTIONS) + +- (id) pluginPointer:(Class)pluginClass; +{ + id pluginPointer = _state.pluginPointer[(_state.currInst >> 3) & 077]; + NSAssert (pluginPointer && [pluginPointer isMemberOfClass:pluginClass], @"Bad plugin pointer"); + return pluginPointer; +} + +#endif + + +#pragma mark Initialization + + +- (void) notifyApplicationWillFinishLaunching:(NSNotification *)notification +{ + // NSLog (@"PDP8 notifyApplicationWillFinishLaunching"); + NSData *data = [[NSUserDefaults standardUserDefaults] dataForKey:PDP8_PREFS_KEY]; + if (data) { + NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data]; + [self initWithCoder:unarchiver]; + [unarchiver finishDecoding]; + [unarchiver release]; + } else { + [self mountEAEforced:NO]; + [self mountKM8Eforced:NO memorySize:PDP8_FIELDSIZE timesharingEnabled:NO]; + [self reset]; + } +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"PDP8 notifyApplicationWillTerminate"); + NSMutableData *data = [NSMutableData data]; + NSKeyedArchiver *archiver = [[NSKeyedArchiver alloc] initForWritingWithMutableData:data]; + [self encodeWithCoder:archiver]; + [archiver finishEncoding]; + [archiver release]; + [[NSUserDefaults standardUserDefaults] setObject:data forKey:PDP8_PREFS_KEY]; +} + + +- (void) awakeFromNib +{ + pdp8 = self; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillFinishLaunching:) + name:NSApplicationWillFinishLaunchingNotification object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; +} + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + // hardware configuration - note: redundant to prefs settings + [self mountEAEforced:[coder decodeBoolForKey:CODER_KEY_HAS_EAE]]; + [self mountKM8Eforced:[coder decodeBoolForKey:CODER_KEY_HAS_KM8E] + memorySize:[coder decodeIntForKey:CODER_KEY_MEMSIZE] + timesharingEnabled:[coder decodeBoolForKey:CODER_KEY_TIMESHARING]]; + // registers + [self setSR:[coder decodeIntForKey:CODER_KEY_SR]]; + [self setLAC:[coder decodeIntForKey:CODER_KEY_LAC]]; + [self setPC:[coder decodeIntForKey:CODER_KEY_PC]]; + [self setSC:[coder decodeIntForKey:CODER_KEY_SC]]; + [self setMQ:[coder decodeIntForKey:CODER_KEY_MQ]]; + [self setGTF:[coder decodeIntForKey:CODER_KEY_GTF]]; + [self setIF:[coder decodeIntForKey:CODER_KEY_IF]]; + [self setIB:[coder decodeIntForKey:CODER_KEY_IB]]; + [self setDF:[coder decodeIntForKey:CODER_KEY_DF]]; + [self setUF:[coder decodeIntForKey:CODER_KEY_UF]]; + [self setUB:[coder decodeIntForKey:CODER_KEY_UB]]; + [self setSF:[coder decodeIntForKey:CODER_KEY_SF]]; + [self setEnable:[coder decodeIntForKey:CODER_KEY_ENABLE]]; + [self setInhibit:[coder decodeIntForKey:CODER_KEY_INHIBIT]]; + [self setDelay:[coder decodeIntForKey:CODER_KEY_DELAY]]; + [coder decodeBoolForKey:CODER_KEY_USERMASK] ? + [self setInterruptMaskBits:userFLAG] : [self clearInterruptMaskBits:userFLAG]; + [coder decodeBoolForKey:CODER_KEY_USERFLAG] ? + [self setIOFlagBits:userFLAG] : [self clearIOFlagBits:userFLAG]; + [self setEAEmode:[coder decodeIntForKey:CODER_KEY_EAEMODE]]; + // memory + NSData *data = [coder decodeObjectForKey:CODER_KEY_MEMORY]; + unsigned long memsize = _hw.memsize * sizeof(mem[0]); + int err = uncompress((void *) mem, &memsize, [data bytes], [data length]); + if (err) + NSLog (@"PDP8 decodeWithCoder memory uncompress error %d", err); + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + // hardware configuration - note: redundant to prefs settings + [coder encodeBool:[self hasEAE] forKey:CODER_KEY_HAS_EAE]; + [coder encodeBool:[self hasKM8E] forKey:CODER_KEY_HAS_KM8E]; + [coder encodeInt:[self memorySize] forKey:CODER_KEY_MEMSIZE]; + [coder encodeBool:[self isTimesharingEnabled] forKey:CODER_KEY_TIMESHARING]; + // registers + [coder encodeInt:[self getSR] forKey:CODER_KEY_SR]; + [coder encodeInt:[self getLAC] forKey:CODER_KEY_LAC]; + [coder encodeInt:[self getPC] forKey:CODER_KEY_PC]; + [coder encodeInt:[self getSC] forKey:CODER_KEY_SC]; + [coder encodeInt:[self getMQ] forKey:CODER_KEY_MQ]; + [coder encodeInt:[self getGTF] forKey:CODER_KEY_GTF]; + [coder encodeInt:[self getIF] forKey:CODER_KEY_IF]; + [coder encodeInt:[self getIB] forKey:CODER_KEY_IB]; + [coder encodeInt:[self getDF] forKey:CODER_KEY_DF]; + [coder encodeInt:[self getUF] forKey:CODER_KEY_UF]; + [coder encodeInt:[self getUB] forKey:CODER_KEY_UB]; + [coder encodeInt:[self getSF] forKey:CODER_KEY_SF]; + [coder encodeInt:[self getEnable] forKey:CODER_KEY_ENABLE]; + [coder encodeInt:[self getInhibit] forKey:CODER_KEY_INHIBIT]; + [coder encodeInt:[self getDelay] forKey:CODER_KEY_DELAY]; + [coder encodeBool:[self getInterruptMaskBits:userFLAG] ? YES : NO forKey:CODER_KEY_USERMASK]; + [coder encodeBool:[self getIOFlagBits:userFLAG] ? YES : NO forKey:CODER_KEY_USERFLAG]; + [coder encodeInt:[self getEAEmode] forKey:CODER_KEY_EAEMODE]; + // memory + unsigned long datasize = compressBound(_hw.memsize * sizeof(mem[0])); + NSMutableData *data = [NSMutableData dataWithLength:datasize]; + int err = compress2([data mutableBytes], &datasize, (void *) mem, + _hw.memsize * sizeof(mem[0]), Z_BEST_COMPRESSION); + if (err) + NSLog (@"PDP8 encodeWithCoder memory compress2 error %d", err); + [data setLength:datasize]; + [coder encodeObject:data forKey:CODER_KEY_MEMORY]; +} + + +#pragma mark Utilities + + +- (NSString *) loadPaperTape:(NSString *)filename toField:(ushort)field +/* this code is based on a very careful analysis of the PDP-8 BIN loader */ +{ + ushort c, x, oldchecksum; + + NSAssert1 ((field & ~07) == 0, @"Bad memory field 0%o", field); + x = oldchecksum = 0; /* to avoid compiler "used uninitialized" warning */ + field <<= 12; + if (field >= _hw.memsize) + return NSLocalizedString(@"Cannot load code to non-existing memory field.", @""); + FILE *fp = fopen([filename cStringUsingEncoding:NSASCIIStringEncoding], "r"); + if (! fp) + return NSLocalizedString(@"Cannot open the paper tape for reading.", @""); + ushort origin = 0; + ushort checksum = 0; + BOOL isRimTape = TRUE; + BOOL lastWordWasOrigin = FALSE; + for (c = 0200; c == 0200 && ! feof(fp); c = getc(fp)) /* leader */ + ; + while (c != 0200 && ! feof(fp)) { + if ((c & 0300) == 0300) { /* field setting */ + if (c != 0377) { /* all holes punched are ignored */ + isRimTape = FALSE; /* RIM cannot have field setting */ + field = ((ushort) (c & 070)) << 9; + if (field >= _hw.memsize) + field = 0100000u; + /* field setting are not included in the checksum */ + } + c = getc(fp); + } else if ((c & 0300) == 0100) { /* origin */ + lastWordWasOrigin = TRUE; + origin = (c & 077) << 6; + oldchecksum = checksum; + checksum += c; + c = getc(fp); + origin += c; + checksum += c; + c = getc(fp); + } else { /* value to deposit in memory */ + if (! lastWordWasOrigin) + isRimTape = FALSE; + lastWordWasOrigin = FALSE; + x = (c & 077) << 6; + oldchecksum = checksum; + checksum += c; + c = getc(fp); + x += c; + checksum += c; + c = getc(fp); + if ((c != 0200 && ! feof(fp)) || isRimTape) { + mem[field | origin] = x; + origin = (origin + 1) & 07777; + } + } + } + [[NSNotificationCenter defaultCenter] + postNotificationName:MEMORY_CHANGED_NOTIFICATION object:self]; + while (c == 0200 && ! feof(fp)) + c = getc(fp); + if (! feof(fp)) { + fclose (fp); + return NSLocalizedString(@"There is something wrong with the paper tape, " + @"maybe garbage before leader or after trailer.", @""); + } + fclose (fp); + if (! isRimTape && (oldchecksum & 07777) != (lastWordWasOrigin ? origin : x)) + return NSLocalizedString(@"The paper tape contains a checksum error.", @""); + return nil; +} + + +- (void) notifyEverythingChanged +{ + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + + [defaultCenter postNotificationName:PROGRAM_COUNTER_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:ACCUMULATOR_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:SR_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:SC_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:GTF_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:MQ_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:EAE_MODE_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:DF_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:UF_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:UB_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:SF_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:ENABLE_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:DELAY_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:INHIBIT_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:IOFLAGS_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:MEMORY_CHANGED_NOTIFICATION object:self]; +} + + +- (void) clearAllFlags +{ + [self setLAC:0]; + [self setEnable:0]; + [self setInhibit:0]; + [self setDelay:0]; + [self clearInterruptMaskBits:~userFLAG]; + [self clearIOFlagBits:~0]; + [self setEAEmode:EAE_MODE_A]; + [self setGTF:0]; + int i; + for (i = 0; i < PDP8_IOADDRS; i++) { + if (_state.pluginPointer[i]) + [(PDP8Plugin *) _state.pluginPointer[i] clearAllFlags:i]; + } + [[NSNotificationCenter defaultCenter] postNotificationName:CLEAR_ALL_FLAGS_NOTIFICATION object:self]; +} + + +- (void) loadExtendedAddress +{ + if (_hw.hasKM8E) { + [self setIB:(SR & 070) >> 3]; + [self setIF:(SR & 070) >> 3]; + [self setDF:SR & 007]; + [self setUB:0]; + [self setUF:0]; + [self clearIOFlagBits:userFLAG]; + } +} + + +- (void) reset +{ + [self setProgramCounter:0200]; + [self setLAC:0]; + [self setSR:0]; + [self setSC:0]; + [self setMQ:0]; + [self setGTF:0]; + [self setDF:0]; + [self setUF:0]; + [self setUB:0]; + [self setSF:0]; + [self setEAEmode:EAE_MODE_A]; + [self setEnable:0]; + [self setDelay:0]; + [self setInhibit:0]; + [self clearInterruptMaskBits:~userFLAG]; + [self clearIOFlagBits:~0]; + [self clearMemory]; +} + + +#pragma mark Step - Trace - Go + + +- (void) setTraceSpeed:(double)speed +{ + _state.usecTraceDelay = (unsigned) (speed * 1000000.0); +} + + +- (void) setGoSpeed:(int)goSpeed +{ + NSAssert (goSpeed == GO_AS_FAST_AS_POSSIBLE || goSpeed == GO_WITH_PDP8_SPEED || + goSpeed == GO_WITH_PDP8_SPEED_PRECISE, @"Illegal go speed specififed"); + /* reset the timer - required when the PDP-8 runs while this method is called */ + _state.executionTime = 0; + _state.absoluteTime = mach_absolute_time(); + _state.goSpeed = goSpeed; +} + + +- (int) getGoSpeed +{ + return _state.goSpeed; +} + + +- (BOOL) isStopped +{ + return _state.running == STOPPED; +} + + +- (BOOL) isTracing +{ + return _state.running == TRACING; +} + + +- (BOOL) isGoing; +{ + return _state.running == GOING; +} + + +- (BOOL) isRunning +{ + return _state.running != STOPPED; +} + + +- (BOOL) isHalted +{ + return _state.halted; +} + + +- (void) setHalt:(BOOL)halt +{ + if (halt) + [self stop]; + _state.halted = halt; +} + + +static void breakInstruction (void) /* used for break opcodes */ +{ + pdp8->_state.running = STOPPED; + pdp8->PC--; +} + + +- (void) setupBreakpoints:(int)stopAddress +{ + NSEnumerator *enumerator; + Breakpoint *next; + + NSAssert (stopAddress == -1 || (stopAddress & ~077777) == 0, @"Invalid stop address"); + + // breakpoints + enumerator = [breakpoints enumerator]; + bzero (bp, sizeof(bp)); + while ((next = (Breakpoint *)[enumerator nextObject])) + bp[[next identifier]] = [next value]; + if (stopAddress >= 0) + bp[stopAddress] = BREAKPOINT; + + // break opcodes + NSAssert (saveopcodes == nil, @"saveopcodes not nil"); + saveopcodes = [[NSMutableDictionary alloc] init]; + enumerator = [breakopcodes enumerator]; + while ((next = (Breakpoint *)[enumerator nextObject])) { + unsigned opcode = [next identifier]; + if ([next value] & USERMODE_BREAKOPCODE) { + [saveopcodes setObject:[NSValue valueWithPointer:itab[opcode]] + forKey:[NSNumber numberWithInt:opcode]]; + itab[opcode] = breakInstruction; + } + if ([next value] & SYSTEMMODE_BREAKOPCODE) { + opcode |= 010000; + [saveopcodes setObject:[NSValue valueWithPointer:itab[opcode]] + forKey:[NSNumber numberWithInt:opcode]]; + itab[opcode] = breakInstruction; + } + } +} + + +- (void) resetBreakpoints +{ + NSNumber *next; + + NSEnumerator *enumerator = [saveopcodes keyEnumerator]; + while ((next = (NSNumber *)[enumerator nextObject])) + itab[[next intValue]] = [[saveopcodes objectForKey:next] pointerValue]; + [saveopcodes release]; + saveopcodes = nil; +} + + +- (void) sendStopNotification // must run on main thread +{ + NSAssertRunningOnMainThread (); + [[NSNotificationCenter defaultCenter] postNotificationName:PDP8_STOP_NOTIFICATION object:self]; + [self notifyEverythingChanged]; +} + + +- (void) oneRunLoopPass +{ + NSAssertRunningOnMainThread (); + [[NSRunLoop currentRunLoop] limitDateForMode:NSDefaultRunLoopMode]; +} + + +- (void) pdp8Step +{ + /* Check for interrupts */ + if (IENABLE && (IOFLAGS & IMASK) && ! (IDELAY || IINHIBIT)) { + mem[0] = PC; + PC = 1; + SF = (UF >> 6) | (IF >> 9) | (DF >> 12); + W_IB = IB = IF = W_DF = DF = UB = UF = IENABLE = 0; + EXECUTION_TIME (14); /* count the execute cycle of JMS 0 */ + } else { + IDELAY = 0; + /* Fetch and execute an instruction */ + itab[UF | (_state.currInst = mem[IF | PC])](); + /* Update the program counter */ + if (++PC & 010000) + PC &= 07777; + } +} + + +- (void) sendStepNotifications +{ + NSAssertRunningOnMainThread (); + [[NSNotificationCenter defaultCenter] postNotificationName:PDP8_STEP_NOTIFICATION object:self]; + [self notifyEverythingChanged]; +} + + +- (void) step +{ + NSAssert (_state.running == STOPPED, @"PDP-8 not stopped"); + [self pdp8Step]; + [self sendStepNotifications]; +} + + +- (void) traceThread:(NSNumber *)stopAddress +{ + struct timeval tv0, tv1; + struct timezone tz; + + NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; + BOOL installBreakpoints = TRUE; + [NSThread setThreadPriority:0]; + // low priority for the trace thread, so the main thread can process user interactions + _state.running = TRACING; + while (_state.running) { + gettimeofday (&tv0, &tz); + [self pdp8Step]; + [self performSelectorOnMainThread:@selector(sendStepNotifications) + withObject:nil waitUntilDone:YES]; + if (installBreakpoints) { // one step without breakpoints + [self setupBreakpoints:[stopAddress intValue]]; + installBreakpoints = FALSE; + } + if (bp[IF | PC]) + _state.running = STOPPED; + else if (_state.running) { + /* Give the main thread the chance to handle events. When tracing with full + speed (state.usecTraceDelay == 0), on dual core machines, the trace thread + calls the step method so fast on the main thread that it can't handle user + events. */ + [self performSelectorOnMainThread:@selector(oneRunLoopPass) + withObject:nil waitUntilDone:YES]; + gettimeofday (&tv1, &tz); + timersub (&tv1, &tv0, &tv0); + if (_state.usecTraceDelay > (ulong) tv0.tv_usec) + usleep (_state.usecTraceDelay - tv0.tv_usec); + } + } + [self resetBreakpoints]; + [self performSelectorOnMainThread:@selector(sendStopNotification) + withObject:nil waitUntilDone:YES]; + [pool release]; +} + + +- (void) trace:(int)stopAddress +{ + NSAssert (_state.running == STOPPED, @"PDP-8 not stopped"); + NSAssert (! _state.halted, @"PDP8 trace while halted"); + if (_state.halted) + [self step]; + else { + [[NSNotificationCenter defaultCenter] postNotificationName:PDP8_TRACE_NOTIFICATION object:self]; + [NSThread detachNewThreadSelector:@selector(traceThread:) toTarget:self + withObject:[NSNumber numberWithInt:stopAddress]]; + } +} + + +- (void) goThread:(id)object +{ + NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; + // _state.running = GOING; // already set, see comment below in the go method + _state.executionTime = 0; + _state.absoluteTime = mach_absolute_time(); + while (_state.running) { + [self pdp8Step]; + /* Check for breakpoints */ + if (bp[IF | PC]) + _state.running = STOPPED; + /* Realtime speed */ + if (_state.goSpeed != GO_AS_FAST_AS_POSSIBLE) { + uint64_t delayUntilAbsolute = _state.absoluteTime + + nanoseconds2absolute(_state.executionTime * 100l); + if (_state.goSpeed == GO_WITH_PDP8_SPEED_PRECISE) { + // precise timing: delay after each PDP-8 instruction using busy waiting + // this delay takes about 0.1 microseconds longer than required + // (precision in the order of 0.1 PDP-8 instructions) + while (mach_absolute_time() < delayUntilAbsolute) + ; + } else if (mach_absolute_time() + nanoseconds2absolute(15000l) < delayUntilAbsolute) { + // PDP-8 speed without precise timing: delay when a forerun of at least + // 15 microseconds has accumulated (to avoid high kernel load on slower Macs) + // mach_wait_until() delays about 10 microseconds longer than required + // (precision in the order of about some dozen PDP-8 instructions) + mach_wait_until (delayUntilAbsolute); + } + // consider the time lag due to too long delays for the next loop + _state.absoluteTime = delayUntilAbsolute; + _state.executionTime = 0; + } + } + [self resetBreakpoints]; + [self performSelectorOnMainThread:@selector(sendStopNotification) + withObject:nil waitUntilDone:YES]; + [pool release]; +} + + +- (void) go:(int)stopAddress +{ + NSAssert (_state.running == STOPPED, @"PDP-8 not stopped"); + NSAssert (! _state.halted, @"PDP-8 trace while halted"); + if (_state.halted) + [self step]; + else { + /* set GOING right now, otherwise [self pdp8Step] might post GUI notifications + (e. g. IOFLAGS_CHANGED_NOTIFICATION via the CAF instruction) that are processed later + when the CPU is already running, and that can cause a crash, e. g. with the skip + indicator update */ + _state.running = GOING; + [self pdp8Step]; // one step without breakpoints and without GUI notifications + [self setupBreakpoints:stopAddress]; + [[NSNotificationCenter defaultCenter] postNotificationName:PDP8_GO_NOTIFICATION object:self]; + [NSThread detachNewThreadSelector:@selector(goThread:) toTarget:self withObject:nil]; + } +} + + +- (void) stop +{ + _state.running = STOPPED; +} + + +#pragma mark Register Access + + +#define NOTIFY(notification) if (_state.running != GOING && [NSThread isMainThread]) { \ + [[NSNotificationCenter defaultCenter] \ + postNotificationName:(notification) object:self]; \ + } + + +- (ushort) getPC +{ + return PC; +} + + +- (void) setPC:(ushort)pc +{ + NSAssert1 ((pc & ~07777) == 0, @"Bad PC: 0%o", pc); + PC = pc; + NOTIFY (PROGRAM_COUNTER_CHANGED_NOTIFICATION); +} + + +- (ushort) getProgramCounter +{ + return IF | PC; +} + + +- (void) setProgramCounter:(ushort)programCounter +{ + NSAssert1 ((programCounter & ~077777) == 0, @"Bad IF|PC: 0%o", programCounter); + NSAssert1 (programCounter < 010000 || _hw.hasKM8E, @"Can't set IF|PC to field %o without KM8-E", + programCounter >> 12); + IB = IF = programCounter & 070000; + PC = programCounter & 007777; + NOTIFY (PROGRAM_COUNTER_CHANGED_NOTIFICATION); +} + + +- (ushort) getIF +{ + return IF >> 12; +} + + +- (void) setIF:(ushort)_if +{ + NSAssert1 ((_if & ~07) == 0, @"Bad IF: 0%o", _if); + IF = _if << 12; + NOTIFY (PROGRAM_COUNTER_CHANGED_NOTIFICATION); +} + + +- (ushort) getIB +{ + return IB >> 12; +} + + +- (void) setIB:(ushort)ib +{ + NSAssert1 ((ib & ~07) == 0, @"Bad IB: 0%o", ib); + W_IB = IB = ib << 12; + if (W_IB >= _hw.memsize) + W_IB = 0100000; + NOTIFY (PROGRAM_COUNTER_CHANGED_NOTIFICATION); +} + + +- (ushort) getDF +{ + return DF >> 12; +} + + +- (void) setDF:(ushort)df +{ + NSAssert1 ((df & ~07) == 0, @"Bad DF: 0%o", df); + W_DF = DF = df << 12; + if (W_DF >= _hw.memsize) + W_DF = 0100000; + NOTIFY (DF_CHANGED_NOTIFICATION); +} + + +- (ushort) getUF +{ + return UF >> 12; +} + + +- (void) setUF:(ushort)uf +{ + NSAssert1 ((uf & ~01) == 0, @"Bad UF: 0%o", uf); + UF = uf << 12; + NOTIFY (UF_CHANGED_NOTIFICATION); +} + + +- (ushort) getUB +{ + return UB >> 12; +} + + +- (void) setUB:(ushort)ub +{ + NSAssert1 ((ub & ~01) == 0, @"Bad UB: %o", ub); + UB = ub << 12; + NOTIFY (UB_CHANGED_NOTIFICATION); +} + + +- (ushort) getSF +{ + return SF; +} + + +- (void) setSF:(ushort)sf +{ + NSAssert1 ((sf & ~0177) == 0, @"Bad SF: 0%o", sf); + SF = sf; + NOTIFY (SF_CHANGED_NOTIFICATION); +} + + +- (ushort) getSR +{ + return SR; +} + + +- (void) setSR:(ushort)sr +{ + NSAssert1 ((sr & ~077777) == 0, @"Bad SR: 0%o", sr); + SR = sr; + NOTIFY (SR_CHANGED_NOTIFICATION); +} + + +- (ushort) getL +{ + return AC >> 12; +} + + +- (void) setL:(ushort)l +{ + NSAssert1 ((l & ~01) == 0, @"Bad Link: 0%o", l); + AC = (l << 12) | (AC & 07777); + NOTIFY (ACCUMULATOR_CHANGED_NOTIFICATION); +} + + +- (ushort) getAC +{ + return AC & 07777; +} + + +- (void) setAC:(ushort)ac +{ + NSAssert1 ((ac & ~07777) == 0, @"Bad AC: 0%o", ac); + AC = (AC & 010000) | ac; + NOTIFY (ACCUMULATOR_CHANGED_NOTIFICATION); +} + + +- (ushort) getLAC +{ + return AC; +} + + +- (void) setLAC:(ushort)lac +{ + NSAssert1 ((lac & ~017777) == 0, @"Bad L|AC: 0%o", lac); + AC = lac; + NOTIFY (ACCUMULATOR_CHANGED_NOTIFICATION); +} + + +- (ushort) getSC +{ + return SC; +} + + +- (void) setSC:(ushort)sc +{ + NSAssert1 ((sc & ~037) == 0, @"Bad SC: 0%o", sc); + SC = sc; + NOTIFY (SC_CHANGED_NOTIFICATION); +} + + +- (ushort) getGTF +{ + return GTF; +} + + +- (void) setGTF:(ushort)gtf +{ + NSAssert1 ((gtf & ~01) == 0, @"Bad GTF: 0%o", gtf); + GTF = gtf; + NOTIFY (GTF_CHANGED_NOTIFICATION); +} + + +- (ushort) getMQ +{ + return MQ; +} + + +- (void) setMQ:(ushort)mq +{ + NSAssert1 ((mq & ~07777) == 0, @"Bad MQ: 0%o", mq); + MQ = mq; + NOTIFY (MQ_CHANGED_NOTIFICATION); +} + + +- (char) getEAEmode +{ + return eaeMode; +} + + +- (void) setEAEmode:(char)mode +{ + NSAssert1 (mode == 'A' || mode == 'B', @"Bad EAE mode: %c", mode); + eaeMode = mode; + NOTIFY (EAE_MODE_CHANGED_NOTIFICATION); +} + + +- (ushort) getEnable +{ + return IENABLE; +} + + +- (void) setEnable:(ushort)enable +{ + NSAssert1 ((enable & ~01) == 0, @"Bad Interrupt Enable Flag: 0%o", enable); + IENABLE = enable; + NOTIFY (ENABLE_CHANGED_NOTIFICATION); +} + + +- (ushort) getDelay +{ + return IDELAY; +} + + +- (void) setDelay:(ushort)delay +{ + NSAssert1 ((delay & ~01) == 0, @"Bad Interrupt Delay Flag: 0%o", delay); + IDELAY = delay; + NOTIFY (DELAY_CHANGED_NOTIFICATION); +} + + +- (ushort) getInhibit +{ + return IINHIBIT; +} + + +- (void) setInhibit:(ushort)inhibit +{ + NSAssert1 ((inhibit & ~01) == 0, @"Bad Interrupt Inhibit Flag: 0%o", inhibit); + IINHIBIT = inhibit; + NOTIFY (INHIBIT_CHANGED_NOTIFICATION); +} + + +- (ulong) getInterruptMaskBits:(ulong)bitmask +{ + return IMASK & bitmask; +} + + +- (void) setInterruptMaskBits:(ulong)bitmask +{ + IMASK |= bitmask; + NOTIFY (IOFLAGS_CHANGED_NOTIFICATION); +} + + +- (void) clearInterruptMaskBits:(ulong)bitmask +{ + IMASK &= ~bitmask; + NOTIFY (IOFLAGS_CHANGED_NOTIFICATION); +} + + +- (ulong) getIOFlagBits:(ulong)bitmask +{ + return IOFLAGS & bitmask; +} + + +- (void) setIOFlagBits:(ulong)bitmask +{ + IOFLAGS |= bitmask; + NOTIFY (IOFLAGS_CHANGED_NOTIFICATION); +} + + +- (void) clearIOFlagBits:(ulong)bitmask +{ + IOFLAGS &= ~bitmask; + NOTIFY (IOFLAGS_CHANGED_NOTIFICATION); +} + + +- (BOOL) interruptRequest +{ + return (IOFLAGS & IMASK) ? YES : NO; +} + + +#pragma mark Memory Access + + +- (ushort) memoryAt:(int)address +{ + NSAssert1 ((address & ~077777) == 0, @"Bad address: 0%o", address); + NSAssert2 ((mem[address] & ~07777) == 0, + @"Bad memory content: pdp8.mem[%5.5o] = 0%o", address, mem[address]); + return mem[address]; +} + + +- (ushort) memoryAtNext:(int)address +{ + NSAssert1 ((address & ~077777) == 0, @"Bad address: 0%o", address); + NSAssert2 ((mem[(address & 070000) | ((address + 1) & 07777)] & ~07777) == 0, + @"Bad memory content: pdp8.mem[%5.5o] = 0%o", + (address & 070000) | ((address + 1) & 07777), + mem[(address & 070000) | ((address + 1) & 07777)]); + return mem[(address & 070000) | ((address + 1) & 07777)]; +} + + +- (ushort *) directMemoryAccess +{ + return mem; +} + + +- (void) notifyMemoryChanged +{ + NSAssertRunningOnMainThread (); + NSAssert (_state.running != GOING, @"PDP-8 is running"); + [[NSNotificationCenter defaultCenter] postNotificationName:(MEMORY_CHANGED_NOTIFICATION) object:self]; +} + + +- (void) directMemoryWriteFinished +{ + if (_state.running != GOING) + [self performSelectorOnMainThread:@selector(notifyMemoryChanged) + withObject:nil waitUntilDone:YES]; +} + + +- (void) setMemoryAtAddress:(int)address toValue:(int)value +{ + NSAssert1 ((address & ~077777) == 0, @"Bad address: 0%o", address); + NSAssert1 (address < _hw.memsize, @"Address out of available memory: 0%o", address); + NSAssert2 ((value & ~07777) == 0, @"Bad value 0%o for pdp8.mem[%5.5o]", value, address); + mem[address] = value; + NOTIFY (MEMORY_CHANGED_NOTIFICATION); +} + + +- (void) setMemoryAtNextAddress:(int)address toValue:(int)value +{ + NSAssert1 ((address & ~077777) == 0, @"Bad address: 0%o", address); + NSAssert2 ((value & ~07777) == 0, @"Bad value 0%o for pdp8.mem[%5.5o]", + value, (address & 070000) | ((address + 1) & 07777)); + NSAssert1 (address < _hw.memsize, @"Address out of available memory: 0%o", address); + mem[(address & 070000) | ((address + 1) & 07777)] = value; + NOTIFY (MEMORY_CHANGED_NOTIFICATION); +} + + +- (void) setMemoryAtAddress:(int)address toValues:(NSArray *)values withMask:(BOOL)withMask +{ + int i; + + int count = [values count]; + NSAssert (values, @"values is nil"); + NSAssert1 ((address & ~077777) == 0, @"Bad start address: 0%o", address); + NSAssert1 (((address + count - 1) & ~077777) == 0, @"Bad end address: 0%o", address + count - 1); + NSAssert1 ((address + count - 1) < _hw.memsize, + @"End address out of available memory: 0%o", address); + for (i = 0; i < count; i++) { + int value = [[values objectAtIndex:i] intValue]; + NSAssert2 ((value & ~(withMask ? 077777777 : 07777)) == 0, + @"Bad mask/value 0%o for pdp8.mem[%5.5o]", value, address + i); + int mask = withMask ? (value >> 12) : 07777; + mem[address + i] = (mem[address + i] & ~mask) | (value & mask); + } + NOTIFY (MEMORY_CHANGED_NOTIFICATION); +} + + +- (void) clearMemory +{ + bzero (mem, sizeof(mem)); + NOTIFY (MEMORY_CHANGED_NOTIFICATION); +} + + +- (ushort) getCurrentOpcode +{ + return _state.currInst; +} + + +- (PDP8InstructionFunctionPointer) getNextInstruction +{ + NSAssert (_state.running != GOING, @"PDP-8 is running"); + _state.currInst = mem[IF | PC]; // the skiptest function may use the PLUGIN_POINTER() macro + return itab[UF | mem[IF | PC]]; +} + + +#pragma mark TSC8-75 + + +- (ushort) getTSC8ertb +{ + return _tsc8.ertb; +} + + +- (void) setTSC8ertb:(ushort)ertb +{ + NSAssert1 ((ertb & ~07777) == 0, @"Bad ERTB: %o", ertb); + _tsc8.ertb = ertb; +} + + +- (ushort) getTSC8eriot +{ + return _tsc8.eriot; +} + + +- (void) setTSC8eriot:(ushort)eriot +{ + NSAssert1 ((eriot & ~07777) == 0, @"Bad ERIOT: %o", eriot); + _tsc8.eriot = eriot; + NOTIFY (IOFLAGS_CHANGED_NOTIFICATION); // ESME might change its skip behaviour on new ERIOT +} + + +- (ushort) getTSC8ecdf +{ + return _tsc8.ecdf; +} + + +- (void) setTSC8ecdf:(ushort)ecdf +{ + NSAssert1 ((ecdf & ~01) == 0, @"Bad ECDF: %o", ecdf); + _tsc8.ecdf = ecdf; + NOTIFY (IOFLAGS_CHANGED_NOTIFICATION); // ESME might change its skip behaviour on new ECDF +} + +- (ulong) getTSC8flag +{ + return _tsc8.flag; +} + + +- (void) setTSC8flag:(ulong)flag +{ + _tsc8.flag = flag; +} + + +- (BOOL) getTSC8esmeEnabled +{ + return _tsc8.esmeEnabled; +} + + +- (void) setTSC8esmeEnabled:(BOOL)enabled +{ + _tsc8.esmeEnabled = enabled; + NOTIFY (IOFLAGS_CHANGED_NOTIFICATION); // ESME might change its skip behaviour when enabled +} + + +@end diff --git a/Emulation/eae.c b/Emulation/eae.c new file mode 100644 index 0000000..37fceb4 --- /dev/null +++ b/Emulation/eae.c @@ -0,0 +1,1255 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * eae.c - EAE instructions code for the PDP-8/E + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Operate microinstruction (OPR) module to handle EAE instructions. + * + * Questions: + */ + + +#import + +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#include "PDP8.h" +#include "eae.h" +#include "pdp8defines.h" + + +/* + * Operate microinstructions + * + * | | | | + * |---|---|---|---|---|---|---|---|---| + * | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10| 11| + * | 1 |CLA|MQA| 0 |MQL| 0 | 0 | 0 | 1 | Group III + * |---|---|---|---|---|---|---|---|---| + * Sequence: 1 2 2 + * + * | | | | + * |---|---|---|---|---|---|---|---|---| + * | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10| 11| + * | 1 |CLA|MQA|SCA|MQL| | | | 1 | Group III Mode A + * |---|---|---|---|---|---|---|---|---| + * Sequence: 1 2 2 \____3____/ + * V + * 0 = NOP 4 = NMI + * 1 = SCL 5 = SHL + * 2 = MUY 6 = ASR + * 3 = DVI 7 = LSR + * + * | | | | + * |---|---|---|---|---|---|---|---|---| + * | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10| 11| + * | 1 |CLA|MQA| |MQL| | | | 1 | Group III Mode B + * |---|---|---|---|---|---|---|---|---| + * Sequence: 1 2 \ 2 / + * \_______3_______/ + * V + * 0 = NOP 10 = SCA + * 1 = ACS 11 = DAD + * 2 = MUY 12 = DST + * 3 = DVI 13 = SWBA + * 4 = NMI 14 = DPSZ + * 5 = SHL 15 = DPIC (MQL & MQA set) + * 6 = ASR 16 = DCM (MQL & MQA set) + * 7 = LSR 17 = SAM + * + * In the code below, the author refers to DPIC and DCM + * instructions without both MQL & MQA bits set as DPIC- + * and DCM- respectively (the author wonders whether he + * has implemented these odd-balls correctly). + */ +/* -------------------------------------------------------------------- */ +VOID i7401 (VOID) /* NOP Grp III */ +{ + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7403 (VOID) +{ + if (EAE == 'A') /* SCL */ + { + if (++PC & 010000) + PC &= 07777 ; + SC = (~(*(base + (IF | PC)))) & 037 ; + EXECUTION_TIME (26); + } + else /* ACS */ + { + SC = AC & 037 ; + AC &= 010000 ; + EXECUTION_TIME (12); + } +} +/* -------------------------------------------------------------------- */ +VOID i7405 (VOID) /* MUY */ +{ + REG UWORD *p ; + REG ULONG temp ; + if (++PC & 010000) + PC &= 07777 ; + p = base + (IF | PC) ; + if (EAE == 'B') + { + if ((PC & 07770) == 010 && (++*p & 010000)) + *p = 0 ; + p = base + (DF | *p) ; + EXECUTION_TIME (86); + } else + EXECUTION_TIME (74); + temp = ((ULONG) *p * MQ) + (AC & 07777) ; + AC = temp >> 12 ; /* no overflow into L can occure */ + MQ = temp & 07777 ; + SC = 014 ; +} +/* -------------------------------------------------------------------- */ +VOID i7407 (VOID) /* DVI */ +{ + REG UWORD *p ; + + if (++PC & 010000) + PC &= 07777 ; + p = base + (IF | PC) ; + if (EAE == 'B') + { + if ((PC & 07770) == 010 && (++*p & 010000)) + *p = 0 ; + p = base + (DF | *p) ; + } +/* + * Note from Bob Supnik at DEC: supnik@human.enet.dec.com + * DVI. If overflow occurs, the MQ is not changed, and the AC + * contains the original AC minus the divisor (result of first + * subtraction). + * Another note from Bob Supnik corrected the above: + * On a divide overflow, the action taken by the EAE is as follows: + * L = 1 + * AC = unchanged + * MQ = ((MQ << 1) + 1) & 07777 + * Also, the SC is 01 (normally, at end of divide, SC is 015). + * This from the EAE diagnostic. + */ + AC &= 07777 ; + if (AC < *p) /* Normal divide */ + { + REG ULONG temp = ((ULONG) AC << 12) | MQ ; + MQ = temp / *p ; + AC = temp - ((ULONG) *p * MQ) ; + SC = 015 ; + EXECUTION_TIME (EAE == 'A' ? 74 : 86); + } + else /* Divide overflow */ + { + AC |= 010000 ; + MQ = ((MQ << 1) + 1) & 07777 ; + SC = 01 ; + EXECUTION_TIME (EAE == 'A' ? 26 : 86); + } +} +/* -------------------------------------------------------------------- */ +VOID i7411 (VOID) /* NMI */ +{ +/* + * Note from Bob Supnik at DEC: supnik@human.enet.dec.com + * NMI. The hardware executes a "for" loop with these conditions: + * for (sc = 0; (AC<0> == AC<1>) && ((AC<2:11>|MQ) != 0); sc++) { + * shift link'ac'mq left 1; } + * If, at the end of normalization, the AC'MQ = 4000'0000 + * and the mode is B, AC is cleared. + */ + REG ULONG temp = ((ULONG) AC << 12) | MQ ; + + for (SC = 0 ; (temp & 040000000) == ((temp & 020000000) << 1) + && (temp & 017777777) ; SC++) + temp <<= 1 ; + if (EAE == 'B' && (temp & 077777777) == 040000000) + temp &= 0100000000 ; + AC = (temp >> 12) & 017777 ; + MQ = temp & 07777 ; + EXECUTION_TIME (15 + 3 * SC); +} +/* -------------------------------------------------------------------- */ +VOID i7413 (VOID) /* SHL */ +{ + REG INT count ; + REG ULONG temp = ((ULONG) AC << 12) | MQ ; + if (++PC & 010000) + PC &= 07777 ; + count = *(base + (IF | PC)) & 037 ; + EXECUTION_TIME (29 + 3 * count); /* A: 2.6 + 0.3 * count; B: 2.9 + 0.3 * count */ + if (EAE == 'A') + count++ ; + if (count) + temp <<= count ; + AC = (temp >> 12) & 017777 ; + MQ = temp & 07777 ; + SC = (EAE == 'B') ? 037 : 0 ; + +} +/* -------------------------------------------------------------------- */ +VOID i7415 (VOID) /* ASR */ +{ + REG INT count ; + REG LONG gtf ; + + AC = ((AC & 04000) << 1) | (AC & 07777) ; + if (++PC & 010000) + PC &= 07777 ; + count = *(base + (IF | PC)) & 037 ; + EXECUTION_TIME (29 + 3 * count); /* A: 2.6 + 0.3 * count; B: 2.9 + 0.3 * count */ + if (EAE == 'A') + count++ ; + if (count) + { + REG LONG temp = ((ULONG) AC << 12) | MQ ; + if (AC & 04000) + temp |= 0xff000000 ; + gtf = (count < 24) ? (temp & (1l << (count - 1))) : (AC & 04000) ; + if (AC & 04000) + { + while (count > 8) + { + temp = (temp >> 8) | 0xffff0000 ; + count -= 8 ; + } + } + temp >>= count ; + if (temp & 040000000) + temp |= 0100000000 ; +/* + * Note from Bob Supnik at DEC: supnik@human.enet.dec.com + * ASR, LSR. If B and count == 0, the GTF is not changed, + * rather than cleared. + */ + if (EAE == 'B') + GTF = (gtf) ? true : false ; + AC = (temp >> 12) & 017777 ; + MQ = temp & 07777 ; + } + SC = (EAE == 'B') ? 037 : 0 ; +} +/* -------------------------------------------------------------------- */ +VOID i7417 (VOID) /* LSR */ +{ + REG INT count ; + REG ULONG temp ; + + if (++PC & 010000) + PC &= 07777 ; + count = *(base + (IF | PC)) & 037 ; + EXECUTION_TIME (29 + 3 * count); /* A: 2.6 + 0.3 * count; B: 2.9 + 0.3 * count */ + if (EAE == 'A') + count++ ; + AC &= 07777 ; + temp = ((ULONG) AC << 12) | MQ ; + if (EAE == 'B' && count) + GTF = (temp >> (count - 1)) & 1; + temp >>= count ; + AC = (temp >> 12) & 07777 ; + MQ = temp & 07777 ; + SC = (EAE == 'B') ? 037 : 0 ; +} +/* -------------------------------------------------------------------- */ +VOID i7421 (VOID) /* MQL */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7423 (VOID) /* MQL SCL */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + i7403 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7425 (VOID) /* MQL MUY */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + i7405 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7427 (VOID) /* MQL DVI */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + i7407 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7431 (VOID) /* SWAB */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + EAE = 'B' ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7433 (VOID) /* MQL SHL */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + i7413 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7435 (VOID) /* MQL ASR */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + i7415 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7437 (VOID) /* MQL LSR */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + i7417 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7441 (VOID) /* SCA */ +{ + AC |= SC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7443 (VOID) +{ + REG UWORD *p ; + if (++PC & 010000) + PC &= 07777 ; + p = base + (IF | PC) ; + if (EAE == 'A') /* A: SCA SCL */ + { + AC |= SC ; + SC = (~*p) & 037 ; + EXECUTION_TIME (26); + } + else /* B: DAD */ + { + REG ULONG temp ; + REG UINT addr; + if ((PC & 07770) == 010 && (++*p & 010000)) + *p = 0 ; + addr = *p; + temp = MQ + *(base + (DF | addr)) ; + temp += ((ULONG) ((AC & 07777) + + *(base + (DF | ((addr+1) & 07777))))) << 12 ; + AC = temp >> 12 ; + MQ = temp & 07777 ; + EXECUTION_TIME (52); + } +} +/* -------------------------------------------------------------------- */ +VOID i7445 (VOID) +{ + if (EAE == 'A') /* A: SCA MUY */ + { + AC |= SC ; + i7405 () ; + } + else /* B: DST */ + { + REG UWORD *p ; + REG UINT addr; + if (++PC & 010000) + PC &= 07777 ; + p = base + (IF | PC) ; + if ((PC & 07770) == 010 && (++*p & 010000)) + *p = 0 ; + addr = *p; + *(base + (W_DF | addr)) = MQ ; + *(base + (W_DF | ((addr+1) & 07777))) = AC & 07777 ; + EXECUTION_TIME (52); + } +} +/* -------------------------------------------------------------------- */ +VOID i7447 (VOID) /* SWBA */ +{ + EAE = 'A' ; + GTF = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7451 (VOID) +{ + if (EAE == 'A') /* A: SCA NMI */ + { + AC |= SC ; + i7411 () ; + } + else /* B: DPSZ */ + { + if (!((AC & 07777) | MQ)) + ++PC ; + EXECUTION_TIME (12); + } +} +unsigned s7451 (VOID) +{ + if (EAE == 'A') /* A: SCA NMI */ + return (false); + else /* B: DPSZ */ + return (!((AC & 07777) | MQ)); +} +/* -------------------------------------------------------------------- */ +VOID i7453 (VOID) +{ + if (EAE == 'A') /* A: SCA SHL */ + { + AC |= SC ; + i7413 () ; + } + else /* B: DPIC- */ + { +/* + * Note from Bob Supnik at DEC: supnik@human.enet.dec.com + * DPIC, DCOM without SWP. The instructions use the swap to + * bring the MQ into the AC, perform step 1, swap back, + * perform step 2: + * + * + * increment/complement AC, carry out to link + * + * add link/complement and add link, carry out to link + */ + REG ULONG temp = (((ULONG) MQ << 12) | (AC & 07777)) + 1 ; + AC = temp >> 12 ; + MQ = temp & 07777 ; + EXECUTION_TIME (18); /* time of DPIC */ + } +} +/* -------------------------------------------------------------------- */ +VOID i7455 (VOID) +{ + if (EAE == 'A') /* A: SCA ASR */ + { + AC |= SC ; + i7415 () ; + } + else /* B: DCM- */ + { +/* + * Note from Bob Supnik at DEC: supnik@human.enet.dec.com + * DPIC, DCOM without SWP. The instructions use the swap to + * bring the MQ into the AC, perform step 1, swap back, + * perform step 2: + * + * + * increment/complement AC, carry out to link + * + * add link/complement and add link, carry out to link + */ + REG ULONG temp = - (((ULONG) MQ << 12) | (AC & 07777)) ; + AC = (temp >> 12) & 017777 ; + MQ = temp & 07777 ; + EXECUTION_TIME (18); /* time of DCM */ + } +} +/* -------------------------------------------------------------------- */ +VOID i7457 (VOID) +{ + if (EAE == 'A') /* A: SCA LSR */ + { + AC |= SC ; + i7417 () ; + } + else /* B: SAM */ + { +/* + * SAM code supplied by Bob Supnik at supnik@human.enet.dec.com + */ + REG INT temp = AC & 07777 ; + AC = MQ + (temp ^ 07777) + 1 ; + GTF = (temp <= MQ) ^ ((temp ^ MQ) >> 11) ; + EXECUTION_TIME (12); + } +} +/* -------------------------------------------------------------------- */ +VOID i7461 (VOID) /* MQL SCA */ +{ + MQ = AC & 07777 ; + AC &= 010000 ; + AC |= SC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7463 (VOID) /* A: MQL SCA SCL */ +{ /* B: MQL DAD */ + MQ = AC & 07777 ; + AC &= 010000 ; + i7443 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7465 (VOID) /* A: MQL SCA MUY */ +{ /* B: MQL DST */ + MQ = AC & 07777 ; + AC &= 010000 ; + i7445 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7467 (VOID) /* A: MQL SCA DVI */ +{ /* B: MQL SWBA (SWBA ignored) */ + MQ = AC & 07777 ; + AC &= 010000 ; + if (EAE == 'A') { + AC |= SC; + i7407 (); + } else + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7471 (VOID) /* A: MQL SCA NMI */ +{ /* B: MQL DPSZ */ + MQ = AC & 07777 ; + AC &= 010000 ; + i7451 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7473 (VOID) /* A: MQL SCA SHL */ +{ /* B: MQL DPIC- (7453) */ + MQ = AC & 07777 ; + AC &= 010000 ; + i7453 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7475 (VOID) /* A: MQL SCA ASR */ +{ /* B: MQL DCM- (7455) */ + MQ = AC & 07777 ; + AC &= 010000 ; + i7455 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7477 (VOID) /* A: MQL SCA LSR */ +{ /* B: MQL SAM */ + MQ = AC & 07777 ; + AC &= 010000 ; + i7457 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7501 (VOID) /* MQA */ +{ + AC |= MQ ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7503 (VOID) /* A: MQA SCL */ +{ /* B: MQA ACS */ + AC |= MQ ; + i7403 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7505 (VOID) /* MQA MUY */ +{ + AC |= MQ ; + i7405 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7507 (VOID) /* MQA DVI */ +{ + AC |= MQ ; + i7407 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7511 (VOID) /* MQA NMI */ +{ + AC |= MQ ; + i7411 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7513 (VOID) /* MQA SHL */ +{ + AC |= MQ ; + i7413 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7515 (VOID) /* MQA ASR */ +{ + AC |= MQ ; + i7415 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7517 (VOID) /* MQA LSR */ +{ + AC |= MQ ; + i7417 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7521 (VOID) /* SWP */ +{ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7523 (VOID) /* A: SWP SCL */ +{ /* B: SWP ACS */ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7403 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7525 (VOID) /* SWP MUY */ +{ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7405 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7527 (VOID) /* SWP DVI */ +{ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7407 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7531 (VOID) /* SWP NMI */ +{ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7411 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7533 (VOID) /* SWP SHL */ +{ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7413 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7535 (VOID) /* SWP ASR */ +{ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7415 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7537 (VOID) /* SWP LSR */ +{ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7417 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7541 (VOID) /* MQA SCA */ +{ + AC |= MQ ; + AC |= SC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7543 (VOID) /* A: MQA SCA SCL */ +{ /* B: MQA DAD */ + AC |= MQ ; + i7443 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7545 (VOID) /* A: MQA SCA MUY */ +{ /* B: MQA DST */ + AC |= MQ ; + i7445 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7547 (VOID) /* A: MQA SCA DVI */ +{ /* B: MQA SWBA (SWBA ignored) */ + AC |= MQ ; + if (EAE == 'A') { + AC |= SC; + i7407 (); + } else + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7551 (VOID) /* A: MQA SCA NMI */ +{ /* B: MQA DPSZ */ + AC |= MQ ; + i7451 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7553 (VOID) /* A: MQA SCA SHL */ +{ /* B: MQA DPIC- (7453) */ + AC |= MQ ; + i7453 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7555 (VOID) /* A: MQA SCA ASR */ +{ /* B: MQA DCM- (7455) */ + AC |= MQ ; + i7455 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7557 (VOID) /* A: MQA SCA LSR */ +{ /* B: MQA SAM */ + AC |= MQ ; + i7457 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7561 (VOID) /* SWP SCA */ +{ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp | SC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7563 (VOID) /* A: SWP SCA SCL */ +{ /* B: SWP DAD */ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7443 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7565 (VOID) /* A: SWP SCA MUY */ +{ /* B: SWP DST */ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7445 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7567 (VOID) /* A: SWP SCA DVI */ +{ /* B: SWP SWBA (SWBA ignored) */ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + if (EAE == 'A') { + AC |= SC; + i7407 (); + } else + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7571 (VOID) /* A: SWP SCA NMI */ +{ /* B: SWP DPSZ */ + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7451 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7573 (VOID) /* A: SWP SCA SHL */ +{ /* B: DPIC */ + if (EAE == 'A') + { + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7453 () ; + } + else + { + REG ULONG temp = (((ULONG) (AC & 07777) << 12) | MQ) + 1 ; + AC = temp >> 12 ; + MQ = temp & 07777 ; + EXECUTION_TIME (18); + } +} +/* -------------------------------------------------------------------- */ +VOID i7575 (VOID) /* A: SWP SCA ASR */ +{ /* B: DCM */ + if (EAE == 'A') + { + REG UINT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7455 () ; + } + else + { + REG ULONG temp = (((((ULONG) (AC & 07777)) << 12) | MQ) + ^ 077777777) + 1 ; + AC = (temp >> 12) & 017777 ; + MQ = temp & 07777 ; + EXECUTION_TIME (18); + } +} +/* -------------------------------------------------------------------- */ +VOID i7577 (VOID) /* A: SWP SCA LSR */ +{ /* B: SWP SAM */ + REG INT temp = MQ ; + MQ = AC & 07777 ; + AC = (AC & 010000) | temp ; + i7457 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7601 (VOID) /* CLA Grp III */ +{ + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7603 (VOID) /* CLA SCA */ +{ + AC &= 010000 ; + i7403 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7605 (VOID) /* CLA MUY */ +{ + AC &= 010000 ; + i7405 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7607 (VOID) /* CLA DVI */ +{ + AC &= 010000 ; + i7407 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7611 (VOID) /* CLA NMI */ +{ + AC &= 010000 ; + i7411 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7613 (VOID) /* CLA SHL */ +{ + AC &= 010000 ; + i7413 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7615 (VOID) /* CLA ASR */ +{ + AC &= 010000 ; + i7415 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7617 (VOID) /* CLA LSR */ +{ + AC &= 010000 ; + i7417 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7621 (VOID) /* CLA MQL */ +{ + AC &= 010000 ; + MQ = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7623 (VOID) /* CLA MQL SCL */ +{ + AC &= 010000 ; + MQ = 0 ; + i7403 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7625 (VOID) /* CLA MQL MUY */ +{ + AC &= 010000 ; + MQ = 0 ; + i7405 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7627 (VOID) /* CLA MQL DVI */ +{ + AC &= 010000 ; + MQ = 0 ; + i7407 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7631 (VOID) /* CLA MQL NMI */ +{ + AC &= 010000 ; + MQ = 0 ; + i7411 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7633 (VOID) /* CLA MQL SHL */ +{ + AC &= 010000 ; + MQ = 0 ; + i7413 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7635 (VOID) /* CLA MQL ASR */ +{ + AC &= 010000 ; + MQ = 0 ; + i7415 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7637 (VOID) /* CLA MQL LSR */ +{ + AC &= 010000 ; + MQ = 0 ; + i7417 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7641 (VOID) /* CLA SCA */ +{ + AC = (AC & 010000) | SC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7643 (VOID) /* A: CLA SCA SCL */ +{ /* B: CLA DAD */ + AC &= 010000 ; + i7443 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7645 (VOID) /* A: CLA SCA MUY */ +{ /* B: CLA DST */ + AC &= 010000 ; + i7445 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7647 (VOID) /* A: CLA SCA DVI */ +{ /* B: CLA SWBA (SWBA ignored) */ + AC &= 010000 ; + if (EAE == 'B') { + AC |= SC; + i7407 (); + } else + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7651 (VOID) /* A: CLA SCA NMI */ +{ /* B: CLA DPSZ */ + AC &= 010000 ; + i7451 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7653 (VOID) /* A: CLA SCA SHL */ +{ /* B: CLA DPIC- (7453) */ + AC &= 010000 ; + i7453 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7655 (VOID) /* A: CLA SCA ASR */ +{ /* B: CLA DCM- (7455) */ + AC &= 010000 ; + i7455 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7657 (VOID) /* A: CLA SCA LSR */ +{ /* B: CLA SAM */ + AC &= 010000 ; + i7457 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7661 (VOID) /* CLA MQL SCA */ +{ + AC = (AC & 010000) | SC ; + MQ = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7663 (VOID) /* A: CLA MQL SCA SCL */ +{ /* B: CLA MQL DAD (DLD) */ + AC &= 010000 ; + MQ = 0 ; + i7443 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7665 (VOID) /* A: CLA MQL SCA MUY */ +{ /* B: CLA MQL DST (DDZ) */ + AC &= 010000 ; + MQ = 0 ; + i7445 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7667 (VOID) /* A: CLA MQL SCA DVI */ +{ /* B: CLA MQL SWBA (SWBA ignored) */ + AC &= 010000 ; + MQ = 0 ; + if (EAE == 'A') { + AC |= SC; + i7407 (); + } else + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7671 (VOID) /* A: CLA MQL SCA NMI */ +{ /* B: CLA MQL DPSZ */ + AC &= 010000 ; + MQ = 0 ; + i7451 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7673 (VOID) /* A: CLA MQL SCA SHL */ +{ /* B: CLA MQL DPIC- (7453) */ + AC &= 010000 ; + MQ = 0 ; + i7453 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7675 (VOID) /* A: CLA MQL SCA ASR */ +{ /* B: CLA MQL DCM- (7455) */ + AC &= 010000; + MQ = 0; + i7455 (); +} +/* -------------------------------------------------------------------- */ +VOID i7677 (VOID) /* A: CLA MQL SCA LSR */ +{ /* B: CLA MQL SAM */ + AC &= 010000 ; + MQ = 0 ; + i7457 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7701 (VOID) /* CLA MQA */ +{ + AC = (AC & 010000) | MQ ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7703 (VOID) /* CLA MQA SCL */ +{ + AC = (AC & 010000) | MQ ; + i7403 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7705 (VOID) /* CLA MQA MUY */ +{ + AC = (AC & 010000) | MQ ; + i7405 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7707 (VOID) /* CLA MQA DVI */ +{ + AC = (AC & 010000) | MQ ; + i7407 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7711 (VOID) /* CLA MQA NMI */ +{ + AC = (AC & 010000) | MQ ; + i7411 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7713 (VOID) /* CLA MQA SHL */ +{ + AC = (AC & 010000) | MQ ; + i7413 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7715 (VOID) /* CLA MQA ASR */ +{ + AC = (AC & 010000) | MQ ; + i7415 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7717 (VOID) /* CLA MQA LSR */ +{ + AC = (AC & 010000) | MQ ; + i7417 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7721 (VOID) /* CLA SWP */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7723 (VOID) /* CLA SWP SCL */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7403 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7725 (VOID) /* CLA SWP MUY */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7405 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7727 (VOID) /* CLA SWP DVI */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7407 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7731 (VOID) /* CLA SWP NMI */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7411 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7733 (VOID) /* CLA SWP SHL */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7413 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7735 (VOID) /* CLA SWP ASR */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7415 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7737 (VOID) /* CLA SWP LSR */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7417 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7741 (VOID) /* CLA MQA SCA */ +{ + AC = (AC & 010000) | MQ | SC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7743 (VOID) /* A: CLA MQA SCA SCL */ +{ /* B: CLA MQA DAD */ + AC = (AC & 010000) | MQ ; + i7443 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7745 (VOID) /* A: CLA MQA SCA MUY */ +{ /* B: CLA MQA DST */ + AC = (AC & 010000) | MQ ; + i7445 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7747 (VOID) /* A: CLA MQA SCA DVI */ +{ /* B: CLA MQA SWBA (SWBA ignored) */ + AC = (AC & 010000) | MQ ; + if (EAE == 'A') { + AC |= SC; + i7407 (); + } else + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7751 (VOID) /* A: CLA MQA SCA NMI */ +{ /* B: CLA MQA DPSZ */ + AC = (AC & 010000) | MQ ; + i7451 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7753 (VOID) /* A: CLA MQA SCA SHL */ +{ /* B: CLA MQA DPIC- (7453) */ + AC = (AC & 010000) | MQ ; + i7453 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7755 (VOID) /* A: CLA MQA SCA ASR */ +{ /* B: CLA MQA DCM- (7455) */ + AC = (AC & 010000) | MQ ; + i7455 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7757 (VOID) /* A: CLA MQA SCA LSR */ +{ /* B: CLA MQA SAM */ + AC = (AC & 010000) | MQ ; + i7457 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7761 (VOID) /* CLA SWP SCA */ +{ + AC = (AC & 010000) | MQ | SC ; + MQ = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7763 (VOID) /* A: CLA SWP SCA SCL */ +{ /* B: CLA DAD */ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7443 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7765 (VOID) /* A: CLA SWP SCA MUY */ +{ /* B: CLA DST */ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7445 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7767 (VOID) /* A: CLA SWP SCA DVI */ +{ /* B: CLA SWP SWBA (SWBA ignored) */ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + if (EAE == 'A') { + AC |= SC; + i7407 (); + } else + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7771 (VOID) /* CLA SWP DPSZ */ +{ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7451 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7773 (VOID) /* A: CLA SWP SCA SHL */ +{ /* B: CLA DPIC */ + AC &= 010000 ; + if (EAE == 'A') + { + AC |= MQ ; + MQ = 0 ; + i7453 () ; + } + else + i7573 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7775 (VOID) /* A: CLA SWP SCA ASR */ +{ /* B: CLA DCM */ + AC &= 010000 ; + i7575 () ; +} +/* -------------------------------------------------------------------- */ +VOID i7777 (VOID) /* A: CLA SWP SCA LSR */ +{ /* B: CLA SWP SAM */ + AC = (AC & 010000) | MQ ; + MQ = 0 ; + i7457 () ; +} +/* -------------------------------------------------------------------- */ diff --git a/Emulation/eae.h b/Emulation/eae.h new file mode 100644 index 0000000..1d4e497 --- /dev/null +++ b/Emulation/eae.h @@ -0,0 +1,171 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * eae.h - Interface for the EAE instructions code for the PDP-8/E + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Include file for Operate microinstruction (OPR) module + * to handle EAE instructions. + */ +/* -------------------------------------------------------------------- */ +extern void i7401 (void) ; /* NOP Grp III */ +extern void i7403 (void) ; +extern void i7405 (void) ; /* MUY */ +extern void i7407 (void) ; /* DVI */ +extern void i7411 (void) ; /* NMI */ +extern void i7413 (void) ; /* SHL */ +extern void i7415 (void) ; /* ASR */ +extern void i7417 (void) ; /* LSR */ +extern void i7421 (void) ; /* MQL */ +extern void i7423 (void) ; /* MQL SCL */ +extern void i7425 (void) ; /* MQL MUY */ +extern void i7427 (void) ; /* MQL DVI */ +extern void i7431 (void) ; /* SWAB */ +extern void i7433 (void) ; /* MQL SHL */ +extern void i7435 (void) ; /* MQL ASR */ +extern void i7437 (void) ; /* MQL LSR */ +extern void i7441 (void) ; /* SCA */ +extern void i7443 (void) ; +extern void i7445 (void) ; +extern void i7447 (void) ; /* SWBA */ +extern void i7451 (void) ; +extern unsigned s7451 (void) ; /* (skip test) */ +extern void i7453 (void) ; +extern void i7455 (void) ; +extern void i7457 (void) ; +extern void i7461 (void) ; /* MQL SCA */ +extern void i7463 (void) ; /* A: MQL SCA SCL */ +extern void i7465 (void) ; /* A: MQL SCA MUY */ +extern void i7467 (void) ; /* MQL SWBA */ +extern void i7471 (void) ; /* A: MQL SCA NMI */ +extern void i7473 (void) ; /* A: MQL SCA SHL */ +extern void i7475 (void) ; /* A: MQL SCA ASR */ +extern void i7477 (void) ; /* A: MQL SCA LSR */ +extern void i7501 (void) ; /* MQA */ +extern void i7503 (void) ; /* A: MQA SCL */ +extern void i7505 (void) ; /* MQA MUY */ +extern void i7507 (void) ; /* MQA DVI */ +extern void i7511 (void) ; /* MQA NMI */ +extern void i7513 (void) ; /* MQA SHL */ +extern void i7515 (void) ; /* MQA ASR */ +extern void i7517 (void) ; /* MQA LSR */ +extern void i7521 (void) ; /* SWP */ +extern void i7523 (void) ; /* A: SWP SCL */ +extern void i7525 (void) ; /* SWP MUY */ +extern void i7527 (void) ; /* SWP DVI */ +extern void i7531 (void) ; /* SWP NMI */ +extern void i7533 (void) ; /* SWP SHL */ +extern void i7535 (void) ; /* SWP ASR */ +extern void i7537 (void) ; /* SWP LSR */ +extern void i7541 (void) ; /* MQA SCA */ +extern void i7543 (void) ; /* A: MQA SCA SCL */ +extern void i7545 (void) ; /* A: MQA SCA MUY */ +extern void i7547 (void) ; /* A: MQA SWBA */ +extern void i7551 (void) ; /* A: MQA SCA NMI */ +extern void i7553 (void) ; /* A: MQA SCA SHL */ +extern void i7555 (void) ; /* A: MQA SCA ASR */ +extern void i7557 (void) ; /* A: MQA SCA LSR */ +extern void i7561 (void) ; /* SWP SCA */ +extern void i7563 (void) ; /* A: SWP SCA SCL */ +extern void i7565 (void) ; /* A: SWP SCA MUY */ +extern void i7567 (void) ; /* SWP SWBA */ +extern void i7571 (void) ; /* A: SWP SCA NMI */ +extern void i7573 (void) ; /* A: SWP SCA SHL */ +extern void i7575 (void) ; +extern void i7577 (void) ; /* A: SWP SCA LSR */ +extern void i7601 (void) ; /* CLA Grp III */ +extern void i7603 (void) ; /* CLA SCA */ +extern void i7605 (void) ; /* CLA MUY */ +extern void i7607 (void) ; /* CLA DVI */ +extern void i7611 (void) ; /* CLA NMI */ +extern void i7613 (void) ; /* CLA SHL */ +extern void i7615 (void) ; /* CLA ASR */ +extern void i7617 (void) ; /* CLA LSR */ +extern void i7621 (void) ; /* CLA MQL */ +extern void i7623 (void) ; /* CLA MQL SCL */ +extern void i7625 (void) ; /* CLA MQL MUY */ +extern void i7627 (void) ; /* CLA MQL DVI */ +extern void i7631 (void) ; /* CLA MQL NMI */ +extern void i7633 (void) ; /* CLA MQL SHL */ +extern void i7635 (void) ; /* CLA MQL ASR */ +extern void i7637 (void) ; /* CLA MQL LSR */ +extern void i7641 (void) ; /* CLA SCA */ +extern void i7643 (void) ; /* A: CLA SCA SCL */ +extern void i7645 (void) ; /* A: CLA SCA MUY */ +extern void i7647 (void) ; /* CLA SWBA */ +extern void i7651 (void) ; /* A: CLA SCA NMI */ +extern void i7653 (void) ; /* A: CLA SCA SHL */ +extern void i7655 (void) ; /* A: CLA SCA ASR */ +extern void i7657 (void) ; /* A: CLA SCA LSR */ +extern void i7661 (void) ; /* CLA MQL SCA */ +extern void i7663 (void) ; /* A: CLA MQL SCA SCL */ +extern void i7665 (void) ; /* A: CLA MQL SCA MUY */ +extern void i7667 (void) ; /* CLA MQL SWBA */ +extern void i7671 (void) ; /* A: CLA MQL SCA NMI */ +extern void i7673 (void) ; /* A: CLA MQL SCA SHL */ +extern void i7675 (void) ; /* A: CLA MQL SCA ASR */ +extern void i7677 (void) ; /* A: CLA MQL SCA LSR */ +extern void i7701 (void) ; /* CLA MQA */ +extern void i7703 (void) ; /* CLA MQA SCL */ +extern void i7705 (void) ; /* CLA MQA MUY */ +extern void i7707 (void) ; /* CLA MQA DVI */ +extern void i7711 (void) ; /* CLA MQA NMI */ +extern void i7713 (void) ; /* CLA MQA SHL */ +extern void i7715 (void) ; /* CLA MQA ASR */ +extern void i7717 (void) ; /* CLA MQA LSR */ +extern void i7721 (void) ; /* CLA SWP */ +extern void i7723 (void) ; /* CLA SWP SCL */ +extern void i7725 (void) ; /* CLA SWP MUY */ +extern void i7727 (void) ; /* CLA SWP DVI */ +extern void i7731 (void) ; /* CLA SWP NMI */ +extern void i7733 (void) ; /* CLA SWP SHL */ +extern void i7735 (void) ; /* CLA SWP ASR */ +extern void i7737 (void) ; /* CLA SWP LSR */ +extern void i7741 (void) ; /* CLA MQA SCA */ +extern void i7743 (void) ; /* A: CLA MQA SCA SCL */ +extern void i7745 (void) ; /* A: CLA MQA SCA MUY */ +extern void i7747 (void) ; /* A: CLA MQA SWBA */ +extern void i7751 (void) ; /* A: CLA MQA SCA NMI */ +extern void i7753 (void) ; /* A: CLA MQA SCA SHL */ +extern void i7755 (void) ; /* A: CLA MQA SCA ASR */ +extern void i7757 (void) ; /* A: CLA MQA SCA LSR */ +extern void i7761 (void) ; /* CLA SWP SCA */ +extern void i7763 (void) ; /* A: CLA SWP SCA SCL */ +extern void i7765 (void) ; /* A: CLA SWP SCA MUY */ +extern void i7767 (void) ; /* A: CLA SWP SCA DVI */ +extern void i7771 (void) ; /* CLA SWP DPSZ */ +extern void i7773 (void) ; /* A: CLA SWP SCA SHL */ +extern void i7775 (void) ; +extern void i7777 (void) ; /* A: CLA SWP SCA LSR */ +/* -------------------------------------------------------------------- */ diff --git a/Emulation/iot.c b/Emulation/iot.c new file mode 100644 index 0000000..b2b8ba0 --- /dev/null +++ b/Emulation/iot.c @@ -0,0 +1,576 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * iot.c - IOT instructions code for the PDP-8/E + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Input / Output Transfer (IOT) module. + */ + + +#import + +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#include "PDP8.h" +#include "iot.h" +#include "pdp8defines.h" +#include "PluginAPI.h" // for CAF for I/O devices + + +/* -------------------------------------------------------------------- */ +VOID iuser (VOID) +{ + io_flags |= userFLAG; + tsc8.eriot = INST; + tsc8.ecdf = ((tsc8.eriot & 07707) == 06201); + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6000 (VOID) /* SKON 6000 */ +{ + if (int_ena) + ++PC ; + int_ena = delay = false ; + EXECUTION_TIME (12); +} +unsigned s6000 (VOID) /* SKON 6000 */ +{ + return (int_ena); +} +/* -------------------------------------------------------------------- */ +VOID i6001 (VOID) /* ION 6001 */ +{ + int_ena = delay = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6002 (VOID) /* IOF 6002 */ +{ + int_ena = delay = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6003 (VOID) /* SRQ 6003 */ +{ + if (io_flags & int_mask) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s6003 (VOID) /* SRQ 6003 */ +{ + return (io_flags & int_mask); +} +/* -------------------------------------------------------------------- */ +VOID i6004 (VOID) /* GTF 6004 */ +{ + AC = (AC & 010000) | ((AC & 010000) >> 1) /* Save the LINK */ + | ((EAE == 'B' && GTF) ? BIT1 : 0) /* Save the GTF */ + | ((io_flags & int_mask) ? BIT2 : 0) /* Save Interrupt Req */ + /* | (int_inh << 8) */ /* Save Interrupt Inh */ + /* AC(3) should become the inhibit flag, but the PDP-8/E + hardware does not implement this - detected by the + Extended Memory Control and Timeshare Test MAINDEC-8E-D1HA */ + | (int_ena << 7) /* Save Interrupt Ena */ + | SF ; /* Save UF, IF, DF */ + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6005 (VOID) /* RTF 6005 */ +{ + AC = (AC & 07777) | ((AC & BIT0) << 1) ; /* Restore LINK */ + if (EAE == 'B') + GTF = (AC & BIT1) >> 10 ; /* Restore GTF */ + SF = AC & 0177 ; /* Restore SF */ + UB = (AC & BIT5) << 6; /* Restore UB */ + W_IB = IB = (AC & 070) << 9 ; /* Restore IB */ + if (IB >= hw.memsize) + W_IB = 0100000; + W_DF = DF = (AC & 07) << 12 ; /* Restore DF */ + if (DF >= hw.memsize) + W_DF = 0100000; + int_ena = delay = int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6006 (VOID) /* SGT 6006 */ +{ + if (EAE == 'B' && GTF) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s6006 (VOID) /* SGT 6006 */ +{ + return (EAE == 'B' && GTF); +} +/* -------------------------------------------------------------------- */ +VOID i6007 (VOID) /* CAF 6007 */ +{ + AC = 0 ; /* Clear pdp8 registers */ + int_ena = int_inh = delay = false ; + io_flags = false ; /* no flags, but serial IE's = 1! */ + EAE = 'A' ; /* Set EAE mode A */ + GTF = false ; + int i; + for (i = 0; i < PDP8_IOADDRS; i++) { + if (pdp8->_state.pluginPointer[i]) + [(PDP8Plugin *) pdp8->_state.pluginPointer[i] CAF:i]; + } + +#ifdef FPP + if (FPP) + { + io_flags &= ~fppFLAG ; /* Clear FPP Int flag */ + fpp_mode = LEAV ; /* Interleaved mode */ + fpp_run = false ; /* Stop the FPP */ + fpp_pause = false ; /* ditto */ + fpp_data = FP ; /* Enable FP mode */ + fpp_stat = 0 ; /* Clear FPP status */ + } + rx5command = 0 ; /* Clear RX50 regs */ + rx5curaddr = 0 ; + rx5block = 0 ; + rx5status = 0 ; + rx5unit = 0 ; + rx5lock = false ; +#endif + + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +/* + * Field change IOTs. + */ +/* -------------------------------------------------------------------- */ +VOID i6201 (VOID) /* CDF 0 6201 */ +{ + W_DF = DF = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6202 (VOID) /* CIF 0 6202 */ +{ + W_IB = IB = 0 ; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6203 (VOID) /* CIF CDF 0 6203 */ +{ + W_IB = IB = W_DF = DF = 0 ; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +/* + * Clear User Interrupt. + */ +/* -------------------------------------------------------------------- */ +VOID i6204 (VOID) /* CINT 6204 */ +{ + io_flags &= ~userFLAG ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6211 (VOID) /* CDF 1 6211 */ +{ + if ((W_DF = DF = 010000) >= hw.memsize) + W_DF = 0100000; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6212 (VOID) /* CIF 1 6212 */ +{ + if ((W_IB = IB = 010000) >= hw.memsize) + W_IB = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6213 (VOID) /* CIF CDF 1 6213 */ +{ + if ((W_IB = IB = W_DF = DF = 010000) >= hw.memsize) + W_IB = W_DF = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6214 (VOID) /* RDF 6214 */ +{ + AC |= DF >> 9 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6221 (VOID) /* CDF 2 6221 */ +{ + if ((W_DF = DF = 020000) >= hw.memsize) + W_DF = 0100000; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6222 (VOID) /* CIF 2 6222 */ +{ + if ((W_IB = IB = 020000) >= hw.memsize) + W_IB = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6223 (VOID) /* CIF CDF 2 6223 */ +{ + if ((W_IB = IB = W_DF = DF = 020000) >= hw.memsize) + W_IB = W_DF = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6224 (VOID) /* RIF 6224 */ +{ + AC |= IF >> 9 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6231 (VOID) /* CDF 3 6231 */ +{ + if ((W_DF = DF = 030000) >= hw.memsize) + W_DF = 0100000; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6232 (VOID) /* CIF 3 6232 */ +{ + if ((W_IB = IB = 030000) >= hw.memsize) + W_IB = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6233 (VOID) /* CIF CDF 3 6233 */ +{ + if ((W_IB = IB = W_DF = DF = 030000) >= hw.memsize) + W_IB = W_DF = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6234 (VOID) /* RIB 6234 */ +{ + AC |= SF ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6241 (VOID) /* CDF 4 6241 */ +{ + if ((W_DF = DF = 040000) >= hw.memsize) + W_DF = 0100000; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6242 (VOID) /* CIF 4 6242 */ +{ + if ((W_IB = IB = 040000) >= hw.memsize) + W_IB = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6243 (VOID) /* CIF CDF 4 6243 */ +{ + if ((W_IB = IB = W_DF = DF = 040000) >= hw.memsize) + W_IB = W_DF = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6244 (VOID) /* RMF 6244 */ +{ + UB = (SF & BIT5) << 6 ; + if ((W_IB = IB = (SF & 070) << 9) >= hw.memsize) + W_IB = 0100000; + if ((W_DF = DF = (SF & 07) << 12) >= hw.memsize) + W_DF = 0100000; + int_inh = true; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6251 (VOID) /* CDF 5 6251 */ +{ + if ((W_DF = DF = 050000) >= hw.memsize) + W_DF = 0100000; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6252 (VOID) /* CIF 5 6252 */ +{ + if ((W_IB = IB = 050000) >= hw.memsize) + W_IB = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6253 (VOID) /* CIF CDF 5 6253 */ +{ + if ((W_IB = IB = W_DF = DF = 050000) >= hw.memsize) + W_IB = W_DF = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +/* + * Skip on User Interrupt. + */ +/* -------------------------------------------------------------------- */ +VOID i6254 (VOID) /* SINT 6254 */ +{ + if (io_flags & userFLAG) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s6254 (VOID) /* SINT 6254 */ +{ + return (io_flags & userFLAG); +} +/* -------------------------------------------------------------------- */ +VOID i6261 (VOID) /* CDF 6 6261 */ +{ + if ((W_DF = DF = 060000) >= hw.memsize) + W_DF = 0100000; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6262 (VOID) /* CIF 6 6262 */ +{ + if ((W_IB = IB = 060000) >= hw.memsize) + W_IB = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6263 (VOID) /* CIF CDF 6 6263 */ +{ + if ((W_IB = IB = W_DF = DF = 060000) >= hw.memsize) + W_IB = W_DF = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +/* + * Clear the User Flag. + */ +/* -------------------------------------------------------------------- */ +VOID i6264 (VOID) /* CUF 6264 */ +{ + UB = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6271 (VOID) /* CDF 7 6271 */ +{ + if ((W_DF = DF = 070000) >= hw.memsize) + W_DF = 0100000; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6272 (VOID) /* CIF 7 6272 */ +{ + if ((W_IB = IB = 070000) >= hw.memsize) + W_IB = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i6273 (VOID) /* CIF CDF 7 6273 */ +{ + if ((W_IB = IB = W_DF = DF = 070000) >= hw.memsize) + W_IB = W_DF = 0100000; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +/* + * Set the User Flag. + */ +/* -------------------------------------------------------------------- */ +VOID i6274 (VOID) /* SUF 6274 */ +{ + UB = 1 << 12 ; + int_inh = true ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +/* + * FPP-8/A Floating Point Processor + */ +/* -------------------------------------------------------------------- */ +#ifdef FPP +VOID i6551 (VOID) /* FPINT 6551 */ +{ + if (io_flags & fppFLAG) + ++PC ; + EXECUTION_TIME (12); +} +#error "s6551 missing" +#endif +/* -------------------------------------------------------------------- */ +#ifdef FPP +VOID i6552 (VOID) /* FPICL 6552 */ +{ + io_flags &= ~fppFLAG ; /* Clear FPP Int flag */ + fpp_mode = LEAV ; /* Interleaved mode */ + fpp_run = false ; /* Stop the FPP */ + fpp_pause = false ; /* ditto */ + fpp_data = FP ; /* Enable FP mode */ + fpp_stat = 0 ; /* Clear FPP status */ + EXECUTION_TIME (12); +} +#endif +/* -------------------------------------------------------------------- */ +#ifdef FPP +VOID i6553 (VOID) /* FPCOM 6553 */ +{ + if (fpp_run == false && !(io_flags & fppFLAG)) + { + fpp_command = (AC & 07777) | 0100000 ; /* Insure non-zero */ + /* See FPEP below */ + fpp_stat &= ~(BIT0 | BIT8 | BIT9) ; /* Set FPP mode FP */ + if (fpp_command & BIT0) + { + fpp_stat |= BIT0 ; /* Set DP in status */ + fpp_data = DP ; /* Set DP mode */ + } + int_mask &= ~fppFLAG ; /* Clear interrupts */ + if (fpp_command & BIT3) /* Enable interrupts ? */ + int_mask |= fppFLAG ; /* Yes */ + fpp_mode = LEAV ; /* Set interleave mode */ + if (fpp_command & BIT8) /* Lockout mode ? */ + { + fpp_mode = LOCK ; /* Yes */ + fpp_stat |= BIT8 ; + } + } + EXECUTION_TIME (12); +} +#endif +/* -------------------------------------------------------------------- */ +#ifdef FPP +VOID i6554 (VOID) /* FPHLT 6554 */ +{ + if (fpp_run) + { + fpp_pause = true ; + fpp_stat |= BIT2 ; + if (fpp_stat & BIT10) /* If FPP paused, */ + fpp_pc = --fpp_pc & 077777 ; /* decrement FPC */ + } + EXECUTION_TIME (12); +} +#endif +/* -------------------------------------------------------------------- */ +#ifdef FPP +VOID i6555 (VOID) /* FPST 6555 */ +{ + if (fpp_run == false && !(io_flags & fppFLAG)) + { + fpp_aptp = ((fpp_command & 07) << 12) | (AC & 07777) ; + fpp_pc = ((*(base + fpp_aptp) & 07) << 12) + + (*(base + fpp_aptp + 1)) ; + fpp_opadd = fpp_pc ; /* OPADD (2-5) */ + if (!(fpp_command & BIT5)) + fpp_x0 = ((*(base + fpp_aptp) & 070) << 9) + + (*(base + fpp_aptp + 2)) ; + if (!(fpp_command & BIT6)) + fpp_br = ((*(base + fpp_aptp) & 0700) << 6) + + (*(base + fpp_aptp + 3)) ; + if (!(fpp_command & BIT7)) + { + fpp_ac [0] = *(base + fpp_aptp + 5) ; + fpp_ac [1] = *(base + fpp_aptp + 6) ; + fpp_ac [2] = *(base + fpp_aptp + 7) ; + if (fpp_data == EP) + { + fpp_ac [3] = *(base + fpp_aptp + 8) ; + fpp_ac [4] = *(base + fpp_aptp + 9) ; + fpp_ac [5] = *(base + fpp_aptp + 10) ; + } + } + fpp_stat &= ~BIT10 ; /* Clear FPAUSE in stat */ + fpp_run = true ; + fpp_stat |= BIT11 ; /* Set RUN in status */ + ++PC ; + } + EXECUTION_TIME (12); +} +#error "s6555 missing" +#endif +/* -------------------------------------------------------------------- */ +#ifdef FPP +VOID i6556 (VOID) /* FPRST 6556 */ +{ + AC = (AC & 010000) | fpp_stat ; + EXECUTION_TIME (12); +} +#endif +/* -------------------------------------------------------------------- */ +#ifdef FPP +VOID i6557 (VOID) /* FPIST 6557 */ +{ + if (io_flags & fppFLAG) + { + ++PC ; + AC = (AC & 010000) | fpp_stat ; + fpp_stat = 0 ; + io_flags &= ~fppFLAG ; + } + EXECUTION_TIME (12); +} +#error "s6557 missing" +#endif +/* -------------------------------------------------------------------- */ +#ifdef FPP +VOID i6567 (VOID) /* FPEP 6567 */ +{ + if ((AC & BIT0) && fpp_run == false && fpp_command) + { + fpp_stat &= ~BIT0 ; /* Remove DP mode */ + if (fpp_command & 0100000) + { + fpp_stat |= 4 ; /* Set EP in status */ + fpp_data = EP ; /* Set EP mode */ + fpp_command &= 0107777 ; + } + } + AC &= 010000 ; + EXECUTION_TIME (12); +} +#endif diff --git a/Emulation/iot.h b/Emulation/iot.h new file mode 100644 index 0000000..82a8763 --- /dev/null +++ b/Emulation/iot.h @@ -0,0 +1,109 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * iot.c - Interface for the IOT instructions code for the PDP-8/E + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Include file for Input / Output Transfer (IOT) module. + */ +/* -------------------------------------------------------------------- */ +/* + * IOT Instructions + */ +/* -------------------------------------------------------------------- */ +extern void iuser (void) ; +extern void i6000 (void) ; /* SKON 6000 */ +extern unsigned s6000 (void) ; /* SKON (skip test) */ +extern void i6001 (void) ; /* ION 6001 */ +extern void i6002 (void) ; /* IOF 6002 */ +extern void i6003 (void) ; /* SRQ 6003 */ +extern unsigned s6003 (void) ; /* SRQ (skip test) */ +extern void i6004 (void) ; /* GTF 6004 */ +extern void i6005 (void) ; /* RTF 6005 */ +extern void i6006 (void) ; /* SGT 6006 */ +extern unsigned s6006 (void) ; /* SGT (skip test) */ +extern void i6007 (void) ; /* CAF 6007 */ +extern void i6201 (void) ; /* CDF 0 6201 */ +extern void i6202 (void) ; /* CIF 0 6202 */ +extern void i6203 (void) ; /* CIF CDF 0 6203 */ +extern void i6204 (void) ; /* CINT 6204 */ +extern void i6211 (void) ; /* CDF 1 6211 */ +extern void i6212 (void) ; /* CIF 1 6212 */ +extern void i6213 (void) ; /* CIF CDF 1 6213 */ +extern void i6214 (void) ; /* RDF 6214 */ +extern void i6221 (void) ; /* CDF 2 6221 */ +extern void i6222 (void) ; /* CIF 2 6222 */ +extern void i6223 (void) ; /* CIF CDF 2 6223 */ +extern void i6224 (void) ; /* RIF 6224 */ +extern void i6231 (void) ; /* CDF 3 6231 */ +extern void i6232 (void) ; /* CIF 3 6232 */ +extern void i6233 (void) ; /* CIF CDF 3 6233 */ +extern void i6234 (void) ; /* RIB 6234 */ +extern void i6241 (void) ; /* CDF 4 6241 */ +extern void i6242 (void) ; /* CIF 4 6242 */ +extern void i6243 (void) ; /* CIF CDF 4 6243 */ +extern void i6244 (void) ; /* RMF 6244 */ +extern void i6251 (void) ; /* CDF 5 6251 */ +extern void i6252 (void) ; /* CIF 5 6252 */ +extern void i6253 (void) ; /* CIF CDF 5 6253 */ +extern void i6254 (void) ; /* SINT 6254 */ +extern unsigned s6254 (void) ; /* SINT (skip test) */ +extern void i6261 (void) ; /* CDF 6 6261 */ +extern void i6262 (void) ; /* CIF 6 6262 */ +extern void i6263 (void) ; /* CIF CDF 6 6263 */ +extern void i6264 (void) ; /* CUF 6264 */ +extern void i6271 (void) ; /* CDF 7 6271 */ +extern void i6272 (void) ; /* CIF 7 6272 */ +extern void i6273 (void) ; /* CIF CDF 7 6273 */ +extern void i6274 (void) ; /* SUF 6274 */ +extern void i6551 (void) ; /* FPINT 6551 */ +extern unsigned s6551 (void) ; /* FPINT (skip test) */ +extern void i6552 (void) ; /* FPICL 6552 */ +extern void i6553 (void) ; /* FPCOM 6553 */ +extern void i6554 (void) ; /* FPHLT 6554 */ +extern void i6555 (void) ; /* FPST 6555 */ +extern unsigned s6555 (void) ; /* FPST (skip test) */ +extern void i6556 (void) ; /* FPRST 6556 */ +extern void i6557 (void) ; /* FPIST 6557 */ +extern unsigned s6557 (void) ; /* FPIST (skip test) */ +extern void i6567 (void) ; /* FPEP 6567 */ +extern void rxsel (void) ; /* SEL 6750 */ +extern void rxlcd (void) ; /* LCD 6751 */ +extern void rxxdr (void) ; /* XDR 6752 */ +extern void rxstr (void) ; /* STR 6753 */ +extern void rxser (void) ; /* SER 6754 */ +extern void rxsdn (void) ; /* SDN 6755 */ +extern void rxintr (void) ; /* INTR 6756 */ +extern void rxinit (void) ; /* INIT 6757 */ +/* -------------------------------------------------------------------- */ diff --git a/Emulation/itab.c b/Emulation/itab.c new file mode 100644 index 0000000..1eed27c --- /dev/null +++ b/Emulation/itab.c @@ -0,0 +1,1095 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * itab.c - The PDP-8/E instruction table + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Instruction pointer table and initialization. + */ + + +#include "itab.h" +#include "pdp8defines.h" +#include "mri.h" +#include "iot.h" +#include "opr.h" +#include "eae.h" + + +void (*itab[])(void) = { +/* + * Normal mode instruction vector table. + */ + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, /* 0000 */ + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, /* 0100 */ + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, /* 0200 */ + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, /* 0300 */ + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, /* 0400 */ + i0410, i0410, i0410, i0410, i0410, i0410, i0410, i0410, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, /* 0500 */ + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, /* 0600 */ + i0610, i0610, i0610, i0610, i0610, i0610, i0610, i0610, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, /* 0700 */ + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, /* 1000 */ + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, /* 1100 */ + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, /* 1200 */ + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, /* 1300 */ + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, /* 1400 */ + i1410, i1410, i1410, i1410, i1410, i1410, i1410, i1410, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, /* 1500 */ + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, /* 1600 */ + i1610, i1610, i1610, i1610, i1610, i1610, i1610, i1610, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, /* 1700 */ + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, /* 2000 */ + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, /* 2100 */ + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, /* 2200 */ + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, /* 2300 */ + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, /* 2400 */ + i2410, i2410, i2410, i2410, i2410, i2410, i2410, i2410, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, /* 2500 */ + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, /* 2600 */ + i2610, i2610, i2610, i2610, i2610, i2610, i2610, i2610, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, /* 2700 */ + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, /* 3000 */ + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, /* 3100 */ + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, /* 3200 */ + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, /* 3300 */ + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, /* 3400 */ + i3410, i3410, i3410, i3410, i3410, i3410, i3410, i3410, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, /* 3500 */ + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, /* 3600 */ + i3610, i3610, i3610, i3610, i3610, i3610, i3610, i3610, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, /* 3700 */ + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, /* 4000 */ + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, /* 4100 */ + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4000, i4000, i4000, i4000, i4000, i4000, i4000, i4000, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, /* 4200 */ + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, /* 4300 */ + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4200, i4200, i4200, i4200, i4200, i4200, i4200, i4200, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, /* 4400 */ + i4410, i4410, i4410, i4410, i4410, i4410, i4410, i4410, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, /* 4500 */ + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4400, i4400, i4400, i4400, i4400, i4400, i4400, i4400, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, /* 4600 */ + i4610, i4610, i4610, i4610, i4610, i4610, i4610, i4610, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, /* 4700 */ + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + i4600, i4600, i4600, i4600, i4600, i4600, i4600, i4600, + + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, /* 5000 */ + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, /* 5100 */ + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5000, i5000, i5000, i5000, i5000, i5000, i5000, i5000, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, /* 5200 */ + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, /* 5300 */ + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5200, i5200, i5200, i5200, i5200, i5200, i5200, i5200, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, /* 5400 */ + i5410, i5410, i5410, i5410, i5410, i5410, i5410, i5410, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, /* 5500 */ + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5400, i5400, i5400, i5400, i5400, i5400, i5400, i5400, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, /* 5600 */ + i5610, i5610, i5610, i5610, i5610, i5610, i5610, i5610, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, /* 5700 */ + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + i5600, i5600, i5600, i5600, i5600, i5600, i5600, i5600, + + i6000, i6001, i6002, i6003, i6004, i6005, i6006, i6007, /* 6000 */ + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, /* 6100 */ + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, /* 6200 */ + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, /* 6300 */ + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, /* 6400 */ + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, /* 6500 */ + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, /* 6600 */ + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, /* 6700 */ + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + i7000, i7000, i7000, i7000, i7000, i7000, i7000, i7000, + + i7000, i7001, i7002, i7003, i7004, i7005, i7006, i7007, /* 7000 */ + i7010, i7011, i7012, i7013, i7014, i7015, i7016, i7017, + i7020, i7021, i7022, i7023, i7024, i7025, i7026, i7027, + i7030, i7031, i7032, i7033, i7034, i7035, i7036, i7037, + i7040, i7041, i7042, i7043, i7044, i7045, i7046, i7047, + i7050, i7051, i7052, i7053, i7054, i7055, i7056, i7057, + i7060, i7061, i7062, i7063, i7064, i7065, i7066, i7067, + i7070, i7071, i7072, i7073, i7074, i7075, i7076, i7077, + i7100, i7101, i7102, i7103, i7104, i7105, i7106, i7107, /* 7100 */ + i7110, i7111, i7112, i7113, i7114, i7115, i7116, i7117, + i7120, i7121, i7122, i7123, i7124, i7125, i7126, i7127, + i7130, i7131, i7132, i7133, i7134, i7135, i7136, i7137, + i7140, i7141, i7142, i7143, i7144, i7145, i7146, i7147, + i7150, i7151, i7152, i7153, i7154, i7155, i7156, i7157, + i7160, i7161, i7162, i7163, i7164, i7165, i7166, i7167, + i7170, i7171, i7172, i7173, i7174, i7175, i7176, i7177, + i7200, i7201, i7202, i7203, i7204, i7205, i7206, i7207, /* 7200 */ + i7210, i7211, i7212, i7213, i7214, i7215, i7216, i7217, + i7220, i7221, i7222, i7223, i7224, i7225, i7226, i7227, + i7230, i7231, i7232, i7233, i7234, i7235, i7236, i7237, + i7240, i7241, i7242, i7243, i7244, i7245, i7246, i7247, + i7250, i7251, i7252, i7253, i7254, i7255, i7256, i7257, + i7260, i7261, i7262, i7263, i7264, i7265, i7266, i7267, + i7270, i7271, i7272, i7273, i7274, i7275, i7276, i7277, + i7300, i7301, i7302, i7303, i7304, i7305, i7306, i7307, /* 7300 */ + i7310, i7311, i7312, i7313, i7314, i7315, i7316, i7317, + i7320, i7321, i7322, i7323, i7324, i7325, i7326, i7327, + i7330, i7331, i7332, i7333, i7334, i7335, i7336, i7337, + i7340, i7341, i7342, i7343, i7344, i7345, i7346, i7347, + i7350, i7351, i7352, i7353, i7354, i7355, i7356, i7357, + i7360, i7361, i7362, i7363, i7364, i7365, i7366, i7367, + i7370, i7371, i7372, i7373, i7374, i7375, i7376, i7377, + i7400, i7401, i7402, i7401, i7404, i7401, i7406, i7401, /* 7400 */ + i7410, i7401, i7412, i7401, i7414, i7401, i7416, i7401, + i7420, i7421, i7422, i7421, i7424, i7421, i7426, i7421, + i7430, i7421, i7432, i7421, i7434, i7421, i7436, i7421, + i7440, i7401, i7442, i7401, i7444, i7401, i7446, i7401, + i7450, i7401, i7452, i7401, i7454, i7401, i7456, i7401, + i7460, i7421, i7462, i7421, i7464, i7421, i7466, i7421, + i7470, i7421, i7472, i7421, i7474, i7421, i7476, i7421, + i7500, i7501, i7502, i7501, i7504, i7501, i7506, i7501, /* 7500 */ + i7510, i7501, i7512, i7501, i7514, i7501, i7516, i7501, + i7520, i7521, i7522, i7521, i7524, i7521, i7526, i7521, + i7530, i7521, i7532, i7521, i7534, i7521, i7536, i7521, + i7540, i7501, i7542, i7501, i7544, i7501, i7546, i7501, + i7550, i7501, i7552, i7501, i7554, i7501, i7556, i7501, + i7560, i7521, i7562, i7521, i7564, i7521, i7566, i7521, + i7570, i7521, i7572, i7521, i7574, i7521, i7576, i7521, + i7600, i7601, i7602, i7601, i7604, i7601, i7606, i7601, /* 7600 */ + i7610, i7601, i7612, i7601, i7614, i7601, i7616, i7601, + i7620, i7621, i7622, i7621, i7624, i7621, i7626, i7621, + i7630, i7621, i7632, i7621, i7634, i7621, i7636, i7621, + i7640, i7601, i7642, i7601, i7644, i7601, i7646, i7601, + i7650, i7601, i7652, i7601, i7654, i7601, i7656, i7601, + i7660, i7621, i7662, i7621, i7664, i7621, i7666, i7621, + i7670, i7621, i7672, i7621, i7674, i7621, i7676, i7621, + i7700, i7701, i7702, i7701, i7704, i7701, i7706, i7701, /* 7700 */ + i7710, i7701, i7712, i7701, i7714, i7701, i7716, i7701, + i7720, i7721, i7722, i7721, i7724, i7721, i7726, i7721, + i7730, i7721, i7732, i7721, i7734, i7721, i7736, i7721, + i7740, i7701, i7742, i7701, i7744, i7701, i7746, i7701, + i7750, i7701, i7752, i7701, i7754, i7701, i7756, i7701, + i7760, i7721, i7762, i7721, i7764, i7721, i7766, i7721, + i7770, i7721, i7772, i7721, i7774, i7721, i7776, i7721, +/* + * User mode instruction vector table. + */ + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, /* 0000 */ + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, /* 0100 */ + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0000, i0000, i0000, i0000, i0000, i0000, i0000, i0000, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, /* 0200 */ + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, /* 0300 */ + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0200, i0200, i0200, i0200, i0200, i0200, i0200, i0200, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, /* 0400 */ + i0410, i0410, i0410, i0410, i0410, i0410, i0410, i0410, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, /* 0500 */ + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0400, i0400, i0400, i0400, i0400, i0400, i0400, i0400, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, /* 0600 */ + i0610, i0610, i0610, i0610, i0610, i0610, i0610, i0610, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, /* 0700 */ + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + i0600, i0600, i0600, i0600, i0600, i0600, i0600, i0600, + + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, /* 1000 */ + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, /* 1100 */ + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1000, i1000, i1000, i1000, i1000, i1000, i1000, i1000, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, /* 1200 */ + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, /* 1300 */ + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1200, i1200, i1200, i1200, i1200, i1200, i1200, i1200, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, /* 1400 */ + i1410, i1410, i1410, i1410, i1410, i1410, i1410, i1410, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, /* 1500 */ + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1400, i1400, i1400, i1400, i1400, i1400, i1400, i1400, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, /* 1600 */ + i1610, i1610, i1610, i1610, i1610, i1610, i1610, i1610, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, /* 1700 */ + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + i1600, i1600, i1600, i1600, i1600, i1600, i1600, i1600, + + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, /* 2000 */ + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, /* 2100 */ + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2000, i2000, i2000, i2000, i2000, i2000, i2000, i2000, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, /* 2200 */ + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, /* 2300 */ + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2200, i2200, i2200, i2200, i2200, i2200, i2200, i2200, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, /* 2400 */ + i2410, i2410, i2410, i2410, i2410, i2410, i2410, i2410, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, /* 2500 */ + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2400, i2400, i2400, i2400, i2400, i2400, i2400, i2400, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, /* 2600 */ + i2610, i2610, i2610, i2610, i2610, i2610, i2610, i2610, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, /* 2700 */ + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + i2600, i2600, i2600, i2600, i2600, i2600, i2600, i2600, + + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, /* 3000 */ + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, /* 3100 */ + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3000, i3000, i3000, i3000, i3000, i3000, i3000, i3000, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, /* 3200 */ + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, /* 3300 */ + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3200, i3200, i3200, i3200, i3200, i3200, i3200, i3200, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, /* 3400 */ + i3410, i3410, i3410, i3410, i3410, i3410, i3410, i3410, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, /* 3500 */ + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3400, i3400, i3400, i3400, i3400, i3400, i3400, i3400, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, /* 3600 */ + i3610, i3610, i3610, i3610, i3610, i3610, i3610, i3610, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, /* 3700 */ + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + i3600, i3600, i3600, i3600, i3600, i3600, i3600, i3600, + + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, /* 4000 */ + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, /* 4100 */ + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4000, u4000, u4000, u4000, u4000, u4000, u4000, u4000, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, /* 4200 */ + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, /* 4300 */ + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4200, u4200, u4200, u4200, u4200, u4200, u4200, u4200, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, /* 4400 */ + u4410, u4410, u4410, u4410, u4410, u4410, u4410, u4410, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, /* 4500 */ + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4400, u4400, u4400, u4400, u4400, u4400, u4400, u4400, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, /* 4600 */ + u4610, u4610, u4610, u4610, u4610, u4610, u4610, u4610, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, /* 4700 */ + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + u4600, u4600, u4600, u4600, u4600, u4600, u4600, u4600, + + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, /* 5000 */ + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, /* 5100 */ + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5000, u5000, u5000, u5000, u5000, u5000, u5000, u5000, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, /* 5200 */ + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, /* 5300 */ + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5200, u5200, u5200, u5200, u5200, u5200, u5200, u5200, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, /* 5400 */ + u5410, u5410, u5410, u5410, u5410, u5410, u5410, u5410, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, /* 5500 */ + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5400, u5400, u5400, u5400, u5400, u5400, u5400, u5400, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, /* 5600 */ + u5610, u5610, u5610, u5610, u5610, u5610, u5610, u5610, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, /* 5700 */ + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + u5600, u5600, u5600, u5600, u5600, u5600, u5600, u5600, + + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, /* 6000 */ + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, /* 6100 */ + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, /* 6200 */ + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, /* 6300 */ + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, /* 6400 */ + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, /* 6500 */ + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, /* 6600 */ + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, /* 6700 */ + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + iuser, iuser, iuser, iuser, iuser, iuser, iuser, iuser, + + i7000, i7001, i7002, i7003, i7004, i7005, i7006, i7007, /* 7000 */ + i7010, i7011, i7012, i7013, i7014, i7315, i7316, i7317, + i7020, i7021, i7022, i7023, i7024, i7025, i7026, i7027, + i7030, i7031, i7032, i7033, i7034, i7335, i7336, i7337, + i7040, i7041, i7042, i7043, i7044, i7045, i7046, i7047, + i7050, i7051, i7052, i7053, i7054, i7355, i7356, i7357, + i7060, i7061, i7062, i7063, i7064, i7065, i7066, i7067, + i7070, i7071, i7072, i7073, i7074, i7375, i7376, i7377, + i7100, i7101, i7102, i7103, i7104, i7105, i7106, i7107, /* 7100 */ + i7110, i7111, i7112, i7113, i7114, i7115, i7116, i7117, + i7120, i7121, i7122, i7123, i7124, i7125, i7126, i7127, + i7130, i7131, i7132, i7133, i7134, i7135, i7136, i7137, + i7140, i7141, i7142, i7143, i7144, i7145, i7146, i7147, + i7150, i7151, i7152, i7153, i7154, i7155, i7156, i7157, + i7160, i7161, i7162, i7163, i7164, i7165, i7166, i7167, + i7170, i7171, i7172, i7173, i7174, i7175, i7176, i7177, + i7200, i7201, i7202, i7203, i7204, i7205, i7206, i7207, /* 7200 */ + i7210, i7211, i7212, i7213, i7214, i7215, i7216, i7217, + i7220, i7221, i7222, i7223, i7224, i7225, i7226, i7227, + i7230, i7231, i7232, i7233, i7234, i7235, i7236, i7237, + i7240, i7241, i7242, i7243, i7244, i7245, i7246, i7247, + i7250, i7251, i7252, i7253, i7254, i7255, i7256, i7257, + i7260, i7261, i7262, i7263, i7264, i7265, i7266, i7267, + i7270, i7271, i7272, i7273, i7274, i7275, i7276, i7277, + i7300, i7301, i7302, i7303, i7304, i7305, i7306, i7307, /* 7300 */ + i7310, i7311, i7312, i7313, i7314, i7315, i7316, i7317, + i7320, i7321, i7322, i7323, i7324, i7325, i7326, i7327, + i7330, i7331, i7332, i7333, i7334, i7335, i7336, i7337, + i7340, i7341, i7342, i7343, i7344, i7345, i7346, i7347, + i7350, i7351, i7352, i7353, i7354, i7355, i7356, i7357, + i7360, i7361, i7362, i7363, i7364, i7365, i7366, i7367, + i7370, i7371, i7372, i7373, i7374, i7375, i7376, i7377, + i7400, i7401, iuser, i7401, iuser, i7401, iuser, i7401, /* 7400 */ + i7410, i7401, u7412, i7401, u7412, i7401, u7412, i7401, + i7420, i7421, u7422, i7421, u7422, i7421, u7422, i7421, + i7430, i7421, u7432, i7421, u7432, i7421, u7432, i7421, + i7440, i7401, u7442, i7401, u7442, i7401, u7442, i7401, + i7450, i7401, u7452, i7401, u7452, i7401, u7452, i7401, + i7460, i7421, u7462, i7421, u7462, i7421, u7462, i7421, + i7470, i7421, u7472, i7421, u7472, i7421, u7472, i7421, + i7500, i7501, u7502, i7501, u7502, i7501, u7502, i7501, /* 7500 */ + i7510, i7501, u7512, i7501, u7512, i7501, u7512, i7501, + i7520, i7521, u7522, i7521, u7522, i7521, u7522, i7521, + i7530, i7521, u7532, i7521, u7532, i7521, u7532, i7521, + i7540, i7501, u7542, i7501, u7542, i7501, u7542, i7501, + i7550, i7501, u7552, i7501, u7552, i7501, u7552, i7501, + i7560, i7521, u7562, i7521, u7562, i7521, u7562, i7521, + i7570, i7521, u7572, i7521, u7572, i7521, u7572, i7521, + i7600, i7601, u7602, i7601, u7602, i7601, u7602, i7601, /* 7600 */ + i7610, i7601, u7612, i7601, u7612, i7601, u7612, i7601, + i7620, i7621, u7622, i7621, u7622, i7621, u7622, i7621, + i7630, i7621, u7632, i7621, u7632, i7621, u7632, i7621, + i7640, i7621, u7642, i7621, u7642, i7621, u7642, i7621, + i7650, i7601, u7652, i7601, u7652, i7601, u7652, i7601, + i7660, i7621, u7662, i7621, u7662, i7621, u7662, i7621, + i7670, i7621, u7672, i7621, u7672, i7621, u7672, i7621, + i7700, i7701, u7702, i7701, u7702, i7701, u7702, i7701, /* 7700 */ + i7710, i7701, u7712, i7701, u7712, i7701, u7712, i7701, + i7720, i7721, u7722, i7721, u7722, i7721, u7722, i7721, + i7730, i7721, u7732, i7721, u7732, i7721, u7732, i7721, + i7740, i7701, u7742, i7701, u7742, i7701, u7742, i7701, + i7750, i7701, u7752, i7701, u7752, i7701, u7752, i7701, + i7760, i7721, u7762, i7721, u7762, i7721, u7762, i7721, + i7770, i7721, u7772, i7721, u7772, i7721, u7772, i7721 +}; diff --git a/Emulation/itab.h b/Emulation/itab.h new file mode 100644 index 0000000..9f22465 --- /dev/null +++ b/Emulation/itab.h @@ -0,0 +1,25 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * itab.h - The PDP-8/E instruction table + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +extern void (*itab[])(void); diff --git a/Emulation/mri.c b/Emulation/mri.c new file mode 100644 index 0000000..375980b --- /dev/null +++ b/Emulation/mri.c @@ -0,0 +1,587 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * mri.c - MRI instructions code for the PDP-8/E + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Memory Reference Instruction (MRI) module. + */ + + +#import + +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#include "PDP8.h" +#include "mri.h" +#include "pdp8defines.h" + + +/* -------------------------------------------------------------------- */ +VOID i0000 (VOID) +{ + AC &= *(base + (IF + INST)) | 010000 ; + EXECUTION_TIME (26); +} +/* -------------------------------------------------------------------- */ +VOID i0200 (VOID) +{ + AC &= *(base + (IF | (PC & 07600) | (INST & 0177))) | 010000 ; + EXECUTION_TIME (26); +} +/* -------------------------------------------------------------------- */ +VOID i0400 (VOID) +{ + AC &= *(base + (DF | *(base + (IF | (INST & 0177))))) | 010000 ; + EXECUTION_TIME (38); +} +/* -------------------------------------------------------------------- */ +VOID i0410 (VOID) +{ + REG UWORD *p = base + (IF | (INST & 0177)) ; + AC &= *(base + (DF | (*p = (*p + 1) & 07777))) | 010000 ; + EXECUTION_TIME (40); +} +/* -------------------------------------------------------------------- */ +VOID i0600 (VOID) +{ + AC &= *(base + (DF | *(base + (IF | (PC & 07600) + | (INST & 0177))))) | 010000 ; + EXECUTION_TIME (38); +} +/* -------------------------------------------------------------------- */ +VOID i0610 (VOID) +{ + REG UINT page = PC & 07600 ; + REG UWORD *p = base + (IF | page | (INST & 0177)) ; + if (!page && (++*p & 010000)) + *p &= 07777 ; + AC &= *(base + (DF | *p)) | 010000 ; + EXECUTION_TIME (page ? 38 : 40); +} +/* -------------------------------------------------------------------- */ +VOID i1000 (VOID) +{ + AC = (AC + *(base + (IF | (INST & 0177)))) & 017777 ; + EXECUTION_TIME (26); +} +/* -------------------------------------------------------------------- */ +VOID i1200 (VOID) +{ + AC = (AC + *(base + (IF | (PC & 07600) | (INST & 0177)))) & 017777 ; + EXECUTION_TIME (26); +} +/* -------------------------------------------------------------------- */ +VOID i1400 (VOID) +{ + AC = (AC + *(base + (DF | *(base + (IF | (INST & 0177)))))) & 017777 ; + EXECUTION_TIME (38); +} +/* -------------------------------------------------------------------- */ +VOID i1410 (VOID) +{ + REG UWORD *p = base + (IF | (INST & 0177)) ; + AC = (AC + *(base + (DF | (*p = (*p + 1) & 07777)))) & 017777 ; + EXECUTION_TIME (40); +} +/* -------------------------------------------------------------------- */ +VOID i1600 (VOID) +{ + AC = (AC + *(base + (DF | *(base + (IF | (PC & 07600) + | (INST & 0177)))))) & 017777 ; + EXECUTION_TIME (38); +} +/* -------------------------------------------------------------------- */ +VOID i1610 (VOID) +{ + REG UINT page = PC & 07600 ; + REG UWORD *p = base + (IF | page | (INST & 0177)) ; + if (!page && (++*p & 010000)) + *p &= 07777 ; + AC = (AC + *(base + (DF | *p))) & 017777 ; + EXECUTION_TIME (page ? 38 : 40); +} +/* -------------------------------------------------------------------- */ +VOID i2000 (VOID) +{ + REG UWORD *p = base + (IF | (INST & 0177)) ; + if (!(*p = (*p + 1) & 07777)) + ++PC ; + EXECUTION_TIME (26); +} +unsigned s2000 (VOID) +{ + REG UWORD *p = base + (IF | (base[IF | PC] & 0177)); + /* Don´t use INST but pdp8.mem[pdp8.IF | pdp8.PC] because + state.currInst is not set up for skip tests */ + return (!((*p + 1) & 07777)); +} +/* -------------------------------------------------------------------- */ +VOID i2200 (VOID) +{ + REG UWORD *p = base + (IF | (PC & 07600) | (INST & 0177)) ; + if (!(*p = (*p + 1) & 07777)) + ++PC ; + EXECUTION_TIME (26); +} +unsigned s2200 (VOID) +{ + REG UWORD *p = base + (IF | (PC & 07600) | (base[IF | PC] & 0177)) ; + return (!((*p + 1) & 07777)); +} +/* -------------------------------------------------------------------- */ +VOID i2400 (VOID) +{ + REG UWORD addr = base[IF | (INST & 0177)]; + REG UWORD *p = base + (DF | addr); + REG UWORD *wp = base + (W_DF | addr); + + *wp = (*p + 1) & 07777; + if (! *wp) /* MB is checked, no re-read from memory */ + PC++; + EXECUTION_TIME (38); +} +unsigned s2400 (VOID) +{ + REG UWORD addr = base[IF | (base[IF | PC] & 0177)]; + REG UWORD *p = base + (DF | addr); + + return (! ((*p + 1) & 07777)); +} +/* -------------------------------------------------------------------- */ +VOID i2410 (VOID) +{ + REG UWORD *p = base + (IF | (INST & 0177)) ; + REG UWORD *wp; + *p = (*p + 1) & 07777 ; + wp = base + (W_DF | *p); + p = base + (DF | *p) ; + *wp = (*p + 1) & 07777; + if (! *wp) /* MB is checked, no re-read from memory */ + ++PC ; + EXECUTION_TIME (40); +} +unsigned s2410 (VOID) +{ + REG UWORD *p = base + (IF | (base[IF | PC] & 0177)) ; + REG UWORD *pp; + REG UWORD inc; + + pp = base + (DF | ((*p + 1) & 07777)) ; + inc = (pp == p) ? 1 : 0; + return (! ((*pp + 1 + inc) & 07777)); +} +/* -------------------------------------------------------------------- */ +VOID i2600 (VOID) +{ + REG UWORD addr = base[IF | (PC & 07600) | (INST & 0177)]; + REG UWORD *p = base + (DF | addr); + REG UWORD *wp = base + (W_DF | addr); + + *wp = (*p + 1) & 07777; + if (! *wp) /* MB is checked, no re-read from memory */ + ++PC ; + EXECUTION_TIME (38); +} +unsigned s2600 (VOID) +{ + REG UWORD addr = base[IF | (PC & 07600) | (base[IF | PC] & 0177)]; + REG UWORD *p = base + (DF | addr); + + return (! ((*p + 1) & 07777)); +} +/* -------------------------------------------------------------------- */ +VOID i2610 (VOID) +{ + REG UWORD page = PC & 07600 ; + REG UWORD *p = base + (IF | page | (INST & 0177)) ; + REG UWORD *wp; + if (!page) + *p = (*p + 1) & 07777 ; + wp = base + (W_DF | *p); + p = base + (DF | *p) ; + *wp = (*p + 1) & 07777; + if (! *wp) /* MB is checked, no re-read from memory */ + ++PC; + EXECUTION_TIME (page ? 38 : 40); +} +unsigned s2610 (VOID) +{ + REG UWORD page = PC & 07600 ; + REG UWORD *p = base + (IF | page | (base[IF | PC] & 0177)) ; + REG UWORD *pp; + REG UWORD inc; + if (!page) { + pp = base + (DF | ((*p + 1) & 07777)) ; + inc = (pp == p) ? 1 : 0; + } else { + pp = base + (DF | *p) ; + inc = 0; + } + return (! ((*pp + 1 + inc) & 07777)); +} +/* -------------------------------------------------------------------- */ +VOID i3000 (VOID) +{ + *(base + (IF | (INST & 0177))) = AC & 07777 ; + AC &= 010000 ; + EXECUTION_TIME (26); +} +/* -------------------------------------------------------------------- */ +VOID i3200 (VOID) +{ + *(base + (IF | (PC & 07600) | (INST & 0177))) = AC & 07777 ; + AC &= 010000 ; + EXECUTION_TIME (26); +} +/* -------------------------------------------------------------------- */ +VOID i3400 (VOID) +{ + *(base + (W_DF | *(base + (IF | (INST & 0177))))) = AC & 07777 ; + AC &= 010000 ; + EXECUTION_TIME (38); +} +/* -------------------------------------------------------------------- */ +VOID i3410 (VOID) +{ + REG UWORD *p = base + (IF | (INST & 0177)) ; + *p = ++*p & 07777 ; + *(base + (W_DF | *p)) = AC & 07777 ; + AC &= 010000 ; + EXECUTION_TIME (40); +} +/* -------------------------------------------------------------------- */ +VOID i3600 (VOID) +{ + *(base + (W_DF | *(base + (IF | (PC & 07600) | (INST & 0177))))) + = AC & 07777 ; + AC &= 010000 ; + EXECUTION_TIME (38); +} +/* -------------------------------------------------------------------- */ +VOID i3610 (VOID) +{ + REG UINT page = PC & 07600 ; + REG UWORD *p = base + (IF | page | (INST & 0177)) ; + if (!page) + *p = (*p + 1) & 07777 ; + *(base + (W_DF | *p)) = AC & 07777 ; + AC &= 010000 ; + EXECUTION_TIME (page ? 38 : 40); +} +/* -------------------------------------------------------------------- */ +VOID i4000 (VOID) +{ + REG UINT temp = INST & 0177 ; + *(base + (W_IB | temp)) = (PC + 1) & 07777 ; + PC = temp ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (26); +} +VOID u4000 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + PC = INST & 0177; + EXECUTION_TIME (26); + } else + i4000 (); +} +/* -------------------------------------------------------------------- */ +VOID i4200 (VOID) +{ + REG UINT temp = (PC & 07600) | (INST & 0177) ; + *(base + (W_IB | temp)) = (PC + 1) & 07777 ; + PC = temp ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (26); +} +VOID u4200 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + PC = (PC & 07600) | (INST & 0177); + EXECUTION_TIME (26); + } else + i4200 (); +} +/* -------------------------------------------------------------------- */ +VOID i4400 (VOID) +{ + REG UINT temp = *(base + (IF | (INST & 0177))) ; + *(base + (W_IB | temp )) = (PC + 1) & 07777 ; + PC = temp ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (38); +} +VOID u4400 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + PC = *(base + (IF | (INST & 0177))); + EXECUTION_TIME (38); + } else + i4400 (); +} +/* -------------------------------------------------------------------- */ +VOID i4410 (VOID) +{ + REG UWORD *p = base + (IF | (INST & 0177)) ; + *(base + (W_IB | (*p = (*p + 1) & 07777))) = (PC + 1) & 07777 ; + PC = *p ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (40); +} +VOID u4410 (VOID) /* user mode with TSC8-75 */ +/* this opcode is not checked by the TSC8.SV hardware diagnostics */ +{ + REG UWORD *p; + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + p = base + (IF | (INST & 0177)); + PC = *p = (*p + 1) & 07777; + EXECUTION_TIME (40); + } else + i4410 (); +} +/* -------------------------------------------------------------------- */ +VOID i4600 (VOID) +{ + REG UINT temp = *(base + (IF | (PC & 07600) | (INST & 0177))) ; + *(base + (W_IB | temp)) = (PC + 1) & 07777 ; + PC = temp ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (38); +} +VOID u4600 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + PC = *(base + (IF | (PC & 07600) | (INST & 0177))); + EXECUTION_TIME (38); + } else + i4600 (); +} +/* -------------------------------------------------------------------- */ +VOID i4610 (VOID) +{ + REG UINT page = PC & 07600 ; + REG UWORD *p = base + (IF | page | (INST & 0177)) ; + if (!page) + *p = (*p + 1) & 07777 ; + *(base + (W_IB | *p)) = (PC + 1) & 07777 ; + PC = *p ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (page ? 38 : 40); +} +VOID u4610 (VOID) /* user mode with TSC8-75 */ +/* the TSC8.SV hardware diagnostics doesn´t check this opcode at the autoincrement memory locations */ +{ + REG UINT page; + REG UWORD *p; + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + page = PC & 07600; + p = base + (IF | page | (INST & 0177)); + if (! page) + *p = (*p + 1) & 07777; + PC = *p; + EXECUTION_TIME (page ? 38 : 40); + } else + i4610 (); +} +/* -------------------------------------------------------------------- */ +VOID i5000 (VOID) +{ + PC = (INST & 0177) - 1 ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (12); +} +VOID u5000 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + } + i5000 (); +} +/* -------------------------------------------------------------------- */ +VOID i5200 (VOID) +{ + PC = ((PC & 07600) | (INST & 0177)) - 1 ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (12); +} +VOID u5200 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + } + i5200 (); +} +/* -------------------------------------------------------------------- */ +VOID i5400 (VOID) +{ + PC = *(base + (IF | (INST & 0177))) - 1 ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (24); +} +VOID u5400 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + } + i5400 (); +} +/* -------------------------------------------------------------------- */ +VOID i5410 (VOID) +{ + REG UWORD *p = base + (IF | (INST & 0177)) ; + PC = *p ; + *p = (*p + 1) & 07777 ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (26); +} +VOID u5410 (VOID) /* user mode with TSC8-75 */ +/* this opcode is not checked by the TSC8.SV hardware diagnostics */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + } + i5410 (); +} +/* -------------------------------------------------------------------- */ +VOID i5600 (VOID) +{ + PC = *(base + (IF | (PC & 07600) | (INST & 0177))) - 1 ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (24); +} +VOID u5600 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + } + i5600 (); +} +/* -------------------------------------------------------------------- */ +VOID i5610 (VOID) +{ + REG UINT page = PC & 07600 ; + REG UWORD *p = base + (IF | page | (INST & 0177)) ; + if (!page) + *p = (*p + 1) & 07777 ; + PC = *p - 1 ; + IF = IB ; + if (hw.hasKM8Etimesharing) + UF = UB ; + int_inh = false ; + EXECUTION_TIME (page ? 24 : 26); +} +VOID u5610 (VOID) /* user mode with TSC8-75 */ +{ + tsc8.eriot = INST; + tsc8.ecdf = 0; + if (int_mask & tsc8.flag) { + tsc8.ertb = PC; + io_flags |= tsc8.flag; + } + i5610 (); +} +/* -------------------------------------------------------------------- */ diff --git a/Emulation/mri.h b/Emulation/mri.h new file mode 100644 index 0000000..e39dc90 --- /dev/null +++ b/Emulation/mri.h @@ -0,0 +1,95 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * mri.h - Interface for the MRI instructions code for the PDP-8/E + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Memory Reference Instruction (MRI) module. + */ +/* -------------------------------------------------------------------- */ +extern void i0000 (void) ; +extern void i0200 (void) ; +extern void i0400 (void) ; +extern void i0410 (void) ; +extern void i0600 (void) ; +extern void i0610 (void) ; +extern void i1000 (void) ; +extern void i1200 (void) ; +extern void i1400 (void) ; +extern void i1410 (void) ; +extern void i1600 (void) ; +extern void i1610 (void) ; +extern void i2000 (void) ; +extern unsigned s2000 (void) ; +extern void i2200 (void) ; +extern unsigned s2200 (void) ; +extern void i2400 (void) ; +extern unsigned s2400 (void) ; +extern void i2410 (void) ; +extern unsigned s2410 (void) ; +extern void i2600 (void) ; +extern unsigned s2600 (void) ; +extern void i2610 (void) ; +extern unsigned s2610 (void) ; +extern void i3000 (void) ; +extern void i3200 (void) ; +extern void i3400 (void) ; +extern void i3410 (void) ; +extern void i3600 (void) ; +extern void i3610 (void) ; +extern void i4000 (void) ; +extern void u4000 (void) ; +extern void i4200 (void) ; +extern void u4200 (void) ; +extern void i4400 (void) ; +extern void u4400 (void) ; +extern void i4410 (void) ; +extern void u4410 (void) ; +extern void i4600 (void) ; +extern void u4600 (void) ; +extern void i4610 (void) ; +extern void u4610 (void) ; +extern void i5000 (void) ; +extern void u5000 (void) ; +extern void i5200 (void) ; +extern void u5200 (void) ; +extern void i5400 (void) ; +extern void u5400 (void) ; +extern void i5410 (void) ; +extern void u5410 (void) ; +extern void i5600 (void) ; +extern void u5600 (void) ; +extern void i5610 (void) ; +extern void u5610 (void) ; +/* -------------------------------------------------------------------- */ diff --git a/Emulation/opr.c b/Emulation/opr.c new file mode 100644 index 0000000..46d08c8 --- /dev/null +++ b/Emulation/opr.c @@ -0,0 +1,3062 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * opr.c - Operate instructions code for the PDP-8/E + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Operate microinstruction (OPR) module for all OPRs except EAE. + * + * Questions: + * 1. Does every microprogrammed combo of MQL MQA + * yield a SWP instruction ? (page 3-17) + */ + + +#import + +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#include "PDP8.h" +#include "opr.h" +#include "pdp8defines.h" + + +/* + * Operate microinstructions + * + * | | | | + * |---|---|---|---|---|---|---|---|---| + * | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10| 11| Group I + * | 0 |CLA|CLL|CMA|CML|RAR|RAL|BSW|IAC| + * |---|---|---|---|---|---|---|---|---| + * Sequence: 1 1 2 2 4 4 4 3 + * + * | | | | + * |---|---|---|---|---|---|---|---|---| + * | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10| 11| + * | 1 |CLA|SMA|SZA|SNL|FL |OSR|HLT| 0 | Group II + * | 1 |CLA|SPA SNA SZL| AG|OSR|HLT| 0 | + * |---|---|---|---|---|---|---|---|---| + * Sequence: 2 1 1 1 1 3 4 + * + */ +/* -------------------------------------------------------------------- */ +VOID i7000 (VOID) /* NOP */ +{ + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7001 (VOID) /* IAC */ +{ + AC = (AC + 1) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7002 (VOID) /* BSW */ +{ + AC = (AC & 010000) | ((AC & 077) << 6) | ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7003 (VOID) /* IAC BSW */ +{ + AC++; + AC = (AC & 010000) + ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7004 (VOID) /* RAL */ +{ + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7005 (VOID) /* IAC RAL */ +{ + AC = (AC + 1) & 017777 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7006 (VOID) /* RTL */ +{ + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7007 (VOID) /* IAC RTL */ +{ + AC = (AC + 1) & 017777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7010 (VOID) /* RAR */ +{ + AC = ((AC << 12) + (AC >> 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7011 (VOID) /* IAC RAR */ +{ + AC = (AC + 1) & 017777 ; + AC = ((AC << 12) + (AC >> 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7012 (VOID) /* RTR */ +{ + AC = ((AC << 11) + (AC >> 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7013 (VOID) /* IAC RTR */ +{ + AC = (AC + 1) & 017777 ; + AC = ((AC << 11) + (AC >> 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7014 (VOID) /* RAR RAL (reserved) */ +{ + AC = AC & 017014; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7015 (VOID) /* IAC RAR RAL (reserved) */ +{ + AC = (AC + 1) & 017015 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7016 (VOID) /* RTR RTL (reserved) */ +{ + AC = (AC & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7017 (VOID) /* IAC RTR RTL (reserved) */ +{ + AC = ((AC + 1) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7020 (VOID) /* CML */ +{ + AC ^= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7021 (VOID) /* CML IAC */ +{ + AC = ((AC ^ 010000) + 1) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7022 (VOID) /* CML BSW */ +{ + AC = ((AC ^ 010000) & 010000) + + ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7023 (VOID) /* CML IAC BSW */ +{ + AC = (AC ^ 010000) + 1 ; + AC = (AC & 010000) + ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7024 (VOID) /* CML RAL */ +{ + AC ^= 010000 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7025 (VOID) /* CML IAC RAL */ +{ + AC = ((AC ^ 010000) + 1) & 017777 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7026 (VOID) /* CML RTL */ +{ + AC = (((AC ^ 010000) >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7027 (VOID) /* CML IAC RTL */ +{ + AC = ((AC ^ 010000) + 1) & 017777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7030 (VOID) /* CML RAR */ +{ + AC = ((AC << 12) + ((AC ^ 010000) >> 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7031 (VOID) /* CML IAC RAR */ +{ + AC = ((AC ^ 010000) + 1) & 017777 ; + AC = ((AC << 12) + (AC >> 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7032 (VOID) /* CML RTR */ +{ + AC = (((AC ^ 010000) >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7033 (VOID) /* CML IAC RTR */ +{ + AC = ((AC ^ 010000) + 1) & 017777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7034 (VOID) /* CML RAR RAL (reserved) */ +{ + AC ^= 010000 ; + AC &= 017034 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7035 (VOID) /* CML IAC RAR RAL (reserved) */ +{ + AC = ((AC ^ 010000) + 1) & 017035 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7036 (VOID) /* CML RTR RTL (reserved) */ +{ + AC ^= 010000 ; + AC = (AC & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7037 (VOID) /* CML IAC RTR RTL (reserved) */ +{ + AC = (AC ^ 010000) + 1 ; + AC = (AC & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7040 (VOID) /* CMA */ +{ + AC ^= 07777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7041 (VOID) /* CMA IAC */ +{ + AC = ((AC ^ 07777) + 1) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7042 (VOID) /* CMA BSW */ +{ + AC ^= 07777 ; + AC = (AC & 010000) + ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7043 (VOID) /* CMA IAC BSW */ +{ + AC = (AC ^ 07777) + 1 ; + AC = (AC & 010000) + ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7044 (VOID) /* CMA RAL */ +{ + AC ^= 07777 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7045 (VOID) /* CMA IAC RAL */ +{ + AC = ((AC ^ 07777) + 1) & 017777 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7046 (VOID) /* CMA RTL */ +{ + AC ^= 07777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7047 (VOID) /* CMA IAC RTL */ +{ + AC = ((AC ^ 07777) + 1) & 017777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7050 (VOID) /* CMA RAR */ +{ + AC ^= 07777 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7051 (VOID) /* CMA IAC RAR */ +{ + AC = ((AC ^ 07777) + 1) & 017777 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7052 (VOID) /* CMA RTR */ +{ + AC ^= 07777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7053 (VOID) /* CMA IAC RTR */ +{ + AC = ((AC ^ 07777) + 1) & 017777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7054 (VOID) /* CMA RAR RAL (reserved) */ +{ + AC ^= 07777 ; + AC &= 017054 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7055 (VOID) /* CMA IAC RAR RAL (reserved) */ +{ + AC = ((AC ^ 07777) + 1) & 017055 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7056 (VOID) /* CMA RTR RTL (reserved) */ +{ + AC = (AC & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7057 (VOID) /* CMA IAC RTR RTL (reserved) */ +{ + AC = (((AC ^ 07777) + 1) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7060 (VOID) /* CMA CML */ +{ + AC ^= 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7061 (VOID) /* CMA CML IAC */ +{ + AC = (-AC) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7062 (VOID) /* CMA CML BSW */ +{ + AC ^= 017777 ; + AC = (AC & 010000) + ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7063 (VOID) /* CMA CML IAC BSW */ +{ + AC = -AC ; + AC = (AC & 010000) + ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7064 (VOID) /* CMA CML RAL */ +{ + AC ^= 017777 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7065 (VOID) /* CMA CML IAC RAL */ +{ + AC = (-AC) & 017777 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7066 (VOID) /* CMA CML RTL */ +{ + AC ^= 017777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7067 (VOID) /* CMA CML IAC RTL */ +{ + AC = (-AC) & 017777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7070 (VOID) /* CMA CML RAR */ +{ + AC ^= 017777 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7071 (VOID) /* CMA CML IAC RAR */ +{ + AC = (-AC) & 017777 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7072 (VOID) /* CMA CML RTR */ +{ + AC ^= 017777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7073 (VOID) /* CMA CML IAC RTR */ +{ + AC = (-AC) & 017777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7074 (VOID) /* CMA CML RAR RAL (reserved) */ +{ + AC ^= 017777 ; + AC &= 017074 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7075 (VOID) /* CMA CML IAC RAR RAL */ +{ /* (reserved) */ + AC = (-AC) & 017075 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7076 (VOID) /* CMA CML RTR RTL (reserved) */ +{ + AC = ((AC ^ 010000) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7077 (VOID) /* CMA CML IAC RTR RTL */ +{ /* (reserved) */ + AC = ((-AC) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7100 (VOID) /* CLL */ +{ + AC &= 07777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7101 (VOID) /* CLL IAC */ +{ + AC = (AC & 07777) + 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7102 (VOID) /* CLL BSW */ +{ + AC = ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7103 (VOID) /* CLL IAC BSW */ +{ + AC = (AC & 07777) + 1 ; + AC = (AC & 010000) + ((AC & 077) << 6) + ((AC & 07700) >> 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7104 (VOID) /* CLL RAL */ +{ + AC = (AC & 07777) << 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7105 (VOID) /* CLL IAC RAL */ +{ + AC = (AC & 07777) + 1 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7106 (VOID) /* CLL RTL */ +{ + AC &= 07777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7107 (VOID) /* CLL IAC RTL */ +{ + AC = (AC & 07777) + 1 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7110 (VOID) /* CLL RAR */ +{ + AC = ((AC & 07776) >> 1) + ((AC & 1) << 12) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7111 (VOID) /* CLL IAC RAR */ +{ + AC = (AC & 07777) + 1 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7112 (VOID) /* CLL RTR */ +{ + AC &= 07777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7113 (VOID) /* CLL IAC RTR */ +{ + AC = (AC & 07777) + 1 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7114 (VOID) /* CLL RAR RAL (reserved) */ +{ + AC &= 07114 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7115 (VOID) /* CLL IAC RAR RAL (reserved) */ +{ + AC = ((AC & 07777) + 1) & 017115 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7116 (VOID) /* CLL RTR RTL (reserved) */ +{ + AC = (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7117 (VOID) /* CLL IAC RTR RTL (reserved) */ +{ + AC = (((AC & 07777) + 1) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7120 (VOID) /* CLL CML */ +{ + AC |= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7121 (VOID) /* CLL CML IAC */ +{ + AC = ((AC | 010000) + 1) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7122 (VOID) /* CLL CML BSW */ +{ + AC = 010000 + ((AC & 07700) >> 6) + ((AC & 077) << 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7123 (VOID) /* CLL CML IAC BSW */ +{ + AC = (AC | 010000) + 1 ; + AC = (AC & 010000) + ((AC & 07700) >> 6) + ((AC & 077) << 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7124 (VOID) /* CLL CML RAL */ +{ + AC |= 010000 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7125 (VOID) /* CLL CML IAC RAL */ +{ + AC = ((AC | 010000) + 1) & 017777 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7126 (VOID) /* CLL CML RTL */ +{ + AC |= 010000 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7127 (VOID) /* CLL CML IAC RTL */ +{ + AC = ((AC | 010000) + 1) & 017777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7130 (VOID) /* CLL CML RAR */ +{ + AC = ((AC | 010000) >> 1) + ((AC & 1) << 12) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7131 (VOID) /* CLL CML IAC RAR */ +{ + AC = ((AC | 010000) + 1) & 017777 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7132 (VOID) /* CLL CML RTR */ +{ + AC = ((AC | 010000) >> 2) + ((AC & 3) << 11) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7133 (VOID) /* CLL CML IAC RTR */ +{ + AC = ((AC | 010000) + 1) & 017777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7134 (VOID) /* CLL CML RAR RAL (reserved) */ +{ + AC = (AC | 010000) & 017134 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7135 (VOID) /* CLL CML IAC RAR RAL */ +{ /* (reserved) */ + AC = ((AC | 010000) + 1) & 017135 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7136 (VOID) /* CLL CML RTR RTL (reserved) */ +{ + AC = 010000 | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7137 (VOID) /* CLL CML IAC RTR RTL */ +{ /* (reserved) */ + AC = (((AC | 010000) + 1) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7140 (VOID) /* CLL CMA */ +{ + AC = (AC & 07777) ^ 07777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7141 (VOID) /* CLL CMA IAC */ +{ + AC = ((AC & 07777) ^ 07777) + 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7142 (VOID) /* CLL CMA BSW */ +{ + AC ^= 07777 ; + AC = ((AC & 07700) >> 6) + ((AC & 077) << 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7143 (VOID) /* CLL CMA IAC BSW */ +{ + AC = ((AC & 07777) ^ 07777) + 1 ; + AC = (AC & 010000) + ((AC & 07700) >> 6) + ((AC & 077) << 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7144 (VOID) /* CLL CMA RAL */ +{ + AC = ((AC & 07777) ^ 07777) << 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7145 (VOID) /* CLL CMA IAC RAL */ +{ + AC = ((AC & 07777) ^ 07777) + 1 ; + AC = ((AC >> 12) + (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7146 (VOID) /* CLL CMA RTL */ +{ + AC = (AC & 07777) ^ 07777 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7147 (VOID) /* CLL CMA IAC RTL */ +{ + AC = ((AC & 07777) ^ 07777) + 1 ; + AC = ((AC >> 11) + (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7150 (VOID) /* CLL CMA RAR */ +{ + AC = (AC & 07777) ^ 07777 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7151 (VOID) /* CLL CMA IAC RAR */ +{ + AC = ((AC & 07777) ^ 07777) + 1 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7152 (VOID) /* CLL CMA RTR */ +{ + AC = (AC & 07777) ^ 07777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7153 (VOID) /* CLL CMA IAC RTR */ +{ + AC = ((AC & 07777) ^ 07777) + 1 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7154 (VOID) /* CLL CMA RAR RAL (reserved) */ +{ + AC = ((AC & 07777) ^ 07777) & 07154 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7155 (VOID) /* CLL CMA IAC RAR RAL */ +{ /* (reserved) */ + AC = (((AC & 07777) ^ 07777) + 1) & 017155 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7156 (VOID) /* CLL CMA RTR RTL (reserved) */ +{ + AC = (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7157 (VOID) /* CLL CMA IAC RTR RTL */ +{ /* (reserved) */ + AC = ((((AC & 07777) ^ 07777) + 1) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7160 (VOID) /* CLL CMA CML */ +{ + AC = (AC & 07777) ^ 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7161 (VOID) /* CLL CMA CML IAC */ +{ + AC = (((AC & 07777) ^ 017777) + 1) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7162 (VOID) /* CLL CMA CML BSW */ +{ + AC ^= 07777 ; + AC = 010000 + ((AC & 07700) >> 6) + ((AC & 077) << 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7163 (VOID) /* CLL CMA CML IAC BSW */ +{ + AC = ((AC & 07777) ^ 017777) + 1 ; + AC = (AC & 010000) + ((AC & 07700) >> 6) + ((AC & 077) << 6) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7164 (VOID) /* CLL CMA CML RAL */ +{ + AC = (((AC & 07777) ^ 07777) << 1) | 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7165 (VOID) /* CLL CMA CML IAC RAL */ +{ + AC = (((AC & 07777) ^ 017777) + 1) & 017777 ; + AC = ((AC >> 12) | (AC << 1)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7166 (VOID) /* CLL CMA CML RTL */ +{ + AC = (AC & 07777) ^ 017777 ; + AC = ((AC >> 11) | (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7167 (VOID) /* CLL CMA CML IAC RTL */ +{ + AC = (((AC & 07777) ^ 017777) + 1) & 017777 ; + AC = ((AC >> 11) | (AC << 2)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7170 (VOID) /* CLL CMA CML RAR */ +{ + AC = (AC & 07777) ^ 017777 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7171 (VOID) /* CLL CMA CML IAC RAR */ +{ + AC = (((AC & 07777) ^ 017777) + 1) & 017777 ; + AC = ((AC >> 1) + (AC << 12)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7172 (VOID) /* CLL CMA CML RTR */ +{ + AC = (AC & 07777) ^ 017777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7173 (VOID) /* CLL CMA CML IAC RTR */ +{ + AC = (((AC & 07777) ^ 017777) + 1) & 017777 ; + AC = ((AC >> 2) + (AC << 11)) & 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7174 (VOID) /* CLL CMA CML RAR RAL */ +{ /* (reserved) */ + AC = ((AC & 07777) ^ 017777) & 017174 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7175 (VOID) /* CLL CMA CML IAC RAR RAL */ +{ /* (reserved) */ + AC = (((AC & 07777) ^ 017777) + 1) & 017175 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7176 (VOID) /* CLL CMA CML RTR RTL */ +{ /* (reserved) */ + AC = (((AC & 07777) ^ 017777) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7177 (VOID) /* CLL CMA CML IAC RTR RTL */ +{ /* (reserved) */ + AC = ((((AC & 07777) ^ 017777) + 1) & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7200 (VOID) /* CLA */ +{ + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7201 (VOID) /* CLA IAC */ +{ + AC = (AC & 010000) + 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7202 (VOID) /* CLA BSW */ +{ + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7203 (VOID) /* CLA IAC BSW */ +{ + AC = (AC & 010000) + 0100 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7204 (VOID) /* CLA RAL */ +{ + AC >>= 12 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7205 (VOID) /* CLA IAC RAL */ +{ + AC = (AC >> 12) + 2 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7206 (VOID) /* CLA RTL */ +{ + AC = (AC & 010000) >> 11 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7207 (VOID) /* CLA IAC RTL */ +{ + AC = ((AC & 010000) >> 11) + 4 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7210 (VOID) /* CLA RAR */ +{ + AC = (AC & 010000) >> 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7211 (VOID) /* CLA IAC RAR */ +{ + AC = 010000 + ((AC & 010000) >> 1) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7212 (VOID) /* CLA RTR */ +{ + AC = (AC & 010000) >> 2 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7213 (VOID) /* CLA IAC RTR */ +{ + AC = 04000 + ((AC & 010000) >> 2) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7214 (VOID) /* CLA RAR RAL (reserved) */ +{ + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7215 (VOID) /* CLA IAC RAR RAL (reserved) */ +{ + AC = (AC & 010000) + 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7216 (VOID) /* CLA RTR RTL (reserved) */ +{ + AC = (AC & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7217 (VOID) /* CLA IAC RTR RTL (reserved) */ +{ + AC = (AC & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7220 (VOID) /* CLA CML */ +{ + AC = (AC & 010000) ^ 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7221 (VOID) /* CLA CML IAC */ +{ + AC = ((AC & 010000) ^ 010000) + 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7222 (VOID) /* CLA CML BSW */ +{ + AC = (AC & 010000) ^ 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7223 (VOID) /* CLA CML IAC BSW */ +{ + AC = ((AC & 010000) ^ 010000) + 0100 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7224 (VOID) /* CLA CML RAL */ +{ + AC = ((AC & 010000) ^ 010000) >> 12 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7225 (VOID) /* CLA CML IAC RAL */ +{ + AC = (((AC & 010000) ^ 010000) >> 12) + 2 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7226 (VOID) /* CLA CML RTL */ +{ + AC = ((AC & 010000) ^ 010000) >> 11 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7227 (VOID) /* CLA CML IAC RTL */ +{ + AC = (((AC & 010000) ^ 010000) >> 11) + 4 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7230 (VOID) /* CLA CML RAR */ +{ + AC = ((AC & 010000) ^ 010000) >> 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7231 (VOID) /* CLA CML IAC RAR */ +{ + AC = 010000 + (((AC & 010000) ^ 010000) >> 1) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7232 (VOID) /* CLA CML RTR */ +{ + AC = ((AC & 010000) ^ 010000) >> 2 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7233 (VOID) /* CLA CML IAC RTR */ +{ + AC = 04000 + (((AC & 010000) ^ 010000) >> 2) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7234 (VOID) /* CLA CML RAR RAL (reserved) */ +{ + AC = (AC & 010000) ^ 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7235 (VOID) /* CLA CML IAC RAR RAL */ +{ /* (reserved) */ + AC = ((AC & 010000) ^ 010000) + 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7236 (VOID) /* CLA CML RTR RTL (reserved) */ +{ + AC = ((AC & 010000) ^ 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7237 (VOID) /* CLA CML IAC RTR RTL */ +{ /* (reserved) */ + AC = ((AC & 010000) ^ 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7240 (VOID) /* CLA CMA */ +{ + AC = (AC & 010000) + 07777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7241 (VOID) /* CLA CMA IAC */ +{ + AC = (AC & 010000) ^ 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7242 (VOID) /* CLA CMA BSW */ +{ + AC |= 07777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7243 (VOID) /* CLA CMA IAC BSW */ +{ + AC = (AC & 010000) ^ 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7244 (VOID) /* CLA CMA RAL */ +{ + AC = (AC >> 12) | 017776 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7245 (VOID) /* CLA CMA IAC RAL */ +{ + AC = ((AC & 010000) ^ 010000) >> 12 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7246 (VOID) /* CLA CMA RTL */ +{ + AC = 017775 + ((AC & 010000) >> 11) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7247 (VOID) /* CLA CMA IAC RTL */ +{ + AC = ((AC & 010000) ^ 010000) >> 11 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7250 (VOID) /* CLA CMA RAR */ +{ + AC = 013777 + ((AC & 010000) >> 1) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7251 (VOID) /* CLA CMA IAC RAR */ +{ + AC = ((AC & 010000) ^ 010000) >> 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7252 (VOID) /* CLA CMA RTR */ +{ + AC = 015777 + ((AC & 010000) >> 2) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7253 (VOID) /* CLA CMA IAC RTR */ +{ + AC = ((AC & 010000) ^ 010000) >> 2 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7254 (VOID) /* CLA CMA RAR RAL (reserved) */ +{ + AC = (AC & 010000) | 07254 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7255 (VOID) /* CLA CMA IAC RAR RAL */ +{ /* (reserved) */ + AC = (AC & 010000) ^ 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7256 (VOID) /* CLA CMA RTR RTL (reserved) */ +{ + AC = (AC & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7257 (VOID) /* CLA CMA IAC RTR RTL */ +{ /* (reserved) */ + AC = ((AC & 010000) ^ 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7260 (VOID) /* CLA CMA CML */ +{ + AC = (AC | 07777) ^ 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7261 (VOID) /* CLA CMA CML IAC */ +{ + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7262 (VOID) /* CLA CMA CML BSW */ +{ + AC = (AC | 07777) ^ 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7263 (VOID) /* CLA CMA CML IAC BSW */ +{ + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7264 (VOID) /* CLA CMA CML RAL */ +{ + AC = 017776 | (AC >> 12) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7265 (VOID) /* CLA CMA CML IAC RAL */ +{ + AC = (AC & 010000) >> 12 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7266 (VOID) /* CLA CMA CML RTL */ +{ + AC = 017775 | (AC >> 11) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7267 (VOID) /* CLA CMA CML IAC RTL */ +{ + AC = (AC & 010000) >> 11 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7270 (VOID) /* CLA CMA CML RAR */ +{ + AC = 013777 | (AC >> 1) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7271 (VOID) /* CLA CMA CML IAC RAR */ +{ + AC = (AC & 010000) >> 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7272 (VOID) /* CLA CMA CML RTR */ +{ + AC = 015777 | (AC >> 2) ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7273 (VOID) /* CLA CMA CML IAC RTR */ +{ + AC = (AC & 010000) >> 2 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7274 (VOID) /* CLA CMA CML RAR RAL */ +{ /* (reserved) */ + AC = ((AC & 010000) ^ 010000) | 07274 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7275 (VOID) /* CLA CMA CML IAC RAR RAL */ +{ /* (reserved) */ + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7276 (VOID) /* CLA CMA CML RTR RTL */ +{ /* (reserved) */ + AC = ((AC & 010000) ^ 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7277 (VOID) /* CLA CMA CML IAC RTR RTL */ +{ /* (reserved) */ + AC = (AC & 010000) | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7300 (VOID) /* CLA CLL */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7301 (VOID) /* CLA CLL IAC */ +{ + AC = 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7302 (VOID) /* CLA CLL BSW */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7303 (VOID) /* CLA CLL IAC BSW */ +{ + AC = 0100 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7304 (VOID) /* CLA CLL RAL */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7305 (VOID) /* CLA CLL IAC RAL */ +{ + AC = 2 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7306 (VOID) /* CLA CLL RTL */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7307 (VOID) /* CLA CLL IAC RTL */ +{ + AC = 4 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7310 (VOID) /* CLA CLL RAR */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7311 (VOID) /* CLA CLL IAC RAR */ +{ + AC = 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7312 (VOID) /* CLA CLL RTR */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7313 (VOID) /* CLA CLL IAC RTR */ +{ + AC = 04000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7314 (VOID) /* CLA CLL RAR RAL (reserved) */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7315 (VOID) /* CLA CLL IAC RAR RAL */ +{ /* (reserved) */ + AC = 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7316 (VOID) /* CLA CLL RTR RTL (reserved) */ +{ + AC = (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7317 (VOID) /* CLA CLL IAC RTR RTL */ +{ /* (reserved) */ + AC = (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7320 (VOID) /* CLA CLL CML */ +{ + AC = 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7321 (VOID) /* CLA CLL CML IAC */ +{ + AC = 010001 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7322 (VOID) /* CLA CLL CML BSW */ +{ + AC = 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7323 (VOID) /* CLA CLL CML IAC BSW */ +{ + AC = 010100 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7324 (VOID) /* CLA CLL CML RAL */ +{ + AC = 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7325 (VOID) /* CLA CLL CML IAC RAL */ +{ + AC = 3 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7326 (VOID) /* CLA CLL CML RTL */ +{ + AC = 2 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7327 (VOID) /* CLA CLL CML IAC RTL */ +{ + AC = 6 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7330 (VOID) /* CLA CLL CML RAR */ +{ + AC = 04000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7331 (VOID) /* CLA CLL CML IAC RAR */ +{ + AC = 014000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7332 (VOID) /* CLA CLL CML RTR */ +{ + AC = 02000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7333 (VOID) /* CLA CLL CML IAC RTR */ +{ + AC = 06000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7334 (VOID) /* CLA CLL CML RAR RAL */ +{ /* (reserved) */ + AC = 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7335 (VOID) /* CLA CLL CML IAC RAR RAL */ +{ /* (reserved) */ + AC = 010001 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7336 (VOID) /* CLA CLL CML RTR RTL */ +{ /* (reserved) */ + AC = 010000 | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7337 (VOID) /* CLA CLL CML IAC RTR RTL */ +{ /* (reserved) */ + AC = 010000 | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7340 (VOID) /* CLA CLL CMA */ +{ + AC = 07777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7341 (VOID) /* CLA CLL CMA IAC */ +{ + AC = 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7342 (VOID) /* CLA CLL CMA BSW */ +{ + AC = 07777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7343 (VOID) /* CLA CLL CMA IAC BSW */ +{ + AC = 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7344 (VOID) /* CLA CLL CMA RAL */ +{ + AC = 017776 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7345 (VOID) /* CLA CLL CMA IAC RAL */ +{ + AC = 1 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7346 (VOID) /* CLA CLL CMA RTL */ +{ + AC = 017775 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7347 (VOID) /* CLA CLL CMA IAC RTL */ +{ + AC = 02 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7350 (VOID) /* CLA CLL CMA RAR */ +{ + AC = 013777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7351 (VOID) /* CLA CLL CMA IAC RAR */ +{ + AC = 04000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7352 (VOID) /* CLA CLL CMA RTR */ +{ + AC = 05777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7353 (VOID) /* CLA CLL CMA IAC RTR */ +{ + AC = 02000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7354 (VOID) /* CLA CLL CMA RAR RAL */ +{ /* (reserved) */ + AC = 07354 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7355 (VOID) /* CLA CLL CMA IAC RAR RAL */ +{ /* (reserved) */ + AC = 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7356 (VOID) /* CLA CLL CMA RTR RTL */ +{ /* (reserved) */ + AC = (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7357 (VOID) /* CLA CLL CMA IAC RTR RTL */ +{ /* (reserved) */ + AC = 010000 | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7360 (VOID) /* CLA CLL CMA CML */ +{ + AC = 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7361 (VOID) /* CLA CLL CMA CML IAC */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7362 (VOID) /* CLA CLL CMA CML BSW */ +{ + AC = 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7363 (VOID) /* CLA CLL CMA CML IAC BSW */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7364 (VOID) /* CLA CLL CMA CML RAL */ +{ + AC = 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7365 (VOID) /* CLA CLL CMA CML IAC RAL */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7366 (VOID) /* CLA CLL CMA CML RTL */ +{ + AC = 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7367 (VOID) /* CLA CLL CMA CML IAC RTL */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7370 (VOID) /* CLA CLL CMA CML RAR */ +{ + AC = 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7371 (VOID) /* CLA CLL CMA CML IAC RAR */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7372 (VOID) /* CLA CLL CMA CML RTR */ +{ + AC = 017777 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7373 (VOID) /* CLA CLL CMA CML IAC RTR */ +{ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7374 (VOID) /* CLA CLL CMA CML RAR RAL */ +{ /* (reserved) */ + AC = 017374 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7375 (VOID) /* CLA CLL CMA CML IAC RAR RAL */ +{ /* (reserved) */ + AC = 0 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7376 (VOID) /* CLA CLL CMA CML RTR RTL */ +{ /* (reserved) */ + AC = 010000 | (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7377 (VOID) /* CLA CLL CMA CML IAC RTR RTL */ +{ /* (reserved) */ + AC = (PC & 07600) | 016 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7400 (VOID) /* NOP Grp II */ +{ + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7402 (VOID) /* HLT */ +{ + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7404 (VOID) /* OSR */ +{ + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7406 (VOID) /* OSR HLT */ +{ + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7410 (VOID) /* SKP */ +{ + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7410 (VOID) /* SKP */ +{ + return (true); +} +/* -------------------------------------------------------------------- */ +VOID i7412 (VOID) /* SKP HLT */ +{ + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7412 (VOID) /* SKP HLT (user mode) */ +{ + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7414 (VOID) /* SKP OSR */ +{ + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7416 (VOID) /* SKP OSR HLT */ +{ + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7420 (VOID) /* SNL */ +{ + if (AC & 010000) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7420 (VOID) /* SNL */ +{ + return (AC & 010000); +} +/* -------------------------------------------------------------------- */ +VOID i7422 (VOID) /* SNL HLT */ +{ + if (AC & 010000) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7422 (VOID) /* SNL HLT (user mode) */ +{ + if (AC & 010000) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7424 (VOID) /* SNL OSR */ +{ + if (AC & 010000) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7426 (VOID) /* SNL OSR HLT */ +{ + if (AC & 010000) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7430 (VOID) /* SZL */ +{ + if (!(AC & 010000)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7430 (VOID) /* SZL */ +{ + return (! (AC & 010000)); +} +/* -------------------------------------------------------------------- */ +VOID i7432 (VOID) /* SZL HLT */ +{ + if (!(AC & 010000)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7432 (VOID) /* SZL HLT (user mode) */ +{ + if (!(AC & 010000)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7434 (VOID) /* SZL OSR */ +{ + if (!(AC & 010000)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7436 (VOID) /* SZL OSR HLT */ +{ + if (!(AC & 010000)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7440 (VOID) /* SZA */ +{ + if (!(AC & 07777)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7440 (VOID) /* SZA */ +{ + return (! (AC & 07777)); +} +/* -------------------------------------------------------------------- */ +VOID i7442 (VOID) /* SZA HLT */ +{ + if (!(AC & 07777)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7442 (VOID) /* SZA HLT (user mode) */ +{ + if (!(AC & 07777)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7444 (VOID) /* SZA OSR */ +{ + if (!(AC & 07777)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7446 (VOID) /* SZA OSR HLT */ +{ + if (!(AC & 07777)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7450 (VOID) /* SNA */ +{ + if (AC & 07777) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7450 (VOID) /* SNA */ +{ + return (AC & 07777); +} +/* -------------------------------------------------------------------- */ +VOID i7452 (VOID) /* SNA HLT */ +{ + if (AC & 07777) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7452 (VOID) /* SNA HLT (user mode) */ +{ + if (AC & 07777) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7454 (VOID) /* SNA OSR */ +{ + if (AC & 07777) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7456 (VOID) /* SNA OSR HLT */ +{ + if (AC & 07777) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7460 (VOID) /* SZA SNL */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7460 (VOID) /* SZA SNL */ +{ + return ((AC & 07777) == 0 || (AC & 010000)); +} +/* -------------------------------------------------------------------- */ +VOID i7462 (VOID) /* SZA SNL HLT */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7462 (VOID) /* SZA SNL HLT (user mode) */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7464 (VOID) /* SZA SNL OSR */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7466 (VOID) /* SZA SNL OSR HLT */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7470 (VOID) /* SNA SZL */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7470 (VOID) /* SNA SZL */ +{ + return ((AC & 07777) && ! (AC & 010000)); +} +/* -------------------------------------------------------------------- */ +VOID i7472 (VOID) /* SNA SZL HLT */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7472 (VOID) /* SNA SZL HLT (user mode) */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7474 (VOID) /* SNA SZL OSR */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7476 (VOID) /* SNA SZL OSR HLT */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7500 (VOID) /* SMA */ +{ + if (AC & 04000) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7500 (VOID) /* SMA */ +{ + return (AC & 04000); +} +/* -------------------------------------------------------------------- */ +VOID i7502 (VOID) /* SMA HLT */ +{ + if (AC & 04000) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7502 (VOID) /* SMA HLT (user mode) */ +{ + if (AC & 04000) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7504 (VOID) /* SMA OSR */ +{ + if (AC & 04000) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7506 (VOID) /* SMA OSR HLT */ +{ + if (AC & 04000) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7510 (VOID) /* SPA */ +{ + if (!(AC & 04000)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7510 (VOID) /* SPA */ +{ + return (! (AC & 04000)); +} +/* -------------------------------------------------------------------- */ +VOID i7512 (VOID) /* SPA HLT */ +{ + if (!(AC & 04000)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7512 (VOID) /* SPA HLT (user mode) */ +{ + if (!(AC & 04000)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7514 (VOID) /* SPA OSR */ +{ + if (!(AC & 04000)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7516 (VOID) /* SPA OSR HLT */ +{ + if (!(AC & 04000)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7520 (VOID) /* SMA SNL */ +{ + if (AC & 014000) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7520 (VOID) /* SMA SNL */ +{ + return (AC & 014000); +} +/* -------------------------------------------------------------------- */ +VOID i7522 (VOID) /* SMA SNL HLT */ +{ + if (AC & 014000) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7522 (VOID) /* SMA SNL HLT (user mode) */ +{ + if (AC & 014000) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7524 (VOID) /* SMA SNL OSR */ +{ + if (AC & 014000) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7526 (VOID) /* SMA SNL OSR HLT */ +{ + if (AC & 014000) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7530 (VOID) /* SPA SZL */ +{ + if (!(AC & 014000)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7530 (VOID) /* SPA SZL */ +{ + return (! (AC & 014000)); +} +/* -------------------------------------------------------------------- */ +VOID i7532 (VOID) /* SPA SZL HLT */ +{ + if (!(AC & 014000)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7532 (VOID) /* SPA SZL HLT (user mode) */ +{ + if (!(AC & 014000)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7534 (VOID) /* SPA SZL OSR */ +{ + if (!(AC & 014000)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7536 (VOID) /* SPA SZL OSR HLT */ +{ + if (!(AC & 014000)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7540 (VOID) /* SMA SZA */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7540 (VOID) /* SMA SZA */ +{ + return ((AC & 04000) || ! (AC & 07777)); +} +/* -------------------------------------------------------------------- */ +VOID i7542 (VOID) /* SMA SZA HLT */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7542 (VOID) /* SMA SZA HLT (user mode) */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7544 (VOID) /* SMA SZA OSR */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7546 (VOID) /* SMA SZA OSR HLT */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7550 (VOID) /* SPA SNA */ +{ + if (!(AC & 04000) && (AC & 03777)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7550 (VOID) /* SPA SNA */ +{ + return (! (AC & 04000) && (AC & 03777)); +} +/* -------------------------------------------------------------------- */ +VOID i7552 (VOID) /* SPA SNA HLT */ +{ + if ((AC & 04000) == 0 && (AC & 03777)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7552 (VOID) /* SPA SNA HLT (user mode) */ +{ + if ((AC & 04000) == 0 && (AC & 03777)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7554 (VOID) /* SPA SNA OSR */ +{ + if ((AC & 04000) == 0 && (AC & 03777)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7556 (VOID) /* SPA SNA OSR HLT */ +{ + if ((AC & 04000) == 0 && (AC & 03777)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7560 (VOID) /* SMA SZA SNL */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7560 (VOID) /* SMA SZA SNL */ +{ + return ((AC & 07777) == 0 || (AC & 014000)); +} +/* -------------------------------------------------------------------- */ +VOID i7562 (VOID) /* SMA SZA SNL HLT */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7562 (VOID) /* SMA SZA SNL HLT (user mode) */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7564 (VOID) /* SMA SZA SNL OSR */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7566 (VOID) /* SMA SZA SNL OSR HLT */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7570 (VOID) /* SPA SNA SZL */ +{ + if (!(AC & 04000) && (AC & 03777) && !(AC & 010000)) + ++PC ; + EXECUTION_TIME (12); +} +unsigned s7570 (VOID) /* SPA SNA SZL */ +{ + return (! (AC & 04000) && (AC & 03777) && ! (AC & 010000)); +} +/* -------------------------------------------------------------------- */ +VOID i7572 (VOID) /* SPA SNA SZL HLT */ +{ + if (!(AC & 04000) && (AC & 03777) && !(AC & 010000)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7572 (VOID) /* SPA SNA SZL HLT (user mode) */ +{ + if (!(AC & 04000) && (AC & 03777) && !(AC & 010000)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7574 (VOID) /* SPA SNA SZL OSR */ +{ + if (!(AC & 04000) && (AC & 03777) && !(AC & 010000)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7576 (VOID) /* SPA SNA SZL OSR HLT */ +{ + if (!(AC & 04000) && (AC & 03777) && !(AC & 010000)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7600 (VOID) /* CLA Grp II */ +{ + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7602 (VOID) /* CLA HLT */ +{ + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7602 (VOID) /* CLA HLT (user mode) */ +{ + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7604 (VOID) /* CLA OSR */ +{ + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7606 (VOID) /* CLA OSR HLT */ +{ + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7610 (VOID) /* SKP CLA */ +{ + AC &= 010000 ; + ++PC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7612 (VOID) /* SKP CLA HLT */ +{ + AC &= 010000 ; + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7612 (VOID) /* SKP CLA HLT (user mode) */ +{ + AC &= 010000 ; + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7614 (VOID) /* SKP CLA OSR */ +{ + AC &= 010000 ; + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7616 (VOID) /* SKP CLA OSR HLT */ +{ + AC &= 010000 ; + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7620 (VOID) /* SNL CLA */ +{ + if (AC &= 010000) + ++PC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7622 (VOID) /* SNL CLA HLT */ +{ + if (AC &= 010000) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7622 (VOID) /* SNL CLA HLT (user mode) */ +{ + if (AC &= 010000) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7624 (VOID) /* SNL CLA OSR */ +{ + if (AC &= 010000) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7626 (VOID) /* SNL CLA OSR HLT */ +{ + if (AC &= 010000) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7630 (VOID) /* SZL CLA */ +{ + if (!(AC &= 010000)) + ++PC ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7632 (VOID) /* SZL CLA HLT */ +{ + if (!(AC &= 010000)) + ++PC ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7632 (VOID) /* SZL CLA HLT (user mode) */ +{ + if (!(AC &= 010000)) + ++PC ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7634 (VOID) /* SZL CLA OSR */ +{ + if (!(AC &= 010000)) + ++PC ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7636 (VOID) /* SZL CLA OSR HLT */ +{ + if (!(AC &= 010000)) + ++PC ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7640 (VOID) /* SZA CLA */ +{ + if (!(AC & 07777)) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7642 (VOID) /* SZA CLA HLT */ +{ + if (!(AC & 07777)) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7642 (VOID) /* SZA CLA HLT (user mode) */ +{ + if (!(AC & 07777)) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7644 (VOID) /* SZA CLA OSR */ +{ + if (!(AC & 07777)) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7646 (VOID) /* SZA CLA OSR HLT */ +{ + if (!(AC & 07777)) + ++PC ; + AC &= 010000 ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7650 (VOID) /* SNA CLA */ +{ + if (AC & 07777) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7652 (VOID) /* SNA CLA HLT */ +{ + if (AC & 07777) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7652 (VOID) /* SNA CLA HLT (user mode) */ +{ + if (AC & 07777) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7654 (VOID) /* SNA CLA OSR */ +{ + if (AC & 07777) + ++PC ; + AC &= 010000 ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7656 (VOID) /* SNA CLA OSR HLT */ +{ + if (AC & 07777) + ++PC ; + AC &= 010000 ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7660 (VOID) /* SZA SNL CLA */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7662 (VOID) /* SZA SNL CLA HLT */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7662 (VOID) /* SZA SNL CLA HLT (user mode) */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7664 (VOID) /* SZA SNL CLA OSR */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + AC &= 010000 ; + AC |= SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7666 (VOID) /* SZA SNL CLA OSR HLT */ +{ + if ((AC & 07777) == 0 || (AC & 010000)) + ++PC ; + AC &= 010000 ; + AC |= SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7670 (VOID) /* SNA SZL CLA */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7672 (VOID) /* SNA SZL CLA HLT */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7672 (VOID) /* SNA SZL CLA HLT (user mode) */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7674 (VOID) /* SNA SZL CLA OSR */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7676 (VOID) /* SNA SZL CLA OSR HLT */ +{ + if ((AC & 07777) && !(AC & 010000)) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7700 (VOID) /* SMA CLA */ +{ + if (AC & 04000) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7702 (VOID) /* SMA CLA HLT */ +{ + if (AC & 04000) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7702 (VOID) /* SMA CLA HLT */ +{ + if (AC & 04000) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7704 (VOID) /* SMA CLA OSR */ +{ + if (AC & 04000) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7706 (VOID) /* SMA CLA OSR HLT */ +{ + if (AC & 04000) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7710 (VOID) /* SPA CLA */ +{ + if (!(AC & 04000)) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7712 (VOID) /* SPA CLA HLT */ +{ + if (!(AC & 04000)) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7712 (VOID) /* SPA CLA HLT (user mode) */ +{ + if (!(AC & 04000)) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7714 (VOID) /* SPA CLA OSR */ +{ + if (!(AC & 04000)) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7716 (VOID) /* SPA CLA OSR HLT */ +{ + if (!(AC & 04000)) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7720 (VOID) /* SMA SNL CLA */ +{ + if (AC & 014000) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7722 (VOID) /* SMA SNL CLA HLT */ +{ + if (AC & 014000) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7722 (VOID) /* SMA SNL CLA HLT (user mode) */ +{ + if (AC & 014000) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7724 (VOID) /* SMA SNL CLA OSR */ +{ + if (AC & 014000) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7726 (VOID) /* SMA SNL CLA OSR HLT */ +{ + if (AC & 014000) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7730 (VOID) /* SPA SZL CLA */ +{ + if (!(AC & 014000)) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7732 (VOID) /* SPA SZL CLA HLT */ +{ + if (!(AC & 014000)) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7732 (VOID) /* SPA SZL CLA HLT (user mode) */ +{ + if (!(AC & 014000)) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7734 (VOID) /* SPA SZL CLA OSR */ +{ + if (!(AC & 014000)) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7736 (VOID) /* SPA SZL CLA OSR HLT */ +{ + if (!(AC & 014000)) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7740 (VOID) /* SMA SZA CLA */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7742 (VOID) /* SMA SZA CLA HLT */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7742 (VOID) /* SMA SZA CLA HLT (user mode) */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7744 (VOID) /* SMA SZA CLA OSR */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7746 (VOID) /* SMA SZA CLA OSR HLT */ +{ + if ((AC & 04000) || !(AC & 07777)) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7750 (VOID) /* SPA SNA CLA */ +{ + if ((AC & 07777) && (AC & 07777) < 04000) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7752 (VOID) /* SPA SNA CLA HLT */ +{ + if ((AC & 07777) && (AC & 07777) < 04000) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7752 (VOID) /* SPA SNA CLA HLT (user mode) */ +{ + if ((AC & 07777) && (AC & 07777) < 04000) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7754 (VOID) /* SPA SNA CLA OSR */ +{ + if ((AC & 07777) && (AC & 07777) < 04000) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7756 (VOID) /* SPA SNA CLA OSR HLT */ +{ + if ((AC & 07777) && (AC & 07777) < 04000) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7760 (VOID) /* SMA SZA SNL CLA */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7762 (VOID) /* SMA SZA SNL CLA HLT */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7762 (VOID) /* SMA SZA SNL CLA HLT */ +{ /* (user mode) */ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7764 (VOID) /* SMA SZA SNL CLA OSR */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7766 (VOID) /* SMA SZA SNL CLA OSR HLT */ +{ + if ((AC & 07777) == 0 || (AC & 014000)) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7770 (VOID) /* SPA SNA SZL CLA */ +{ + if ((AC & 07777) && !(AC & 014000)) + ++PC ; + AC &= 010000 ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7772 (VOID) /* SPA SNA SZL CLA HLT */ +{ + if ((AC & 07777) && !(AC & 014000)) + ++PC ; + AC &= 010000 ; + run = false ; + EXECUTION_TIME (12); +} +VOID u7772 (VOID) /* SPA SNA SZL CLA HLT */ +{ /* (user mode) */ + if ((AC & 07777) && !(AC & 014000)) + ++PC ; + AC &= 010000 ; + io_flags |= userFLAG ; + tsc8.eriot = INST; + tsc8.ecdf = 0; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7774 (VOID) /* SPA SNA SZL CLA OSR */ +{ + if ((AC & 07777) && !(AC & 014000)) + ++PC ; + AC = (AC & 010000) | SR ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ +VOID i7776 (VOID) /* SPA SNA SZL CLA OSR HLT */ +{ + if ((AC & 07777) && !(AC & 014000)) + ++PC ; + AC = (AC & 010000) | SR ; + run = false ; + EXECUTION_TIME (12); +} +/* -------------------------------------------------------------------- */ diff --git a/Emulation/opr.h b/Emulation/opr.h new file mode 100644 index 0000000..29e4964 --- /dev/null +++ b/Emulation/opr.h @@ -0,0 +1,472 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * opr.h - Interface for the operate instructions code for the PDP-8/E + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +/* + * EMUL-8: a pdp8e emulator. + * + * Author: + * Bill Haygood + * 41832 Ernest Road + * Loon Lake, WA 99148-9607 + * Internet: billh@comtch.iea.com + * Voice/AnsMach/FAX \ + * or 509-233-2555 + * Cellular/Pager / + * + * Copyright 1992, 1993, 1994 by the author with all rights reserved. + * + * Include file for Operate microinstruction (OPR) module + * for all OPRs except EAE. + */ +/* -------------------------------------------------------------------- */ +extern void i7000 (void) ; /* NOP */ +extern void i7001 (void) ; /* IAC */ +extern void i7002 (void) ; /* BSW */ +extern void i7003 (void) ; /* IAC BSW */ +extern void i7004 (void) ; /* RAL */ +extern void i7005 (void) ; /* IAC RAL */ +extern void i7006 (void) ; /* RTL */ +extern void i7007 (void) ; /* IAC RTL */ +extern void i7010 (void) ; /* RAR */ +extern void i7011 (void) ; /* IAC RAR */ +extern void i7012 (void) ; /* RTR */ +extern void i7013 (void) ; /* IAC RTR */ +extern void i7014 (void) ; /* RAR RAL (reserved) */ +extern void i7015 (void) ; /* IAC RAR RAL (reserved) */ +extern void i7016 (void) ; /* RTR RTL (reserved) */ +extern void i7017 (void) ; /* IAC RTR RTL (reserved) */ +extern void i7020 (void) ; /* CML */ +extern void i7021 (void) ; /* CML IAC */ +extern void i7022 (void) ; /* CML BSW */ +extern void i7023 (void) ; /* CML IAC BSW */ +extern void i7024 (void) ; /* CML RAL */ +extern void i7025 (void) ; /* CML IAC RAL */ +extern void i7026 (void) ; /* CML RTL */ +extern void i7027 (void) ; /* CML IAC RTL */ +extern void i7030 (void) ; /* CML RAR */ +extern void i7031 (void) ; /* CML IAC RAR */ +extern void i7032 (void) ; /* CML RTR */ +extern void i7033 (void) ; /* CML IAC RTR */ +extern void i7034 (void) ; /* CML RAR RAL (reserved) */ +extern void i7035 (void) ; /* CML IAC RAR RAL (reserved) */ +extern void i7036 (void) ; /* CML RTR RTL (reserved) */ +extern void i7037 (void) ; /* CML IAC RTR RTL (reserved) */ +extern void i7040 (void) ; /* CMA */ +extern void i7041 (void) ; /* CMA IAC */ +extern void i7042 (void) ; /* CMA BSW */ +extern void i7043 (void) ; /* CMA IAC BSW */ +extern void i7044 (void) ; /* CMA RAL */ +extern void i7045 (void) ; /* CMA IAC RAL */ +extern void i7046 (void) ; /* CMA RTL */ +extern void i7047 (void) ; /* CMA IAC RTL */ +extern void i7050 (void) ; /* CMA RAR */ +extern void i7051 (void) ; /* CMA IAC RAR */ +extern void i7052 (void) ; /* CMA RTR */ +extern void i7053 (void) ; /* CMA IAC RTR */ +extern void i7054 (void) ; /* CMA RAR RAL (reserved) */ +extern void i7055 (void) ; /* CMA IAC RAR RAL (reserved) */ +extern void i7056 (void) ; /* CMA RTR RTL (reserved) */ +extern void i7057 (void) ; /* CMA IAC RTR RTL (reserved) */ +extern void i7060 (void) ; /* CMA CML */ +extern void i7061 (void) ; /* CMA CML IAC */ +extern void i7062 (void) ; /* CMA CML BSW */ +extern void i7063 (void) ; /* CMA CML IAC BSW */ +extern void i7064 (void) ; /* CMA CML RAL */ +extern void i7065 (void) ; /* CMA CML IAC RAL */ +extern void i7066 (void) ; /* CMA CML RTL */ +extern void i7067 (void) ; /* CMA CML IAC RTL */ +extern void i7070 (void) ; /* CMA CML RAR */ +extern void i7071 (void) ; /* CMA CML IAC RAR */ +extern void i7072 (void) ; /* CMA CML RTR */ +extern void i7073 (void) ; /* CMA CML IAC RTR */ +extern void i7074 (void) ; /* CMA CML RAR RAL (reserved) */ +extern void i7075 (void) ; /* CMA CML IAC RAR RAL */ +extern void i7076 (void) ; /* CMA CML RTR RTL (reserved) */ +extern void i7077 (void) ; /* CMA CML IAC RTR RTL */ +extern void i7100 (void) ; /* CLL */ +extern void i7101 (void) ; /* CLL IAC */ +extern void i7102 (void) ; /* CLL BSW */ +extern void i7103 (void) ; /* CLL IAC BSW */ +extern void i7104 (void) ; /* CLL RAL */ +extern void i7105 (void) ; /* CLL IAC RAL */ +extern void i7106 (void) ; /* CLL RTL */ +extern void i7107 (void) ; /* CLL IAC RTL */ +extern void i7110 (void) ; /* CLL RAR */ +extern void i7111 (void) ; /* CLL IAC RAR */ +extern void i7112 (void) ; /* CLL RTR */ +extern void i7113 (void) ; /* CLL IAC RTR */ +extern void i7114 (void) ; /* CLL RAR RAL (reserved) */ +extern void i7115 (void) ; /* CLL IAC RAR RAL (reserved) */ +extern void i7116 (void) ; /* CLL RTR RTL (reserved) */ +extern void i7117 (void) ; /* CLL IAC RTR RTL (reserved) */ +extern void i7120 (void) ; /* CLL CML */ +extern void i7121 (void) ; /* CLL CML IAC */ +extern void i7122 (void) ; /* CLL CML BSW */ +extern void i7123 (void) ; /* CLL CML IAC BSW */ +extern void i7124 (void) ; /* CLL CML RAL */ +extern void i7125 (void) ; /* CLL CML IAC RAL */ +extern void i7126 (void) ; /* CLL CML RTL */ +extern void i7127 (void) ; /* CLL CML IAC RTL */ +extern void i7130 (void) ; /* CLL CML RAR */ +extern void i7131 (void) ; /* CLL CML IAC RAR */ +extern void i7132 (void) ; /* CLL CML RTR */ +extern void i7133 (void) ; /* CLL CML IAC RTR */ +extern void i7134 (void) ; /* CLL CML RAR RAL (reserved) */ +extern void i7135 (void) ; /* CLL CML IAC RAR RAL */ +extern void i7136 (void) ; /* CLL CML RTR RTL (reserved) */ +extern void i7137 (void) ; /* CLL CML IAC RTR RTL */ +extern void i7140 (void) ; /* CLL CMA */ +extern void i7141 (void) ; /* CLL CMA IAC */ +extern void i7142 (void) ; /* CLL CMA BSW */ +extern void i7143 (void) ; /* CLL CMA IAC BSW */ +extern void i7144 (void) ; /* CLL CMA RAL */ +extern void i7145 (void) ; /* CLL CMA IAC RAL */ +extern void i7146 (void) ; /* CLL CMA RTL */ +extern void i7147 (void) ; /* CLL CMA IAC RTL */ +extern void i7150 (void) ; /* CLL CMA RAR */ +extern void i7151 (void) ; /* CLL CMA IAC RAR */ +extern void i7152 (void) ; /* CLL CMA RTR */ +extern void i7153 (void) ; /* CLL CMA IAC RTR */ +extern void i7154 (void) ; /* CLL CMA RAR RAL (reserved) */ +extern void i7155 (void) ; /* CLL CMA IAC RAR RAL */ +extern void i7156 (void) ; /* CLL CMA RTR RTL (reserved) */ +extern void i7157 (void) ; /* CLL CMA IAC RTR RTL */ +extern void i7160 (void) ; /* CLL CMA CML */ +extern void i7161 (void) ; /* CLL CMA CML IAC */ +extern void i7162 (void) ; /* CLL CMA CML BSW */ +extern void i7163 (void) ; /* CLL CMA CML IAC BSW */ +extern void i7164 (void) ; /* CLL CMA CML RAL */ +extern void i7165 (void) ; /* CLL CMA CML IAC RAL */ +extern void i7166 (void) ; /* CLL CMA CML RTL */ +extern void i7167 (void) ; /* CLL CMA CML IAC RTL */ +extern void i7170 (void) ; /* CLL CMA CML RAR */ +extern void i7171 (void) ; /* CLL CMA CML IAC RAR */ +extern void i7172 (void) ; /* CLL CMA CML RTR */ +extern void i7173 (void) ; /* CLL CMA CML IAC RTR */ +extern void i7174 (void) ; /* CLL CMA CML RAR RAL */ +extern void i7175 (void) ; /* CLL CMA CML IAC RAR RAL */ +extern void i7176 (void) ; /* CLL CMA CML RTR RTL */ +extern void i7177 (void) ; /* CLL CMA CML IAC RTR RTL */ +extern void i7200 (void) ; /* CLA */ +extern void i7201 (void) ; /* CLA IAC */ +extern void i7202 (void) ; /* CLA BSW */ +extern void i7203 (void) ; /* CLA IAC BSW */ +extern void i7204 (void) ; /* CLA RAL */ +extern void i7205 (void) ; /* CLA IAC RAL */ +extern void i7206 (void) ; /* CLA RTL */ +extern void i7207 (void) ; /* CLA IAC RTL */ +extern void i7210 (void) ; /* CLA RAR */ +extern void i7211 (void) ; /* CLA IAC RAR */ +extern void i7212 (void) ; /* CLA RTR */ +extern void i7213 (void) ; /* CLA IAC RTR */ +extern void i7214 (void) ; /* CLA RAR RAL (reserved) */ +extern void i7215 (void) ; /* CLA IAC RAR RAL (reserved) */ +extern void i7216 (void) ; /* CLA RTR RTL (reserved) */ +extern void i7217 (void) ; /* CLA IAC RTR RTL (reserved) */ +extern void i7220 (void) ; /* CLA CML */ +extern void i7221 (void) ; /* CLA CML IAC */ +extern void i7222 (void) ; /* CLA CML BSW */ +extern void i7223 (void) ; /* CLA CML IAC BSW */ +extern void i7224 (void) ; /* CLA CML RAL */ +extern void i7225 (void) ; /* CLA CML IAC RAL */ +extern void i7226 (void) ; /* CLA CML RTL */ +extern void i7227 (void) ; /* CLA CML IAC RTL */ +extern void i7230 (void) ; /* CLA CML RAR */ +extern void i7231 (void) ; /* CLA CML IAC RAR */ +extern void i7232 (void) ; /* CLA CML RTR */ +extern void i7233 (void) ; /* CLA CML IAC RTR */ +extern void i7234 (void) ; /* CLA CML RAR RAL (reserved) */ +extern void i7235 (void) ; /* CLA CML IAC RAR RAL */ +extern void i7236 (void) ; /* CLA CML RTR RTL (reserved) */ +extern void i7237 (void) ; /* CLA CML IAC RTR RTL */ +extern void i7240 (void) ; /* CLA CMA */ +extern void i7241 (void) ; /* CLA CMA IAC */ +extern void i7242 (void) ; /* CLA CMA BSW */ +extern void i7243 (void) ; /* CLA CMA IAC BSW */ +extern void i7244 (void) ; /* CLA CMA RAL */ +extern void i7245 (void) ; /* CLA CMA IAC RAL */ +extern void i7246 (void) ; /* CLA CMA RTL */ +extern void i7247 (void) ; /* CLA CMA IAC RTL */ +extern void i7250 (void) ; /* CLA CMA RAR */ +extern void i7251 (void) ; /* CLA CMA IAC RAR */ +extern void i7252 (void) ; /* CLA CMA RTR */ +extern void i7253 (void) ; /* CLA CMA IAC RTR */ +extern void i7254 (void) ; /* CLA CMA RAR RAL (reserved) */ +extern void i7255 (void) ; /* CLA CMA IAC RAR RAL */ +extern void i7256 (void) ; /* CLA CMA RTR RTL (reserved) */ +extern void i7257 (void) ; /* CLA CMA IAC RTR RTL */ +extern void i7260 (void) ; /* CLA CMA CML */ +extern void i7261 (void) ; /* CLA CMA CML IAC */ +extern void i7262 (void) ; /* CLA CMA CML BSW */ +extern void i7263 (void) ; /* CLA CMA CML IAC BSW */ +extern void i7264 (void) ; /* CLA CMA CML RAL */ +extern void i7265 (void) ; /* CLA CMA CML IAC RAL */ +extern void i7266 (void) ; /* CLA CMA CML RTL */ +extern void i7267 (void) ; /* CLA CMA CML IAC RTL */ +extern void i7270 (void) ; /* CLA CMA CML RAR */ +extern void i7271 (void) ; /* CLA CMA CML IAC RAR */ +extern void i7272 (void) ; /* CLA CMA CML RTR */ +extern void i7273 (void) ; /* CLA CMA CML IAC RTR */ +extern void i7274 (void) ; /* CLA CMA CML RAR RAL */ +extern void i7275 (void) ; /* CLA CMA CML IAC RAR RAL */ +extern void i7276 (void) ; /* CLA CMA CML RTR RTL */ +extern void i7277 (void) ; /* CLA CMA CML IAC RTR RTL */ +extern void i7300 (void) ; /* CLA CLL */ +extern void i7301 (void) ; /* CLA CLL IAC */ +extern void i7302 (void) ; /* CLA CLL BSW */ +extern void i7303 (void) ; /* CLA CLL IAC BSW */ +extern void i7304 (void) ; /* CLA CLL RAL */ +extern void i7305 (void) ; /* CLA CLL IAC RAL */ +extern void i7306 (void) ; /* CLA CLL RTL */ +extern void i7307 (void) ; /* CLA CLL IAC RTL */ +extern void i7310 (void) ; /* CLA CLL RAR */ +extern void i7311 (void) ; /* CLA CLL IAC RAR */ +extern void i7312 (void) ; /* CLA CLL RTR */ +extern void i7313 (void) ; /* CLA CLL IAC RTR */ +extern void i7314 (void) ; /* CLA CLL RAR RAL (reserved) */ +extern void i7315 (void) ; /* CLA CLL IAC RAR RAL */ +extern void i7316 (void) ; /* CLA CLL RTR RTL (reserved) */ +extern void i7317 (void) ; /* CLA CLL IAC RTR RTL */ +extern void i7320 (void) ; /* CLA CLL CML */ +extern void i7321 (void) ; /* CLA CLL CML IAC */ +extern void i7322 (void) ; /* CLA CLL CML BSW */ +extern void i7323 (void) ; /* CLA CLL CML IAC BSW */ +extern void i7324 (void) ; /* CLA CLL CML RAL */ +extern void i7325 (void) ; /* CLA CLL CML IAC RAL */ +extern void i7326 (void) ; /* CLA CLL CML RTL */ +extern void i7327 (void) ; /* CLA CLL CML IAC RTL */ +extern void i7330 (void) ; /* CLA CLL CML RAR */ +extern void i7331 (void) ; /* CLA CLL CML IAC RAR */ +extern void i7332 (void) ; /* CLA CLL CML RTR */ +extern void i7333 (void) ; /* CLA CLL CML IAC RTR */ +extern void i7334 (void) ; /* CLA CLL CML RAR RAL */ +extern void i7335 (void) ; /* CLA CLL CML IAC RAR RAL */ +extern void i7336 (void) ; /* CLA CLL CML RTR RTL */ +extern void i7337 (void) ; /* CLA CLL CML IAC RTR RTL */ +extern void i7340 (void) ; /* CLA CLL CMA */ +extern void i7341 (void) ; /* CLA CLL CMA IAC */ +extern void i7342 (void) ; /* CLA CLL CMA BSW */ +extern void i7343 (void) ; /* CLA CLL CMA IAC BSW */ +extern void i7344 (void) ; /* CLA CLL CMA RAL */ +extern void i7345 (void) ; /* CLA CLL CMA IAC RAL */ +extern void i7346 (void) ; /* CLA CLL CMA RTL */ +extern void i7347 (void) ; /* CLA CLL CMA IAC RTL */ +extern void i7350 (void) ; /* CLA CLL CMA RAR */ +extern void i7351 (void) ; /* CLA CLL CMA IAC RAR */ +extern void i7352 (void) ; /* CLA CLL CMA RTR */ +extern void i7353 (void) ; /* CLA CLL CMA IAC RTR */ +extern void i7354 (void) ; /* CLA CLL CMA RAR RAL */ +extern void i7355 (void) ; /* CLA CLL CMA IAC RAR RAL */ +extern void i7356 (void) ; /* CLA CLL CMA RTR RTL */ +extern void i7357 (void) ; /* CLA CLL CMA IAC RTR RTL */ +extern void i7360 (void) ; /* CLA CLL CMA CML */ +extern void i7361 (void) ; /* CLA CLL CMA CML IAC */ +extern void i7362 (void) ; /* CLA CLL CMA CML BSW */ +extern void i7363 (void) ; /* CLA CLL CMA CML IAC BSW */ +extern void i7364 (void) ; /* CLA CLL CMA CML RAL */ +extern void i7365 (void) ; /* CLA CLL CMA CML IAC RAL */ +extern void i7366 (void) ; /* CLA CLL CMA CML RTL */ +extern void i7367 (void) ; /* CLA CLL CMA CML IAC RTL */ +extern void i7370 (void) ; /* CLA CLL CMA CML RAR */ +extern void i7371 (void) ; /* CLA CLL CMA CML IAC RAR */ +extern void i7372 (void) ; /* CLA CLL CMA CML RTR */ +extern void i7373 (void) ; /* CLA CLL CMA CML IAC RTR */ +extern void i7374 (void) ; /* CLA CLL CMA CML RAR RAL */ +extern void i7375 (void) ; /* CLA CLL CMA CML IAC RAR RAL */ +extern void i7376 (void) ; /* CLA CLL CMA CML RTR RTL */ +extern void i7377 (void) ; /* CLA CLL CMA CML IAC RTR RTL */ +extern void i7400 (void) ; /* NOP Grp II */ +extern void i7402 (void) ; /* HLT */ +extern void i7404 (void) ; /* OSR */ +extern void i7406 (void) ; /* OSR HLT */ +extern void i7410 (void) ; /* SKP */ +extern unsigned s7410 (void) ; /* SKP (skip test) */ +extern void i7412 (void) ; /* SKP HLT */ +extern void u7412 (void) ; /* SKP HLT (user mode) */ +extern void i7414 (void) ; /* SKP OSR */ +extern void i7416 (void) ; /* SKP OSR HLT */ +extern void i7420 (void) ; /* SNL */ +extern unsigned s7420 (void) ; /* SNL (skip test) */ +extern void i7422 (void) ; /* SNL HLT */ +extern void u7422 (void) ; /* SNL HLT (user mode) */ +extern void i7424 (void) ; /* SNL OSR */ +extern void i7426 (void) ; /* SNL OSR HLT */ +extern void i7430 (void) ; /* SZL */ +extern unsigned s7430 (void) ; /* SZL (skipt test) */ +extern void i7432 (void) ; /* SZL HLT */ +extern void u7432 (void) ; /* SZL HLT (user mode) */ +extern void i7434 (void) ; /* SZL OSR */ +extern void i7436 (void) ; /* SZL OSR HLT */ +extern void i7440 (void) ; /* SZA */ +extern unsigned s7440 (void) ; /* SZA (skip test) */ +extern void i7442 (void) ; /* SZA HLT */ +extern void u7442 (void) ; /* SZA HLT (user mode) */ +extern void i7444 (void) ; /* SZA OSR */ +extern void i7446 (void) ; /* SZA OSR HLT */ +extern void i7450 (void) ; /* SNA */ +extern unsigned s7450 (void) ; /* SNA (skip test) */ +extern void i7452 (void) ; /* SNA HLT */ +extern void u7452 (void) ; /* SNA HLT (user mode) */ +extern void i7454 (void) ; /* SNA OSR */ +extern void i7456 (void) ; /* SNA OSR HLT */ +extern void i7460 (void) ; /* SZA SNL */ +extern unsigned s7460 (void) ; /* SZA SNL (skip test) */ +extern void i7462 (void) ; /* SZA SNL HLT */ +extern void u7462 (void) ; /* SZA SNL HLT (user mode) */ +extern void i7464 (void) ; /* SZA SNL OSR */ +extern void i7466 (void) ; /* SZA SNL OSR HLT */ +extern void i7470 (void) ; /* SNA SZL */ +extern unsigned s7470 (void) ; /* SNA SZL (skip test) */ +extern void i7472 (void) ; /* SNA SZL HLT */ +extern void u7472 (void) ; /* SNA SZL HLT (user mode) */ +extern void i7474 (void) ; /* SNA SZL OSR */ +extern void i7476 (void) ; /* SNA SZL OSR HLT */ +extern void i7500 (void) ; /* SMA */ +extern unsigned s7500 (void) ; /* SMA (skip test) */ +extern void i7502 (void) ; /* SMA HLT */ +extern void u7502 (void) ; /* SMA HLT (user mode) */ +extern void i7504 (void) ; /* SMA OSR */ +extern void i7506 (void) ; /* SMA OSR HLT */ +extern void i7510 (void) ; /* SPA */ +extern unsigned s7510 (void) ; /* SPA (skip test) */ +extern void i7512 (void) ; /* SPA HLT */ +extern void u7512 (void) ; /* SPA HLT (user mode) */ +extern void i7514 (void) ; /* SPA OSR */ +extern void i7516 (void) ; /* SPA OSR HLT */ +extern void i7520 (void) ; /* SMA SNL */ +extern unsigned s7520 (void) ; /* SMA SNL (skip test) */ +extern void i7522 (void) ; /* SMA SNL HLT */ +extern void u7522 (void) ; /* SMA SNL HLT (user mode) */ +extern void i7524 (void) ; /* SMA SNL OSR */ +extern void i7526 (void) ; /* SMA SNL OSR HLT */ +extern void i7530 (void) ; /* SPA SZL */ +extern unsigned s7530 (void) ; /* SPA SZL (skip test) */ +extern void i7532 (void) ; /* SPA SZL HLT */ +extern void u7532 (void) ; /* SPA SZL HLT (user mode) */ +extern void i7534 (void) ; /* SPA SZL OSR */ +extern void i7536 (void) ; /* SPA SZL OSR HLT */ +extern void i7540 (void) ; /* SMA SZA */ +extern unsigned s7540 (void) ; /* SMA SZA (skip test) */ +extern void i7542 (void) ; /* SMA SZA HLT */ +extern void u7542 (void) ; /* SMA SZA HLT (user mode) */ +extern void i7544 (void) ; /* SMA SZA OSR */ +extern void i7546 (void) ; /* SMA SZA OSR HLT */ +extern void i7550 (void) ; /* SPA SNA */ +extern unsigned s7550 (void) ; /* SPA SNA (skip test) */ +extern void i7552 (void) ; /* SPA SNA HLT */ +extern void u7552 (void) ; /* SPA SNA HLT (user mode) */ +extern void i7554 (void) ; /* SPA SNA OSR */ +extern void i7556 (void) ; /* SPA SNA OSR HLT */ +extern void i7560 (void) ; /* SMA SZA SNL */ +extern unsigned s7560 (void) ; /* SMA SZA SNL (skip test) */ +extern void i7562 (void) ; /* SMA SZA SNL HLT */ +extern void u7562 (void) ; /* SMA SZA SNL HLT (user mode) */ +extern void i7564 (void) ; /* SMA SZA SNL OSR */ +extern void i7566 (void) ; /* SMA SZA SNL OSR HLT */ +extern void i7570 (void) ; /* SPA SNA SZL */ +extern unsigned s7570 (void) ; /* SPA SNA SZL (skip test) */ +extern void i7572 (void) ; /* SPA SNA SZL HLT */ +extern void u7572 (void) ; /* SPA SNA SZL HLT (user mode) */ +extern void i7574 (void) ; /* SPA SNA SZL OSR */ +extern void i7576 (void) ; /* SPA SNA SZL OSR HLT */ +extern void i7600 (void) ; /* CLA Grp II */ +extern void i7602 (void) ; /* CLA HLT */ +extern void u7602 (void) ; /* CLA HLT (user mode) */ +extern void i7604 (void) ; /* CLA OSR */ +extern void i7606 (void) ; /* CLA OSR HLT */ +extern void i7610 (void) ; /* SKP CLA */ +extern void i7612 (void) ; /* SKP CLA HLT */ +extern void u7612 (void) ; /* SKP CLA HLT (user mode) */ +extern void i7614 (void) ; /* SKP CLA OSR */ +extern void i7616 (void) ; /* SKP CLA OSR HLT */ +extern void i7620 (void) ; /* SNL CLA */ +extern void i7622 (void) ; /* SNL CLA HLT */ +extern void u7622 (void) ; /* SNL CLA HLT (user mode) */ +extern void i7624 (void) ; /* SNL CLA OSR */ +extern void i7626 (void) ; /* SNL CLA OSR HLT */ +extern void i7630 (void) ; /* SZL CLA */ +extern void i7632 (void) ; /* SZL CLA HLT */ +extern void u7632 (void) ; /* SZL CLA HLT (user mode) */ +extern void i7634 (void) ; /* SZL CLA OSR */ +extern void i7636 (void) ; /* SZL CLA OSR HLT */ +extern void i7640 (void) ; /* SZA CLA */ +extern void i7642 (void) ; /* SZA CLA HLT */ +extern void u7642 (void) ; /* SZA CLA HLT (user mode) */ +extern void i7644 (void) ; /* SZA CLA OSR */ +extern void i7646 (void) ; /* SZA CLA OSR HLT */ +extern void i7650 (void) ; /* SNA CLA */ +extern void i7652 (void) ; /* SNA CLA HLT */ +extern void u7652 (void) ; /* SNA CLA HLT (user mode) */ +extern void i7654 (void) ; /* SNA CLA OSR */ +extern void i7656 (void) ; /* SNA CLA OSR HLT */ +extern void i7660 (void) ; /* SZA SNL CLA */ +extern void i7662 (void) ; /* SZA SNL CLA HLT */ +extern void u7662 (void) ; /* SZA SNL CLA HLT (user mode) */ +extern void i7664 (void) ; /* SZA SNL CLA OSR */ +extern void i7666 (void) ; /* SZA SNL CLA OSR HLT */ +extern void i7670 (void) ; /* SNA SZL CLA */ +extern void i7672 (void) ; /* SNA SZL CLA HLT */ +extern void u7672 (void) ; /* SNA SZL CLA HLT (user mode) */ +extern void i7674 (void) ; /* SNA SZL CLA OSR */ +extern void i7676 (void) ; /* SNA SZL CLA OSR HLT */ +extern void i7700 (void) ; /* SMA CLA */ +extern void i7702 (void) ; /* SMA CLA HLT */ +extern void u7702 (void) ; /* SMA CLA HLT */ +extern void i7704 (void) ; /* SMA CLA OSR */ +extern void i7706 (void) ; /* SMA CLA OSR HLT */ +extern void i7710 (void) ; /* SPA CLA */ +extern void i7712 (void) ; /* SPA CLA HLT */ +extern void u7712 (void) ; /* SPA CLA HLT (user mode) */ +extern void i7714 (void) ; /* SPA CLA OSR */ +extern void i7716 (void) ; /* SPA CLA OSR HLT */ +extern void i7720 (void) ; /* SMA SNL CLA */ +extern void i7722 (void) ; /* SMA SNL CLA HLT */ +extern void u7722 (void) ; /* SMA SNL CLA HLT (user mode) */ +extern void i7724 (void) ; /* SMA SNL CLA OSR */ +extern void i7726 (void) ; /* SMA SNL CLA OSR HLT */ +extern void i7730 (void) ; /* SPA SZL CLA */ +extern void i7732 (void) ; /* SPA SZL CLA HLT */ +extern void u7732 (void) ; /* SPA SZL CLA HLT (user mode) */ +extern void i7734 (void) ; /* SPA SZL CLA OSR */ +extern void i7736 (void) ; /* SPA SZL CLA OSR HLT */ +extern void i7740 (void) ; /* SMA SZA CLA */ +extern void i7742 (void) ; /* SMA SZA CLA HLT */ +extern void u7742 (void) ; /* SMA SZA CLA HLT (user mode) */ +extern void i7744 (void) ; /* SMA SZA CLA OSR */ +extern void i7746 (void) ; /* SMA SZA CLA OSR HLT */ +extern void i7750 (void) ; /* SPA SNA CLA */ +extern void i7752 (void) ; /* SPA SNA CLA HLT */ +extern void u7752 (void) ; /* SPA SNA CLA HLT (user mode) */ +extern void i7754 (void) ; /* SPA SNA CLA OSR */ +extern void i7756 (void) ; /* SPA SNA CLA OSR HLT */ +extern void i7760 (void) ; /* SMA SZA SNL CLA */ +extern void i7762 (void) ; /* SMA SZA SNL CLA HLT */ +extern void u7762 (void) ; /* SMA SZA SNL CLA HLT */ +extern void i7764 (void) ; /* SMA SZA SNL CLA OSR */ +extern void i7766 (void) ; /* SMA SZA SNL CLA OSR HLT */ +extern void i7770 (void) ; /* SPA SNA SZL CLA */ +extern void i7772 (void) ; /* SPA SNA SZL CLA HLT */ +extern void u7772 (void) ; /* SPA SNA SZL CLA HLT */ +extern void i7774 (void) ; /* SPA SNA SZL CLA OSR */ +extern void i7776 (void) ; /* SPA SNA SZL CLA OSR HLT */ +/* -------------------------------------------------------------------- */ diff --git a/Emulation/pdp8defines.h b/Emulation/pdp8defines.h new file mode 100644 index 0000000..432271b --- /dev/null +++ b/Emulation/pdp8defines.h @@ -0,0 +1,80 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * pdp8defines.h - #defines making the PDP8 class from + * PDP8.h compatible to Bill Haygoods pdp8 + * instruction execution routines + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +/* Types */ +#define VOID void +#define REG register +#define UWORD unsigned short +#define ULONG unsigned long +#define LONG long +#define INT short +#define UINT unsigned short +#define BYTE char +#define UBYTE unsigned char + + +/* Attributes of the PDP8 class */ +#define base (pdp8->mem) +#define SR (pdp8->SR) +#define AC (pdp8->AC) +#define PC (pdp8->PC) +#define SC (pdp8->SC) +#define MQ (pdp8->MQ) +#define GTF (pdp8->GTF) +#define IF (pdp8->IF) +#define IB (pdp8->IB) +#define W_IB (pdp8->W_IB) +#define DF (pdp8->DF) +#define W_DF (pdp8->W_DF) +#define UF (pdp8->UF) +#define UB (pdp8->UB) +#define SF (pdp8->SF) +#define int_ena (pdp8->IENABLE) +#define int_inh (pdp8->IINHIBIT) +#define delay (pdp8->IDELAY) +#define io_flags (pdp8->IOFLAGS) +#define int_mask (pdp8->IMASK) +#define EAE (pdp8->eaeMode) +#define tsc8 (pdp8->_tsc8) +#define hw (pdp8->_hw) +#define INST (pdp8->_state.currInst) +#define run (pdp8->_state.running) + + +/* The 12 bits of a PDP-8 word are numered 0-11 from left to right. + The following defines reflect this numbering. */ +#define BIT0 04000 +#define BIT1 02000 +#define BIT2 01000 +#define BIT3 00400 +#define BIT4 00200 +#define BIT5 00100 +#define BIT6 00040 +#define BIT7 00020 +#define BIT8 00010 +#define BIT9 00004 +#define BIT10 00002 +#define BIT11 00001 diff --git a/GeneralPreferences/English.lproj/GeneralPreferences.nib/classes.nib b/GeneralPreferences/English.lproj/GeneralPreferences.nib/classes.nib new file mode 100644 index 0000000..6e434bb --- /dev/null +++ b/GeneralPreferences/English.lproj/GeneralPreferences.nib/classes.nib @@ -0,0 +1,59 @@ + + + + + IBClasses + + + CLASS + NSControl + LANGUAGE + ObjC + SUPERCLASS + NSView + + + ACTIONS + + + id + + CLASS + FirstResponder + LANGUAGE + ObjC + SUPERCLASS + NSObject + + + CLASS + NSPreferencePane + LANGUAGE + ObjC + OUTLETS + + _firstKeyView + NSView + _initialKeyView + NSView + _lastKeyView + NSView + _window + NSWindow + + SUPERCLASS + NSObject + + + CLASS + GeneralPreferences + LANGUAGE + ObjC + SUPERCLASS + NSPreferencePane + + + IBVersion + 1 + + diff --git a/GeneralPreferences/English.lproj/GeneralPreferences.nib/info.nib b/GeneralPreferences/English.lproj/GeneralPreferences.nib/info.nib new file mode 100644 index 0000000..27bcd3a --- /dev/null +++ b/GeneralPreferences/English.lproj/GeneralPreferences.nib/info.nib @@ -0,0 +1,20 @@ + + + + + IBFramework Version + 644 + IBLastKnownRelativeProjectPath + ../../pdp8e-simulator.xcodeproj + IBOldestOS + 5 + IBOpenObjects + + 67 + + IBSystem Version + 9C31 + targetFramework + IBCocoaFramework + + diff --git a/GeneralPreferences/English.lproj/GeneralPreferences.nib/keyedobjects.nib b/GeneralPreferences/English.lproj/GeneralPreferences.nib/keyedobjects.nib new file mode 100644 index 0000000..3808a6a Binary files /dev/null and b/GeneralPreferences/English.lproj/GeneralPreferences.nib/keyedobjects.nib differ diff --git a/GeneralPreferences/English.lproj/GeneralPreferences~.nib/classes.nib b/GeneralPreferences/English.lproj/GeneralPreferences~.nib/classes.nib new file mode 100644 index 0000000..856f592 --- /dev/null +++ b/GeneralPreferences/English.lproj/GeneralPreferences~.nib/classes.nib @@ -0,0 +1,35 @@ +{ + IBClasses = ( + { + ACTIONS = {"" = id; }; + CLASS = FirstResponder; + LANGUAGE = ObjC; + SUPERCLASS = NSObject; + }, + { + ACTIONS = {driftChange = id; goSpeedClick = id; traceSpeedChange = id; }; + CLASS = GeneralPreferences; + LANGUAGE = ObjC; + OUTLETS = { + driftSlider = NSSlider; + driftSliderLeftLabel = NSTextField; + driftSliderRightLabel = NSTextField; + goSpeedRadiobuttons = NSMatrix; + traceSpeedSlider = NSSlider; + }; + SUPERCLASS = NSPreferencePane; + }, + { + CLASS = NSPreferencePane; + LANGUAGE = ObjC; + OUTLETS = { + "_firstKeyView" = NSView; + "_initialKeyView" = NSView; + "_lastKeyView" = NSView; + "_window" = NSWindow; + }; + SUPERCLASS = NSObject; + } + ); + IBVersion = 1; +} \ No newline at end of file diff --git a/GeneralPreferences/English.lproj/GeneralPreferences~.nib/info.nib b/GeneralPreferences/English.lproj/GeneralPreferences~.nib/info.nib new file mode 100644 index 0000000..51215fc --- /dev/null +++ b/GeneralPreferences/English.lproj/GeneralPreferences~.nib/info.nib @@ -0,0 +1,16 @@ + + + + + IBDocumentLocation + 156 102 356 240 0 0 1440 878 + IBFramework Version + 446.1 + IBOpenObjects + + 5 + + IBSystem Version + 8L2127 + + diff --git a/GeneralPreferences/English.lproj/GeneralPreferences~.nib/keyedobjects.nib b/GeneralPreferences/English.lproj/GeneralPreferences~.nib/keyedobjects.nib new file mode 100644 index 0000000..9907ecd Binary files /dev/null and b/GeneralPreferences/English.lproj/GeneralPreferences~.nib/keyedobjects.nib differ diff --git a/GeneralPreferences/English.lproj/InfoPlist.strings b/GeneralPreferences/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..0005eb5 --- /dev/null +++ b/GeneralPreferences/English.lproj/InfoPlist.strings @@ -0,0 +1,26 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InfoPlist.strings - Localized strings for General preference pane Info.plist + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +NSPrefPaneIconLabel = "General"; +PrefPaneWindowTitle = "General Preferences"; diff --git a/GeneralPreferences/GeneralPreferences.h b/GeneralPreferences/GeneralPreferences.h new file mode 100644 index 0000000..bd2077f --- /dev/null +++ b/GeneralPreferences/GeneralPreferences.h @@ -0,0 +1,26 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * GeneralPreferences.h - General Preferences Pane + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define GENERAL_PREFS_TRACE_SPEED_KEY @"TraceSpeed" +#define GENERAL_PREFS_GO_SPEED_KEY @"GoSpeed" diff --git a/GeneralPreferences/GeneralPreferences.m b/GeneralPreferences/GeneralPreferences.m new file mode 100644 index 0000000..a50a8e3 --- /dev/null +++ b/GeneralPreferences/GeneralPreferences.m @@ -0,0 +1,41 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * GeneralPreferences.m - General Preferences Pane + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "GeneralPreferences.h" + + +@interface GeneralPreferences : NSPreferencePane +{ +} + +@end + + +@implementation GeneralPreferences + +// empty class, otherwise the preference pane bundle has no loadable code and does not load + +@end diff --git a/GeneralPreferences/Info.plist b/GeneralPreferences/Info.plist new file mode 100644 index 0000000..a2353f7 --- /dev/null +++ b/GeneralPreferences/Info.plist @@ -0,0 +1,34 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleIdentifier + de.bernhard-baehr.pdp8e.GeneralPreferences + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + BNDL + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + CFBundleShortVersionString + 2.0.2 + NSMainNibFile + GeneralPreferences + NSPrefPaneIconFile + generalPrefIcon.tiff + NSPrefPaneIconLabel + General + NSPrincipalClass + GeneralPreferences + OrderInPreferencesPanelToolbar + 01 + PrefPaneWindowTitle + General Preferences + + diff --git a/GeneralPreferences/generalPrefIcon.tiff b/GeneralPreferences/generalPrefIcon.tiff new file mode 100644 index 0000000..5fd226b Binary files /dev/null and b/GeneralPreferences/generalPrefIcon.tiff differ diff --git a/KC8EA/BackgroundView.h b/KC8EA/BackgroundView.h new file mode 100644 index 0000000..c0d6a70 --- /dev/null +++ b/KC8EA/BackgroundView.h @@ -0,0 +1,33 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * BackgroundView.h - NSView for a background image for a window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface BackgroundView : NSView +{ +@private + NSImage *backgroundImage; +} + +- (void) setBackgroundImage:(NSString *)imageName ofType:(NSString *)type; + +@end diff --git a/KC8EA/BackgroundView.m b/KC8EA/BackgroundView.m new file mode 100644 index 0000000..c7b0cb9 --- /dev/null +++ b/KC8EA/BackgroundView.m @@ -0,0 +1,47 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * BackgroundView.m - NSView for a background image for a window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "BackgroundView.h" + + +@implementation BackgroundView + + +- (void) setBackgroundImage:(NSString *)imageName ofType:(NSString *)type; +{ + backgroundImage = [[NSImage alloc] initByReferencingFile: + [[NSBundle bundleForClass:[self class]] pathForResource:imageName ofType:type]]; +} + + +- (void) drawRect:(NSRect)rect +{ + [backgroundImage drawInRect:[self bounds] fromRect:NSZeroRect + operation:NSCompositeSourceOver fraction:1]; +} + + +@end diff --git a/KC8EA/ConsoleSwitchCell.h b/KC8EA/ConsoleSwitchCell.h new file mode 100644 index 0000000..d3f852b --- /dev/null +++ b/KC8EA/ConsoleSwitchCell.h @@ -0,0 +1,46 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ConsoleSwitchCell.h - NSButtonCell subclass for the console switches + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +// for toggles with default position "up" +// - image is up image with shaddow +// - alternate image is down position +// - alternate title is the name of the up position image with shadow +// for switches +// - image is the down image +// - alternate image is the up position image without shadow +// - alternate title is the name of the up position image with shadow +// tag value == -1 for a momentary changing switch, otherwise it is a dual state switch + + +@interface ConsoleSwitchCell : NSButtonCell +{ +@private + IBOutlet ConsoleSwitchCell *leftNeighbour; + NSImage *upWithShadow; + NSImage *upWithoutShadow; +} + +- (void) updateShadow:(BOOL)showShadow; + +@end diff --git a/KC8EA/ConsoleSwitchCell.m b/KC8EA/ConsoleSwitchCell.m new file mode 100644 index 0000000..05e734d --- /dev/null +++ b/KC8EA/ConsoleSwitchCell.m @@ -0,0 +1,92 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ConsoleSwitchCell.h - NSButtonCell subclass for the console switches + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "ConsoleSwitchCell.h" + + +@implementation ConsoleSwitchCell + + +- (void) awakeFromNib +{ + if ([self tag] == -1) { + upWithoutShadow = [[NSImage alloc] initByReferencingFile: + [[NSBundle bundleForClass:[self class]] + pathForResource:[self alternateTitle] ofType:@"png"]]; + upWithShadow = [[self image] retain]; + } else { + upWithoutShadow = [[self alternateImage] retain]; + upWithShadow = [[NSImage alloc] initByReferencingFile: + [[NSBundle bundleForClass:[self class]] + pathForResource:[self alternateTitle] ofType:@"png"]]; + } + [(NSButton *)[self controlView] setAlternateTitle:nil]; +} + + +- (void) highlight:(BOOL)flag withFrame:(NSRect)frame inView:(NSView *)view +{ + // we need highlight only for momentary changing switches, detected via tag value -1 + if ([self tag] == -1) { + [super highlight:flag withFrame:frame inView:view]; + [leftNeighbour updateShadow:! flag]; + } + else + [view setNeedsDisplay:YES]; +} + + +- (void) performClick:(id)sender +{ + // called by the key equivalents; the default method causes the switch to highlight + // we need highlight only for momentary changing switches, detected via tag value -1 + if ([self tag] == -1) + [super performClick:sender]; + else { + [self setState:! [self state]]; + [[self target] performSelector:[self action] withObject:sender]; + } + [[self controlView] setNeedsDisplay:YES]; // to show keyboad operation via space key with Tiger +} + + +- (void) setState:(int)state +{ + [super setState:state]; + [leftNeighbour updateShadow:state]; +} + + +- (void) updateShadow:(BOOL)showShadow +{ + if ([self tag] == -1) + [self setImage:showShadow ? upWithShadow : upWithoutShadow]; + else + [self setAlternateImage:showShadow ? upWithShadow : upWithoutShadow]; +} + + +@end diff --git a/KC8EA/English.lproj/InfoPlist.strings b/KC8EA/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..5c9eeda --- /dev/null +++ b/KC8EA/English.lproj/InfoPlist.strings @@ -0,0 +1,28 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InfoPlist.strings - Localized strings for Info.plist + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +CFBundleName = "KC8-EA Programmer’s Console"; +CFBundleGetInfoString = "KC8-EA Programmer’s Console 2.0.2, Copyright © 1994-2015 Bernhard Baehr"; +NSHumanReadableCopyright = "Copyright © 1994-2015 Bernhard Baehr"; +CFBundleHelpBookName = "KC8-EA Programmer's Console Help"; \ No newline at end of file diff --git a/KC8EA/English.lproj/KC8EA.nib/designable.nib b/KC8EA/English.lproj/KC8EA.nib/designable.nib new file mode 100644 index 0000000..f783dec --- /dev/null +++ b/KC8EA/English.lproj/KC8EA.nib/designable.nib @@ -0,0 +1,5123 @@ + + + + 1040 + 13E28 + 851 + 1265.21 + 698.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + YES + + + + YES + com.apple.InterfaceBuilder.CocoaPlugin + + + YES + + YES + + + YES + + + + YES + + KC8EA + + + FirstResponder + + + NSApplication + + + 7 + 2 + {{0, 171}, {1280, 585}} + 1618478080 + KC8-EA Programmer’s Console + KeepInMenuWindow + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + + + 256 + + YES + + + 268 + {{361, 84}, {38, 54}} + + + 1 + YES + + 67108864 + 167804928 + + + LucidaGrande + 13 + 1040 + + + 1 + 1212960768 + 134217730 + + NSImage + sr1down + + + NSImage + sr1up_sr2down + + sr1up_sr2up + 1 + 400 + 75 + + NO + + + + 268 + {{323, 84}, {38, 54}} + + + YES + + 67108864 + 167804928 + + + + 1212960768 + 134217730 + + NSImage + sr0down + + + NSImage + sr0up_sr1down + + sr0up_sr1up + 0 + 400 + 75 + + NO + + + + 268 + {{246, 82}, {41, 55}} + + + YES + + 67108864 + 167804928 + + + + 1212960768 + 134217730 + + NSImage + sw_down + + + NSImage + sw_up + + sw_up + w + 400 + 75 + + NO + + + + 268 + {{810, 84}, {39, 55}} + + + YES + + -2080374784 + 167804928 + + + + -1 + 139214848 + 134217730 + + NSImage + addrload_up_extdaddrload_up + + + NSImage + addrload_down + + addrload_up_extdaddrload_down + l + 400 + 75 + + NO + + + + 268 + {{849, 84}, {38, 55}} + + + YES + + 67108864 + 167804928 + + + + -1 + 139214848 + 134217730 + + NSImage + extdaddrload_up + + + NSImage + extdaddrload_down + + extdaddrload_up + x + 400 + 75 + + NO + + + + 268 + {{922, 84}, {39, 55}} + + + YES + + 67108864 + 167804928 + + + + -1 + 139214848 + 134217730 + + NSImage + clear_up_cont_up + + + NSImage + clear_down + + clear_up_cont_down + c + 400 + 75 + + NO + + + + 268 + {{961, 84}, {37, 55}} + + + YES + + 67108864 + 167804928 + + + + -1 + 139214848 + 134217730 + + NSImage + cont_up_exam_up + + + NSImage + cont_down + + cont_up_exam_down + t + 400 + 75 + + NO + + + + 268 + {{998, 84}, {39, 55}} + + + YES + + 67108864 + 167804928 + + + + -1 + 139214848 + 134217730 + + NSImage + exam_up_halt_up + + + NSImage + exam_down + + exam_up_halt_down + e + 400 + 75 + + NO + + + + 268 + {{399, 84}, {37, 54}} + + + 2 + YES + + 67108864 + 167804928 + + + + 2 + 1212960768 + 134217730 + + NSImage + sr2down + + + NSImage + sr2up_sr3down + + sr2up_sr3up + 2 + 400 + 75 + + NO + + + + 268 + {{436, 84}, {37, 54}} + + + 3 + YES + + 67108864 + 167804928 + + + + 3 + 1212960768 + 134217730 + + NSImage + sr3down + + + NSImage + sr3up_sr4down + + sr3up_sr4up + 3 + 400 + 75 + + NO + + + + 268 + {{473, 84}, {38, 54}} + + + 4 + YES + + 67108864 + 167804928 + + + + 4 + 1212960768 + 134217730 + + NSImage + sr4down + + + NSImage + sr4up_sr5down + + sr4up_sr5up + 4 + 400 + 75 + + NO + + + + 268 + {{511, 84}, {37, 54}} + + + 5 + YES + + 67108864 + 167804928 + + + + 5 + 1212960768 + 134217730 + + NSImage + sr5down + + + NSImage + sr5up_sr6down + + sr5up_sr6up + 5 + 400 + 75 + + NO + + + + 268 + {{548, 84}, {38, 54}} + + + 6 + YES + + 67108864 + 167804928 + + + + 6 + 1212960768 + 134217730 + + NSImage + sr6down + + + NSImage + sr6up_sr7down + + sr6up_sr7up + 6 + 400 + 75 + + NO + + + + 268 + {{586, 84}, {38, 54}} + + + 7 + YES + + 67108864 + 167804928 + + + + 7 + 1212960768 + 134217730 + + NSImage + sr7down + + + NSImage + sr7up_sr8down + + sr7up_sr8up + 7 + 400 + 75 + + NO + + + + 268 + {{624, 84}, {37, 54}} + + + 8 + YES + + 67108864 + 167804928 + + + + 8 + 1212960768 + 134217730 + + NSImage + sr8down + + + NSImage + sr8up_sr9down + + sr8up_sr9up + 8 + 400 + 75 + + NO + + + + 268 + {{661, 84}, {38, 54}} + + + 9 + YES + + 67108864 + 167804928 + + + + 9 + 1212960768 + 134217730 + + NSImage + sr9down + + + NSImage + sr9up_sr10down + + sr9up_sr10up + 9 + 400 + 75 + + NO + + + + 268 + {{699, 84}, {37, 54}} + + + 10 + YES + + 67108864 + 167804928 + + + + 10 + 1212960768 + 134217730 + + NSImage + sr10down + + + NSImage + sr10up_sr11down + + sr10up_sr11up + a + 400 + 75 + + NO + + + + 268 + {{736, 84}, {38, 54}} + + + 11 + YES + + 67108864 + 167804928 + + + + 11 + 1212960768 + 134217730 + + NSImage + sr11down + + + NSImage + sr11up + + sr11up + b + 400 + 75 + + NO + + + + 268 + {{1037, 84}, {37, 55}} + + + YES + + -2080374784 + 167804928 + + + + 1212960768 + 134217730 + + NSImage + halt_down + + + NSImage + halt_up_singstep_down + + halt_up_singstep_up + h + 400 + 75 + + NO + + + + 268 + {{1074, 84}, {39, 55}} + + + YES + + -2080374784 + 167804928 + + + + 1212960768 + 134217730 + + NSImage + singstep_down + + + NSImage + singstep_up + + singstep_up + s + 400 + 75 + + NO + + + + 268 + {{1148, 84}, {42, 55}} + + YES + + 67108864 + 167804928 + + + + -1 + 139214848 + 134217730 + + NSImage + dep_down + + + NSImage + dep_up + + dep_up + d + 400 + 75 + + NO + + + + 268 + {{809, 214}, {82, 92}} + + + YES + + 67108864 + 167804928 + + + + 6 + 139214848 + 134217730 + + NSImage + knob0 + + + knob + < + 400 + 75 + + NO + + + + 268 + {{84, 77}, {127, 70}} + + + YES + + 67108864 + 167804928 + + + + -3 + 139214848 + 134217730 + + NSImage + key0 + + + key + > + 400 + 75 + + NO + + + + 268 + {{221, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + NSImage + light_off + + + NSImage + light_on + + + + 200 + 25 + + NO + + + + 268 + {{258, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{295, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{333, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{370, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{407, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{445, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{482, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{519, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{557, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{594, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{631, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{669, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{706, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{743, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{890, 361}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{333, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{370, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{407, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{445, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{482, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{519, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{557, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{594, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{631, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{669, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{706, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{743, 320}, {18, 18}} + + + YES + + 603979776 + 134217728 + + + + 1212436480 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{323, 293.30859375}, {111, 19}} + + _NS:1109 + NSCustomView + + + + 268 + {{435, 293}, {112, 19}} + + _NS:1109 + NSCustomView + + + + 268 + {{548.75, 275}, {110, 17}} + + _NS:1109 + NSCustomView + + + + 268 + {{511, 275}, {36, 17}} + + _NS:1109 + NSCustomView + + + + 268 + {{473, 275}, {37, 17}} + + _NS:1109 + NSCustomView + + + + 268 + {{435.5, 275}, {36, 17}} + + _NS:1109 + NSCustomView + + + + 268 + {{398, 275}, {36, 17}} + + _NS:1109 + NSCustomView + + + + 268 + {{360.5, 275}, {36, 17}} + + _NS:1109 + NSCustomView + + + + 268 + {{323, 275}, {36, 17}} + + _NS:1109 + NSCustomView + + + + 268 + {{660, 275}, {112, 17}} + + _NS:1109 + NSCustomView + + + + 268 + {{548.5, 293}, {36, 19}} + + _NS:1109 + NSCustomView + + + + 268 + {{586, 293}, {35, 19}} + + _NS:1109 + NSCustomView + + + + 268 + {{622, 293}, {37, 19}} + + _NS:1109 + NSCustomView + + + + 268 + {{660, 293}, {36, 19}} + + _NS:1109 + NSCustomView + + + + 268 + {{697.5, 293}, {36, 19}} + + _NS:1109 + NSCustomView + + + + 268 + {{735, 293}, {37, 19}} + + _NS:1109 + NSCustomView + + + {1280, 585} + + + + {{0, 0}, {1280, 778}} + {1.7976931348623157e+308, 1.7976931348623157e+308} + KC8EAWindow + YES + + + + + YES + + + window + + + + 3 + + + + sr1 + + + + 129 + + + + sr2 + + + + 130 + + + + sr3 + + + + 131 + + + + sr4 + + + + 132 + + + + sr5 + + + + 133 + + + + sr6 + + + + 134 + + + + sr7 + + + + 135 + + + + sr8 + + + + 136 + + + + sr9 + + + + 137 + + + + sr10 + + + + 138 + + + + sr11 + + + + 139 + + + + srClicked: + + + + 141 + + + + srClicked: + + + + 142 + + + + srClicked: + + + + 143 + + + + srClicked: + + + + 144 + + + + srClicked: + + + + 145 + + + + srClicked: + + + + 146 + + + + srClicked: + + + + 147 + + + + srClicked: + + + + 148 + + + + srClicked: + + + + 149 + + + + srClicked: + + + + 150 + + + + srClicked: + + + + 151 + + + + srClicked: + + + + 156 + + + + sr0 + + + + 157 + + + + addrload + + + + 210 + + + + sw + + + + 211 + + + + addrloadClicked: + + + + 212 + + + + swClicked: + + + + 213 + + + + extdaddrloadClicked: + + + + 217 + + + + extdaddrload + + + + 218 + + + + clear + + + + 224 + + + + clearClicked: + + + + 225 + + + + cont + + + + 235 + + + + contClicked: + + + + 236 + + + + exam + + + + 237 + + + + examClicked: + + + + 238 + + + + halt + + + + 244 + + + + haltClicked: + + + + 245 + + + + singstep + + + + 252 + + + + stingstepClicked: + + + + 253 + + + + leftNeighbour + + + + 254 + + + + leftNeighbour + + + + 255 + + + + leftNeighbour + + + + 256 + + + + leftNeighbour + + + + 257 + + + + leftNeighbour + + + + 258 + + + + leftNeighbour + + + + 259 + + + + leftNeighbour + + + + 260 + + + + leftNeighbour + + + + 261 + + + + leftNeighbour + + + + 262 + + + + leftNeighbour + + + + 263 + + + + leftNeighbour + + + + 264 + + + + leftNeighbour + + + + 265 + + + + leftNeighbour + + + + 266 + + + + leftNeighbour + + + + 267 + + + + leftNeighbour + + + + 268 + + + + leftNeighbour + + + + 269 + + + + depClicked: + + + + 274 + + + + dep + + + + 275 + + + + knobClicked: + + + + 305 + + + + knob + + + + 309 + + + + key + + + + 310 + + + + keyClicked: + + + + 311 + + + + addr0 + + + + 369 + + + + addr1 + + + + 370 + + + + addr2 + + + + 371 + + + + addr3 + + + + 372 + + + + addr14 + + + + 373 + + + + addr13 + + + + 374 + + + + addr12 + + + + 375 + + + + addr11 + + + + 376 + + + + addr10 + + + + 377 + + + + addr9 + + + + 378 + + + + addr4 + + + + 384 + + + + addr5 + + + + 385 + + + + addr6 + + + + 386 + + + + addr7 + + + + 387 + + + + addr8 + + + + 388 + + + + run + + + + 401 + + + + display0 + + + + 403 + + + + display1 + + + + 404 + + + + display2 + + + + 405 + + + + display11 + + + + 406 + + + + display10 + + + + 407 + + + + display9 + + + + 408 + + + + display3 + + + + 409 + + + + display4 + + + + 410 + + + + display5 + + + + 411 + + + + display6 + + + + 412 + + + + display7 + + + + 413 + + + + display8 + + + + 414 + + + + + YES + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 1 + + + YES + + + + + + 2 + + + YES + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 106 + + + YES + + + + + + 107 + + + + + 108 + + + YES + + + + + + 109 + + + + + 110 + + + YES + + + + + + 111 + + + + + 112 + + + YES + + + + + + 113 + + + + + 114 + + + YES + + + + + + 115 + + + + + 116 + + + YES + + + + + + 117 + + + + + 118 + + + YES + + + + + + 119 + + + + + 120 + + + YES + + + + + + 121 + + + + + 122 + + + YES + + + + + + 123 + + + + + 124 + + + YES + + + + + + 125 + + + + + 126 + + + YES + + + + + + 127 + + + + + 154 + + + YES + + + + + + 155 + + + + + 203 + + + YES + + + + + + 204 + + + + + 207 + + + YES + + + + + + 208 + + + + + 214 + + + YES + + + + + + 215 + + + + + 220 + + + YES + + + + + + 221 + + + + + 226 + + + YES + + + + + + 227 + + + + + 231 + + + YES + + + + + + 232 + + + + + 240 + + + YES + + + + + + 241 + + + + + 247 + + + YES + + + + + + 248 + + + + + 270 + + + YES + + + + + + 271 + + + + + 303 + + + YES + + + + + + 304 + + + + + 306 + + + YES + + + + + + 307 + + + + + 312 + + + YES + + + + + + 313 + + + + + 315 + + + YES + + + + + + 316 + + + + + 317 + + + YES + + + + + + 318 + + + + + 319 + + + YES + + + + + + 320 + + + + + 321 + + + YES + + + + + + 322 + + + YES + + + + + + 323 + + + YES + + + + + + 324 + + + YES + + + + + + 325 + + + + + 326 + + + + + 327 + + + + + 328 + + + + + 329 + + + YES + + + + + + 330 + + + YES + + + + + + 331 + + + YES + + + + + + 332 + + + YES + + + + + + 333 + + + YES + + + + + + 334 + + + YES + + + + + + 335 + + + YES + + + + + + 336 + + + + + 337 + + + + + 338 + + + + + 339 + + + + + 340 + + + + + 341 + + + + + 342 + + + + + 343 + + + YES + + + + + + 344 + + + YES + + + + + + 345 + + + YES + + + + + + 346 + + + YES + + + + + + 347 + + + YES + + + + + + 348 + + + YES + + + + + + 349 + + + YES + + + + + + 350 + + + YES + + + + + + 351 + + + YES + + + + + + 352 + + + YES + + + + + + 353 + + + YES + + + + + + 354 + + + YES + + + + + + 355 + + + + + 356 + + + + + 357 + + + + + 358 + + + + + 359 + + + + + 360 + + + + + 361 + + + + + 362 + + + + + 363 + + + + + 364 + + + + + 365 + + + + + 366 + + + + + 367 + + + YES + + + + + + 368 + + + + + 416 + + + + + 417 + + + + + 418 + + + + + 420 + + + + + 421 + + + + + 422 + + + + + 423 + + + + + 424 + + + + + 425 + + + + + 426 + + + + + 427 + + + + + 428 + + + + + 429 + + + + + 430 + + + + + 431 + + + + + 432 + + + + + + + YES + + YES + -1.IBPluginDependency + -2.IBPluginDependency + -3.IBPluginDependency + 1.IBEditorWindowLastContentRect + 1.IBPluginDependency + 1.IBWindowTemplateEditedContentRect + 1.NSWindowTemplate.visibleAtLaunch + 106.IBAttributePlaceholdersKey + 106.IBPluginDependency + 107.CustomClassName + 107.IBPluginDependency + 108.IBAttributePlaceholdersKey + 108.IBPluginDependency + 109.CustomClassName + 109.IBPluginDependency + 110.IBAttributePlaceholdersKey + 110.IBPluginDependency + 111.CustomClassName + 111.IBPluginDependency + 112.IBAttributePlaceholdersKey + 112.IBPluginDependency + 113.CustomClassName + 113.IBPluginDependency + 114.IBAttributePlaceholdersKey + 114.IBPluginDependency + 115.CustomClassName + 115.IBPluginDependency + 116.IBAttributePlaceholdersKey + 116.IBPluginDependency + 117.CustomClassName + 117.IBPluginDependency + 118.IBAttributePlaceholdersKey + 118.IBPluginDependency + 119.CustomClassName + 119.IBPluginDependency + 120.IBAttributePlaceholdersKey + 120.IBPluginDependency + 121.CustomClassName + 121.IBPluginDependency + 122.IBAttributePlaceholdersKey + 122.IBPluginDependency + 123.CustomClassName + 123.IBPluginDependency + 124.IBAttributePlaceholdersKey + 124.IBPluginDependency + 125.CustomClassName + 125.IBPluginDependency + 126.IBAttributePlaceholdersKey + 126.IBPluginDependency + 127.CustomClassName + 127.IBPluginDependency + 154.IBAttributePlaceholdersKey + 154.IBPluginDependency + 155.CustomClassName + 155.IBPluginDependency + 2.CustomClassName + 2.IBAttributePlaceholdersKey + 2.IBPluginDependency + 203.IBAttributePlaceholdersKey + 203.IBPluginDependency + 204.CustomClassName + 204.IBPluginDependency + 207.IBAttributePlaceholdersKey + 207.IBPluginDependency + 208.CustomClassName + 208.IBPluginDependency + 214.IBAttributePlaceholdersKey + 214.IBPluginDependency + 215.CustomClassName + 215.IBPluginDependency + 220.IBAttributePlaceholdersKey + 220.IBPluginDependency + 220.IBViewBoundsToFrameTransform + 221.CustomClassName + 221.IBPluginDependency + 226.IBAttributePlaceholdersKey + 226.IBPluginDependency + 227.CustomClassName + 227.IBPluginDependency + 231.IBAttributePlaceholdersKey + 231.IBPluginDependency + 232.CustomClassName + 232.IBPluginDependency + 240.IBAttributePlaceholdersKey + 240.IBPluginDependency + 241.CustomClassName + 241.IBPluginDependency + 247.IBAttributePlaceholdersKey + 247.IBPluginDependency + 247.IBViewBoundsToFrameTransform + 248.CustomClassName + 248.IBPluginDependency + 270.IBAttributePlaceholdersKey + 270.IBPluginDependency + 271.CustomClassName + 271.IBPluginDependency + 303.IBAttributePlaceholdersKey + 303.IBPluginDependency + 304.CustomClassName + 304.IBPluginDependency + 306.IBAttributePlaceholdersKey + 306.IBPluginDependency + 307.CustomClassName + 307.IBPluginDependency + 312.IBAttributePlaceholdersKey + 312.IBPluginDependency + 313.IBPluginDependency + 315.IBAttributePlaceholdersKey + 315.IBPluginDependency + 316.IBPluginDependency + 317.IBAttributePlaceholdersKey + 317.IBPluginDependency + 318.IBPluginDependency + 319.IBAttributePlaceholdersKey + 319.IBPluginDependency + 320.IBPluginDependency + 321.IBAttributePlaceholdersKey + 321.IBPluginDependency + 322.IBAttributePlaceholdersKey + 322.IBPluginDependency + 323.IBAttributePlaceholdersKey + 323.IBPluginDependency + 324.IBAttributePlaceholdersKey + 324.IBPluginDependency + 325.IBPluginDependency + 326.IBPluginDependency + 327.IBPluginDependency + 328.IBPluginDependency + 329.IBAttributePlaceholdersKey + 329.IBPluginDependency + 330.IBAttributePlaceholdersKey + 330.IBPluginDependency + 331.IBAttributePlaceholdersKey + 331.IBPluginDependency + 332.IBAttributePlaceholdersKey + 332.IBPluginDependency + 333.IBAttributePlaceholdersKey + 333.IBPluginDependency + 334.IBAttributePlaceholdersKey + 334.IBPluginDependency + 335.IBAttributePlaceholdersKey + 335.IBPluginDependency + 336.IBPluginDependency + 337.IBPluginDependency + 338.IBPluginDependency + 339.IBPluginDependency + 340.IBPluginDependency + 341.IBPluginDependency + 342.IBPluginDependency + 343.IBAttributePlaceholdersKey + 343.IBPluginDependency + 344.IBAttributePlaceholdersKey + 344.IBPluginDependency + 345.IBAttributePlaceholdersKey + 345.IBPluginDependency + 346.IBAttributePlaceholdersKey + 346.IBPluginDependency + 347.IBAttributePlaceholdersKey + 347.IBPluginDependency + 348.IBAttributePlaceholdersKey + 348.IBPluginDependency + 349.IBAttributePlaceholdersKey + 349.IBPluginDependency + 350.IBAttributePlaceholdersKey + 350.IBPluginDependency + 351.IBAttributePlaceholdersKey + 351.IBPluginDependency + 352.IBAttributePlaceholdersKey + 352.IBPluginDependency + 353.IBAttributePlaceholdersKey + 353.IBPluginDependency + 354.IBAttributePlaceholdersKey + 354.IBPluginDependency + 355.IBPluginDependency + 356.IBPluginDependency + 357.IBPluginDependency + 358.IBPluginDependency + 359.IBPluginDependency + 360.IBPluginDependency + 361.IBPluginDependency + 362.IBPluginDependency + 363.IBPluginDependency + 364.IBPluginDependency + 365.IBPluginDependency + 366.IBPluginDependency + 367.IBAttributePlaceholdersKey + 367.IBPluginDependency + 368.IBPluginDependency + 416.IBAttributePlaceholdersKey + 416.IBPluginDependency + 416.IBViewBoundsToFrameTransform + 416.IBViewIntegration.shadowBlurRadius + 416.IBViewIntegration.shadowColor + 416.IBViewIntegration.shadowOffsetHeight + 416.IBViewIntegration.shadowOffsetWidth + 417.IBAttributePlaceholdersKey + 417.IBPluginDependency + 417.IBViewBoundsToFrameTransform + 417.IBViewIntegration.shadowBlurRadius + 417.IBViewIntegration.shadowColor + 417.IBViewIntegration.shadowOffsetHeight + 417.IBViewIntegration.shadowOffsetWidth + 418.IBAttributePlaceholdersKey + 418.IBPluginDependency + 418.IBViewBoundsToFrameTransform + 418.IBViewIntegration.shadowBlurRadius + 418.IBViewIntegration.shadowColor + 418.IBViewIntegration.shadowOffsetHeight + 418.IBViewIntegration.shadowOffsetWidth + 420.IBAttributePlaceholdersKey + 420.IBPluginDependency + 420.IBViewBoundsToFrameTransform + 420.IBViewIntegration.shadowBlurRadius + 420.IBViewIntegration.shadowColor + 420.IBViewIntegration.shadowOffsetHeight + 420.IBViewIntegration.shadowOffsetWidth + 421.IBAttributePlaceholdersKey + 421.IBPluginDependency + 421.IBViewBoundsToFrameTransform + 421.IBViewIntegration.shadowBlurRadius + 421.IBViewIntegration.shadowColor + 421.IBViewIntegration.shadowOffsetHeight + 421.IBViewIntegration.shadowOffsetWidth + 422.IBAttributePlaceholdersKey + 422.IBPluginDependency + 422.IBViewBoundsToFrameTransform + 422.IBViewIntegration.shadowBlurRadius + 422.IBViewIntegration.shadowColor + 422.IBViewIntegration.shadowOffsetHeight + 422.IBViewIntegration.shadowOffsetWidth + 423.IBAttributePlaceholdersKey + 423.IBPluginDependency + 423.IBViewBoundsToFrameTransform + 423.IBViewIntegration.shadowBlurRadius + 423.IBViewIntegration.shadowColor + 423.IBViewIntegration.shadowOffsetHeight + 423.IBViewIntegration.shadowOffsetWidth + 424.IBAttributePlaceholdersKey + 424.IBPluginDependency + 424.IBViewBoundsToFrameTransform + 424.IBViewIntegration.shadowBlurRadius + 424.IBViewIntegration.shadowColor + 424.IBViewIntegration.shadowOffsetHeight + 424.IBViewIntegration.shadowOffsetWidth + 425.IBAttributePlaceholdersKey + 425.IBPluginDependency + 425.IBViewBoundsToFrameTransform + 425.IBViewIntegration.shadowBlurRadius + 425.IBViewIntegration.shadowColor + 425.IBViewIntegration.shadowOffsetHeight + 425.IBViewIntegration.shadowOffsetWidth + 426.IBAttributePlaceholdersKey + 426.IBPluginDependency + 426.IBViewBoundsToFrameTransform + 426.IBViewIntegration.shadowBlurRadius + 426.IBViewIntegration.shadowColor + 426.IBViewIntegration.shadowOffsetHeight + 426.IBViewIntegration.shadowOffsetWidth + 427.IBAttributePlaceholdersKey + 427.IBPluginDependency + 427.IBViewBoundsToFrameTransform + 427.IBViewIntegration.shadowBlurRadius + 427.IBViewIntegration.shadowColor + 427.IBViewIntegration.shadowOffsetHeight + 427.IBViewIntegration.shadowOffsetWidth + 428.IBAttributePlaceholdersKey + 428.IBPluginDependency + 428.IBViewBoundsToFrameTransform + 428.IBViewIntegration.shadowBlurRadius + 428.IBViewIntegration.shadowColor + 428.IBViewIntegration.shadowOffsetHeight + 428.IBViewIntegration.shadowOffsetWidth + 429.IBAttributePlaceholdersKey + 429.IBPluginDependency + 429.IBViewBoundsToFrameTransform + 429.IBViewIntegration.shadowBlurRadius + 429.IBViewIntegration.shadowColor + 429.IBViewIntegration.shadowOffsetHeight + 429.IBViewIntegration.shadowOffsetWidth + 430.IBAttributePlaceholdersKey + 430.IBPluginDependency + 430.IBViewBoundsToFrameTransform + 430.IBViewIntegration.shadowBlurRadius + 430.IBViewIntegration.shadowColor + 430.IBViewIntegration.shadowOffsetHeight + 430.IBViewIntegration.shadowOffsetWidth + 431.IBAttributePlaceholdersKey + 431.IBPluginDependency + 431.IBViewBoundsToFrameTransform + 431.IBViewIntegration.shadowBlurRadius + 431.IBViewIntegration.shadowColor + 431.IBViewIntegration.shadowOffsetHeight + 431.IBViewIntegration.shadowOffsetWidth + 432.IBAttributePlaceholdersKey + 432.IBPluginDependency + 432.IBViewBoundsToFrameTransform + 432.IBViewIntegration.shadowBlurRadius + 432.IBViewIntegration.shadowColor + 432.IBViewIntegration.shadowOffsetHeight + 432.IBViewIntegration.shadowOffsetWidth + + + YES + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + {{1404, 21}, {1280, 585}} + com.apple.InterfaceBuilder.CocoaPlugin + {{1404, 21}, {1280, 585}} + + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Switch Register with twelve switches enable communication between the operator and the machine. It allows a 12-bit word to be input. A switch up means a binary 1; switch down is a 0. SR is used during manual functions or under program control. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + BackgroundView + + YES + + + YES + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + V2hlbiBTVyBTd2l0Y2ggaXMgdXAsIHRoZSBTVyBsaW5lIG9uIHRoZSBPTU5JQlVTIGlzIGhpZ2g7IHdo +ZW4gaXQgaXMgZG93biwgdGhlIGxpbmUgaXMgbG93LiBJdCBpcyB1c2VkIGJ5IHNwZWNpYWwgcGVyaXBo +ZXJhbCBjb250cm9scywgc3VjaCBhcyB0aGUgYm9vdHN0cmFwIGxvYWRlci4KCldpdGggdGhlIFBEUC04 +L0UgU2ltdWxhdG9yLCB0aGlzIHNpZ25hbCBpcyBhdmFpbGFibGUgZm9yIEkvTyBkZXZpY2VzIHZpYSB0 +aGUg4oCca2M4ZWFTV0NoYW5nZWROb3RpZmljYXRpb27igJ0gbm90aWZpY2F0aW9uLg + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Address Load Key loads the contents of the Switch Register into the CPMA and forces the processor to the Fetch state. (On a hardware PDP-8/E, no major state is set while this key is depressed.) + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Extended Address Load Key loads the contents of SR(6-8) into the Instruction Field (IF, IB), SR(9-11) into the Data Field (DF) of the KM8-E Memory Extension and forces the machine to system mode by clearing the user mode flags UF and UB. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Clear Key issues an initialize pulse, clearing the AC, Link, the interrupt system, and the I/O flags. + + + com.apple.InterfaceBuilder.CocoaPlugin + + P4AAAL+AAABEZoAAwwkAAA + + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Continue Key resumes the computer program by issuing a memory start and setting the Run flip-flop. The word stored at the address currently held by the CPMA is taken as the first instruction. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Examine Key puts the contents of core memory at the address specified by the contents of the CPMA into the MB. Then the contents of the PC and CPMA are incremented by one to allow examination of the contents of sequential core memory addresses. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + SGFsdCBTd2l0Y2ggY2xlYXJzIHRoZSBSdW4gZmxpcC1mbG9wIGFuZCBjYXVzZXMgdGhlIG1hY2hpbmUg +dG8gc3RvcCBhdCBUUzEgb2YgdGhlIG5leHQgRmV0Y2ggY3ljbGUuIFdoZW4gdGhpcyBzd2l0Y2ggaXMg +aW4gdGhlIGRvd24gcG9zaXRpb24gKGFuZCBTaW5nbGUgU3RlcCBpcyB1cCkgYW5kIHRoZSBjb250aW51 +ZSBrZXkgaXMgb3BlcmF0ZWQsIHRoZSBtYWNoaW5lIGV4ZWN1dGVzIGEgc2luZ2xlIGluc3RydWN0aW9u +LgoKV2l0aCB0aGUgUERQLTgvRSBTaW11bGF0b3IsIHRoZSBTdGVwLCBUcmFjZSwgR28gYW5kIEhhbHQg +YnV0dG9ucyBpbiB0aGUgQ1BVIHdpbmRvdyBhcmUgbm90IGF2YWlsYWJsZSB3aGlsZSB0aGUgSGFsdCBT +d2l0Y2ggaXMgaW4gdGhlIGRvd24gcG9zaXRpb24uA + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + U2luZ2xlIFN0ZXAgU3dpdGNoIGNsZWFycyB0aGUgUnVuIGZsaXAtZmxvcCBhbmQgY2F1c2VzIHRoZSBt +YWNoaW5lIHRvIHN0b3AgYXQgVFMxIG9mIHRoZSBuZXh0IGN5Y2xlLiBXaGVuIHRoaXMgc3dpdGNoIGlz +IGluIHRoZSBkb3duIHBvc2l0aW9uIGFuZCB0aGUgY29udGludWUga2V5IGlzIG9wZXJhdGVkLCB0aGUg +bWFjaGluZSBleGVjdXRlcyBleGFjdGx5IG9uZSBtZW1vcnkgY3ljbGUuCgpXaXRoIHRoZSBQRFAtOC9F +IFNpbXVsYXRvciwgdGhlIFN0ZXAsIFRyYWNlLCBHbyBhbmQgSGFsdCBidXR0b25zIGluIHRoZSBDUFUg +d2luZG93IGFyZSBub3QgYXZhaWxhYmxlIHdoaWxlIHRoZSBTaW5nbGUgU3RlcCBTd2l0Y2ggaXMgaW4g +dGhlIGRvd24gcG9zaXRpb24uA + + + com.apple.InterfaceBuilder.CocoaPlugin + + P4AAAL+AAABEhkAAwwkAAA + + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Deposit Key loads the contents of SR into MB and core memory at the address given by the contents of the CPMA. Then the PC and CPMA are incremented by one. This allows storing of information in sequential memory locations by repeated deposit operation. + + + com.apple.InterfaceBuilder.CocoaPlugin + ConsoleSwitchCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Indicator Selector Switch is a six-position rotary switch, used to select a register for display. For STATE, the first line of the table at the left describes the displayed bits; for STATUS, refer to the second line. + + + com.apple.InterfaceBuilder.CocoaPlugin + KnobCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Power Key is a key operated switch. The OFF position quits the PDP-8/E Simulator. The POWER position enables all manual controls. The PANEL LOCK position disables all controls (except SR and SW) and turns off all panel indicators (except RUN). + + + com.apple.InterfaceBuilder.CocoaPlugin + KnobCell + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Extended Memory Address indicates which extended memory field (data or instruction field) is beeing accessed. When no KM8-E Memory Extension is present, EMA is always zero. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Extended Memory Address indicates which extended memory field (data or instruction field) is beeing accessed. When no KM8-E Memory Extension is present, EMA is always zero. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Extended Memory Address indicates which extended memory field (data or instruction field) is beeing accessed. When no KM8-E Memory Extension is present, EMA is always zero. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Memory Address indicates the memory address which will be accessed next. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + Depending on the position of the Indicator Selector Switch, STATE or STATUS bits of the CPU, the AC, the memory buffer MD, the MQ, or the CPU´s data BUS is displayed here. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + When the Run light is lit, the machine´s timing is enabled and capable of executing instructions. + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATE, these three lights of the display indicate the current major state of the CPU: Fetch, Defer, Execute. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUOhgABDkqeAA + + + + 3 + MAA + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATE, these three lights of the display show the Instruction Register (IR), i. e. indicate the opcode of the instruction currently processed by the CPU. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUPZgABDkoAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATE, this bit of the display indicates the direction of data transfer between the memory buffer and core memory. When the light is lit, transfer occurs from memory to MD, else vice versa. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUQJQABDkoAAA + + + + + + + ToolTip + + ToolTip + + V2hlbiB0aGUgaW5kaWNhdG9yIHNlbGVjdG9yIHN3aXRjaCBpcyB0dXJuZWQgdG8gU1RBVEUsIHRoaXMg +Yml0IG9mIHRoZSBkaXNwbGF5IGluZGljYXRlcyB0aGUgQlJLIERBVEEgQ09OVCBzaWduYWwgb2YgdGhl +IE9NTklCVVMuCgpXaXRoIHRoZSBQRFAtOC9FIFNpbXVsYXRvciwgdGhpcyBzaWduYWwgaXMgbm90IGF2 +YWlsYWJsZS4 + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUQSgABDkoAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATE, this bit of the display indicates the SW line of the OMNIBUS, set by the SW console switch. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUQbYABDkoAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATE, this bit of the display indicates the I/O PAUSE signal of the OMNIBUS. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUQlAABDkoAAA + + + + + + + ToolTip + + ToolTip + + V2hlbiB0aGUgaW5kaWNhdG9yIHNlbGVjdG9yIHN3aXRjaCBpcyB0dXJuZWQgdG8gU1RBVEUsIHRoaXMg +Yml0IG9mIHRoZSBkaXNwbGF5IGluZGljYXRlcyB0aGUgQlJLIElOIFBST0cgc2lnbmFsIG9mIHRoZSBP +TU5JQlVTLgoKV2l0aCB0aGUgUERQLTgvRSBTaW11bGF0b3IsIHRoaXMgc2lnbmFsIGlzIG5vdCBhdmFp +bGFibGUuA + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUQuQABDkoAAA + + + + + + + ToolTip + + ToolTip + + V2hlbiB0aGUgaW5kaWNhdG9yIHNlbGVjdG9yIHN3aXRjaCBpcyB0dXJuZWQgdG8gU1RBVEUsIHRoaXMg +Yml0IG9mIHRoZSBkaXNwbGF5IGluZGljYXRlcyB0aGUgQlJFQUsgQ1lDTEUgc2lnbmFsIG9mIHRoZSBP +TU5JQlVTLgoKV2l0aCB0aGUgUERQLTgvRSBTaW11bGF0b3IsIHRoaXMgc2lnbmFsIGlzIG5vdCBhdmFp +bGFibGUuA + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUQIQABDkoAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATUS and the machine has a KM8-E Memory Extension, these three bit of the display indicate the current Instruction Field (IF). + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUQJQABDiQAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATUS and the machine has a KM8-E Memory Extension, these three bit of the display indicate the current Data Field (DF). + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUPZAABDkoAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATUS and the machine has a KM8-E Memory Extension, this bit of the display indicates the state of the User Mode. When lit, the CPU runs in user mode (UF=1), else in system mode (UF=0). + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUP/gABDiQAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATUS, this bit of the display indicates the state of the Interrupt Enable Flag of the CPU. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUPsQABDiQAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATUS, this bit of the display indicates if interrupts are not allowed (e. g. in the instruction sequence ION, JMP I 0). + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUPZwABDiQAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATUS, this bit of the display indicates whether an interrupt request is pending. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUP+wABDiQAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATUS and the machine has a KE8-E Extended Arithmetic Element, this bit of the display indicates the GTF (Greater Than Flag) of the EAE. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUPrAABDiQAAA + + + + + + + ToolTip + + ToolTip + + When the indicator selector switch is turned to STATUS, this bit of the display indicates the Link register of the CPU. + + + com.apple.InterfaceBuilder.CocoaPlugin + + AUQJQABDiIAAA + + + + + + + + + YES + + + YES + + + + + YES + + + YES + + + + 432 + + + + YES + + BackgroundView + NSView + + IBProjectSource + KC8EA/BackgroundView.h + + + + ConsoleSwitchCell + NSButtonCell + + leftNeighbour + ConsoleSwitchCell + + + leftNeighbour + + leftNeighbour + ConsoleSwitchCell + + + + IBProjectSource + KC8EA/ConsoleSwitchCell.h + + + + KC8EA + PDP8Plugin + + YES + + YES + addrloadClicked: + clearClicked: + contClicked: + depClicked: + examClicked: + extdaddrloadClicked: + haltClicked: + keyClicked: + knobClicked: + srClicked: + stingstepClicked: + swClicked: + + + YES + id + id + id + id + id + id + id + id + id + id + id + id + + + + YES + + YES + addrloadClicked: + clearClicked: + contClicked: + depClicked: + examClicked: + extdaddrloadClicked: + haltClicked: + keyClicked: + knobClicked: + srClicked: + stingstepClicked: + swClicked: + + + YES + + addrloadClicked: + id + + + clearClicked: + id + + + contClicked: + id + + + depClicked: + id + + + examClicked: + id + + + extdaddrloadClicked: + id + + + haltClicked: + id + + + keyClicked: + id + + + knobClicked: + id + + + srClicked: + id + + + stingstepClicked: + id + + + swClicked: + id + + + + + YES + + YES + addr0 + addr1 + addr10 + addr11 + addr12 + addr13 + addr14 + addr2 + addr3 + addr4 + addr5 + addr6 + addr7 + addr8 + addr9 + addrload + clear + cont + dep + display0 + display1 + display10 + display11 + display2 + display3 + display4 + display5 + display6 + display7 + display8 + display9 + exam + extdaddrload + halt + key + knob + run + singstep + sr0 + sr1 + sr10 + sr11 + sr2 + sr3 + sr4 + sr5 + sr6 + sr7 + sr8 + sr9 + sw + window + + + YES + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + KeepInMenuWindow + + + + YES + + YES + addr0 + addr1 + addr10 + addr11 + addr12 + addr13 + addr14 + addr2 + addr3 + addr4 + addr5 + addr6 + addr7 + addr8 + addr9 + addrload + clear + cont + dep + display0 + display1 + display10 + display11 + display2 + display3 + display4 + display5 + display6 + display7 + display8 + display9 + exam + extdaddrload + halt + key + knob + run + singstep + sr0 + sr1 + sr10 + sr11 + sr2 + sr3 + sr4 + sr5 + sr6 + sr7 + sr8 + sr9 + sw + window + + + YES + + addr0 + NSButton + + + addr1 + NSButton + + + addr10 + NSButton + + + addr11 + NSButton + + + addr12 + NSButton + + + addr13 + NSButton + + + addr14 + NSButton + + + addr2 + NSButton + + + addr3 + NSButton + + + addr4 + NSButton + + + addr5 + NSButton + + + addr6 + NSButton + + + addr7 + NSButton + + + addr8 + NSButton + + + addr9 + NSButton + + + addrload + NSButton + + + clear + NSButton + + + cont + NSButton + + + dep + NSButton + + + display0 + NSButton + + + display1 + NSButton + + + display10 + NSButton + + + display11 + NSButton + + + display2 + NSButton + + + display3 + NSButton + + + display4 + NSButton + + + display5 + NSButton + + + display6 + NSButton + + + display7 + NSButton + + + display8 + NSButton + + + display9 + NSButton + + + exam + NSButton + + + extdaddrload + NSButton + + + halt + NSButton + + + key + NSButton + + + knob + NSButton + + + run + NSButton + + + singstep + NSButton + + + sr0 + NSButton + + + sr1 + NSButton + + + sr10 + NSButton + + + sr11 + NSButton + + + sr2 + NSButton + + + sr3 + NSButton + + + sr4 + NSButton + + + sr5 + NSButton + + + sr6 + NSButton + + + sr7 + NSButton + + + sr8 + NSButton + + + sr9 + NSButton + + + sw + NSButton + + + window + KeepInMenuWindow + + + + + IBProjectSource + KC8EA/KC8EA.h + + + + KeepInMenuWindow + NSWindow + + YES + + YES + orderBackFromDefaults: + orderFrontFromDefaults: + + + YES + id + id + + + + YES + + YES + orderBackFromDefaults: + orderFrontFromDefaults: + + + YES + + orderBackFromDefaults: + id + + + orderFrontFromDefaults: + id + + + + + IBProjectSource + Utilities/KeepInMenuWindow.h + + + + KnobCell + NSButtonCell + + IBProjectSource + KC8EA/KnobCell.h + + + + NSControl + + IBProjectSource + Categories/NSControl+FileDrop.h + + + + PDP8Plugin + NSObject + + IBProjectSource + Plugins/PluginAPI.h + + + + + YES + + KeepInMenuWindow + NSWindow + + IBFrameworkSource + PluginFramework.framework/Headers/KeepInMenuWindow.h + + + + NSControl + + IBFrameworkSource + PluginFramework.framework/Headers/NSControl+FileDrop.h + + + + PDP8Plugin + NSObject + + IBFrameworkSource + PluginFramework.framework/Headers/PluginAPI.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + + com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3 + + + YES + ../../pdp8e-simulator.xcodeproj + 3 + + YES + + YES + addrload_down + addrload_up_extdaddrload_up + clear_down + clear_up_cont_up + cont_down + cont_up_exam_up + dep_down + dep_up + exam_down + exam_up_halt_up + extdaddrload_down + extdaddrload_up + halt_down + halt_up_singstep_down + key0 + knob0 + light_off + light_on + singstep_down + singstep_up + sr0down + sr0up_sr1down + sr10down + sr10up_sr11down + sr11down + sr11up + sr1down + sr1up_sr2down + sr2down + sr2up_sr3down + sr3down + sr3up_sr4down + sr4down + sr4up_sr5down + sr5down + sr5up_sr6down + sr6down + sr6up_sr7down + sr7down + sr7up_sr8down + sr8down + sr8up_sr9down + sr9down + sr9up_sr10down + sw_down + sw_up + + + YES + {39, 55} + {39, 55} + {39, 55} + {39, 55} + {37, 55} + {37, 55} + {42, 55} + {42, 55} + {39, 55} + {39, 55} + {38, 55} + {38, 55} + {37, 55} + {37, 55} + {127, 70} + {82, 90} + {18, 18} + {18, 18} + {39, 55} + {39, 55} + {38, 54} + {38, 54} + {37, 54} + {37, 54} + {38, 54} + {38, 54} + {38, 54} + {38, 54} + {37, 54} + {37, 54} + {37, 54} + {37, 54} + {38, 54} + {38, 54} + {37, 54} + {37, 54} + {38, 54} + {38, 54} + {38, 54} + {38, 54} + {37, 54} + {37, 54} + {38, 54} + {38, 54} + {41, 55} + {41, 55} + + + + diff --git a/KC8EA/English.lproj/KC8EA.nib/keyedobjects.nib b/KC8EA/English.lproj/KC8EA.nib/keyedobjects.nib new file mode 100644 index 0000000..0471f12 Binary files /dev/null and b/KC8EA/English.lproj/KC8EA.nib/keyedobjects.nib differ diff --git a/KC8EA/English.lproj/KC8EAOnlineHelp/index.html b/KC8EA/English.lproj/KC8EAOnlineHelp/index.html new file mode 100644 index 0000000..478b526 --- /dev/null +++ b/KC8EA/English.lproj/KC8EAOnlineHelp/index.html @@ -0,0 +1,314 @@ + + + + + + KC8-EA Programmer’s Console Help + + + + + + + +

Controls and Indicators of the KC8-EA Programmer’s Console

+ +

+The controls and indicators on the Programmer’s Console provide manual control and indicate the +program conditions of the PDP-8/E. Controls on the Programmer’s Console provide the operator +with the hardware to start, stop, examine, modify, or continue a program. The indicators on the console +provide a visual indication of the machine status and current program, the contents of the major registers, +and the condition of the control flip-flops. A lighted indicator denotes the presence of a binary 1 in +a specific register bit position or control flip-flop. The table below lists the functions of controls and +indicators. The controls are divided into two groups; switches and keys. Keys are momentary, or +spring-return, switches. +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Control or IndicatorFunction
Off / Power / Panel Lock + This is a key operated switch. In the counter-clockwise, or OFF, position, the + switch disconnects all primary power to the machiine. In the POWER, or straight up position, + it enables all manual controls and applies primary computer power. In the PANEL LOCK or + clockwise position, it disables all keys and switches with the exception of the Switch + Register and the SW switch. In this position, a running program is protected from + inadvertent switch operation and all panel indicators except the RUN light are turned off. +
SW + When this switch is up, the line on the OMNIBUS called SW is high; when the lever is down, + the line is low. This switch is used by special peripheral controls, such as the + Bootstrap Loader. +
Switch Register Switches
(SR)
+ These 12 switches provide a means of communication between operator and machine. + They allow a 12-bit word to be input. When the switch is up, it designates a binary 1 + to the machine; switch down is a 0. These switches are used during manual functions or + under program control. +
Load Address Key
(ADDR LOAD)
+ This key loads the contents of the Switch Register into the CPMA and forces Fetch to be + set (no Major States while the Load Address Key is depressed). +
Extended Address Load
(EXTD ADDR LOAD)
+ This switch loads the contents of SR(6–11) into the Data Field and Instruction Field + registers of the Memory Extension Control. SR(9–11) goes to Data Field 0–2, + SR(6–8) goes to Instruction Field 0–2. +
Clear Key (CLEAR) + This key issues an Initialize Pulse, clearing the AC, Link, Interrupt system, and I/O Flags. +
Continue Key (CONT) + This key resumes the computer program by issuing a Memory Start and setting the Run + flip-flop. The word stored at the address currently held by the CPMA is taken as the first + instruction. +
Examine Key (EXAM) + Puts the contents of core memory at the address specified by the contents of the CPMA + into the MB. Then the contents of the PC and CPMA are incremented by one to allow + examination of the contents of sequential core memory addresses by repeating the operation + of the Examine switch. +
Halt Switch (HALT) + This switch clears the Run flip-flop and and causes the machine to stop at TS1 of the next + Fetch cycle. This switch is also used for single instruction stepping. +
Single Step Switch
(SING STEP)
+ This switch clears the Run flip-flop and causes the machine to stop at TS1 of the next + cycle. Thereafter, repeated depressing of the Continue key steps the program one cycle at + a time, so that the contents of registers can be observed in each state. +
Deposit Key (DEP) + Loads the contents of the SR into the MB and core memory at the address given by the + current contents of the CPMA. Then the contents of the PC and CPMA are incremented by one. + This allows storing of information in sequential memory addresses by repeated operation + of the Deposit switch. +
Indicator Selector Switch + This is a six-position rotary switch, used to select a register for display. The six + positions are as follows: +
    +
  • STATE — Indicates an individual function for each bit:
    + + + + + + + + + + + + + +
    0Fetch
    1Defer
    2Execute
    3Instruction Register 0
    4Instruction Register 1
    5Instruction Register 2
    6MD DIR
    7Data Control
    8SW
    9Pause
    10Break in Prog
    11Break
    +
  • +
  • STATUS — Indicates an individual function each bit:
    + + + + + + + + + + + + + +
    0Link
    1Greater Than Flag
    2Interrupt Bus
    3No Interrupt Allowed
    4Interrupt On
    5User Mode
    6Instruction Field 0
    7Instruction Field 1
    8Instruction Field 2
    9Data Field 0
    10Data Field 1
    11Data Field 2
    +
  • +
  • AC — Indicates bits 0–11 of the Accumulator at TS1.
  • +
  • MD — Indicates information just written or rewritten into memory.
  • +
  • MQ — Indicates contents of MQ register during TS1.
  • +
  • BUS — Indicates bis 0–11 of the DATA lines.
  • +
+
Memory Address + Indicates the contents of the memory address which will be accessed next. +
EMA + Indicates which Extended Memory field is being accessed. +
Run Light + When lit means machine’s timing is enabled and capable of executing instructions. +
+ +

Limitations and extensions of the simulated KC8-EA Programmer’s Console

+ +

+The simulated KC8-EA has some limitations and extensions compared to a hardware KC8-EA: +

+ +
    +
  • + The console is able to simulate single step execution. This simulation is done console + internally because the PDP-8/E Simulator itself performs PDP-8/E instructions atomically. + While executing a Fetch and Defer memory cycle, no state changes occur in the simulators + PDP-8/E, only the display lights of the console reflect the accompanying state changes. + When the final Execute memory cycle (or, for single cycle instructions, e. g. OPRs, the + Fetch cycle) is performed, the simulators PDP-8/E is instructed by the console to perform + the complete PDP-8/E instruction at once. So, while the console is in a Defer or Execute + state, there may be inconsistencies between the register values visible in the CPU window + and the corresponding values displayed by the KC8-EA. To avoid confusion, it is suggested + not to alternately use single step execution of the console and the instruction stepping + of the simulator. +
  • +
  • + When the user depresses the Single Step switch while the PDP-8/E is running, + it halts at TS1 of a Fetch cycle, like with the Halt switch, and not at TS1 of any memory cycle. + When the Single Step or Halt switch is down, the simulator can’t be started + in Step, Trace or Go mode. +
  • +
  • + When the machine is in single instruction mode (Halt switch down) and an interrupt is pending, + depressing the Continue switch once brings the simulator to the first instruction of the + interrupt service routine at location 1. On a real PDP-8/E, the switch must be operated twice + to reach this state. When the interrupt is caused by a privileged instruction executed in + user mode, the simulator halts after the privileged instruction, a hardware PDP-8/E halts + at location 0. The next operation of the Continue switch brings both the simulator and a + real PDP-8/E to the first instruction of the interrupt service routine at location 1. + This different behaviour is also present when stepping on memory cycle level (Single Step switch + down). +
  • +
  • + The state of the SW switch is not directly available for other I/O devices. But whenever the + user operates this switch, a Cocoa notification with the name + “kc8eaSWChangedNotification” is posted; the notification object is a number representing + the state of the switch, 0 for down and 1 for up. +
  • +
  • + Turning the Power key to OFF quits the PDP-8/E Simulator. +
  • +
  • + When the PDP-8/E is running, the display lights are sampled with a frequency of 60 Hz. They then + display the state at the end of the Fetch cycle, before the instruction is actually executed, + of the next PDP-8/E instruction to be performed; so the STATE display display can indicate Defer + and Execute cycles. +
  • +
  • + At least in the following points the display differs from a hardware PDP-8/E: +
      +
    • + The DATA CONT, BRK PROG and BRK indicators of the STATE display are always off. +
    • +
    • + The PAUSE indicator of the STATE display may be inprecise. +
    • +
    • + The NO INT indicator of the STATUS display is illuminated when the Interrupt Delay or + Interrupt Inhibit flag is set. On a hardware PDP-8/E, this indicator is derived from + signals not available with the PDP-8/E Simulator. +
    • +
    • + The BUS display may be inprecise under certain circumstances, e. g. for group 3 OPRs + of the EAE or for IOT instructions, where always the AC is shown. +
    • +
    • + The MD display does not reflect the additional memory access of EAE two word instructions. +
    • +
    • + When the PDP-8/E halts from the Step, Trace or Go mode of the simulator, the STATE, MD and + BUS display may be inprecise. E. g. the MD DIR is always turned on, MD shows the opcode + of the last instruction executed, but not the memory references eventually performed by + the instruction. (When you execute single PDP-8/E instructions by pressing the + Continue key of the console while the Halt switch is down, the display is more precise + because then the KC8-EA internally simulates the Fetch, Defer and Execute cycle of the + instruction.) +
    • +
    +
  • +
  • + The console keys and switches can be operated using the following keyboard shortcuts: + + + + + + + + + + + + + + +
    ⌥wOperate the SW switch
    ⌥0,…,⌥9, ⌥a, ⌥bOperate the corresponding switch of the Switch Register
    ⌥lOperate the Load Address key
    ⌥xOperate the Extended Address Load key
    ⌥cOperate the Clear key
    ⌥tOperate the Continue key
    ⌥eOperate the Examine key
    ⌥hOperate the Halt switch
    ⌥sOperate the Single Step switch
    ⌥dOperate the Deposit key
    ⌥<Turn the Indicator Selector switch anticlockwise
    ⌥>Turn the Power key clockwise
    +
  • +
+ + + diff --git a/KC8EA/English.lproj/KC8EAOnlineHelp/pdp8e.png b/KC8EA/English.lproj/KC8EAOnlineHelp/pdp8e.png new file mode 100644 index 0000000..2c0c485 Binary files /dev/null and b/KC8EA/English.lproj/KC8EAOnlineHelp/pdp8e.png differ diff --git a/KC8EA/English.lproj/KC8EAOnlineHelp/styles.css b/KC8EA/English.lproj/KC8EAOnlineHelp/styles.css new file mode 100644 index 0000000..c18751d --- /dev/null +++ b/KC8EA/English.lproj/KC8EAOnlineHelp/styles.css @@ -0,0 +1,239 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * styles.css - Online help - Style sheet + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +p { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +p.small { + font-size: 8pt; +} + +a { + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +a:hover { + text-decoration: underline +} + +ul { + margin-left: 1.25em; padding-left: 0em; +} + +li { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +#mainbox { + background-color: #fff; + margin-top: 30px; + margin-right: 26px; + margin-left: 18px; + position: absolute; + top: 10px +} + +#taskbox { + background-color: #eee; + list-style-type: decimal; + list-style-position: outside; + margin-top: 12px; + margin-bottom: 12px; + border: solid 1px #444 +} + +h1 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 6pt; +} + +h2 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 8pt; +} + +h3 { + font-size: 10pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 5pt; +} + +h4 { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 4pt; +} + +/* index.html */ + +table.index { + padding-top: 20px; + width: 100%; +} + +td.banner { + padding: 20px; +} + +td.toc { + padding-top: 10px; + padding-bottom: 10px; + padding-left: 20px; + padding-right:20px; + border-left: 1px solid darkgray; +} + +p.toc { + line-height: 40px; +} + +/* other pages */ + +table { + border-collapse: separate; + border-spacing: 0px; +} + +th { + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + font-style: bold; + border-bottom: 1px solid gray; + padding-left: 10px; + padding-right: 10px; +} + +th.left { + text-align: left; +} + +td { + text-align: center; + vertical-align: top; + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + padding-left: 10px; + padding-right: 10px; +} + +td.left { + text-align: left; +} + +td.right { + text-align: right; +} + +td.br { + border-right: 1px solid gray; +} + +td.bb { + border-bottom: 1px solid lightgray; +} + +td.bb_left { + text-align: left; + border-bottom: 1px solid lightgray; +} + +td.bbr { + border-bottom: 1px solid lightgray; + border-right: 1px solid gray; +} + +td.opcode { + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_right { + text-align: right; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_left { + text-align: left; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-left: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + border-right: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} diff --git a/KC8EA/English.lproj/io-info.plist b/KC8EA/English.lproj/io-info.plist new file mode 100644 index 0000000..a6c4c7b --- /dev/null +++ b/KC8EA/English.lproj/io-info.plist @@ -0,0 +1,37 @@ + + + + + + ioflags + + + ioaddresses + + + iots + + + + diff --git a/KC8EA/Info.plist b/KC8EA/Info.plist new file mode 100644 index 0000000..ce6e981 --- /dev/null +++ b/KC8EA/Info.plist @@ -0,0 +1,32 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleHelpBookFolder + KC8EAOnlineHelp + CFBundleHelpBookName + KC8-EA Programmer's Console Help + CFBundleIconFile + + CFBundleIdentifier + de.bernhard-baehr.pdp8e.KC8EA + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + ${PRODUCT_NAME} + CFBundlePackageType + BNDL + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + CFBundleShortVersionString + 2.0.2 + NSPrincipalClass + KC8EA + + diff --git a/KC8EA/KC8EA.h b/KC8EA/KC8EA.h new file mode 100644 index 0000000..243fecd --- /dev/null +++ b/KC8EA/KC8EA.h @@ -0,0 +1,103 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * KC8EA.h - KC8-EA Programmer’s Console for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class KeepInMenuWindow, StateMachine; + + +@interface KC8EA : PDP8Plugin +{ +@private + IBOutlet KeepInMenuWindow *window; + IBOutlet NSButton *addr0; + IBOutlet NSButton *addr1; + IBOutlet NSButton *addr2; + IBOutlet NSButton *addr3; + IBOutlet NSButton *addr4; + IBOutlet NSButton *addr5; + IBOutlet NSButton *addr6; + IBOutlet NSButton *addr7; + IBOutlet NSButton *addr8; + IBOutlet NSButton *addr9; + IBOutlet NSButton *addr10; + IBOutlet NSButton *addr11; + IBOutlet NSButton *addr12; + IBOutlet NSButton *addr13; + IBOutlet NSButton *addr14; + IBOutlet NSButton *display0; + IBOutlet NSButton *display1; + IBOutlet NSButton *display2; + IBOutlet NSButton *display3; + IBOutlet NSButton *display4; + IBOutlet NSButton *display5; + IBOutlet NSButton *display6; + IBOutlet NSButton *display7; + IBOutlet NSButton *display8; + IBOutlet NSButton *display9; + IBOutlet NSButton *display10; + IBOutlet NSButton *display11; + IBOutlet NSButton *run; + IBOutlet NSButton *sr0; + IBOutlet NSButton *sr1; + IBOutlet NSButton *sr2; + IBOutlet NSButton *sr3; + IBOutlet NSButton *sr4; + IBOutlet NSButton *sr5; + IBOutlet NSButton *sr6; + IBOutlet NSButton *sr7; + IBOutlet NSButton *sr8; + IBOutlet NSButton *sr9; + IBOutlet NSButton *sr10; + IBOutlet NSButton *sr11; + IBOutlet NSButton *sw; + IBOutlet NSButton *addrload; + IBOutlet NSButton *extdaddrload; + IBOutlet NSButton *clear; + IBOutlet NSButton *cont; + IBOutlet NSButton *exam; + IBOutlet NSButton *halt; + IBOutlet NSButton *singstep; + IBOutlet NSButton *dep; + IBOutlet NSButton *knob; + IBOutlet NSButton *key; + NSTimer *goTimer; + unsigned short addressValue; + unsigned short displayValue; + int powerKeyPosition; + StateMachine *stateMachine; +} + +- (IBAction) srClicked:(id)sender; +- (IBAction) swClicked:(id)sender; +- (IBAction) addrloadClicked:(id)sender; +- (IBAction) extdaddrloadClicked:(id)sender; +- (IBAction) clearClicked:(id)sender; +- (IBAction) contClicked:(id)sender; +- (IBAction) examClicked:(id)sender; +- (IBAction) haltClicked:(id)sender; +- (IBAction) stingstepClicked:(id)sender; +- (IBAction) depClicked:(id)sender; +- (IBAction) knobClicked:(id)sender; +- (IBAction) keyClicked:(id)sender; + +@end diff --git a/KC8EA/KC8EA.m b/KC8EA/KC8EA.m new file mode 100644 index 0000000..78c6f01 --- /dev/null +++ b/KC8EA/KC8EA.m @@ -0,0 +1,555 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * KC8EA.m - KC8-EA Programmer’s Console for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" +#import "PluginFramework/KeepInMenuWindow.h" +#import "PluginFramework/Utilities.h" + +#import "KC8EA.h" +#import "StateMachine.h" +#import "BackgroundView.h" + + +// notifications +#define KC8EA_UPDATE_DISPLAY_NOTIFICATION @"kc8eaUpdateDisplayNotification" +#define KC8EA_SW_CHANGED_NOTIFICATION @"kc8eaSWChangedNotification" + /* Notification posted when the SW switch changes; notification object is a NSNumber + with the new state of SW (0 or 1) */ + +// coder keys +#define CODER_KEY_POWER_KEY @"power" +#define CODER_KEY_DISPLAY_SELECTOR_KNOB @"knob" +#define CODER_KEY_SW @"sw" +#define CODER_KEY_HALT @"halt" +#define CODER_KEY_SINGSTEP @"singstep" + +// tag values of the display selection knob +#define DISPLAY_STATE 0 +#define DISPLAY_STATUS 1 +#define DISPLAY_AC 2 +#define DISPLAY_MD 3 +#define DISPLAY_MQ 4 +#define DISPLAY_BUS 5 + +// tag values of the power key +#define KEY_OFF 0 +#define KEY_POWER 1 +#define KEY_PANEL_LOCK 2 + +// states of the console switches +#define UP 1 +#define DOWN 0 + +// states of the lights +#define OFF 0 +#define ON 1 + + +@implementation KC8EA + + +API_VERSION + + +#pragma mark GUI + + +- (void) updateDisplay +{ + unsigned short val = 0; + if ([key tag] == KEY_POWER) { + switch ([knob tag]) { + case DISPLAY_STATE : + val = [stateMachine state:! [sw state]]; + break; + case DISPLAY_STATUS : + val = [stateMachine status]; + break; + case DISPLAY_AC : + val = [pdp8 getAC]; + break; + case DISPLAY_MD : + val = [stateMachine md]; + break; + case DISPLAY_MQ : + val = [pdp8 getMQ]; + break; + case DISPLAY_BUS : + val = [stateMachine bus]; + break; + default : + NSAssert (FALSE, @"Invalid display selection knob tag"); + break; + } + } + if (displayValue != val) { // optimization + [display0 setState:val & 00001]; + [display1 setState:val & 00002]; + [display2 setState:val & 00004]; + [display3 setState:val & 00010]; + [display4 setState:val & 00020]; + [display5 setState:val & 00040]; + [display6 setState:val & 00100]; + [display7 setState:val & 00200]; + [display8 setState:val & 00400]; + [display9 setState:val & 01000]; + [display10 setState:val & 02000]; + [display11 setState:val & 04000]; + displayValue = val; + } +} + + +- (void) updateAddress +{ + unsigned short addr = 0; + if ([key tag] == KEY_POWER) + addr = [stateMachine cpma]; + if (addressValue != addr) { // optimization + [addr0 setState:addr & 000001]; + [addr1 setState:addr & 000002]; + [addr2 setState:addr & 000004]; + [addr3 setState:addr & 000010]; + [addr4 setState:addr & 000020]; + [addr5 setState:addr & 000040]; + [addr6 setState:addr & 000100]; + [addr7 setState:addr & 000200]; + [addr8 setState:addr & 000400]; + [addr9 setState:addr & 001000]; + [addr10 setState:addr & 002000]; + [addr11 setState:addr & 004000]; + [addr12 setState:addr & 010000]; + [addr13 setState:addr & 020000]; + [addr14 setState:addr & 040000]; + addressValue = addr; + } +} + + +- (void) update +{ + [self updateDisplay]; + [self updateAddress]; +} + + +- (IBAction) srClicked:(id)sender +{ + [pdp8 setSR:[pdp8 getSR] ^ (04000 >> [sender tag])]; +} + + +- (IBAction) swClicked:(id)sender +{ + [self updateDisplay]; + /* The SW switch is not used by the simulator, but plugins that want to know about the + corresponding OMNIBUS signal can listen for this notification */ + [[NSNotificationCenter defaultCenter] postNotificationName:KC8EA_SW_CHANGED_NOTIFICATION + object:[NSNumber numberWithInt:[sender state] == UP]]; +} + + +- (IBAction) addrloadClicked:(id)sender +{ + if (powerKeyPosition != KEY_PANEL_LOCK) { + [stateMachine loadAddress]; + [self update]; + } +} + + +- (IBAction) extdaddrloadClicked:(id)sender +{ + if (powerKeyPosition != KEY_PANEL_LOCK) { + [stateMachine loadExtendedAddress]; + [self update]; + } +} + + +- (IBAction) clearClicked:(id)sender +{ + if (powerKeyPosition != KEY_PANEL_LOCK) + [pdp8 clearAllFlags]; +} + + +- (IBAction) contClicked:(id)sender +{ + if (powerKeyPosition != KEY_PANEL_LOCK && [pdp8 isStopped]) { + [run setState:ON]; + [window display]; + if ([singstep state] == DOWN) { + [stateMachine executeSingleCycle]; + [self update]; + [run setState:OFF]; + } else if ([halt state] == DOWN) { + do { + [stateMachine executeSingleCycle]; + [self update]; + [window display]; + } while (! [stateMachine isInFetchCycle]); + [run setState:OFF]; + } else { + while (! [stateMachine isInFetchCycle]) + [stateMachine executeSingleCycle]; + [[NSApp delegate] performSelector:@selector(go:) withObject:self]; + + } + } +} + + +- (IBAction) examClicked:(id)sender +{ + if (powerKeyPosition != KEY_PANEL_LOCK && [pdp8 isStopped]) { + [run setState:ON]; + [window display]; + [stateMachine examine]; + [self update]; + [run setState:OFF]; + } +} + + +- (IBAction) haltClicked:(id)sender +{ + if (powerKeyPosition != KEY_PANEL_LOCK) { + [pdp8 setHalt:[sender state] == DOWN || [singstep state] == DOWN]; + [NSApp setWindowsNeedUpdate:YES]; // cause Step/Trace/Go CPU window toolbar items update + } +} + + +- (IBAction) stingstepClicked:(id)sender +{ + if (powerKeyPosition != KEY_PANEL_LOCK) { + [pdp8 setHalt:[sender state] == DOWN || [halt state] == DOWN]; + [NSApp setWindowsNeedUpdate:YES]; // cause Step/Trace/Go CPU window toolbar items update + } +} + + +- (IBAction) depClicked:(id)sender +{ + if (powerKeyPosition != KEY_PANEL_LOCK && [pdp8 isStopped]) { + [run setState:ON]; + [window display]; + [stateMachine deposit]; + [self update]; + [run setState:OFF]; + } +} + + +- (IBAction) knobClicked:(id)sender +{ + [self updateDisplay]; +} + + +- (IBAction) keyClicked:(id)sender +{ + NSEventType eventType = [[NSApp currentEvent] type]; + switch ([sender tag]) { + case KEY_OFF : + if (eventType == NSLeftMouseUp || eventType == NSKeyDown) { + NSAlert *alert = [[NSAlert alloc] init]; + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + [alert setMessageText:NSLocalizedStringFromTableInBundle( + @"Do you really want to power off the\nPDP-8/E Simulator?", nil, bundle, @"")]; + [alert addButtonWithTitle: + NSLocalizedStringFromTableInBundle(@"No", nil, bundle, @"")]; + [alert addButtonWithTitle: + NSLocalizedStringFromTableInBundle(@"Yes", nil, bundle, @"")]; + if ([alert runModal] == NSAlertFirstButtonReturn) { + [[sender cell] setTag:eventType == NSKeyDown ? KEY_POWER : powerKeyPosition]; + [self update]; + } else + [NSApp terminate:self]; + [alert release]; + } + break; + case KEY_POWER : + powerKeyPosition = KEY_POWER; + [self update]; + [pdp8 setHalt:[halt state] == DOWN || [singstep state] == DOWN]; + [NSApp setWindowsNeedUpdate:YES]; // cause Step/Trace/Go CPU window toolbar items update + break; + case KEY_PANEL_LOCK : + powerKeyPosition = KEY_PANEL_LOCK; + [self update]; + [pdp8 setHalt:NO]; + [NSApp setWindowsNeedUpdate:YES]; // cause Step/Trace/Go CPU window toolbar items update + break; + default : + NSAssert (FALSE, @"Invalid power key tag"); + break; + } +} + + +#pragma mark Notifications + + +- (void) goTimerFireMethod:(NSTimer *)timer +{ + [stateMachine updateState:NO]; + [self update]; +} + + +- (void) notifyGo:(NSNotification *)notification +{ + // hardcoded refresh rate at 60 Hz + goTimer = [NSTimer scheduledTimerWithTimeInterval:1/60.0 target:self + selector:@selector(goTimerFireMethod:) userInfo:nil repeats:YES]; + [run setState:ON]; +} + + +- (void) notifyStep:(NSNotification *)notification +{ + [stateMachine updateState:NO]; + [self update]; +} + + +- (void) notifyTrace:(NSNotification *)notification +{ + [run setState:YES]; +} + + +- (void) notifyStop:(NSNotification *)notification +{ + [goTimer invalidate]; + goTimer = nil; + [run setState:OFF]; + [stateMachine updateState:YES]; + [self update]; +} + + +- (void) notifyPDP8Changed:(NSNotification *)notification +{ + // NSLog (@"KC8EA notifyPDP8Changed"); + [[NSNotificationQueue defaultQueue] enqueueNotification: + [NSNotification notificationWithName:KC8EA_UPDATE_DISPLAY_NOTIFICATION object:self] + postingStyle:NSPostASAP coalesceMask:NSNotificationCoalescingOnName forModes:nil]; +} + + +- (void) notifyUpdateDisplay:(NSNotification *) notification +{ + // NSLog (@"KC8EA notifyUpdateDisplay"); + [stateMachine updateState:NO]; + [self update]; +} + + +- (void) notifySRChanged:(NSNotification *)notification +{ + unsigned short sreg = [pdp8 getSR]; + [sr0 setState:sreg & 04000 ? 1 : 0]; + [sr1 setState:sreg & 02000 ? 1 : 0]; + [sr2 setState:sreg & 01000 ? 1 : 0]; + [sr3 setState:sreg & 00400 ? 1 : 0]; + [sr4 setState:sreg & 00200 ? 1 : 0]; + [sr5 setState:sreg & 00100 ? 1 : 0]; + [sr6 setState:sreg & 00040 ? 1 : 0]; + [sr7 setState:sreg & 00020 ? 1 : 0]; + [sr8 setState:sreg & 00010 ? 1 : 0]; + [sr9 setState:sreg & 00004 ? 1 : 0]; + [sr10 setState:sreg & 00002 ? 1 : 0]; + [sr11 setState:sreg & 00001 ? 1 : 0]; +} + + +- (void) notifyClearAllFlags:(NSNotification *)notification +{ + [clear highlight:UP]; + [NSTimer scheduledTimerWithTimeInterval:0.1 target:self + selector:@selector(unhighliteClearTimerFireMethod:) userInfo:nil repeats:NO]; +} + + +- (void) unhighliteClearTimerFireMethod:(NSTimer *)timer +{ + [clear highlight:DOWN]; +} + + +#pragma mark Initialization + + +- (void) resetDevice +{ + [[key cell] setTag:KEY_POWER]; + [[knob cell] setTag:DISPLAY_AC]; + [sw setState:UP]; + [halt setState:UP]; + [singstep setState:UP]; + [stateMachine updateState:NO]; + [self update]; +} + + +- (id) init +{ + self = [super init]; + powerKeyPosition = KEY_POWER; + [[key cell] setTag:powerKeyPosition]; + [[knob cell] setTag:DISPLAY_AC]; + [sw setState:UP]; + addressValue = displayValue = -1; + /* dummy assignments to suppress Analyzer warning "never used" for the GUI elements not + accessed by source code; for the sake of completeness, they are connected in Interface Builder */ + addrload = nil; + extdaddrload = nil; + cont = nil; + dep = nil; + exam = nil; + return self; +} + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + powerKeyPosition = [coder decodeIntForKey:CODER_KEY_POWER_KEY]; + [[key cell] setTag:powerKeyPosition]; + [[knob cell] setTag:[coder decodeIntForKey:CODER_KEY_DISPLAY_SELECTOR_KNOB]]; + [sw setState:[coder decodeBoolForKey:CODER_KEY_SW]]; + [halt setState:[coder decodeBoolForKey:CODER_KEY_HALT]]; + [singstep setState:DOWN]; // to cause the HALT cell update shaddow to be called + [singstep setState:[coder decodeBoolForKey:CODER_KEY_SINGSTEP]]; + [pdp8 setHalt:[key tag] == KEY_PANEL_LOCK ? NO : ([halt state] == DOWN || [singstep state] == DOWN)]; + addressValue = displayValue = -1; + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + [coder encodeInt:powerKeyPosition forKey:CODER_KEY_POWER_KEY]; + [coder encodeInt:[knob tag] forKey:CODER_KEY_DISPLAY_SELECTOR_KNOB]; + [coder encodeBool:[sw state] forKey:CODER_KEY_SW]; + [coder encodeBool:[halt state] forKey:CODER_KEY_HALT]; + [coder encodeBool:[singstep state] forKey:CODER_KEY_SINGSTEP]; +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"KC8EA notifyApplicationWillTerminate"); + NSMutableData *data = [NSMutableData data]; + NSKeyedArchiver *archiver = [[NSKeyedArchiver alloc] initForWritingWithMutableData:data]; + [self encodeWithCoder:archiver]; + [stateMachine encodeWithCoder:archiver]; + [archiver finishEncoding]; + [archiver release]; + [[NSUserDefaults standardUserDefaults] setObject:data forKey:[self pluginName]]; +} + + +- (void) notifyPluginsLoaded:(NSNotification *)notification +{ + [self notifySRChanged:nil]; + [self swClicked:sw]; + [self notifyUpdateDisplay:nil]; + [window orderBackFromDefaults:self]; +} + + +- (void) pluginDidLoad +{ + NSData *data = [[NSUserDefaults standardUserDefaults] dataForKey:[self pluginName]]; + if (data) { + NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data]; + self = [self initWithCoder:unarchiver]; + stateMachine = [[StateMachine alloc] initWithCoder:unarchiver pdp8:pdp8]; + [unarchiver finishDecoding]; + [unarchiver release]; + } else { + self = [self init]; + stateMachine = [[StateMachine alloc] initWithPDP8:pdp8]; + } + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + [defaultCenter addObserver:self selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyPluginsLoaded:) + name:PLUGINS_LOADED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyGo:) name:PDP8_GO_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyStop:) name:PDP8_STOP_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyStep:) name:PDP8_STEP_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyTrace:) name:PDP8_TRACE_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifySRChanged:) name:SR_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:MEMORY_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:PROGRAM_COUNTER_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:ACCUMULATOR_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:SC_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:GTF_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:MQ_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:EAE_MODE_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:DF_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:UF_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:UB_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:SF_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:ENABLE_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:DELAY_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:INHIBIT_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPDP8Changed:) name:IOFLAGS_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyUpdateDisplay:) name:KC8EA_UPDATE_DISPLAY_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyClearAllFlags:) name:CLEAR_ALL_FLAGS_NOTIFICATION object:nil]; + [(BackgroundView *) [window contentView] setBackgroundImage:@"background" ofType:@"png"]; +} + + +@end diff --git a/KC8EA/KnobCell.h b/KC8EA/KnobCell.h new file mode 100644 index 0000000..ea92472 --- /dev/null +++ b/KC8EA/KnobCell.h @@ -0,0 +1,38 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * KnobCell.h - NSButtonCell subclass for the console turning switches + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +// alternate title of the control is the prefix for the images of the knob +// the tag of the cell is the number of positions / images of the knob +// when this number is negative, the knob is operated horizontally, otherwise upright +// the control tag always contains the current knob position +// use [[control cell] setTag:x] to set the tag (i. e. position) of the knob and update the image + + +@interface KnobCell : NSButtonCell +{ +@private + NSMutableArray *images; +} + +@end diff --git a/KC8EA/KnobCell.m b/KC8EA/KnobCell.m new file mode 100644 index 0000000..d9ca5e2 --- /dev/null +++ b/KC8EA/KnobCell.m @@ -0,0 +1,119 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * KnobCell.m - NSButtonCell subclass for the console turning switches + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "KnobCell.h" + + +@implementation KnobCell + + +- (void) awakeFromNib +{ + int i; + + NSString *imageNamePrefix = [self alternateTitle]; + [(NSButton *)[self controlView] setAlternateTitle:nil]; + int numberOfImages = [self tag]; + if (numberOfImages < 0) + numberOfImages = -numberOfImages; + images = [[NSMutableArray alloc] initWithCapacity:numberOfImages]; + for (i = 0; i < numberOfImages; i++) { + [images insertObject:[[[NSImage alloc] initByReferencingFile: + [[NSBundle bundleForClass:[self class]] + pathForResource:[imageNamePrefix stringByAppendingFormat:@"%d", i] + ofType:@"png"]] autorelease] + atIndex:i]; + } +} + + +- (void) setTag:(int)tag +// correctly, we would have to overwrite [NSButton setTag], but to avoid subclassing NSButton, +// we use the cell method to set the buttons tag and image +{ + NSButton *button = (NSButton *)[self controlView]; + [button setTag:tag]; + [button setImage:[images objectAtIndex:tag]]; + [button setAlternateImage:[images objectAtIndex:tag]]; +} + + +- (void) performClick:(id)sender +{ + // called by the key equivalents + int newsegment = ([sender tag] + 1) % [images count]; + [sender setImage:[images objectAtIndex:newsegment]]; + [sender setAlternateImage:[images objectAtIndex:newsegment]]; + [sender setTag:newsegment]; + [[self target] performSelector:[self action] withObject:sender]; + [[self controlView] setNeedsDisplay:YES]; // to show keyboad operation via space key with Tiger +} + + + +- (BOOL) startTrackingAt:(NSPoint)startPoint inView:(NSView *)controlView +{ + return YES; +} + + +- (void) trackAt:(NSPoint)currentPoint inView:(NSButton *)control sendAction:(BOOL)sendAction +{ + int segments = [self tag]; + NSSize size = [control bounds].size; + float length = size.height; + float pos = currentPoint.y; + if (segments < 0) { + segments = -segments; + length = size.width; + pos = currentPoint.x; + } + int newsegment = pos / length * segments; + if (newsegment != [control tag]) { + [control setImage:[images objectAtIndex:newsegment]]; + [control setAlternateImage:[images objectAtIndex:newsegment]]; + [control setTag:newsegment]; + if (sendAction) + [[self target] performSelector:[self action] withObject:control]; + } +} + + +- (BOOL) continueTracking:(NSPoint)lastPoint at:(NSPoint)currentPoint inView:(NSButton *)control +{ + [self trackAt:currentPoint inView:control sendAction:YES]; + return YES; +} + + +- (void) stopTracking:(NSPoint)lastPoint at:(NSPoint)stopPoint inView:(NSButton *)control mouseIsUp:(BOOL)up +{ + if (up) + [self trackAt:stopPoint inView:control sendAction:NO]; +} + + +@end diff --git a/KC8EA/StateMachine.h b/KC8EA/StateMachine.h new file mode 100644 index 0000000..55cc466 --- /dev/null +++ b/KC8EA/StateMachine.h @@ -0,0 +1,61 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * StateMachine.h - State Machine for the KC8-EA Programmer’s Console + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class PDP8; + + +@interface StateMachine : NSObject { +@private + PDP8 *pdp8; + unsigned short cycle; + unsigned short md; + unsigned short mdDir; + unsigned short ir; + unsigned short cpma; + unsigned short bus; + BOOL pause; + unsigned short autoindex; + BOOL interruptInProgress; + unsigned short oldpc; + unsigned short oldinst; +} + +- (StateMachine *) initWithPDP8:(PDP8 *)p8; +- (StateMachine *) initWithCoder:(NSCoder *)coder pdp8:(PDP8 *)p8; + +- (unsigned short) state:(BOOL)sw; +- (unsigned short) status; +- (unsigned short) md; +- (unsigned short) bus; +- (unsigned short) cpma; + +- (BOOL) isInFetchCycle; +- (void) loadAddress; +- (void) loadExtendedAddress; +- (void) updateState:(BOOL)exitFromGo; +- (void) executeSingleCycle; +- (void) examine; +- (void) deposit; + +@end diff --git a/KC8EA/StateMachine.m b/KC8EA/StateMachine.m new file mode 100644 index 0000000..a56f9a2 --- /dev/null +++ b/KC8EA/StateMachine.m @@ -0,0 +1,415 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * StateMachine.c - State Machine for the KC8-EA Programmer’s Console + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/PDP8.h" +#import "PluginFramework/Utilities.h" + +#import "StateMachine.h" + + +// these bits are in the positions of the "state" display +#define FETCH 04000 +#define DEFER 02000 +#define EXECUTE 01000 +#define NO_CYCLE 00000 + +// opcodes in the instruction register +#define IR_AND 00000 +#define IR_TAD 00100 +#define IR_ISZ 00200 +#define IR_DCA 00300 +#define IR_JMS 00400 +#define IR_JMP 00500 +#define IR_IOT 00600 +#define IR_OPR 00700 + +// values for mdDir: to or from memory +#define MB_TO_MEM 00000 +#define MB_FROM_MEM 00040 + +// coder keys +#define CODER_KEY_CYCLE @"cycle" +#define CODER_KEY_MD @"md" +#define CODER_KEY_MDDIR @"mdDir" +#define CODER_KEY_IR @"ir" +#define CODER_KEY_CPMA @"cpma" +#define CODER_KEY_BUS @"bus" +#define CODER_KEY_PAUSE @"pause" +#define CODER_KEY_AUTOINDEX @"autoindex" +#define CODER_KEY_INTERRUPT_IN_PROGRESS @"interruptInProgress" +#define CODER_KEY_OLDPC @"oldpc" +#define CODER_KEY_OLDINST @"oldinst" + + +@implementation StateMachine + + +- (StateMachine *) initWithPDP8:(PDP8 *)p8 +{ + self = [super init]; + pdp8 = p8; + [self updateState:NO]; + return self; +} + + +- (StateMachine *) initWithCoder:(NSCoder *)coder pdp8:(PDP8 *)p8 +{ + self = [self initWithCoder:coder]; + pdp8 = p8; + [self updateState:NO]; + return self; +} + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + cycle = [coder decodeIntForKey:CODER_KEY_CYCLE]; + md = [coder decodeIntForKey:CODER_KEY_MD]; + mdDir = [coder decodeIntForKey:CODER_KEY_MDDIR]; + ir = [coder decodeIntForKey:CODER_KEY_IR]; + cpma = [coder decodeIntForKey:CODER_KEY_CPMA]; + bus = [coder decodeIntForKey:CODER_KEY_BUS]; + pause = [coder decodeBoolForKey:CODER_KEY_PAUSE]; + autoindex = [coder decodeIntForKey:CODER_KEY_AUTOINDEX]; + interruptInProgress = [coder decodeBoolForKey:CODER_KEY_INTERRUPT_IN_PROGRESS]; + oldpc = [coder decodeIntForKey:CODER_KEY_OLDPC]; + oldinst = [coder decodeIntForKey:CODER_KEY_OLDINST]; + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + [coder encodeInt:cycle forKey:CODER_KEY_CYCLE]; + [coder encodeInt:md forKey:CODER_KEY_MD]; + [coder encodeInt:mdDir forKey:CODER_KEY_MDDIR]; + [coder encodeInt:ir forKey:CODER_KEY_IR]; + [coder encodeInt:cpma forKey:CODER_KEY_CPMA]; + [coder encodeInt:bus forKey:CODER_KEY_BUS]; + [coder encodeBool:pause forKey:CODER_KEY_PAUSE]; + [coder encodeInt:autoindex forKey:CODER_KEY_AUTOINDEX]; + [coder encodeBool:interruptInProgress forKey:CODER_KEY_INTERRUPT_IN_PROGRESS]; + [coder encodeInt:oldpc forKey:CODER_KEY_OLDPC]; + [coder encodeInt:oldinst forKey:CODER_KEY_OLDINST]; +} + + +- (unsigned short) state:(BOOL)sw +{ + return cycle | ir | mdDir | (sw ? 00010 : 0) | (pause ? 00004 : 0); +} + + +- (unsigned short) status +{ + return ([pdp8 getL] ? 04000 : 0) // Link + | ([pdp8 getGTF] ? 02000 : 0) // Greater Than Flag + | ([pdp8 interruptRequest] ? 01000 : 0) // Interrupt Request + | ([pdp8 getInhibit] || [pdp8 getDelay] ? 00400 : 0) // NO INT + | ([pdp8 getEnable] ? 00200 : 0) // Interrupt On + | (interruptInProgress ? 0 : [pdp8 getUF] ? 00100 : 0) // User Flag + | ([pdp8 getIF] << 3) // Instruction Field + | [pdp8 getDF]; // Data Field +} + + +- (unsigned short) md +{ + return md; +} + + +- (unsigned short) bus +{ + return bus; +} + + +- (unsigned short) cpma +{ + return cpma; +} + + +- (BOOL) isInFetchCycle +{ + return cycle == FETCH; +} + + +- (void) loadAddress +{ + if ([pdp8 isStopped]) { + cpma = ([pdp8 getIF] << 12) | [pdp8 getSR]; + bus = [pdp8 getSR]; + [pdp8 setPC:bus]; + cycle = FETCH; + } +} + + +- (void) loadExtendedAddress +{ + if ([pdp8 isStopped]) { + bus = [pdp8 getSR]; + [pdp8 loadExtendedAddress]; + } +} + + +- (void) setDatabus +{ + bus = [pdp8 getAC]; + if ((md & 07200) == 07200) // 7200 == CLA at seq. 1 + bus = 0; + if ((md & 07501) == 07501) // 7501 == MQA at seq. 2 + bus |= [pdp8 getMQ]; + if ((md & 07404) == 07404) // 7404 == OSR at seq. 3 + bus |= [pdp8 getSR]; + /* the bus setting may be wrong for group 3 OPRs implemented by the EAE */ +} + + +- (void) updateState:(BOOL)exitFromGo +{ + autoindex = -1; + if ([pdp8 isStopped]) { + if ([pdp8 getProgramCounter] != oldpc || [pdp8 memoryAt:oldpc] != oldinst) { + oldpc = cpma = [pdp8 getProgramCounter]; + oldinst = [pdp8 memoryAt:oldpc]; + cycle = FETCH; + if (exitFromGo) { + ir = ([pdp8 getCurrentOpcode] & 07000) >> 3; + mdDir = MB_FROM_MEM; + md = [pdp8 getCurrentOpcode]; + [self setDatabus]; + } + } + } else { + /* set state at the end of the next instructions fetch cycle, + before the instruction is executed */ + bus = [pdp8 getAC]; + if ([pdp8 getEnable] && [pdp8 interruptRequest] && + ! ([pdp8 getDelay] || [pdp8 getInhibit])) { /* interrupt */ + cpma = 0; + ir = IR_JMS; + cycle = EXECUTE; + } else { /* normal instruction fetch */ + md = [pdp8 memoryAt:[pdp8 getProgramCounter]]; + mdDir = MB_FROM_MEM; + ir = (md & 07000) >> 3; + cpma = ([pdp8 getIF] << 12) | + ((md & 00200) ? (cpma & 07600) : 0) | (md & 0177); + if (ir <= IR_JMP && (md & 00400)) /* indirect MRI */ + cycle = DEFER; + else if (ir < IR_JMP) /* direct MRI != JMP */ + cycle = EXECUTE; + else { /* OPR, IOT or direct JMP */ + cycle = FETCH; + if (ir == IR_JMP) + cpma = ([pdp8 getIB] << 12) | (cpma & 07777); + else { + cpma = ([pdp8 getIF] << 12) | (([pdp8 getPC] + 1) & 07777); + [self setDatabus]; + if (ir == IR_IOT) + pause = YES; + } + } + } + } +} + + +- (void) eaeExecute +/* check for memory cycles of EAE operate instructions */ +{ + switch (md) { + case 07403 : /* SCL */ + if ([pdp8 getEAEmode] == EAE_MODE_A) { + cpma = ([pdp8 getIF] << 12) | (([pdp8 getPC] + 1) & 07777); + md = [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + } + break; + case 07405 : /* MUY */ + case 07407 : /* DVI */ + cpma = ([pdp8 getIF] << 12) | (([pdp8 getPC] + 1) & 07777); + md = [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + if ([pdp8 getEAEmode] == EAE_MODE_B) { + if ((cpma & 07770) == 010) { + autoindex = cpma; + md = (md + 1) & 07777; + mdDir = MB_TO_MEM; + } + cpma = ([pdp8 getDF] << 12) | md; + md = (cpma == autoindex) ? ([pdp8 memoryAt:cpma] + 1) & 07777 : [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + } + break; + case 07413 : /* SHL */ + case 07415 : /* ASR */ + case 07417 : /* LSR */ + cpma = ([pdp8 getIF] << 12) | (([pdp8 getPC] + 1) & 07777); + md = [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + break; + case 07443 : /* DAD */ + if ([pdp8 getEAEmode] == EAE_MODE_B) { + cpma = ([pdp8 getIF] << 12) | (([pdp8 getPC] + 1) & 07777); + md = [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + if ((cpma & 07770) == 010) { + autoindex = cpma; + md = (md + 1) & 07777; + mdDir = MB_TO_MEM; + } + cpma = ([pdp8 getDF] << 12) | ((md + 1) & 07777); + md = (cpma == autoindex) ? ([pdp8 memoryAt:cpma] + 1) & 07777 : [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + } + break; + case 07445 : /* DST */ + if ([pdp8 getEAEmode] == EAE_MODE_B) { + cpma = ([pdp8 getIF] << 12) | (([pdp8 getPC] + 1) & 07777); + md = [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + if ((cpma & 07770) == 010) { + autoindex = cpma; + md = (md + 1) & 07777; + mdDir = MB_TO_MEM; + } + cpma = ([pdp8 getDF] << 12) | ((md + 1) & 07777); + md = [pdp8 getAC]; + mdDir = MB_TO_MEM; + } + break; + } +} + + +- (void) executeSingleCycle +{ + switch (cycle) { + case FETCH : + autoindex = -1; + bus = [pdp8 getAC]; + if ([pdp8 getEnable] && ! ([pdp8 getDelay] || [pdp8 getInhibit]) && [pdp8 interruptRequest]) { + interruptInProgress = YES; /* interrupt */ + cpma = 0; + ir = IR_JMS; + cycle = EXECUTE; + } else { /* normal instruction fetch */ + cpma = [pdp8 getProgramCounter]; + md = [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + ir = (md & 07000) >> 3; + cpma = ([pdp8 getIF] << 12) | + ((md & 0200) ? (cpma & 07600) : 0) | (md & 0177); + if (ir <= IR_JMP && (md & 0400)) + cycle = DEFER; + else if (ir < IR_JMP) + cycle = EXECUTE; + else { + [self setDatabus]; + [self eaeExecute]; + if (ir == IR_IOT) { + bus = [pdp8 getAC]; + pause = YES; + } + [pdp8 step]; + } + } + break; + case DEFER : + if ((cpma & 07770) == 00010) { /* autoindex */ + autoindex = cpma; + md = ([pdp8 memoryAt:cpma] + 1) & 07777; + mdDir = MB_TO_MEM; /* incremented value is written back */ + } else { + md = [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + } + cpma = ([pdp8 getDF] << 12) | md; + cycle = EXECUTE; + break; + case EXECUTE : + switch (ir) { + case IR_AND : + md = (cpma == autoindex) ? ([pdp8 memoryAt:cpma] + 1) & 07777 : [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + break; + case IR_TAD : + md = (cpma == autoindex) ? ([pdp8 memoryAt:cpma] + 1) & 07777 : [pdp8 memoryAt:cpma]; + mdDir = MB_FROM_MEM; + break; + case IR_ISZ : + md = (cpma == autoindex) ? ([pdp8 memoryAt:cpma] + 1) & 07777 : [pdp8 memoryAt:cpma]; + md = (md + 1) & 07777; + mdDir = MB_TO_MEM; + break; + case IR_DCA : + bus = md = [pdp8 getAC]; + mdDir = MB_TO_MEM; + break; + case IR_JMS : + md = ([pdp8 getPC] + (interruptInProgress ? 0 : 1)) & 07777; + mdDir = MB_TO_MEM; + break; + case IR_JMP : + break; + } + interruptInProgress = NO; + cycle = FETCH; + [pdp8 step]; + break; + } +} + + +- (void) examine +{ + md = [pdp8 memoryAt:cpma]; + [pdp8 setPC:([pdp8 getPC] + 1) & 07777]; + cpma = [pdp8 getProgramCounter]; +} + + +- (void) deposit +{ + cpma = [pdp8 getProgramCounter]; + md = bus = [pdp8 getSR]; + if ([pdp8 memorySize] > cpma) + [pdp8 setMemoryAtAddress:cpma toValue:md]; + mdDir = MB_TO_MEM; + [pdp8 setPC:([pdp8 getPC] + 1) & 07777]; + cpma = [pdp8 getProgramCounter]; +} + + +@end diff --git a/KC8EA/addrload_down.png b/KC8EA/addrload_down.png new file mode 100644 index 0000000..5f37bb7 Binary files /dev/null and b/KC8EA/addrload_down.png differ diff --git a/KC8EA/addrload_up_extdaddrload_down.png b/KC8EA/addrload_up_extdaddrload_down.png new file mode 100644 index 0000000..00d61fc Binary files /dev/null and b/KC8EA/addrload_up_extdaddrload_down.png differ diff --git a/KC8EA/addrload_up_extdaddrload_up.png b/KC8EA/addrload_up_extdaddrload_up.png new file mode 100644 index 0000000..ccf72fb Binary files /dev/null and b/KC8EA/addrload_up_extdaddrload_up.png differ diff --git a/KC8EA/background.png b/KC8EA/background.png new file mode 100644 index 0000000..94e90f3 Binary files /dev/null and b/KC8EA/background.png differ diff --git a/KC8EA/clear_down.png b/KC8EA/clear_down.png new file mode 100644 index 0000000..4a7afa2 Binary files /dev/null and b/KC8EA/clear_down.png differ diff --git a/KC8EA/clear_up_cont_down.png b/KC8EA/clear_up_cont_down.png new file mode 100644 index 0000000..4a95b80 Binary files /dev/null and b/KC8EA/clear_up_cont_down.png differ diff --git a/KC8EA/clear_up_cont_up.png b/KC8EA/clear_up_cont_up.png new file mode 100644 index 0000000..d4fb0fc Binary files /dev/null and b/KC8EA/clear_up_cont_up.png differ diff --git a/KC8EA/cont_down.png b/KC8EA/cont_down.png new file mode 100644 index 0000000..a2cb4e0 Binary files /dev/null and b/KC8EA/cont_down.png differ diff --git a/KC8EA/cont_up_exam_down.png b/KC8EA/cont_up_exam_down.png new file mode 100644 index 0000000..ba03ce9 Binary files /dev/null and b/KC8EA/cont_up_exam_down.png differ diff --git a/KC8EA/cont_up_exam_up.png b/KC8EA/cont_up_exam_up.png new file mode 100644 index 0000000..d4671f3 Binary files /dev/null and b/KC8EA/cont_up_exam_up.png differ diff --git a/KC8EA/dep_down.png b/KC8EA/dep_down.png new file mode 100644 index 0000000..c4e199c Binary files /dev/null and b/KC8EA/dep_down.png differ diff --git a/KC8EA/dep_up.png b/KC8EA/dep_up.png new file mode 100644 index 0000000..cf715c0 Binary files /dev/null and b/KC8EA/dep_up.png differ diff --git a/KC8EA/exam_down.png b/KC8EA/exam_down.png new file mode 100644 index 0000000..ecbd416 Binary files /dev/null and b/KC8EA/exam_down.png differ diff --git a/KC8EA/exam_up_halt_down.png b/KC8EA/exam_up_halt_down.png new file mode 100644 index 0000000..c734416 Binary files /dev/null and b/KC8EA/exam_up_halt_down.png differ diff --git a/KC8EA/exam_up_halt_up.png b/KC8EA/exam_up_halt_up.png new file mode 100644 index 0000000..d7afe40 Binary files /dev/null and b/KC8EA/exam_up_halt_up.png differ diff --git a/KC8EA/extdaddrload_down.png b/KC8EA/extdaddrload_down.png new file mode 100644 index 0000000..3f327c3 Binary files /dev/null and b/KC8EA/extdaddrload_down.png differ diff --git a/KC8EA/extdaddrload_up.png b/KC8EA/extdaddrload_up.png new file mode 100644 index 0000000..d7f4ce8 Binary files /dev/null and b/KC8EA/extdaddrload_up.png differ diff --git a/KC8EA/halt_down.png b/KC8EA/halt_down.png new file mode 100644 index 0000000..5828f33 Binary files /dev/null and b/KC8EA/halt_down.png differ diff --git a/KC8EA/halt_up_singstep_down.png b/KC8EA/halt_up_singstep_down.png new file mode 100644 index 0000000..1ef7501 Binary files /dev/null and b/KC8EA/halt_up_singstep_down.png differ diff --git a/KC8EA/halt_up_singstep_up.png b/KC8EA/halt_up_singstep_up.png new file mode 100644 index 0000000..384c9fa Binary files /dev/null and b/KC8EA/halt_up_singstep_up.png differ diff --git a/KC8EA/key0.png b/KC8EA/key0.png new file mode 100644 index 0000000..174f357 Binary files /dev/null and b/KC8EA/key0.png differ diff --git a/KC8EA/key1.png b/KC8EA/key1.png new file mode 100644 index 0000000..3c69bf6 Binary files /dev/null and b/KC8EA/key1.png differ diff --git a/KC8EA/key2.png b/KC8EA/key2.png new file mode 100644 index 0000000..c281d29 Binary files /dev/null and b/KC8EA/key2.png differ diff --git a/KC8EA/knob0.png b/KC8EA/knob0.png new file mode 100644 index 0000000..72e6329 Binary files /dev/null and b/KC8EA/knob0.png differ diff --git a/KC8EA/knob1.png b/KC8EA/knob1.png new file mode 100644 index 0000000..9042d17 Binary files /dev/null and b/KC8EA/knob1.png differ diff --git a/KC8EA/knob2.png b/KC8EA/knob2.png new file mode 100644 index 0000000..15ba272 Binary files /dev/null and b/KC8EA/knob2.png differ diff --git a/KC8EA/knob3.png b/KC8EA/knob3.png new file mode 100644 index 0000000..120e7ac Binary files /dev/null and b/KC8EA/knob3.png differ diff --git a/KC8EA/knob4.png b/KC8EA/knob4.png new file mode 100644 index 0000000..ac2d772 Binary files /dev/null and b/KC8EA/knob4.png differ diff --git a/KC8EA/knob5.png b/KC8EA/knob5.png new file mode 100644 index 0000000..94270ac Binary files /dev/null and b/KC8EA/knob5.png differ diff --git a/KC8EA/light_off.png b/KC8EA/light_off.png new file mode 100644 index 0000000..e7c4a59 Binary files /dev/null and b/KC8EA/light_off.png differ diff --git a/KC8EA/light_on.png b/KC8EA/light_on.png new file mode 100644 index 0000000..fc5348e Binary files /dev/null and b/KC8EA/light_on.png differ diff --git a/KC8EA/singstep_down.png b/KC8EA/singstep_down.png new file mode 100644 index 0000000..14e9d62 Binary files /dev/null and b/KC8EA/singstep_down.png differ diff --git a/KC8EA/singstep_up.png b/KC8EA/singstep_up.png new file mode 100644 index 0000000..ad09fb4 Binary files /dev/null and b/KC8EA/singstep_up.png differ diff --git a/KC8EA/sr0down.png b/KC8EA/sr0down.png new file mode 100644 index 0000000..27ef5a5 Binary files /dev/null and b/KC8EA/sr0down.png differ diff --git a/KC8EA/sr0up_sr1down.png b/KC8EA/sr0up_sr1down.png new file mode 100644 index 0000000..e329c86 Binary files /dev/null and b/KC8EA/sr0up_sr1down.png differ diff --git a/KC8EA/sr0up_sr1up.png b/KC8EA/sr0up_sr1up.png new file mode 100644 index 0000000..eece5b8 Binary files /dev/null and b/KC8EA/sr0up_sr1up.png differ diff --git a/KC8EA/sr10down.png b/KC8EA/sr10down.png new file mode 100644 index 0000000..3a0c3c9 Binary files /dev/null and b/KC8EA/sr10down.png differ diff --git a/KC8EA/sr10up_sr11down.png b/KC8EA/sr10up_sr11down.png new file mode 100644 index 0000000..9ae903e Binary files /dev/null and b/KC8EA/sr10up_sr11down.png differ diff --git a/KC8EA/sr10up_sr11up.png b/KC8EA/sr10up_sr11up.png new file mode 100644 index 0000000..dfed9e3 Binary files /dev/null and b/KC8EA/sr10up_sr11up.png differ diff --git a/KC8EA/sr11down.png b/KC8EA/sr11down.png new file mode 100644 index 0000000..12264bd Binary files /dev/null and b/KC8EA/sr11down.png differ diff --git a/KC8EA/sr11up.png b/KC8EA/sr11up.png new file mode 100644 index 0000000..d6a335b Binary files /dev/null and b/KC8EA/sr11up.png differ diff --git a/KC8EA/sr1down.png b/KC8EA/sr1down.png new file mode 100644 index 0000000..3935bbf Binary files /dev/null and b/KC8EA/sr1down.png differ diff --git a/KC8EA/sr1up_sr2down.png b/KC8EA/sr1up_sr2down.png new file mode 100644 index 0000000..168d525 Binary files /dev/null and b/KC8EA/sr1up_sr2down.png differ diff --git a/KC8EA/sr1up_sr2up.png b/KC8EA/sr1up_sr2up.png new file mode 100644 index 0000000..ddb0276 Binary files /dev/null and b/KC8EA/sr1up_sr2up.png differ diff --git a/KC8EA/sr2down.png b/KC8EA/sr2down.png new file mode 100644 index 0000000..f4b341d Binary files /dev/null and b/KC8EA/sr2down.png differ diff --git a/KC8EA/sr2up_sr3down.png b/KC8EA/sr2up_sr3down.png new file mode 100644 index 0000000..c71106e Binary files /dev/null and b/KC8EA/sr2up_sr3down.png differ diff --git a/KC8EA/sr2up_sr3up.png b/KC8EA/sr2up_sr3up.png new file mode 100644 index 0000000..f964736 Binary files /dev/null and b/KC8EA/sr2up_sr3up.png differ diff --git a/KC8EA/sr3down.png b/KC8EA/sr3down.png new file mode 100644 index 0000000..7ef6d80 Binary files /dev/null and b/KC8EA/sr3down.png differ diff --git a/KC8EA/sr3up_sr4down.png b/KC8EA/sr3up_sr4down.png new file mode 100644 index 0000000..c3f1615 Binary files /dev/null and b/KC8EA/sr3up_sr4down.png differ diff --git a/KC8EA/sr3up_sr4up.png b/KC8EA/sr3up_sr4up.png new file mode 100644 index 0000000..9d4433d Binary files /dev/null and b/KC8EA/sr3up_sr4up.png differ diff --git a/KC8EA/sr4down.png b/KC8EA/sr4down.png new file mode 100644 index 0000000..856a3ab Binary files /dev/null and b/KC8EA/sr4down.png differ diff --git a/KC8EA/sr4up_sr5down.png b/KC8EA/sr4up_sr5down.png new file mode 100644 index 0000000..99b2ff3 Binary files /dev/null and b/KC8EA/sr4up_sr5down.png differ diff --git a/KC8EA/sr4up_sr5up.png b/KC8EA/sr4up_sr5up.png new file mode 100644 index 0000000..f111177 Binary files /dev/null and b/KC8EA/sr4up_sr5up.png differ diff --git a/KC8EA/sr5down.png b/KC8EA/sr5down.png new file mode 100644 index 0000000..1337e9a Binary files /dev/null and b/KC8EA/sr5down.png differ diff --git a/KC8EA/sr5up_sr6down.png b/KC8EA/sr5up_sr6down.png new file mode 100644 index 0000000..4ce8ecc Binary files /dev/null and b/KC8EA/sr5up_sr6down.png differ diff --git a/KC8EA/sr5up_sr6up.png b/KC8EA/sr5up_sr6up.png new file mode 100644 index 0000000..89d22c5 Binary files /dev/null and b/KC8EA/sr5up_sr6up.png differ diff --git a/KC8EA/sr6down.png b/KC8EA/sr6down.png new file mode 100644 index 0000000..d3b6388 Binary files /dev/null and b/KC8EA/sr6down.png differ diff --git a/KC8EA/sr6up_sr7down.png b/KC8EA/sr6up_sr7down.png new file mode 100644 index 0000000..c580125 Binary files /dev/null and b/KC8EA/sr6up_sr7down.png differ diff --git a/KC8EA/sr6up_sr7up.png b/KC8EA/sr6up_sr7up.png new file mode 100644 index 0000000..ebeb3a6 Binary files /dev/null and b/KC8EA/sr6up_sr7up.png differ diff --git a/KC8EA/sr7down.png b/KC8EA/sr7down.png new file mode 100644 index 0000000..973c5be Binary files /dev/null and b/KC8EA/sr7down.png differ diff --git a/KC8EA/sr7up_sr8down.png b/KC8EA/sr7up_sr8down.png new file mode 100644 index 0000000..e4ce947 Binary files /dev/null and b/KC8EA/sr7up_sr8down.png differ diff --git a/KC8EA/sr7up_sr8up.png b/KC8EA/sr7up_sr8up.png new file mode 100644 index 0000000..47e0706 Binary files /dev/null and b/KC8EA/sr7up_sr8up.png differ diff --git a/KC8EA/sr8down.png b/KC8EA/sr8down.png new file mode 100644 index 0000000..11cbd87 Binary files /dev/null and b/KC8EA/sr8down.png differ diff --git a/KC8EA/sr8up_sr9down.png b/KC8EA/sr8up_sr9down.png new file mode 100644 index 0000000..c975320 Binary files /dev/null and b/KC8EA/sr8up_sr9down.png differ diff --git a/KC8EA/sr8up_sr9up.png b/KC8EA/sr8up_sr9up.png new file mode 100644 index 0000000..e7ee059 Binary files /dev/null and b/KC8EA/sr8up_sr9up.png differ diff --git a/KC8EA/sr9down.png b/KC8EA/sr9down.png new file mode 100644 index 0000000..fad61e3 Binary files /dev/null and b/KC8EA/sr9down.png differ diff --git a/KC8EA/sr9up_sr10down.png b/KC8EA/sr9up_sr10down.png new file mode 100644 index 0000000..5659d60 Binary files /dev/null and b/KC8EA/sr9up_sr10down.png differ diff --git a/KC8EA/sr9up_sr10up.png b/KC8EA/sr9up_sr10up.png new file mode 100644 index 0000000..0b364a4 Binary files /dev/null and b/KC8EA/sr9up_sr10up.png differ diff --git a/KC8EA/sw_down.png b/KC8EA/sw_down.png new file mode 100644 index 0000000..81bd2e0 Binary files /dev/null and b/KC8EA/sw_down.png differ diff --git a/KC8EA/sw_up.png b/KC8EA/sw_up.png new file mode 100644 index 0000000..ce4d12d Binary files /dev/null and b/KC8EA/sw_up.png differ diff --git a/Main/MainController.h b/Main/MainController.h new file mode 100644 index 0000000..f362f8c --- /dev/null +++ b/Main/MainController.h @@ -0,0 +1,61 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MainController.h - Main Application Controller Class + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class PDP8, BreakpointArray, PluginManager, KeepInMenuWindow; + + +@interface MainController : NSObject +{ +@private + IBOutlet KeepInMenuWindow *cpuWindow; + IBOutlet NSPanel *preferencesPanel; + IBOutlet NSPanel *breakpointPanel; + IBOutlet NSPanel *bootstrapPanel; + IBOutlet NSDrawer *memoryInspectorDrawer; + IBOutlet NSView *loadPaperTapeFieldView; + IBOutlet NSStepper *loadPaperTapeFieldStepper; + IBOutlet PDP8 *pdp8; + IBOutlet BreakpointArray *breakpoints; + IBOutlet BreakpointArray *breakopcodes; + IBOutlet PluginManager *pluginManager; + BOOL memoryInspectorVisibleBeforeGo; + BOOL breakpointPanelVisibleBeforeGo; + BOOL bootstrapPanelVisibleBeforeGo; +} + +- (IBAction) reset:(id)sender; +- (IBAction) step:(id)sender; +- (IBAction) trace:(id)sender; +- (IBAction) go:(id)sender; +- (IBAction) stop:(id)sender; +- (IBAction) showPreferencesPanel:(id)sender; +- (IBAction) showHideBreakpointPanel:(id)sender; +- (IBAction) showHideBootstrapPanel:(id)sender; +- (IBAction) toggleMemoryInspectorDrawer:(id)sender; +- (IBAction) clearAllFlags:(id)sender; +- (IBAction) loadExtendedAddress:(id)sender; +- (IBAction) loadPaperTape:(id)sender; +- (IBAction) performZoomAll:(id)sender; + +@end diff --git a/Main/MainController.m b/Main/MainController.m new file mode 100644 index 0000000..d32079e --- /dev/null +++ b/Main/MainController.m @@ -0,0 +1,324 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MainController.m - Main Application Controller Class + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import +#import + +#import "MainController.h" +#import "CPUWindowController.h" +#import "PDP8.h" +#import "BreakpointArray.h" +#import "BreakpointController.h" +#import "GeneralPreferences.h" +#import "CPUPreferences.h" +#import "PluginManager.h" +#import "Utilities.h" +#import "KeepInMenuWindow.h" + + +@implementation MainController + + +- (void) notifyStopPDP8:(NSNotification *)notification +{ + if (memoryInspectorVisibleBeforeGo) { + [memoryInspectorDrawer open:self]; + memoryInspectorVisibleBeforeGo = NO; + } + if (breakpointPanelVisibleBeforeGo) { + [breakpointPanel orderBack:self]; + breakpointPanelVisibleBeforeGo = NO; + } + if (bootstrapPanelVisibleBeforeGo) { + [bootstrapPanel orderBack:self]; + bootstrapPanelVisibleBeforeGo = NO; + } +} + + +- (void) notifyPreferencesChanged:(NSNotification *)notification +{ + // NSLog (@"MainController notifyPreferencesChanged"); + NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; + [pdp8 mountEAE:[defaults boolForKey:CPU_PREFS_EAE_KEY]]; + /* The preferences may be inconsistent here because NSUserDefaultsController sends the + notification before the km8eClick: method of CPUPreferences is called. */ + BOOL hasKM8E = [defaults boolForKey:CPU_PREFS_KM8E_KEY]; + unsigned memsize = [defaults integerForKey:CPU_PREFS_MEMORYSIZE_KEY]; + memsize = hasKM8E ? max(memsize, 2 * PDP8_FIELDSIZE) : PDP8_FIELDSIZE; + BOOL hasTimesharing = hasKM8E ? [defaults boolForKey:CPU_PREFS_TIMESHARING_KEY] : NO; + [pdp8 mountKM8E:hasKM8E memorySize:memsize timesharingEnabled:hasTimesharing]; + [pdp8 setTraceSpeed:[defaults floatForKey:GENERAL_PREFS_TRACE_SPEED_KEY]]; + [pdp8 setGoSpeed:[defaults integerForKey:GENERAL_PREFS_GO_SPEED_KEY]]; +} + + +- (void) cancelEditing +{ + /* Cancel editing (in memory table views). Otherwise the [tableview reload] + caused by [pdp8 reset] ends editing normally, and this causes values from + the active input field to be written back to the PDP-8 memory. Send the + cancelOperation: only to NSTextView subclasses to avoid a beep caused by + other responders. */ + NSResponder *firstResponder = [[NSApp keyWindow] firstResponder]; + if ([[firstResponder class] isSubclassOfClass:[NSTextView class]]) + [firstResponder doCommandBySelector:@selector(cancelOperation:)]; +} + + +- (IBAction) reset:(id)sender +{ + NSAlert *alert = [[NSAlert alloc] init]; + + [alert setMessageText:NSLocalizedString(@"Do you really want to reset the PDP-8/E?", @"")]; + [alert setInformativeText:NSLocalizedString( + @"All registers and the memory content will be set to zero. " + @"The preferences and mounted tapes, disks etc. will be preserved. " + @"All breakpoints and break opcodes will be disabled.", @"")]; + [[alert addButtonWithTitle:NSLocalizedString(@"Yes", @"")] setKeyEquivalent:@"\r"]; + [[alert addButtonWithTitle:NSLocalizedString(@"No", @"")] setKeyEquivalent:@"\e"]; + if ([alert runModal] == NSAlertFirstButtonReturn) { + [self cancelEditing]; + [pdp8 reset]; + [breakpoints setAllValues:0]; + [breakopcodes setAllValues:0]; + [pluginManager resetAllDevices]; + } + [alert release]; +} + + +- (IBAction) step:(id)sender +{ + [self cancelEditing]; + [pdp8 step]; +} + + +- (IBAction) trace:(id)sender +{ + [self cancelEditing]; + [pdp8 trace:NO_STOP_ADDRESS]; +} + + +- (IBAction) go:(id)sender +{ + int s = [memoryInspectorDrawer state]; + memoryInspectorVisibleBeforeGo = s == NSDrawerOpenState || s == NSDrawerOpeningState; + breakpointPanelVisibleBeforeGo = [breakpointPanel isVisible]; + bootstrapPanelVisibleBeforeGo = [bootstrapPanel isVisible]; + [breakpointPanel orderOut:self]; + [bootstrapPanel orderOut:self]; + [memoryInspectorDrawer close:self]; + [self cancelEditing]; + [pdp8 go:NO_STOP_ADDRESS]; +} + + +- (IBAction) stop:(id)sender +{ + [pdp8 stop]; +} + + +- (IBAction) showPreferencesPanel:(id)sender +{ + [preferencesPanel makeKeyAndOrderFront:self]; +} + + +- (IBAction) showHideBreakpointPanel:(id)sender +{ + if ([breakpointPanel isVisible]) + [breakpointPanel orderOut:sender]; + else { + [breakpointPanel setBecomesKeyOnlyIfNeeded:YES]; + [breakpointPanel orderFront:sender]; + } +} + + +- (IBAction) showHideBootstrapPanel:(id)sender +{ + if ([bootstrapPanel isVisible]) + [bootstrapPanel orderOut:sender]; + else { + [bootstrapPanel setBecomesKeyOnlyIfNeeded:YES]; + [bootstrapPanel orderFront:sender]; + } +} + + +- (IBAction) toggleMemoryInspectorDrawer:(id)sender +{ + [memoryInspectorDrawer toggle:sender]; +} + + +- (IBAction) loadPaperTape:(id)sender +{ + NSOpenPanel *panel = [NSOpenPanel openPanel]; + [panel setTitle:NSLocalizedString(@"Load a Paper Tape", @"")]; + [panel setPrompt:NSLocalizedString(@"Load", @"")]; + [loadPaperTapeFieldView retain]; + // [loadPaperTapeFieldStepper setIntValue:[pdp8 getIF]]; + int lastField = ([pdp8 memorySize] >> 12) - 1; + [loadPaperTapeFieldStepper setMaxValue:lastField]; + [loadPaperTapeFieldStepper setEnabled:lastField != 0]; + [[loadPaperTapeFieldStepper target] performSelector:[loadPaperTapeFieldStepper action] + withObject:loadPaperTapeFieldStepper]; + [panel setAccessoryView:loadPaperTapeFieldView]; + if ([panel runModalForDirectory: + [[NSUserDefaults standardUserDefaults] stringForKey:LAST_FILE_PANEL_DIR_KEY] + file:nil types:[NSArray arrayWithObjects: + NSFileTypeForHFSTypeCode(0x504e4348l /* 'PNCH' */), + @"BIN", @"bin", @"BN", @"bn", @"RIM", @"rim", @"PT", @"pt", nil]] == NSOKButton) { + [self cancelEditing]; + NSString *error = [pdp8 loadPaperTape:[panel filename] + toField:[loadPaperTapeFieldStepper intValue]]; + if (error) { + NSAlert *alert = [[NSAlert alloc] init]; + [alert setAlertStyle:NSWarningAlertStyle]; + [alert setMessageText:error]; + [alert setInformativeText:[panel filename]]; + [alert runModal]; + [alert release]; + } + } + [[NSUserDefaults standardUserDefaults] setObject:[panel directory] forKey:LAST_FILE_PANEL_DIR_KEY]; +} + + +- (IBAction) clearAllFlags:(id)sender +{ + [self cancelEditing]; + [pdp8 clearAllFlags]; +} + + +- (IBAction) loadExtendedAddress:(id)sender +{ + [self cancelEditing]; + [pdp8 loadExtendedAddress]; +} + + +- (BOOL) validateMenuItem:(NSMenuItem *)menuItem +{ + SEL action = [menuItem action]; + if (action == @selector(stop:)) + return [pdp8 isRunning]; + if (action == @selector(step:) || action == @selector(trace:) || action == @selector(go:)) + return ! [pdp8 isHalted] && [pdp8 isStopped]; + if (action == @selector(reset:) || action == @selector(loadPaperTape:) || + action == @selector(clearAllFlags:) || action == @selector(loadExtendedAddress:)) + return [pdp8 isStopped]; + if (action == @selector(showHideBreakpointPanel:)) { + if ([menuItem respondsToSelector:@selector(setState:)]) + [menuItem setState:[breakpointPanel isVisible]]; + return ! [pdp8 isGoing]; + } + if (action == @selector(showHideBootstrapPanel:)) { + if ([menuItem respondsToSelector:@selector(setState:)]) + [menuItem setState:[bootstrapPanel isVisible]]; + return ! [pdp8 isGoing]; + } + if (action == @selector(toggleMemoryInspectorDrawer:)) { + if ([menuItem respondsToSelector:@selector(setState:)]) { + int s = [memoryInspectorDrawer state]; + [menuItem setState:s == NSDrawerOpenState || s == NSDrawerOpeningState ? + NSOnState : NSOffState]; + } + return [[memoryInspectorDrawer parentWindow] isVisible] && ! [pdp8 isGoing]; + } + if (action == @selector(performZoomAll:)) { // don't know how to archieve this automatically + NSWindow *window; + NSEnumerator *enumerator = [[NSApp windows] objectEnumerator]; + while ((window = [enumerator nextObject])) { + if ([window level] == NSNormalWindowLevel && + [window isZoomable] && [window isVisible]) + return TRUE; + } + return FALSE; + } + return TRUE; +} + + +- (BOOL) validateToolbarItem:(NSToolbarItem *)toolbarItem +{ + return [self validateMenuItem:(NSMenuItem *)toolbarItem]; +} + + +- (void) applicationWillFinishLaunching:(NSNotification *)notification +{ + if (! runningOnTigerOrNewer()) { + NSRunAlertPanel ( + NSLocalizedString( + @"This version of the PDP-8/E Simulator needs Mac OS X 10.4 or better", @""), + NSLocalizedString(@"For older Systems (down to System 2.0.1 on a Mac 512Ke), there " + "is still the old version 1.5 of the PDP-8/E Simulator available.", @""), + NSLocalizedString(@"Quit", @""), nil, nil); + exit (0); + } + LOG_ASSERTING (); +} + + +- (void) applicationDidFinishLaunching:(NSNotification *)notification +{ + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyStopPDP8:) name:PDP8_STOP_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPreferencesChanged:) name:NSUserDefaultsDidChangeNotification + object:nil]; + [self notifyPreferencesChanged:nil]; + [breakpoints loadFromPrefs:@"Breakpoints"]; + [breakopcodes loadFromPrefs:@"BreakOpcodes"]; + [[cpuWindow toolbar] validateVisibleItems]; // revalidate because of the HALT/SINGSTEP console key + [cpuWindow orderFrontFromDefaults:self]; +} + + +- (void) applicationWillTerminate:(NSNotification *)notification +{ + [[NSNotificationCenter defaultCenter] removeObserver:self name:NSUserDefaultsDidChangeNotification + object:nil]; +} + + +- (IBAction) performZoomAll:(id)sender // don't know how to archieve this automatically +{ + NSWindow *window; + NSEnumerator *enumerator = [[NSApp windows] objectEnumerator]; + while ((window = [enumerator nextObject])) { + if ([window level] == NSNormalWindowLevel && [window isZoomable] && [window isVisible]) + [window performZoom:sender]; + } +} + + +@end diff --git a/Main/main.m b/Main/main.m new file mode 100644 index 0000000..19716f8 --- /dev/null +++ b/Main/main.m @@ -0,0 +1,31 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * main.m - The main() routine + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + + +int main (int argc, char *argv[]) +{ + return NSApplicationMain(argc, (const char **) argv); +} diff --git a/MemoryInspector/MemoryInspector6BitASCII.m b/MemoryInspector/MemoryInspector6BitASCII.m new file mode 100644 index 0000000..2e0d801 --- /dev/null +++ b/MemoryInspector/MemoryInspector6BitASCII.m @@ -0,0 +1,164 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspector6BitASCII.m - 6-Bit ASCII Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" +#import "Unicode.h" + + +#define ORDER_IN_MENU 10 +#define WORDS_PER_ROW 4 +#define CONTENT_WIDTH 8 +#define NEEDS_ALIGNMENT NO +#define ALLOWS_EDITING YES +#define MENU_TITLE @"6-Bit ASCII" +#define TOOL_TIP @"This column displays the memory content as 6-bit ASCII. " \ + "When editing a cell, use " UNICODE_MIDDLE_DOT_UTF8 " (option-shift-9) " \ + "to keep the current value and " UNICODE_BULLET_UTF8 \ + " (option-8 on an English keyboard or option-ü on a German keyboard) to force zero." + + +@interface MemoryInspector6BitASCII : NSFormatter +{ +} +@end + + +@implementation MemoryInspector6BitASCII + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + NSMutableString *string = [NSMutableString stringWithCapacity:8]; + int i; + for (i = 0; i < WORDS_PER_ROW; i++) { + unsigned short c1 = [[value objectAtIndex:i] intValue]; + unsigned short c0 = c1 >> 6; + if (c0 == 0) + c0 = UNICODE_MIDDLE_DOT; + else if (c0 < 040) + c0 |= 0100; + c1 &= 077; + if (c1 == 0) + c1 = UNICODE_MIDDLE_DOT; + else if (c1 < 040) + c1 |= 0100; + [string appendFormat:@"%C%C", c0, c1]; + } + return string; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + int i, c0, c1, m0, m1; + + if ([string length] != CONTENT_WIDTH) { + if (error) + *error = NSLocalizedString(@"Exactly eight characters required.", @""); + return FALSE; + } + m1 = c1 = 0; // only to avoid "used uninitialized" compiler warning + NSMutableArray *val = [NSMutableArray arrayWithCapacity:WORDS_PER_ROW]; + for (i = 0; i < CONTENT_WIDTH; i++) { + c0 = [string characterAtIndex:i]; + m0 = 0770000; + if (c0 == UNICODE_MIDDLE_DOT) // don't care, save old value + c0 = m0 = 0; + else if (c0 == UNICODE_BULLET) // force zero + c0 = 0; + else if (040 <= c0 && c0 < 0140) + c0 &= 077; + else { + if (error) + *error = [NSString stringWithFormat:NSLocalizedString( + @"Invalid 6-bit ASCII character %C%C%C.", @""), + UNICODE_LEFT_DOUBLEQUOTE, c0, UNICODE_RIGHT_DOUBLEQUOTE]; + return FALSE; + } + if (i & 1) + [val addObject:[NSNumber numberWithInt:m1 | m0 | c1 | c0]]; + else { + c1 = c0 << 6; + m1 = m0 << 6; + } + } + *value = val; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspector8BitASCII.m b/MemoryInspector/MemoryInspector8BitASCII.m new file mode 100644 index 0000000..a090184 --- /dev/null +++ b/MemoryInspector/MemoryInspector8BitASCII.m @@ -0,0 +1,149 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspector8BitASCII.m - 8-Bit ASCII Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" +#import "Unicode.h" + + +#define ORDER_IN_MENU 20 +#define WORDS_PER_ROW 4 +#define CONTENT_WIDTH 4 +#define NEEDS_ALIGNMENT NO +#define ALLOWS_EDITING YES +#define MENU_TITLE @"8-Bit ASCII" +#define TOOL_TIP @"This column displays the memory content as 8-bit ASCII. " \ + "When editing a cell, use " UNICODE_MIDDLE_DOT_UTF8 " (option-shift-9) " \ + "to keep the current value and " UNICODE_BULLET_UTF8 \ + " (option-8 on an English keyboard or option-ü on a German keyboard) to force zero." + + +@interface MemoryInspector8BitASCII : NSFormatter +{ +} +@end + + +@implementation MemoryInspector8BitASCII + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + NSMutableString *string = [NSMutableString stringWithCapacity:4]; + int i; + for (i = 0; i < WORDS_PER_ROW; i++) { + unsigned short c = [[value objectAtIndex:i] intValue]; + c &= ~0200; // ignore parity bit + if (c < 040 || 0177 <= c) + c = UNICODE_MIDDLE_DOT; + [string appendFormat:@"%C", c]; + } + return string; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + int i, c, m; + + if ([string length] != CONTENT_WIDTH) { + if (error) + *error = NSLocalizedString(@"Exactly four characters required.", @""); + return FALSE; + } + NSMutableArray *val = [NSMutableArray arrayWithCapacity:WORDS_PER_ROW]; + for (i = 0; i < CONTENT_WIDTH; i++) { + c = [string characterAtIndex:i]; + m = 077770000; + if (c == UNICODE_MIDDLE_DOT) // don't care, save old value + c = m = 0; + else if (c == UNICODE_BULLET) // force zero + c = 0; + else if (c & ~0177) { + if (error) + *error = [NSString stringWithFormat:NSLocalizedString( + @"Invalid 8-bit ASCII character %C%C%C.", @""), + UNICODE_LEFT_DOUBLEQUOTE, c, UNICODE_RIGHT_DOUBLEQUOTE]; + return FALSE; + } + [val addObject:[NSNumber numberWithInt:m | c]]; + } + *value = val; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorController.h b/MemoryInspector/MemoryInspectorController.h new file mode 100644 index 0000000..b4561dd --- /dev/null +++ b/MemoryInspector/MemoryInspectorController.h @@ -0,0 +1,51 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorController.h - Controller for the Memory Inspectors Drawer + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class NonWrappingTableView, TableCornerView, PDP8; +@protocol MemoryInspector; + + +@interface MemoryInspectorScrollView : NSScrollView +{ +} +@end + + +@interface MemoryInspectorController : NSObject { +@private + IBOutlet NSDrawer *memoryInspectorDrawer; + IBOutlet NSPopUpButton *popupButton; + IBOutlet NonWrappingTableView *memoryView; + IBOutlet TableCornerView *cornerView; + IBOutlet PDP8 *pdp8; + NSArray *memoryInspectors; + NSFormatter *currentInspector; + unsigned alignment; + unsigned lastTopRow; +} + +- (IBAction) selectMemoryInspector:(id)sender; +- (IBAction) alignMemory:(id)sender; + +@end diff --git a/MemoryInspector/MemoryInspectorController.m b/MemoryInspector/MemoryInspectorController.m new file mode 100644 index 0000000..329c103 --- /dev/null +++ b/MemoryInspector/MemoryInspectorController.m @@ -0,0 +1,448 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorController.m - Controller for the Memory Inspectors Drawer + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import +#import + +#import "MemoryInspectorController.h" +#import "MemoryInspectorProtocol.h" +#import "NonWrappingTableView.h" +#import "NSTableView+Scrolling.h" +#import "TableCornerView.h" +#import "OctalFormatter.h" +#import "Utilities.h" +#import "PDP8.h" + + +#define ADDR_COLUMN 0 +#define OCTAL_COLUMN 1 +#define CONTENT_COLUMN 2 + +#define ADDR_COLUMN_ID @"0" +#define OCTAL_COLUMN_ID @"1" +#define CONTENT_COLUMN_ID @"2" + +#define CURRENT_INSPECTOR_CLASS_PREFS_KEY @"MemInspectorClass" +#define TOP_ROW_PREFS_KEY @"MemInspectorTopRow" +#define ALIGNMENT_PREFS_KEY @"MemInspectorAlign" +#define INSPECTOR_OPEN_PREFS_KEY @"MemInspectorOpen" + + +@implementation NSFormatter (OrderInMemoryInspectorMenu) + + +- (NSComparisonResult) compareOrderInMemoryInspectorMenu:(id )inspector +{ + return [[(id ) self orderInMemoryInspectorMenu] + compare:[inspector orderInMemoryInspectorMenu]]; +} + + +@end + + +@implementation MemoryInspectorScrollView : NSScrollView + + +- (void) setFrame:(NSRect)frameRect +/* Auto resizing of the drawer makes the memory table view overlap the memory format popup + menu when the CPU window shrinks to the title bar (while "go" mode). (Cocoa bug?) + This methods calculates the scroll view height from the drawer height and the initial, + correct height delta between drawer and scroll view height. */ +{ + static float delta = (float) 0.0; + + if (delta == 0.0) { + if ([self window]) + delta = [[self window] frame].size.height - frameRect.size.height; + } else + frameRect.size.height = [[self window] frame].size.height - delta; + [super setFrame:frameRect]; +} + + +@end + + +@implementation MemoryInspectorController + + +- (void) cancelEditingInInspector +{ + NSResponder *first, *next; + + for (first = next = [[NSApp keyWindow] firstResponder]; next; next = [next nextResponder]) { + if (next == [memoryInspectorDrawer contentView] && + [[first class] isSubclassOfClass:[NSTextView class]]) { + [first doCommandBySelector:@selector(cancelOperation:)]; + break; + } + } +} + + +- (NSArray *) allMemoryInspectors +{ + int i; + + int numClasses = 0; + int newNumClasses = objc_getClassList(NULL, 0); + + Class *allClasses = NULL; + while (numClasses < newNumClasses) { + numClasses = newNumClasses; + allClasses = realloc(allClasses, sizeof(Class) * numClasses); + newNumClasses = objc_getClassList(allClasses, numClasses); + } + NSMutableArray *inspectors = [NSMutableArray array]; + for (i = 0; i < numClasses; i++) { + Class currentClass = allClasses[i]; + while (currentClass) { + if (currentClass->super_class == [NSFormatter class] && + [currentClass conformsToProtocol:@protocol(MemoryInspector)]) { + [inspectors addObject:[[[allClasses[i] alloc] init] autorelease]]; + break; + } + currentClass = currentClass->super_class; + } + } + free (allClasses); + [inspectors sortUsingSelector:@selector(compareOrderInMemoryInspectorMenu:)]; + return inspectors; +} + + +- (NSRange) visibleRange +{ + // see also [CPUMemoryViewController updateVisibleMemoryRange] and [NSTableView(Scrolling) scrollRowToTop:] + NSRange range; + range.location = range.length = 0; + NSRect rect = [memoryView visibleRect]; + if (rect.size.height > 0) { // zero immediately after "Stop" when the window is not yet enlarged + if (runningOnElCapitanOrNewer()) + rect.origin.y += [memoryView rectOfRow:0].size.height; + unsigned pixelPerRow = (unsigned) ([memoryView rowHeight] + [memoryView intercellSpacing].height); + range.location = [memoryView rowsInRect:rect].location; + range.length = rect.size.height / pixelPerRow; + } + return range; +} + + +- (IBAction) selectMemoryInspector:(id)sender +{ + NSSize drawerSize; + + // get the new inspector + NSFormatter *newInspector = [memoryInspectors objectAtIndex:[sender indexOfSelectedItem]]; + if ([currentInspector isEqual:newInspector]) + return; + + // stop editing in the old inspector + [self cancelEditingInInspector]; + + NSTableColumn *addrColumn = [memoryView tableColumnWithIdentifier:ADDR_COLUMN_ID]; + NSTableColumn *octalColumn = [memoryView tableColumnWithIdentifier:OCTAL_COLUMN_ID]; + NSTableColumn *contentColumn = [memoryView tableColumnWithIdentifier:CONTENT_COLUMN_ID]; + + // set octal column width + drawerSize.width = [addrColumn width]; + float width = [newInspector wordsPerRow] * 35; + drawerSize.width += width; + [octalColumn setMinWidth:width]; + [octalColumn setMaxWidth:width]; + [octalColumn setWidth:width]; + + // set content column width + width = [newInspector contentWidthInCharacters] * 7 + 4; + drawerSize.width += width; + [contentColumn setMinWidth:width]; + [contentColumn setMaxWidth:width]; + [contentColumn setWidth:width]; + + // resize drawer + drawerSize.width += 42; + drawerSize.height = 0; + [memoryInspectorDrawer setMaxContentSize:drawerSize]; + [memoryInspectorDrawer setMinContentSize:drawerSize]; + [memoryInspectorDrawer setContentSize:drawerSize]; + + // scroll to a reasonable location + int newTopRow = 0; + int newSelectedRow = -1; + if (currentInspector) { + NSRange visibleRange = [self visibleRange]; + int selectedRow = [memoryView selectedRow]; + if (NSLocationInRange(selectedRow, visibleRange)) { + newTopRow = selectedRow * [currentInspector wordsPerRow] / + [newInspector wordsPerRow] - (selectedRow - visibleRange.location); + newSelectedRow = newTopRow + (selectedRow - visibleRange.location); + } else + newTopRow = visibleRange.location * [currentInspector wordsPerRow] / + [newInspector wordsPerRow]; + int lastAddress = (newTopRow + visibleRange.length) * [newInspector wordsPerRow]; + if (lastAddress >= PDP8_MEMSIZE) // don't show white space at the end of the table view + newTopRow -= (lastAddress - PDP8_MEMSIZE) / [newInspector wordsPerRow] + 1; + } + + // switch to the new inspector, set the formatter and reload data + alignment = 0; + currentInspector = newInspector; + [[octalColumn dataCell] setObjectValue:nil]; // remove old value with wrong number of words + [[[octalColumn dataCell] formatter] setNumberOfWords:[currentInspector wordsPerRow]]; + [[contentColumn dataCell] setObjectValue:nil]; // remove old value with wrong number of words + [[contentColumn dataCell] setFormatter:currentInspector]; + [memoryView reloadData]; + + // set selected row + [memoryView scrollRowToTop:newTopRow]; + if (newSelectedRow >= 0) + [memoryView selectRowIndexes:[NSIndexSet indexSetWithIndex:newSelectedRow] + byExtendingSelection:NO]; + else + [memoryView deselectAll:self]; + + // enable or disable corner view for memory alignment + if ([currentInspector needsMemoryAlignment]) { + [cornerView setImageNamed:@"alignMemoryArrow" toolTip: + NSLocalizedString(@"Click or option-click to align multiword formats", @"")]; + [cornerView setClickable:YES]; + } else { + [cornerView setImageNamed:nil toolTip:nil]; + [cornerView setClickable:NO]; + } +} + + +- (IBAction) alignMemory:(id)sender +{ + if ([currentInspector needsMemoryAlignment]) { + [self cancelEditingInInspector]; + int wordsPerRow = [currentInspector wordsPerRow]; + alignment = (alignment + wordsPerRow + + (([[NSApp currentEvent] modifierFlags] & NSAlternateKeyMask) ? -1 : 1)) % wordsPerRow; + [memoryView reloadData]; + } +} + + +- (void) notifyMemoryChanged:(NSNotification *)notification +{ + // NSLog (@"MemoryInspectorController notifyMemoryChanged"); + [memoryView reloadData]; +} + + +- (BOOL) tableView:(NSTableView *)tableView shouldEditTableColumn:(NSTableColumn *)column row:(int)row +{ + return [currentInspector wordsPerRow] * (row + 1) + alignment <= [pdp8 memorySize] + && ([[column identifier] intValue] != CONTENT_COLUMN || [currentInspector allowsEditing]); +} + + +- (int) numberOfRowsInTableView:(NSTableView *)tableView +{ + int wordsPerRow = [currentInspector wordsPerRow]; + return wordsPerRow ? (PDP8_MEMSIZE + wordsPerRow - alignment - 1) / wordsPerRow : 0; +} + + +- (id) tableView:(NSTableView *)tableView objectValueForTableColumn:(NSTableColumn *)column row:(int)row +{ + int i; + NSMutableArray *value; + + int wordsPerRow = [currentInspector wordsPerRow]; + switch ([[column identifier] intValue]) { + case ADDR_COLUMN : + return [NSString stringWithFormat:@"%5.5o", wordsPerRow * row + alignment]; + case OCTAL_COLUMN : + value = [NSMutableArray arrayWithCapacity:wordsPerRow]; + for (i = 0; i < wordsPerRow && wordsPerRow * row + alignment + i < PDP8_MEMSIZE; i++) + [value addObject:[NSNumber numberWithInt: + [pdp8 memoryAt:wordsPerRow * row + alignment + i]]]; + return value; + case CONTENT_COLUMN : + if (wordsPerRow * (row + 1) /* + alignment */ > [pdp8 memorySize]) + return NSLocalizedString(@"n/a", @""); + value = [NSMutableArray arrayWithCapacity:wordsPerRow]; + for (i = 0; i < wordsPerRow; i++) + [value addObject:[NSNumber numberWithInt: + (wordsPerRow * row + alignment + i < PDP8_MEMSIZE) ? + [pdp8 memoryAt:wordsPerRow * row + alignment + i] : 0]]; + return value; + } + return nil; +} + + +- (NSString *) tableView:(NSTableView *)tableView toolTipForCell:(NSCell *)cell + rect:(NSRectPointer)rect tableColumn:(NSTableColumn *)column row:(int)row + mouseLocation:(NSPoint)mouseLocation +{ + switch ([[column identifier] intValue]) { + case ADDR_COLUMN : + return NSLocalizedString(@"This column displays the memory adresses.", @""); + case OCTAL_COLUMN : + return NSLocalizedString(@"This column displays the octal memory content.", @""); + case CONTENT_COLUMN : + return [currentInspector toolTipForContentColumn]; + } + return nil; +} + + +- (void) tableView:(NSTableView *)tableView setObjectValue:(NSArray *)values + forTableColumn:(NSTableColumn *)column row:(int)row +{ + /* value == nil when the user tabs (without editing) over cells with + output strings that are not valid input strings, e. g. "(IEEE overflow)". + In this case, the formatter is called with error == nil, returns the + value nil for the invalid input string, but Cocoa does not call + control:didFailToFormatString:errorDescription: */ + if (values) + [pdp8 setMemoryAtAddress:row * [currentInspector wordsPerRow] + alignment + toValues:values withMask:[[column identifier] intValue] == CONTENT_COLUMN]; +} + + +- (BOOL) control:(NSControl *)control didFailToFormatString:(NSString *)string + errorDescription:(NSString *)error +{ + NSRange range; + range.location = 0; + range.length = -1; + [[control currentEditor] setSelectedRange:range]; + NSAlert *alert = [[NSAlert alloc] init]; + [alert setMessageText:error]; + [alert beginSheetModalForWindow:[memoryInspectorDrawer parentWindow] + modalDelegate:nil didEndSelector:nil contextInfo:nil]; + [alert release]; + return NO; +} + + +- (BOOL) control:(NSControl *)control textView:(NSTextView *)textView doCommandBySelector:(SEL)command +{ + if (command == @selector(cancelOperation:)) { + // ESC aborts editing of the cell + [control abortEditing]; + return YES; + } + return NO; +} + + +#pragma mark Delegate and Notification + + +- (void) drawerWillClose:(NSNotification *)notification +{ + [self cancelEditingInInspector]; + lastTopRow = [self visibleRange].location; +} + + +- (void) scrollDrawerToLastTopRow +{ + [memoryView scrollRowToTop:lastTopRow]; +} + + +- (void) drawerDidOpen:(NSNotification *)notification +{ + // When the PDP-8 runs, the CPU window shrinks to the title bar, so the memory view scrolls to row 0 + // We can't scroll in drawerWillOpen:; even when this method runs, often the CPU window is still shrunk, + // so a direct [memoryView scrollRowToTop:lastTopRow] has no effect, and the memory view stays at location 0. + // So we delay the scrolling via performSelector:, accepting the side effect that the scrolling is visible. + [self performSelector:@selector(scrollDrawerToLastTopRow) withObject:nil afterDelay:0]; +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"MemoryInspectorController notifyApplicationWillTerminate"); + NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; + [defaults setObject:[currentInspector className] forKey:CURRENT_INSPECTOR_CLASS_PREFS_KEY]; + [defaults setObject:[NSNumber numberWithInt:[self visibleRange].location] forKey:TOP_ROW_PREFS_KEY]; + [defaults setObject:[NSNumber numberWithInt:alignment] forKey:ALIGNMENT_PREFS_KEY]; + int s = [memoryInspectorDrawer state]; + [defaults setBool:s == NSDrawerOpenState || s == NSDrawerOpeningState + forKey:INSPECTOR_OPEN_PREFS_KEY]; +} + + +- (void) notifyApplicationDidFinishLaunching:(NSNotification *)notification +/* Look for memory inspector classes at "did finish launching", after plugins have been loaded at + "will finish launching", so we find inspector classes of plugins, too. */ +{ + unsigned i; + + memoryInspectors = [[self allMemoryInspectors] retain]; + [popupButton removeAllItems]; + for (i = 0; i < [memoryInspectors count]; i++) + [popupButton addItemWithTitle:[[memoryInspectors objectAtIndex:i] menuTitle]]; + NSFont *font = [NSFont userFixedPitchFontOfSize:11]; + [[[[memoryView tableColumns] objectAtIndex:ADDR_COLUMN] dataCell] setFont:font]; + [[[[memoryView tableColumns] objectAtIndex:OCTAL_COLUMN] dataCell] setFont:font]; + [[[[memoryView tableColumns] objectAtIndex:CONTENT_COLUMN] dataCell] setFont:font]; + [[[[memoryView tableColumns] objectAtIndex:OCTAL_COLUMN] dataCell] + setFormatter:[OctalFormatter formatterWithBitMask:07777 wildcardAllowed:NO]]; + // restore preferences + NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; + NSString *currentInspectorClass = [defaults stringForKey:CURRENT_INSPECTOR_CLASS_PREFS_KEY]; + alignment = 0; + lastTopRow = 0; + for (i = 0; i < [memoryInspectors count]; i++) { + if ([[[memoryInspectors objectAtIndex:i] className] isEqualToString:currentInspectorClass]) { + [popupButton selectItemAtIndex:i]; + alignment = [defaults integerForKey:ALIGNMENT_PREFS_KEY]; + lastTopRow = [defaults integerForKey:TOP_ROW_PREFS_KEY]; + break; + } + } + [self selectMemoryInspector:popupButton]; + [memoryView scrollRowToTop:lastTopRow]; + if ([[NSUserDefaults standardUserDefaults] boolForKey:INSPECTOR_OPEN_PREFS_KEY] + && [[memoryInspectorDrawer parentWindow] isVisible]) + [memoryInspectorDrawer open]; +} + + +- (void) awakeFromNib +{ + adjustTableHeaderForElCapitan (memoryView); + // set notifications + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationDidFinishLaunching:) + name:NSApplicationDidFinishLaunchingNotification object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(notifyMemoryChanged:) + name:MEMORY_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorDWSignedInteger.m b/MemoryInspector/MemoryInspectorDWSignedInteger.m new file mode 100644 index 0000000..0a7f302 --- /dev/null +++ b/MemoryInspector/MemoryInspectorDWSignedInteger.m @@ -0,0 +1,139 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorDWSignedInteger.m - Double Word Signed Integer Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" + + +#define ORDER_IN_MENU 60 +#define WORDS_PER_ROW 2 +#define CONTENT_WIDTH 8 +#define NEEDS_ALIGNMENT YES +#define ALLOWS_EDITING YES +#define MENU_TITLE @"Double Word Signed Integer" +#define TOOL_TIP @"This column displays the memory content as double word signed integer." + + +@interface MemoryInspectorDWSignedInteger : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorDWSignedInteger + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + int n = [[value objectAtIndex:0] intValue] | ([[value objectAtIndex:1] intValue] << 12); + if (n & 040000000) + n |= ~077777777; + return [NSString stringWithFormat:@"%8d", n]; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + int n; + + NSMutableArray *val = [NSMutableArray arrayWithCapacity:WORDS_PER_ROW]; + NSScanner *scanner = [NSScanner scannerWithString:string]; + if ([scanner scanInt:&n]) { + if ((n & ~037777777) != 0 && (n & ~037777777) != ~037777777) { + if (error) + *error = NSLocalizedString(@"Double word signed integer out of valid " + "range from -8388608 to 8388607.", @""); + return FALSE; + } + [val addObject:[NSNumber numberWithInt:077770000 | (n & 07777)]]; + [val addObject:[NSNumber numberWithInt:077770000 | ((n >> 12) & 07777)]]; + } else { + if (error) + *error = NSLocalizedString(@"Invalid double word signed integer.", @""); + return FALSE; + } + if (! [scanner isAtEnd]) { + if (error) + *error = NSLocalizedString( + @"Exactly one double word signed integer expected.", @""); + return FALSE; + } + *value = val; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorDWUnsignedInteger.m b/MemoryInspector/MemoryInspectorDWUnsignedInteger.m new file mode 100644 index 0000000..250c654 --- /dev/null +++ b/MemoryInspector/MemoryInspectorDWUnsignedInteger.m @@ -0,0 +1,137 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorDWUnsignedInteger.m - Double Word Unsigned Integer Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" + + +#define ORDER_IN_MENU 70 +#define WORDS_PER_ROW 2 +#define CONTENT_WIDTH 8 +#define NEEDS_ALIGNMENT YES +#define ALLOWS_EDITING YES +#define MENU_TITLE @"Double Word Unsigned Integer" +#define TOOL_TIP @"This column displays the memory content as double word unsigned integer." + + +@interface MemoryInspectorDWUnsignedInteger : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorDWUnsignedInteger + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + return [NSString stringWithFormat:@"%8d", + [[value objectAtIndex:0] intValue] | ([[value objectAtIndex:1] intValue] << 12)]; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + int n; + + NSMutableArray *val = [NSMutableArray arrayWithCapacity:WORDS_PER_ROW]; + NSScanner *scanner = [NSScanner scannerWithString:string]; + if ([scanner scanInt:&n]) { + if ((n & ~077777777) != 0) { + if (error) + *error = NSLocalizedString(@"Double word unsigned integer out of valid " + "range from 0 to 16777215.", @""); + return FALSE; + } + [val addObject:[NSNumber numberWithInt:077770000 | (n & 07777)]]; + [val addObject:[NSNumber numberWithInt:077770000 | ((n >> 12) & 07777)]]; + } else { + if (error) + *error = NSLocalizedString(@"Invalid double word unsigned integer.", @""); + return FALSE; + } + if (! [scanner isAtEnd]) { + if (error) + *error = NSLocalizedString( + @"Exactly one double word unsigned integer expected.", @""); + return FALSE; + } + *value = val; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorFPP8AEPFloatingPoint.m b/MemoryInspector/MemoryInspectorFPP8AEPFloatingPoint.m new file mode 100644 index 0000000..f5fd07b --- /dev/null +++ b/MemoryInspector/MemoryInspectorFPP8AEPFloatingPoint.m @@ -0,0 +1,136 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorFPP8AEPFloatingPoint.m - FPP8-A EP Floating Point Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" +#import "FloatingPointNumber.h" + + +#define ORDER_IN_MENU 90 +#define WORDS_PER_ROW 6 +#define CONTENT_WIDTH 22 +#define NEEDS_ALIGNMENT YES +#define ALLOWS_EDITING YES +#define MENU_TITLE @"FPP8-A EP Floating Point (6 words)" +#define TOOL_TIP @"This column displays the memory content as FPP8-A EP floating point numbers." + + +@interface MemoryInspectorFPP8AEPFloatingPoint : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorFPP8AEPFloatingPoint + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + return [[FloatingPointNumber + floatingPointNumberWithExponent:[[value objectAtIndex:0] intValue] + bias:0 + negative:([[value objectAtIndex:1] intValue] & 04000) ? YES : NO + twoComplementMantissa:YES + mantissa:([[value objectAtIndex:1] longLongValue] << 53) | + ([[value objectAtIndex:2] longLongValue] << 41) | + ([[value objectAtIndex:3] longLongValue] << 29) | + ([[value objectAtIndex:4] longLongValue] << 17) | + ([[value objectAtIndex:5] longLongValue] << 5)] + stringValueWithPrecision:15]; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + FloatingPointNumber *f = [FloatingPointNumber floatingPointNumberFromString:string + withBias:0 withTwoComplementMantissa:YES error:error]; + if (! f) + return FALSE; + unsigned long long mantissa = [f mantissa]; + *value = [NSArray arrayWithObjects: + [NSNumber numberWithInt:077770000 | [f exponent]], + [NSNumber numberWithInt: + 077770000 | ([f negative] ? 04000 : 0) | (unsigned long) (mantissa >> 53)], + [NSNumber numberWithInt:077770000 | (unsigned long) ((mantissa >> 41) & 07777)], + [NSNumber numberWithInt:077770000 | (unsigned long) ((mantissa >> 29) & 07777)], + [NSNumber numberWithInt:077770000 | (unsigned long) ((mantissa >> 17) & 07777)], + [NSNumber numberWithInt:077770000 | (unsigned long) ((mantissa >> 5) & 07777)], + nil]; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorFPP8AFPFloatingPoint.m b/MemoryInspector/MemoryInspectorFPP8AFPFloatingPoint.m new file mode 100644 index 0000000..f3d18df --- /dev/null +++ b/MemoryInspector/MemoryInspectorFPP8AFPFloatingPoint.m @@ -0,0 +1,129 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorFPP8AFPFloatingPoint.m - FPP8-A FP Floating Point Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" +#import "FloatingPointNumber.h" + + +#define ORDER_IN_MENU 80 +#define WORDS_PER_ROW 3 +#define CONTENT_WIDTH 16 +#define NEEDS_ALIGNMENT YES +#define ALLOWS_EDITING YES +#define MENU_TITLE @"FPP8-A FP Floating Point (3 words)" +#define TOOL_TIP @"This column displays the memory content as FPP8-A FP floating point numbers." + + +@interface MemoryInspectorFPP8AFPFloatingPoint : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorFPP8AFPFloatingPoint + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + return [[FloatingPointNumber + floatingPointNumberWithExponent:[[value objectAtIndex:0] intValue] + bias:0 + negative:([[value objectAtIndex:1] intValue] & 04000) ? YES : NO + twoComplementMantissa:YES + mantissa:([[value objectAtIndex:1] longLongValue] << 53) | + ([[value objectAtIndex:2] longLongValue] << 41)] + stringValueWithPrecision:6]; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + FloatingPointNumber *f = [FloatingPointNumber floatingPointNumberFromString:string + withBias:0 withTwoComplementMantissa:YES error:error]; + if (! f) + return FALSE; + *value = [NSArray arrayWithObjects: + [NSNumber numberWithInt:077770000 | [f exponent]], + [NSNumber numberWithInt: + 077770000 | ([f negative] ? 04000 : 0) | (unsigned long) ([f mantissa] >> 53)], + [NSNumber numberWithInt:077770000 | (unsigned long) (([f mantissa] >> 41) & 07777)], + nil]; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorFortranIIFloatingPoint.m b/MemoryInspector/MemoryInspectorFortranIIFloatingPoint.m new file mode 100644 index 0000000..55f6d84 --- /dev/null +++ b/MemoryInspector/MemoryInspectorFortranIIFloatingPoint.m @@ -0,0 +1,131 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorFortranIIFloatingPoint.m - Fortran II Floating Point Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" +#import "FloatingPointNumber.h" + + +#define ORDER_IN_MENU 100 +#define WORDS_PER_ROW 3 +#define CONTENT_WIDTH 16 +#define NEEDS_ALIGNMENT YES +#define ALLOWS_EDITING YES +#define MENU_TITLE @"FORTRAN II Floating Point (3 words)" +#define TOOL_TIP @"This column displays the memory content as FORTRAN II floating point numbers." + + +@interface MemoryInspectorFortranIIFloatingPoint : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorFortranIIFloatingPoint + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + return [[FloatingPointNumber + floatingPointNumberWithExponent:([[value objectAtIndex:0] intValue] >> 3) & 0377 + bias:0200 + negative:([[value objectAtIndex:0] intValue] & 04000) ? YES : NO + twoComplementMantissa:NO + mantissa:([[value objectAtIndex:0] longLongValue] << 61) | + ([[value objectAtIndex:1] longLongValue] << 49) | + ([[value objectAtIndex:2] longLongValue] << 37)] + stringValueWithPrecision:8]; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + FloatingPointNumber *f = [FloatingPointNumber floatingPointNumberFromString:string + withBias:0200 withTwoComplementMantissa:NO error:error]; + if (! f) + return FALSE; + unsigned long long mantissa = [f mantissa]; + *value = [NSArray arrayWithObjects: + [NSNumber numberWithInt:077770000 | + ([f negative] ? 04000 : 0) | ([f exponent] << 3) | (unsigned long) (mantissa >> 61)], + [NSNumber numberWithInt:077770000 | (unsigned long) ((mantissa >> 49) & 07777)], + [NSNumber numberWithInt:077770000 | (unsigned long) ((mantissa >> 37) & 07777)], + nil]; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorOS8Packed8BitASCII.m b/MemoryInspector/MemoryInspectorOS8Packed8BitASCII.m new file mode 100644 index 0000000..a947485 --- /dev/null +++ b/MemoryInspector/MemoryInspectorOS8Packed8BitASCII.m @@ -0,0 +1,178 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorOS8Packed8BitASCII.m - OS/8 Packed 8Bit ASCII Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" +#import "Unicode.h" + + +#define ORDER_IN_MENU 30 +#define WORDS_PER_ROW 4 +#define CONTENT_WIDTH 6 +#define NEEDS_ALIGNMENT YES +#define ALLOWS_EDITING YES +#define MENU_TITLE @"OS/8 Packed 8-Bit ASCII" +#define TOOL_TIP @"This column displays the memory content as OS/8 Packed 8-bit ASCII. " \ + "When editing a cell, use " UNICODE_MIDDLE_DOT_UTF8 " (option-shift-9) " \ + "to keep the current value and " UNICODE_BULLET_UTF8 \ + " (option-8 on an English keyboard or option-ü on a German keyboard) to force zero." + + +@interface MemoryInspectorOS8Packed8BitASCII : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorOS8Packed8BitASCII + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + unsigned short i, c, w0, w1; + + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + NSMutableString *string = [NSMutableString stringWithCapacity:CONTENT_WIDTH]; + for (i = 0; i < WORDS_PER_ROW; i += 2) { + w0 = [[value objectAtIndex:i] intValue]; + c = w0 & 0177; + if (c < 040 || c >= 0177) + c = UNICODE_MIDDLE_DOT; + [string appendFormat:@"%C", c]; + w1 = [[value objectAtIndex:i + 1] intValue]; + c = w1 & 0177; + if (c < 040 || c >= 0177) + c = UNICODE_MIDDLE_DOT; + [string appendFormat:@"%C", c]; + c = ((w0 & 03400) >> 4) | ((w1 & 07400) >> 8); + if (c < 040 || c >= 0177) + c = UNICODE_MIDDLE_DOT; + [string appendFormat:@"%C", c]; + } + return string; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + int i, c, c0, c1, m, m0, m1; + + if ([string length] != CONTENT_WIDTH) { + if (error) + *error = NSLocalizedString(@"Exactly six characters required.", @""); + return FALSE; + } + c0 = c1 = m0 = m1 = 0; // only to avoid "used uninitialized" compiler warning + NSMutableArray *val = [NSMutableArray arrayWithCapacity:4]; + for (i = 0; i < CONTENT_WIDTH; i++) { + c = [string characterAtIndex:i]; + m = 0377; + if (c == UNICODE_MIDDLE_DOT) { // don't care, save old value + c = 0; + m &= ~0377; + } else if (c == UNICODE_BULLET) // force zero + c = 0; + else if (c & ~0177) { + if (error) + *error = [NSString stringWithFormat:NSLocalizedString( + @"Invalid 8-bit ASCII character %C%C%C.", @""), + UNICODE_LEFT_DOUBLEQUOTE, c, UNICODE_RIGHT_DOUBLEQUOTE]; + return FALSE; + } + switch (i % 3) { + case 0 : + c0 = c; + m0 = m; + break; + case 1 : + c1 = c; + m1 = m; + break; + case 2 : + c0 |= (c & 0360) << 4; + m0 |= (m & 0360) << 4; + c1 |= (c & 017) << 8; + m1 |= (m & 017) << 8; + [val addObject:[NSNumber numberWithInt:(m0 << 12) | c0]]; + [val addObject:[NSNumber numberWithInt:(m1 << 12) | c1]]; + break; + } + } + *value = val; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorPascalSFloatingPoint.m b/MemoryInspector/MemoryInspectorPascalSFloatingPoint.m new file mode 100644 index 0000000..3b36cb4 --- /dev/null +++ b/MemoryInspector/MemoryInspectorPascalSFloatingPoint.m @@ -0,0 +1,131 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorPascalSFloatingPoint.m - Pascal-S Floating Point Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" +#import "FloatingPointNumber.h" + + +#define ORDER_IN_MENU 110 +#define WORDS_PER_ROW 4 +#define CONTENT_WIDTH 17 +#define NEEDS_ALIGNMENT YES +#define ALLOWS_EDITING YES +#define MENU_TITLE @"Pascal-S Floating Point (4 words)" +#define TOOL_TIP @"This column displays the memory content as Pascal-S floating point numbers." + + +@interface MemoryInspectorPascalSFloatingPoint : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorPascalSFloatingPoint + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + return [[FloatingPointNumber + floatingPointNumberWithExponent:[[value objectAtIndex:0] intValue] + bias:0 + negative:([[value objectAtIndex:1] intValue] & 04000) ? YES : NO + twoComplementMantissa:NO + mantissa:([[value objectAtIndex:1] longLongValue] << 53) | + ([[value objectAtIndex:2] longLongValue] << 41) | + ([[value objectAtIndex:3] longLongValue] << 29)] + stringValueWithPrecision:10]; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + FloatingPointNumber *f = [FloatingPointNumber floatingPointNumberFromString:string + withBias:0 withTwoComplementMantissa:NO error:error]; + if (! f) + return FALSE; + *value = [NSArray arrayWithObjects: + [NSNumber numberWithInt:077770000 | [f exponent]], + [NSNumber numberWithInt: + 077770000 | ([f negative] ? 04000 : 0) | (unsigned long) ([f mantissa] >> 53)], + [NSNumber numberWithInt:077770000 | (unsigned long) (([f mantissa] >> 41) & 07777)], + [NSNumber numberWithInt:077770000 | (unsigned long) (([f mantissa] >> 29) & 07777)], + nil]; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorProtocol.h b/MemoryInspector/MemoryInspectorProtocol.h new file mode 100644 index 0000000..20aa8a7 --- /dev/null +++ b/MemoryInspector/MemoryInspectorProtocol.h @@ -0,0 +1,44 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorProtocol.h - Protocol for Memory Inspectors + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +/* A Memory Inspector is a subclass of NSFormatter that conforms to the MemoryInspector protocol. + To add a new inspector, simply include a new class in a plugin; it will automatically be detected. + The NSFormatter methods work on a NSArray of wordsPerRow 12-bit PDP-8 words. The order of the + inspector in the popup menu of the memory inspector drawer is determined by orderInMemoryInspectorMenu; + the built-in inspectors use numbers 10, 20,... */ + + +@protocol MemoryInspector + ++ (void) load; // empty dummy method to cause ZeroLink to load the class in the debug builds + +- (NSNumber *) orderInMemoryInspectorMenu; +- (NSString *) menuTitle; +- (unsigned) wordsPerRow; +- (unsigned) contentWidthInCharacters; +- (BOOL) needsMemoryAlignment; +- (BOOL) allowsEditing; +- (NSString *) toolTipForContentColumn; + +@end diff --git a/MemoryInspector/MemoryInspectorSignedInteger.m b/MemoryInspector/MemoryInspectorSignedInteger.m new file mode 100644 index 0000000..1eae037 --- /dev/null +++ b/MemoryInspector/MemoryInspectorSignedInteger.m @@ -0,0 +1,145 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorSignedInteger.m - Signed Integer Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" + + +#define ORDER_IN_MENU 40 +#define WORDS_PER_ROW 2 +#define CONTENT_WIDTH 11 +#define NEEDS_ALIGNMENT NO +#define ALLOWS_EDITING YES +#define MENU_TITLE @"Signed Integer" +#define TOOL_TIP @"This column displays the memory content as signed integer." + + +@interface MemoryInspectorSignedInteger : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorSignedInteger + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + int w0 = [[value objectAtIndex:0] intValue]; + int w1 = [[value objectAtIndex:1] intValue]; + if (w0 & 04000) + w0 |= ~07777; + if (w1 & 04000) + w1 |= ~07777; + return [NSString stringWithFormat:@"%5d %5d", w0, w1]; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + int i, n; + + NSMutableArray *val = [NSMutableArray arrayWithCapacity:WORDS_PER_ROW]; + NSScanner *scanner = [NSScanner scannerWithString:string]; + for (i = 0; i < WORDS_PER_ROW; i++) { + if ([scanner scanInt:&n]) { + if ((n & ~03777) != 0 && (n & ~03777) != ~03777) { + if (error) + *error = NSLocalizedString( + @"Signed integer out of valid range from -2048 to 2047.", + @""); + return FALSE; + } + [val addObject:[NSNumber numberWithInt:077770000 | (n & 07777)]]; + } else { + if (error) + *error = [scanner isAtEnd] ? + NSLocalizedString(@"Exactly two signed integers expected.", @"") : + NSLocalizedString(@"Invalid signed integer.", @""); + return FALSE; + } + } + if (! [scanner isAtEnd]) { + if (error) + *error = NSLocalizedString(@"Exactly two signed integers expected.", @""); + return FALSE; + } + *value = val; + return TRUE; +} + + +@end diff --git a/MemoryInspector/MemoryInspectorUnsignedInteger.m b/MemoryInspector/MemoryInspectorUnsignedInteger.m new file mode 100644 index 0000000..a17aced --- /dev/null +++ b/MemoryInspector/MemoryInspectorUnsignedInteger.m @@ -0,0 +1,139 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * MemoryInspectorUnsignedInteger.m - Unsigned Integer Memory Inspector + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "MemoryInspectorProtocol.h" + + +#define ORDER_IN_MENU 50 +#define WORDS_PER_ROW 2 +#define CONTENT_WIDTH 9 +#define NEEDS_ALIGNMENT NO +#define ALLOWS_EDITING YES +#define MENU_TITLE @"Unsigned Integer" +#define TOOL_TIP @"This column displays the memory content as unsigned integer." + + +@interface MemoryInspectorUnsignedInteger : NSFormatter +{ +} +@end + + +@implementation MemoryInspectorUnsignedInteger + + ++ (void) load +{ + /* dummy to load the class when zero-linking while development */ +} + + +- (NSNumber *) orderInMemoryInspectorMenu +{ + return [NSNumber numberWithInt:ORDER_IN_MENU]; +} + + +- (NSString *) menuTitle +{ + return NSLocalizedString(MENU_TITLE, @""); +} + + +- (unsigned) wordsPerRow +{ + return WORDS_PER_ROW; +} + + +- (unsigned) contentWidthInCharacters +{ + return CONTENT_WIDTH; +} + + +- (BOOL) needsMemoryAlignment +{ + return NEEDS_ALIGNMENT; +} + + +- (BOOL) allowsEditing +{ + return ALLOWS_EDITING; +} + + +- (NSString *) toolTipForContentColumn +{ + return NSLocalizedString(TOOL_TIP, @""); +} + + +- (NSString *) stringForObjectValue:(NSArray *)value +{ + if ([[value class] isSubclassOfClass:[NSString class]]) + return (NSString *) value; + NSAssert ([value count] == WORDS_PER_ROW, @"Invalid number of words to format"); + return [NSString stringWithFormat:@"%4d %4d", + [[value objectAtIndex:0] intValue], [[value objectAtIndex:1] intValue]]; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +{ + int i, n; + + NSMutableArray *val = [NSMutableArray arrayWithCapacity:WORDS_PER_ROW]; + NSScanner *scanner = [NSScanner scannerWithString:string]; + for (i = 0; i < WORDS_PER_ROW; i++) { + if ([scanner scanInt:&n]) { + if ((n & ~07777) != 0) { + if (error) + *error = NSLocalizedString( + @"Unsigned integer out of valid range from 0 to 4095.", @""); + return FALSE; + } + [val addObject:[NSNumber numberWithInt:077770000 | n]]; + } else { + if (error) + *error = [scanner isAtEnd] ? + NSLocalizedString(@"Exactly two unsigned integers expected.", @"") : + NSLocalizedString(@"Invalid unsigned integer.", @""); + return FALSE; + } + } + if (! [scanner isAtEnd]) { + if (error) + *error = NSLocalizedString(@"Exactly two unsigned integers expected.", @""); + return FALSE; + } + *value = val; + return TRUE; +} + + +@end diff --git a/PC8E/English.lproj/InfoPlist.strings b/PC8E/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..8bb23f4 --- /dev/null +++ b/PC8E/English.lproj/InfoPlist.strings @@ -0,0 +1,28 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InfoPlist.strings - Localized strings for Info.plist + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +CFBundleName = "PC8-E Paper Tape Reader & Punch"; +CFBundleGetInfoString = "PC8-E Paper Tape Reader & Punch 2.0.2, Copyright © 1994-2015 Bernhard Baehr"; +NSHumanReadableCopyright = "Copyright © 1994-2015 Bernhard Baehr"; +CFBundleHelpBookName = "PC8-E Paper Tape Reader & Punch Help"; \ No newline at end of file diff --git a/PC8E/English.lproj/PC8E.nib/designable.nib b/PC8E/English.lproj/PC8E.nib/designable.nib new file mode 100644 index 0000000..1792567 --- /dev/null +++ b/PC8E/English.lproj/PC8E.nib/designable.nib @@ -0,0 +1,1213 @@ + + + + 1040 + 10K549 + 851 + 1038.36 + 461.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + YES + + + + YES + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + YES + + PC8E + + + FirstResponder + + + NSApplication + + + 4103 + 2 + {{196, 376}, {436, 118}} + 1618477056 + PC8-E Paper Tape Reader & Punch + KeepInMenuWindow + + {1.79769e+308, 1.79769e+308} + + + 256 + + YES + + + 45 + + YES + + + 274 + + YES + + + 256 + {{13, 59}, {57, 19}} + + YES + 1 + 1 + + YES + + -1805647807 + 205521920 + 377 + + LucidaGrande + 11 + 3100 + + + 23.18017578125 + + 67108864 + 67108864 + RBF + + + + + + {57, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 23.18017578125 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 3 + MQA + + + + + + -2147483392 + {{13, 32}, {182, 19}} + + + YES + + 71303232 + 138545664 + Filename + + + 1 + + 2 + MC44NDcwNTg4OSAwLjg0NzA1ODg5IDAuODQ3MDU4ODkAA + + + 6 + System + controlTextColor + + 3 + MAA + + + + + + + -2147483392 + {{13, 12}, {182, 12}} + + 16652 + 100 + + + + 268 + {{78, 54}, {122, 28}} + + YES + + 67108864 + 134348800 + Load + + + -2038284288 + 129 + + + 200 + 25 + + + + {{2, 2}, {208, 89}} + + + + {{5, 4}, {212, 106}} + + {0, 0} + + 67108864 + 0 + High Speed Reader + + + 6 + System + textBackgroundColor + + + + 3 + MCAwLjgwMDAwMDAxMTkAA + + + + 3 + 0 + 2 + NO + + + + 45 + + YES + + + 274 + + YES + + + 256 + {{13, 59}, {57, 19}} + + YES + 1 + 1 + + YES + + -1805647807 + 205521920 + 377 + + + 23.18017578125 + + 67108864 + 67108864 + PBF + + + + + + {57, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 23.18017578125 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + -2147483392 + {{13, 32}, {182, 19}} + + + YES + + 71303232 + 138545664 + Filename + + + 1 + + 2 + MC44NDcwNTg4OSAwLjg0NzA1ODg5IDAuODQ3MDU4ODkAA + + + + + + + -2147483392 + {{13, 12}, {182, 12}} + + 16654 + 100 + + + + 268 + {{78, 54}, {122, 28}} + + 1 + YES + + 67108864 + 134348800 + Load + + + -2038284288 + 129 + + + 200 + 25 + + + + {{2, 2}, {208, 89}} + + + + {{219, 4}, {212, 106}} + + {0, 0} + + 67108864 + 0 + High Speed Punch + + + + 3 + MCAwLjgwMDAwMDAxMTkAA + + + + 3 + 0 + 2 + NO + + + {436, 118} + + + {{0, 0}, {1680, 1028}} + {1.79769e+308, 1.79769e+308} + PC8EWindow + NO + + + PaperTapeController + + + PaperTapeController + + + + + YES + + + window + + + + 39 + + + + filenameField + + + + 206 + + + + progressIndicator + + + + 207 + + + + inputConsumer + + + + 213 + + + + inputConsumer + + + + 216 + + + + reader + + + + 221 + + + + punch + + + + 222 + + + + rbfCell + + + + 224 + + + + filenameField + + + + 235 + + + + progressIndicator + + + + 237 + + + + loadUnloadButton + + + + 250 + + + + loadUnloadClicked: + + + + 251 + + + + pbfCell + + + + 252 + + + + initialFirstResponder + + + + 253 + + + + nextKeyView + + + + 256 + + + + nextKeyView + + + + 257 + + + + nextKeyView + + + + 260 + + + + loadUnloadClicked: + + + + 261 + + + + loadUnloadButton + + + + 262 + + + + nextKeyView + + + + 263 + + + + + YES + + 0 + + YES + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 1 + + + YES + + + + + + 2 + + + YES + + + + + + + 179 + + + YES + + + + + + + + + 189 + + + YES + + + + + + + 190 + + + YES + + + + + + 191 + + + + + 192 + + + + + 193 + + + + + 194 + + + + + 205 + + + ReaderController + + + 214 + + + PunchController + + + 225 + + + YES + + + + + + + + + 226 + + + + + 228 + + + YES + + + + + + 229 + + + YES + + + + + + + 230 + + + + + 231 + + + + + 232 + + + + + 248 + + + YES + + + + + + 249 + + + + + 258 + + + YES + + + + + + 259 + + + + + + + YES + + YES + -3.IBPluginDependency + 1.IBEditorWindowLastContentRect + 1.IBPluginDependency + 1.IBWindowTemplateEditedContentRect + 1.NSWindowTemplate.visibleAtLaunch + 1.WindowOrigin + 1.editorWindowContentRectSynchronizationRect + 179.IBPluginDependency + 179.IBViewBoundsToFrameTransform + 189.IBAttributePlaceholdersKey + 189.IBPluginDependency + 189.ImportedFromIB2 + 190.IBAttributePlaceholdersKey + 190.IBPluginDependency + 191.CustomClassName + 191.IBAttributePlaceholdersKey + 191.IBPluginDependency + 191.IBViewBoundsToFrameTransform + 192.IBPluginDependency + 193.CustomClassName + 193.IBAttributePlaceholdersKey + 193.IBPluginDependency + 193.ImportedFromIB2 + 194.IBPluginDependency + 2.IBPluginDependency + 205.IBPluginDependency + 214.IBPluginDependency + 225.IBPluginDependency + 225.IBViewBoundsToFrameTransform + 226.CustomClassName + 226.IBAttributePlaceholdersKey + 226.IBPluginDependency + 226.IBViewBoundsToFrameTransform + 228.IBAttributePlaceholdersKey + 228.IBPluginDependency + 229.IBAttributePlaceholdersKey + 229.IBPluginDependency + 229.ImportedFromIB2 + 230.IBPluginDependency + 231.CustomClassName + 231.IBAttributePlaceholdersKey + 231.IBPluginDependency + 231.ImportedFromIB2 + 232.IBPluginDependency + 248.IBAttributePlaceholdersKey + 248.IBPluginDependency + 249.IBPluginDependency + 258.IBAttributePlaceholdersKey + 258.IBPluginDependency + 259.IBPluginDependency + + + YES + com.apple.InterfaceBuilder.CocoaPlugin + {{289, 83}, {436, 118}} + com.apple.InterfaceBuilder.CocoaPlugin + {{289, 83}, {436, 118}} + + {196, 240} + {{357, 418}, {480, 270}} + com.apple.InterfaceBuilder.CocoaPlugin + + AUCgAABAgAAAA + + + ToolTip + + ToolTip + + The RBF (Reader Buffer) receives the characters read from the paper tape. After putting a new character into RBF, the reader raises its input flag. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Filename of the paper tape currently loaded into the reader + + + com.apple.InterfaceBuilder.CocoaPlugin + PaperTapeProgressIndicator + + ToolTip + + ToolTip + + Progress indicator for the paper tape reader + + + com.apple.InterfaceBuilder.CocoaPlugin + + P4AAAL+AAABBYAAAwbAAAA + + com.apple.InterfaceBuilder.CocoaPlugin + RegisterFormCell + + ToolTip + + ToolTip + + The ERIOT register holds the opcode of the last JMS, JMP, IOT, HLT or OSR instruction performed in user mode. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + AUGIAABCxAAAA + + PaperTapeProgressIndicator + + ToolTip + + ToolTip + + Progress indicator for the paper tape punch + + + com.apple.InterfaceBuilder.CocoaPlugin + + P4AAAL+AAABBYAAAwbAAAA + + + ToolTip + + ToolTip + + Filename of the paper tape currently loaded into the punch + + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + The CPU loads the characters it wants to punch from AC into PBF (Punch Buffer) using IOT PPC (6024). When the character is punched, the punch sets its output flag. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + RegisterFormCell + + ToolTip + + ToolTip + + The ERIOT register holds the opcode of the last JMS, JMP, IOT, HLT or OSR instruction performed in user mode. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + TG9hZHMgb3IgdW5sb2FkcyBhIHBhcGVyIHRhcGUgZm9yIHRoZSBwdW5jaC4KCllvdSBhbHNvIGNhbiBk +cmFnIGZpbGVzIGZyb20gdGhlIEZpbmRlciB0byB0aGlzIGJ1dHRvbiB0byBsb2FkIHRoZW0uA + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + ToolTip + + ToolTip + + TG9hZHMgb3IgdW5sb2FkcyBhIHBhcGVyIHRhcGUgZm9yIHRoZSByZWFkZXIuCgpZb3UgYWxzbyBjYW4g +ZHJhZyBmaWxlcyBmcm9tIHRoZSBGaW5kZXIgdG8gdGhpcyBidXR0b24gdG8gbG9hZCB0aGVtLg + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + + + YES + + + YES + + + + + YES + + + YES + + + + 263 + + + + YES + + KeepInMenuWindow + NSWindow + + YES + + YES + orderBackFromDefaults: + orderFrontFromDefaults: + + + YES + id + id + + + + YES + + YES + orderBackFromDefaults: + orderFrontFromDefaults: + + + YES + + orderBackFromDefaults: + id + + + orderFrontFromDefaults: + id + + + + + IBProjectSource + Utilities/KeepInMenuWindow.h + + + + NSControl + + IBProjectSource + Categories/NSControl+FileDrop.h + + + + PC8E + PDP8Plugin + + YES + + YES + pbfCell + punch + rbfCell + reader + window + + + YES + RegisterFormCell + PaperTapeController + RegisterFormCell + PaperTapeController + KeepInMenuWindow + + + + YES + + YES + pbfCell + punch + rbfCell + reader + window + + + YES + + pbfCell + RegisterFormCell + + + punch + PaperTapeController + + + rbfCell + RegisterFormCell + + + reader + PaperTapeController + + + window + KeepInMenuWindow + + + + + IBProjectSource + PC8E/PC8E.h + + + + PDP8Plugin + NSObject + + IBProjectSource + Plugins/PluginAPI.h + + + + PaperTapeController + NSObject + + YES + + YES + loadUnloadClicked: + onOffClicked: + + + YES + id + id + + + + YES + + YES + loadUnloadClicked: + onOffClicked: + + + YES + + loadUnloadClicked: + id + + + onOffClicked: + id + + + + + YES + + YES + filenameField + inputConsumer + loadUnloadButton + onOffButton + progressIndicator + + + YES + NSTextField + id + NSControl + NSSegmentedControl + PaperTapeProgressIndicator + + + + YES + + YES + filenameField + inputConsumer + loadUnloadButton + onOffButton + progressIndicator + + + YES + + filenameField + NSTextField + + + inputConsumer + id + + + loadUnloadButton + NSControl + + + onOffButton + NSSegmentedControl + + + progressIndicator + PaperTapeProgressIndicator + + + + + IBProjectSource + ASR33/PaperTapeController.h + + + + PaperTapeProgressIndicator + NSProgressIndicator + + IBProjectSource + ASR33/PaperTapeProgressIndicator.h + + + + RegisterFormCell + NSFormCell + + registerOwner + id + + + registerOwner + + registerOwner + id + + + + IBProjectSource + Utilities/RegisterFormCell.h + + + + + YES + + KeepInMenuWindow + NSWindow + + IBFrameworkSource + PluginFramework.framework/Headers/KeepInMenuWindow.h + + + + NSControl + + IBFrameworkSource + PluginFramework.framework/Headers/NSControl+FileDrop.h + + + + PDP8Plugin + NSObject + + IBFrameworkSource + PluginFramework.framework/Headers/PluginAPI.h + + + + RegisterFormCell + NSFormCell + + IBFrameworkSource + PluginFramework.framework/Headers/RegisterFormCell.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + + com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3 + + + YES + ../../pdp8e-simulator.xcodeproj + 3 + + diff --git a/PC8E/English.lproj/PC8E.nib/keyedobjects.nib b/PC8E/English.lproj/PC8E.nib/keyedobjects.nib new file mode 100644 index 0000000..8b62633 Binary files /dev/null and b/PC8E/English.lproj/PC8E.nib/keyedobjects.nib differ diff --git a/PC8E/English.lproj/PC8EOnlineHelp/ascii_tape.png b/PC8E/English.lproj/PC8EOnlineHelp/ascii_tape.png new file mode 100644 index 0000000..6db31a7 Binary files /dev/null and b/PC8E/English.lproj/PC8EOnlineHelp/ascii_tape.png differ diff --git a/PC8E/English.lproj/PC8EOnlineHelp/bin_tape.png b/PC8E/English.lproj/PC8EOnlineHelp/bin_tape.png new file mode 100644 index 0000000..2f340ae Binary files /dev/null and b/PC8E/English.lproj/PC8EOnlineHelp/bin_tape.png differ diff --git a/PC8E/English.lproj/PC8EOnlineHelp/index.html b/PC8E/English.lproj/PC8EOnlineHelp/index.html new file mode 100644 index 0000000..0264f6e --- /dev/null +++ b/PC8E/English.lproj/PC8EOnlineHelp/index.html @@ -0,0 +1,194 @@ + + + + + + PC8-E Paper Tape Reader & Punch Help + + + + + + + +

IOTs for the PC8-E Paper Tape Reader & Punch

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Mnemonic
Symbol
Octal
Code

Description
RPE6010 + Set the interrupt enable mask for the punch and the reader. +
RSF6011 + Skip the next instruction when the reader I/O flag is raised, i. e. when a new + character is loaded into the reader buffer RBF. +
RRB6012 + Read the content of the reader buffer RBF into AC (by performing a logical OR) + and clear the reader I/O flag. +
RFC6014 + Clear the reader I/O flag and RBF and start to fetch one character from the input tape + to be loaded into RBF. The reader I/O flag is set again when the operation is completed. +
RCC6016 + Load RBF into AC (by performing a logical OR), clear the reader I/O flag and RBF and + start to read the next tape character. Microprogrammed combination of RRB and RFC. +
PCE6020 + Clear the interrupt enable mask for the punch and the reader. +
PSF6021 + Skip the next instruction when the punch I/O flag is set. +
PCF6022 + Clear the punch I/O flag and the punch buffer PBF. +
PPC6024 + Load the punch buffer from AC(4-11) (by performing a logical OR) and start to punch the + character in PBF. (This instruction does not clear the PBF and the punch I/O flag.) +
PLS6026 + Clear the punch I/O flag, clear PBF, load PBF from AC(4-11) and start to punch the + character in PBF. The punch I/O flag is set again when the operation is complete. + Microprogrammed combination of PCF and PPC. +
+ +

Remark

+ +

+The IOTs RPE (6010), RCC (6016) and PCE (6020) are not available with older PDP-8 models +(PDP-8, -8/S, -8/I, -8/L). +

+ +

Paper Tape Formats

+ +

+There are three basic paper tape formats commonly used in conjunction with the PDP-8 family of computers. +The following paragraphs describe and illustrate these formats. +

+ + + + + + + + + + + + + + +
+ + +

ASCII Format

+

+The ASCII format uses eight channels of the paper tape to represent a single character as shown in the +diagram at left. Channel 8 is normally designated for parity check. The paper tape units of the PDP-8 +family computers do not generate parity, and channel 8 is always punched. +

+

+377 (DEL, Rubout; all channels perforated) is used to “correct” typing errors and is ignored +by paper tape rading programs. +

+ + +

RIM (Read In Mode) Format

+

+RIM format tape uses adjacent columns to represent 12-bit binary information directly. +Channels 1 through 6 are used to represent either addresses or information to be stored. +A channel 7 punch indicates that the adjacent column and the following column are to be interpreted as an +address specifiying the location in which the information of the following two columns is to be stored. +The tape leader and trailer of RIM format tape must be punched in channel 8 only (octal 200). +

+
+ + +

BIN (Binary) Format

+

+BIN format tape is similar to RIM format except that only the first address of consecutive locations is +specified. +An address is designated by a channel 7 punch, and information following an address is stored in sequential +locations after the designated address until another location is specified as an origin. +The tape leader and trailer of BIN format tape must be punched in channel 8 (octal 200) only. +Field setting is designated by channel 8 and 7 punch plus a three digit field number in channels 4 through 6. +

+

+The last two columns of a BIN format tape contain a checksum. +The checksum is the sum (modulo 7777) of all preceding columns not containing a channel 8 punch +(the field settings are not included in the checksum). +When the BIN loader halts the PDP-8 with AC ≠ 0, then a checksum error occured while loading the tape. +

+
+ + + diff --git a/PC8E/English.lproj/PC8EOnlineHelp/pdp8e.png b/PC8E/English.lproj/PC8EOnlineHelp/pdp8e.png new file mode 100644 index 0000000..2c0c485 Binary files /dev/null and b/PC8E/English.lproj/PC8EOnlineHelp/pdp8e.png differ diff --git a/PC8E/English.lproj/PC8EOnlineHelp/rim_tape.png b/PC8E/English.lproj/PC8EOnlineHelp/rim_tape.png new file mode 100644 index 0000000..187e756 Binary files /dev/null and b/PC8E/English.lproj/PC8EOnlineHelp/rim_tape.png differ diff --git a/PC8E/English.lproj/PC8EOnlineHelp/styles.css b/PC8E/English.lproj/PC8EOnlineHelp/styles.css new file mode 100644 index 0000000..c18751d --- /dev/null +++ b/PC8E/English.lproj/PC8EOnlineHelp/styles.css @@ -0,0 +1,239 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * styles.css - Online help - Style sheet + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +p { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +p.small { + font-size: 8pt; +} + +a { + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +a:hover { + text-decoration: underline +} + +ul { + margin-left: 1.25em; padding-left: 0em; +} + +li { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +#mainbox { + background-color: #fff; + margin-top: 30px; + margin-right: 26px; + margin-left: 18px; + position: absolute; + top: 10px +} + +#taskbox { + background-color: #eee; + list-style-type: decimal; + list-style-position: outside; + margin-top: 12px; + margin-bottom: 12px; + border: solid 1px #444 +} + +h1 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 6pt; +} + +h2 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 8pt; +} + +h3 { + font-size: 10pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 5pt; +} + +h4 { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 4pt; +} + +/* index.html */ + +table.index { + padding-top: 20px; + width: 100%; +} + +td.banner { + padding: 20px; +} + +td.toc { + padding-top: 10px; + padding-bottom: 10px; + padding-left: 20px; + padding-right:20px; + border-left: 1px solid darkgray; +} + +p.toc { + line-height: 40px; +} + +/* other pages */ + +table { + border-collapse: separate; + border-spacing: 0px; +} + +th { + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + font-style: bold; + border-bottom: 1px solid gray; + padding-left: 10px; + padding-right: 10px; +} + +th.left { + text-align: left; +} + +td { + text-align: center; + vertical-align: top; + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + padding-left: 10px; + padding-right: 10px; +} + +td.left { + text-align: left; +} + +td.right { + text-align: right; +} + +td.br { + border-right: 1px solid gray; +} + +td.bb { + border-bottom: 1px solid lightgray; +} + +td.bb_left { + text-align: left; + border-bottom: 1px solid lightgray; +} + +td.bbr { + border-bottom: 1px solid lightgray; + border-right: 1px solid gray; +} + +td.opcode { + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_right { + text-align: right; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_left { + text-align: left; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-left: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + border-right: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} diff --git a/PC8E/English.lproj/io-info.plist b/PC8E/English.lproj/io-info.plist new file mode 100644 index 0000000..8c100b7 --- /dev/null +++ b/PC8E/English.lproj/io-info.plist @@ -0,0 +1,59 @@ + + + + + + ioflags + + PC8-E Reader + PC8-E Punch + + ioaddresses + + 1 + 2 + + iots + + + RPE + RSF + RRB + + RFC + + RCC + + + PCE + PSF + PCF + + PPC + + PLS + + + + diff --git a/PC8E/Info.plist b/PC8E/Info.plist new file mode 100644 index 0000000..5467cdc --- /dev/null +++ b/PC8E/Info.plist @@ -0,0 +1,32 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleHelpBookFolder + PC8EOnlineHelp + CFBundleHelpBookName + PC8-E Paper Tape Reader & Punch Help + CFBundleIconFile + + CFBundleIdentifier + de.bernhard-baehr.pdp8e.PC8E + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + ${PRODUCT_NAME} + CFBundlePackageType + BNDL + CFBundleShortVersionString + 2.0.2 + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + NSPrincipalClass + PC8E + + diff --git a/PC8E/PC8E.h b/PC8E/PC8E.h new file mode 100644 index 0000000..8218834 --- /dev/null +++ b/PC8E/PC8E.h @@ -0,0 +1,73 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * ASR33.h - ASR 33 Teletype for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define RBF_CHANGED_NOTIFICATION @"pc8eReaderBufferChangedNotification" +#define PBF_CHANGED_NOTIFICATION @"pc8ePunchBufferChangedChangedNotification" + + +@class NSCondition, KeepInMenuWindow, RegisterFormCell, PaperTapeController; + + +@interface PC8E : PDP8Plugin +{ +@public +/* The attributes are public, so the C functions implementing the PDP-8 instructions can + access them directly. No other Cocoa code should use them directly. To ensure this, + the register names are mapped to dummy names with the #defines below. In the source + codes files with the instruction C functions, #define USE_PC8E_REGISTERS_DIRECTLY + to make the registers available. */ + unsigned short RBF; + unsigned long inflag; + unsigned long outflag; + unsigned short output; +@private + unsigned short PBF; // private: not accessed by IOTs + int input; // int: can be EOF == -1 + IBOutlet KeepInMenuWindow *window; + IBOutlet RegisterFormCell *rbfCell; + IBOutlet RegisterFormCell *pbfCell; + IBOutlet PaperTapeController *reader; + IBOutlet PaperTapeController *punch; + NSConditionLock *inputLock; + NSConditionLock *outputLock; +} + +- (void) canContinueInput; +- (void) canContinueOutput; +- (unsigned short) getRBF; +- (void) setRBF:(unsigned short)rbf; +- (unsigned short) getPBF; +- (void) setPBF:(unsigned short)pbf; + +@end + + +#if ! USE_PC8E_REGISTERS_DIRECTLY +#define RBF __dont_use_RBF__ +#define PBF __dont_use_PBF__ +#define inflag __dont_use_inflag__ +#define outflag __dont_use_outflag__ +#define input __dont_use_input__ +#define output __dont_use_output__ +#endif diff --git a/PC8E/PC8E.m b/PC8E/PC8E.m new file mode 100644 index 0000000..b836139 --- /dev/null +++ b/PC8E/PC8E.m @@ -0,0 +1,382 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PC8E.m - PC8-E Paper Tape Reader and Punch for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" +#import "PluginFramework/Utilities.h" +#import "PluginFramework/RegisterFormCell.h" +#import "PluginFramework/KeepInMenuWindow.h" +#import "FileDropControlTargetProtocol.h" +#import "PluginFramework/PaperTapeController.h" +#import "PluginFramework/NSThread+MainThread.h" + +#define USE_PC8E_REGISTERS_DIRECTLY 1 + +#import "PC8E.h" +#import "PC8Eiot.h" + + +#define CODER_KEY_RBF @"rbf" +#define CODER_KEY_PBF @"pbf" +#define CODER_KEY_INFLAG @"inflag" +#define CODER_KEY_INMASK @"inmask" +#define CODER_KEY_OUTFLAG @"outflag" +#define CODER_KEY_OUTMASK @"outmask" + +#define NO_OUTPUT 0 +#define OUTPUT 1 +#define NO_INPUT 0 +#define INPUT 1 + +#define READER_CONTINUOUS_DELAY 3333333ull // nanosec. * 300 = 1 sec. => delay for 300 char/sec. +#define READER_STARTSTOP_DELAY 40000000ull // nanosec. * 25 = 1 sec. => delay for 25 char/sec. +#define PUNCH_DELAY 20000000ull // nanosec. * 50 = 1 sec. => delay for 50 char/sec. +#define STOP_DELAY 6000000ull // "stop delay" occurs 6 ms after RFC + + +@implementation PC8E + + +API_VERSION + + +#pragma mark Plugin Methods + + +- (NSArray *) iotsForAddress:(int)ioAddress +{ + return ioAddress == 01 ? + [NSArray arrayWithObjects: + [NSValue valueWithPointer:i6010], + [NSValue valueWithPointer:i6011], + [NSValue valueWithPointer:i6012], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:i6014], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:i6016], + [NSValue valueWithPointer:nil], + nil] : + [NSArray arrayWithObjects: + [NSValue valueWithPointer:i6020], + [NSValue valueWithPointer:i6021], + [NSValue valueWithPointer:i6022], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:i6024], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:i6026], + [NSValue valueWithPointer:nil], + nil]; +} + + +- (NSArray *) skiptestsForAddress:(int)ioAddress +{ + return ioAddress == 01 ? + [NSArray arrayWithObjects: + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6011], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + nil] : + [NSArray arrayWithObjects: + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6021], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + nil]; +} + + +- (void) setIOFlag:(unsigned long)flag forIOFlagName:(NSString *)name; +{ + if (inflag) + outflag = flag; + else + inflag = flag; +} + + +- (void) CAF:(int)ioAddress +{ + if (ioAddress == 01) { // CAF is called twice, ignore second call (01 == reader I/O address) + RBF = 0; + PBF = 0; + [pdp8 setInterruptMaskBits:inflag | outflag]; + [pdp8 clearIOFlagBits:inflag | outflag]; + } +} + + +- (void) clearAllFlags:(int)ioAddress +{ + if (ioAddress == 01) // CAF is called twice, ignore second call (01 == reader I/O address) + [self resetDevice]; +} + + +- (void) resetDevice +{ + [self setRBF:0]; + [self setPBF:0]; + [pdp8 setInterruptMaskBits:inflag | outflag]; + [pdp8 clearIOFlagBits:inflag | outflag]; +} + + +#pragma mark Thread Handling + + +- (void) realtimeDelay:(uint64_t)matStartTime lastStart:(uint64_t)matLastStartTime +{ + int speed = [pdp8 getGoSpeed]; + if (speed != GO_AS_FAST_AS_POSSIBLE) { + uint64_t delay; + if (matLastStartTime == 0) // punch with 50 cps + delay = PUNCH_DELAY; + else { // reader + uint64_t delta = absolute2nanoseconds(matStartTime - matLastStartTime); + if (delta > READER_STARTSTOP_DELAY) // next char already buffered + delay = 0; + else + if (delta > STOP_DELAY) // start stop mode with 25 cps + delay = READER_STARTSTOP_DELAY; + else // continuous read with 300 cps + delay = READER_CONTINUOUS_DELAY; + } + if (speed == GO_WITH_PDP8_SPEED) + mach_wait_until (matStartTime + nanoseconds2absolute(delay)); + else { + while (mach_absolute_time() < matStartTime + nanoseconds2absolute(delay)) + ; + } + } +} + + +- (void) canContinueInput +{ + if ([inputLock tryLockWhenCondition:NO_INPUT]) + [inputLock unlockWithCondition:INPUT]; +#if ! defined(NS_BLOCK_ASSERTIONS) + else + NSLog (@"PDP-8 software bug: RFC or RCC executed before preceding tape read finished"); +#endif +} + + +- (void) canContinueOutput +{ + if ([outputLock tryLockWhenCondition:NO_OUTPUT]) + [outputLock unlockWithCondition:OUTPUT]; +#if ! defined(NS_BLOCK_ASSERTIONS) + else + NSLog (@"PDP-8 software bug: PPC or PLS executed before preceding tape punch finished"); +#endif +} + + +- (void) pc8eReaderThread:(id)object +{ + [[NSAutoreleasePool alloc] init]; + uint64_t matStartTime = mach_absolute_time(); + uint64_t matLastStartTime; + for (;;) { + [inputLock lockWhenCondition:INPUT]; + matLastStartTime = matStartTime; + matStartTime = mach_absolute_time(); + input = [reader getChar]; + if (input != EOF) + [self setRBF:input & 0377]; // strip off Unicode characters etc. + [inputLock unlockWithCondition:NO_INPUT]; + [self realtimeDelay:matStartTime lastStart:matLastStartTime]; + if (input != EOF) + [pdp8 setIOFlagBits:inflag]; + } +} + + +- (void) pc8ePunchThread:(id)object +{ + [[NSAutoreleasePool alloc] init]; + for (;;) { + [outputLock lockWhenCondition:OUTPUT]; + uint64_t matStart = mach_absolute_time(); + [self setPBF:output]; + BOOL done = [punch putChar:output handleBackspace:NO]; + [outputLock unlockWithCondition:NO_OUTPUT]; + [self realtimeDelay:matStart lastStart:0]; + if (done) + [pdp8 setIOFlagBits:outflag]; + } +} + + +#pragma mark Register Access + + +- (unsigned short) getRBF +{ + return RBF; +} + + +- (void) notifyRBF +{ + NSAssertRunningOnMainThread (); + [[NSNotificationCenter defaultCenter] postNotificationName:RBF_CHANGED_NOTIFICATION object:self]; + +} + + +- (void) setRBF:(unsigned short)rbf +{ + NSAssert1 ((rbf & ~0377) == 0, @"Bad RBF: 0%o", rbf); + RBF = rbf; + if ([NSThread isMainThread]) + [[NSNotificationCenter defaultCenter] + postNotificationName:RBF_CHANGED_NOTIFICATION object:self]; + else + [self performSelectorOnMainThread:@selector(notifyRBF) withObject:self waitUntilDone:NO]; +} + + +- (unsigned short) getPBF +{ + return PBF; +} + + +- (void) notifyPBF +{ + NSAssertRunningOnMainThread (); + [[NSNotificationCenter defaultCenter] postNotificationName:PBF_CHANGED_NOTIFICATION object:self]; + +} + + +- (void) setPBF:(unsigned short)pbf +{ + NSAssert1 ((pbf & ~0377) == 0, @"Bad PBF: 0%o", pbf); + PBF = pbf; + if ([NSThread isMainThread]) + [[NSNotificationCenter defaultCenter] + postNotificationName:PBF_CHANGED_NOTIFICATION object:self]; + else + [self performSelectorOnMainThread:@selector(notifyPBF) withObject:self waitUntilDone:NO]; +} + + +#pragma mark Notifications + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"PC8E notifyApplicationWillTerminate"); + [[NSNotificationCenter defaultCenter] removeObserver:self name:NSUserDefaultsDidChangeNotification + object:nil]; + NSMutableData *data = [NSMutableData data]; + NSKeyedArchiver *archiver = [[NSKeyedArchiver alloc] initForWritingWithMutableData:data]; + [self encodeWithCoder:archiver]; + [archiver finishEncoding]; + [archiver release]; + [[NSUserDefaults standardUserDefaults] setObject:data forKey:[self pluginName]]; +} + + +- (void) notifyPluginsLoaded:(NSNotification *)notification +{ + [window orderBackFromDefaults:self]; + [window makeFirstResponder:window]; +} + + +#pragma mark Initialization + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + [self setRBF:[coder decodeIntForKey:CODER_KEY_RBF]]; + [self setPBF:[coder decodeIntForKey:CODER_KEY_PBF]]; + [coder decodeBoolForKey:CODER_KEY_INFLAG] ? + [pdp8 setIOFlagBits:inflag] : [pdp8 clearIOFlagBits:inflag]; + [coder decodeBoolForKey:CODER_KEY_INMASK] ? + [pdp8 setInterruptMaskBits:inflag] : [pdp8 clearInterruptMaskBits:inflag]; + [coder decodeBoolForKey:CODER_KEY_OUTFLAG] ? + [pdp8 setIOFlagBits:outflag] : [pdp8 clearIOFlagBits:outflag]; + [coder decodeBoolForKey:CODER_KEY_OUTMASK] ? + [pdp8 setInterruptMaskBits:outflag] : [pdp8 clearInterruptMaskBits:outflag]; + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + [coder encodeInt:[self getRBF] forKey:CODER_KEY_RBF]; + [coder encodeInt:[self getPBF] forKey:CODER_KEY_PBF]; + [coder encodeBool:[pdp8 getIOFlagBits:inflag] ? YES : NO forKey:CODER_KEY_INFLAG]; + [coder encodeBool:[pdp8 getInterruptMaskBits:inflag] ? YES : NO forKey:CODER_KEY_INMASK]; + [coder encodeBool:[pdp8 getIOFlagBits:outflag] ? YES : NO forKey:CODER_KEY_OUTFLAG]; + [coder encodeBool:[pdp8 getInterruptMaskBits:outflag] ? YES : NO forKey:CODER_KEY_OUTMASK]; +} + + +- (void) pluginDidLoad +{ + [rbfCell setupRegisterFor:self getRegisterValue:@selector(getRBF) setRegisterValue:@selector(setRBF:) + changedNotificationName:RBF_CHANGED_NOTIFICATION mask:0377 base:8]; + [pbfCell setupRegisterFor:self getRegisterValue:@selector(getPBF) setRegisterValue:@selector(setPBF:) + changedNotificationName:PBF_CHANGED_NOTIFICATION mask:0377 base:8]; + NSData *data = [[NSUserDefaults standardUserDefaults] dataForKey:[self pluginName]]; + if (data) { + NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data]; + self = [self initWithCoder:unarchiver]; + [unarchiver finishDecoding]; + [unarchiver release]; + } + inputLock = [[NSConditionLock alloc] initWithCondition:NO_INPUT]; + outputLock = [[NSConditionLock alloc] initWithCondition:NO_OUTPUT]; + [NSThread detachNewThreadSelector:@selector(pc8eReaderThread:) toTarget:self withObject:nil]; + [NSThread detachNewThreadSelector:@selector(pc8ePunchThread:) toTarget:self withObject:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyPluginsLoaded:) + name:PLUGINS_LOADED_NOTIFICATION object:nil]; +} + + +@end diff --git a/PC8E/PC8Eiot.c b/PC8E/PC8Eiot.c new file mode 100644 index 0000000..8cdad78 --- /dev/null +++ b/PC8E/PC8Eiot.c @@ -0,0 +1,124 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PC8Eiot.c - PC8-E Paper Tape Reader & Punch IOTs + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#define USE_PC8E_REGISTERS_DIRECTLY 1 +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" + +#import "PC8E.h" +#import "PC8Eiot.h" + + +void i6010 (void) /* RPE 6010 */ +{ + pdp8->IMASK |= PLUGIN_POINTER(PC8E)->inflag | PLUGIN_POINTER(PC8E)->outflag; + EXECUTION_TIME (12); +} + + +void i6011 (void) /* RSF 6011 */ +{ + if (pdp8->IOFLAGS & PLUGIN_POINTER(PC8E)->inflag) + pdp8->PC++; + EXECUTION_TIME (12); +} + + +unsigned s6011 (void) /* RSF 6011 skiptest */ +{ + return pdp8->IOFLAGS & PLUGIN_POINTER(PC8E)->inflag; +} + + +void i6012 (void) /* RRB 6012 */ +{ + pdp8->AC |= PLUGIN_POINTER(PC8E)->RBF; + pdp8->IOFLAGS &= ~PLUGIN_POINTER(PC8E)->inflag; + EXECUTION_TIME (12); +} + + +void i6014 (void) /* RFC 6014 */ +{ + pdp8->IOFLAGS &= ~PLUGIN_POINTER(PC8E)->inflag; + [PLUGIN_POINTER(PC8E) canContinueInput]; + EXECUTION_TIME (12); +} + + +void i6016 (void) /* RCC 6016 */ +{ + pdp8->AC |= PLUGIN_POINTER(PC8E)->RBF; + i6014 (); +} + + +void i6020 (void) /* PCE 6020 */ +{ + pdp8->IMASK &= ~(PLUGIN_POINTER(PC8E)->inflag | PLUGIN_POINTER(PC8E)->outflag); + EXECUTION_TIME (12); +} + + +void i6021 (void) /* PSF 6021 */ +{ + if (pdp8->IOFLAGS & PLUGIN_POINTER(PC8E)->outflag) + pdp8->PC++; + EXECUTION_TIME (12); +} + + +unsigned s6021 (void) /* PSF 6021 skiptest */ +{ + return pdp8->IOFLAGS & PLUGIN_POINTER(PC8E)->outflag; +} + + +void i6022 (void) /* PCF 6022 */ +{ + pdp8->IOFLAGS &= ~PLUGIN_POINTER(PC8E)->outflag; + PLUGIN_POINTER(PC8E)->output = 0; + EXECUTION_TIME (12); +} + + +void i6024 (void) /* PPC 6024 */ +{ + PLUGIN_POINTER(PC8E)->output |= pdp8->AC & 0377; + [PLUGIN_POINTER(PC8E) canContinueOutput]; + EXECUTION_TIME (12); +} + + +void i6026 (void) /* PLS 6026 */ +{ + pdp8->IOFLAGS &= ~PLUGIN_POINTER(PC8E)->outflag; + PLUGIN_POINTER(PC8E)->output = pdp8->AC & 0377; + [PLUGIN_POINTER(PC8E) canContinueOutput]; + EXECUTION_TIME (12); +} diff --git a/PC8E/PC8Eiot.h b/PC8E/PC8Eiot.h new file mode 100644 index 0000000..9355712 --- /dev/null +++ b/PC8E/PC8Eiot.h @@ -0,0 +1,36 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PC8Eiot.h - PC8-E Paper Tape Reader & Punch IOTs + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +extern void i6010 (void); /* RPE 6010 */ +extern void i6011 (void); /* RSF 6011 */ +extern unsigned s6011 (void); /* RSF (skip test) */ +extern void i6012 (void); /* RRB 6012 */ +extern void i6014 (void); /* RFC 6014 */ +extern void i6016 (void); /* RRB RFC 6016 */ +extern void i6020 (void); /* PCE 6020 */ +extern void i6021 (void); /* PSF 6021 */ +extern unsigned s6021 (void); /* PSF (skip test) */ +extern void i6022 (void); /* PCF 6022 */ +extern void i6024 (void); /* PPC 6024 */ +extern void i6026 (void); /* PLS 6026 */ diff --git a/Panels/BootstrapPanelController.h b/Panels/BootstrapPanelController.h new file mode 100644 index 0000000..3ca1088 --- /dev/null +++ b/Panels/BootstrapPanelController.h @@ -0,0 +1,39 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * BootstrapPanelController.h - Controller for the bootstrap panel + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class PDP8; + + +@interface BootstrapPanelController : NSObject +{ +@private + IBOutlet NSMatrix *loaderRadioButtons; + IBOutlet NSButton *adjustPCCheckbox; + IBOutlet NSStepper *ifStepper; + IBOutlet PDP8 *pdp8; +} + +- (IBAction) loadBootstrapLoader:(id)sender; + +@end diff --git a/Panels/BootstrapPanelController.m b/Panels/BootstrapPanelController.m new file mode 100644 index 0000000..a589f0b --- /dev/null +++ b/Panels/BootstrapPanelController.m @@ -0,0 +1,121 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * BootstrapPanelController.h - Controller for the bootstrap panel + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "BootstrapPanelController.h" +#import "PDP8.h" + + +@implementation BootstrapPanelController + + +#define LOW_SPEED_RIM_TAG 0 +#define HIGH_SPEED_RIM_TAG 1 +#define BIN_LOADER_TAG 2 +#define RK8E_BOOTCODE_TAG 3 + +#define LOW_SPEED_RIM_TAPE @"lowspeedRIM.bin" +#define HIGH_SPEED_RIM_TAPE @"highspeedRIM.bin" +#define BIN_LOADER_TAPE @"binLoader.rim" +#define RK8E_BOOTCODE_TAPE @"rk8eBootcode.bin" + + +- (void) awakeFromNib +{ + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(notifyMemorySizeChanged:) + name:KM8E_MOUNT_NOTIFICATION object:nil]; +} + + +- (BOOL) validateMenuItem:(NSMenuItem *)menuItem // only the Load Bootstrap Loader menu item +{ + return ! [pdp8 isGoing]; +} + + +- (void) notifyMemorySizeChanged:(NSNotification *)notification +{ + [ifStepper setMaxValue:([pdp8 memorySize] >> 12) - 1]; + [[ifStepper target] performSelector:[ifStepper action] withObject:ifStepper]; +} + + +- (IBAction) loadBootstrapLoader:(id)sender +{ + unsigned addr, field; + NSString *error, *path, *file; + + NSBundle *mainBundle = [NSBundle mainBundle]; + + switch ([[loaderRadioButtons selectedCell] tag]) { + case LOW_SPEED_RIM_TAG : + path = [mainBundle pathForResource:LOW_SPEED_RIM_TAPE ofType:nil]; + file = LOW_SPEED_RIM_TAPE; + field = [ifStepper intValue]; + addr = 07756; + break; + case HIGH_SPEED_RIM_TAG : + path = [mainBundle pathForResource:HIGH_SPEED_RIM_TAPE ofType:nil]; + file = HIGH_SPEED_RIM_TAPE; + field = [ifStepper intValue]; + addr = 07756; + break; + case BIN_LOADER_TAG : + path = [mainBundle pathForResource:BIN_LOADER_TAPE ofType:nil]; + file = BIN_LOADER_TAPE; + field = [ifStepper intValue]; + addr = 07777; + break; + case RK8E_BOOTCODE_TAG : + path = [mainBundle pathForResource:RK8E_BOOTCODE_TAPE ofType:nil]; + file = RK8E_BOOTCODE_TAPE; + field = 0; + addr = 00027; + break; + default : /* to avoid compiler "used uninitialized" warning */ + path = file = nil; + field = addr = 0; + break; + } + error = [pdp8 loadPaperTape:path toField:field]; + if (error) { + if (! path) + path = [NSString stringWithFormat:NSLocalizedString( + @"The resource file %@ is missing in the application bundle.", @""), file]; + NSAlert *alert = [[NSAlert alloc] init]; + [alert setAlertStyle:NSWarningAlertStyle]; + [alert setMessageText:error]; + [alert setInformativeText:path]; + [alert runModal]; + [alert release]; + } else if ([adjustPCCheckbox intValue]) { + [pdp8 setPC:addr]; + [pdp8 setIF:field]; + [pdp8 setIB:field]; + } +} + + +@end diff --git a/Panels/BreakpointController.h b/Panels/BreakpointController.h new file mode 100644 index 0000000..fff8234 --- /dev/null +++ b/Panels/BreakpointController.h @@ -0,0 +1,43 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * BreakpointController.h - Class for maintaining breakpoints + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class BreakpointArray; + + +@interface BreakpointController : NSObject { +@private + IBOutlet NSTableView *tableView; + IBOutlet NSButton *addButton; + IBOutlet NSButton *deleteButton; + IBOutlet NSButton *enableAllButton; + IBOutlet NSButton *disableAllButton; + IBOutlet BreakpointArray *breakpoints; +} + +- (IBAction) addBreakpoint:(id)sender; +- (IBAction) deleteBreakpoint:(id)sender; +- (IBAction) disableAllBreakpoints:(id)sender; +- (IBAction) enableAllBreakpoints:(id)sender; + +@end diff --git a/Panels/BreakpointController.m b/Panels/BreakpointController.m new file mode 100644 index 0000000..43906f8 --- /dev/null +++ b/Panels/BreakpointController.m @@ -0,0 +1,228 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * BreakpointController.m - Class for maintaining breakpoints + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "BreakpointController.h" +#import "BreakpointArray.h" +#import "OctalFormatter.h" +#import "Utilities.h" + + +@implementation BreakpointController + + +/* ADDRESS_COLUMN is the identifier of the address column. The other checkbox + columns must be identified with integers representing the bit mask for the + enabled bit in the breakpoints enable bit mask, i. e. 1, 2, 4, 8,... + Then ALL_BREAKPOINTS is the mask for "all columns enabled". */ + +#define ADDRESS_COLUMN 0 +#define ALL_BREAKPOINTS ((1 << ([tableView numberOfColumns] - 1)) - 1) + + +/* #defines for the cases where the instance must know if it is the + breakpoints or break opcodes controller */ + +#define IS_BREAKPOINT_CONTROLLER ([tableView numberOfColumns] == 2) +#define IS_BREAKOPCODE_CONTROLLER ([tableView numberOfColumns] == 3) + +#define MAX_ADDRESS (IS_BREAKPOINT_CONTROLLER ? 077777 : 07777) + +#define BREAKPOINT_COLUMN 1 +#define USER_BREAKOPCODE_COLUMN 1 +#define SYSTEM_BREAKOPCODE_COLUMN 2 + + +- (void) notifyUpdateBreakpointView:(NSNotification *)notification +{ + // NSLog (@"BreakpointController notifyUpdateBreakpointView"); + [enableAllButton setEnabled:[breakpoints hasBreakpointWithValueNotEqualTo:ALL_BREAKPOINTS]]; + [disableAllButton setEnabled:[breakpoints hasBreakpointWithValueNotEqualTo:0]]; + [tableView reloadData]; +} + + +- (IBAction) addBreakpoint:(id)sender +{ + [[sender window] makeKeyWindow]; + [breakpoints setBreakpointWithIdentifier:0 value:ALL_BREAKPOINTS]; + [tableView selectRowIndexes:[NSIndexSet indexSetWithIndex:0] byExtendingSelection:NO]; + [tableView editColumn:[tableView columnWithIdentifier: + [NSString stringWithFormat:@"%d", ADDRESS_COLUMN]] + row:0 withEvent:nil select:YES]; +} + + +- (IBAction) deleteBreakpoint:(id)sender +{ + int selectedRow = [tableView selectedRow]; + [tableView reloadData]; // when editing, this saves the edited cell that will be deleted + [breakpoints deleteBreakpointsAtIndexes:[tableView selectedRowIndexes]]; + // reselect old row, otherwise selection jumps to the position of the edited but deleted breakpoint + [tableView selectRowIndexes:[NSIndexSet indexSetWithIndex:selectedRow] byExtendingSelection:NO]; +} + + +- (IBAction) enableAllBreakpoints:(id)sender +{ + [breakpoints setAllValues:ALL_BREAKPOINTS]; +} + + +- (IBAction) disableAllBreakpoints:(id)sender +{ + [breakpoints setAllValues:0]; +} + + +- (void) tableViewSelectionDidChange:(NSNotification *)notification +{ + [deleteButton setEnabled:[tableView numberOfSelectedRows] != 0]; +} + + +- (int) numberOfRowsInTableView:(NSTableView *)tableView +{ + return [breakpoints numberOfBreakpoints]; +} + + +- (id) tableView:(NSTableView *)tableView + objectValueForTableColumn:(NSTableColumn *)column row:(int)row +{ + int columnID = [[column identifier] intValue]; + return columnID == ADDRESS_COLUMN ? + [NSNumber numberWithInt:[breakpoints identifierAtIndex:row]] : + [NSNumber numberWithBool:[breakpoints valueAtIndex:row] & columnID]; +} + + +- (void) tableView:(NSTableView *)tabView setObjectValue:(id)object + forTableColumn:(NSTableColumn *)column row:(int)row +{ + int columnID = [[column identifier] intValue]; + if (columnID == ADDRESS_COLUMN) { + [breakpoints deleteBreakpointAtIndex:row]; + if ([object isKindOfClass:[NSNumber class]]) + [tableView selectRowIndexes:[NSIndexSet indexSetWithIndex: + [breakpoints setBreakpointWithIdentifier:[object intValue] + value:ALL_BREAKPOINTS]] + byExtendingSelection:NO]; + else { + NSIndexSet *index = [breakpoints setBreakpointsWithIdentifierArray:object + value:ALL_BREAKPOINTS]; + [tableView selectRowIndexes:index byExtendingSelection:NO]; + row = [index firstIndex]; + } + [tableView editColumn:0 row:0 withEvent:nil select:NO]; + // [tableView abortEditing] does not work, so edit an invalid cell + [tableView scrollRowToVisible:row]; + [tableView reloadData]; + [enableAllButton setEnabled:[breakpoints hasBreakpointWithValueNotEqualTo:ALL_BREAKPOINTS]]; + [disableAllButton setEnabled:[breakpoints hasBreakpointWithValueNotEqualTo:0]]; + } else { + unsigned value = [breakpoints valueAtIndex:row]; + if ([[NSApp currentEvent] modifierFlags] & NSAlternateKeyMask) + value = value ? 0 : ALL_BREAKPOINTS; + else + value = (value & columnID) ? (value & ~columnID) : (value | columnID); + [breakpoints setBreakpointWithIdentifier:[breakpoints identifierAtIndex:row] value:value]; + } +} + + +- (NSString *) tableView:(NSTableView *)tabView toolTipForCell:(NSCell *)cell + rect:(NSRectPointer)rect tableColumn:(NSTableColumn *)column row:(int)row + mouseLocation:(NSPoint)mouseLocation +{ + switch ([[column identifier] intValue]) { + case ADDRESS_COLUMN : + return IS_BREAKPOINT_CONTROLLER ? + NSLocalizedString( + @"Address where the PDP-8 halts when the breakpoint is enabled", @"") : + NSLocalizedString( + @"Opcode that causes the PDP-8 to halt when enabled for the current mode", @""); + case BREAKPOINT_COLUMN | USER_BREAKOPCODE_COLUMN : + return IS_BREAKPOINT_CONTROLLER ? + NSLocalizedString(@"Enables or disables this breakpoint", @"") : + NSLocalizedString(@"Enables or disables this break opcode for PDP-8 user mode " + @"(option-click to set user and system mode simultaneously)", @""); + case SYSTEM_BREAKOPCODE_COLUMN : + return NSLocalizedString(@"Enables or disables this break opcode for PDP-8 system mode " + @"(option-click to set user and system mode simultaneously)", @""); + + default : + NSAssert (FALSE, @"Unknown column in BreakpointControllers table view"); + break; + } + return nil; +} + + +- (BOOL) control:(NSControl *)control didFailToFormatString:(NSString *)string + errorDescription:(NSString *)error +{ + [control abortEditing]; + NSAlert *alert = [[NSAlert alloc] init]; + [alert setMessageText:error]; + [alert beginSheetModalForWindow:[control window] modalDelegate:self + didEndSelector:nil contextInfo:nil]; + [alert release]; + return NO; +} + + +- (void) awakeFromNib +{ + NSCell *dataCell = [[tableView tableColumnWithIdentifier: + [NSString stringWithFormat:@"%d", ADDRESS_COLUMN]] dataCell]; + [dataCell setFormatter:[OctalFormatter formatterWithBitMask:MAX_ADDRESS wildcardAllowed:YES]]; + [dataCell setFont:[NSFont userFixedPitchFontOfSize:11]]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyUpdateBreakpointView:) + name:BREAKPOINTS_CHANGED_NOTIFICATION object:breakpoints]; + /* set max width = min width of the panel: IB only allows max width one pixel more + than min width, so the user can resize the width for one pixel - bug in IB? */ + NSSize size = [[tableView window] minSize]; + size.height = [[tableView window] maxSize].height; + [[tableView window] setMaxSize:size]; + if (runningOnLionOrNewer()) { // move the + and - button title one pixel up + NSMutableParagraphStyle *style= [[[NSMutableParagraphStyle alloc] init] autorelease]; + [style setAlignment:NSCenterTextAlignment]; + NSDictionary *dict = [NSDictionary dictionaryWithObjectsAndKeys: + [NSNumber numberWithFloat:1], NSBaselineOffsetAttributeName, + style, NSParagraphStyleAttributeName, nil]; + [addButton setAttributedTitle: + [[[NSAttributedString alloc] initWithString:[addButton title] attributes:dict] autorelease]]; + [deleteButton setAttributedTitle: + [[[NSAttributedString alloc] initWithString:[deleteButton title] attributes:dict] autorelease]]; + } + adjustTableHeaderForElCapitan (tableView); +} + + +@end + + diff --git a/Panels/PreferencesController.h b/Panels/PreferencesController.h new file mode 100644 index 0000000..72bb6cf --- /dev/null +++ b/Panels/PreferencesController.h @@ -0,0 +1,36 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PreferencesController.h - Controller for the preferences panel + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define PREF_PANE_EXTENSION @"prefPane" + + +@interface PreferencesController : NSObject +{ +@private + IBOutlet NSPanel *prefPanel; + NSArray *prefPaneIdentifiers; + NSPreferencePane *currentPrefPane; +} + +@end diff --git a/Panels/PreferencesController.m b/Panels/PreferencesController.m new file mode 100644 index 0000000..cb900d1 --- /dev/null +++ b/Panels/PreferencesController.m @@ -0,0 +1,228 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PreferencesController.m - Controller for the preferences panel + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import +#import + +#import "PreferencesController.h" +#import "NSMutableArray+BinarySearch.h" + + +#define PREFS_PANEL_TOPLEFT_KEY @"PrefsPanel TopLeft" + + +@implementation NSBundle (OrderInPreferencesPanelToolbar) + + +- (NSComparisonResult) compareOrderInPreferencesPanelToolbarInfoPlistKey:(NSBundle *)bundle +{ + return [[self objectForInfoDictionaryKey:@"OrderInPreferencesPanelToolbar"] + compare:[bundle objectForInfoDictionaryKey:@"OrderInPreferencesPanelToolbar"]]; +} + + +@end + + +@implementation PreferencesController + + +#pragma mark Toolbar + + +- (void) setupToolbar +{ + NSToolbar *toolbar = [[[NSToolbar alloc] initWithIdentifier:@"PrefsPanelToolbar"] autorelease]; + [toolbar setAllowsUserCustomization:NO]; + [toolbar setAutosavesConfiguration:YES]; + [toolbar setDelegate:self]; + [prefPanel setToolbar:toolbar]; + [prefPanel setShowsToolbarButton:YES]; + [toolbar setSelectedItemIdentifier:[prefPaneIdentifiers objectAtIndex:0]]; +} + + +- (NSToolbarItem *) toolbar:(NSToolbar *)toolbar itemForItemIdentifier:(NSString *)identifier + willBeInsertedIntoToolbar:(BOOL)willBeInserted +{ + NSToolbarItem *toolbarItem = + [[[NSToolbarItem alloc] initWithItemIdentifier:identifier] autorelease]; + NSBundle *bundle = [NSBundle bundleWithIdentifier:identifier]; + [toolbarItem setLabel:[bundle objectForInfoDictionaryKey:@"NSPrefPaneIconLabel"]]; + [toolbarItem setImage:[[[NSImage alloc] initWithContentsOfFile:[bundle pathForResource: + [bundle objectForInfoDictionaryKey:@"NSPrefPaneIconFile"] ofType:nil]] autorelease]]; + [toolbarItem setTarget:self]; + [toolbarItem setAction:@selector(selectPreferencePane:)]; + return toolbarItem; +} + + +- (NSArray *) toolbarDefaultItemIdentifiers:(NSToolbar *)toolbar +{ + return prefPaneIdentifiers; +} + + +- (NSArray *) toolbarAllowedItemIdentifiers:(NSToolbar *)toolbar +{ + return prefPaneIdentifiers; +} + + +- (NSArray *) toolbarSelectableItemIdentifiers:(NSToolbar *)toolbar +{ + return prefPaneIdentifiers; +} + + +#pragma mark Initialization + + +- (void) findPrefPanesAtPath:(NSString *)path addToArray:(NSMutableArray *)array +{ + NSString *bundleName; + NSBundle *bundle; + + NSDirectoryEnumerator *bundlePathEnum = [[NSFileManager defaultManager] enumeratorAtPath:path]; + while ((bundleName = [bundlePathEnum nextObject])) { + if ([[bundleName pathExtension] isEqualToString:PREF_PANE_EXTENSION]) { + [bundlePathEnum skipDescendents]; + bundle = [NSBundle bundleWithPath:[path stringByAppendingPathComponent:bundleName]]; + if (bundle) + [array addObject:bundle toArraySortedBy: + @selector(compareOrderInPreferencesPanelToolbarInfoPlistKey:) + replaceExistingObject:YES]; + } + } +} + + +- (NSArray *) findPrefPanes +{ + NSEnumerator *enumerator; + NSBundle *bundle; + + NSMutableArray *prefPaneBundles = [NSMutableArray array]; + [self findPrefPanesAtPath:[[NSBundle mainBundle] sharedSupportPath] addToArray:prefPaneBundles]; + [self findPrefPanesAtPath:[[NSBundle mainBundle] builtInPlugInsPath] addToArray:prefPaneBundles]; + NSMutableArray *prefPaneIdents = [NSMutableArray array]; + enumerator = [prefPaneBundles objectEnumerator]; + while ((bundle = [enumerator nextObject])) + [prefPaneIdents addObject:[bundle bundleIdentifier]]; + return prefPaneIdents; +} + + +#pragma mark Pane Handling + + +- (void) resizeWindowForContentView:(NSView *)view +{ + NSRect windowFrame = + [NSPanel contentRectForFrameRect:[prefPanel frame] styleMask:[prefPanel styleMask]]; + float newWindowHeight = NSHeight([view frame]); + if ([[prefPanel toolbar] isVisible]) + newWindowHeight += NSHeight(windowFrame) - NSHeight([[prefPanel contentView] frame]); + NSRect newWindowFrame = [NSPanel frameRectForContentRect: + NSMakeRect(NSMinX(windowFrame), NSMaxY(windowFrame) - newWindowHeight, + NSWidth(windowFrame), newWindowHeight) styleMask:[prefPanel styleMask]]; + [prefPanel setFrame:newWindowFrame display:YES animate:[prefPanel isVisible]]; + } + + +- (void) selectPreferencePaneWithIdentifier:(NSString *)identifier +{ + if (currentPrefPane) { + if ([currentPrefPane shouldUnselect] != NSUnselectNow) { + NSLog (@"Handle pref pane unwilling to unselect"); + return; + } + [currentPrefPane willUnselect]; + [[currentPrefPane mainView] removeFromSuperview]; + [currentPrefPane didUnselect]; + [currentPrefPane release]; + currentPrefPane = nil; + } + NSBundle *prefBundle = [NSBundle bundleWithIdentifier:identifier]; + currentPrefPane = [[[prefBundle principalClass] alloc] initWithBundle:prefBundle]; + if ([currentPrefPane loadMainView]) { + [currentPrefPane willSelect]; + [self resizeWindowForContentView:[currentPrefPane mainView]]; + [prefPanel setContentView:[currentPrefPane mainView]]; + [prefPanel setTitle:[prefBundle objectForInfoDictionaryKey:@"PrefPaneWindowTitle"]]; + [currentPrefPane didSelect]; + [prefPanel setInitialFirstResponder:[currentPrefPane initialKeyView]]; + } else + NSLog (@"Pref pane loadMainView failed"); +} + + +- (IBAction) selectPreferencePane:(id)sender +{ + [[prefPanel toolbar] setSelectedItemIdentifier:[sender itemIdentifier]]; + [self selectPreferencePaneWithIdentifier:[sender itemIdentifier]]; +} + + +- (void) windowWillClose:(NSNotification *)notification +{ + [currentPrefPane willUnselect]; + [currentPrefPane didUnselect]; +} + + +- (void) windowDidMove:(NSNotification *)notificatin +{ + /* because of the panel resizing, we can't use the auto frame save feature */ + NSRect frame = [prefPanel frame]; + NSPoint topLeft = frame.origin; // bottom left + topLeft.y += NSHeight(frame); // top left + [[NSUserDefaults standardUserDefaults] setObject: + [NSString stringWithFormat:@"%f %f", topLeft.x, topLeft.y] forKey:PREFS_PANEL_TOPLEFT_KEY]; +} + + +- (void) windowDidBecomeKey:(NSNotification *)notification +{ + if (prefPaneIdentifiers == nil) { // initialization + prefPaneIdentifiers = [[self findPrefPanes] retain]; + [self setupToolbar]; + } + if (currentPrefPane == nil) { + [self selectPreferencePaneWithIdentifier:[prefPaneIdentifiers objectAtIndex:0]]; + NSString *str = [[NSUserDefaults standardUserDefaults] objectForKey:PREFS_PANEL_TOPLEFT_KEY]; + if (str) { // restore old panel position + NSScanner *scanner = [NSScanner scannerWithString:str]; + NSPoint topLeft; + if ([scanner scanFloat:&topLeft.x] && [scanner scanFloat:&topLeft.y]) + [prefPanel setFrameTopLeftPoint:topLeft]; + else + [prefPanel center]; + } else + [prefPanel center]; + } +} + + +@end diff --git a/Plugins/HelpMenuManager.h b/Plugins/HelpMenuManager.h new file mode 100644 index 0000000..bbd047c --- /dev/null +++ b/Plugins/HelpMenuManager.h @@ -0,0 +1,35 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * HelpMenuManager.h - Manager for Help menu items of plugins + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface HelpMenuManager : NSObject +{ +@private + NSMutableArray *registeredHelpBookDomains; +} + ++ (HelpMenuManager *) sharedHelpMenuManager; + +- (void) addBundleHelp:(NSBundle *)bundle; + +@end diff --git a/Plugins/HelpMenuManager.m b/Plugins/HelpMenuManager.m new file mode 100644 index 0000000..4f87f1b --- /dev/null +++ b/Plugins/HelpMenuManager.m @@ -0,0 +1,167 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * HelpMenuManager.m - Manager for Help menu items of plugins + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "Utilities.h" +#import "HelpMenuManager.h" +#import "NSFileManager+Additions.h" + + +@implementation HelpMenuManager + + ++ (HelpMenuManager *) sharedHelpMenuManager +{ + static HelpMenuManager *sharedHelpMenuManager; + + if (! sharedHelpMenuManager) + sharedHelpMenuManager = [[self alloc] init]; + return sharedHelpMenuManager; +} + + +- (HelpMenuManager *) init +{ + self = [super init]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; + registeredHelpBookDomains = [[NSMutableArray alloc] initWithCapacity:10]; + return self; +} + + +- (void) unregisterHelpBookForDomain:(NSString *)domain +// see http://lists.apple.com/archives/carbon-development/2003/Nov/msg00090.html +{ + NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; + NSMutableDictionary *dict = [NSMutableDictionary dictionaryWithDictionary: + [defaults persistentDomainForName:@"com.apple.help"]]; + [dict removeObjectForKey:domain]; + [defaults setPersistentDomain:dict forName:@"com.apple.help"]; +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + NSString *domain; + + NSEnumerator *enumerator = [registeredHelpBookDomains objectEnumerator]; + while ((domain = [enumerator nextObject])) + [self unregisterHelpBookForDomain:domain]; +} + + +- (NSString *) helpUrlForId:(NSString *)id +// extract the URL of the help page from ~/Library/Preferences/com.apple.help.plist (Lion and better) +// for Lion and Mountain Lion, the ID is the title of the help book +// for Mavericks, the ID is the bundle identifier of the plugin containing the help book +{ + NSArray *array; + + NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; + NSDictionary *dict = [defaults persistentDomainForName:@"com.apple.help"]; + + dict = [dict valueForKey:@"RegisteredBooks"]; + NSEnumerator *enumerator = [dict objectEnumerator]; + while ((array = [enumerator nextObject])) { + dict = [array objectAtIndex:0]; + if ([id isEqualToString:[dict objectForKey:@"id"]]) + return [NSString stringWithFormat:@"%@index.html", [dict objectForKey:@"url"]]; + } + return nil; +} + + +- (void) openHelpUrl:(NSString *)url +// open the HelpViewer.app via AppleScript with the "handle URL" command (Lion only) +{ + NSString *source = [NSString stringWithFormat: + @"tell app \"HelpViewer\"\nactivate\nhandle URL \"%@\"\nend tell", url]; + NSAppleScript *script = [[[NSAppleScript alloc] initWithSource:source] autorelease]; + NSDictionary *error = nil; + [script executeAndReturnError:&error]; + if (error) + NSLog (@"AppleScript error while opening HelpViewer: %@", error); +} + + +- (void) showHelp:(id)sender +{ + NSString *title = [sender title]; + + if (runningOnLionOrNewer()) + // Help book lookup does not work as before, don't know why. + // We now use AppleScript to open HelpViewer with the URL of the help page. + [self openHelpUrl:[self helpUrlForId:(runningOnMavericksOrNewer() ? + [sender representedObject] : title)]]; + else + AHGotoPage (title, NULL, NULL); +} + + +- (void) addHelpMenuItem:(NSString *)title id:(NSString *)id +{ + NSMenu *helpMenu = [[[NSApp mainMenu] itemWithTitle:NSLocalizedString(@"Help", @"")] submenu]; + int n = [helpMenu numberOfItems]; + int i; + for (i = 1; i < n; i++) { + switch ([[[helpMenu itemAtIndex:i] title] compare:title]) { + case NSOrderedSame : + n = -1; + break; + case NSOrderedDescending : + n = i; + break; + default : + break; + } + } + if (n > 0) { + NSMenuItem *item = [helpMenu insertItemWithTitle:title action:@selector(showHelp:) + keyEquivalent:@"" atIndex:n]; + [item setTarget:self]; + [item setRepresentedObject:id]; + } +} + + +- (void) addBundleHelp:(NSBundle *)bundle +{ + FSRef fsRef; + + if ([[NSFileManager defaultManager] fsRef:&fsRef forPath:[bundle bundlePath]]) { + [self unregisterHelpBookForDomain:[bundle bundleIdentifier]]; + if (AHRegisterHelpBook(&fsRef) == noErr) { + [registeredHelpBookDomains addObject:[bundle bundleIdentifier]]; + NSString *bookTitle = [[bundle infoDictionary] objectForKey:@"CFBundleHelpBookName"]; + if (bookTitle) + [self addHelpMenuItem:bookTitle id:[bundle bundleIdentifier]]; + } + } +} + + +@end diff --git a/Plugins/Info.plist b/Plugins/Info.plist new file mode 100644 index 0000000..348a326 --- /dev/null +++ b/Plugins/Info.plist @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + PluginFramework + CFBundleIdentifier + de.bernhard-baehr.pdp8e.PluginFramework + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + FMWK + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + CFBundleShortVersionString + 2.0.2 + + diff --git a/Plugins/PluginAPI.h b/Plugins/PluginAPI.h new file mode 100644 index 0000000..6489025 --- /dev/null +++ b/Plugins/PluginAPI.h @@ -0,0 +1,93 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PluginAPI.h - Plugin API Definitions for PDP-8/E I/O Device Plugins + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define PLUGIN_API_VERSION_0 0 +#define CURRENT_PLUGIN_API_VERSION PLUGIN_API_VERSION_0 // see apiVersion method, below +#define API_VERSION - (unsigned) apiVersion { \ + LOG_ASSERTING (); \ + return CURRENT_PLUGIN_API_VERSION; \ + } + + +#define DEFAULT_IO_INFO_FILENAME @"io-info" // see iotInformationPlistName method + // keys in this property list: +#define IO_INFO_IOFLAGS_KEY @"ioflags" // an array of I/O flag names in the plist +#define IO_INFO_IOADDRESSES_KEY @"ioaddresses" // an array of I/O addresses in the plist +#define IO_INFO_IOTS_KEY @"iots" // an array of IOT mnemonics in the plist + + +/* Notification that is posted after all plugins are loaded. Plugins are loaded on the + NSApplicationWillFinishLaunchingNotification, then on the NSApplicationDidFinishLaunchingNotification, + the PLUGINS_LOADED_NOTIFICATION is posted. Use this notification e. g. to make plugin windows visible + to avoid screen flicker. */ +#define PLUGINS_LOADED_NOTIFICATION @"PluginsLoadedNotification" + + +@class PDP8; + + +@interface PDP8Plugin : NSObject +{ +@private + NSBundle *bundle; +@protected + PDP8 *pdp8; +} + +- (void) setPDP8:(PDP8 *)p8; // gives the plugin a pointer to the global PDP-8 object +- (unsigned) apiVersion; // get the API compiletime version, you must define this + // method in your implementation with the API_VERSION macro, above +- (NSBundle *) bundle; // returns the plugin bundle private variable +- (void) setBundle:(NSBundle *)bndl; // sets the plugin bundle private variable +- (NSString *) pluginName; // returns the plugin name, i. e. file system name of the bundle +- (void *) pluginPointer; // returns a pointer of the plugin instance that can be accessed + // by the IOT functions via the PLUGIN_POINTER macro from pdp8.h + // useful for multiinstance plugins to access the correct instance +- (NSString *) ioInformationPlistName; // returns the name (in the localizable resources directory) + // for the property list that contains the I/O flag and IOT info +- (NSDictionary *) ioInformation; // returns a dictionary with information about I/O flags and IOTs +- (NSArray *) iotsForAddress:(int)ioAddress; + // get 8 IOTs for an I/O address (nil for unused) +- (NSArray *) skiptestsForAddress:(int)ioAddress; + // get 8 skiptests for an I/O address (nil for unused) + // called after the iotsForAddress method +- (void) setIOFlag:(unsigned long)flag forIOFlagName:(NSString *)name; + // called for each I/O flag name from the property list in that order +- (void) loadNibs; // called after it is known that the I/O device fits into the PDP-8, + // called after the methods above, so they must not access resources + // from nibs +- (void) pluginDidLoad; // called after the plugin has loaded and the PDP-8, the IOTs and + // I/O flags have been setup and the nibs are loaded +- (void) CAF:(int)ioAddress; // called when the CPU performs the CAF instruction; must not update + // the GUI e. g. by sending notifications; is called from non-main + // thread) (note: for devices without I/O adresses, it is not called) +- (void) clearAllFlags:(int)ioAddress; // called when the user operates the Clear key of the KC8-EA console + // (or the equivalent menu item); is called from main thread and must + // update the GUI e. g. by sending notifications + // (note: for devices without I/O addresses, it is not called, but + // you can listen for the CLEAR_ALL_FLAGS_NOTIFICAITON) +- (void) resetDevice; // called when the user resets the simulator (might be nearly + // the same as clearAllFlags:) + +@end diff --git a/Plugins/PluginAPI.m b/Plugins/PluginAPI.m new file mode 100644 index 0000000..6e5b776 --- /dev/null +++ b/Plugins/PluginAPI.m @@ -0,0 +1,149 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PluginAPI.m - Plugin API Definitions for PDP-8/E I/O Device Plugins + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginAPI.h" +#import "Utilities.h" + + +@implementation PDP8Plugin + + +PDP8 *pdp8; // plugin local pdp8 variable for the IOT functions + + +static void setPDP8 (PDP8 *p8) +{ + pdp8 = p8; // set the plugin local pdp8 variable for the IOT function +} + + +- (void) setPDP8:(PDP8 *)p8 +{ + pdp8 = p8; // set the class variable pdp8 + setPDP8 (p8); +} + + +- (unsigned) apiVersion +{ + [[NSAssertionHandler currentHandler] handleFailureInMethod:_cmd object:self + file:[NSString stringWithCString:__FILE__] lineNumber:__LINE__ + description:NSLocalizedString( + @"Your plugin must override the apiVersion method using the API_VERSION macro.", + @"")]; + return CURRENT_PLUGIN_API_VERSION; +} + + +- (NSBundle *) bundle +{ + return bundle; +} + + +- (void) setBundle:(NSBundle *)bndl +{ + bundle = bndl; +} + + +- (NSString *) pluginName +{ + return [[bundle bundlePath] lastPathComponent]; +} + + +- (void *) pluginPointer +{ + return (void *) self; +} + + +- (NSString *) ioInformationPlistName +{ + return DEFAULT_IO_INFO_FILENAME; +} + + +- (NSDictionary *) ioInformation +{ + return [NSDictionary dictionaryWithContentsOfFile: + [bundle pathForResource:[self ioInformationPlistName] ofType:@"plist"]]; +} + + +- (NSArray *) iotsForAddress:(int)ioAddress +{ + return nil; +} + + +- (NSArray *) skiptestsForAddress:(int)ioAddress +{ + return nil; +} + + +- (void) setIOFlag:(unsigned long)flag forIOFlagName:(NSString *)name; +{ +} + + +- (void) loadNibs +{ + NSString *resourceName; + + NSString *resourcePath = [[NSBundle bundleForClass:[self class]] resourcePath]; + NSDirectoryEnumerator *resourcePathEnum = + [[NSFileManager defaultManager] enumeratorAtPath:resourcePath]; + while (resourcePathEnum && (resourceName = [resourcePathEnum nextObject])) { + if ([[resourceName pathExtension] isEqualToString:@"nib"]) + [NSBundle loadNibNamed:[resourceName lastPathComponent] owner:self]; + } +} + + +- (void) pluginDidLoad +{ +} + + +- (void) CAF:(int)ioAddress +{ +} + + +- (void) clearAllFlags:(int)ioAddress +{ +} + + +- (void) resetDevice +{ +} + + +@end diff --git a/Plugins/PluginManager.h b/Plugins/PluginManager.h new file mode 100644 index 0000000..646c791 --- /dev/null +++ b/Plugins/PluginManager.h @@ -0,0 +1,39 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PluginManager.h - Manager for I/O Device Plugins + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class PDP8, SkipController, IOFlagController; + + +@interface PluginManager : NSObject +{ +@private + IBOutlet PDP8 *pdp8; + IBOutlet SkipController *skipController; + IBOutlet IOFlagController *ioFlagController; + NSArray *pluginInstances; +} + +- (void) resetAllDevices; + +@end diff --git a/Plugins/PluginManager.m b/Plugins/PluginManager.m new file mode 100644 index 0000000..d08d199 --- /dev/null +++ b/Plugins/PluginManager.m @@ -0,0 +1,280 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PluginManager.m - Manager for I/O Device Plugins + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginManager.h" +#import "PluginAPI.h" +#import "PDP8.h" +#import "SkipController.h" +#import "IOFlagController.h" +#import "Assembler.h" +#import "Disassembler.h" +#import "OctalFormatter.h" +#import "HelpMenuManager.h" +#import "Unicode.h" +#import "NSFileManager+Additions.h" + + +#define PLUGIN_EXTENSION @"pdp8Plugin" +#define PLUGIN_APPSUPPORT_PATH @"Application Support/PDP-8:E Simulator" +#define PLUGIN_NEXTTOAPP_PATH @"../PDP-8:E Simulator Plugins" + + +@implementation PluginManager + + +- (BOOL) canInstallIOTs:(NSArray *)mnemonics withIOAddresses:(NSArray *)ioAddresses + noLoadMessage:(NSString *)noLoadMessage +{ + NSString *ioAddress; + + if (! mnemonics || ! [mnemonics isKindOfClass:[NSArray class]]) { + NSRunAlertPanel (NSLocalizedString( + @"Invalid IOT information in the I/O description of the plug-in", @""), + noLoadMessage, nil, nil, nil); + return NO; + } + if (! ioAddresses || ! [ioAddresses isKindOfClass:[NSArray class]]) { + NSRunAlertPanel (NSLocalizedString( + @"Invalid I/O address information in the I/O description of the plug-in.", @""), + noLoadMessage, nil, nil, nil); + return NO; + } + if ([mnemonics count] != 8 * [ioAddresses count]) { + NSRunAlertPanel (NSLocalizedString( + @"The number of IOTs does not match number of I/O addresses in the I/O description " + "of the plug-in.", @""), noLoadMessage, nil, nil, nil); + return NO; + } + NSEnumerator *enumerator = [ioAddresses objectEnumerator]; + while ((ioAddress = [enumerator nextObject])) { + NSNumber *number; + if (! [[OctalFormatter formatterWithBitMask:077 wildcardAllowed:NO] getObjectValue:&number + forString:ioAddress errorDescription:nil]) { + NSRunAlertPanel ([NSString stringWithFormat:NSLocalizedString( + @"Invalid I/O address %C%@%C in the I/O description of the plug-in.", + @""), UNICODE_LEFT_DOUBLEQUOTE, ioAddress, UNICODE_RIGHT_DOUBLEQUOTE], + noLoadMessage, nil, nil, nil); + return NO; + } + int addr = [number intValue]; + if (! [pdp8 isIOAddressAvailable:addr]) { + NSRunAlertPanel ([NSString stringWithFormat:NSLocalizedString( + @"The I/O address %2.2o requested by the plug-in is already in use.", @""), + addr], noLoadMessage, nil, nil, nil); + return NO; + } + } + return YES; +} + + +- (void) installIOTs:(NSArray *)mnemonics withAddresses:(NSArray *)ioAddresses forPlugin:(PDP8Plugin *)plugin +{ + int i; + NSString *ioAddress; + + int base = 0; + NSEnumerator *ioAddrEnum = [ioAddresses objectEnumerator]; + while ((ioAddress = [ioAddrEnum nextObject])) { + NSNumber *number; + [[OctalFormatter formatterWithBitMask:077 wildcardAllowed:NO] getObjectValue:&number + forString:ioAddress errorDescription:nil]; + int addr = [number intValue]; + [pdp8 setPluginPointer:plugin forIOAddress:addr]; + NSArray *iots = [plugin iotsForAddress:addr]; + if (iots) { + NSArray *skiptests = [plugin skiptestsForAddress:addr]; + int opcode = 06000 | (addr << 3); + for (i = 0; i < 8; i++) { + NSValue *iot = [iots objectAtIndex:i]; + [pdp8 setIOT:iot forOpcode:opcode | i]; + NSValue *skiptest = skiptests ? [skiptests objectAtIndex:i] : nil; + [skipController addSkiptest:skiptest forInstruction:iot]; + NSString *mnemonic = [mnemonics objectAtIndex:base + i]; + [[Assembler sharedAssembler] addMnemonic:mnemonic forIOT:opcode | i]; + [[Disassembler sharedDisassembler] addMnemonic:mnemonic forIOT:opcode | i]; + } + } + base += 8; + } +} + + +- (BOOL) canInstallIOFlags:(NSArray *)ioFlags noLoadMessage:(NSString *)noLoadMessage +{ + if (! ioFlags || ! [ioFlags isKindOfClass:[NSArray class]]) { + NSRunAlertPanel (NSLocalizedString( + @"Invalid I/O flag information in the I/O description of the plug-in.", @""), + noLoadMessage, nil, nil, nil); + return NO; + } + if ([ioFlags count] > [ioFlagController numberOfAvailableFlags]) { + NSRunAlertPanel (NSLocalizedString(@"There are not enough I/O flags available.", @""), + noLoadMessage, nil, nil, nil); + return NO; + } + return YES; +} + + +- (void) installIOFlags:(NSArray *)ioFlags forPlugin:(PDP8Plugin *)plugin +{ + NSString *ioFlagName; + + NSEnumerator *enumerator = [ioFlags objectEnumerator]; + while ((ioFlagName = [enumerator nextObject])) + [plugin setIOFlag:[ioFlagController addIODevice:ioFlagName] forIOFlagName:ioFlagName]; +} + + +- (void) resetAllDevices +{ + PDP8Plugin *plugin; + + NSEnumerator *enumerator = [pluginInstances objectEnumerator]; + while ((plugin = [enumerator nextObject])) + [plugin resetDevice]; +} + + +- (NSString *) noLoadMessage:(NSString *)pluginName +{ + return [NSString stringWithFormat:NSLocalizedString(@"The plug-in %C%@%C will not be loaded.", @""), + UNICODE_LEFT_DOUBLEQUOTE, pluginName, UNICODE_RIGHT_DOUBLEQUOTE]; +} + + +- (PDP8Plugin *) loadPlugin:(NSBundle *)bundle +{ + PDP8Plugin *plugin = nil; + Class principalClass = [bundle principalClass]; + if (principalClass && [principalClass isSubclassOfClass:[PDP8Plugin class]]) { + plugin = [[principalClass alloc] init]; + if (plugin) { + [plugin apiVersion]; // plugin must overrides this method, otherwise we crash + [plugin setBundle:bundle]; + [plugin setPDP8:pdp8]; + NSDictionary *ioInfo = [plugin ioInformation]; + NSArray *ioFlagNames = [ioInfo objectForKey:IO_INFO_IOFLAGS_KEY]; + NSArray *ioAddresses = [ioInfo objectForKey:IO_INFO_IOADDRESSES_KEY]; + NSArray *mnemonics = [ioInfo objectForKey:IO_INFO_IOTS_KEY]; + if ([self canInstallIOFlags:ioFlagNames + noLoadMessage:[self noLoadMessage:[plugin pluginName]]] && + [self canInstallIOTs:mnemonics withIOAddresses:ioAddresses + noLoadMessage:[self noLoadMessage:[plugin pluginName]]]) { + [self installIOFlags:[ioInfo objectForKey:IO_INFO_IOFLAGS_KEY] + forPlugin:plugin]; + [self installIOTs:mnemonics withAddresses:ioAddresses forPlugin:plugin]; + [plugin loadNibs]; + [plugin pluginDidLoad]; + [[HelpMenuManager sharedHelpMenuManager] addBundleHelp:bundle]; + } else { + [plugin release]; + // unload is a 10.5 method (does nothing on 10.4), but we use the 10.4 SDK + // so use performSelector: to avoid unknown message warning + [bundle performSelector:@selector(unload)]; + return nil; + } + } else { + NSRunAlertPanel (NSLocalizedString(@"Cannot instantiate the plug-in.", @""), + [self noLoadMessage:[[bundle bundlePath] lastPathComponent]], nil, nil, nil); + } + } else { + NSRunAlertPanel (principalClass ? + NSLocalizedString(@"The plug-in has an invalid principal class.", @"") : + NSLocalizedString(@"Cannot determine the principal class of the plug-in.", @""), + [self noLoadMessage:[[bundle bundlePath] lastPathComponent]], nil, nil, nil); + + } + return [plugin autorelease]; +} + + +- (NSArray *) loadAllPlugins +{ + NSEnumerator *searchPathEnum; + NSString *path; + NSString *bundleName; + + NSMutableArray *bundleSearchPaths = [NSMutableArray array]; + NSMutableArray *plugins = [NSMutableArray array]; + + searchPathEnum = [NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, + NSAllDomainsMask - NSSystemDomainMask, YES) objectEnumerator]; + while ((path = [searchPathEnum nextObject])) + [bundleSearchPaths addObject:[path stringByAppendingPathComponent:PLUGIN_APPSUPPORT_PATH]]; + [bundleSearchPaths addObject:[[[NSBundle mainBundle] bundlePath] + stringByAppendingPathComponent:PLUGIN_NEXTTOAPP_PATH]]; + [bundleSearchPaths addObject:[[NSBundle mainBundle] builtInPlugInsPath]]; + searchPathEnum = [bundleSearchPaths objectEnumerator]; + while ((path = [searchPathEnum nextObject])) { + NSDirectoryEnumerator *bundlePathEnum = + [[NSFileManager defaultManager] enumeratorAtPath:path]; + while (bundlePathEnum && (bundleName = [bundlePathEnum nextObject])) { + [bundlePathEnum skipDescendents]; + if ([[bundleName pathExtension] isEqualToString:PLUGIN_EXTENSION]) { + NSBundle *bundle = [NSBundle bundleWithPath: + [[NSFileManager defaultManager] resolveAliasPath: + [path stringByAppendingPathComponent:bundleName]]]; + if (bundle) { + PDP8Plugin *plugin = [self loadPlugin:bundle]; + if (plugin) + [plugins addObject:plugin]; + } else + NSRunAlertPanel ( + NSLocalizedString(@"Loading of the plug-in bundle failed.", + @""), [self noLoadMessage:bundleName], nil, nil, nil); + } + } + } + return plugins; +} + + +- (void) notifyApplicationWillFinishLaunching:(NSNotification *)notification +{ + pluginInstances = [[self loadAllPlugins] retain]; +} + + +- (void) notifyApplicationDidFinishLaunching:(NSNotification *)notification +{ + [[NSNotificationCenter defaultCenter] postNotificationName:PLUGINS_LOADED_NOTIFICATION object:nil]; +} + + +- (void) awakeFromNib +{ + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillFinishLaunching:) + name:NSApplicationWillFinishLaunchingNotification object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationDidFinishLaunching:) + name:NSApplicationDidFinishLaunchingNotification object:nil]; +} + + +@end diff --git a/RK8E/English.lproj/InfoPlist.strings b/RK8E/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..d7c9dcd --- /dev/null +++ b/RK8E/English.lproj/InfoPlist.strings @@ -0,0 +1,28 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InfoPlist.strings - Localized strings for Info.plist + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +CFBundleName = "RK8-E Disk Cartridge System"; +CFBundleGetInfoString = "RK8-E Disk Cartridge System 2.0.2, Copyright © 1994-2015 Bernhard Baehr"; +NSHumanReadableCopyright = "Copyright © 1994-2015 Bernhard Baehr"; +CFBundleHelpBookName = "RK8-E Disk Cartridge System Help"; \ No newline at end of file diff --git a/RK8E/English.lproj/RK8E.nib/designable.nib b/RK8E/English.lproj/RK8E.nib/designable.nib new file mode 100644 index 0000000..20b1afc --- /dev/null +++ b/RK8E/English.lproj/RK8E.nib/designable.nib @@ -0,0 +1,4652 @@ + + + + 1040 + 13E28 + 851 + 1265.21 + 698.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + RK8E + + + FirstResponder + + + NSApplication + + + 4103 + 2 + {{31, 363}, {624, 352}} + 1677721600 + RK8-E Disk Cartridge System + KeepInMenuWindow + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + + + 256 + + + + 268 + + + + 274 + + + + 268 + {{173, 233}, {57, 22}} + + 264 + YES + + -2076180416 + 133120 + + LucidaGrande + 11 + 3088 + + + 109199360 + 1 + + + 400 + 75 + + + No + + 1048576 + 2147483647 + 1 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + _popUpItemAction: + + + YES + + OtherViews + + + + + Yes + + 1048576 + 2147483647 + + + _popUpItemAction: + 1 + + + + + 1 + YES + YES + 1 + + NO + + + + 268 + {{14, 260}, {60, 17}} + + YES + + 67108928 + 4326400 + Function + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + NO + 1 + + + + 268 + {{184, 108}, {46, 22}} + + 256 + YES + + -2076180416 + 133120 + + + 109199360 + 1 + + + 400 + 75 + + + 0 + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + + + YES + + OtherViews + + + + + 1 + + 1048576 + 2147483647 + + + _popUpItemAction: + 1 + + + + + 1 + YES + YES + 1 + + NO + + + + 268 + {{14, 110}, {108, 17}} + + YES + + 67108928 + 4326400 + Block Number MSB + + + + + + NO + 1 + + + + 268 + {{14, 185}, {77, 17}} + + YES + + 67108928 + 4326400 + Block Length + + + + + + NO + 1 + + + + 268 + {{14, 235}, {129, 17}} + + YES + + 67108928 + 4326400 + Interupt on Done Flag + + + + + + NO + 1 + + + + 268 + {{120, 258}, {110, 22}} + + 1801 + YES + + -2076180416 + 133120 + + + 109199360 + 1 + + + 400 + 75 + + + Read + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + + + YES + + OtherViews + + + + + Read All + + 1048576 + 2147483647 + + + _popUpItemAction: + 1 + + + + + Lock + + 1048576 + 2147483647 + + + _popUpItemAction: + 2 + + + + + Seek + + 1048576 + 2147483647 + + + _popUpItemAction: + 3 + + + + + Write + + 1048576 + 2147483647 + + + _popUpItemAction: + 4 + + + + + Write All + + 1048576 + 2147483647 + + + _popUpItemAction: + 5 + + + + + No Operation + + 1048576 + 2147483647 + + + _popUpItemAction: + 6 + + + + + No Operation + + 1048576 + 2147483647 + + + _popUpItemAction: + 7 + + + + + 1 + YES + YES + 1 + + NO + + + + 268 + {{184, 133}, {46, 22}} + + 769 + YES + + -2076180416 + 133120 + + + 109199360 + 1 + + + 400 + 75 + + + 0 + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + + + YES + + OtherViews + + + + + 1 + + 1048576 + 2147483647 + + + _popUpItemAction: + 1 + + + + + 2 + + 1048576 + 2147483647 + + + _popUpItemAction: + 2 + + + + + 3 + + 1048576 + 2147483647 + + + _popUpItemAction: + 3 + + + + + 1 + YES + YES + 1 + + NO + + + + 268 + {{14, 160}, {151, 17}} + + YES + + 67108928 + 4326400 + Extended Memory Address + + + + + + NO + 1 + + + + 268 + {{184, 158}, {46, 22}} + + 1795 + YES + + -2076180416 + 133120 + + + 109199360 + 1 + + + 400 + 75 + + + 0 + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + + + YES + + OtherViews + + + + + 1 + + 1048576 + 2147483647 + + + _popUpItemAction: + 1 + + + + + 2 + + 1048576 + 2147483647 + + + _popUpItemAction: + 2 + + + + + 3 + + 1048576 + 2147483647 + + + _popUpItemAction: + 3 + + + + + 4 + + 1048576 + 2147483647 + + + _popUpItemAction: + 4 + + + + + 5 + + 1048576 + 2147483647 + + + _popUpItemAction: + 5 + + + + + 6 + + 1048576 + 2147483647 + + + _popUpItemAction: + 6 + + + + + 7 + + 1048576 + 2147483647 + + + _popUpItemAction: + 7 + + + + + 1 + YES + YES + 1 + + NO + + + + 268 + {{14, 135}, {77, 17}} + + YES + + 67108928 + 4326400 + Drive Select + + + + + + NO + 1 + + + + 268 + {{109, 183}, {121, 22}} + + 262 + YES + + -2076180416 + 133120 + + + 109199360 + 1 + + + 400 + 75 + + + Half Block + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + 1 + + + YES + + OtherViews + + + + Complete Block + + 1048576 + 2147483647 + + + _popUpItemAction: + + + + + + 1 + 1 + YES + YES + 1 + + NO + + + + 268 + {{251, 181}, {145, 18}} + + 128 + YES + + 67108864 + 131072 + File not Ready + + + 1211912448 + 2 + + NSImage + NSSwitch + + + NSSwitch + + + + 200 + 25 + + NO + + + + 268 + {{251, 161}, {145, 18}} + + 64 + YES + + 67108864 + 131072 + Control Busy + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 201}, {145, 18}} + + 256 + YES + + 67108864 + 131072 + Seek Failed + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 61}, {145, 18}} + + 2 + YES + + 67108864 + 131072 + Drive Status Error + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 241}, {145, 18}} + + 1024 + YES + + 67108864 + 131072 + Head in Motion + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 261}, {145, 18}} + + 2048 + YES + + 67108864 + 131072 + Transfer Done + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 221}, {145, 18}} + + 512 + YES + + 67108864 + 131072 + Unused + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 81}, {145, 18}} + + 4 + YES + + 67108864 + 131072 + Data Request Late + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 41}, {145, 18}} + + 1 + YES + + 67108864 + 131072 + Cylinder Address Error + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 121}, {145, 18}} + + 16 + YES + + 67108864 + 131072 + Write Lock Error + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{251, 141}, {145, 18}} + + 32 + YES + + 67108864 + 131072 + Timing Error + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 256 + + {{14, 294}, {99, 19}} + + YES + NO + 1 + 1 + + + -1805647807 + 205652992 + 7777 + + + 59 + + 67108864 + 67108864 + Command + + + + + + {99, 19} + {0, 8} + 524288 + NSActionCell + + 342884416 + 205652992 + + + 59 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + 3 + MQA + + + + + + 256 + {{14, 14}, {141, 19}} + + YES + NO + 1 + 1 + + + -1805647807 + 205521920 + 77777 + + + 94 + + 67108864 + 67108864 + Memory Address + + + + + + {141, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 94 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{29, 41}, {126, 19}} + + YES + NO + 1 + 1 + + + -1805647807 + 205521920 + 17777 + + + 79 + + 67108864 + 67108864 + Block Number + + + + + + {126, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 79 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{251, 294}, {77, 19}} + + YES + NO + 1 + 1 + + + -1805647807 + 205521920 + 7777 + + + 37 + + 67108864 + 67108864 + Status + + + + + + {77, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 37 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 268 + {{251, 101}, {145, 18}} + + 8 + YES + + 67108864 + 131072 + CRC Error + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{14, 210}, {154, 17}} + + YES + + 67108928 + 4326400 + Set Done Flag on Seek Done + + + + + + NO + 1 + + + + 268 + {{173, 208}, {57, 22}} + + 263 + YES + + -2076180416 + 133120 + + + 109199360 + 1 + + + 400 + 75 + + + Yes + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + 1 + + + YES + + OtherViews + + + + No + + 1048576 + 2147483647 + + + _popUpItemAction: + + + + + + 1 + 1 + YES + YES + 1 + + NO + + + {{1, 1}, {409, 324}} + + + + {{5, 4}, {411, 340}} + + {0, 0} + + 67108864 + 0 + RK8-E Disk Control + + + 6 + System + textBackgroundColor + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 1 + 0 + 2 + NO + + + + 268 + + + + 274 + + + + -2147483380 + {{14, 12}, {171, 19}} + + YES + + 71303232 + 138544128 + + + + YES + 1 + + + + NO + 1 + + + + 268 + {{96, 38}, {91, 18}} + + YES + + 67108864 + 131072 + Write Protect + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{14, 38}, {69, 18}} + + YES + + 67108864 + 134348800 + Mount + + + -2037628928 + 32 + + + 400 + 75 + + NO + + + {{1, 1}, {199, 66}} + + + + {{418, 262}, {201, 82}} + + {0, 0} + + 67108864 + 0 + RK05 Drive 0 + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 1 + 0 + 2 + NO + + + + 268 + + + + 274 + + + + -2147483380 + {{14, 12}, {171, 19}} + + YES + + 71303232 + 138544128 + + + + YES + 1 + + + + NO + 1 + + + + 268 + {{96, 38}, {91, 18}} + + YES + + 67108864 + 131072 + Write Protect + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{14, 38}, {69, 18}} + + 1 + YES + + 67108864 + 134348800 + Mount + + + -2037628928 + 32 + + + 400 + 75 + + NO + + + {{1, 1}, {199, 66}} + + + + {{418, 176}, {201, 82}} + + {0, 0} + + 67108864 + 0 + RK05 Drive 1 + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 1 + 0 + 2 + NO + + + + 268 + + + + 274 + + + + -2147483380 + {{14, 12}, {171, 19}} + + YES + + 71303232 + 138544128 + + + + YES + 1 + + + + NO + 1 + + + + 268 + {{96, 38}, {91, 18}} + + YES + + 67108864 + 131072 + Write Protect + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{14, 38}, {69, 18}} + + 2 + YES + + 67108864 + 134348800 + Mount + + + -2037628928 + 32 + + + 400 + 75 + + NO + + + {{1, 1}, {199, 66}} + + + + {{418, 90}, {201, 82}} + + {0, 0} + + 67108864 + 0 + RK05 Drive 2 + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 1 + 0 + 2 + NO + + + + 268 + + + + 274 + + + + -2147483380 + {{14, 12}, {171, 19}} + + YES + + 71303232 + 138544128 + + + + YES + 1 + + + + NO + 1 + + + + 268 + {{96, 38}, {91, 18}} + + YES + + 67108864 + 131072 + Write Protect + + + 1211912448 + 2 + + + + + 200 + 25 + + NO + + + + 268 + {{14, 38}, {69, 18}} + + 3 + YES + + 67108864 + 134348800 + Mount + + + -2037628928 + 32 + + + 400 + 75 + + NO + + + {{1, 1}, {199, 66}} + + + + {{418, 4}, {201, 82}} + + {0, 0} + + 67108864 + 0 + RK05 Drive 3 + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 1 + 0 + 2 + NO + + + {624, 352} + + + {{0, 0}, {1440, 878}} + {1.7976931348623157e+308, 1.7976931348623157e+308} + RK8EWindow + YES + + + RK8EController + + + RK05Controller + + + RK05Controller + + + RK05Controller + + + RK05Controller + + + RK05 + + + RK05 + + + RK05 + + + RK05 + + + + + + + nextKeyView + + + + 1179 + + + + nextKeyView + + + + 1180 + + + + nextKeyView + + + + 1181 + + + + nextKeyView + + + + 1182 + + + + nextKeyView + + + + 1183 + + + + nextKeyView + + + + 1184 + + + + nextKeyView + + + + 1185 + + + + nextKeyView + + + + 1186 + + + + nextKeyView + + + + 1188 + + + + nextKeyView + + + + 1189 + + + + nextKeyView + + + + 1190 + + + + nextKeyView + + + + 1191 + + + + nextKeyView + + + + 1192 + + + + nextKeyView + + + + 1193 + + + + nextKeyView + + + + 1194 + + + + nextKeyView + + + + 1195 + + + + nextKeyView + + + + 1196 + + + + nextKeyView + + + + 1197 + + + + nextKeyView + + + + 1199 + + + + nextKeyView + + + + 1202 + + + + nextKeyView + + + + 1222 + + + + nextKeyView + + + + 1223 + + + + nextKeyView + + + + 1224 + + + + nextKeyView + + + + 1226 + + + + nextKeyView + + + + 1228 + + + + nextKeyView + + + + 1230 + + + + nextKeyView + + + + 1276 + + + + nextKeyView + + + + 1277 + + + + nextKeyView + + + + 1278 + + + + nextKeyView + + + + 1279 + + + + nextKeyView + + + + 1280 + + + + blockNumberRegister + + + + 1329 + + + + cmdBlockLength + + + + 1330 + + + + cmdBlockNumberMSB + + + + 1331 + + + + cmdDriveSelect + + + + 1332 + + + + cmdExtendedAddress + + + + 1333 + + + + cmdFunction + + + + 1334 + + + + cmdInterrupt + + + + 1335 + + + + commandRegister + + + + 1336 + + + + memoryAddressRegister + + + + 1337 + + + + rk8e + + + + 1338 + + + + statusControlBusy + + + + 1339 + + + + statusCRCError + + + + 1340 + + + + statusCylinderAddressError + + + + 1341 + + + + statusDataRequestLate + + + + 1342 + + + + statusDriveStatusError + + + + 1343 + + + + statusHeadInMotion + + + + 1344 + + + + statusRegister + + + + 1345 + + + + statusSeekFailed + + + + 1346 + + + + statusTimingError + + + + 1347 + + + + statusTransferDone + + + + 1348 + + + + statusUnused + + + + 1349 + + + + statusWriteLockError + + + + 1350 + + + + statusFileNotReady + + + + 1351 + + + + commandPopupClicked: + + + + 1364 + + + + commandPopupClicked: + + + + 1366 + + + + commandPopupClicked: + + + + 1367 + + + + commandPopupClicked: + + + + 1368 + + + + commandPopupClicked: + + + + 1369 + + + + commandPopupClicked: + + + + 1370 + + + + statusCheckboxClicked: + + + + 1371 + + + + statusCheckboxClicked: + + + + 1372 + + + + statusCheckboxClicked: + + + + 1373 + + + + statusCheckboxClicked: + + + + 1374 + + + + statusCheckboxClicked: + + + + 1375 + + + + statusCheckboxClicked: + + + + 1376 + + + + statusCheckboxClicked: + + + + 1377 + + + + statusCheckboxClicked: + + + + 1378 + + + + statusCheckboxClicked: + + + + 1379 + + + + statusCheckboxClicked: + + + + 1380 + + + + statusCheckboxClicked: + + + + 1381 + + + + statusCheckboxClicked: + + + + 1382 + + + + cmdSetDone + + + + 1396 + + + + commandPopupClicked: + + + + 1397 + + + + writeProtectCheckbox + + + + 1525 + + + + writeProtectCheckbox + + + + 1528 + + + + writeProtectCheckbox + + + + 1531 + + + + writeProtectCheckbox + + + + 1534 + + + + mountUnmountClicked: + + + + 1535 + + + + writeProtectClicked: + + + + 1536 + + + + mountUnmountClicked: + + + + 1537 + + + + writeProtectClicked: + + + + 1538 + + + + mountUnmountClicked: + + + + 1539 + + + + writeProtectClicked: + + + + 1540 + + + + mountUnmountClicked: + + + + 1541 + + + + writeProtectClicked: + + + + 1542 + + + + rk05 + + + + 1547 + + + + rk05 + + + + 1548 + + + + rk05 + + + + 1549 + + + + rk05 + + + + 1550 + + + + mountUnmountButton + + + + 1551 + + + + mountUnmountButton + + + + 1552 + + + + mountUnmountButton + + + + 1553 + + + + mountUnmountButton + + + + 1554 + + + + filenameField + + + + 1555 + + + + filenameField + + + + 1556 + + + + filenameField + + + + 1557 + + + + filenameField + + + + 1558 + + + + window + + + + 1715 + + + + rk05_0 + + + + 1759 + + + + rk05_1 + + + + 1760 + + + + rk05_2 + + + + 1761 + + + + rk05_3 + + + + 1762 + + + + rk8e + + + + 1763 + + + + rk8e + + + + 1764 + + + + rk8e + + + + 1765 + + + + rk8e + + + + 1766 + + + + rk8eBox + + + + 1851 + + + + rk05Controller_0 + + + + 1936 + + + + rk05Controller_1 + + + + 1937 + + + + rk05Controller_2 + + + + 1938 + + + + rk05Controller_3 + + + + 1939 + + + + initialFirstResponder + + + + 1957 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 807 + + + + + + RK8EWindow + + + 808 + + + + + + + + + + + + 812 + + + + + + + + + + 815 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1063 + + + + + + + + + + 1070 + + + + + + + + + + 1077 + + + + + + + + + + 1328 + + + RK8EController + + + 1519 + + + RK05-0 Controller + + + 1520 + + + RK05-1 Controller + + + 1521 + + + RK05-2 Controller + + + 1522 + + + RK05-3 Controller + + + 1543 + + + RK05-0 + + + 1544 + + + RK05-1 + + + 1545 + + + RK05-2 + + + 1546 + + + RK05-3 + + + 909 + + + + + + + + 1895 + + + + + 908 + + + + + + + + 1894 + + + + + 1061 + + + + + + + + 1896 + + + + + 828 + + + + + + + + 1908 + + + + + + + + 830 + + + + + + + + + 831 + + + + + 832 + + + + + 827 + + + + + + + + 1907 + + + + + 826 + + + + + + + + 1906 + + + + + + + + 835 + + + + + + + + + 836 + + + + + 837 + + + + + 825 + + + + + + + + 1905 + + + + + 823 + + + + + + + + 1904 + + + + + 822 + + + + + + + + 1903 + + + + + 821 + + + + + + + + 1902 + + + + + + + + 844 + + + + + + + + + + + + + + + 845 + + + + + 846 + + + + + 847 + + + + + 848 + + + + + 849 + + + + + 850 + + + + + 851 + + + + + 852 + + + + + 820 + + + + + + + + 1901 + + + + + + + + 854 + + + + + + + + + + + 855 + + + + + 856 + + + + + 857 + + + + + 858 + + + + + 819 + + + + + + + + 1900 + + + + + 818 + + + + + + + + 1899 + + + + + + + + 861 + + + + + + + + + + + + + + + 862 + + + + + 863 + + + + + 864 + + + + + 865 + + + + + 866 + + + + + 867 + + + + + 868 + + + + + 869 + + + + + 817 + + + + + + + + 1898 + + + + + 816 + + + + + + + + 1897 + + + + + + + + 872 + + + + + + + + + 873 + + + + + 874 + + + + + 932 + + + + + + + + 1909 + + + + + 933 + + + + + + + + 1910 + + + + + 934 + + + + + + + + 1911 + + + + + 935 + + + + + + + + 1912 + + + + + 937 + + + + + + + + 1913 + + + + + 938 + + + + + + + + 1914 + + + + + 939 + + + + + + + + 1915 + + + + + 940 + + + + + + + + 1916 + + + + + 941 + + + + + + + + 1917 + + + + + 942 + + + + + + + + 1918 + + + + + 943 + + + + + + + + 1919 + + + + + 1110 + + + + + + + + + 1932 + + + + + 1111 + + + + + 1113 + + + + + + + + + 1933 + + + + + 1115 + + + + + 1116 + + + + + + + + + 1934 + + + + + 1117 + + + + + 1119 + + + + + + + + + 1935 + + + + + 1121 + + + + + 944 + + + + + + + + 1920 + + + + + 1383 + + + + + + + + 1921 + + + + + 1385 + + + + + + + + 1922 + + + + + + + + 1387 + + + + + + + + + 1388 + + + + + 1389 + + + + + 1066 + + + + + + + + 1925 + + + + + 1065 + + + + + + + + 1924 + + + + + 1064 + + + + + + + + 1923 + + + + + 1071 + + + + + + + + 1926 + + + + + 1072 + + + + + + + + 1927 + + + + + 1073 + + + + + + + + 1928 + + + + + 1080 + + + + + + + + 1931 + + + + + 1079 + + + + + + + + 1930 + + + + + 1078 + + + + + + + + 1929 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + TW91bnRzIG9yIHVubW91bnRzIGEgREVDcGFjayBkaXNrIGltYWdlIGZvciB0aGlzIFJLMDUgZHJpdmUu +CgpPcHRpb24tY2xpY2sgdG8gY3JlYXRlIGEgbmV3IGRpc2sgaW1hZ2UuCgpZb3UgYWxzbyBjYW4gZHJh +ZyBkaXNrIGltYWdlcyBmcm9tIHRoZSBGaW5kZXIgdG8gdGhpcyBidXR0b24gdG8gbW91bnQgdGhlbS4 + + + com.apple.InterfaceBuilder.CocoaPlugin + + P4AAAL+AAABCEAAAwlgAAA + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + TW91bnRzIG9yIHVubW91bnRzIGEgREVDcGFjayBkaXNrIGltYWdlIGZvciB0aGlzIFJLMDUgZHJpdmUu +CgpPcHRpb24tY2xpY2sgdG8gY3JlYXRlIGEgbmV3IGRpc2sgaW1hZ2UuCgpZb3UgYWxzbyBjYW4gZHJh +ZyBkaXNrIGltYWdlcyBmcm9tIHRoZSBGaW5kZXIgdG8gdGhpcyBidXR0b24gdG8gbW91bnQgdGhlbS4 + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Turns write protection for this RK05 drive on or off. Write protection can be turned on by software (RK8-E command function 2 “Lock”), but it can be turned off only manually using this switch. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Filename of the mounted DECpack disk image + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Filename of the mounted DECpack disk image + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Turns write protection for this RK05 drive on or off. Write protection can be turned on by software (RK8-E command function 2 “Lock”), but it can be turned off only manually using this switch. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + TW91bnRzIG9yIHVubW91bnRzIGEgREVDcGFjayBkaXNrIGltYWdlIGZvciB0aGlzIFJLMDUgZHJpdmUu +CgpPcHRpb24tY2xpY2sgdG8gY3JlYXRlIGEgbmV3IGRpc2sgaW1hZ2UuCgpZb3UgYWxzbyBjYW4gZHJh +ZyBkaXNrIGltYWdlcyBmcm9tIHRoZSBGaW5kZXIgdG8gdGhpcyBidXR0b24gdG8gbW91bnQgdGhlbS4 + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + TW91bnRzIG9yIHVubW91bnRzIGEgREVDcGFjayBkaXNrIGltYWdlIGZvciB0aGlzIFJLMDUgZHJpdmUu +CgpPcHRpb24tY2xpY2sgdG8gY3JlYXRlIGEgbmV3IGRpc2sgaW1hZ2UuCgpZb3UgYWxzbyBjYW4gZHJh +ZyBkaXNrIGltYWdlcyBmcm9tIHRoZSBGaW5kZXIgdG8gdGhpcyBidXR0b24gdG8gbW91bnQgdGhlbS4 + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Turns write protection for this RK05 drive on or off. Write protection can be turned on by software (RK8-E command function 2 “Lock”), but it can be turned off only manually using this switch. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Filename of the mounted DECpack disk image + + + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + SU9UIERMREMgKDY3NDYpIGxvYWRzIHRoZSBjb21tYW5kIHRoZSBQRFAtOCB3YW50cyB0aGUgUks4LUUg +dG8gZXhlY3V0ZSBmcm9tIEFDIGludG8gdGhlIENvbW1hbmQgcmVnaXN0ZXIuCgpUaGUgYml0cyBpbiB0 +aGUgQ29tbWFuZCByZWdpc3RlciBhcmUgc2hvd24gaW4gdGhlIHBvcHVwIG1lbnVzIGJlbG93Lg + + + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + VGhpcyBNZW1vcnkgQWRkcmVzcyByZWdpc3RlciBzcGVjaWZpZXMgdGhlIGFic29sdXRlIG1lbW9yeSBh +ZGRyZXNzIHRoYXQgZGF0YSBpcyB0byBiZSB0cmFuc2ZlcnJlZCB0byBvciBmcm9tIG1lbW9yeS4KCk5v +dGUgdGhhdCBpdCBpcyBhIDEyLWJpdCByZWdpc3RlcjsgdGhlIHRocmVlIE1TQnMgYXJlIGlkZW50aWNh +bCB0byBiaXRzIDYtOCBvZiB0aGUgQ29tbWFuZCByZWdpc3Rlci4 + + + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + VGhlIEJsb2NrIE51bWJlciByZWdpc3RlciBzcGVjaWZpZXMgYSBkaXNrIGJsb2NrIHdoZXJlIGRhdGEg +aXMgdG8gYmUgdHJhbnNmZXJyZWQuIEEgZGlzayBoYXMgdHdvIHN1cmZhY2VzIChzKSwgMTYgc2VjdG9y +cyAoUyksIDIwMyBjeWxpbmRlcnMgKGMpIGFuZCAxMy1iaXQgYWRkcmVzc2VzIGNjY2NjY2Njc1NTU1Mu +CgpOb3RlIHRoYXQgaXQgaXMgYSAxMi1iaXQgcmVnaXN0ZXI7IE1TQj1MU0Igb2YgdGhlIENvbW1hbmQg +cmVnaXN0ZXIuA + + + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + VGhlIFN0YXR1cyByZWdpc3RlciBjb250YWlucyBhbGwgdGhlIGluZm9ybWF0aW9uIGEgcHJvZ3JhbSBy +ZXF1aXJlcyB0byBkZXRlcm1pbmUgaWYgdGhlIGNvbW1hbmQgdG8gdGhlIFJLOC1FIGlzIGNvbXBsZXRl +ZCBhbmQgd2hldGhlciBvciBub3QgaXQgd2FzIHN1Y2Nlc3NmdWwuIElPVCBEUlNUICg2NzQ1KSBsb2Fk +cyB0aGUgU3RhdHVzIHJlZ2lzdGVyIGludG8gQUMuCgpUaGUgc3RhdHVzIGZsYWdzIGFyZSBzaG93biBp +biB0aGUgY2hlY2sgYm94ZXMgYmVsb3cuA + + + com.apple.InterfaceBuilder.CocoaPlugin + + + EnableDisableTextField + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + When Command(4) is set, the RK8-E raises its I/O flag when a seek operation finishs. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + {{100, 309}, {624, 352}} + com.apple.InterfaceBuilder.CocoaPlugin + {{100, 309}, {624, 352}} + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + When Command(5) is set, the RK8-E operates on half blocks (128 12-bit words), otherwise on full blocks (256 12-bit words). + + + com.apple.InterfaceBuilder.CocoaPlugin + + EnableDisableTextField + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Q29tbWFuZCg2LTgpIGhvbGRzIHRoZSBtZW1vcnkgZmllbGQgdGhlIFJLOC1FIHVzZXMgZm9yIERhdGEg +QnJlYWsgSS9PLgoKTm90ZSB0aGF0IHRoZXNlIGJpdHMgYXJlIGlkZW50aWNhbCB0byB0aGUgTVNCcyBv +ZiB0aGUgTWVtb3J5IEFkZHJlc3MgcmVnaXN0ZXIuA + + + com.apple.InterfaceBuilder.CocoaPlugin + + EnableDisableTextField + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Command(9-10) holds the number of the RK05 drive to be used for the command. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Command(0-2) holds the function to be performed by the RK8-E. + + + com.apple.InterfaceBuilder.CocoaPlugin + + EnableDisableTextField + com.apple.InterfaceBuilder.CocoaPlugin + + EnableDisableTextField + com.apple.InterfaceBuilder.CocoaPlugin + + EnableDisableTextField + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Q29tbWFuZCgxMSkgaXMgdGhlIG1vc3Qgc2lnbmlmaWNhbnQgYml0IG9mIGJsb2NrIG51bWJlci4KCk5v +dGUgdGhhdCB0aGlzIGJpdCBpZGVudGljYWwgdG8gdGhlIE1TQiBvZiB0aGUgQmxvY2sgTnVtYmVyIHJl +Z2lzdGVyLg + + + com.apple.InterfaceBuilder.CocoaPlugin + + EnableDisableTextField + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Q29tbWFuZCgzKSBpcyB0aGUgaW50ZXJydXB0IG1hc2sgZm9yIHRoZSBSSzgtRS4KCk5vdGUgdGhhdCB0 +aGlzIGJpdCBpcyBpZGVudGljYWwgdG8gdGhlIFJLOC1FIEludGVycnVwdCBFbmFibGUgZmxhZyBpbiB0 +aGUgQ1BVIHdpbmRvdy4 + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Turns write protection for this RK05 drive on or off. Write protection can be turned on by software (RK8-E command function 2 “Lock”), but it can be turned off only manually using this switch. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Filename of the mounted DECpack disk image + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(4) — File not Ready + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(5) — Control Busy + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(3) — Seek Failed + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(10) — Drive Status Error + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(1) — Head in Motion + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(0) — Transfer Done + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(2) — Unused + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(9) — Data Request Late + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(11) — Cylinder Address Error + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(7) — Write Lock Error + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(6) — Timing Error + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + Status(8) — CRC Error + + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 1957 + + + + + EnableDisableTextField + NSTextField + + IBProjectSource + Utilities/EnableDisableTextField.h + + + + EnableDisableTextField + NSTextField + + IBUserSource + + + + + KeepInMenuWindow + NSWindow + + id + id + + + + orderBackFromDefaults: + id + + + orderFrontFromDefaults: + id + + + + IBProjectSource + Utilities/KeepInMenuWindow.h + + + + KeepInMenuWindow + NSWindow + + IBUserSource + + + + + NSControl + + IBProjectSource + Categories/NSControl+FileDrop.h + + + + NSControl + NSView + + IBUserSource + + + + + PDP8Plugin + NSObject + + IBProjectSource + Plugins/PluginAPI.h + + + + PDP8Plugin + NSObject + + IBUserSource + + + + + RK05 + NSObject + + rk8e + RK8E + + + rk8e + + rk8e + RK8E + + + + IBProjectSource + RK8E/RK05.h + + + + RK05 + NSObject + + IBUserSource + + + + + RK05Controller + NSObject + + id + id + + + + mountUnmountClicked: + id + + + writeProtectClicked: + id + + + + NSTextField + NSButton + RK05 + NSButton + + + + filenameField + NSTextField + + + mountUnmountButton + NSButton + + + rk05 + RK05 + + + writeProtectCheckbox + NSButton + + + + IBProjectSource + RK8E/RK05Controller.h + + + + RK05Controller + NSObject + + IBUserSource + + + + + RK8E + PDP8Plugin + + RK05Controller + RK05Controller + RK05Controller + RK05Controller + RK05 + RK05 + RK05 + RK05 + + + + rk05Controller_0 + RK05Controller + + + rk05Controller_1 + RK05Controller + + + rk05Controller_2 + RK05Controller + + + rk05Controller_3 + RK05Controller + + + rk05_0 + RK05 + + + rk05_1 + RK05 + + + rk05_2 + RK05 + + + rk05_3 + RK05 + + + + IBProjectSource + RK8E/RK8E.h + + + + RK8E + PDP8Plugin + + IBUserSource + + + + + RK8EController + NSObject + + id + id + + + + commandPopupClicked: + id + + + statusCheckboxClicked: + id + + + + RegisterFormCell + NSPopUpButton + NSPopUpButton + NSPopUpButton + NSPopUpButton + NSPopUpButton + NSPopUpButton + NSPopUpButton + RegisterFormCell + RegisterFormCell + RK8E + NSBox + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + NSButton + RegisterFormCell + NSButton + NSButton + NSButton + NSButton + NSButton + KeepInMenuWindow + + + + blockNumberRegister + RegisterFormCell + + + cmdBlockLength + NSPopUpButton + + + cmdBlockNumberMSB + NSPopUpButton + + + cmdDriveSelect + NSPopUpButton + + + cmdExtendedAddress + NSPopUpButton + + + cmdFunction + NSPopUpButton + + + cmdInterrupt + NSPopUpButton + + + cmdSetDone + NSPopUpButton + + + commandRegister + RegisterFormCell + + + memoryAddressRegister + RegisterFormCell + + + rk8e + RK8E + + + rk8eBox + NSBox + + + statusCRCError + NSButton + + + statusControlBusy + NSButton + + + statusCylinderAddressError + NSButton + + + statusDataRequestLate + NSButton + + + statusDriveStatusError + NSButton + + + statusFileNotReady + NSButton + + + statusHeadInMotion + NSButton + + + statusRegister + RegisterFormCell + + + statusSeekFailed + NSButton + + + statusTimingError + NSButton + + + statusTransferDone + NSButton + + + statusUnused + NSButton + + + statusWriteLockError + NSButton + + + window + KeepInMenuWindow + + + + IBProjectSource + RK8E/RK8EController.h + + + + RK8EController + NSObject + + IBUserSource + + + + + RegisterFormCell + NSFormCell + + registerOwner + id + + + registerOwner + + registerOwner + id + + + + IBProjectSource + Utilities/RegisterFormCell.h + + + + RegisterFormCell + NSFormCell + + IBUserSource + + + + + + + EnableDisableTextField + NSTextField + + IBFrameworkSource + PluginFramework.framework/Headers/EnableDisableTextField.h + + + + KeepInMenuWindow + NSWindow + + IBFrameworkSource + PluginFramework.framework/Headers/KeepInMenuWindow.h + + + + NSControl + + IBFrameworkSource + PluginFramework.framework/Headers/NSControl+FileDrop.h + + + + PDP8Plugin + NSObject + + IBFrameworkSource + PluginFramework.framework/Headers/PluginAPI.h + + + + RegisterFormCell + NSFormCell + + IBFrameworkSource + PluginFramework.framework/Headers/RegisterFormCell.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../../pdp8e-simulator.xcodeproj + 3 + + {11, 11} + {10, 3} + {15, 15} + + + diff --git a/RK8E/English.lproj/RK8E.nib/keyedobjects.nib b/RK8E/English.lproj/RK8E.nib/keyedobjects.nib new file mode 100644 index 0000000..5b9c9f4 Binary files /dev/null and b/RK8E/English.lproj/RK8E.nib/keyedobjects.nib differ diff --git a/RK8E/English.lproj/RK8EOnlineHelp/index.html b/RK8E/English.lproj/RK8EOnlineHelp/index.html new file mode 100644 index 0000000..b323b41 --- /dev/null +++ b/RK8E/English.lproj/RK8EOnlineHelp/index.html @@ -0,0 +1,268 @@ + + + + + + RK8-E Disk Cartridge System Help + + + + + + + +

IOTs for the RK8-E Disk Cartridge System

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Mnemonic
Symbol
Octal
Code

Description
DSKP6741 + Disk Skip on Flag. If the RK8-E I/O flag is set, the next instruction is skipped. + The flag is raised when an I/O operation is completed or an I/O error occured. +
DCLR6742 + Disk Clear. The function is regulated by AC(10–11):
+ AC(10–11) = 00 (DCLS): Clear AC and the status register.
+ AC(10–11) = 01 (DCLC): Clear AC and all RK8-E registers. + This instruction aborts any disk command in progress and resets the maintenance mode.
+ AC(10–11) = 10 (DCLD): Clear AC and the status register and recalibrate the + selected drive to cylinder 0.
+ AC(10–11) = 11: Undefined. Performs the same function as with AC(10–11) = 00. +
DLAG6743 + Load Address and Go. The disk cylinder, surface and sector bits (12 least significant + bits of the block number) are loaded from AC(0–6), AC(7) and AC(8–11) + respectively, and the function indicated by the current content of the command register + is executed. +
DLCA6744 + Load Current Address. The content of AC is loaded into the disk current address register + (12 least significant bits of the memory address). The next data transfer between memory + and the disk will use this memory start address. After the transfer is completed, the + content of the current address register is incremented by the size of the transferred + data block. +
DRST6745 + Read Status. The content of the disk status register is transferred into AC. +
DLDC6746 + Load Command. The content of AC is loaded into the disk command register. + Then AC and the disk status register are both cleared. +
DMAN6747 + Maintenance instruction. This instruction is only used by hardware diagnostic software. + The function is regulated by bits in the AC which cannot be microprogrammed:
+ AC(0) = 1: Enter maintenance mode and disable the DLAG IOT.
+ AC(1) = 1: Enable a shift to the lower data buffer DB4.
+ AC(2) = 1: Check CRC register. AC(10), the CRC register and the lower data buffer are + connected as a shift register, and AC(10) shifts to the CRC, CRC shifts to + lower data buffer.
+ AC(3) = 1: Check command register. The command register is shifted by one bit to the + lower data buffer.
+ AC(4) = 1: Check surface and sector register. The surface and sector register (12 LSBs + of the current block number) is shifted by one bit to the lower data buffer.
+ AC(5) = 1: Check data buffer. AC(10) is shifted to the upper data buffer, + the upper data buffer sinks to the lower data buffers when it is full (after 12 shifts).
+ AC(6) = 1: Check data break request. A single cycle data break request is performed. + The direction of data transfer is regulated by the function in the command register.
+ AC(7) = 1: Transfer the content of the lower data buffer DB4 to the AC.
+ AC(8): Not used.
+ AC(9): Not used.
+ AC(10): Used as data for some maintenance functions.
+ AC(11): Not used. +
+ +

Formatting a DECpack Disk Cartridge

+ +

+With the PDP-8/E Simulator, formatting a new DECpack disk cartridge is not necessary and would increase +the size of the DECpack disk file to its maximum amount (see Technical Notes, below). With the simulator, +the Read and Read All resp. the Write and Write All commands are identical. With a hardware RK8-E, to +format a new disk, a program has to address every sector and write test patterns (containing the sector +number) with the Write All command, which writes the data and the sector header word. The sector header +word is used internally by the disk control and cannot be accessed by PDP-8 software. The Read All +command then can be used to verify the data written to the initialized sectors. The Read All command +prevents the RK8-E from reading sector header words and report header errors that will certainly exist +on an unformatted disk. +

+ +

Normal Read and Write Operations

+ +

+For a normal disk read or write, a program has to perform the following steps: +

+ +
    +
  • + Set up the memory transfer address using DLCA. +
  • +
  • + Set up the command register with 00xy for read and 10xy for write using DLDC (xy is determined + by the memory field for the data transfer, the selected disk drive and the disk block number; + see the RK8-E window for the exact bit assignment.) +
  • +
  • + Set up the required disk address (block number) and start the I/O operation using DLAG. +
  • +
  • + Wait until the data is transferred by “Data Break” (Direct Memory Access, DMA) and + the RK8-E I/O flag is raised (using DSKP), then check for errors (using DRST to read the + status register). +
  • +
+ +

Seek Only

+ +

+The sequence for seek only (command register function bits equal three) is different from normal read +or write operation. It is necessary to put two skip or interrupt sequences in the program: +

+ +
    +
  • + Set up the command register with 300x for seek only and the desired drive number. +
  • +
  • + Load the disk address (block number) and go. +
  • +
  • + Wait for the RK8-E I/O flag. +
  • +
  • + Clear the RK8-E I/O flag. The drive has started to move the head to the desired track. +
  • +
  • + If the RK8-E I/O flag is to be set when the seek is complete, bit 4 of the command register must + be set to one. So issue a load command (DLDC) with the selected drive number in AC(10–11) + and AC(4) = 1. +
  • +
  • + Wait for the RK8-E I/O flag. +
  • +
+ +

+The alternative to the last two steps is to check the “Head in Motion” bit of the +RK8-E status register (bit 1) which is zero when the seek is completed. +

+ +

+When seek operations are started for more than one RK05 drive simultaneously (overlapped seek), +care has to be taken to determine which drive has completed its seek operation when the RK8-E I/O flag +is raised or a disk interrupt occurs. There are two methods to do this: +

+ +
    +
  • + Before selecting a new drive to check its seek status, clear bit 4 of the command register + without changing the old drive number. Then change the drive number with bit 4 of the + command register equal to a one. When the new drive has completed the seek, there will be + no confusion as to which drive set the RK8-E I/O flag. +
  • +
  • + Leave bit 4 of the command register set and check bit 1 (“Head in Motion”) of the + status register to determine if the now or previously selected drive set the RK8-E I/O flag. +
  • +
+ +

Capacity of a DECpack Disk Cartridge

+ +

+A DECpack cartridge has two surfaces, each surface has 200 (+ 3 spare) cylinders, each cylinder has +16 sectors (blocks) with 256 12-bit words. So a disk has block numbers 0–6,495 and a capacity of +1,662,976 words (nearly 2.5 MB); a PDP-8 with four RK05 drives has online access to nearly 10 MB of +mass storage. +

+ +

Technical Notes

+ +
    +
  • + The PDP-8/E Simulator stores DECpack disk cartridges in files with the extension .rk05. + (For compatibility reasons, files with the file type ‘RK8E’ and creator + ‘RK8E’ used by the Classic PDP-8/E Simulator are still recognized.) + The disk is stored as an unstructured sequence of DECpack disk blocks, each block with 256 12-bit + words. Two consecutive 12-bit words aaaaaaaaAAAA BBBBbbbbbbbb are stored in three consecutive bytes + aaaaaaaa AAAABBBB bbbbbbbb (MSB at the left in both cases). +
  • +
  • + Cylinders of newly created DECpack disk files are not stored in the file until a block of the + cylinder is read or written by the PDP-8. Reading never written data returns zeros. The simulator + always buffers a complete DECpack disk cylinder in memory. +
  • +
  • + The RK8-E uses threads for each RK05 drive, so the drives really work parallel to the simulated PDP-8. +
  • +
  • + The header words of the sectors are not simulated explicitly. They are assumed to be always correct. + It is impossible for PDP-8 software to access this word temporarily stored in the CRC register + with the DMAN IOT. +
  • +
  • + The block CRC words are not stored in the DECpack disk file because there is no danger of single + bit errors with the simulated disks. The CRC is calculated when a block is read or written and is + available for the PDP-8 via the DMAN IOT. However, the PDP-8 can write wrong CRCs to the disk by + issuing DMAN instructions shifting the CRC register while an I/O operation is in progress. Then + the PDP-8 can read the block back and check for CRC errors. For this purpose, the simulator holds + a bit for every block indicating that the CRC of the block was willfully destroyed. This bit array + is not stored with the disk image, so CRC errors disappear by unmounting and remounting a DECpack + disk or by restarting the simulator. +
  • +
+ + + \ No newline at end of file diff --git a/RK8E/English.lproj/RK8EOnlineHelp/pdp8e.png b/RK8E/English.lproj/RK8EOnlineHelp/pdp8e.png new file mode 100644 index 0000000..2c0c485 Binary files /dev/null and b/RK8E/English.lproj/RK8EOnlineHelp/pdp8e.png differ diff --git a/RK8E/English.lproj/RK8EOnlineHelp/styles.css b/RK8E/English.lproj/RK8EOnlineHelp/styles.css new file mode 100644 index 0000000..c18751d --- /dev/null +++ b/RK8E/English.lproj/RK8EOnlineHelp/styles.css @@ -0,0 +1,239 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * styles.css - Online help - Style sheet + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +p { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +p.small { + font-size: 8pt; +} + +a { + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +a:hover { + text-decoration: underline +} + +ul { + margin-left: 1.25em; padding-left: 0em; +} + +li { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +#mainbox { + background-color: #fff; + margin-top: 30px; + margin-right: 26px; + margin-left: 18px; + position: absolute; + top: 10px +} + +#taskbox { + background-color: #eee; + list-style-type: decimal; + list-style-position: outside; + margin-top: 12px; + margin-bottom: 12px; + border: solid 1px #444 +} + +h1 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 6pt; +} + +h2 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 8pt; +} + +h3 { + font-size: 10pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 5pt; +} + +h4 { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 4pt; +} + +/* index.html */ + +table.index { + padding-top: 20px; + width: 100%; +} + +td.banner { + padding: 20px; +} + +td.toc { + padding-top: 10px; + padding-bottom: 10px; + padding-left: 20px; + padding-right:20px; + border-left: 1px solid darkgray; +} + +p.toc { + line-height: 40px; +} + +/* other pages */ + +table { + border-collapse: separate; + border-spacing: 0px; +} + +th { + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + font-style: bold; + border-bottom: 1px solid gray; + padding-left: 10px; + padding-right: 10px; +} + +th.left { + text-align: left; +} + +td { + text-align: center; + vertical-align: top; + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + padding-left: 10px; + padding-right: 10px; +} + +td.left { + text-align: left; +} + +td.right { + text-align: right; +} + +td.br { + border-right: 1px solid gray; +} + +td.bb { + border-bottom: 1px solid lightgray; +} + +td.bb_left { + text-align: left; + border-bottom: 1px solid lightgray; +} + +td.bbr { + border-bottom: 1px solid lightgray; + border-right: 1px solid gray; +} + +td.opcode { + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_right { + text-align: right; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_left { + text-align: left; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-left: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + border-right: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} diff --git a/RK8E/English.lproj/io-info.plist b/RK8E/English.lproj/io-info.plist new file mode 100644 index 0000000..c97f10c --- /dev/null +++ b/RK8E/English.lproj/io-info.plist @@ -0,0 +1,47 @@ + + + + + + ioflags + + RK8-E + + ioaddresses + + 74 + + iots + + + DSKP + DCLR + DLAG + DLCA + DRST + DLDC + DMAN + + + diff --git a/RK8E/Info.plist b/RK8E/Info.plist new file mode 100644 index 0000000..c2ba4a5 --- /dev/null +++ b/RK8E/Info.plist @@ -0,0 +1,32 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleHelpBookFolder + RK8EOnlineHelp + CFBundleHelpBookName + RK8-E Disk Cartridge System Help + CFBundleIconFile + + CFBundleIdentifier + de.bernhard-baehr.pdp8e.RK8E + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + ${PRODUCT_NAME} + CFBundlePackageType + BNDL + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + CFBundleShortVersionString + 2.0.2 + NSPrincipalClass + RK8E + + diff --git a/RK8E/RK05.h b/RK8E/RK05.h new file mode 100644 index 0000000..b30ed55 --- /dev/null +++ b/RK8E/RK05.h @@ -0,0 +1,77 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK05.h - Class implementing a RK05 DECpack drive + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define WRITEPROTECT_CHANGED_NOTIFICATION @"rk05WriteProtectChangedNotification" + +#define RK05_BUFSIZE ((long) 32 * 384) /* 32 blocks with 256 12-bit-words */ +#define RK05_BLOCKS (203 * 2 * 16) /* 203 tracks, 2 surfaces, 16 blocks per track */ + + +@class RK8E, PDP8; + + +@interface RK05 : NSObject { +@private + IBOutlet RK8E *rk8e; + PDP8 *pdp8; + short driveNumber; + FILE *decpack; + volatile unsigned short cmd; + short cyl; + BOOL dirty; + BOOL locked; + short newcyl; + unsigned short blk; + unsigned char crcstate[RK05_BLOCKS / 8]; // for any block, a bit indicating that the CRC + // word virtually stored on the disk is correct + unsigned char buffer[RK05_BUFSIZE]; // buffer for one RK05 cylinder + unsigned long durationMicroSeconds; // duration of the current I/O operation + uint64_t startAtMachAbsolute; // Mach absolute time when drive started working + NSConditionLock *commandsLock; +} + +- (int) driveNumber; +- (void) setDriveNumber:(short)drvNum; +- (void) setPDP8:(PDP8 *)p8; +- (void) setWriteProtected:(BOOL)writeProtected; +- (BOOL) isWriteProtected; +- (BOOL) flush; +- (BOOL) canMount:(NSString *)path; +- (int) mount:(NSString *)path create:(BOOL)create; // 0 = ok, -1 = can't open file, -2 = file is locked +- (BOOL) unmount; +- (BOOL) isMounted; +- (BOOL) isBusy; +- (BOOL) isCalibrating; +- (void) stopCalibrating; +- (void) abortAllCommands; +- (void) setStatusAndAbortAllCommands; +- (void) setRecalibrating; +- (void) setFlushCylinder; +- (void) setReadCylinder:(unsigned short)cylinder; +- (void) setRaiseFlag; +- (void) clearRaiseFlag; +- (void) setRead:(BOOL)read write:(BOOL)write all:(BOOL)all newBlock:(unsigned short)newBlock; +- (void) start; + +@end diff --git a/RK8E/RK05.m b/RK8E/RK05.m new file mode 100644 index 0000000..cd5522f --- /dev/null +++ b/RK8E/RK05.m @@ -0,0 +1,512 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK05.m - Class implementing a RK05 DECpack drive + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import +#import +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" +#import "PluginFramework/Utilities.h" + +#import "RK05.h" +#import "RK8E.h" + + +@implementation RK05 + + +/* "commands" for a RK05 drive to be performed asynchroniously, bit coded in self.cmd */ +#define RK05_RECALIBRATE 0400 +#define RK05_SET_CRC_STATE 0200 +#define RK05_DELAY 0100 +#define RK05_SEEK 0040 +#define RK05_FLUSH_CYL 0020 +#define RK05_READ_CYL 0010 +#define RK05_INPUT_BLOCK 0004 +#define RK05_OUTPUT_BLOCK 0002 +#define RK05_RAISE_FLAG 0001 + +#define NO_COMMANDS_AVAILABLE 0 +#define COMMANDS_AVAILABLE 1 + + +- (int) driveNumber +{ + return driveNumber; +} + + +- (void) setDriveNumber:(short)drvNum +{ + driveNumber = drvNum; +} + + +- (void) setPDP8:(PDP8 *)p8 +{ + pdp8 = p8; +} + + +- (void) setWriteProtected:(BOOL)writeProtected +{ + locked = writeProtected; + [[NSNotificationCenter defaultCenter] postNotificationName:WRITEPROTECT_CHANGED_NOTIFICATION + object:self]; +} + + +- (BOOL) isWriteProtected +{ + return locked; +} + + +- (BOOL) flush +{ + BOOL error = NO; + if (decpack && dirty) { + if (fseek(decpack, cyl * RK05_BUFSIZE, SEEK_SET) < 0) + error = YES; + else if (fwrite(buffer, 1, RK05_BUFSIZE, decpack) != RK05_BUFSIZE) + error = YES; + dirty = NO; + } + return error; +} + + +- (BOOL) canMount:(NSString *)path +{ + NSAssert (decpack == NULL, @"A DECpack is already mounted"); + FILE *handle = fopen([path cStringUsingEncoding:NSUTF8StringEncoding], "r+"); + if (handle) { + if (flock(fileno(handle), LOCK_EX | LOCK_NB)) { + fclose (handle); + return NO; + } + flock (fileno(handle), LOCK_UN); + return YES; + } + return NO; +} + + +- (int) mount:(NSString *)path create:(BOOL)create +{ + NSAssert (decpack == NULL, @"A DECpack is already mounted"); + int err = 0; + decpack = fopen([path cStringUsingEncoding:NSUTF8StringEncoding], create ? "w+" : "r+"); + if (decpack) { + if (flock(fileno(decpack), LOCK_EX | LOCK_NB)) { + fclose (decpack); + decpack = NULL; + err = -2; + } + } else + err = -1; + cyl = -1; + dirty = NO; + memset (crcstate, 0, sizeof(crcstate)); + [rk8e updateStatusMountFlags]; + return err; +} + + +- (BOOL) unmount +{ + NSAssert (decpack != NULL, @"Cannot unmount without mounted DECpack"); + BOOL error = [self flush]; + flock (fileno(decpack), LOCK_UN); + fclose (decpack); + decpack = NULL; + [rk8e updateStatusMountFlags]; + return error; +} + + +- (BOOL) isMounted +{ + return decpack != NULL; +} + + +- (BOOL) isBusy +{ + return cmd != 0; +} + + +- (BOOL) isCalibrating +{ + return (cmd & RK05_RECALIBRATE) ? YES : NO; +} + + +- (void) stopCalibrating +{ + cmd &= ~RK05_RECALIBRATE; +} + + +- (void) abortAllCommands +{ + cmd = 0; +} + + +- (void) setStatusAndAbortAllCommands +{ + if (cmd) { + unsigned short set = 0; + if (cmd & RK05_RECALIBRATE) + set |= STATUS_CONTROL_BUSY; + else + set |= (STATUS_DONE | STATUS_ERROR); + if (cmd & RK05_SEEK) + set |= STATUS_HEAD_IN_MOTION; + cmd = 0; + [rk8e setStatusBits:set clearStatusBits:0]; + } +} + + +- (void) setRecalibrating +{ + durationMicroSeconds = 85000; // 85 ms == 200 track movement + cmd |= RK05_RECALIBRATE | RK05_DELAY; +} + + +- (void) setFlushCylinder +{ + if (dirty) + cmd |= RK05_FLUSH_CYL; +} + + +- (void) setReadCylinder:(unsigned short)cylinder +{ + if (cyl != cylinder) { + newcyl = cylinder; + cmd |= RK05_READ_CYL; + } +} + + +- (void) setRaiseFlag +{ + cmd |= RK05_RAISE_FLAG; +} + + +- (void) clearRaiseFlag +{ + cmd &= ~RK05_RAISE_FLAG; +} + + +- (void) setRead:(BOOL)read write:(BOOL)write all:(BOOL)all newBlock:(unsigned short)newBlock +{ + long d; + + if (write && locked) { + [rk8e setStatusBits:STATUS_WRITE_LOCK_ERROR | STATUS_ERROR clearStatusBits:0]; + return; + } + if (newBlock > 014537) { + [rk8e setStatusBits:STATUS_DONE | STATUS_ERROR clearStatusBits:0]; + return; + } + if (! read && ! write && [self isMounted]) { // seek only + /* set on DISK ADDRESS ACKNOWLAGE; it is set again + on seek complete when command bit 4 is on */ + [rk8e setStatusBits:STATUS_DONE clearStatusBits:0]; + cmd |= RK05_SEEK; + } + if (cyl != (newBlock >> 5)) { + if (dirty) + cmd |= RK05_FLUSH_CYL; + newcyl = newBlock >> 5; + cmd |= RK05_READ_CYL; + d = newcyl - cyl; + if (d < 0) + d = -d; + d = 9621l + 379l * d; + /* 9.621 ms for seek start/stop, 0.379 ms per track */ + } else if (read || write) { + d = ((long) (newBlock & 017)) - ((long) (blk & 017)); + if (d < 0) + d += 16; + /* d == # sectors between the last accessed sector and the new sector */ + if (d <= 1) { /* correctly, this must be "if (d == 1)", but + MAINDEC-08-DHRKB-E-PB test 28 (consecutive sector read all test) + seems to have a little bug: it starts with WRITE ALL sector 36, + then READ ALL sector 0 (two sectors distance) and often fails + immediately with Transfer Done not set. The test should start + with sector 37. */ + if (all) { /* read or write ALL can read consecutive sectors */ + d = 1; + } else { /* normal read can't read consecutive sectors */ + if (d == 1) + d = 16; + } + } + d *= 2500; /* 2.5 ms per sector, 40 ms per revolution */ + } else + d = 0; + durationMicroSeconds = d; + cmd |= RK05_DELAY; + blk = newBlock; /* DMAN may destroy rk8e.block */ + if (read) + cmd |= RK05_INPUT_BLOCK | RK05_RAISE_FLAG; + if (write) + cmd |= RK05_OUTPUT_BLOCK | RK05_RAISE_FLAG; +} + + +- (void) start +{ + NSDate *delayUntil = [[NSDate alloc] initWithTimeIntervalSinceNow:0.005]; // 5 ms + startAtMachAbsolute = mach_absolute_time(); + if ([commandsLock lockWhenCondition:NO_COMMANDS_AVAILABLE beforeDate:delayUntil]) { + [commandsLock unlockWithCondition:COMMANDS_AVAILABLE]; + } + [delayUntil release]; // don't use autorelease, this floods the PDP-8 run thread autorelease pool +} + + +static ushort CRC (const unsigned char *p) /* CRC with polygon x^16 + x^15 + x^2 + 1 */ +{ + register short i, j; + register unsigned long data; + register ushort crc; + + crc = i = 0; + while (i < 384) { + data = p[i++] << 4; + data |= p[i] >> 4; + data |= p[i++] << 20; + data |= p[i++] << 12; + for (j = 0; j < 24; j++) { + if ((data ^ crc) & 0x1) + crc = (crc >> 1) ^ 0xa001; + else + crc >>= 1; + data >>= 1; + } + } + return (crc); +} + + +- (void) processCommand +{ + register ushort *field; + register unsigned char *bp; + register ushort i; + register ushort words; + unsigned short rk8eBlock; + unsigned short rk8eCommand; + unsigned short clear, set; + + /* after processing a command, return, so that the next call can process higher priority + commands that may have been added in the meantime by the RK8-E control */ + if (cmd & RK05_FLUSH_CYL) { + [rk8e lockControl]; + cmd &= ~RK05_FLUSH_CYL; + if (driveNumber == [rk8e getCurrentDriveNumber]) + [rk8e setStatusBits:STATUS_HEAD_IN_MOTION clearStatusBits:0]; + cmd |= RK05_SEEK; + if (fseek(decpack, cyl * RK05_BUFSIZE, SEEK_SET) < 0) + [rk8e setStatusBits:STATUS_SEEK_FAILED clearStatusBits:0]; + else if (fwrite(buffer, 1, RK05_BUFSIZE, decpack) != RK05_BUFSIZE) + [rk8e setStatusBits:STATUS_ERROR clearStatusBits:0]; + else + dirty = 0; + [rk8e unlockControl]; + return; + } + if (cmd & RK05_READ_CYL) { + [rk8e lockControl]; + cmd &= ~RK05_READ_CYL; + if (cyl != newcyl) { + if (driveNumber == [rk8e getCurrentDriveNumber]) + [rk8e setStatusBits:STATUS_HEAD_IN_MOTION clearStatusBits:0]; + cmd |= RK05_SEEK; + cyl = newcyl; + if (fseek(decpack, 0, SEEK_END) < 0) + [rk8e setStatusBits:STATUS_SEEK_FAILED clearStatusBits:0]; + else if (ftell(decpack) < (cyl + 1) * RK05_BUFSIZE) + bzero (buffer, RK05_BUFSIZE); + else if (fseek(decpack, cyl * RK05_BUFSIZE, SEEK_SET) < 0) + [rk8e setStatusBits:STATUS_SEEK_FAILED clearStatusBits:0]; + else if (fread(buffer, 1, RK05_BUFSIZE, decpack) != RK05_BUFSIZE) + [rk8e setStatusBits:STATUS_ERROR clearStatusBits:0]; + } + [rk8e unlockControl]; + return; + } + if (cmd & RK05_INPUT_BLOCK) { + [rk8e lockControl]; + if (! [rk8e isCRCOK]) + [rk8e setStatusBits:STATUS_CYLINDER_ADDRESS_ERROR clearStatusBits:0]; +/* + * Read a sector from the RK8E disk file. The file packing scheme: + * <- 8 bits-> + * +---------+ 0H => High order of pdp8 word 0 + * | 0H | 0L => Low order of pdp8 word 0 + * +----+----+ 1H => High order of pdp8 word 1 + * | 0L | 1H | 1L => Low order of pdp8 word 1 + * +----+----+ + * | 1L | In other words, pdp8 words are written + * +----+----+ in bit order (high to low). + */ + rk8eBlock = [rk8e getBlockNumber]; + bp = buffer + (rk8eBlock & 037) * 384; + [rk8e setCRC:CRC(bp)]; + rk8eCommand = [rk8e getCommand]; + words = (rk8eCommand & COMMAND_HALF_BLOCK) ? 64 : 128; /* half of words to transfer */ + field = [pdp8 directMemoryAccess] + ((rk8eCommand & 070) << 9); + i = [rk8e getCurrentAddress]; + if (field < [pdp8 directMemoryAccess] + [pdp8 memorySize]) { + while (words--) { /* two words per loop */ + field[i & 07777] = *bp++ << 4; + field[i++ & 07777] |= *bp >> 4; + field[i & 07777] = (*bp++ & 017) << 8; + field[i++ & 07777] |= *bp++; + } + [pdp8 directMemoryWriteFinished]; + } + words = (rk8eCommand & COMMAND_HALF_BLOCK) ? 128 : 256; + [rk8e setCurrentAddress:([rk8e getCurrentAddress] + words) & 07777]; + cmd &= ~RK05_INPUT_BLOCK; + if (crcstate[rk8eBlock >> 3] & (1 << (rk8eBlock & 7))) + [rk8e setStatusBits:STATUS_CRC_ERROR clearStatusBits:0]; + [rk8e unlockControl]; + return; + } + if (cmd & RK05_OUTPUT_BLOCK) { + [rk8e lockControl]; + if (! [rk8e isCRCOK]) + [rk8e setStatusBits:STATUS_CYLINDER_ADDRESS_ERROR clearStatusBits:0]; + rk8eBlock = [rk8e getBlockNumber]; + bp = (unsigned char *) buffer + (rk8eBlock & 037) * 384; + rk8eCommand = [rk8e getCommand]; + words = (rk8eCommand & COMMAND_HALF_BLOCK) ? 64 : 128; /* half of words to transfer */ + field = [pdp8 directMemoryAccess] + ((rk8eCommand & 070) << 9); + i = [rk8e getCurrentAddress]; + while (words--) { /* two words per loop */ + *bp++ = field[i & 07777] >> 4; + *bp = field[i++ & 07777] << 4; + *bp++ |= field[i & 07777] >> 8; + *bp++ = field[i++ & 07777]; + } + if (rk8eCommand & COMMAND_HALF_BLOCK) { + for (i = 0; i < 192; i++) + *bp++ = 0; + } + [rk8e setCRC:CRC(bp - 384)]; + words = (rk8eCommand & COMMAND_HALF_BLOCK) ? 128 : 256; + [rk8e setCurrentAddress:([rk8e getCurrentAddress] + words) & 07777]; + dirty = true; + cmd &= ~RK05_OUTPUT_BLOCK; + cmd |= RK05_SET_CRC_STATE; + [rk8e unlockControl]; + return; + } + if (cmd & RK05_DELAY) { + // don't lock the control + cmd &= ~RK05_DELAY; + int speed = [pdp8 getGoSpeed]; + if (speed != GO_AS_FAST_AS_POSSIBLE) { + uint64_t delayUntilAbsolute = startAtMachAbsolute + + nanoseconds2absolute(durationMicroSeconds * 1000ll); + if (speed == GO_WITH_PDP8_SPEED) + mach_wait_until (delayUntilAbsolute); + else { + while (mach_absolute_time() < delayUntilAbsolute) + ; + } + } + // don't unlock the control + return; + } + if (cmd & RK05_SET_CRC_STATE) { + [rk8e lockControl]; + cmd &= ~RK05_SET_CRC_STATE; + words = 1 << (blk & 7); + if ([rk8e isCRCOK]) + crcstate[blk >> 3] &= ~words; + else + crcstate[blk >> 3] |= words; + [rk8e unlockControl]; + return; + } + if (cmd & (RK05_RECALIBRATE | RK05_SEEK | RK05_RAISE_FLAG)) { + [rk8e lockControl]; + set = clear = 0; + if (cmd & RK05_RAISE_FLAG) { + set = STATUS_DONE; + if (driveNumber == [rk8e getCurrentDriveNumber]) + clear |= STATUS_HEAD_IN_MOTION; + if (! [rk8e isCRCOK]) + set |= STATUS_CYLINDER_ADDRESS_ERROR; + } + if (cmd & (RK05_RECALIBRATE | RK05_SEEK)) { + if (driveNumber == [rk8e getCurrentDriveNumber]) { + if ([rk8e getCommand] & COMMAND_SET_DONE_ON_SEEK_DONE) + set = STATUS_DONE; + clear = STATUS_HEAD_IN_MOTION; + } + } + [rk8e setStatusBits:set clearStatusBits:clear]; + cmd &= ~(RK05_RAISE_FLAG | RK05_RECALIBRATE | RK05_SEEK); + [rk8e unlockControl]; + return; + } +} + + +- (void) rk05Thread:(id)object +{ + [[NSAutoreleasePool alloc] init]; + for (;;) { + [commandsLock lockWhenCondition:COMMANDS_AVAILABLE]; + while (cmd) + [self processCommand]; + [commandsLock unlockWithCondition:NO_COMMANDS_AVAILABLE]; + } +} + + +- (void) awakeFromNib +{ + commandsLock = [[NSConditionLock alloc] initWithCondition:NO_COMMANDS_AVAILABLE]; + [NSThread detachNewThreadSelector:@selector(rk05Thread:) toTarget:self withObject:nil]; +} + + +@end diff --git a/RK8E/RK05Controller.h b/RK8E/RK05Controller.h new file mode 100644 index 0000000..0813680 --- /dev/null +++ b/RK8E/RK05Controller.h @@ -0,0 +1,40 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK05Controller.h - Controller for RK05 view + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class RK05; + + +@interface RK05Controller : NSObject { +@private + IBOutlet NSButton *mountUnmountButton; + IBOutlet NSButton *writeProtectCheckbox; + IBOutlet NSTextField *filenameField; + IBOutlet RK05 *rk05; + NSString *decpackPath; +} + +- (IBAction) mountUnmountClicked:(id)sender; +- (IBAction) writeProtectClicked:(id)sender; + +@end diff --git a/RK8E/RK05Controller.m b/RK8E/RK05Controller.m new file mode 100644 index 0000000..19d7885 --- /dev/null +++ b/RK8E/RK05Controller.m @@ -0,0 +1,252 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK05Controller.m - Controller for RK05 view + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/Utilities.h" +#import "PluginFramework/Unicode.h" +#import "PluginFramework/NSControl+FileDrop.h" +#import "PluginFramework/FileDropControlTargetProtocol.h" + +#import "RK05Controller.h" +#import "RK05.h" + + +#define DECPACK_HFS_TYPE_CODE 0x524b3845l // 'RK8E', for compatibility with the old simulator +#define DECPACK_EXTENSION_RK05 @"rk05" +#define DECPACK_EXTENSION_DECPACK @"decpack" + +#define CODER_KEY_RK05_PATH_FMT @"rk05path%d" +#define CODER_KEY_RK05_LOCK_FMT @"rk05lock%d" + + +@implementation RK05Controller + + +- (IBAction) writeProtectClicked:(id)sender +{ + [rk05 setWriteProtected:[sender intValue]]; +} + + +- (void) notifyWriteProtectChanged:(NSNotification *)notification +{ + // NSLog (@"RK05Controller notifyWriteProtectChanged"); + [writeProtectCheckbox setIntValue:[rk05 isWriteProtected]]; +} + + +- (void) updateMountButton:(NSString *)path +{ + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + if (path) { + decpackPath = [path retain]; + [filenameField setStringValue:[[NSFileManager defaultManager] displayNameAtPath:path]]; + [filenameField setHidden:NO]; + [mountUnmountButton setTitle: + NSLocalizedStringFromTableInBundle(@"Unmount", nil, bundle, @"")]; + [mountUnmountButton unregisterAsFileDropTarget]; + } else { + [mountUnmountButton setTitle: + NSLocalizedStringFromTableInBundle(@"Mount", nil, bundle, @"")]; + [mountUnmountButton registerAsFileDropTarget]; + [filenameField setHidden:YES]; + [decpackPath release]; + decpackPath = nil; + } +} + + +- (BOOL) mount:(NSString *)path create:(BOOL)create +{ + int err = [rk05 mount:path create:create]; + if (err) { + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + NSAlert *alert = [[NSAlert alloc] init]; + [alert setMessageText:err == -1 ? + (create ? + NSLocalizedStringFromTableInBundle( + @"Cannot create this DECpack.", nil, bundle, @"") : + NSLocalizedStringFromTableInBundle( + @"Cannot mount this DECpack, maybe it is write protected.", + nil, bundle, @"")) : + NSLocalizedStringFromTableInBundle( + @"This DECpack is already mounted to another RK05 drive.", nil, bundle, @"") + ]; + [alert setInformativeText:path]; + [alert beginSheetModalForWindow:[mountUnmountButton window] + modalDelegate:nil didEndSelector:nil contextInfo:nil]; + [alert release]; + } else + [self updateMountButton:path]; + return err == 0; +} + + +- (void) panelDidEnd:(NSSavePanel *)panel return:(int)ret context:(void *)context +{ + if (ret == NSOKButton) { + [panel close]; + [self mount:[panel filename] create:[panel isMemberOfClass:[NSSavePanel class]]]; + } + [[NSUserDefaults standardUserDefaults] setObject:[panel directory] forKey:LAST_FILE_PANEL_DIR_KEY]; +} + + +- (NSArray *) openFileTypes +{ + return [NSArray arrayWithObjects:DECPACK_EXTENSION_RK05, DECPACK_EXTENSION_DECPACK, + NSFileTypeForHFSTypeCode(DECPACK_HFS_TYPE_CODE), nil]; +} + + +- (IBAction) mountUnmountClicked:(id)sender +{ + if ([rk05 isMounted]) { + if ([rk05 unmount]) { + NSAlert *alert = [[NSAlert alloc] init]; + [alert setMessageText:NSLocalizedStringFromTableInBundle( + @"An error occured while closing the DECpack. " + "The data on that DECpack might be corrupt.", nil, + [NSBundle bundleForClass:[self class]], @"")]; + [alert setInformativeText:[filenameField stringValue]]; + [alert beginSheetModalForWindow:[mountUnmountButton window] + modalDelegate:nil didEndSelector:nil contextInfo:nil]; + [alert release]; + } + [self updateMountButton:nil]; + } else { + if ([[NSApp currentEvent] modifierFlags] & NSAlternateKeyMask) { + NSSavePanel *savePanel = [NSSavePanel savePanel]; + [savePanel setRequiredFileType:@"rk05"]; + [savePanel beginSheetForDirectory: + [[NSUserDefaults standardUserDefaults] stringForKey:LAST_FILE_PANEL_DIR_KEY] + file:nil modalForWindow:[mountUnmountButton window] modalDelegate:self + didEndSelector:@selector(panelDidEnd:return:context:) contextInfo:nil]; + } else + [[NSOpenPanel openPanel] beginSheetForDirectory: + [[NSUserDefaults standardUserDefaults] stringForKey:LAST_FILE_PANEL_DIR_KEY] + file:nil types:[self openFileTypes] + modalForWindow:[mountUnmountButton window] modalDelegate:self + didEndSelector:@selector(panelDidEnd:return:context:) contextInfo:nil]; + } +} + + +- (void) setDecpackPathAndMountAtStartup:(NSString *)path +{ + if (path == nil) + return; + if ([rk05 mount:path create:NO]) { + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + NSAlert *alert = [[NSAlert alloc] init]; + [alert setMessageText:[NSString stringWithFormat:NSLocalizedStringFromTableInBundle( + @"The following DECpack could not be found. It was mounted on RK05 drive %d. " + "Do you want to locate it?", nil, bundle, @""), [rk05 driveNumber]]]; + [alert setInformativeText:path]; + [[alert addButtonWithTitle:NSLocalizedStringFromTableInBundle(@"Yes", nil, bundle, @"")] + setKeyEquivalent:@"\r"]; + [[alert addButtonWithTitle:NSLocalizedStringFromTableInBundle(@"No", nil, bundle, @"")] + setKeyEquivalent:@"\e"]; + if ([alert runModal] == NSAlertFirstButtonReturn) { + NSOpenPanel *openPanel = [NSOpenPanel openPanel]; + [openPanel setTitle:[NSString stringWithFormat: + NSLocalizedStringFromTableInBundle(@"Locate the DECpack %C%@%C", + nil, bundle, @""), + UNICODE_LEFT_DOUBLEQUOTE, + [[NSFileManager defaultManager] displayNameAtPath:path], + UNICODE_RIGHT_DOUBLEQUOTE]]; + if ([openPanel runModalForDirectory: + [[NSUserDefaults standardUserDefaults] stringForKey:LAST_FILE_PANEL_DIR_KEY] + file:nil types:[self openFileTypes]] == NSOKButton) + [self mount:[openPanel filename] create:NO]; + [[NSUserDefaults standardUserDefaults] + setObject:[openPanel directory] forKey:LAST_FILE_PANEL_DIR_KEY]; + } + [alert release]; + } else + [self updateMountButton:path]; +} + + +#pragma mark FileDropControlTarget Protocol + + +- (BOOL) willAcceptFile:(NSString *)path +{ + NSString *extension = [path pathExtension]; + if ([extension isEqualToString:DECPACK_EXTENSION_RK05] || + [extension isEqualToString:DECPACK_EXTENSION_DECPACK] || + [NSHFSTypeOfFile(path) isEqualToString:NSFileTypeForHFSTypeCode(DECPACK_HFS_TYPE_CODE)]) { + return [rk05 canMount:path]; + } + return NO; +} + + +- (BOOL) acceptFile:(NSString *)path +{ + return [self mount:path create:NO]; +} + + +#pragma mark Initialization + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(notifyWriteProtectChanged:) + name:WRITEPROTECT_CHANGED_NOTIFICATION object:nil]; + [mountUnmountButton registerAsFileDropTarget]; + if (runningOnLionOrNewer()) { + // Make the textured button a normal push button of the same size, otherwise + // the label is not centered vertically and aligned with the "Write Proctect" label + NSRect rect = [mountUnmountButton frame]; + [mountUnmountButton setBezelStyle:NSRoundedBezelStyle]; + [mountUnmountButton setFrame:NSInsetRect(NSOffsetRect(rect, 0, -1), -5, -2)]; + } + int drive = [mountUnmountButton tag]; + [rk05 setDriveNumber:drive]; + [self setDecpackPathAndMountAtStartup: + [coder decodeObjectForKey:[NSString stringWithFormat:CODER_KEY_RK05_PATH_FMT, drive]]]; + [rk05 setWriteProtected: + [coder decodeBoolForKey:[NSString stringWithFormat:CODER_KEY_RK05_LOCK_FMT, drive]]]; + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + int drive = [rk05 driveNumber]; + [coder encodeObject:decpackPath forKey: + [NSString stringWithFormat:CODER_KEY_RK05_PATH_FMT, drive]]; + [coder encodeBool:[rk05 isWriteProtected] forKey: + [NSString stringWithFormat:CODER_KEY_RK05_LOCK_FMT, drive]]; + [rk05 flush]; +} + + +@end diff --git a/RK8E/RK8E.h b/RK8E/RK8E.h new file mode 100644 index 0000000..37f26e2 --- /dev/null +++ b/RK8E/RK8E.h @@ -0,0 +1,141 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK8E.h - RK8-E Disk Cartridge System for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#define COMMAND_CHANGED_NOTIFICATION @"rk8eCommandChangedNotification" +#define STATUS_CHANGED_NOTIFICATION @"rk8eStatusChangedNotification" +#define BLOCKNUMBER_CHANGED_NOTIFICATION @"rk8eBlockNumberChangedNotification" +#define MEMORYADDRESS_CHANGED_NOTIFICATION @"rk8eMemoryAddressChangedNotification" + + +/* RK8-E status flags */ +#define STATUS_DONE 04000 +#define STATUS_HEAD_IN_MOTION 02000 +#define STATUS_UNUSED 01000 +#define STATUS_SEEK_FAILED 00400 +#define STATUS_FILE_NOT_READY 00200 +#define STATUS_CONTROL_BUSY 00100 +#define STATUS_TIMING_ERROR 00040 +#define STATUS_WRITE_LOCK_ERROR 00020 +#define STATUS_CRC_ERROR 00010 +#define STATUS_DATA_REQUEST_LATE 00004 +#define STATUS_ERROR 00002 +#define STATUS_CYLINDER_ADDRESS_ERROR 00001 + +//#define STATUS_RAISE_FLAG_MASK 04153 // This is the value from PDP-8/E Simulator 1.x. Why? +#define STATUS_RAISE_FLAG_MASK 04142 + + +/* RK8-E command bits */ +#define COMMAND_FUNCTION_MASK 07000 +#define COMMAND_FUNCTION_READ 00000 +#define COMMAND_FUNCTION_READ_ALL 01000 +#define COMMAND_FUNCTION_LOCK 02000 +#define COMMAND_FUNCTION_SEEK 03000 +#define COMMAND_FUNCTION_WRITE 04000 +#define COMMAND_FUNCTION_WRITE_ALL 05000 +#define COMMAND_INTERRUPT_ON_DONE 00400 +#define COMMAND_SET_DONE_ON_SEEK_DONE 00200 +#define COMMAND_HALF_BLOCK 00100 +#define COMMAND_EXTENDED_ADDRESS_MASK 00070 +#define COMMAND_DRIVE_SELECT_MASK 00006 +#define COMMAND_BLOCK_NUMBER_MSB 00001 + + +@class RK05, RK05Controller; + + +@interface RK8E : PDP8Plugin +{ +@private + IBOutlet RK05 *rk05_0; + IBOutlet RK05 *rk05_1; + IBOutlet RK05 *rk05_2; + IBOutlet RK05 *rk05_3; + IBOutlet RK05Controller *rk05Controller_0; + IBOutlet RK05Controller *rk05Controller_1; + IBOutlet RK05Controller *rk05Controller_2; + IBOutlet RK05Controller *rk05Controller_3; + NSLock *controlLock; +@public +/* The attributes are public, so the C functions implementing the PDP-8 instructions can + access them directly. No other Cocoa code should use them directly. To ensure this, + the register names are mapped to dummy names with the #defines below. In the source + codes files with the instruction C functions, #define USE_RK8E_REGISTERS_DIRECTLY + to make the registers available. */ + RK05 *rk05[4]; // array of the four pointers above set while initialization + unsigned short command; + volatile unsigned short status; + unsigned short block; // 13 bit value + unsigned short curaddr; + unsigned long ioflag; + BOOL maint; // the following registers for maintenance mode + unsigned short ldb[4]; // lower data buffer + unsigned char ldbfill; // how many lower data buffers are full + unsigned short udb; // upper data buffer + unsigned short crc; // checksum + unsigned short checkcrc; // needed for check if DMAN can destroy the CRC + unsigned char shifts; // how many shifts occured for udb or ldb + unsigned short wordcount; // word count for data breaks + BOOL shiftEnabled; // DMAN with AC=2000 was issued +} + +- (unsigned short) getCommand; +- (void) setCommand:(unsigned short)cmd; +- (unsigned short) getStatus; +- (void) setStatus:(unsigned short)stat; +- (unsigned short) getBlockNumber; // 13 bit value including most significant bit +- (void) setBlockNumber:(unsigned short)blk; // from command register +- (unsigned short) getMemoryAddress; // 15 bit value including extended address +- (void) setMemoryAddress:(unsigned short)addr; // from command register +- (unsigned short) getCurrentAddress; +- (void) setCurrentAddress:(unsigned short)addr; + +- (unsigned short) getCurrentDriveNumber; +- (void) updateStatusMountFlags; +- (void) setStatusBits:(unsigned)set clearStatusBits:(unsigned)clear; +- (void) setCRC:(unsigned)newCRC; +- (BOOL) isCRCOK; +- (void) lockControl; +- (void) unlockControl; + +@end + + +#if ! USE_RK8E_REGISTERS_DIRECTLY +#define rk05 __dont_use_rk05__ +#define command __dont_use_command__ +#define status __dont_use_status__ +#define block __dont_use_block__ +#define address __dont_use_address__ +#define curaddr __dont_use_curraddr__ +#define ioflag __dont_use_ioflag__ +#define maint __dont_use_maint__ +#define ldb __dont_use_ldb__ +#define ldbfill __dont_use_ldbfill__ +#define crc __dont_use_crc__ +#define shifts __dont_use_shifts__ +#define wordcount __dont_use_wordcount__ +#define checkcrc __dont_use_checkcrc__ +#define shiftEnabled __dont_use_shiftEnabled__ +#endif diff --git a/RK8E/RK8E.m b/RK8E/RK8E.m new file mode 100644 index 0000000..2299de5 --- /dev/null +++ b/RK8E/RK8E.m @@ -0,0 +1,427 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK8E.m - RK8-E Disk Cartridge System for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" +#import "PluginFramework/Utilities.h" +#import "PluginFramework/FileDropControlTargetProtocol.h" +#import "PluginFramework/NSThread+MainThread.h" + +#define USE_RK8E_REGISTERS_DIRECTLY 1 + +#import "RK8E.h" +#import "RK8Eiot.h" +#import "RK05.h" +#import "RK05Controller.h" + + +#define CODER_KEY_COMMAND @"cmd" +#define CODER_KEY_STATUS @"status" +#define CODER_KEY_BLOCK @"block" +#define CODER_KEY_CURADDR @"curaddr" +#define CODER_KEY_IOFLAG @"ioflag" +#define CODER_KEY_IOMASK @"iomask" +#define CODER_KEY_MAINT @"maint" +#define CODER_KEY_LDB0 @"ldb0" +#define CODER_KEY_LDB1 @"ldb1" +#define CODER_KEY_LDB2 @"ldb2" +#define CODER_KEY_LDB3 @"ldb3" +#define CODER_KEY_LDBFILL @"ldbfill" +#define CODER_KEY_UDB @"udb" +#define CODER_KEY_CRC @"crc" +#define CODER_KEY_CHECKCRC @"checkcrc" +#define CODER_KEY_SHIFTS @"shifts" +#define CODER_KEY_WORDCOUNT @"wordcount" +#define CODER_KEY_SHIFT_ENABLE @"shiftena" + + +@implementation RK8E + + +API_VERSION + + +#pragma mark Plugin Methods + + +- (NSArray *) iotsForAddress:(int)ioAddress +{ + return [NSArray arrayWithObjects: + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:i6741], + [NSValue valueWithPointer:i6742], + [NSValue valueWithPointer:i6743], + [NSValue valueWithPointer:i6744], + [NSValue valueWithPointer:i6745], + [NSValue valueWithPointer:i6746], + [NSValue valueWithPointer:i6747], + nil]; +} + + +- (NSArray *) skiptestsForAddress:(int)ioAddress +{ + return [NSArray arrayWithObjects: + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6741], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + nil]; + +} + + +- (void) setIOFlag:(unsigned long)flag forIOFlagName:(NSString *)name; +{ + ioflag = flag; +} + + +- (void) resetInternalRegisters +{ + maint = NO; + ldb[0] = ldb[1] = ldb[2] = ldb[3] = 0; + ldbfill = 0; + udb = 0; + crc = 0; + checkcrc = 0; + shifts = 0; + wordcount = 0; + shiftEnabled = NO; +} + + +- (void) CAF:(int)ioAddress +{ + command = 0; + block = 0; + status = [rk05[0] isMounted] ? 0 : STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY; + curaddr = 0; + [self resetInternalRegisters]; + [pdp8 clearIOFlagBits:ioflag]; + [pdp8 clearInterruptMaskBits:ioflag]; + [rk05[0] abortAllCommands]; + [rk05[1] abortAllCommands]; + [rk05[2] abortAllCommands]; + [rk05[3] abortAllCommands]; +} + + +- (void) clearAllFlags:(int)ioAddress +{ + [self setCommand:0]; + [self setBlockNumber:0]; + [self setStatus:0]; + [self updateStatusMountFlags]; + [self setMemoryAddress:0]; + [self resetInternalRegisters]; + [pdp8 clearIOFlagBits:ioflag]; + [pdp8 clearInterruptMaskBits:ioflag]; + [rk05[0] abortAllCommands]; + [rk05[1] abortAllCommands]; + [rk05[2] abortAllCommands]; + [rk05[3] abortAllCommands]; +} + + +- (void) resetDevice +{ + [self clearAllFlags:0]; + [rk05[0] setWriteProtected:NO]; + [rk05[1] setWriteProtected:NO]; + [rk05[2] setWriteProtected:NO]; + [rk05[3] setWriteProtected:NO]; +} + + +#pragma mark Register Access + + +- (unsigned short) getCommand +{ + return command; +} + + +- (void) setCommand:(unsigned short)cmd +{ + NSAssert1 ((cmd & ~07777) == 0, @"Bad RK8-E Command: 0%o", cmd); + command = cmd; + if (command & COMMAND_INTERRUPT_ON_DONE) + [pdp8 setInterruptMaskBits:ioflag]; + else + [pdp8 clearInterruptMaskBits:ioflag]; + [self updateStatusMountFlags]; + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + [defaultCenter postNotificationName:COMMAND_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:MEMORYADDRESS_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:BLOCKNUMBER_CHANGED_NOTIFICATION object:self]; +} + + +- (void) notifyPDP8IOFlagsChanged:(NSNotification *)notification +{ + //NSLog (@"RK8E notifyPDP8IOFlagsChanged"); + if ([pdp8 getInterruptMaskBits:ioflag]) + command |= COMMAND_INTERRUPT_ON_DONE; + else + command &= ~COMMAND_INTERRUPT_ON_DONE; + [[NSNotificationCenter defaultCenter] postNotificationName:COMMAND_CHANGED_NOTIFICATION object:self]; + if ([pdp8 getIOFlagBits:ioflag]) { + if (! (status & STATUS_RAISE_FLAG_MASK)) + status |= STATUS_DONE; + } else + status &= ~STATUS_RAISE_FLAG_MASK; + [[NSNotificationCenter defaultCenter] postNotificationName:STATUS_CHANGED_NOTIFICATION object:self]; +} + + +- (unsigned short) getStatus +{ + return status; +} + + +- (void) setStatus:(unsigned short)stat +{ + NSAssert1 ((stat & ~07777) == 0, @"Bad RK8-E Status: 0%o", stat); + status = stat; + if (status & STATUS_RAISE_FLAG_MASK) + [pdp8 setIOFlagBits:ioflag]; + else + [pdp8 clearIOFlagBits:ioflag]; + [[NSNotificationCenter defaultCenter] postNotificationName:STATUS_CHANGED_NOTIFICATION object:self]; +} + + +- (void) updateStatusMountFlags +{ + NSAssertRunningOnMainThread (); + if ([rk05[(command >> 1) & 3] isMounted]) + status &= ~(STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY); + else + status |= STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY; + [[NSNotificationCenter defaultCenter] postNotificationName:STATUS_CHANGED_NOTIFICATION object:self]; +} + + +- (void) notifyStatusChangedWhenNotRunning +{ + NSAssertRunningOnMainThread (); + NSAssert (! [pdp8 isGoing], @"PDP-8 is running"); + [[NSNotificationCenter defaultCenter] postNotificationName:STATUS_CHANGED_NOTIFICATION object:self]; +} + + +- (void) setStatusBits:(unsigned)set clearStatusBits:(unsigned)clear +{ + status |= set; + status &= ~clear; + if (status & STATUS_RAISE_FLAG_MASK) + [pdp8 setIOFlagBits:ioflag]; + else + [pdp8 clearIOFlagBits:ioflag]; + if (! [pdp8 isGoing]) + [self performSelectorOnMainThread:@selector(notifyStatusChangedWhenNotRunning) + withObject:nil waitUntilDone:YES]; +} + + +- (unsigned short) getBlockNumber +{ + return ((command & 1) << 12) | block; +} + + +- (void) setBlockNumber:(unsigned short)blk +{ + NSAssert1 ((blk & ~017777) == 0, @"Bad RK8-E Block Number: 0%o", blk); + block = blk & 07777; + [[NSNotificationCenter defaultCenter] postNotificationName:BLOCKNUMBER_CHANGED_NOTIFICATION + object:self]; + [self setCommand:([self getCommand] & 07776) | (blk >> 12)]; +} + + +- (unsigned short) getMemoryAddress +{ + return ((command & 070) << 9) | curaddr; +} + + +- (void) setMemoryAddress:(unsigned short)addr +{ + NSAssert1 ((addr & ~077777) == 0, @"Bad RK8-E Memory Address: 0%o", addr); + curaddr = addr & 07777; + [[NSNotificationCenter defaultCenter] postNotificationName:MEMORYADDRESS_CHANGED_NOTIFICATION + object:self]; + [self setCommand:([self getCommand] & 07707) | ((addr >> 9) & 070)]; +} + + +- (unsigned short) getCurrentAddress +{ + return curaddr; +} + + +- (void) setCurrentAddress:(unsigned short)addr +{ + NSAssert1 ((addr & ~07777) == 0, @"Bad Current Address: 0%o", addr); + curaddr = addr; +} + + +- (unsigned short) getCurrentDriveNumber +{ + return (command >> 1) & 3; +} + + +- (void) setCRC:(unsigned)newCRC +{ + crc = checkcrc = newCRC; +} + + +- (BOOL) isCRCOK +{ + return crc == checkcrc; +} + + +- (void) lockControl +{ + [controlLock lock]; +} + + +- (void) unlockControl +{ + [controlLock unlock]; +} + + +#pragma mark Initialization + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + [self setCommand:[coder decodeIntForKey:CODER_KEY_COMMAND]]; + [self setStatus:[coder decodeIntForKey:CODER_KEY_STATUS]]; + [self setBlockNumber:[coder decodeIntForKey:CODER_KEY_BLOCK]]; + [self setCurrentAddress:[coder decodeIntForKey:CODER_KEY_CURADDR]]; + [coder decodeBoolForKey:CODER_KEY_IOFLAG] ? + [pdp8 setIOFlagBits:ioflag] : [pdp8 clearIOFlagBits:ioflag]; + [coder decodeBoolForKey:CODER_KEY_IOMASK] ? + [pdp8 setInterruptMaskBits:ioflag] : [pdp8 clearInterruptMaskBits:ioflag]; + maint = [coder decodeBoolForKey:CODER_KEY_MAINT]; + ldb[0] = [coder decodeIntForKey:CODER_KEY_LDB0]; + ldb[1] = [coder decodeIntForKey:CODER_KEY_LDB1]; + ldb[2] = [coder decodeIntForKey:CODER_KEY_LDB2]; + ldb[3] = [coder decodeIntForKey:CODER_KEY_LDB3]; + ldbfill = [coder decodeIntForKey:CODER_KEY_LDBFILL]; + udb = [coder decodeIntForKey:CODER_KEY_UDB]; + crc = [coder decodeIntForKey:CODER_KEY_CRC]; + checkcrc = [coder decodeIntForKey:CODER_KEY_CHECKCRC]; + shifts = [coder decodeIntForKey:CODER_KEY_SHIFTS]; + wordcount = [coder decodeIntForKey:CODER_KEY_WORDCOUNT]; + shiftEnabled = [coder decodeBoolForKey:CODER_KEY_SHIFT_ENABLE]; + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + [coder encodeInt:[self getCommand] forKey:CODER_KEY_COMMAND]; + [coder encodeInt:[self getStatus] forKey:CODER_KEY_STATUS]; + [coder encodeInt:[self getBlockNumber] forKey:CODER_KEY_BLOCK]; + [coder encodeInt:[self getCurrentAddress] forKey:CODER_KEY_CURADDR]; + [coder encodeBool:[pdp8 getIOFlagBits:ioflag] ? YES : NO forKey:CODER_KEY_IOFLAG]; + [coder encodeBool:[pdp8 getInterruptMaskBits:ioflag] ? YES : NO forKey:CODER_KEY_IOMASK]; + [coder encodeBool:maint forKey:CODER_KEY_MAINT]; + [coder encodeInt:ldb[0] forKey:CODER_KEY_LDB0]; + [coder encodeInt:ldb[1] forKey:CODER_KEY_LDB1]; + [coder encodeInt:ldb[2] forKey:CODER_KEY_LDB2]; + [coder encodeInt:ldb[3] forKey:CODER_KEY_LDB3]; + [coder encodeInt:ldbfill forKey:CODER_KEY_LDBFILL]; + [coder encodeInt:udb forKey:CODER_KEY_UDB]; + [coder encodeInt:crc forKey:CODER_KEY_CRC]; + [coder encodeInt:checkcrc forKey:CODER_KEY_CHECKCRC]; + [coder encodeInt:shifts forKey:CODER_KEY_SHIFTS]; + [coder encodeInt:wordcount forKey:CODER_KEY_WORDCOUNT]; + [coder encodeBool:shiftEnabled forKey:CODER_KEY_SHIFT_ENABLE]; +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"RK8E notifyApplicationWillTerminate"); + NSMutableData *data = [NSMutableData data]; + NSKeyedArchiver *archiver = [[NSKeyedArchiver alloc] initForWritingWithMutableData:data]; + [self encodeWithCoder:archiver]; + [rk05Controller_0 encodeWithCoder:archiver]; + [rk05Controller_1 encodeWithCoder:archiver]; + [rk05Controller_2 encodeWithCoder:archiver]; + [rk05Controller_3 encodeWithCoder:archiver]; + [archiver finishEncoding]; + [archiver release]; + [[NSUserDefaults standardUserDefaults] setObject:data forKey:[self pluginName]]; +} + + +- (void) pluginDidLoad +{ + rk05[0] = rk05_0; [rk05[0] setPDP8:pdp8]; + rk05[1] = rk05_1; [rk05[1] setPDP8:pdp8]; + rk05[2] = rk05_2; [rk05[2] setPDP8:pdp8]; + rk05[3] = rk05_3; [rk05[3] setPDP8:pdp8]; + NSData *data = [[NSUserDefaults standardUserDefaults] dataForKey:[self pluginName]]; + if (data) { + NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data]; + self = [self initWithCoder:unarchiver]; + [rk05Controller_0 initWithCoder:unarchiver]; + [rk05Controller_1 initWithCoder:unarchiver]; + [rk05Controller_2 initWithCoder:unarchiver]; + [rk05Controller_3 initWithCoder:unarchiver]; + [unarchiver finishDecoding]; + [unarchiver release]; + } + controlLock = [[NSLock alloc] init]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(notifyPDP8IOFlagsChanged:) + name:IOFLAGS_CHANGED_NOTIFICATION object:nil]; +} + + +@end diff --git a/RK8E/RK8EController.h b/RK8E/RK8EController.h new file mode 100644 index 0000000..890c27b --- /dev/null +++ b/RK8E/RK8EController.h @@ -0,0 +1,61 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK8EController.h - Controller for RK8-E register view + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class RK8E, RegisterFormCell, KeepInMenuWindow; + + +@interface RK8EController : NSObject { +@private + IBOutlet RK8E *rk8e; + IBOutlet KeepInMenuWindow *window; + IBOutlet NSBox *rk8eBox; + IBOutlet RegisterFormCell *commandRegister; + IBOutlet NSPopUpButton *cmdFunction; + IBOutlet NSPopUpButton *cmdInterrupt; + IBOutlet NSPopUpButton *cmdSetDone; + IBOutlet NSPopUpButton *cmdBlockLength; + IBOutlet NSPopUpButton *cmdExtendedAddress; + IBOutlet NSPopUpButton *cmdDriveSelect; + IBOutlet NSPopUpButton *cmdBlockNumberMSB; + IBOutlet RegisterFormCell *statusRegister; + IBOutlet NSButton *statusTransferDone; + IBOutlet NSButton *statusHeadInMotion; + IBOutlet NSButton *statusUnused; + IBOutlet NSButton *statusSeekFailed; + IBOutlet NSButton *statusFileNotReady; + IBOutlet NSButton *statusControlBusy; + IBOutlet NSButton *statusTimingError; + IBOutlet NSButton *statusWriteLockError; + IBOutlet NSButton *statusCRCError; + IBOutlet NSButton *statusDataRequestLate; + IBOutlet NSButton *statusDriveStatusError; + IBOutlet NSButton *statusCylinderAddressError; + IBOutlet RegisterFormCell *blockNumberRegister; + IBOutlet RegisterFormCell *memoryAddressRegister; +} + +- (IBAction) commandPopupClicked:(id)sender; +- (IBAction) statusCheckboxClicked:(id)sender; + +@end diff --git a/RK8E/RK8EController.m b/RK8E/RK8EController.m new file mode 100644 index 0000000..712f324 --- /dev/null +++ b/RK8E/RK8EController.m @@ -0,0 +1,184 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK8EController.h - Controller for RK8-E register view + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" +#import "PluginFramework/RegisterFormCell.h" +#import "PluginFramework/KeepInMenuWindow.h" + +#import "RK8EController.h" +#import "RK8E.h" + + +@implementation RK8EController + + +/* The tags of the popups contain in the high byte the mask for the bits in the command register + represented by the popup, and in the low byte the shift to move the bits of the popup to the + correct position in the command register. The tags of the items of the popup menus are the item + index, i. e. the bits to set when the item is selected. */ + + +- (IBAction) commandPopupClicked:(id)sender +{ + unsigned short tag = [sender tag]; + unsigned short mask = (tag >> 8) << (tag & 0xff); + [rk8e setCommand:([rk8e getCommand] & ~mask) | ([[sender selectedItem] tag] << (tag & 0xff))]; +} + + +- (void) notifyCommandChanged:(NSNotification *)notification +{ + // NSLog (@"RK8EController notifyCommandChanged"); + unsigned short tag; + unsigned short command = [rk8e getCommand]; +#define SET_COMMAND_POPUP(popup) \ + tag = [(popup) tag]; [(popup) selectItemAtIndex:(command >> (tag & 0xff)) & (tag >> 8)] + SET_COMMAND_POPUP (cmdFunction); + SET_COMMAND_POPUP (cmdInterrupt); + SET_COMMAND_POPUP (cmdSetDone); + SET_COMMAND_POPUP (cmdBlockLength); + SET_COMMAND_POPUP (cmdExtendedAddress); + SET_COMMAND_POPUP (cmdDriveSelect); + SET_COMMAND_POPUP (cmdBlockNumberMSB); +#undef SET_COMMAND_POPUP +} + + +/* The tags of the status checkboxes are the corresponding bit masks of the flags in the status register. */ + + +- (IBAction) statusCheckboxClicked:(id)sender +{ + if ([sender intValue]) + [rk8e setStatusBits:[sender tag] clearStatusBits:0]; + else + [rk8e setStatusBits:0 clearStatusBits:[sender tag]]; +} + + +- (void) notifyStatusChanged:(NSNotification *)notification +{ + // NSLog (@"RK8EController notifyStatusChanged"); + unsigned short status = [rk8e getStatus]; +#define SET_STATUS_CHECKBOX(ckbox) [(ckbox) setIntValue:(status & [(ckbox) tag]) ? 1 : 0] + SET_STATUS_CHECKBOX (statusTransferDone); + SET_STATUS_CHECKBOX (statusHeadInMotion); + SET_STATUS_CHECKBOX (statusUnused); + SET_STATUS_CHECKBOX (statusSeekFailed); + SET_STATUS_CHECKBOX (statusFileNotReady); + SET_STATUS_CHECKBOX (statusControlBusy); + SET_STATUS_CHECKBOX (statusTimingError); + SET_STATUS_CHECKBOX (statusWriteLockError); + SET_STATUS_CHECKBOX (statusCRCError); + SET_STATUS_CHECKBOX (statusDataRequestLate); + SET_STATUS_CHECKBOX (statusDriveStatusError); + SET_STATUS_CHECKBOX (statusCylinderAddressError); +#undef SET_STATUS_CHECKBOX +} + + +- (void) setRK8EControllerEnabled:(BOOL)flag +{ + NSControl *control; + NSEnumerator *enumerator = [[[rk8eBox contentView] subviews] objectEnumerator]; + while ((control = [enumerator nextObject])) + [control setEnabled:flag]; +} + + +- (void) notifyGo:(NSNotification *)notification +{ + [self setRK8EControllerEnabled:NO]; +} + + +- (void) notifyStep:(NSNotification *)notification +{ + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + [defaultCenter postNotificationName:COMMAND_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:STATUS_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:MEMORYADDRESS_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:BLOCKNUMBER_CHANGED_NOTIFICATION object:self]; +} + + +- (void) notifyStop:(NSNotification *)notification +{ + [self notifyStep:notification]; + [self setRK8EControllerEnabled:YES]; +} + + +- (void) setupNotifications +{ + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyCommandChanged:) name:COMMAND_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyStatusChanged:) name:STATUS_CHANGED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyGo:) name:PDP8_GO_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyStop:) name:PDP8_STOP_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyStep:) name:PDP8_STEP_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(notifyPluginsLoaded:) + name:PLUGINS_LOADED_NOTIFICATION object:nil]; +} + + +- (void) setupRegisters +{ + [commandRegister setupRegisterFor:rk8e + getRegisterValue:@selector(getCommand) setRegisterValue:@selector(setCommand:) + changedNotificationName:COMMAND_CHANGED_NOTIFICATION mask:07777 base:8]; + [statusRegister setupRegisterFor:rk8e + getRegisterValue:@selector(getStatus) setRegisterValue:@selector(setStatus:) + changedNotificationName:STATUS_CHANGED_NOTIFICATION mask:07777 base:8]; + [blockNumberRegister setupRegisterFor:rk8e + getRegisterValue:@selector(getBlockNumber) setRegisterValue:@selector(setBlockNumber:) + changedNotificationName:BLOCKNUMBER_CHANGED_NOTIFICATION mask:017777 base:8]; + [memoryAddressRegister setupRegisterFor:rk8e + getRegisterValue:@selector(getMemoryAddress) setRegisterValue:@selector(setMemoryAddress:) + changedNotificationName:MEMORYADDRESS_CHANGED_NOTIFICATION mask:077777 base:8]; +} + + +- (void) notifyPluginsLoaded:(NSNotification *)notification +{ + [window orderBackFromDefaults:self]; + [window makeFirstResponder:window]; +} + + +- (void) awakeFromNib +{ + [self setupRegisters]; + [self setupNotifications]; +} + + +@end diff --git a/RK8E/RK8Eiot.c b/RK8E/RK8Eiot.c new file mode 100644 index 0000000..3ceb4ad --- /dev/null +++ b/RK8E/RK8Eiot.c @@ -0,0 +1,383 @@ +/* + * PDP-8/E Simulator Source Code + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK8Eiot.h - IOTs for the RK8-E plugin + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#define USE_RK8E_REGISTERS_DIRECTLY 1 +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#include "PluginFramework/PluginAPI.h" +#include "PluginFramework/PDP8.h" + +#include "RK8Eiot.h" +#include "RK8E.h" +#include "RK05.h" + + +void i6741 (void) /* DSKP 6741 */ +{ + RK8E *rk8e = PLUGIN_POINTER(RK8E); + [rk8e lockControl]; + if (pdp8->IOFLAGS & rk8e->ioflag) + pdp8->PC++; + + [rk8e unlockControl]; + EXECUTION_TIME (26); +} + + +unsigned s6741 (void) /* DSKP 6741 skiptest */ +{ + return pdp8->IOFLAGS & PLUGIN_POINTER(RK8E)->ioflag; +} + + +void i6742 (void) /* DCLR 6742 */ +{ + RK05 *pack; + + RK8E *rk8e = PLUGIN_POINTER(RK8E); + [rk8e lockControl]; + rk8e->status = 0; + switch (pdp8->AC & 3) { + case 03 : + /* Unlock the drive - else MAINDEC-08-DHRKA-B-PB (diskless control test) + fails on second pass at test 15 because the drives are write protected. + (What happens with a real RK8-E in this case?) + if (! rk8e.pack[(pdp8.AC & 06) >> 1].pb.ioRefNum) + rk8e.pack[(pdp8.AC & 06) >> 1].locked = false; + */ + /* undefined 03 does the same as 00 - fall through */ + case 00 : + pdp8->AC &= 010000 ; + pdp8->IOFLAGS &= ~rk8e->ioflag; + pack = rk8e->rk05[(rk8e->command >> 1) & 3]; + if (! [pack isMounted]) + rk8e->status |= STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY; + if ([pack isCalibrating]) { + rk8e->status |= STATUS_CONTROL_BUSY | STATUS_ERROR; + pdp8->IOFLAGS |= rk8e->ioflag; + } + break; + case 01 : + pdp8->AC &= 010000; + pdp8->IMASK &= ~rk8e->ioflag; + pdp8->IOFLAGS &= ~rk8e->ioflag; + rk8e->command = 0; + rk8e->block &= ~010000; /* CRC is not affected */ + rk8e->curaddr = 0; + [rk8e->rk05[0] abortAllCommands]; + [rk8e->rk05[1] abortAllCommands]; + [rk8e->rk05[2] abortAllCommands]; + [rk8e->rk05[3] abortAllCommands]; + rk8e->maint = false; + rk8e->ldbfill = 0; + rk8e->ldb[0] = 0; + rk8e->ldb[1] = 0; + rk8e->ldb[2] = 0; + rk8e->ldb[3] = 0; + rk8e->udb = 0; + rk8e->wordcount = 0; + rk8e->shifts = 0; + if (! [rk8e->rk05[0] isMounted]) + rk8e->status |= STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY; + break; + case 02 : /* recalibrate to track 0 */ + pdp8->AC &= 010000; + pack = rk8e->rk05[(rk8e->command >> 1) & 3]; + BOOL wasCalibrating = [pack isCalibrating]; + [pack setRecalibrating]; + if ([pack isMounted]) { + [pack setFlushCylinder]; + [pack setReadCylinder:0]; + rk8e->status |= STATUS_DONE; + pdp8->IOFLAGS |= rk8e->ioflag; + if ([pack isBusy]) { + [pack setRaiseFlag]; + [pack start]; + } + } else { + rk8e->status |= STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY | STATUS_ERROR; + if (wasCalibrating) + rk8e->status |= STATUS_CONTROL_BUSY; + if (! rk8e->maint) + pdp8->IOFLAGS |= rk8e->ioflag; + [pack start]; + } + break ; + } + [rk8e unlockControl]; + EXECUTION_TIME (26); +} + + +void i6743 (void) /* DLAG 6743 */ +{ + RK8E *rk8e = PLUGIN_POINTER(RK8E); + [rk8e lockControl]; + rk8e->wordcount = (rk8e->command & COMMAND_HALF_BLOCK) ? 128 : 0; + RK05 *pack = rk8e->rk05[(rk8e->command >> 1) & 3]; + if ((! [pack isWriteProtected] || rk8e->maint) && ! [pack isCalibrating]) { + rk8e->block = ((rk8e->command & 1) << 12) | (pdp8->AC & 07777); + rk8e->crc = rk8e->checkcrc = rk8e->block & 017740; + /* cylinder in 16 bit format 000xxxxxxxx00000*/ + } + pdp8->AC &= 010000; + [pack setStatusAndAbortAllCommands]; + switch (rk8e->command & 07000) { + case 00000 : /* Read Data */ + [pack setRead:YES write:NO all:NO newBlock:rk8e->block]; + break; + case 01000 : /* Read All */ + [pack setRead:YES write:NO all:YES newBlock:rk8e->block]; + break ; + case 02000 : /* Set Write Protect */ + [pack setWriteProtected:YES]; + break ; + case 03000 : /* Seek Only */ + [pack setRead:NO write:NO all:NO newBlock:rk8e->block]; + break ; + case 04000 : /* Write Data */ + [pack setRead:NO write:YES all:NO newBlock:rk8e->block]; + break; + case 05000 : /* Write All */ + [pack setRead:NO write:YES all:YES newBlock:rk8e->block]; + break; + case 06000 : /* unused */ + case 07000 : /* unused */ + pdp8->IOFLAGS |= rk8e->ioflag; + rk8e->status |= STATUS_DONE | STATUS_TIMING_ERROR; + break; + } + if ([pack isMounted]) + [pack start]; + else { + [pack abortAllCommands]; + rk8e->status |= STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY | STATUS_ERROR; + pdp8->IOFLAGS |= rk8e->ioflag; + } + [rk8e unlockControl]; + EXECUTION_TIME (36); +} + + +void i6744 (void) /* DLCA 6744 */ +{ + RK8E *rk8e = PLUGIN_POINTER(RK8E); + [rk8e lockControl]; + rk8e->curaddr = pdp8->AC & 07777; + pdp8->AC &= 010000; + if ([rk8e->rk05[(rk8e->command >> 1) & 3] isCalibrating]) { + rk8e->status |= STATUS_CONTROL_BUSY; + pdp8->IOFLAGS |= rk8e->ioflag; + } + [rk8e unlockControl]; + EXECUTION_TIME (26); +} + + +void i6745 (void) /* DRST 6745 */ +{ + RK8E *rk8e = PLUGIN_POINTER(RK8E); + [rk8e lockControl]; + pdp8->AC = (pdp8->AC & 010000) | rk8e->status; + [rk8e unlockControl]; + EXECUTION_TIME (36); +} + + +void i6746 (void) /* DLDC 6746 */ +{ + RK8E *rk8e = PLUGIN_POINTER(RK8E); + [rk8e lockControl]; + rk8e->status = 0; + pdp8->IOFLAGS &= ~rk8e->ioflag; + RK05 *pack = rk8e->rk05[(rk8e->command >> 1) & 3]; + if (! rk8e->maint || ! [pack isCalibrating]) { + rk8e->command = pdp8->AC & 07777; + if (rk8e->command & 1) + rk8e->block |= 010000; /* CRC is not affected */ + pack = rk8e->rk05[(rk8e->command >> 1) & 3]; + } + pdp8->AC &= 010000; + if ([pack isMounted]) { + if ([pack isBusy]) + rk8e->status |= STATUS_HEAD_IN_MOTION; /* still seeking */ + // detected by Clang: rk8e->status is already 0 + // else + // rk8e->status &= ~STATUS_HEAD_IN_MOTION; /* seek already done */ + if ((rk8e->command & COMMAND_SET_DONE_ON_SEEK_DONE)) { + if (! [pack isBusy]) { + rk8e->status |= STATUS_DONE; + pdp8->IOFLAGS |= rk8e->ioflag; + } + } else + [pack clearRaiseFlag]; + } else { + rk8e->status = STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY; + if ([pack isCalibrating]) { + rk8e->status |= STATUS_CONTROL_BUSY | STATUS_ERROR; + pdp8->IOFLAGS |= rk8e->ioflag; + } + } + if (rk8e->command & COMMAND_INTERRUPT_ON_DONE) + pdp8->IMASK |= rk8e->ioflag; + else + pdp8->IMASK &= ~rk8e->ioflag; + [rk8e unlockControl]; + EXECUTION_TIME (36); +} + + +void i6747 (void) /* DMAN 6747 */ +{ + RK8E *rk8e = PLUGIN_POINTER(RK8E); + [rk8e lockControl]; + RK05 *pack = rk8e->rk05[(rk8e->command >> 1) & 3]; + if (pdp8->AC & 04000) { + /* enter maintenance mode */ + rk8e->maint = true; + rk8e->shifts = 0; + rk8e->shiftEnabled = false; + if (! (rk8e->status & ~(STATUS_HEAD_IN_MOTION | STATUS_FILE_NOT_READY | STATUS_ERROR))) + pdp8->IOFLAGS &= ~rk8e->ioflag; + } + if (rk8e->maint) { + switch (pdp8->AC & 07760) { + case 02000 : + /* enable to shift to lower data buffer */ + rk8e->shiftEnabled = true; + break; + case 01200 : + /* combination of 01000 and 00200 where the bit shifted into lower data + buffer is the logical OR of the bits from CRC and surface & sector */ + rk8e->ldb[0] = ((rk8e->block << 11) | (rk8e->ldb[0] >> 1)) & 07777; + rk8e->crc = ((pdp8->AC & 2) << 14) | (rk8e->crc >> 1); + rk8e->block = (rk8e->crc & 017740) | ((rk8e->block >> 1) & 037); + if (++rk8e->shifts == 12 && rk8e->ldbfill == 0) { + rk8e->ldbfill = 1; + rk8e->shifts = 0; + } + break; + case 01000 : + /* shift CRC to lower data buffer and AC10 to CRC */ + rk8e->ldb[0] = ((rk8e->crc << 11) | (rk8e->ldb[0] >> 1)) & 07777; + rk8e->crc = ((pdp8->AC & 2) << 14) | (rk8e->crc >> 1); + rk8e->block = (rk8e->crc & 017740) | (rk8e->block & 037); + if (++rk8e->shifts == 12 && rk8e->ldbfill == 0) { + rk8e->ldbfill = 1; + rk8e->shifts = 0; + } + if (! rk8e->shiftEnabled && ! rk8e->ldbfill) { + rk8e->status |= STATUS_DATA_REQUEST_LATE; + pdp8->IOFLAGS |= rk8e->ioflag; + } + if ([pack isCalibrating]) { + rk8e->status |= STATUS_DONE; + pdp8->IOFLAGS |= rk8e->ioflag; + } + break; + case 00400 : + /* shift command register to lower data buffer */ + rk8e->ldb[0] = ((rk8e->ldb[0] << 1) | (rk8e->command >> 11)) & 0177777; + rk8e->command = (rk8e->command << 1) & 07777; + rk8e->block &= ~010000; + rk8e->crc &= ~010000; + if (rk8e->command & COMMAND_INTERRUPT_ON_DONE) + pdp8->IMASK |= rk8e->ioflag; + else + pdp8->IMASK &= ~rk8e->ioflag; + if (++rk8e->shifts == 12 && rk8e->ldbfill == 0) + rk8e->ldbfill = 1; + break; + case 00200 : + /* shift surface and sector to lower data buffer */ + rk8e->ldb[0] = ((rk8e->block << 11) | (rk8e->ldb[0] >> 1)) & 07777; + rk8e->block = (rk8e->block & 07740) | ((rk8e->block & 037) >> 1); + if (++rk8e->shifts == 12 && rk8e->ldbfill == 0) { + rk8e->ldbfill = 1; + rk8e->shifts = 0; + } + break; + case 00100 : + /* shift AC10 to upper data buffer, buffer should sink in the silo when full */ + if (rk8e->ldbfill < 4 && rk8e->wordcount < 256) { + rk8e->udb = ((pdp8->AC & 2) << 10) | (rk8e->udb >> 1); + if (++rk8e->shifts == 12) { + if ((rk8e->command & COMMAND_HALF_BLOCK) && rk8e->wordcount >= 128) + rk8e->udb = 0; + rk8e->ldb[3] = rk8e->ldb[2]; + rk8e->ldb[2] = rk8e->ldb[1]; + rk8e->ldb[1] = rk8e->ldb[0]; + rk8e->ldb[0] = rk8e->udb; + rk8e->ldbfill++; + rk8e->wordcount++; + rk8e->shifts = 0; + } + if (((rk8e->command & COMMAND_HALF_BLOCK) && rk8e->wordcount == 128 && + rk8e->shifts == 0) + || (rk8e->wordcount == 255 && rk8e->shifts == 11)) { + rk8e->status |= STATUS_DONE; + pdp8->IOFLAGS |= rk8e->ioflag; + } + } else { + rk8e->status |= STATUS_DATA_REQUEST_LATE; + pdp8->IOFLAGS |= rk8e->ioflag; + } + break; + case 00040 : + /* single cycle data break */ + if ((rk8e->command & 07000) == 04000 || (rk8e->command & 07000) == 05000) { + /* write */ + if (rk8e->wordcount < 256 && rk8e->ldbfill < 4) { + rk8e->ldb[3] = rk8e->ldb[2]; + rk8e->ldb[2] = rk8e->ldb[1]; + rk8e->ldb[1] = rk8e->ldb[0]; + rk8e->ldb[0] = + pdp8->mem[((rk8e->command & 070) << 9) | rk8e->curaddr]; + rk8e->ldbfill++; + rk8e->wordcount++; + } + } else { /* read */ + if (((rk8e->command & 070) << 9) < pdp8->_hw.memsize) { + pdp8->mem[((rk8e->command & 070) << 9) | rk8e->curaddr] = + (rk8e->ldbfill > 0) ? rk8e->ldb[--rk8e->ldbfill] : 0; + } + } + rk8e->curaddr = (rk8e->curaddr + 1) & 07777; + break; + case 04020 : + case 00020 : + /* read lower data buffer into AC */ + if (rk8e->ldbfill > 0) + pdp8->AC = (pdp8->AC & 010000) | (rk8e->ldb[--rk8e->ldbfill] & 07777); + else + pdp8->AC &= 010000; + break; + } + } + [pack stopCalibrating]; + [rk8e unlockControl]; + EXECUTION_TIME (46); +} diff --git a/RK8E/RK8Eiot.h b/RK8E/RK8Eiot.h new file mode 100644 index 0000000..6a4a522 --- /dev/null +++ b/RK8E/RK8Eiot.h @@ -0,0 +1,32 @@ +/* + * PDP-8/E Simulator Source Code + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RK8Eiots.c - IOTs for the RK8-E plugin + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +extern void i6741 (void); /* DSKP 6741 */ +extern unsigned s6741 (void); /* DSKP (skip test) */ +extern void i6742 (void); /* DCLR 6742 */ +extern void i6743 (void); /* DLAG 6743 */ +extern void i6744 (void); /* DLCA 6744 */ +extern void i6745 (void); /* DRST 6745 */ +extern void i6746 (void); /* DLDC 6746 */ +extern void i6747 (void); /* DMAN 6747 */ diff --git a/ReadMe.rtf b/ReadMe.rtf new file mode 100644 index 0000000..0c293d5 --- /dev/null +++ b/ReadMe.rtf @@ -0,0 +1,9 @@ +{\rtf1\ansi\ansicpg1252\cocoartf1343\cocoasubrtf160 +{\fonttbl\f0\fswiss\fcharset0 Helvetica;} +{\colortbl;\red255\green255\blue255;} +\paperw11900\paperh16840\margl1440\margr1440\vieww12600\viewh7800\viewkind0 +\pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\pardirnatural + +\f0\fs24 \cf0 This folder contains the source code for PDP-8/E Simulator 2.0.\ +\ +Xcode 3.2.6 and the Mac OS X 10.4 SDK is required to compile and build the application.} \ No newline at end of file diff --git a/Resources/English.lproj/Credits.html b/Resources/English.lproj/Credits.html new file mode 100644 index 0000000..373efe5 --- /dev/null +++ b/Resources/English.lproj/Credits.html @@ -0,0 +1,73 @@ + + + + +About PDP-8/E Simulator + + + + +
+ +


+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 3 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, see http://www.gnu.org/licenses/. +

+ +

+The source code for this program is available at the
+PDP-8/E Simulator homepage. +

+ +

+You can contact the author via +bernhard.baehr@gmx.de. +

+ +

+
+ +
+
+Made in Germany +

+ +
+
+ + diff --git a/Resources/English.lproj/InfoPlist.strings b/Resources/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..4f2443a Binary files /dev/null and b/Resources/English.lproj/InfoPlist.strings differ diff --git a/Resources/English.lproj/MainMenu.nib/designable.nib b/Resources/English.lproj/MainMenu.nib/designable.nib new file mode 100644 index 0000000..e373f6f --- /dev/null +++ b/Resources/English.lproj/MainMenu.nib/designable.nib @@ -0,0 +1,8665 @@ + + + + 1040 + 10K549 + 851 + 1038.36 + 461.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + + + NSApplication + + + + FirstResponder + + + NSApplication + + + MainMenu + + + + PDP-8/E Simulator + + 1048576 + 2147483647 + + NSImage + NSMenuCheckmark + + + NSImage + NSMenuMixedState + + submenuAction: + + + PDP-8/E Simulator + + + + About PDP-8/E Simulator + + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Preferences… + , + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Services + + 1048576 + 2147483647 + + + submenuAction: + + + + Services + + + _NSServicesMenu + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Hide PDP-8/E Simulator + h + 1048576 + 2147483647 + + + + + + Hide Others + h + 1572864 + 2147483647 + + + + + + Show All + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Quit PDP-8/E Simulator + q + 1048576 + 2147483647 + + + + + _NSAppleMenu + + + + + File + + 1048576 + 2147483647 + + + submenuAction: + + + + File + + + + + Load Paper Tape... + l + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Close + w + 1048576 + 2147483647 + + + + + + + + + Edit + + 1048576 + 2147483647 + + + submenuAction: + + + + Edit + + + + + Undo + z + 1048576 + 2147483647 + + + + + + Redo + Z + 1179648 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Cut + x + 1048576 + 2147483647 + + + + + + Copy + c + 1048576 + 2147483647 + + + + + + Paste + v + 1048576 + 2147483647 + + + + + + Delete + + 1048576 + 2147483647 + + + + + + Select All + a + 1048576 + 2147483647 + + + + + + + + + Simulator + + 1048576 + 2147483647 + + + submenuAction: + + + Simulator + + + + Step + e + 1048576 + 2147483647 + + + + + + Trace + t + 1048576 + 2147483647 + + + + + + Go + g + 1048576 + 2147483647 + + + + + + Stop + . + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Breakpoints & Break Opcodes + + 2147483647 + + + + + + YES + YES + + + 2147483647 + + + + + + Bootstrap Loader + + 2147483647 + + + + + + Load Bootstrap Loader + b + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Memory Inspector + i + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Clear All Flags + + 1048576 + 2147483647 + + + + + + Load Extended Address + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Reset + n + 1048576 + 2147483647 + + + + + + + + + Window + + 1048576 + 2147483647 + + + submenuAction: + + + + Window + + + + + Minimize + m + 1048576 + 2147483647 + + + + + + YES + Minimize All + m + 1572864 + 2147483647 + + + + + + Zoom + + 1048576 + 2147483647 + + + + + + YES + Zoom All + + 1572864 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Bring All to Front + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Hide Toolbar + t + 1572864 + 2147483647 + + + + + + Customize Toolbar... + + 1048576 + 2147483647 + + + + + _NSWindowsMenu + + + + + Help + + 1048576 + 2147483647 + + + submenuAction: + + + + Help + + + + + PDP-8/E Simulator Help + ? + 1048576 + 2147483647 + + + + + + + + _NSMainMenu + + + MainController + + + BreakpointController + + + 155 + 2 + {{594, 568}, {332, 173}} + -265289728 + Breakpoints & Break Opcodes + NSPanel + + View + + {333, 800} + {332, 173} + + + 256 + + + + 272 + + + + 2304 + + + + 4352 + {138, 85} + + YES + + + 256 + {138, 17} + + + + + + 256 + {{139, 0}, {12, 17}} + + + + + 2 + 20 + 20 + 20 + + 75497536 + 134219776 + S + + LucidaGrande + 11 + 3100 + + + 3 + MC4zMzMzMzI5OQA + + + 6 + System + headerTextColor + + 3 + MAA + + + + + 67108864 + 134479872 + + + LucidaGrande + 12 + 16 + + + 1215582464 + 2 + + NSSwitch + + + + 400 + 75 + + YES + + + + 1 + 20 + 20 + 20 + + 75497536 + 134219776 + U + + + + + + 67108864 + 134479872 + + + + 1215582464 + 2 + + + + 400 + 75 + + YES + + + + 0 + 89 + 87.4599609375 + 89 + + 75497536 + 134219776 + Break Opcodes + + + 6 + System + headerColor + + 3 + MQA + + + + + + 337641536 + 134219776 + Text Cell + + LucidaGrande + 13 + 1044 + + + + 6 + System + controlBackgroundColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + + + + + + 3 + 2 + + + 6 + System + gridColor + + 3 + MC41AA + + + 15 + 448790528 + + + 0 + 15 + 0 + YES + 0 + + + {{1, 17}, {138, 85}} + + + + + 4 + + + + 256 + {{139, 17}, {11, 85}} + + 256 + + _doScroller: + 0.5 + + + + -2147483392 + {{-100, -100}, {160, 15}} + + 257 + + _doScroller: + 0.90780138969421387 + + + + 2304 + + + + {{1, 0}, {138, 17}} + + + + + 4 + + + + {{171, 60}, {151, 103}} + + + 18 + + + + + QSAAAEEgAABBiAAAQYgAAA + + + + 272 + + + + 2304 + + + + 4352 + {138, 85} + + YES + + + 256 + {138, 17} + + + + + + 256 + {{139, 0}, {12, 17}} + + + + + 1 + 43 + 43 + 43 + + 75497536 + 134219776 + + + + 3 + MC4zMzMzMzI5OQA + + + + + 67108864 + 134479872 + + + + 1213485312 + 2 + + + + 400 + 75 + + YES + + + + 0 + 88.86865234375 + 74.86865234375 + 89 + + 75497536 + 134219776 + Breakpoints + + + + + + 337641536 + 134219776 + Text Cell + + + + + + + + + 3 + 2 + + + 15 + 448790528 + + + 0 + 15 + 0 + YES + 0 + + + {{1, 17}, {138, 85}} + + + + + 4 + + + + 256 + {{139, 17}, {11, 85}} + + 256 + + _doScroller: + 0.5 + + + + -2147483392 + {{-100, -100}, {146, 15}} + + 257 + + _doScroller: + 0.99047619104385376 + + + + 2304 + + + + {{1, 0}, {138, 17}} + + + + + 4 + + + + {{10, 60}, {151, 103}} + + + 18 + + + + + QSAAAEEgAABBiAAAQYgAAA + + + + 288 + {{10, 34}, {76, 17}} + + YES + + 67108864 + 134217728 + + + + + -2036580352 + 34 + + + + + 200 + 25 + + + + + 288 + {{85, 34}, {76, 17}} + + YES + + 603979776 + 134217728 + - + + + -2036449280 + 34 + + + + 200 + 25 + + + + + 288 + {{171, 34}, {76, 17}} + + YES + + 67108864 + 134217728 + + + + + -2036580352 + 34 + + + + + 200 + 25 + + + + + 288 + {{246, 34}, {76, 17}} + + YES + + 603979776 + 134217728 + - + + + -2036580352 + 34 + + + + + 200 + 25 + + + + + 288 + {{85, 9}, {76, 17}} + + YES + + 603979776 + 134348800 + Disable All + + + -2036580352 + 34 + + + + + 200 + 25 + + + + + 256 + {{246, 9}, {76, 17}} + + YES + + 603979776 + 134348800 + Disable All + + + -2036580352 + 34 + + + + + 200 + 25 + + + + + 288 + {{10, 9}, {76, 17}} + + YES + + 603979776 + 134348800 + Enable All + + + -2036580352 + 34 + + + + + 200 + 25 + + + + + 288 + {{171, 9}, {76, 17}} + + YES + + 603979776 + 134348800 + Enable All + + + -2036580352 + 34 + + + + + 200 + 25 + + + + {332, 173} + + {{0, 0}, {1440, 878}} + {332, 189} + {333, 816} + BreakpointPanel + + + 4111 + 2 + {{38, 286}, {643, 373}} + 1618477056 + PDP-8/E CPU + KeepInMenuWindow + + View + + {1.79769e+308, 1.79769e+308} + {643, 373} + + + 256 + + + + 273 + + + + 2304 + + + + 256 + {351, 357} + + YES + + + 256 + {351, 17} + + + + + + 256 + {{352, 0}, {16, 17}} + + + + + 0 + 23 + 23 + 23 + + 75497536 + 134219776 + PC + + + 3 + MC4zMzMzMzI5OQA + + + + + 0 + 33554432 + + 549453824 + {15, 15} + + + + + + TU0AKgAAAFiAO2BP8AQWDQeEQmFQuGQ0AQJ2wSHROKRWERCJRaNRuExiOR+Px6QSOKyKSSeGSaUSuDyq +WSyXS+UTGZSSaTWQTecRydTuNT2fSWB0GTwEAAAPAQAAAwAAAAEADwAAAQEAAwAAAAEADwAAAQIAAwAA +AAQAAAESAQMAAwAAAAEABQAAAQYAAwAAAAEAAgAAAREABAAAAAEAAAAIARIAAwAAAAEAAQAAARUAAwAA +AAEABAAAARYAAwAAAAEADwAAARcABAAAAAEAAABPARwAAwAAAAEAAQAAAT0AAwAAAAEAAgAAAVIAAwAA +AAEAAQAAAVMAAwAAAAQAAAEah3MABwAAG6wAAAEiAAAAAAAIAAgACAAIAAEAAQABAAEAABusYXBwbAIA +AABtbnRyUkdCIFhZWiAH2wAHABgADgAdAAZhY3NwQVBQTAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +9tYAAQAAAADTLWFwcGwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +ABFyWFlaAAABUAAAABRnWFlaAAABZAAAABRiWFlaAAABeAAAABR3dHB0AAABjAAAABRjaGFkAAABoAAA +ACxyVFJDAAABzAAACAxnVFJDAAAJ2AAACAxiVFJDAAAR5AAACAxhYXJnAAAZ8AAAACBhYWdnAAAaEAAA +ACBhYWJnAAAaMAAAACB2Y2d0AAAaUAAAADBuZGluAAAagAAAADhkZXNjAAAauAAAAGJkc2NtAAAbHAAA +AERtbW9kAAAbYAAAAChjcHJ0AAAbiAAAACRYWVogAAAAAAAAdEsAAD3tAAAD0FhZWiAAAAAAAABacwAA +rHQAABczWFlaIAAAAAAAACgYAAAVngAAuCpYWVogAAAAAAAA81EAAQAAAAEWzHNmMzIAAAAAAAEMQgAA +Bd7///MmAAAHkwAA/ZD///ui///9owAAA9wAAMBuY3VydgAAAAAAAAQAAAAABQAKAA8AFAAZAB4AIwAo +AC0AMgA3ADsAQABFAEoATwBUAFkAXgBjAGgAbQByAHcAfACBAIYAiwCQAJUAmgCfAKQAqQCuALIAtwC8 +AMEAxgDLANAA1QDaAOAA5QDqAPAA9QD7AQEBBwEMARIBGAEeASUBKwExATgBPgFFAUsBUgFZAWABZgFt +AXUBfAGDAYoBkgGZAaEBqAGwAbgBwAHIAdAB2AHgAekB8QH6AgICCwIUAhwCJQIuAjcCQAJKAlMCXAJm +AnACeQKDAo0ClwKhAqsCtQK/AsoC1ALfAuoC9AL/AwoDFQMgAysDNwNCA00DWQNlA3ADfAOIA5QDoAOs +A7kDxQPSA94D6wP4BAQEEQQeBCwEOQRGBFQEYQRvBHwEigSYBKYEtATCBNEE3wTuBPwFCwUaBSgFNwVH +BVYFZQV0BYQFkwWjBbMFwwXTBeMF8wYDBhQGJAY1BkUGVgZnBngGiQaaBqsGvQbOBuAG8gcDBxUHJwc5 +B0wHXgdwB4MHlgeoB7sHzgfhB/QICAgbCC8IQghWCGoIfgiSCKYIugjOCOMI9wkMCSEJNglLCWAJdQmK +CaAJtQnLCeAJ9goMCiIKOQpPCmUKfAqSCqkKwArXCu4LBQsdCzQLSwtjC3sLkwurC8ML2wvzDAwMJAw9 +DFYMbgyHDKEMugzTDO0NBg0gDToNVA1uDYgNog28DdcN8Q4MDicOQg5dDngOkw6vDsoO5g8CDx4POg9W +D3IPjg+rD8gP5BABEB4QOxBYEHYQkxCxEM4Q7BEKESgRRhFkEYMRoRHAEd8R/hIdEjwSWxJ6EpoSuRLZ +EvkTGRM5E1kTehOaE7sT2xP8FB0UPhRfFIEUohTEFOUVBxUpFUsVbRWQFbIV1RX3FhoWPRZgFoMWpxbK +Fu4XEhc1F1kXfReiF8YX6hgPGDQYWRh9GKMYyBjtGRMZOBleGYQZqhnQGfYaHRpDGmoakBq3Gt4bBhst +G1QbfBujG8sb8xwbHEMcbByUHL0c5h0OHTcdYB2KHbMd3R4GHjAeWh6EHq4e2B8DHy0fWB+DH64f2SAE +IDAgWyCHILMg3iEKITchYyGPIbwh6SIVIkIicCKdIsoi+CMlI1MjgSOvI90kDCQ6JGkklyTGJPUlJCVU +JYMlsyXiJhImQiZyJqMm0ycDJzQnZSeWJ8cn+CgqKFsojSi+KPApIilVKYcpuSnsKh8qUiqFKrgq6yse +K1Irhiu6K+4sIixWLIosvyz0LSktXi2TLcgt/S4zLmkuni7ULwsvQS93L64v5DAbMFIwiTDBMPgxMDFn +MZ8x1zIPMkgygDK4MvEzKjNjM5wz1TQPNEg0gjS8NPY1MDVqNaU13zYaNlU2kDbLNwY3Qjd+N7k39Tgx +OG04qjjmOSM5YDmdOdo6FzpUOpI6zzsNO0s7iTvHPAY8RDyDPMI9AT1APX89vz3+Pj4+fj6+Pv4/Pz9/ +P8BAAEBBQIJAxEEFQUdBiEHKQgxCTkKRQtNDFkNYQ5tD3kQhRGVEqETsRTBFdEW4RfxGQEaFRspHDkdT +R5lH3kgjSGlIr0j1STtJgUnHSg5KVUqbSuJLKktxS7hMAExITJBM2E0gTWhNsU36TkJOjE7VTx5PZ0+x +T/tQRVCPUNlRJFFuUblSBFJPUppS5VMxU3xTyFQUVGBUrVT5VUZVklXfVixWelbHVxRXYlewV/5YTFia +WOlZOFmGWdVaJFp0WsNbE1tjW7JcA1xTXKNc9F1EXZVd5l43Xole2l8sX35f0GAiYHRgx2EZYWxhv2IS +YmViuWMMY2BjtGQIZFxksWUFZVplr2YEZllmr2cEZ1pnsGgGaFxosmkJaV9ptmoNamRqvGsTa2trw2wb +bHNsy20jbXxt1W4ubodu4G86b5Nv7XBHcKFw+3FWcbByC3JmcsFzHHN4c9N0L3SLdOd1Q3Wgdfx2WXa2 +dxN3cHfOeCt4iXjneUV5o3oCemB6v3see3173Hw8fJt8+31bfbt+G358ftx/PX+ef/+AYIDCgSOBhYHn +gkmCq4MOg3CD04Q2hJmE/IVghcOGJ4aLhu+HVIe4iB2IgYjmiUyJsYoWinyK4otIi66MFIx7jOKNSI2v +jheOfo7lj02PtZAdkIWQ7pFWkb+SKJKRkvqTZJPNlDeUoZULlXWV4JZKlrWXIJeLl/eYYpjOmTqZppoS +mn6a65tXm8ScMZyfnQydeZ3nnlWew58xn6CgD6B9oOyhW6HLojqiqqMao4qj+qRqpNulTKW8pi6mn6cQ +p4Kn9KhlqNipSqm8qi+qoqsVq4ir+6xvrOOtVq3Lrj+us68or52wEbCHsPyxcbHnsl2y07NJs7+0NrSt +tSS1m7YStom3Abd5t/G4abjhuVq50rpLusS7Pru3vDC8qr0kvZ6+Gb6Tvw6/icAEwH/A+sF2wfHCbcLp +w2bD4sRfxNzFWcXWxlPG0cdOx8zISsjJyUfJxspFysTLQ8vCzELMwc1BzcHOQs7Cz0PPw9BE0MbRR9HI +0krSzNNO09DUU9TW1VjV29Ze1uLXZdfp2G3Y8dl12fraf9sD24jcDtyT3Rndnt4k3qrfMd+34D7gxeFM +4dPiWuLi42rj8uR65QLli+YT5pznJeev6DjowulM6dbqYOrq63Xr/+yK7Rbtoe4s7rjvRO/Q8Fzw6fF1 +8gLyj/Mc86r0N/TF9VP14fZv9v73jPgb+Kr5OfnJ+ln66Pt4/Aj8mf0p/br+S/7c/25jdXJ2AAAAAAAA +BAAAAAAFAAoADwAUABkAHgAjACgALQAyADcAOwBAAEUASgBPAFQAWQBeAGMAaABtAHIAdwB8AIEAhgCL +AJAAlQCaAJ8ApACpAK4AsgC3ALwAwQDGAMsA0ADVANoA4ADlAOoA8AD1APsBAQEHAQwBEgEYAR4BJQEr +ATEBOAE+AUUBSwFSAVkBYAFmAW0BdQF8AYMBigGSAZkBoQGoAbABuAHAAcgB0AHYAeAB6QHxAfoCAgIL +AhQCHAIlAi4CNwJAAkoCUwJcAmYCcAJ5AoMCjQKXAqECqwK1Ar8CygLUAt8C6gL0Av8DCgMVAyADKwM3 +A0IDTQNZA2UDcAN8A4gDlAOgA6wDuQPFA9ID3gPrA/gEBAQRBB4ELAQ5BEYEVARhBG8EfASKBJgEpgS0 +BMIE0QTfBO4E/AULBRoFKAU3BUcFVgVlBXQFhAWTBaMFswXDBdMF4wXzBgMGFAYkBjUGRQZWBmcGeAaJ +BpoGqwa9Bs4G4AbyBwMHFQcnBzkHTAdeB3AHgweWB6gHuwfOB+EH9AgICBsILwhCCFYIagh+CJIIpgi6 +CM4I4wj3CQwJIQk2CUsJYAl1CYoJoAm1CcsJ4An2CgwKIgo5Ck8KZQp8CpIKqQrACtcK7gsFCx0LNAtL +C2MLewuTC6sLwwvbC/MMDAwkDD0MVgxuDIcMoQy6DNMM7Q0GDSANOg1UDW4NiA2iDbwN1w3xDgwOJw5C +Dl0OeA6TDq8Oyg7mDwIPHg86D1YPcg+OD6sPyA/kEAEQHhA7EFgQdhCTELEQzhDsEQoRKBFGEWQRgxGh +EcAR3xH+Eh0SPBJbEnoSmhK5EtkS+RMZEzkTWRN6E5oTuxPbE/wUHRQ+FF8UgRSiFMQU5RUHFSkVSxVt +FZAVshXVFfcWGhY9FmAWgxanFsoW7hcSFzUXWRd9F6IXxhfqGA8YNBhZGH0YoxjIGO0ZExk4GV4ZhBmq +GdAZ9hodGkMaahqQGrca3hsGGy0bVBt8G6MbyxvzHBscQxxsHJQcvRzmHQ4dNx1gHYodsx3dHgYeMB5a +HoQerh7YHwMfLR9YH4Mfrh/ZIAQgMCBbIIcgsyDeIQohNyFjIY8hvCHpIhUiQiJwIp0iyiL4IyUjUyOB +I68j3SQMJDokaSSXJMYk9SUkJVQlgyWzJeImEiZCJnImoybTJwMnNCdlJ5Ynxyf4KCooWyiNKL4o8Cki +KVUphym5KewqHypSKoUquCrrKx4rUiuGK7or7iwiLFYsiiy/LPQtKS1eLZMtyC39LjMuaS6eLtQvCy9B +L3cvri/kMBswUjCJMMEw+DEwMWcxnzHXMg8ySDKAMrgy8TMqM2MznDPVNA80SDSCNLw09jUwNWo1pTXf +Nho2VTaQNss3BjdCN343uTf1ODE4bTiqOOY5IzlgOZ052joXOlQ6kjrPOw07SzuJO8c8BjxEPIM8wj0B +PUA9fz2/Pf4+Pj5+Pr4+/j8/P38/wEAAQEFAgkDEQQVBR0GIQcpCDEJOQpFC00MWQ1hDm0PeRCFEZUSo +ROxFMEV0RbhF/EZARoVGykcOR1NHmUfeSCNIaUivSPVJO0mBScdKDkpVSptK4ksqS3FLuEwATEhMkEzY +TSBNaE2xTfpOQk6MTtVPHk9nT7FP+1BFUI9Q2VEkUW5RuVIEUk9SmlLlUzFTfFPIVBRUYFStVPlVRlWS +Vd9WLFZ6VsdXFFdiV7BX/lhMWJpY6Vk4WYZZ1VokWnRaw1sTW2NbslwDXFNco1z0XURdlV3mXjdeiV7a +Xyxffl/QYCJgdGDHYRlhbGG/YhJiZWK5YwxjYGO0ZAhkXGSxZQVlWmWvZgRmWWavZwRnWmewaAZoXGiy +aQlpX2m2ag1qZGq8axNra2vDbBtsc2zLbSNtfG3Vbi5uh27gbzpvk2/tcEdwoXD7cVZxsHILcmZywXMc +c3hz03QvdIt053VDdaB1/HZZdrZ3E3dwd854K3iJeOd5RXmjegJ6YHq/ex57fXvcfDx8m3z7fVt9u34b +fnx+3H89f55//4BggMKBI4GFgeeCSYKrgw6DcIPThDaEmYT8hWCFw4YnhouG74dUh7iIHYiBiOaJTImx +ihaKfIrii0iLrowUjHuM4o1Ija+OF45+juWPTY+1kB2QhZDukVaRv5IokpGS+pNkk82UN5ShlQuVdZXg +lkqWtZcgl4uX95himM6ZOpmmmhKafprrm1ebxJwxnJ+dDJ15neeeVZ7DnzGfoKAPoH2g7KFbocuiOqKq +oxqjiqP6pGqk26VMpbymLqafpxCngqf0qGWo2KlKqbyqL6qiqxWriKv7rG+s461WrcuuP66zryivnbAR +sIew/LFxseeyXbLTs0mzv7Q2tK21JLWbthK2ibcBt3m38bhpuOG5WrnSuku6xLs+u7e8MLyqvSS9nr4Z +vpO/Dr+JwATAf8D6wXbB8cJtwunDZsPixF/E3MVZxdbGU8bRx07HzMhKyMnJR8nGykXKxMtDy8LMQszB +zUHNwc5CzsLPQ8/D0ETQxtFH0cjSStLM007T0NRT1NbVWNXb1l7W4tdl1+nYbdjx2XXZ+tp/2wPbiNwO +3JPdGd2e3iTeqt8x37fgPuDF4Uzh0+Ja4uLjauPy5HrlAuWL5hPmnOcl56/oOOjC6Uzp1upg6urrdev/ +7IrtFu2h7izuuO9E79DwXPDp8XXyAvKP8xzzqvQ39MX1U/Xh9m/2/veM+Bv4qvk5+cn6Wfro+3j8CPyZ +/Sn9uv5L/tz/bmN1cnYAAAAAAAAEAAAAAAUACgAPABQAGQAeACMAKAAtADIANwA7AEAARQBKAE8AVABZ +AF4AYwBoAG0AcgB3AHwAgQCGAIsAkACVAJoAnwCkAKkArgCyALcAvADBAMYAywDQANUA2gDgAOUA6gDw +APUA+wEBAQcBDAESARgBHgElASsBMQE4AT4BRQFLAVIBWQFgAWYBbQF1AXwBgwGKAZIBmQGhAagBsAG4 +AcAByAHQAdgB4AHpAfEB+gICAgsCFAIcAiUCLgI3AkACSgJTAlwCZgJwAnkCgwKNApcCoQKrArUCvwLK +AtQC3wLqAvQC/wMKAxUDIAMrAzcDQgNNA1kDZQNwA3wDiAOUA6ADrAO5A8UD0gPeA+sD+AQEBBEEHgQs +BDkERgRUBGEEbwR8BIoEmASmBLQEwgTRBN8E7gT8BQsFGgUoBTcFRwVWBWUFdAWEBZMFowWzBcMF0wXj +BfMGAwYUBiQGNQZFBlYGZwZ4BokGmgarBr0GzgbgBvIHAwcVBycHOQdMB14HcAeDB5YHqAe7B84H4Qf0 +CAgIGwgvCEIIVghqCH4IkgimCLoIzgjjCPcJDAkhCTYJSwlgCXUJigmgCbUJywngCfYKDAoiCjkKTwpl +CnwKkgqpCsAK1wruCwULHQs0C0sLYwt7C5MLqwvDC9sL8wwMDCQMPQxWDG4MhwyhDLoM0wztDQYNIA06 +DVQNbg2IDaINvA3XDfEODA4nDkIOXQ54DpMOrw7KDuYPAg8eDzoPVg9yD44Pqw/ID+QQARAeEDsQWBB2 +EJMQsRDOEOwRChEoEUYRZBGDEaERwBHfEf4SHRI8ElsSehKaErkS2RL5ExkTORNZE3oTmhO7E9sT/BQd +FD4UXxSBFKIUxBTlFQcVKRVLFW0VkBWyFdUV9xYaFj0WYBaDFqcWyhbuFxIXNRdZF30XohfGF+oYDxg0 +GFkYfRijGMgY7RkTGTgZXhmEGaoZ0Bn2Gh0aQxpqGpAatxreGwYbLRtUG3wboxvLG/McGxxDHGwclBy9 +HOYdDh03HWAdih2zHd0eBh4wHloehB6uHtgfAx8tH1gfgx+uH9kgBCAwIFsghyCzIN4hCiE3IWMhjyG8 +IekiFSJCInAinSLKIvgjJSNTI4EjryPdJAwkOiRpJJckxiT1JSQlVCWDJbMl4iYSJkImciajJtMnAyc0 +J2UnlifHJ/goKihbKI0ovijwKSIpVSmHKbkp7CofKlIqhSq4KusrHitSK4YruivuLCIsViyKLL8s9C0p +LV4tky3ILf0uMy5pLp4u1C8LL0Evdy+uL+QwGzBSMIkwwTD4MTAxZzGfMdcyDzJIMoAyuDLxMyozYzOc +M9U0DzRINII0vDT2NTA1ajWlNd82GjZVNpA2yzcGN0I3fje5N/U4MThtOKo45jkjOWA5nTnaOhc6VDqS +Os87DTtLO4k7xzwGPEQ8gzzCPQE9QD1/Pb89/j4+Pn4+vj7+Pz8/fz/AQABAQUCCQMRBBUFHQYhBykIM +Qk5CkULTQxZDWEObQ95EIURlRKhE7EUwRXRFuEX8RkBGhUbKRw5HU0eZR95II0hpSK9I9Uk7SYFJx0oO +SlVKm0riSypLcUu4TABMSEyQTNhNIE1oTbFN+k5CToxO1U8eT2dPsU/7UEVQj1DZUSRRblG5UgRST1Ka +UuVTMVN8U8hUFFRgVK1U+VVGVZJV31YsVnpWx1cUV2JXsFf+WExYmljpWThZhlnVWiRadFrDWxNbY1uy +XANcU1yjXPRdRF2VXeZeN16JXtpfLF9+X9BgImB0YMdhGWFsYb9iEmJlYrljDGNgY7RkCGRcZLFlBWVa +Za9mBGZZZq9nBGdaZ7BoBmhcaLJpCWlfabZqDWpkarxrE2tra8NsG2xzbMttI218bdVuLm6HbuBvOm+T +b+1wR3ChcPtxVnGwcgtyZnLBcxxzeHPTdC90i3TndUN1oHX8dll2tncTd3B3zngreIl453lFeaN6Anpg +er97Hnt9e9x8PHybfPt9W327fht+fH7cfz1/nn//gGCAwoEjgYWB54JJgquDDoNwg9OENoSZhPyFYIXD +hieGi4bvh1SHuIgdiIGI5olMibGKFop8iuKLSIuujBSMe4zijUiNr44Xjn6O5Y9Nj7WQHZCFkO6RVpG/ +kiiSkZL6k2STzZQ3lKGVC5V1leCWSpa1lyCXi5f3mGKYzpk6maaaEpp+muubV5vEnDGcn50MnXmd555V +nsOfMZ+goA+gfaDsoVuhy6I6oqqjGqOKo/qkaqTbpUylvKYupp+nEKeCp/SoZajYqUqpvKovqqKrFauI +q/usb6zjrVaty64/rrOvKK+dsBGwh7D8sXGx57JdstOzSbO/tDa0rbUktZu2EraJtwG3ebfxuGm44bla +udK6S7rEuz67t7wwvKq9JL2evhm+k78Ov4nABMB/wPrBdsHxwm3C6cNmw+LEX8TcxVnF1sZTxtHHTsfM +yErIyclHycbKRcrEy0PLwsxCzMHNQc3BzkLOws9Dz8PQRNDG0UfRyNJK0szTTtPQ1FPU1tVY1dvWXtbi +12XX6dht2PHZddn62n/bA9uI3A7ck90Z3Z7eJN6q3zHft+A+4MXhTOHT4lri4uNq4/LkeuUC5YvmE+ac +5yXnr+g46MLpTOnW6mDq6ut16//siu0W7aHuLO6470Tv0PBc8OnxdfIC8o/zHPOq9Df0xfVT9eH2b/b+ +94z4G/iq+Tn5yfpZ+uj7ePwI/Jn9Kf26/kv+3P9ucGFyYQAAAAAAAwAAAAJmZgAA8qcAAA1ZAAAT0AAA +CwNwYXJhAAAAAAADAAAAAmZmAADypwAADVkAABPQAAALA3BhcmEAAAAAAAMAAAACZmYAAPKnAAANWQAA +E9AAAAsDdmNndAAAAAAAAAABAAEAAAAAAAAAAQAAAAEAAAAAAAAAAQAAAAEAAAAAAAAAAQAAbmRpbgAA +AAAAAAAwAAChSAAAVwoAAEuFAACa4QAAJ64AABO2AABQDQAAVDkAAjMzAAIzMwACMzNkZXNjAAAAAAAA +AAhEaXNwbGF5AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAbWx1YwAAAAAAAAACAAAADGVuVVMAAAAOAAAAKGRl +REUAAAAOAAAANgBEAGkAcwBwAGwAYQB5AE0AbwBuAGkAdABvAHJtbW9kAAAAAHVua24AAAcXAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAdGV4dAAAAABDb3B5cmlnaHQgQXBwbGUsIEluYy4sIDIwMTEAA + + NSCalibratedRGBColorSpace + 8 + 24 + 0 + + + + + 3 + MCAwAA + + + 0 + 0 + 0 + YES + + + + + 1 + 23 + 23 + 23 + + 75497536 + 134219776 + BP + + + + + + 0 + 33554432 + + 0 + 0 + 0 + YES + + + + + 2 + 45 + 45 + 45 + + 75497536 + 134219776 + Addr + + + + + + 337641536 + 134219776 + Text Cell + + + + + + + + + 3 + 45 + 45 + 45 + + 75497536 + 134219776 + Octal + + + + + + 337641536 + 134219776 + Text Cell + + + + + + + + + 4 + 200 + 200 + 200 + + 75497536 + 2048 + Opcode + + + + + + 338690048 + 0 + Text Cell + + + + 6 + System + textBackgroundColor + + + + + YES + + + + 3 + 2 + + + 15 + 381681664 + + + 0 + 15 + 0 + NO + 0 + + + {{1, 17}, {351, 357}} + + + + + 4 + + + + 256 + {{352, 17}, {15, 342}} + + + _doScroller: + 0.9699699878692627 + + + + -2147483392 + {{-100, -100}, {296, 11}} + + 1 + + _doScroller: + 0.99047619104385376 + + + + 2304 + + + + {{1, 0}, {351, 17}} + + + + + 4 + + + + {{276, -1}, {368, 375}} + + + 18 + + + + + + QSAAAEEgAABBiAAAQYgAAA + + + + 264 + + + + 274 + + + + 256 + {{13, 38}, {29, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 1 + + + 10 + + 67108864 + 67108864 + L + + + + + + {29, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 10 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + 6 + System + controlColor + + + + + + + + 256 + {{53, 65}, {57, 19}} + + YES + 1 + 1 + + + -1805647807 + 205521920 + 7777 + + + 17 + + 67108864 + 67108864 + SR + + + + + + {57, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 17 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{50, 38}, {60, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 7777 + + + 20 + + 67108864 + 67108864 + AC + + + + + + {60, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 20 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{52, 11}, {58, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 7777 + + + 18 + + 67108864 + 67108864 + PC + + + + + + {58, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 18 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + {{2, 2}, {126, 95}} + + + + {{5, 253}, {130, 112}} + + {0, 0} + + 67108864 + 0 + KK8-E CPU + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 3 + 0 + 2 + NO + + + + 264 + + + + 274 + + + + 256 + {{18, 65}, {44, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 37 + + + 18 + + 67108864 + 67108864 + SC + + + + + + {44, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 18 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{70, 65}, {44, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 1 + + + 8 + 25 + + 67108864 + 67108864 + GTF + + + + + + {44, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 25 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{13, 38}, {63, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 7777 + + + 23 + + 67108864 + 67108864 + MQ + + + + + + {63, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 23 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + + + + 256 + {{60, 0}, {18, 20}} + + 1 + YES + + 67108864 + 134348800 + B + + + 1 + 914767872 + 34 + + LucidaGrande + 11 + 16 + + + + 400 + 75 + + + + + 256 + {{-3, 3}, {34, 14}} + + YES + + 67108864 + 4325376 + TW9kZQo + + + + + + + + + 256 + {{34, 0}, {18, 20}} + + YES + + 67108864 + 134348800 + A + + + 914767872 + 34 + + + + 400 + 75 + + + + {{16, 10}, {78, 19}} + + + NSView + + NSResponder + + + {{2, 2}, {130, 95}} + + + + {{137, 253}, {134, 112}} + + {0, 0} + + 67108864 + 0 + KE8-E EAE + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 3 + 0 + 2 + NO + + + + 264 + + + + 274 + + + + 256 + {{13, 38}, {38, 19}} + + YES + 1 + 1 + + + -1805647807 + 205521920 + 7 + + + 19 + + 67108864 + 67108864 + DF + + + + + + {38, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 19 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{59, 38}, {33, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 7 + + + 14 + + 67108864 + 67108864 + IF + + + + + + {33, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 14 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{100, 38}, {37, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 1 + + + 18.5 + + 67108864 + 67108864 + UF + + + + + + {37, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 18 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{145, 38}, {49, 19}} + + YES + 1 + 1 + + + -1805647807 + 205521920 + 177 + + + 16 + + 67108864 + 67108864 + SF + + + + + + {49, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 16 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{59, 11}, {33, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 7 + + + 14 + + 67108864 + 67108864 + IB + + + + + + {33, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 14 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{100, 11}, {37, 19}} + + YES + 1 + 1 + + + 341835841 + 205521920 + 1 + + + 18 + + 67108864 + 67108864 + UB + + + + + + {37, 19} + {1, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 18 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + {{2, 2}, {262, 68}} + + + + {{5, 164}, {266, 85}} + + {0, 0} + + 67108864 + 0 + KM8-E Memory Extension + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 3 + 0 + 2 + NO + + + + 272 + + + + 274 + + + + 272 + + + + 2304 + + + + 256 + {149, 97} + + YES + + + 256 + {149, 17} + + + + + + 256 + {{150, 0}, {12, 17}} + + + + + 0 + 90 + 90 + 90 + + 75497536 + 2048 + I/O Device + + + 3 + MC4zMzMzMzI5OQA + + + + + 337641536 + 2048 + Text Cell + + + + + + + + + 1 + 25 + 25 + 25 + + 75497536 + 134219776 + IE + + + + + + 67108864 + 134479872 + + + LucidaGrande + 9 + 3614 + + + -935051008 + 2 + + NSImage + NSSwitch + + + + + 200 + 25 + + YES + + + + 2 + 25 + 25 + 25 + + 75497536 + 134219776 + IO + + + + + + 67108864 + 134479872 + + + + -931905280 + 2 + + + + + 200 + 25 + + YES + + + + 3 + 2 + + + 15 + 314572800 + + + 0 + 15 + 0 + YES + 0 + + + {{1, 17}, {149, 97}} + + + + + 6 + + + + 256 + {{150, 17}, {11, 97}} + + 256 + + _doScroller: + 0.58235293626785278 + + + + -2147483392 + {{-100, -100}, {132, 11}} + + 257 + + _doScroller: + 0.99047619104385376 + + + + 2304 + + + + {{1, 0}, {149, 17}} + + + + + 4 + + + + {{84, 11}, {162, 115}} + + + 18 + + + + + + QSAAAEEgAABBiAAAQYgAAA + + + + 264 + {{13, 109}, {55, 18}} + + YES + + 67108864 + 134348800 + Enable + + + 917782528 + 34 + + + 200 + 25 + + + + + 264 + {{13, 85}, {55, 18}} + + YES + + 67108864 + 134348800 + Delay + + + 917782528 + 34 + + + 200 + 25 + + + + + 264 + {{13, 61}, {55, 18}} + + YES + + 67108864 + 134348800 + Inhibit + + + 917782528 + 34 + + + 200 + 25 + + + + {{2, 2}, {262, 137}} + + + + {{5, 4}, {266, 154}} + + {0, 0} + + 67108864 + 0 + Interrupt Control + + + + 3 + MCAwLjgwMDAwMDAxAA + + + + 3 + 0 + 2 + NO + + + + 256 + {{246, 352}, {28, 22}} + + TableCornerView + NSControl + + + {643, 373} + + + {{0, 0}, {1440, 878}} + {643, 395} + {1.79769e+308, 1.79769e+308} + CPUWindow + + + CPUWindowController + + + PDP8 + + + BreakpointArray + + + BreakpointController + + + BreakpointArray + + + CPUMemoryViewController + + + IOFlagController + + + SkipController + + + 147 + 2 + {{30, 613}, {330, 119}} + -260571136 + Bootstrap Loader + + NSPanel + + + View + + {409, 154} + {158.906, 100} + + + 256 + + + + 256 + {{8, 38}, {186, 70}} + + YES + 4 + 1 + + + -2080374784 + 131072 + Low Speed Reader RIM Loader + + + 1211912448 + 0 + + NSRadioButton + + + + + + 200 + 25 + + + 67108864 + 131072 + High Speed Reader RIM Loader + + + 1 + 1211912448 + 0 + + + + 200 + 25 + + + 67108864 + 131072 + BIN Loader + + + 2 + 1211912448 + 0 + + + + 400 + 75 + + + 67108864 + 131072 + RK8-E Boot Sequence + + + 3 + 1211912448 + 0 + + + + 400 + 75 + + + {186, 16} + {4, 2} + 1143472128 + NSActionCell + + 67108864 + 0 + Radio + + 1211912448 + 0 + + 400 + 75 + + + + + + + + + 256 + {{198, 93}, {46, 14}} + + YES + + 67108864 + 272760832 + at 7756 + + + + + + + + + 256 + {{198, 75}, {46, 14}} + + YES + + 67108864 + 272760832 + at 7756 + + + + + + + + + 256 + {{198, 57}, {46, 14}} + + YES + + 67108864 + 272760832 + at 7617 + + + + + + + + + 256 + {{198, 39}, {46, 14}} + + YES + + 67108864 + 272760832 + at 0027 + + + + + + + + + 256 + + Apple PDF pasteboard type + Apple PICT pasteboard type + Apple PNG pasteboard type + NSFilenamesPboardType + NeXT Encapsulated PostScript v1.2 pasteboard type + NeXT TIFF v4.0 pasteboard type + + {{249, 59}, {9, 45}} + + YES + + 0 + 33554432 + + NSImage + bracket + + 0 + 2 + 0 + NO + + YES + + + + 256 + {{7, 8}, {176, 18}} + + YES + + -2080374784 + 131072 + Adjust Program Counter + + + 1211912448 + 2 + + + + 200 + 25 + + + + + 256 + {{245, 3}, {80, 28}} + + YES + + 67108864 + 134348800 + Load + + + -2038284288 + 1 + + + + + + 200 + 25 + + + + + 256 + {{263, 75}, {31, 14}} + + YES + + 67108864 + 272760832 + on IF + + + + + + + + + 256 + {{263, 39}, {42, 14}} + + YES + + 67108864 + 272760832 + on IF 0 + + + + + + + + + 256 + {{307, 70}, {15, 22}} + + YES + + 0 + 131072 + + 7 + 1 + YES + + + + + 256 + {{293, 75}, {11, 14}} + + YES + + 67108864 + 272760832 + 0 + + + + + + + + {330, 119} + + + {{0, 0}, {1440, 878}} + {158.906, 116} + {409, 170} + BootstrapPanel + + + BootstrapPanelController + + + + 256 + + + + 256 + {{-3, 11}, {239, 17}} + + YES + + 68157440 + 272629760 + Load the Paper Tape to Memory Field + + + + + + + + + 256 + {{238, 11}, {14, 17}} + + YES + + 67108864 + 272629760 + 0 + + + + + + + + + 256 + {{253, 5}, {19, 28}} + + YES + + 0 + 0 + + 7 + 1 + YES + + + + {270, 38} + + + NSView + + NSResponder + + + 3 + 2 + {{185, 431}, {500, 250}} + 1886913536 + Preferences + + NSPanel + + + View + + {501, 500} + {500, 5} + + + 256 + {500, 250} + + {{0, 0}, {1440, 878}} + {500, 27} + {501, 522} + + + PreferencesController + + + Menu + + + + Set Breakpoint + + 1048576 + 2147483647 + + + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Set Break Opcode + + 1048576 + 2147483647 + + + 1 + + + + Set System Mode Break Opcode + + 1048576 + 2147483647 + + + 2 + + + + Set User Mode Break Opcode + + 1048576 + 2147483647 + + + 3 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Set Program Counter + + 1048576 + 2147483647 + + + 4 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Go and Stop Here + + 1048576 + 2147483647 + + + 5 + + + + Trace and Stop Here + + 1048576 + 2147483647 + + + 6 + + + + YES + YES + + + 1048576 + 2147483647 + + + + + + Scroll to Program Counter + + 2147483647 + + + 7 + + + + YES + YES + + + 2147483647 + + + + + + Set Default Program Counter Row + + 1048576 + 2147483647 + + + 8 + + + + + + + {200, 341} + {100, 0} + {600, 0} + 2 + 0.0 + 15 + + + + + + 256 + + + + 266 + {{7, 314}, {246, 22}} + + YES + + -2076049856 + 133120 + + + 109199360 + 1 + + + + + + 400 + 75 + + + Dummy + + 1048576 + 2147483647 + 1 + + + _popUpItemAction: + + + YES + + + OtherViews + + + + + + 3 + YES + YES + 1 + + + + + 274 + + + + 2304 + + + + 4352 + {238, 282} + + YES + + + 256 + {238, 17} + + + + + + -2147483392 + {{-22, 0}, {12, 17}} + + + + + 0 + 45 + 45 + 45 + + 75497536 + 134219776 + Addr + + + 3 + MC4zMzMzMzI5OQA + + + + + 337641536 + 134219776 + Text Cell + + + + + + + + + 1 + 45 + 45 + 45 + + 75497536 + 2048 + Octal + + + + + + 337641536 + 2048 + Text Cell + + + + + + YES + + + + 2 + 70 + 46.3779296875 + 70 + + 75497536 + 2048 + Content + + + + + + 337641536 + 2048 + Text Cell + + + + + + YES + + + + 3 + 2 + + + 15 + 312475648 + + + 0 + 15 + 0 + YES + 0 + + + {{1, 17}, {238, 282}} + + + + + 4 + + + + -2147483392 + {{-22, 17}, {11, 246}} + + 256 + + _doScroller: + 0.98947370052337646 + + + + -2147483392 + {{1, -22}, {227, 11}} + + 257 + + _doScroller: + 0.97844827175140381 + + + + 2304 + + + + {{1, 0}, {238, 17}} + + + + + 4 + + + + {{10, 10}, {240, 300}} + + + 562 + + + + + + QSAAAEEgAABBiAAAQYgAAA + + + + 256 + {{222, 270}, {19, 17}} + + TableCornerView + NSControl + + + {260, 341} + + NSView + + NSResponder + + + MemoryInspectorController + + + PluginManager + + + YES + + + + + + + showHelp: + + + + 122 + + + + terminate: + + + + 139 + + + + orderFrontStandardAboutPanel: + + + + 142 + + + + hideOtherApplications: + + + + 146 + + + + hide: + + + + 152 + + + + unhideAllApplications: + + + + 153 + + + + performClose: + + + + 193 + + + + copy: + + + + 224 + + + + paste: + + + + 226 + + + + cut: + + + + 228 + + + + selectAll: + + + + 232 + + + + delete: + + + + 235 + + + + toggleToolbarShown: + + + + 254 + + + + delegate + + + + 279 + + + + nextKeyView + + + + 314 + + + + nextKeyView + + + + 315 + + + + nextKeyView + + + + 316 + + + + nextKeyView + + + + 317 + + + + nextKeyView + + + + 318 + + + + nextKeyView + + + + 319 + + + + nextKeyView + + + + 320 + + + + nextKeyView + + + + 321 + + + + nextKeyView + + + + 322 + + + + nextKeyView + + + + 323 + + + + nextKeyView + + + + 324 + + + + nextKeyView + + + + 325 + + + + window + + + + 348 + + + + enableAllBreakpoints: + + + + 406 + + + + disableAllBreakpoints: + + + + 407 + + + + runToolbarCustomizationPalette: + + + + 424 + + + + delegate + + + + 450 + + + + addBreakpoint: + + + + 509 + + + + dataSource + + + + 512 + + + + deleteBreakpoint: + + + + 601 + + + + breakpoints + + + + 605 + + + + addButton + + + + 606 + + + + enableAllButton + + + + 607 + + + + disableAllButton + + + + 608 + + + + deleteButton + + + + 609 + + + + tableView + + + + 610 + + + + tableView + + + + 614 + + + + addButton + + + + 615 + + + + deleteButton + + + + 616 + + + + enableAllButton + + + + 617 + + + + disableAllButton + + + + 618 + + + + breakpoints + + + + 620 + + + + addBreakpoint: + + + + 621 + + + + deleteBreakpoint: + + + + 622 + + + + enableAllBreakpoints: + + + + 623 + + + + disableAllBreakpoints: + + + + 624 + + + + dataSource + + + + 625 + + + + delegate + + + + 626 + + + + mq + + + + 707 + + + + sc + + + + 709 + + + + l + + + + 712 + + + + pdp8 + + + + 739 + + + + gtf + + + + 740 + + + + pdp8 + + + + 741 + + + + nextKeyView + + + + 785 + + + + nextKeyView + + + + 786 + + + + nextKeyView + + + + 787 + + + + initialFirstResponder + + + + 788 + + + + df + + + + 789 + + + + sf + + + + 794 + + + + sr + + + + 810 + + + + ac + + + + 816 + + + + pc + + + + 817 + + + + _if + + + + 819 + + + + uf + + + + 823 + + + + ib + + + + 826 + + + + ub + + + + 827 + + + + reset: + + + + 831 + + + + cpuWindow + + + + 832 + + + + enable + + + + 887 + + + + delay + + + + 888 + + + + inhibit + + + + 889 + + + + breakopcodes + + + + 891 + + + + breakpoints + + + + 892 + + + + memoryView + + + + 893 + + + + pdp8 + + + + 894 + + + + dataSource + + + + 895 + + + + delegate + + + + 896 + + + + pdp8 + + + + 901 + + + + breakpoints + + + + 903 + + + + pdp8 + + + + 913 + + + + enableCheckboxClicked: + + + + 914 + + + + delayCheckboxClicked: + + + + 915 + + + + inhibitCheckboxClicked: + + + + 916 + + + + delegate + + + + 920 + + + + step: + + + + 926 + + + + trace: + + + + 927 + + + + go: + + + + 928 + + + + stop: + + + + 929 + + + + breakopcodes + + + + 932 + + + + bootstrapPanel + + + + 961 + + + + loaderRadioButtons + + + + 964 + + + + adjustPCCheckbox + + + + 965 + + + + pdp8 + + + + 968 + + + + takeStringValueFrom: + + + + 983 + + + + ifStepper + + + + 984 + + + + breakpointPanel + + + + 990 + + + + loadPaperTape: + + + + 993 + + + + takeIntValueFrom: + + + + 998 + + + + loadPaperTapeFieldView + + + + 999 + + + + loadPaperTapeFieldStepper + + + + 1000 + + + + clearAllFlags: + + + + 1004 + + + + loadExtendedAddress: + + + + 1005 + + + + nextKeyView + + + + 1009 + + + + nextKeyView + + + + 1010 + + + + nextKeyView + + + + 1011 + + + + nextKeyView + + + + 1012 + + + + nextKeyView + + + + 1016 + + + + nextKeyView + + + + 1017 + + + + nextKeyView + + + + 1018 + + + + nextKeyView + + + + 1019 + + + + nextKeyView + + + + 1020 + + + + nextKeyView + + + + 1021 + + + + nextKeyView + + + + 1022 + + + + nextKeyView + + + + 1023 + + + + nextKeyView + + + + 1024 + + + + nextKeyView + + + + 1025 + + + + nextKeyView + + + + 1029 + + + + nextKeyView + + + + 1030 + + + + nextKeyView + + + + 1031 + + + + nextKeyView + + + + 1032 + + + + preferencesPanel + + + + 1066 + + + + showPreferencesPanel: + + + + 1067 + + + + prefPanel + + + + 1075 + + + + menu + + + + 1088 + + + + handleContextMenu: + + + + 1101 + + + + handleContextMenu: + + + + 1102 + + + + handleContextMenu: + + + + 1103 + + + + handleContextMenu: + + + + 1104 + + + + handleContextMenu: + + + + 1105 + + + + handleContextMenu: + + + + 1106 + + + + handleContextMenu: + + + + 1107 + + + + handleContextMenu: + + + + 1110 + + + + delegate + + + + 1115 + + + + contentView + + + + 1123 + + + + parentWindow + + + + 1125 + + + + memoryInspectorDrawer + + + + 1129 + + + + toggleMemoryInspectorDrawer: + + + + 1130 + + + + popupButton + + + + 1142 + + + + memoryView + + + + 1143 + + + + selectMemoryInspector: + + + + 1146 + + + + pdp8 + + + + 1147 + + + + memoryInspectorDrawer + + + + 1148 + + + + cornerView + + + + 1172 + + + + alignMemory: + + + + 1173 + + + + cornerView + + + + 1175 + + + + view + + + + 1176 + + + + cornerView + + + + 1177 + + + + dataSource + + + + 1178 + + + + delegate + + + + 1179 + + + + a + + + + 1195 + + + + b + + + + 1196 + + + + mode + + + + 1197 + + + + eaeModeButtonClick: + + + + 1198 + + + + eaeModeButtonClick: + + + + 1199 + + + + breakpoints + + + + 1211 + + + + breakopcodes + + + + 1212 + + + + nextKeyView + + + + 1213 + + + + nextKeyView + + + + 1214 + + + + nextKeyView + + + + 1215 + + + + nextKeyView + + + + 1216 + + + + nextKeyView + + + + 1217 + + + + arrangeInFront: + + + + 1218 + + + + performMiniaturize: + + + + 1219 + + + + performZoom: + + + + 1220 + + + + pdp8 + + + + 1222 + + + + skipController + + + + 1223 + + + + ioFlagController + + + + 1225 + + + + ioFlagsView + + + + 1417 + + + + dataSource + + + + 1418 + + + + delegate + + + + 1419 + + + + nextKeyView + + + + 1515 + + + + undo: + + + + 1614 + + + + redo: + + + + 1673 + + + + delegate + + + + 1769 + + + + pluginManager + + + + 1837 + + + + value: values.BootstrapLoaderAdjustPC + + + + + + value: values.BootstrapLoaderAdjustPC + value + values.BootstrapLoaderAdjustPC + + + + + + + + + + + + + 2 + + + 2014 + + + + value: values.BootstrapLoaderField + + + + + + value: values.BootstrapLoaderField + value + values.BootstrapLoaderField + + + + + + + + + + + + + 2 + + + 2016 + + + + selectedIndex: values.BootstrapLoader + + + + + + selectedIndex: values.BootstrapLoader + selectedIndex + values.BootstrapLoader + + + + + + + + + + + + + 2 + + + 2018 + + + + miniaturizeAll: + + + + 2124 + + + + performZoomAll: + + + + 2128 + + + + showHideBreakpointPanel: + + + + 2129 + + + + showHideBootstrapPanel: + + + + 2130 + + + + loadBootstrapLoader: + + + + 2232 + + + + loadBootstrapLoader: + + + + 2233 + + + + handleContextMenu: + + + + 2239 + + + + + + 0 + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 29 + + + + + + + + + + + MainMenu + + + 19 + + + + + + + + 24 + + + + + + + + + + + + + + + + 5 + + + + + 23 + + + + + 92 + + + + + 239 + + + + + 251 + + + + + 252 + + + + + 253 + + + + + 2122 + + + + + 2127 + + + + + 56 + + + + + + + + 57 + + + + + + + + + + + + + + + + + + 58 + + + + + 129 + + + + + 131 + + + + + + + + 130 + + + + + 134 + + + + + 136 + + + + + 143 + + + + + 144 + + + + + 145 + + + + + 149 + + + + + 150 + + + + + 236 + + + + + 83 + + + + + + + + 81 + + + + + + + + + + 73 + + + + + 991 + + + + + 992 + + + + + 103 + + + + + + + + 106 + + + + + + + + 111 + + + + + 217 + + + + + + + + 205 + + + + + + + + + + + + + + + 197 + + + + + 198 + + + + + 199 + + + + + 202 + + + + + 203 + + + + + 1611 + + + + + 1612 + + + + + 1672 + + + + + 256 + + + + + + + + 257 + + + + + + + + + + + + + + + + + + + + + + + 258 + + + + + 259 + + + + + 260 + + + + + 262 + + + + + 288 + + + + + 289 + + + + + 829 + + + + + 830 + + + + + 956 + + + + + 1001 + + + + + 1002 + + + + + 1003 + + + + + 1126 + + + + + 1127 + + + + + 278 + + + MainController + + + 291 + + + BreakpointController + + + 292 + + + + + + BreakpointPanel + + + 293 + + + + + + + + + + + + + + + + + 294 + + + + + + + + 295 + + + + + + + + 296 + + + + + + + + 297 + + + + + + + + 298 + + + + + + + + + + + 299 + + + + + + + + + + 300 + + + + + + + + 301 + + + + + 302 + + + + + + + + 303 + + + + + + + + 304 + + + + + 305 + + + + + + + + 306 + + + + + + + + 307 + + + + + + + + 308 + + + + + + + + 309 + + + + + + + + + + + 310 + + + + + + + + + 311 + + + + + + + + 312 + + + + + 313 + + + + + + + + 332 + + + + + + CPUWindow + + + 333 + + + + + + + + + + + + + 334 + + + + + + + + + + + 335 + + + + + + + + + + + + 336 + + + + + + + + 337 + + + + + 338 + + + + + + + + 339 + + + + + 340 + + + + + + + + 341 + + + + + 342 + + + + + + + + 343 + + + + + + + + 639 + + + + + + + + + + + 685 + + + + + + + + + + + 770 + + + + + + + + + + + + + 839 + + + + + + + + + + + 1174 + + + + + 345 + + + CPUWindowController + + + 352 + + + pdp8 + + + 603 + + + Breakpoints + + + 613 + + + BreakOpcodeController + + + 619 + + + BreakOpcodes + + + 890 + + + CPUMemoryViewController + + + 897 + + + IOFlagController + + + 911 + + + SkipController + + + 933 + + + + + + BootstrapPanel + + + 934 + + + + + + + + + + + + + + + + + + + 935 + + + + + + + + + + + + 938 + + + + + 939 + + + + + 940 + + + + + 941 + + + + + 944 + + + + + + + + 945 + + + + + + + + 946 + + + + + + + + 947 + + + + + + + + 949 + + + + + + + + 951 + + + + + + + + 953 + + + + + + + + 954 + + + + + + + + 955 + + + + + + + + 979 + + + + + + + + 980 + + + + + + + + 963 + + + BootstrapPanelController + + + 994 + + + + + + + + LoadPaperTapeFieldView + + + 995 + + + + + + + + 996 + + + + + + + + 997 + + + + + + + + 1033 + + + + + + PreferencesPanel + + + 1034 + + + + + 1070 + + + PreferencesController + + + 1085 + + + + + + + + + + + + + + + + + + + CPUMemContextMenu + + + 1087 + + + + + 1090 + + + + + 1091 + + + + + 1092 + + + + + 1093 + + + + + 1094 + + + + + 1096 + + + + + 1097 + + + + + 1098 + + + + + 1099 + + + + + 1108 + + + + + 1109 + + + + + 1119 + + + MemoryInspectorDrawer + + + 1122 + + + + + + + + MemoryInspectorContentView + + + 1131 + + + + + + + + 1136 + + + + + + + + + + + 1137 + + + + + + + + + + 1138 + + + + + + + + 1139 + + + + + + + + 1140 + + + + + + + + 1171 + + + + + 1141 + + + MemoryInspectorController + + + 1221 + + + PluginManager + + + 2008 + + + Shared User Defaults Controller + + + 2163 + + + + + 2164 + + + + + 2165 + + + + + 2166 + + + + + 2167 + + + + + 2168 + + + + + 2169 + + + + + 2170 + + + + + 2177 + + + + + 2178 + + + + + 2179 + + + + + 2180 + + + + + 2181 + + + + + 2182 + + + + + 2183 + + + + + 2184 + + + + + 2185 + + + + + 2186 + + + + + 2187 + + + + + 2188 + + + + + 2189 + + + + + 2190 + + + + + 2191 + + + + + + + + 2205 + + + + + 2206 + + + + + 2207 + + + + + 2208 + + + + + 2209 + + + + + 2211 + + + + + 2212 + + + + + 2213 + + + + + 1132 + + + + + + + + 1144 + + + + + 2214 + + + + + 2215 + + + + + 2216 + + + + + 2217 + + + + + 2218 + + + + + 2219 + + + + + 2220 + + + + + 2221 + + + + + 2222 + + + + + 2226 + + + + + 2227 + + + + + 2228 + + + + + 660 + + + + + + + + + 2192 + + + + + 663 + + + + + 679 + + + + + + + + + 2193 + + + + + 809 + + + + + 795 + + + + + + + + + 2194 + + + + + 812 + + + + + 802 + + + + + + + + + 2195 + + + + + 814 + + + + + 687 + + + + + + + + + 2196 + + + + + 688 + + + + + 690 + + + + + + + + + 2197 + + + + + 691 + + + + + 693 + + + + + + + + + 2198 + + + + + 694 + + + + + 1185 + + + + + + + + + + 1193 + + + + + + + + 1192 + + + + + + + + 1191 + + + + + + + + 2171 + + + + + 2172 + + + + + 2173 + + + + + 773 + + + + + + + + + 2199 + + + + + 776 + + + + + 777 + + + + + + + + + 2200 + + + + + 818 + + + + + 780 + + + + + + + + + 2201 + + + + + 822 + + + + + 783 + + + + + + + + + 2202 + + + + + 784 + + + + + 820 + + + + + + + + + 2203 + + + + + 821 + + + + + 824 + + + + + + + + + 2204 + + + + + 825 + + + + + 865 + + + + + + + + + + + 2225 + + + + + 2224 + + + + + 2223 + + + + + 866 + + + + + + + + + + 1905 + + + + + + + + 1294 + + + + + + + + 868 + + + + + + + + 2210 + + + + + 1296 + + + + + 1909 + + + + + 881 + + + + + + + + 2174 + + + + + 883 + + + + + + + + 2175 + + + + + 885 + + + + + + + + 2176 + + + + + 2229 + + + + + 2230 + + + + + 2237 + + + + + 2238 + + + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + {501, 500} + {500, 5} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + {{0, 846}, {294, 233}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + MemoryInspectorScrollView + com.apple.InterfaceBuilder.CocoaPlugin + + NonWrappingTableView + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + The EAE can run in two modes. In mode A, the EAE is software-compatible to earlier PDP-8 EAEs; mode B provides an extended set of arithmetic operations. Instructions SWAB (7431) and SWBA (7447) swap the EAE mode. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + EnableDisableTextField + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{251, 515}, {151, 153}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{467, 806}, {235, 163}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{295, 395}, {276, 273}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{131, 969}, {468, 20}} + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + + + {333, 800} + {332, 173} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + To set multiple break opcode at once, use the wildcard #. E. g. 62#1 sets break opcodes for CDF for all eight memory fields. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + To set multiple breakpoints at once, use the wildcard #. E. g. #0200 sets a breakpoint at address 0200 on all eight memory fields. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{18, 156}, {643, 373}} + com.apple.InterfaceBuilder.CocoaPlugin + {{18, 156}, {643, 373}} + + + {643, 373} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + CPUMemoryTableView + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + ToolTip + + ToolTip + + This area displays the basic components of the PDP-8 CPU. From the software point of view, a bare PDP-8 CPU has only these four registers SR, L, AC and PC. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + L (Link) is a 1-bit register used as an extension of the AC register. If a carry results from the addition of the most significant bits of AC and an other word, this carry causes the link value to toggle from 0 to 1 or from 1 to 0. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + This area displays the Extended Arithmetic Element. The EAE option provides the capability to perform arithmetic operations which cannot be directly performed with the basic PDP-8 instruction set, e. g. multiplication and division. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + SC (Step Counter) is used to hold the number of shift operations needed to normalize a binary fraction held in AC and MQ. The EAE instruction NMI (7411) calculates this number. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + GTF (Greater Than Flag) holds sign information calculated while the execution of some EAE mode B instructions. The mode B skip instruction SGT (6006) skips if GTF is set. In EAE mode A, GTF is not available and should be cleared. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + MQ (Multiplier Quotient) is used in conjunction with AC to perform direct multiplication and divison. The PDP-8/E has the MQ register even if it has no EAE; earlier machines (PDP-8, PDP-8/S, PDP-8/I) have it only in conjunction with an EAE. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + This area displays the KM8-E Memory Extension. The KM8-E provides the capability to expand the PDP-8 memory to up to 32K (15-bit addresses) and contains additions for time sharing operation of the PDP-8. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + DF (Data Field) is a 3-bit register which determines the memory field from which operands of indirectly addressed memory reference instructions are taken. (The pointer addresses are obtained from the instruction field.) + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + When an interrupt occurs, the values of UF, IF and DF are loaded into the 7-bit register SF (Save Field) and UF, IF, DF are cleared. RIB (Read Interrupt Buffer, 6234) reads SF into AC; RMF (Restore Memory Fields, 6244) restores UB, IB and DF from SF. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + On a real PDP-8, SR (Switch Register) is a set of twelve toggle switches at the console used to specify values which are loaded into the CPU when other switches are operated. OSR (7404) loads the logical OR of AC and SR into AC. + + + com.apple.InterfaceBuilder.CocoaPlugin + + {{209, 615}, {203, 53}} + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + AC (Accumulator) is the prime component of the arithmetic unit of the basic PDP-8. It is a 12-bit register used to perform all arithmetic operations of the CPU. + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + PC (Program Counter) is used to record the memory address of the next instruction to be executed. When the PDP-8 has more than 4K memory, the IF register is provided as an extension of PC to enable addressing of up to 32K. + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + IF (Instruction Field) determines the memory field the next instruction is to be taken from. Directly addressed instructions optain their operand from IF; indirectly addressed instructions take their pointer address from IF and their operand from DF. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + The IF changing instructions CIF x (62x2) load the number of the new instruction field into IB (Instruction Buffer). The value of IB is then loaded into IF while execution of the next JMP or JMS instruction. + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + For time sharing operation, UF (User Flag) determines whether the CPU is running in system mode (UF=0) or user mode (UF=1). In user mode, the execution of IOT, OSR or HLT instructions causes the CPU issue an interrupt. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + The instructions RTF (6005), RMF (6244), CUF (6264) and SUF (6274) clear or set UB (User Buffer). The value of UB is then loaded into UF while execution of the next JMP or JMS instruction, provided that the time sharing option of the KM8-E is enabled. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + This area displays all elements of the PDP-8 needed for interrupt and I/O processing. When an interrupt occurs, the old value of PC is saved in memory location 0, and execution continues at location 1. UF, IF and DF are saved in SF and become cleared. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + When the Interrupt Enable Flag is set, the delay and inhibit flags are cleared and an I/O devices interrupt enable flag is set, this device can cause an interrupt by raising its I/O flag. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + ION (6001) sets the enable and delay flag. This Interrupt Delay Flag is cleared again while the execution of the next instruction after checking for interrupts. So the effect of ION is delayed for one instruction - for secure return from ISR. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + ToolTip + + ToolTip + + The Interrupt Inhibit Flag is part of the KM8-E Memory Extension. It is set by the IF changing instructions CIF x (62x2) and cleared again by the next JMP or JMS instruction. So interrupts cannot occur while the new field setting is not effective. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + com.apple.InterfaceBuilder.CocoaPlugin + + {{63, 552}, {330, 119}} + com.apple.InterfaceBuilder.CocoaPlugin + {{63, 552}, {330, 119}} + + + + {409, 154} + {158.906, 100} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + {{42, 661}, {270, 38}} + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + + 2239 + + + + + BootstrapPanelController + NSObject + + loadBootstrapLoader: + id + + + loadBootstrapLoader: + + loadBootstrapLoader: + id + + + + NSButton + NSStepper + NSMatrix + PDP8 + + + + adjustPCCheckbox + NSButton + + + ifStepper + NSStepper + + + loaderRadioButtons + NSMatrix + + + pdp8 + PDP8 + + + + IBProjectSource + Panels/BootstrapPanelController.h + + + + BootstrapPanelController + NSObject + + IBUserSource + + + + + BreakpointArray + NSObject + + IBProjectSource + Utilities/BreakpointArray.h + + + + BreakpointArray + NSObject + + IBUserSource + + + + + BreakpointController + NSObject + + id + id + id + id + + + + addBreakpoint: + id + + + deleteBreakpoint: + id + + + disableAllBreakpoints: + id + + + enableAllBreakpoints: + id + + + + NSButton + BreakpointArray + NSButton + NSButton + NSButton + NSTableView + + + + addButton + NSButton + + + breakpoints + BreakpointArray + + + deleteButton + NSButton + + + disableAllButton + NSButton + + + enableAllButton + NSButton + + + tableView + NSTableView + + + + IBProjectSource + Panels/BreakpointController.h + + + + BreakpointController + NSObject + + IBUserSource + + + + + CPUMemoryTableView + NonWrappingTableView + + IBUserSource + + + + + CPUMemoryViewController + NSObject + + handleContextMenu: + id + + + handleContextMenu: + + handleContextMenu: + id + + + + BreakpointArray + BreakpointArray + CPUMemoryTableView + PDP8 + + + + breakopcodes + BreakpointArray + + + breakpoints + BreakpointArray + + + memoryView + CPUMemoryTableView + + + pdp8 + PDP8 + + + + IBProjectSource + CPUWindow/CPUMemoryViewController.h + + + + CPUMemoryViewController + NSObject + + IBUserSource + + + + + CPUWindowController + NSObject + + id + id + id + id + + + + delayCheckboxClicked: + id + + + eaeModeButtonClick: + id + + + enableCheckboxClicked: + id + + + inhibitCheckboxClicked: + id + + + + RegisterFormCell + NSButton + RegisterFormCell + NSButton + NSButton + RegisterFormCell + NSButton + RegisterFormCell + RegisterFormCell + NSButton + RegisterFormCell + EnableDisableTextField + RegisterFormCell + RegisterFormCell + PDP8 + RegisterFormCell + RegisterFormCell + RegisterFormCell + RegisterFormCell + RegisterFormCell + NSWindow + + + + _if + RegisterFormCell + + + a + NSButton + + + ac + RegisterFormCell + + + b + NSButton + + + delay + NSButton + + + df + RegisterFormCell + + + enable + NSButton + + + gtf + RegisterFormCell + + + ib + RegisterFormCell + + + inhibit + NSButton + + + l + RegisterFormCell + + + mode + EnableDisableTextField + + + mq + RegisterFormCell + + + pc + RegisterFormCell + + + pdp8 + PDP8 + + + sc + RegisterFormCell + + + sf + RegisterFormCell + + + sr + RegisterFormCell + + + ub + RegisterFormCell + + + uf + RegisterFormCell + + + window + NSWindow + + + + IBProjectSource + CPUWindow/CPUWindowController.h + + + + CPUWindowController + NSObject + + IBUserSource + + + + + EnableDisableTextField + NSTextField + + IBProjectSource + Utilities/EnableDisableTextField.h + + + + EnableDisableTextField + NSTextField + + IBUserSource + + + + + FirstResponder + NSObject + + : + id + + + : + + : + id + + + + IBUserSource + + + + + IOFlagController + NSObject + + NSTableView + PDP8 + + + + ioFlagsView + NSTableView + + + pdp8 + PDP8 + + + + IBProjectSource + CPUWindow/IOFlagController.h + + + + IOFlagController + NSObject + + IBUserSource + + + + + KeepInMenuWindow + NSWindow + + id + id + + + + orderBackFromDefaults: + id + + + orderFrontFromDefaults: + id + + + + IBProjectSource + Utilities/KeepInMenuWindow.h + + + + KeepInMenuWindow + NSWindow + + IBUserSource + + + + + MainController + NSObject + + id + id + id + id + id + id + id + id + id + id + id + id + id + + + + clearAllFlags: + id + + + go: + id + + + loadExtendedAddress: + id + + + loadPaperTape: + id + + + performZoomAll: + id + + + reset: + id + + + showHideBootstrapPanel: + id + + + showHideBreakpointPanel: + id + + + showPreferencesPanel: + id + + + step: + id + + + stop: + id + + + toggleMemoryInspectorDrawer: + id + + + trace: + id + + + + NSPanel + BreakpointArray + NSPanel + BreakpointArray + KeepInMenuWindow + NSStepper + NSView + NSDrawer + PDP8 + PluginManager + NSPanel + + + + bootstrapPanel + NSPanel + + + breakopcodes + BreakpointArray + + + breakpointPanel + NSPanel + + + breakpoints + BreakpointArray + + + cpuWindow + KeepInMenuWindow + + + loadPaperTapeFieldStepper + NSStepper + + + loadPaperTapeFieldView + NSView + + + memoryInspectorDrawer + NSDrawer + + + pdp8 + PDP8 + + + pluginManager + PluginManager + + + preferencesPanel + NSPanel + + + + IBProjectSource + Main/MainController.h + + + + MainController + NSObject + + IBUserSource + + + + + MemoryInspectorController + NSObject + + id + id + + + + alignMemory: + id + + + selectMemoryInspector: + id + + + + TableCornerView + NSDrawer + NonWrappingTableView + PDP8 + NSPopUpButton + + + + cornerView + TableCornerView + + + memoryInspectorDrawer + NSDrawer + + + memoryView + NonWrappingTableView + + + pdp8 + PDP8 + + + popupButton + NSPopUpButton + + + + IBProjectSource + MemoryInspector/MemoryInspectorController.h + + + + MemoryInspectorController + NSObject + + IBUserSource + + + + + MemoryInspectorScrollView + NSScrollView + + + + MemoryInspectorScrollView + NSScrollView + + IBUserSource + + + + + NSControl + + IBProjectSource + Categories/NSControl+FileDrop.h + + + + NSControl + NSView + + IBUserSource + + + + + NSTableView + + IBProjectSource + Categories/NSTableView+Scrolling.h + + + + NSTableView + NSControl + + IBUserSource + + + + + NonWrappingTableView + NSTableView + + IBProjectSource + Utilities/NonWrappingTableView.h + + + + NonWrappingTableView + NSTableView + + IBUserSource + + + + + PDP8 + NSObject + + BreakpointArray + BreakpointArray + + + + breakopcodes + BreakpointArray + + + breakpoints + BreakpointArray + + + + IBProjectSource + Emulation/PDP8.h + + + + PDP8 + NSObject + + IBUserSource + + + + + PluginManager + NSObject + + IOFlagController + PDP8 + SkipController + + + + ioFlagController + IOFlagController + + + pdp8 + PDP8 + + + skipController + SkipController + + + + IBProjectSource + Plugins/PluginManager.h + + + + PluginManager + NSObject + + IBUserSource + + + + + PreferencesController + NSObject + + prefPanel + NSPanel + + + prefPanel + + prefPanel + NSPanel + + + + IBProjectSource + Panels/PreferencesController.h + + + + PreferencesController + NSObject + + IBUserSource + + + + + RegisterFormCell + NSFormCell + + registerOwner + id + + + registerOwner + + registerOwner + id + + + + IBProjectSource + Utilities/RegisterFormCell.h + + + + RegisterFormCell + NSFormCell + + IBUserSource + + + + + SkipController + NSObject + + PDP8 + TableCornerView + + + + pdp8 + PDP8 + + + view + TableCornerView + + + + IBProjectSource + CPUWindow/SkipController.h + + + + SkipController + NSObject + + IBUserSource + + + + + TableCornerView + NSControl + + IBProjectSource + Utilities/TableCornerView.h + + + + TableCornerView + NSControl + + IBUserSource + + + + + + + EnableDisableTextField + NSTextField + + IBFrameworkSource + PluginFramework.framework/Headers/EnableDisableTextField.h + + + + KeepInMenuWindow + NSWindow + + IBFrameworkSource + PluginFramework.framework/Headers/KeepInMenuWindow.h + + + + NSControl + + IBFrameworkSource + PluginFramework.framework/Headers/NSControl+FileDrop.h + + + + NSTableView + + IBFrameworkSource + PluginFramework.framework/Headers/NSTableView+Scrolling.h + + + + PDP8 + NSObject + + BreakpointArray + BreakpointArray + + + + breakopcodes + BreakpointArray + + + breakpoints + BreakpointArray + + + + IBFrameworkSource + PluginFramework.framework/Headers/PDP8.h + + + + RegisterFormCell + NSFormCell + + IBFrameworkSource + PluginFramework.framework/Headers/RegisterFormCell.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + YES + ../../pdp8e-simulator.xcodeproj + 3 + + {9, 8} + {7, 2} + {15, 15} + {9, 45} + + + diff --git a/Resources/English.lproj/MainMenu.nib/keyedobjects.nib b/Resources/English.lproj/MainMenu.nib/keyedobjects.nib new file mode 100644 index 0000000..cb48a8a Binary files /dev/null and b/Resources/English.lproj/MainMenu.nib/keyedobjects.nib differ diff --git a/Resources/English.lproj/OnlineHelp/AsciiCharacterTable/AsciiCharacterTable.html b/Resources/English.lproj/OnlineHelp/AsciiCharacterTable/AsciiCharacterTable.html new file mode 100644 index 0000000..91cc89f --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/AsciiCharacterTable/AsciiCharacterTable.html @@ -0,0 +1,240 @@ + + + + + + ASCII Character Table + + + + + + +

ASCII Character Table

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ 1. Col.: Decimal — + 2. Col.: 7-Bit Octal — + 3. Col.: ASCII — + 4. Col.: 6-Bit Octal +
0000NULL32040SPC4064100@0096140`
1001SOH33041!4165101A0197141a
2002STX34042"4266102B0298142b
3003ETX35043#4367103C0399143c
4004EOT36044$4468104D04100144d
5005ENQ37045%4569105E05101145e
6006ACK38046&4670106F06102146f
707BEL39047'4771107G07103147g
8010BS40050(5072110H10104150h
9011HT41051)5173111I11105151i
10012LF42052*5274112J12106152j
11013VT43053+5375113K13107153k
12014FF44054,5476114L14108154l
13015CR45055-5577115M15109155m
14016SO46056.5678116N16110156n
15017SI47057/5779117O17111157o
16020DLE4806006080120P20112160p
17021DC14906116181121Q21113161q
18022DC25006226282122R22114162r
19023DC35106336383123S23115163s
20024DC45206446484124T24116164t
21025NAK5306556585125U25117165u
22026SYN5406666686126V26118166v
23027ETB5506776787127W27119167w
24030CAN5607087088130X30120170x
25031EM5707197189131Y31121171y
26032SUB58072:7290132Z32122172z
27033ESC59073;7391133[33123173{
28034FS60074<7492134\34124174|
29035GS61075=7593135]35125175}
30036RS62076>7694136^36126176~
31037US63077?7795137_37127177DEL
+ + + diff --git a/Resources/English.lproj/OnlineHelp/DataFormats/DataFormats.html b/Resources/English.lproj/OnlineHelp/DataFormats/DataFormats.html new file mode 100644 index 0000000..b91746f --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/DataFormats/DataFormats.html @@ -0,0 +1,157 @@ + + + + + + Data Formats + + + + + + +

Data Formats in the Memory Inspector Drawer

+ +
    +
  • +6-Bit ASCII. +Two 6-bit ASCII characters are packed into one memory word, +the first character in the most significant half of the word. +This format is often used for packed storage of character strings in +the PDP-8 memory. +
  • +
  • +8-Bit ASCII. +Any memory word contains one 8-bit ASCII character, stored in the least +significant bits fo the word. The memory inspector ignores the most +significant bit because it is normally set to one or used as a parity bit. +
  • +
  • +OS/8 Packed 8-Bit ASCII. +The OS/8 Disk Monitor System uses this format for storing text files. +Three 8-bit characters aaaaAAAA bbbbBBBB ccccCCCC are stored in two +consecutive 12-bit words as ccccaaaaAAAA CCCCbbbbBBBB. The memory inspector +ignores the most significant bits of the 8-bit characters. +
  • +
  • +Sigend Integer. +The 12-bit memory words are interpreted as 12-bit two’s complement +numbers. The valid range is −2048 to 2047. +
  • +
  • +Unsigned Integer. +The 12-bit memory words are interpreted as 12-bit binary numbers. +The valid range is 0 to 4095. +
  • +
  • +Double Word Signed Integer. +Two consecutive 12-bit memory words are interpreted as a 24-bit two’s +complement number. The first 12-bit word contains the least significant half +of the number, the second word the most significant half. This is the order +used by the EAE instructions DAD and DST. The valid range is −8388608 to +8388607. +
  • +
  • +Double Word Unsigned Integer. +Two consecutive 12-bit memory words are interpreted as a 24-bit binary number. +The first 12-bit word contains the least significant half of the number, the +second word the most significant half. The valid range is 0 to 16777215. +
  • +
  • +FPP8-A Floating Point. +This is the single precision floating point format used by the FPP8-A floating +pointn processor, the DEC floating point software package and a lot of PDP-8 +software, e. g. FORTRAN IV and FOCAL-8. FP numbers are stored in three +memory words: + +The expontent e is a 12-bit signed two’s complement integer, +the mantissa is interpreted as a signed two’s complement normalized +fration, i. e. 0.5 ≤ |m| < 1, and the represented number +is m · 2e. The range of FP numbers is +about −0.99E+619 to 0.99E+619; they have about six significant decimal +digits. +

    +

    + +
    +

    +
  • +
  • +FPP8-A EP Floating Point. +This is the extended precision floating point format of the FPP8-A floating +point processor. The EP format is the same as the FP format, but the mantissa +occupies five 12-bit words, extending the precision of EP numbers to +approximately 15 significant decimal digits. +
  • +
  • +FORTRAN II Floating Point. +This floating point format is used by the PDP-8 8K FORTRAN system. +A number of this format is stored in three words: +

    +

    + +
    +

    +The exponent e of the number is stored (after adding 200 (octal)) as +an 8-bit unsigned binary number. The mantissa m is stored as a 27-bit +usigned normalized fraction, i. e. 0.5 ≤ m < 1. +The range of FORTRAN II floating point numbers is about −1.7E+38 to +1.7E+38, the smallest nonzero number is ±0.14E−38; they have +approximately eight significant decimal digits. +
  • +
  • +Pascal-S Floating Point. +This is the floating point format used by the PDP-8 Pascal-S compiler of +Heinz Stegbauer. It is the same as the FPP8-A FP format, but uses three words +for the mantissa (about ten significant decimal digits) and stores it as an +unsigned (not two’s complement) normalized fraction. +
  • +
+ +

Remarks

+ +
    +
  • +For input and output of PDP-8 floating point formats in the memory inspector, +the simulator uses IEEE double precision floating point numbers as an intermediate +format. Because the biggest IEEE double is 1.79E+308, there are very big PDP-8 +floating point numbers which cannot be represented as an IEEE double. These +numbers are displayed as “(IEEE overflow)”. Likewise very small +PDP-8 floating point numbers can cause an IEEE double underflow, signaled by +“(IEEE underflow)”. Because IEEE doubles have fewer mantissa bits +than the FPP8-A EP floating point numbers, the rightmost bits of the EP +format mantissa are ignored. Bit patterns which do not represent normalized, +valid PDP-8 floating point numbers are indicated by “(not normalized)”. +
  • +
  • +Plug-ins for the PDP-8/E Simulator can add additional formats to the memory inspector drawer. +They simply have to provide an Objective-C subclass of “NSFormatter” that conforms +to the “MemoryInspectorProtocol” protocol from the plug-in API. These classes are +automatically detected and registered. +
  • +

    + + + diff --git a/Resources/English.lproj/OnlineHelp/DataFormats/fortran2fp.png b/Resources/English.lproj/OnlineHelp/DataFormats/fortran2fp.png new file mode 100644 index 0000000..699f8f4 Binary files /dev/null and b/Resources/English.lproj/OnlineHelp/DataFormats/fortran2fp.png differ diff --git a/Resources/English.lproj/OnlineHelp/DataFormats/fpp8a_fp.png b/Resources/English.lproj/OnlineHelp/DataFormats/fpp8a_fp.png new file mode 100644 index 0000000..77bd72b Binary files /dev/null and b/Resources/English.lproj/OnlineHelp/DataFormats/fpp8a_fp.png differ diff --git a/Resources/English.lproj/OnlineHelp/ExtendedArithmeticElement/ExtendedArithmeticElement.html b/Resources/English.lproj/OnlineHelp/ExtendedArithmeticElement/ExtendedArithmeticElement.html new file mode 100644 index 0000000..c5a767f --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/ExtendedArithmeticElement/ExtendedArithmeticElement.html @@ -0,0 +1,461 @@ + + + + + + KE8-E Extended Arithmetic Element + + + + + + +

    KE8-E Extended Arithmetic Element

    + +

    +The instructions for the KE8-E Extended Arithmetic Element are operate +instructions with bits 3 and 11 set. They are microprogrammable and are +often called Group 3 Microoperations. +

    + +

    +With the PDP-8/E (not with earlier models), the EAE has two operation modes. +In mode A, the EAE is software compatible to older PDP-8 EAEs; in mode B, +it provides an extended set of instructions. The PDP-8/E (not the earlier +models PDP-8, -8/S, -8/I, -8/L) has the MQ register and the group 3 +microoperations NOP (7401), MQL (7421), MQA (7501), and CLA (7601) +(and their microprogrammed combinations, e. g. SWP (7521), +CAM (7621), ACL (7701)) even if it has no EAE. +

    + +

    +Some of the EAE instructions require a direct operand in an extension word +of the instruction. Some mode B instructions use this extension word for +indirect addressing of the operand. In this case, when the extension word +is located in an autoindexing memory location (0010–0017 on each +field), autoincrementing takes place, i. e. the extension word is +incremented before it is used as the operands address. +

    + +

    +Bit assignments of the group 3 microinstructions: + +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Mode A:SCA +
    + + + + + + + + + + + + + + + + + + + + +
    Bits 8–10
    0 - NOP4 - NMI
    1 - SCL5 - SHL
    2 - MUY6 - ASR
    3 - DVI7 - LSR
    +
    +
    Mode A and B:CLAMQAMQL
    Opcode 1111
    Bits01234567891011
    Mode B: + Group Bit: 1
    + (with Bit 11 = 1):
    + Group 3









    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Bits 6 and 8–10
    00 - NOP10 - SCA
    01 - ACS11 - DAD
    02 - MUY12 - DST
    03 - DVI13 - SWBA
    04 - NMI14 - DPSZ
    05 - SHL15 - DPIC
    06 - ASR16 - DCM
    07 - LSR17 - SAM
    +
    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Mnemonic
    Symbol
    Octal
    Code
    Sequence/
    EAE Mode

    Description
    NOP7401−/A,B + No operation. +
    CLA76011/A,B + Clear AC. The AC is cleared during sequence 1, allowing this + command to be combined with EAE commands that load AC during + sequence 2. +
    MQA75012/A,B + Load MQ into AC (by performing a logical OR of AC and MQ). +
    MQL74212/A,B + Load MQ from AC, then clear AC. +
    SWP75212/A,B + Swap the contents of AC and MQ. Microprogrammed combination + of MQA and MQL. +
    ACL77011,2/A,B + Load MQ into AC. Microprogrammed combination of CLA and MQA. +
    CAM76211,2/A,B + Clear AC and MQ. Microprogrammed combination of CLA and MQL. +
    SWAB74312/A,B + Switch to EAE mode B (and execute MQL). +
    SCA #74033/A + Load SC from memory. Loads the complement of bis 7–11 of + the memory word following the instruction into the step counter. +
    ACS74033/B + Load SC from AC(7–11) and then clear AC. +
    MUY #74053/A + Multiply. The number held in MQ is multiplied by the number + held in the memory word following the instruction. The most + significatn 12 bits of the product are containted in AC and + the least significatn 12 bits are contained in MQ. +
    DVI #74073/A + Divide. The 24-bit dividend held in AC (most significant 12 bits) + and MQ (least significant 12 bits) is divided by the number held + in the memory word following the instruction. After execution of + this instruction the quotient is held in MQ, the remainder is + held in AC, and L is cleared. If L contains a one, a divide + overflow occured and the operation was aborted after the first + cycle of the division. +
    DVI #74073/B + Same as mode A divide, but the word following the instruction + does not contain the divisor, but the address (in DF) of the + divisor. +
    NMI74113/A,B + Normalize. This instruction is used as part of the conversion + of a binary number to a fraction and an exponent for use in + floating point arithmetic. The combined content of AC and MQ + is shifted left by this command until AC(0) ≠ AC(1) + (or AC(2–11) and MQ become zero). Zeros are shifted into + the vacated MQ(11) positions. At the conclusion of this operation, + the step counter SC contains the number of shifts performed. + The content of L is lost. (In mode B operation, if, at the end + of the normalization, only AC(0) is set (and AC(1–11) and + MQ are zero), then AC is cleared.) NMI nust not be combined + with other EAE operations. +
    SHL #74133/A,B + Shift arithmetic left. This instruction shifts the combined + content of AC and MQ to the left one more than the number of + positions (mode A) resp. exactly the number of positions (mode B) + indicated by the content of the memory location following the + instruction. During the shifting, zeros are shifted into + vacated MQ(11) positions. +
    ASR #74153/A,B + Arithmetic shift right. The combined content of AC and MQ is + shifted right one position more than (mode A) resp. exactly the + number of positions (mode B) contained in the memory location + following the instruction. The sign bit, contained in AC(0), + enters vacated positions. In mode B operation, GTF receives the + last digit shifted out of MQ(11). SC is set to zero in mode A + and to 37 (octal) in mode B operation. +
    LSR #74173/A,B + Logical shift right. This instruction works as ASR except that + zeros enter vacated positions at AC(0) instead of the sign bit. +
    DAD #74433/B + Double word addition. The content of the memory word following + the instruction is used as the address (in DF) of a double word + in memory (first word: least significant 12 bits, second word: + most significant 12 bits.) This double word is added to the + 24-bit number contained in AC (most significant 12 bits) and + MQ (least significant 12 bits). The result is stored in AC and + MQ; L receives the carry. +
    SWBA74473/A,B + Switch to EAE mode A (and clear GTF). When it is combined with + other EAE operations, SWBA is ignored when running in EAE mode B. +
    DPSZ74513/B + Skip the next instruction if the double word held in AC and MQ + is zero. +
    DPIC75733/B + Increment the double word held in AC and MQ by one. If an + overflow occurs, L receives the carry. (The DPIC instruction + requires the MQA and MQL bits to be set. If they are not set + (opcode 7453), the increment takes place for the double word + with MSBs in MQ and LSBs in AC.) +
    DCM75753/B + Build the two’s complement of the double word held in + AC and MQ. If an overflow occurs, L receives the carry. + (The DCM instruction requires the MQA and MQL bits to be set. + If they are not set (opcode 7455), the complement is build for + the double word with MSBs in MQ and LSBs in AC.) +
    SAM74573/B + Subtract. The content of AC is subtracted form the content of MQ, + and the result is stored in AC. The values in AC and MQ are + treated as signed two’s complement numbers. The greater than + flag GTF is set to one if the result of the subtraction is + positiv, otherwise it is cleared. +
    DLD #76631–3/B + Load double word. This is the microprogrammed combination of + CLA, MQL and DAD. +
    DDZ #76651–3/B + Store double word zero in memory. This is the microprogrammed + combination of CLA, MQL and DST. +
    SGT6006−/B + Skip on GTF. The next instruction is skipped if the greater than + flag is set. Note that this is an IOT instruction. +
    + + + diff --git a/Resources/English.lproj/OnlineHelp/InterruptControl/InterruptControl.html b/Resources/English.lproj/OnlineHelp/InterruptControl/InterruptControl.html new file mode 100644 index 0000000..344f494 --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/InterruptControl/InterruptControl.html @@ -0,0 +1,170 @@ + + + + + + Interrupt Control + + + + + + +

    Interrupt Control

    + +

    +On the PDP-8, an interrupt can occur when the interrupt enable flag is set and +the delay and inhibit flags are cleared. With the PDP-8/E (not with earlier +models), any I/O device has an interrupt enable flag. They and the I/O flags of +the devices are collected in the interrupt enable and I/O flags table of the CPU +window. When a devices interrupt mask flag is set, this device can cause an +interrupt by setting its I/O flag when completing an I/O operation to signal that +it is ready for new I/O operations or that new input is available. The interrupt +mask flags can be set or cleared by device specific IOTs. +

    + +

    +When the CPU accepts an interrupt, i. e. when the interrupt enable flag is set, +the delay and inhibit flags are cleared and a device thats interrupt mask flag is set +raises its I/O flag, the following happens: The CPU completes the execution of the +instruction in progress and acknowledges the interrupt. The interrupt enable flag +is cleared, i. e. no further interrupts can occur, the content of PC is saved in +memory location 0 (on field 0), and PC is set to one. So execution continues at +location 1 where the interrupt service routine must reside. When the PDP-8 has +a KM8-E Memory Extension, additionally the values of DF, IF and UB are saved +in the 7-bit register SF (UB in SF(0), IF in SF(1–3), and DF in SF(4–6)), +and DF, IF, IB, UB, and UF are cleared, i. e. the CPU switches to memory field 0 +and to system mode (UF=0). +

    + +

    +When the interrupt service routine has serviced the I/O request, it must enable +interrupts and return to the user program. (Eventually it has to restore DF, IF, and UF; +for that and the function of the inhibit flag see the KM8-E help.) To re-enable +interrupts, it executes an ION instruction which sets the interrupt enable and delay +flag, and a JMP I 0. Because the delay flag is set, no interrupt can occur between the +ION and JMP instruction which would destroy the return address in location 0. The +delay flag is cleared in any instruction cycle after checking for interrupts and +before execution of the instruction; so new interrupts can occur after execution of +the JMP instruction. +

    + +

    +The machine instructions for controlling the interrupt facility are IOTs with +I/O address 0: +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Mnemonic
    Symbol
    Octal
    Code

    Description
    SKON6000 + Skip the next instruction if interrupts are enabled and disable interrupts, + i. e. clear the interrupt enable flag. +
    ION6001 + Turn interrupts on and enable the computer to respond to an interrupt request. + When this instruction is given, the computer executes the next instruction, + then enables interrupts. The additional instruction allows exit from the + interrupt service routine before allowing another interrupt to occur. +
    IOF6002 + Turn interrupts off, i. e. disable interrupts. +
    SRQ6003 + Skip on interrupt request. When the interrupt enable flag and the I/O flag of + any I/O device are set, the next instruction is skipped. +
    GTF6004 + Get interrupt flags. All status flags of the CPU are loaded into AC:
    + AC(0) = L flag,
    + AC(1) = GTF (when the EAE is running in mode B),
    + AC(2) = 1 when an interrupt request is pending, else 0,
    + AC(3) = 0 (the KM8-E was specified to load the interrupt inhibit flag into + AC(3), but the hardware ignores this flag),
    + AC(4) = interrupt enable flag,
    + AC(5–11) = SF. +
    RTF6005 + Restore interrupt flags. This is the invers operation of GTF and loads the + CPU status flags from AC:
    + L = AC(0),
    + GTF = AC(1) (when the EAE is running in mode B),
    + SF = AC(5–11),
    + UB = AC(5),
    + IB = AC(6–8),
    + DF = AC(9–11),
    + Interrupt inhibit flag = 1,
    + Interrupt enable flag = 1,
    + Interrupt delay flag = 1. +
    SGT6006 + Clear all flags. This instruction clears L, AC, the interrupt enable, delay + and inhibit flag, the I/O flags, the interrupt enable flags (it sets the + enable flags for TTY input and output and, if UB is one, the user mode mask); + it switches the EAE to mode A and clears GTF, and it clears the input and + output registers of all attached I/O devices. +
    + +

    Remark

    + +

    +Earlier PDP-8 models (PDP-8, -8/S, -8/I, -8/L) do not support IOTs SKON (6000) and +SRQ, GTF, RTF, SGF, CAF (6003–6007). +

    + + + diff --git a/Resources/English.lproj/OnlineHelp/MemoryExtension/MemoryExtension.html b/Resources/English.lproj/OnlineHelp/MemoryExtension/MemoryExtension.html new file mode 100644 index 0000000..da28542 --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/MemoryExtension/MemoryExtension.html @@ -0,0 +1,164 @@ + + + + + + KM8-E Memory Extension + + + + + + +

    KM8-E Memory Extension

    + +

    +The KM8-E IOTs enable programs to change the instruction and data field +registers (IF and DF) of the KM8-E Memory Extension to address up to 32K +words of memory and to operate the time sharing capabilities of the +extended PDP-8. For information about memory field addressing with the +KM8-E, see +here. +

    + +

    +The time sharing option of the KM8-E can be enabled with a jumper on the +board. When this jumper is in place, loading of the UF flip flop from the +UBB flip flop is inhibited. When the jumper is removed, loading of UF is +enabled. With the PDP-8/E Simulator, this jumper is emulated by a checkbox +in the PDP-8/E CPU preferences panel. +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Mnemonic
    Symbol
    Octal
    Code

    Description
    CDF x0662x1 + Change to data field x (x=0,…,7). The data field register DF + is loaded with the selected field number x. All subsequent memory + requests for operands are automatically switched to that memory + field until the field number is changed by a new CDF command or an + interrupt occurs. +
    CIF x062x2 + Prepare to change to instruction field x (x=0,…,7). The + instruction field buffer IB is loaded with the selected field + number x, and the interrupt inhibit flag is set. The next JMP or + JMS insruction causes the value of IB to be loaded into IF and the + inhibit flag to be cleared. This enables a program to continue at + a defined location on the new instruction field and disables + interrupts while the new field setting is pending. +
    CDI x062x3 + Microprogrammed combination of CDF x0 and CIF x0. +
    CINT6204 + Clear the user mode I/O flag. The user mode I/O flag is set when + the CPU executes a privileged instruction (IOT or HLT) when running + in user mode (UF=1). Then an interrupt will occur to enable the + operating system to handle this exception and to clear the flag + with CINT. +
    RDF6214 + Read data field DF into AC(6–8) (logical OR of IF with + AC(6–8)). The other bits of AC are not affected. +
    RIF6224 + Same as RDF except that the instruction field IF is read. +
    RIB6234 + Read interrupt buffer SF (save field) into AC(5–11) (logical + OR of SF with AC(5–11)). The other bits of AC are not + affected. +
    RMF6244 + Restore memory fields to exit from an interrupt service routine. + This instruction loads UB from SF(0), IB from SF(1–3) and + DF from SF(4–6). +
    SINT6254 + Skip the next instruction if the user mode I/O flag is set. + Usefull for checking if an interrupt was caused by the execution + of a privileged instruction in user mode. +
    CUF6264 + Clear user flag. This instruction clears the UB flip flop. +
    SUF6274 + Set user flag. This instruction sets the UB flip flop and the + interrupt inhibit flag. The next JMP or JMS instruction loads + UB into UF and clears the inhibit flag and so switches the CPU + to user mode operation. +
    + + + diff --git a/Resources/English.lproj/OnlineHelp/MemoryReferenceInstructions/MRI-Example.png b/Resources/English.lproj/OnlineHelp/MemoryReferenceInstructions/MRI-Example.png new file mode 100644 index 0000000..89461f7 Binary files /dev/null and b/Resources/English.lproj/OnlineHelp/MemoryReferenceInstructions/MRI-Example.png differ diff --git a/Resources/English.lproj/OnlineHelp/MemoryReferenceInstructions/MemoryReferenceInstructions.html b/Resources/English.lproj/OnlineHelp/MemoryReferenceInstructions/MemoryReferenceInstructions.html new file mode 100644 index 0000000..1f92615 --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/MemoryReferenceInstructions/MemoryReferenceInstructions.html @@ -0,0 +1,221 @@ + + + + + + Memory Reference Instructions + + + + + + +

    Instruction Format of Memory Reference Instructions (MRIs)

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    Opcode
    + Page
    + Bit +

    Page Address
    Bits01234567891011
    + Address
    + Mode Bit +
    +
    + +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    MnemonicOpcodeDescription
    AND Y000 + Logical AND. The AND operation is performed between the + content of memory location Y and the content of AC. The + result is left in AC, the original content of AC is + lost, and the content of Y is unchanged. +
    TAD Y001 + Two’s complement add. The content of memory + location Y is added to the content of AC in + two’s complement arithmetic. The result of this + addition is held in AC, the original content of AC is + lost, and the content of Y is unchanged. If there is + a carry from the MSB of AC, the L flag is + complemented. +
    ISZ Y010 + Increment and skip if zero. The content of memory + location Y is incremented by one. If the resultant + content of Y equals zero, the content of PC is + incremented and the next instruction is skipped. + If the resultant content of Y does not equal zero, + the program proceeds to the next instruction. +
    DCA Y011 + Deposit and clear AC. The content of AC is deposited + in core memory at the address Y and AC is cleared. + The previous content of memory location Y is lost. +
    JMS Y100 + Jump to subroutine. The incremented content of PC is + deposited in core memory location Y, and PC is loaded + with the address of the memory location Y+1. So the + first word of the subroutine contains the return + address and execution continues at the second word + of the subroutine. +
    JMP Y101 + Jump to Y. The address Y is loaded into PC so that the + next instruction is taken from core memory location Y. + The original content of PC is lost. +
    + +

    Addressing Modes

    + +

    +When the Address Mode Bit is zero, the memory location +specified by the instruciton word contains the operand +(direct addressing). When the Address Mode Bit is +one, the memory location specified by the instruction word +contains the address of the operand +(indirect addressing). In symbolic notation, +indirect addressing is indicated by the letter “I” +between the mnemonic and the actual address, e. g. +“TAD I 10”. +

    + +

    The Page Bit

    + +

    +The basic 4K core memory is (logically) partitioned into 32 +pages of 128 (octal 200) words each. A page number determines +the five most significant bits of an address. When the Page +Bit of a MRI is zero, the operand is taken from memory page +zero. When the Page Bit is one, the page number of the operand +is the number of the page where the instruction resides, +i. e. the five MSBs of the operand address are identical +to the five MSBs of the instruction words address. The offset +inside the designated page is taken from the Page Address part +(bits 5–11) of the instruction word. +

    + +

    Autoindexing Memory Locations

    + +

    +Memory locations 0010–0017 (of all memory fields, +i. e. locations 00010–00017, 10010–10017, +20010–20017, …) are special registers which are +automatically incremented when they are used as pointer +addresses of indirectly addressed memory reference +instructions. The increment takes place before the +value is used as indirect address. When these locations are +addressed directly, they behave as any other memory location. +

    + +

    +Note that the CPU window displays disassembled instructions +as if the increment of autoindexing memory locations has +already occured; showing the location the instruction will +really access. The autoindexing addresses appear underlined +in the CPU window. +

    + +

    Memory Reference Instructions with the KM8-E Memory Extension

    + +

    +When the PDP-8 has a KM8-E Memory Extension, it can have up to +32K words of core memory, partitioned in eight 4K fields. The +value of the KM8-E register IF (Instruction Field) is used as +a 3-bit extension of the PC. IF not only determines the +memory field where the next instruction is to be taken from, +but also the field where directly addressed operands and the +pointer addresses of indirectly addressed operands are to be +taken from. The final operand of the indirect addressing is +taken from the memory field designated by the KM8-E register +DF (Data Field). +

    + +

    Example

    + +

    Assume DF=1, IF=2, PC=205 (octal).
    +

    +

    + + + diff --git a/Resources/English.lproj/OnlineHelp/OperateInstructions/OperateInstructions.html b/Resources/English.lproj/OnlineHelp/OperateInstructions/OperateInstructions.html new file mode 100644 index 0000000..90afe52 --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/OperateInstructions/OperateInstructions.html @@ -0,0 +1,745 @@ + + + + + + Operate Instructions + + + + + + +

    Operate Instructions

    + +

    +The operate instructions allow a program to manipulate or test the +data located in AC and the L flag. Many different instructions are +possible with one operation code because the operand bits are not +needed to specify an address as they are in a MRI and can be used +to specify different instructions. Combining more than one operation +in an OPR instruction by setting more than one operation bit is +called Microprogramming. The instructions that can be +combined in one OPR — called Microoperations — +are executed in a defined order: they have a Sequence Number +between one and four, and they are executed in the order of their +sequence numbers. The operate instructions are separated in two +groups: Group 1, which contains manipulation instructions, +and Group 2, which is primarily concerned with testing operations. +

    + +

    Group 1 Microinstructions

    + +

    +Bit assignments of the group 1 microinstructions: +

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Opcode 111CLACLLCMACMLRARRALIAC
    Bits01234567891011
    + Group Bit:
    + 0: Group 1
    + 1: Group 2
    +   +
    + BSW or
    + Rotate Count:
    + 0: Rotate once
    + 1: Rotate twice +
    +
    + +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    MnemonicSeq.Description
    CLA1 + Clear the accumulator. If bit 4 is one, the instruction + sets the accumulator to all zeros. +
    CLL1 + Clear the link flag. If bit 5 is one, the link flag is + set to zero. +
    CMA2 + Complement the accumulator. If bit 6 is one, the + accumulator is set to the one’s complement + of its original value. +
    CML2 + Complement the link flag. If bit 7 is one, the state + of the link flag is reversed by the instruction. +
    RAR4 + Rotate the accumulator and the link flag right. + If bit 8 is one and bit 10 is zero, the instruction + treats AC and L as a closed loop and shifts all bits + in the loop one position to the right. +
    RTR4 + Rotate the accumulator and the link flag twice right. + If bit 8 is one and bit 10 is also one, a circular + shift of two places to the right is executed. +
    RAL4 + Rotate the accumulator and the link flag left. + If bit 9 is one and bit 10 is zero, the instruction + treats AC and L as a closed loop and shifts all bits + in the loop one position to the left. +
    RTL4 + Rotate the accumulator and the link flag twice left. + If bit 9 is one and bit 10 is also one, a circular + shift of two places to the left is executed. +
    BSW4 + Swap the bytes in the accumulator. If bit 10 is one + and bits 8 and 9 are zero, the instruction swaps the + two 6-bit bytes in AC(0–5) and AC(6–11). +
    IAC3 + Increment the accumulator. When bit 11 is one, the + content of AC is incremented by one. +
    NOP + No operation. If bits 4 through 11 contain zeros, + no operation is performed and program control is + transferred to the next instruction of the program. +
    + +

    Remarks

    + +
      +
    • + The byte swap operation BSW is not available on earlier + PDP-8 models (PDP-8, PDP-8/S, PDP-8/I, PDP-8/L). +
    • +
    • + The combination of IAC with rotate microoperations is not + allowed on the original PDP-8 and the PDP-8/S. +
    • +
    • + The combination of CMA with rotate microoperations is not + allowed on the PDP-8/S. +
    • +
    • + The meaningless combination of the RAR and RAL + microoperation have special effects on the different PDP-8 + models which allow a program to determine the model it is + running on. On the original PDP-8, combinations of RAR and + RAL or RTR and RTL have unpredictable results. On the + PDP-8/I and PDP-8/L, they produce the logical AND of the + expected results from each of the combined shifts. On the + PDP-8/E, /F, and /M, the combination of RAR and RAL produces + the logical AND of AC with the opcode, and the combination + of RTR and RTL does an effective address computation loading + the five high bits of AC with the current page and the lower + bits of AC with lower seven bits (page address) of the OPR + instruction. On the PDP-8/A, combination of RAR and RAL + produces the logical AND of AC with the opcode, and the + combination of RTR and RTL loads the next address into AC. + In the CPU window, OPR instructions with RAR and RAL + combinations are disassembled as “(reserved)”. +
    • +
    + +

    Group 2 Microinstructions

    + +

    +Bit assignments of the group 2 microinstructions: +

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    Opcode 111

    CLA
    SMA
    SPA
    SZA
    SNA
    SNL
    SZL

    OSR

    HLT

    0
    Bits01234567891011
    + Group Bit:
    + 0: Group 1
    + 1: Group 2
    +   +
    + Reverse
    Sensing Bit:
    + 0: SMA, SZA, SNL
    + 1: SPA, SNA, SZL +
    +
    +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    MnemonicSeq.Description
    CLA2 + Clear the accumulator. If bit 4 is one, the instruction + sets the accumulator to all zeros. +
    SMA1 + Skip on minus accumulator. If bit 5 is one and bit 8 is + zero, the next instruction is skipped if the accumulator + is less than zero. +
    SPA1 + Skip on positive accumulator. If bit 5 is one and bit 8 + is also one, the next instruction is skipped if the + accumulator is greater than or equal to zero. +
    SZA1 + Skip on zero accumulator. If bit 6 is one and bit 8 is + zero, the next instruction is skipped if the accumulator + is zero. +
    SNA1 + Skip on nonzero accumulator. If bit 6 is one and bit 8 + is also one, the next instruction is skipped if the + accumulator is not zero. +
    SNL1 + Skip on nonzero link. If bit 7 is one and bit 8 is zero, + the next instruction is skipped when the link flag is one. +
    SZL1 + Skip on zero link. If bit 7 is one and bit 8 is also one, + the next instruction is skipped when the link flag is zero. +
    SKP1 + Unconditional skip. If bit 8 is one and bits 5 to 7 are + all zeros, the next instruction is skipped. +
    OSR3 + Logical OR of the switch register and AC. If bit 9 is one, + a logical OR operation is performed between the content + of the accumulator and the console switch register SR. + The result is left in AC. +
    HLT3 + Halt. If bit 10 is one, the computer will stop at the + conclusion of the current machine cycle. +
    NOP + No operation. If bits 4 through 11 contain zeros, no + operation is performed and the program control is + transferred to the next instruction of the program. +
    + +

    Remarks

    + +
      +
    • + When SMA, SZA or SNL are combined (bit 8 of the instruction + is zero), the skip takes place if one of the conditions is + true, i. e. when the logical OR of the results of the + condition tests is true. When SPA, SNA or SZL are combined + (bit 8 of the instruction is one), the skip takes place if + all conditions simultaneously are true, i. e. when the + logical AND of the results of the condition tests is true. +
    • +
    • + For Group 2 OPRs, bit 11 is always zero. When the group + bit 3 and bit 11 of an OPR instruction are one, it is an + instruction for the Extended Arithmetic Element. EAE + microoperations are also called Group 3 + microoperations. +
    • +
    + +

    Mnemonics for OPR instructions

    + +

    +Some usefull microoperation combinations have special mnemonics +recognized by PDP-8 assemblers. They and the basic OPR +instructions are listed in the following table. Note that the +CPU window disassembles combined microoperations as a sequence +of basic microoperations in the order of their sequence numbers, +i. e. execution order. +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    MnemonicOctalSeq.Description
    NOP7000No operation.Group 1
    IAC70013Increment AC.
    RAL70044Rotate AC and L circular left.
    RTL70064Rotate AC and L twice circular left.
    RAR70104Rotate AC and L curcular right.
    RTR70124Rotate AC and L twice circular right.
    CML70202Complement L.
    CMA70402Complement AC.
    CIA70412,3 + Complement and increment AC, i. e. built + the two’s complement of AC. +
    CLL71001Clear L.
    CLL RAL71041,4Shift positive number one left.
    CLL RTL71061,4Clear L, rotate two left.
    CLL RAR71101,4Shift positive number one right.
    CLL RTR71121,4Clear L, rotate two right.
    STL71201,2Set L = 1.
    CLA72001Clear AC.
    CLA IAC72011,3Set AC = 1.
    GLK72041,4Get link. Transfer L into AC(11).
    CLA CLL73001Clear AC and L.
    STA72402Set AC = −1.
    BSW70024Byte swap of AC(0–5) and AC(6–11).
    HLT74023Halt the computer.Group 2
    OSR74043Logical OR AC with SR.
    SKP74101Skip unconditionally.
    SNL74201 + Skip if L ≠ 0. +
    SZL74301 + Skip if L = 0. +
    SZA74401 + Skip if AC = 0. +
    SNA74501 + Skip if AC ≠ 0. +
    SZA SNL74601 + Skip if AC = 0 or L = 1. +
    SNA SZL74701 + Skip if AC ≠ 0 and L = 0. +
    SMA75001 + Skip if AC < 0. +
    SPA75101 + Skip if AC ≥ 0. +
    SMA SNL75201 + Skip if AC < 0 or L = 1. +
    SPA SZL75301 + Skip if AC ≥ 0 and L = 0. +
    SMA SZA75401 + Skip if AC ≤ 0. +
    SPA SNA75501 + Skip if AC > 0. +
    CLA76002 + Clear AC. +
    LAS76042,3 + Load AC with SR. +
    SZA CLA76401,2 + Skip if AC = 0, then clear AC. +
    SNA CLA76501,2 + Skip if AC ≠ 0, then clear AC. +
    SMA CLA77001,2 + Skip if AC < 0, then clear AC. +
    SPA CLA77101,2 + Skip if AC ≥ 0, then clear AC. +
    + + + diff --git a/Resources/English.lproj/OnlineHelp/PDP8InstructionFormat/PDP8InstructionFormat.html b/Resources/English.lproj/OnlineHelp/PDP8InstructionFormat/PDP8InstructionFormat.html new file mode 100644 index 0000000..3779d66 --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/PDP8InstructionFormat/PDP8InstructionFormat.html @@ -0,0 +1,196 @@ + + + + + + PDP-8 Instruction Format + + + + + + +

    PDP-8 Instruction Format

    + +

    +PDP-8 machine instructions are 12-bit values; each instruction +occupies exactly one 12-bit memory word. There are eight basic +instructions, separated in three classes: +

    + +

    Memory Reference Instructions (MRIs)

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    Opcode
    + Page
    + Bit +

    Page Address
    Bits01234567891011
    + Address
    + Mode Bit +
    +
    + +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    MnemonicOctalOpcodeDescription
    AND0xxx000Logical AND
    TAD1xxx001Two’s complemend add
    ISZ2xxx010Increment and skip if zero
    DCA3xxx011Deposit and clear AC
    JMS4xxx100Jump to subroutine
    JMP5xxx101Jump
    + +

    Input Output Transfer Instructions (IOTs)

    + +
    + + + + + + + + + + + + + + + + + + + + + + +
    Opcode 110I/O Device AddressI/O Operation
    Bits01234567891011
    +
    + +

    Operate Instructions (OPRs)

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Opcode 111Microoperation
    Bits01234567891011
    + Group +
    +
    + +

    +Note that EAE instructions are special OPRs. Some of them require +a direct operand in an extension word of the instruction. +

    + + + diff --git a/Resources/English.lproj/OnlineHelp/index.html b/Resources/English.lproj/OnlineHelp/index.html new file mode 100644 index 0000000..7733d6a --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/index.html @@ -0,0 +1,71 @@ + + + + + + PDP-8/E Simulator Help + + + + + + + + + + + + + +
    +

    + + PDP-8 Instruction Format
    + + Operate Instructions
    + + Memory Reference Instructions
    + + KM8-E Memory Extension
    + + Interrupt Control
    + + Extended Arithmetic Element
    + + Data Formats in the Memory Inspector Drawer
    + + ASCII Character Table +
    +

    +
    + + + \ No newline at end of file diff --git a/Resources/English.lproj/OnlineHelp/resources/pdp8e.png b/Resources/English.lproj/OnlineHelp/resources/pdp8e.png new file mode 100644 index 0000000..2c0c485 Binary files /dev/null and b/Resources/English.lproj/OnlineHelp/resources/pdp8e.png differ diff --git a/Resources/English.lproj/OnlineHelp/resources/pdp8e_256x256.png b/Resources/English.lproj/OnlineHelp/resources/pdp8e_256x256.png new file mode 100644 index 0000000..a8d11f4 Binary files /dev/null and b/Resources/English.lproj/OnlineHelp/resources/pdp8e_256x256.png differ diff --git a/Resources/English.lproj/OnlineHelp/resources/styles.css b/Resources/English.lproj/OnlineHelp/resources/styles.css new file mode 100644 index 0000000..c18751d --- /dev/null +++ b/Resources/English.lproj/OnlineHelp/resources/styles.css @@ -0,0 +1,239 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * styles.css - Online help - Style sheet + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +p { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +p.small { + font-size: 8pt; +} + +a { + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +a:hover { + text-decoration: underline +} + +ul { + margin-left: 1.25em; padding-left: 0em; +} + +li { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +#mainbox { + background-color: #fff; + margin-top: 30px; + margin-right: 26px; + margin-left: 18px; + position: absolute; + top: 10px +} + +#taskbox { + background-color: #eee; + list-style-type: decimal; + list-style-position: outside; + margin-top: 12px; + margin-bottom: 12px; + border: solid 1px #444 +} + +h1 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 6pt; +} + +h2 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 8pt; +} + +h3 { + font-size: 10pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 5pt; +} + +h4 { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 4pt; +} + +/* index.html */ + +table.index { + padding-top: 20px; + width: 100%; +} + +td.banner { + padding: 20px; +} + +td.toc { + padding-top: 10px; + padding-bottom: 10px; + padding-left: 20px; + padding-right:20px; + border-left: 1px solid darkgray; +} + +p.toc { + line-height: 40px; +} + +/* other pages */ + +table { + border-collapse: separate; + border-spacing: 0px; +} + +th { + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + font-style: bold; + border-bottom: 1px solid gray; + padding-left: 10px; + padding-right: 10px; +} + +th.left { + text-align: left; +} + +td { + text-align: center; + vertical-align: top; + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + padding-left: 10px; + padding-right: 10px; +} + +td.left { + text-align: left; +} + +td.right { + text-align: right; +} + +td.br { + border-right: 1px solid gray; +} + +td.bb { + border-bottom: 1px solid lightgray; +} + +td.bb_left { + text-align: left; + border-bottom: 1px solid lightgray; +} + +td.bbr { + border-bottom: 1px solid lightgray; + border-right: 1px solid gray; +} + +td.opcode { + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_right { + text-align: right; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_left { + text-align: left; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-left: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + border-right: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} diff --git a/Resources/English.lproj/disassembler.plist b/Resources/English.lproj/disassembler.plist new file mode 100644 index 0000000..85fe7dc --- /dev/null +++ b/Resources/English.lproj/disassembler.plist @@ -0,0 +1,1358 @@ + + + + + + MRI + + AND + TAD + ISZ + DCA + JMS + JMP + + IOT + + + SKON + ION + IOF + SRQ + GTF + RTF + SGT + CAF + + RPE + RSF + RRB + + RFC + + RCC + + + PCE + PSF + PCF + + PPC + + PLS + + + KCF + KSF + KCC + + KRS + KIE + KRB + + + TFL + TSF + TCF + + TPC + TSK + TLS + + + DPLA + DPGO + DPSM + DPMB + DPMD + + DPCL + DPBELL + + + + + + + + + + + + + + + + + + + + DPI + SMP + SPL + EPI + CMP + SMPCMP + CEP + SPO + + + + + + + + + + + + + + + + + + + + + + CLEI + CLDI + CLSK + + CLIE + CLCF + CLSK + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CDF 0 + CIF 0 + CDI 0 + CINT + + + + + + CDF 1 + CIF 1 + CDI 1 + RDF + + + + + + CDF 2 + CIF 2 + CDI 2 + RIF + + + + + + CDF 3 + CIF 3 + CDI 3 + RIB + + + + + + CDF 4 + CIF 4 + CDI 4 + RMF + + + + + + CDF 5 + CIF 5 + CDI 5 + SINT + + + + + + CDF 6 + CIF 6 + CDI 6 + CUF + + + + + + CDF 7 + CIF 7 + CDI 7 + SUF + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ADCL + ADLM + ADST + ADRB + ADSK + ADSE + ADLE + ADRS + + + + + + + + + + + + FPINT + FPICL + FPCOM + FPHLT + FPST + FPRST + FPIST + + + + + + + + + FPEP + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + RCSF + RCRA + + RCRB + RCNO + RCRC + RCNI + + + + + + + + + + + PLCE + PLSF + PLCF + PLPU + PLLR + PLPD + PLCF PLLR + PLSE + + + PSKF + PCLF + PSKE + PSTB + PSIE + PCLF PSTB + PCIE + + + RCSD + RCSE + + RCRD + RCSI + RCTF + + + + LWCR + CWCR + LCAR + CCAR + LCMR + LFGR + LDBR + + + RWCR + CLT + RCAR + RMSR + RCMR + RFSR + RDBR + + + SKEF + SKCB + SKJD + SKTR + CLF + (maintenance) + (maintenance) + + + + + + + + + + + + DSKP + DCLR + DLAG + DLCA + DRST + DLDC + DMAN + + + + + + + + + + + + DTRA + DTCA + + DTXA + + DTLA + + + + DTSF + DTRB + + DTLB + + + + + OPR Group 1 + + + NOP + IAC + BSW + IAC BSW + RAL + IAC RAL + RTL + IAC RTL + + RAR + IAC RAR + RTR + IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CML + CML IAC + CML BSW + CML IAC BSW + CML RAL + CML IAC RAL + CML RTL + CML IAC RTL + + CML RAR + CML IAC RAR + CML RTR + CML IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CMA + CMA IAC + CMA BSW + CMA IAC BSW + CMA RAL + CMA IAC RAL + CMA RTL + CMA IAC RTL + + CMA RAR + CMA IAC RAR + CMA RTR + CMA IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CMA CML + CMA CML IAC + CMA CML BSW + CMA CML IAC BSW + CMA CML RAL + CMA CML IAC RAL + CMA CML RTL + CMA CML IAC RTL + + CMA CML RAR + CMA CML IAC RAR + CMA CML RTR + CMA CML IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLL + CLL IAC + CLL BSW + CLL IAC BSW + CLL RAL + CLL IAC RAL + CLL RTL + CLL IAC RTL + + CLL RAR + CLL IAC RAR + CLL RTR + CLL IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLL CML + CML CML IAC + CLL CML BSW + CLL CML IAC BSW + CLL CML RAL + CLL CML IAC RAL + CLL CML RTL + CLL CML IAC RTL + + CLL CML RAR + CLL CML IAC RAR + CLL CML RTR + CLL CML IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLL CMA + CLL CMA IAC + CLL CMA BSW + CLL CMA IAC BSW + CLL CMA RAL + CLL CMA IAC RAL + CLL CMA RTL + CLL CMA IAC RTL + + CLL CMA RAR + CLL CMA IAC RAR + CLL CMA RTR + CLL CMA IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLL CMA CML + CLL CMA CML IAC + CLL CMA CML BSW + CLL CMA CML IAC BSW + CLL CMA CML RAL + CLL CMA CML IAC RAL + CLL CMA CML RTL + CLL CMA CML IAC RTL + + CLL CMA CML RAR + CLL CMA CML IAC RAR + CLL CMA CML RTR + CLL CMA CML IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLA + CLA IAC + CLA BSW + CLA IAC BSW + CLA RAL + CLA IAC RAL + CLA RTL + CLA IAC RTL + + CLA RAR + CLA IAC RAR + CLA RTR + CLA IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLA CML + CLA CML IAC + CLA CML BSW + CLA CML IAC BSW + CLA CML RAL + CLA CML IAC RAL + CLA CML RTL + CLA CML IAC RTL + + CLA CML RAR + CLA CML IAC RAR + CLA CML RTR + CLA CML IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLA CMA + CLA CMA IAC + CLA CMA BSW + CLA CMA IAC BSW + CLA CMA RAL + CLA CMA IAC RAL + CLA CMA RTL + CLA CMA IAC RTL + + CLA CMA RAR + CLA CMA IAC RAR + CLA CMA RTR + CLA CMA IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLA CMA CML + CLA CMA CML IAC + CLA CMA CML BSW + CLA CMA CML IAC BSW + CLA CMA CML RAL + CLA CMA CML IAC RAL + CLA CMA CML RTL + CLA CMA CML IAC RTL + + CLA CMA CML RAR + CLA CMA CML IAC RAR + CLA CMA CML RTR + CLA CMA CML IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLA CLL + CLA CLL IAC + CLA CLL BSW + CLA CLL IAC BSW + CLA CLL RAL + CLA CLL IAC RAL + CLA CLL RTL + CLA CLL IAC RTL + + CLA CLL RAR + CLA CLL IAC RAR + CLA CLL RTR + CLA CLL IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLA CLL CML + CLA CLL CML IAC + CLA CLL CML BSW + CLA CLL CML IAC BSW + CLA CLL CML RAL + CLA CLL CML IAC RAL + CLA CLL CML RTL + CLA CLL CML IAC RTL + + CLA CLL CML RAR + CLA CLL CML IAC RAR + CLA CLL CML RTR + CLA CLL CML IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLA CLL CMA + CLA CLL CMA IAC + CLA CLL CMA BSW + CLA CLL CMA IAC BSW + CLA CLL CMA RAL + CLA CLL CMA IAC RAL + CLA CLL CMA RTL + CLA CLL CMA IAC RTL + + CLA CLL CMA RAR + CLA CLL CMA IAC RAR + CLA CLL CMA RTR + CLA CLL CMA IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + CLA CLL CMA CML + CLA CLL CMA CML IAC + CLA CLL CMA CML BSW + CLA CLL CMA CML IAC BSW + CLA CLL CMA CML RAL + CLA CLL CMA CML IAC RAL + CLA CLL CMA CML RTL + CLA CLL CMA CML IAC RTL + + CLA CLL CMA CML RAR + CLA CLL CMA CML IAC RAR + CLA CLL CMA CML RTR + CLA CLL CMA CML IAC RTR + (reserved) + (reserved) + (reserved) + (reserved) + + OPR Group 2 + + + NOP + HLT + OSR + OSR HLT + SKP + SKP HLT + SKP OSR + SKP OSR HLT + + SNL + SNL HLT + SNL OSR + SNL OSR HLT + SZL + SZL HLT + SZL OSR + SZL OSR HLT + + SZA + SZA HLT + SZA OSR + SZA OSR HLT + SNA + SNA HLT + SNA OSR + SNA OSR HLT + + SZA SNL + SZA SNL HLT + SZA SNL OSR + SZA SNL OSR HLT + SNA SZL + SNA SZL HLT + SNA SZL OSR + SNA SZL OSR HLT + + SMA + SMA HLT + SMA OSR + SMA OSR HLT + SPA + SPA HLT + SPA OSR + SPA OSR HLT + + SMA SNL + SMA SNL HLT + SMA SNL OSR + SMA SNL OSR HLT + SPA SZL + SPA SZL HLT + SPA SZL OSR + SPA SZL OSR HLT + + SMA SZA + SMA SZA HLT + SMA SZA OSR + SMA SZA OSR HLT + SPA SNA + SPA SNA HLT + SPA SNA OSR + SPA SNA OSR HLT + + SMA SZA SNL + SMA SZA SNL HLT + SMA SZA SNL OSR + SMA SZA SNL OSR HLT + SPA SNA SZL + SPA SNA SZL HLT + SPA SNA SZL OSR + SPA SNA SZL OSR HLT + + CLA + CLA HLT + CLA OSR + CLA OSR HLT + SKP CLA + SKP CLA HLT + SKP CLA OSR + SKP CLA OSR HLT + + SNL CLA + SNL CLA HLT + SNL CLA OSR + SNL CLA OSR HLT + SZL CLA + SZL CLA HLT + SZL CLA OSR + SZA CLA OSR HLT + + SZA CLA + SZA CLA HLT + SZA CLA OSR + SZA CLA OSR HLT + SNA CLA + SNA CLA HLT + SNA CLA OSR + SNA CLA OSR HLT + + SZA SNL CLA + SZA SNL CLA HLT + SZA SNL CLA OSR + SZA SNL CLA OSR HLT + SNA SZL CLA + SNA SZL CLA HLT + SNA SZL CLA OSR + SNA SZL CLA OSR HLT + + SMA CLA + SMA CLA HLT + SMA CLA OSR + SMA CLA OSR HLT + SPA CLA + SPA CLA HLT + SPA CLA OSR + SPA CLA OSR HLT + + SMA SNL CLA + SMA SNL CLA HLT + SMA SNL CLA OSR + SMA SNL CLA OSR HLT + SPA SZL CLA + SPA SZL CLA HLT + SPA SZL CLA OSR + SPA SZL CLA OSR HLT + + SMA SZA CLA + SMA SZA CLA HLT + SMA SZA CLA OSR + SMA SZA CLA OSR HLT + SPA SNA CLA + SPA SNA CLA HLT + SPA SNA CLA OSR + SPA SNA CLA OSR HLT + + SMA SZA SNL CLA + SMA SZA SNL CLA HLT + SMA SZA SNL CLA OSR + SMA SZA SNL CLA OSR HLT + SPA SNA SZL CLA + SPA SNA SZL CLA HLT + SPA SNA SZL CLA OSR + SPA SNA SZL CLA OSR HLT + + EAE Mode A + + + NOP + SCL + MUY + DVI + NMI + SHL + ASR + LSR + + MQL + MQL SCL + MQL MUY + MQL DVI + SWAB + MQL SHL + MQL ASR + MQL LSR + + SCA + SCA SCL + SCA MUY + SWBA + SCA NMI + SCA SHL + SCA ASR + SCA LSR + + MQL SCA + MQL SCA SCL + MQL SCA MUY + MQL SCA DVI + MQL SCA NMI + MQL SCA SHL + MQL SCA ASR + MQL SCA LSR + + MQA + MQA SCL + MQA MUY + MQA DVI + MQA NMI + MQA SHL + MQA ASR + MQA LSR + + SWP + SWP SCL + SWP MUY + SWP DVI + SWP NMI + SWP SHL + SWP ASR + SWP LSR + + MQA SCA + MQA SCA SCL + MQA SCA MUY + MQA SCA DVI + MQA SCA NMI + MQA SCA SHL + MQA SCA ASR + MQA SCA LSR + + SWP SCA + SWP SCA SCL + SWP SCA MUY + SWP SCA DVI + SWP SCA NMI + SWP SCA SHL + SWP SCA ASR + MQA MQA SCA LSR + + CLA + CLA SCL + CLA MUY + CLA DVI + CLA NMI + CLA SHL + CLA ASR + CLA LSR + + CAM + CAM SCL + CAM MUY + CAM DVI + CAM NMI + CAM SHL + CAM ASR + CAM LSR + + CLA SCA + CLA SCA SCL + CLA SCA MUY + CLA SCA DVI + CLA SCA NMI + CLA SCA SHL + CLA SCA ASR + CLA SCA LSR + + CAM SCA + CAM SCA SCL + CAM SCA MUY + CAM SCA DVI + CAM SCA NMI + CAM SCA SHL + CAM SCA ASR + CAM SCA LSR + + CLA MQA + CLA MQA SCL + CLA MQA MUY + CLA MQA DVI + CLA MQA NMI + CLA MQA SHL + CLA MQA ASR + CLA MQA LSR + + CLA SWP + CLA SWP SCL + CLA SWP MUY + CLA SWP DVI + CLA SWP NMI + CLA SWP SHL + CLA SWP ASR + CLA SWP LSR + + CLA MQA SCA + CLA MQA SCA SCL + CLA MQA SCA MUY + CLA MQA SCA DVI + CLA MQA SCA NMI + CLA MQA SCA SHL + CLA MQA SCA ASR + CLA MQA SCA LSR + + CLA SWP SCA + CLA SWP SCA SCL + CLA SWP SCA MUY + CLA SWP SCA DVI + CLA SWP SCA NMI + CLA SWP SCA SHL + CLA SWP SCA ASR + CLA SWP SCA LSR + + EAE Mode B + + + NOP + ACS + MUY + DVI + NMI + SHL + ASR + LSR + + MQL + MQL ACS + MQL MUY + MQL DVI + SWAB + MQL SHL + MQL ASR + MQL LSR + + SCA + DAD + DST + SWBA + DPSZ + (reserved - EAE Mode B) + (reserved - EAE Mode B) + SAM + + MQL SCA + MQL DAD + MQL DST + MQL (SWBA) + MQL DPSZ + (reserved - EAE Mode B) + (reserved - EAE Mode B) + MQL SAM + + MQA + MQA ACS + MQA MUY + MQA DVI + MQA NMI + MQA SHL + MQA ASR + MQA LSR + + SWP + SWP ACS + SWP MUY + SWP DVI + SWP NMI + SWP SHL + SWP ASR + SWP LSR + + MQA SCA + MQA DAD + MQA DST + MQA (SWBA) + MQA DPSZ + (reserved - EAE Mode B) + (reserved - EAE Mode B) + MQA SAM + + SWP SCA + SWP DAD + SWP DST + SWP (SWBA) + SWP DPSZ + DPIC + DCM + SWP SAM + + CLA + CLA ACS + CLA MUY + CLA DVI + CLA NMI + CLA SHL + CLA ASR + CLA LSR + + CAM + CAM ACS + CAM MUY + CAM DVI + CAM NMI + CAM SHL + CAM ASR + CAM LSR + + CLA SCA + CLA DAD + CLA DST + CLA (SWBA) + CLA DPSZ + (reserved - EAE Mode B) + (reserved - EAE Mode B) + CLA SAM + + CAM SCA + DLD + DDZ + CAM (SWBA) + CAM DPSZ + CAM DPIC + DLD + CAM SAM + + CLA MQA + CLA MQA ACS + CLA MQA MUY + CLA MQA DVI + CLA MQA NMI + CLA MQA SHL + CLA MQA ASR + CLA MQA LSR + + CLA SWP + CLA SWP ACS + CLA SWP MUY + CLA SWP DVI + CLA SWP NMI + CLA SWP SHL + CLA SWP ASR + CLA SWP LSR + + CLA MQA SCA + CLA MQA DAD + CLA MQA DST + CLA MQA (SWBA) + CLA MQA DPSZ + CLA DPIC + CLA DCM + CLA MQA SAM + + CLA SWP SCA + CLA SWP DAD + CLA SWP DST + CLA SWP (SWBA) + CLA SWP DPSZ + CLA SWP DPIC + CLA SWP DCM + CLA SWP SAM + + + diff --git a/Resources/Info.plist b/Resources/Info.plist new file mode 100644 index 0000000..a083b14 --- /dev/null +++ b/Resources/Info.plist @@ -0,0 +1,122 @@ + + + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleHelpBookFolder + OnlineHelp + CFBundleHelpBookName + PDP-8/E Simulator Help + CFBundleIconFile + pdp8e + CFBundleIdentifier + de.bernhard-baehr.pdp8e.simulator + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + APPL + CFBundleSignature + PDP8 + CFBundleVersion + 2.0.2 + CFBundleShortVersionString + 2.0.2 + LSMinimumSystemVersion + 10.4.9 + LSRequiresNativeExecution + YES + NSMainNibFile + MainMenu + NSPrincipalClass + NSApplication + CFBundleDocumentTypes + + + CFBundleTypeExtensions + + pdp8Plugin + + CFBundleTypeIconFile + plugin.icns + CFBundleTypeName + PDP-8/E Simulator Plugin + CFBundleTypeRole + None + + + CFBundleTypeExtensions + + BIN + bin + BN + bn + RIM + rim + PT + pt + PA + pa + PAL + pal + + CFBundleTypeOSTypes + + PNCH + + CFBundleTypeIconFile + papertape.icns + CFBundleTypeName + PDP-8/E Paper Tape + CFBundleTypeRole + None + + + CFBundleTypeExtensions + + rk8e + RK8E + rk05 + RK05 + decpack + DECPACK + + CFBundleTypeOSTypes + + RK8E + + CFBundleTypeIconFile + decpack.icns + CFBundleTypeName + PDP-8/E DECpack Disk Cartridge + CFBundleTypeRole + None + + + + diff --git a/Resources/alignMemoryArrow.tiff b/Resources/alignMemoryArrow.tiff new file mode 100644 index 0000000..4d197a5 Binary files /dev/null and b/Resources/alignMemoryArrow.tiff differ diff --git a/Resources/assembler.plist b/Resources/assembler.plist new file mode 100644 index 0000000..63c79bb --- /dev/null +++ b/Resources/assembler.plist @@ -0,0 +1,1005 @@ + + + + + + ACS + + 07403 + isOPR3b + + ADCL + + 06530 + isIOT + + ADLE + + 06536 + isIOT + + ADLM + + 06531 + isIOT + + ADRB + + 06533 + isIOT + + ADRS + + 06537 + isIOT + + ADSE + + 06535 + isIOT + + ADSK + + 06534 + isIOT + + ADST + + 06532 + isIOT + + AND + + 00000 + isMRI + needsOperand + + ASR + + 07415 + isOPR3a + isOPR3b + needsOperand + + BSW + + 07002 + isOPR1 + + CAF + + 06007 + isIOT + + CAM + + 07621 + isOPR3a + isOPR3b + + CCAR + + 06704 + isIOT + + CDF + + 06201 + isIOT + needsOperand + + CDI + + 06203 + isIOT + needsOperand + + CEP + + 06106 + isIOT + + CIA + + 07041 + isOPR1 + + CIF + + 06202 + isIOT + needsOperand + + CINT + + 06204 + isIOT + + CLA + + 07200 + isOPR1 + isOPR2 + isOPR3a + isOPR3b + + CLCF + + 06136 + isIOT + + CLDI + + 06132 + isIOT + + CLEI + + 06131 + isIOT + + CLF + + 06725 + isIOT + + CLIE + + 06135 + isIOT + + CLL + + 07100 + isOPR1 + + CLT + + 06712 + isIOT + + CMA + + 07040 + isOPR1 + + CML + + 07020 + isOPR1 + + CMP + + 06104 + isIOT + + CUF + + 06264 + isIOT + + CWCR + + 06702 + isIOT + + DAD + + 07443 + isOPR3b + needsOperand + + DCA + + 03000 + isMRI + needsOperand + + DCLR + + 06742 + isIOT + + DCM + + 07575 + isOPR3b + + DDZ + + 07665 + isOPR3b + needsOperand + + DLAG + + 06743 + isIOT + + DLCA + + 06744 + isIOT + + DLD + + 07663 + isOPR3b + needsOperand + + DLDC + + 06746 + isIOT + + DMAN + + 06747 + isIOT + + DPBELL + + 06057 + isIOT + + DPCL + + 06056 + isIOT + + DPGO + + 06051 + isIOT + + DPI + + 06100 + isIOT + + DPIC + + 07573 + isOPR3b + + DPLA + + 06050 + isIOT + + DPMB + + 06053 + isIOT + + DPMD + + 06054 + isIOT + + DPSM + + 06052 + isIOT + + DPSZ + + 07451 + isOPR3b + + DRST + + 06745 + isIOT + + DSKP + + 06741 + isIOT + + DST + + 07445 + isOPR3b + needsOperand + + DTCA + + 06762 + isIOT + + DTLA + + 06766 + isIOT + + DTLB + + 06774 + isIOT + + DTRA + + 06761 + isIOT + + DTRB + + 06772 + isIOT + + DTSF + + 06771 + isIOT + + DTXA + + 06764 + isIOT + + DVI + + 07407 + isOPR3a + isOPR3b + needsOperand + + EPI + + 06103 + isIOT + + FPCOM + + 06553 + isIOT + + FPEP + + 06567 + isIOT + + FPHLT + + 06554 + isIOT + + FPICL + + 06552 + isIOT + + FPINT + + 06551 + isIOT + + FPIST + + 06557 + isIOT + + FPRST + + 06556 + isIOT + + FPST + + 06555 + isIOT + + GLK + + 07204 + isOPR1 + + GTF + + 06004 + isIOT + + HLT + + 07402 + isOPR2 + + I + + 00400 + isIndirect + + IAC + + 07001 + isOPR1 + + IOF + + 06002 + isIOT + + ION + + 06001 + isIOT + + ISZ + + 02000 + isMRI + needsOperand + + JMP + + 05000 + isMRI + needsOperand + + JMS + + 04000 + isMRI + needsOperand + + KCC + + 06032 + isIOT + + KCF + + 06030 + isIOT + + KIE + + 06035 + isIOT + + KRB + + 06036 + isIOT + + KRS + + 06034 + isIOT + + KSF + + 06031 + isIOT + + LAS + + 07604 + isOPR2 + + LCAR + + 06703 + isIOT + + LCMR + + 06705 + isIOT + + LDBR + + 06707 + isIOT + + LFGR + + 06706 + isIOT + + LSR + + 07417 + isOPR3a + isOPR3b + needsOperand + + LWCR + + 06701 + isIOT + + MQA + + 07501 + isOPR3a + isOPR3b + + MQL + + 07421 + isOPR3a + isOPR3b + + MUY + + 07405 + isOPR3a + isOPR3b + needsOperand + + NMI + + 07411 + isOPR3a + isOPR3b + + NOP + + 07000 + isOPR1 + isOPR2 + isOPR3a + isOPR3b + + OSR + + 07404 + isOPR2 + + PCE + + 06020 + isIOT + + PCF + + 06022 + isIOT + + PCIE + + 06667 + isIOT + + PCLF + + 06662 + isIOT + + PLCE + + 06650 + isIOT + + PLCF + + 06652 + isIOT + + PLLR + + 06654 + isIOT + + PLPD + + 06655 + isIOT + + PLPU + + 06653 + isIOT + + PLS + + 06026 + isIOT + + PLSE + + 06657 + isIOT + + PLSF + + 06651 + isIOT + + PPC + + 06024 + isIOT + + PSF + + 06021 + isIOT + + PSIE + + 06665 + isIOT + + PSKE + + 06663 + isIOT + + PSKF + + 06661 + isIOT + + PSTB + + 06664 + isIOT + + RAL + + 07004 + isOPR1 + + RAR + + 07010 + isOPR1 + + RCAR + + 06713 + isIOT + + RCC + + 06016 + isIOT + + RCMR + + 06715 + isIOT + + RCNI + + 06637 + isIOT + + RCNO + + 06635 + isIOT + + RCRA + + 06632 + isIOT + + RCRB + + 06634 + isIOT + + RCRC + + 06636 + isIOT + + RCRD + + 06674 + isIOT + + RCSD + + 06671 + isIOT + + RCSE + + 06672 + isIOT + + RCSF + + 06631 + isIOT + + RCSI + + 06675 + isIOT + + RCTF + + 06676 + isIOT + + RDBR + + 06717 + isIOT + + RDF + + 06214 + isIOT + + RFC + + 06014 + isIOT + + RFSR + + 06716 + isIOT + + RIB + + 06234 + isIOT + + RIF + + 06224 + isIOT + + RMF + + 06244 + isIOT + + RMSR + + 06714 + isIOT + + RPE + + 06010 + isIOT + + RRB + + 06012 + isIOT + + RSF + + 06011 + isIOT + + RTF + + 06005 + isIOT + + RTL + + 07006 + isOPR1 + + RTR + + 07012 + isOPR1 + + RWCR + + 06711 + isIOT + + SAM + + 07457 + isOPR3b + + SCA + + 07441 + isOPR3b + + SCL + + 07403 + isOPR3a + needsOperand + + SGT + + 06006 + isIOT + + SHL + + 07413 + isOPR3a + isOPR3b + needsOperand + + SINT + + 06254 + isIOT + + SKCB + + 06722 + isIOT + + SKEF + + 06721 + isIOT + + SKJD + + 06723 + isIOT + + SKON + + 06000 + isIOT + + SKP + + 07410 + isOPR2 + + SKTR + + 06724 + isIOT + + SMA + + 07500 + isOPR2 + + SMP + + 06101 + isIOT + + SMPCMP + + 06105 + isIOT + + SNA + + 07450 + isOPR2 + + SNL + + 07420 + isOPR2 + + SPA + + 07510 + isOPR2 + + SPL + + 06102 + isIOT + + SPO + + 06107 + isIOT + + SRQ + + 06003 + isIOT + + STA + + 07240 + isOPR1 + + STL + + 07120 + isOPR1 + + SUF + + 06274 + isIOT + + SWAB + + 07431 + isOPR3a + isOPR3b + + SWBA + + 07447 + isOPR3a + isOPR3b + + SWP + + 07521 + isOPR3a + isOPR3b + + SZA + + 07440 + isOPR2 + + SZL + + 07430 + isOPR2 + + TAD + + 01000 + isMRI + needsOperand + + TCF + + 06042 + isIOT + + TFL + + 06040 + isIOT + + TLS + + 06046 + isIOT + + TPC + + 06044 + isIOT + + TSF + + 06041 + isIOT + + TSK + + 06045 + isIOT + + + diff --git a/Resources/bb.tiff b/Resources/bb.tiff new file mode 100644 index 0000000..c9b2e90 Binary files /dev/null and b/Resources/bb.tiff differ diff --git a/Resources/binLoader.rim b/Resources/binLoader.rim new file mode 100644 index 0000000..ab67d37 Binary files /dev/null and b/Resources/binLoader.rim differ diff --git a/Resources/bootstrapToolbarIcon.tiff b/Resources/bootstrapToolbarIcon.tiff new file mode 100644 index 0000000..e2761aa Binary files /dev/null and b/Resources/bootstrapToolbarIcon.tiff differ diff --git a/Resources/bracket.png b/Resources/bracket.png new file mode 100644 index 0000000..8d576b6 Binary files /dev/null and b/Resources/bracket.png differ diff --git a/Resources/breakOpcode.tiff b/Resources/breakOpcode.tiff new file mode 100644 index 0000000..ccb6100 Binary files /dev/null and b/Resources/breakOpcode.tiff differ diff --git a/Resources/breakOpcodeS.tiff b/Resources/breakOpcodeS.tiff new file mode 100644 index 0000000..02e9c40 Binary files /dev/null and b/Resources/breakOpcodeS.tiff differ diff --git a/Resources/breakOpcodeU.tiff b/Resources/breakOpcodeU.tiff new file mode 100644 index 0000000..971cc54 Binary files /dev/null and b/Resources/breakOpcodeU.tiff differ diff --git a/Resources/breakpoint.tiff b/Resources/breakpoint.tiff new file mode 100644 index 0000000..fc223dc Binary files /dev/null and b/Resources/breakpoint.tiff differ diff --git a/Resources/breakpointsToolbarIcon.tiff b/Resources/breakpointsToolbarIcon.tiff new file mode 100644 index 0000000..f834caf Binary files /dev/null and b/Resources/breakpointsToolbarIcon.tiff differ diff --git a/Resources/decpack.icns b/Resources/decpack.icns new file mode 100644 index 0000000..64b68ce Binary files /dev/null and b/Resources/decpack.icns differ diff --git a/Resources/goToolbarIcon.tiff b/Resources/goToolbarIcon.tiff new file mode 100644 index 0000000..f9e815f Binary files /dev/null and b/Resources/goToolbarIcon.tiff differ diff --git a/Resources/highspeedRIM.bin b/Resources/highspeedRIM.bin new file mode 100644 index 0000000..b16a62f Binary files /dev/null and b/Resources/highspeedRIM.bin differ diff --git a/Resources/interruptArrow.tiff b/Resources/interruptArrow.tiff new file mode 100644 index 0000000..a660098 Binary files /dev/null and b/Resources/interruptArrow.tiff differ diff --git a/Resources/lowspeedRIM.bin b/Resources/lowspeedRIM.bin new file mode 100644 index 0000000..a03d147 Binary files /dev/null and b/Resources/lowspeedRIM.bin differ diff --git a/Resources/memoryInspectorToolbarIcon.tiff b/Resources/memoryInspectorToolbarIcon.tiff new file mode 100644 index 0000000..ad95ef5 Binary files /dev/null and b/Resources/memoryInspectorToolbarIcon.tiff differ diff --git a/Resources/papertape.icns b/Resources/papertape.icns new file mode 100644 index 0000000..e16b9d5 Binary files /dev/null and b/Resources/papertape.icns differ diff --git a/Resources/pcArrowBlue.tiff b/Resources/pcArrowBlue.tiff new file mode 100644 index 0000000..9e787e1 Binary files /dev/null and b/Resources/pcArrowBlue.tiff differ diff --git a/Resources/pcArrowGraphite.tiff b/Resources/pcArrowGraphite.tiff new file mode 100644 index 0000000..df48583 Binary files /dev/null and b/Resources/pcArrowGraphite.tiff differ diff --git a/Resources/pdp8e.icns b/Resources/pdp8e.icns new file mode 100644 index 0000000..b63c494 Binary files /dev/null and b/Resources/pdp8e.icns differ diff --git a/Resources/plugin.icns b/Resources/plugin.icns new file mode 100644 index 0000000..afa0149 Binary files /dev/null and b/Resources/plugin.icns differ diff --git a/Resources/resetToolbarIcon.tiff b/Resources/resetToolbarIcon.tiff new file mode 100644 index 0000000..dd8eec8 Binary files /dev/null and b/Resources/resetToolbarIcon.tiff differ diff --git a/Resources/rk8eBootcode.bin b/Resources/rk8eBootcode.bin new file mode 100644 index 0000000..10d0ebb --- /dev/null +++ b/Resources/rk8eBootcode.bin @@ -0,0 +1 @@ +@07#7!( \ No newline at end of file diff --git a/Resources/skipArrow.tiff b/Resources/skipArrow.tiff new file mode 100644 index 0000000..cc37f78 Binary files /dev/null and b/Resources/skipArrow.tiff differ diff --git a/Resources/stepToolbarIcon.tiff b/Resources/stepToolbarIcon.tiff new file mode 100644 index 0000000..460aeed Binary files /dev/null and b/Resources/stepToolbarIcon.tiff differ diff --git a/Resources/stopToolbarIcon.tiff b/Resources/stopToolbarIcon.tiff new file mode 100644 index 0000000..a65c6df Binary files /dev/null and b/Resources/stopToolbarIcon.tiff differ diff --git a/Resources/traceToolbarIcon.tiff b/Resources/traceToolbarIcon.tiff new file mode 100644 index 0000000..58b9893 Binary files /dev/null and b/Resources/traceToolbarIcon.tiff differ diff --git a/TSC8/English.lproj/InfoPlist.strings b/TSC8/English.lproj/InfoPlist.strings new file mode 100644 index 0000000..9ed0670 --- /dev/null +++ b/TSC8/English.lproj/InfoPlist.strings @@ -0,0 +1,28 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InfoPlist.strings - Localized strings for Info.plist + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +CFBundleName = "TSC8-75 Board"; +CFBundleGetInfoString = "TSC8-75 Board 2.0.2, Copyright © 1994-2015 Bernhard Baehr"; +NSHumanReadableCopyright = "Copyright © 1994-2015 Bernhard Baehr"; +CFBundleHelpBookName = "TSC8-75 Board Help"; \ No newline at end of file diff --git a/TSC8/English.lproj/TSC8.nib/designable.nib b/TSC8/English.lproj/TSC8.nib/designable.nib new file mode 100644 index 0000000..dbd121e --- /dev/null +++ b/TSC8/English.lproj/TSC8.nib/designable.nib @@ -0,0 +1,919 @@ + + + + 1040 + 12C60 + 851 + 1187.34 + 625.00 + + com.apple.InterfaceBuilder.CocoaPlugin + 851 + + + YES + + + + YES + com.apple.InterfaceBuilder.CocoaPlugin + + + PluginDependencyRecalculationVersion + + + + YES + + TSC8 + + + FirstResponder + + + NSApplication + + + 263 + 2 + {{196, 396}, {353, 113}} + 1618478080 + TSC8-75 Board + KeepInMenuWindow + + + {1.7976931348623157e+308, 1.7976931348623157e+308} + + + 256 + + YES + + + 268 + {{131, 20}, {205, 42}} + + YES + + 67108864 + 4325376 + The ESME feature is available with TSC8-75 boards with serial number 699 and higher. It enables IOT 6365. + + LucidaGrande + 11 + 3088 + + + + 6 + System + controlColor + + 3 + MC42NjY2NjY2NjY3AA + + + + 6 + System + controlTextColor + + 3 + MAA + + + + NO + + + + 268 + {{128, 69}, {210, 28}} + + YES + + 67108864 + 134348800 + ESME is currently disabled + + + -930725888 + 1 + + ESME is currently enabled + + 400 + 75 + + NO + + + + 256 + {{26, 74}, {70, 19}} + + YES + NO + 1 + 1 + + YES + + -1805647807 + 205521920 + 7777 + + + 30.2001953125 + + 67108864 + 67108864 + ERTB + + + + + + {70, 19} + {1, 8} + 67633152 + NSActionCell + + -1805647807 + 205521920 + 7777 + + 30.2001953125 + + 67108864 + 67108864 + ERTB + + + + -1 + -1 + + + 3 + MQA + + + LucidaGrande + 13 + 1040 + + + + + 12 + {{112, 20}, {5, 73}} + + {0, 0} + + 67108864 + 0 + Box + + + 6 + System + textBackgroundColor + + + + 3 + MCAwLjgwMDAwMDAxMTkAA + + + 3 + 2 + 0 + NO + + + + 256 + {{20, 47}, {76, 19}} + + YES + NO + 1 + 1 + + YES + + -1805647807 + 205521920 + 7777 + + + 36 + + 67108864 + 67108864 + ERIOT + + + + + + {76, 19} + {0, 8} + 67633152 + NSActionCell + + 342884416 + 205521920 + + + 36 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + + 256 + {{24, 20}, {51, 19}} + + YES + NO + 1 + 1 + + YES + + 341835841 + 205521920 + 1 + + + 1 + 32 + + 67108864 + 67108864 + ECDF + + + + + + {51, 19} + {1, 8} + 336068608 + NSActionCell + + 342884416 + 205521920 + + + 32 + + 67108864 + 67108864 + Field: + + + + -1 + -1 + + + + + + {353, 113} + + + {{0, 0}, {1680, 1028}} + {1.7976931348623157e+308, 1.7976931348623157e+308} + TSC8Window + NO + YES + + + + + YES + + + esmeButton + + + + 38 + + + + window + + + + 39 + + + + esmeEnabledClicked: + + + + 40 + + + + ecdfRegister + + + + 156 + + + + eriotRegister + + + + 157 + + + + ertbRegister + + + + 158 + + + + nextKeyView + + + + 164 + + + + nextKeyView + + + + 165 + + + + nextKeyView + + + + 166 + + + + representedObject + + + + 173 + + + + initialFirstResponder + + + + 174 + + + + nextKeyView + + + + 175 + + + + + YES + + 0 + + YES + + + + + + -2 + + + File's Owner + + + -1 + + + First Responder + + + -3 + + + Application + + + 1 + + + YES + + + + + + 2 + + + YES + + + + + + + + + + + 18 + + + YES + + + + + + 19 + + + + + 31 + + + YES + + + + + + 32 + + + + + 34 + + + + + 59 + + + YES + + + + + + + 60 + + + + + 96 + + + + + 133 + + + YES + + + + + + + 134 + + + + + 135 + + + + + 142 + + + YES + + + + + + + 143 + + + + + 144 + + + + + + + YES + + YES + -3.IBPluginDependency + 1.IBEditorWindowLastContentRect + 1.IBPluginDependency + 1.IBWindowTemplateEditedContentRect + 1.NSWindowTemplate.visibleAtLaunch + 1.WindowOrigin + 1.editorWindowContentRectSynchronizationRect + 133.IBAttributePlaceholdersKey + 133.IBPluginDependency + 133.ImportedFromIB2 + 134.CustomClassName + 134.IBAttributePlaceholdersKey + 134.IBPluginDependency + 134.ImportedFromIB2 + 135.IBPluginDependency + 142.IBAttributePlaceholdersKey + 142.IBPluginDependency + 142.ImportedFromIB2 + 143.CustomClassName + 143.IBAttributePlaceholdersKey + 143.IBPluginDependency + 143.ImportedFromIB2 + 144.IBPluginDependency + 18.IBPluginDependency + 18.IBViewBoundsToFrameTransform + 19.IBPluginDependency + 2.IBPluginDependency + 31.IBPluginDependency + 32.IBPluginDependency + 34.IBPluginDependency + 34.IBViewIntegration.shadowBlurRadius + 34.IBViewIntegration.shadowColor + 34.IBViewIntegration.shadowOffsetHeight + 34.IBViewIntegration.shadowOffsetWidth + 59.IBAttributePlaceholdersKey + 59.IBPluginDependency + 59.ImportedFromIB2 + 59.showNotes + 60.CustomClassName + 60.IBAttributePlaceholdersKey + 60.IBPluginDependency + 60.ImportedFromIB2 + 96.CustomClassName + 96.IBAttributePlaceholdersKey + 96.IBPluginDependency + 96.ImportedFromIB2 + + + YES + com.apple.InterfaceBuilder.CocoaPlugin + {{243, 445}, {353, 113}} + com.apple.InterfaceBuilder.CocoaPlugin + {{243, 445}, {353, 113}} + + {196, 240} + {{357, 418}, {480, 270}} + + YES + + + YES + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + The ERIOT register holds the opcode of the last JMS, JMP, IOT, HLT or OSR instruction performed in user mode. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + + YES + + + YES + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + The ECDF flag ist set when a CDF opcode (62x1) is loaded into ERIOT. It is cleared when any other opcode is loaded into ERIOT or when a ECDF or a skipping ESME instruction is executed. + + + com.apple.InterfaceBuilder.CocoaPlugin + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + P4AAAL+AAABDAgAAwoQAAA + + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + com.apple.InterfaceBuilder.CocoaPlugin + + + + + + YES + + + YES + + + com.apple.InterfaceBuilder.CocoaPlugin + + + RegisterFormCell + + ToolTip + + ToolTip + + The ERTB register holds the address of the last JMS or JMP instruction performed in user mode. + + + com.apple.InterfaceBuilder.CocoaPlugin + + RegisterFormCell + + ToolTip + + ToolTip + + MQ (Multiplier Quotient) is used in conjunction with AC to perform direct multiplication and divison. The PDP-8/E has the MQ register even if it has no EAE; earlier machines (PDP-8, PDP-8/S, PDP-8/I) have it only in conjunction with an EAE. + + + com.apple.InterfaceBuilder.CocoaPlugin + + + + + YES + + + YES + + + + + YES + + + YES + + + + 175 + + + + YES + + KeepInMenuWindow + NSWindow + + YES + + YES + orderBackFromDefaults: + orderFrontFromDefaults: + + + YES + id + id + + + + YES + + YES + orderBackFromDefaults: + orderFrontFromDefaults: + + + YES + + orderBackFromDefaults: + id + + + orderFrontFromDefaults: + id + + + + + IBProjectSource + Utilities/KeepInMenuWindow.h + + + + NSControl + + IBProjectSource + Categories/NSControl+FileDrop.h + + + + PDP8Plugin + NSObject + + IBProjectSource + Plugins/PluginAPI.h + + + + RegisterFormCell + NSFormCell + + registerOwner + id + + + registerOwner + + registerOwner + id + + + + IBProjectSource + Utilities/RegisterFormCell.h + + + + TSC8 + PDP8Plugin + + esmeEnabledClicked: + id + + + esmeEnabledClicked: + + esmeEnabledClicked: + id + + + + YES + + YES + ecdfRegister + eriotRegister + ertbRegister + esmeButton + window + + + YES + RegisterFormCell + RegisterFormCell + RegisterFormCell + NSButton + KeepInMenuWindow + + + + YES + + YES + ecdfRegister + eriotRegister + ertbRegister + esmeButton + window + + + YES + + ecdfRegister + RegisterFormCell + + + eriotRegister + RegisterFormCell + + + ertbRegister + RegisterFormCell + + + esmeButton + NSButton + + + window + KeepInMenuWindow + + + + + IBProjectSource + TSC8/TSC8.h + + + + + YES + + KeepInMenuWindow + NSWindow + + IBFrameworkSource + PluginFramework.framework/Headers/KeepInMenuWindow.h + + + + NSControl + + IBFrameworkSource + PluginFramework.framework/Headers/NSControl+FileDrop.h + + + + PDP8Plugin + NSObject + + IBFrameworkSource + PluginFramework.framework/Headers/PluginAPI.h + + + + RegisterFormCell + NSFormCell + + IBFrameworkSource + PluginFramework.framework/Headers/RegisterFormCell.h + + + + + 0 + IBCocoaFramework + + com.apple.InterfaceBuilder.CocoaPlugin.macosx + + + + com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3 + + + YES + ../../pdp8e-simulator.xcodeproj + 3 + + diff --git a/TSC8/English.lproj/TSC8.nib/keyedobjects.nib b/TSC8/English.lproj/TSC8.nib/keyedobjects.nib new file mode 100644 index 0000000..354e28b Binary files /dev/null and b/TSC8/English.lproj/TSC8.nib/keyedobjects.nib differ diff --git a/TSC8/English.lproj/TSC8OnlineHelp/index.html b/TSC8/English.lproj/TSC8OnlineHelp/index.html new file mode 100644 index 0000000..1e04ee3 --- /dev/null +++ b/TSC8/English.lproj/TSC8OnlineHelp/index.html @@ -0,0 +1,211 @@ + + + + + + TSC8-75 Board Help + + + + + + + +

    TSC8-75 Board for ETOS

    + +

    +The TSC8-75 board is a proprietary piece of hardware for the PDP-8/E required +to run ETOS, +EduComp’s Timeshared Operating System +(later called Extended Timeshared Operating System when EduComp was renamed to QuoData). +

    + +

    +The following description of the functioning of the TSC8-75 board was derived from the +TSC8.SV hardware diagnostic program (available on the ETOS disk images from ftp://ftp.pdp8.net/images/etos; +to convert them to the image format required for the PDP-8/E Simulator, use these download links: +etosv5b-demo.rk05, +etosv5b-pl5-config.rk05, +etosv5b-pl5-dist.rk05), +from the ETOS manuals +(testing the ETOS board is described in the System Manager Guide chapter 2.11, pp. 2-41 - 2-48) +and the ETOS white paper. +

    + +

    +The TSC8-75 provides the following registers: +

    + +
      +
    • +An enable flag. When it is cleared, the PDP-8/E works as usual. +When it is set, the TSC8-75 is operational. +
    • + +
    • +An interrupt flag. When the TSC8-75 and interrupts are enabled and this flag is set, +an interrupt occurs. +
    • + +
    • +A 12-bit register holding the opcode of the last JMS, JMP, IOT, HLT or OSR +instruction performed by the PDP-8/E running in user mode. We refer to it with +the name ERIOT register (the original name is unknown). +
    • + +
    • +A 12-bit register holding the address of the last JMS or JMP instruction performed +by the PDP-8/E running in user mode. We call it the ERTB register +(the original name is unknown). +
    • + +
    • +A 1-bit register that is set whenever a CDF opcode (62x1) is loaded into the +ERIOT register. It is cleared when any other opcode is loaded into the ERIOT +register or when a ECDF or skipping ESME instruction is performed. We call it +the ECDF flag (the original name is unknown). + +
    • +
    + +

    +Every TSC8-75 provides the following IOT instructions (at I/O address 36). +The mnemonics were retrieved from the error messages of the TSC8.SV diagnostics. +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Mnemonic
    Symbol
    Octal
    Code

    Description
    ETDS6360Disable the TSC8-75 by clearing the enable and interrupt flag.
    ESKP6361Skip the next instruction when the interrupt flag of the TSC8-75 is set.
    ECTF6362Clear the interrupt flag of the TSC8-75.
    ECDF6363Move ERIOT(6-8) to AC(9-11) by performing a logical OR (when ERIOT holds a CIF, + CDF or CDI, this is the field number of the instruction). When the ECDF flag is set + (then ERIOT holds a CDF instruction (62x1)), additionally the next instruction is + skipped. The ECDF flag is cleared. +
    ERTB6364Clear AC, then move the ERTB register to AC.
    ERIOT6366Clear AC, then move the ERIOT register to AC.
    ETEN6367Enable the TSC8-75 by setting the enable flag.
    + +

    +TSC8-75 boards starting with serial number 699 additionally provide the so called +ESME feature (see ETOS System Manager Guide chapter 3.5, pp. 3-10 - 3-11). +This feature enables the software to skip the emulation of unnecessary CDF instructions +when the data field of the CDF is the current field. +The TSC8.SV diagnostics is supposed to test the ESME feature (when SR9=1), +but it gives no indicator for what the feature actually does. +Inspecting the interrupt service routine of ETOS shows that the ESME feature is +implemented by the IOT 6365 (this is the first instruction in the interrupt service +routine), refered by the mnemonic ESME (the original mnemonic is unknown): +

    + + + + + + + + + + + + +
    Mnemonic
    Symbol
    Octal
    Code

    Description
    ESME6365Serial number of TSC8-75 board before 699: NOP
    + Serial number of TSC8-75 board 699 or higher: + Skip the next instruction when the ECDF flag is set (then the ERIOT register + contains a CDF opcode (62x1)) and the target data field of this CDF in + ERIOT(6-8) is equal to SF(4-6), the data field that was active before the + last interrupt. When a skip occurs, the ECDF flag is cleared, otherwise not. +
    + +

    +When a TSC8-75 board is installed in a PDP-8/E, the following instructions behave not +as usual when executed while the processor is running in user mode: +

    + +
      +
    • +HLT (7402), OSR (7404) and microprogrammed combinations with HLT and OSR: +Additional to raising a user mode interrupt, the current OPR opcode is moved +to the ERIOT register and the ECDF flag is cleared. +
    • + +
    • +IOT (6xxx): Additional to raising a user mode interrupt, the current IOT opcode is moved +to the ERIOT register. When the IOT is a CDF instruction (62x1), the ECDF flag is set, +otherwise it is cleared. +
    • + +
    • +JMP (5xxx): The current JMP opcode is moved to the ERIOT register, the ECDF flag is +cleared. The address of the JMP instruction is loaded into the ERTB register and +the TSC8-75 I/O flag is raised. Then the JMP is performed as usual (including the +setting of IF, UF and clearing the interrupt inhibit flag). +
    • + +
    • +JMS (4xxx): The current JMS opcode is moved to the ERIOT register, the ECDF flag +is cleared. The address of the JMS instruction is loaded into the ERTB register and +the TSC8-75 I/O flag is raised. When the TSC8-75 is enabled, the target addess of the +JMS is loaded into PC, but nothing else (loading of IF, UF, clearing the interrupt +inhibit flag, storing of the return address in the first word of the subroutine) +happens. When the TSC8-75 is disabled, the JMS is performed as usual. +
    • +
    + + + diff --git a/TSC8/English.lproj/TSC8OnlineHelp/pdp8e.png b/TSC8/English.lproj/TSC8OnlineHelp/pdp8e.png new file mode 100644 index 0000000..2c0c485 Binary files /dev/null and b/TSC8/English.lproj/TSC8OnlineHelp/pdp8e.png differ diff --git a/TSC8/English.lproj/TSC8OnlineHelp/styles.css b/TSC8/English.lproj/TSC8OnlineHelp/styles.css new file mode 100644 index 0000000..c18751d --- /dev/null +++ b/TSC8/English.lproj/TSC8OnlineHelp/styles.css @@ -0,0 +1,239 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * styles.css - Online help - Style sheet + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + +p { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +p.small { + font-size: 8pt; +} + +a { + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +a:hover { + text-decoration: underline +} + +ul { + margin-left: 1.25em; padding-left: 0em; +} + +li { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + text-decoration: none +} + +#mainbox { + background-color: #fff; + margin-top: 30px; + margin-right: 26px; + margin-left: 18px; + position: absolute; + top: 10px +} + +#taskbox { + background-color: #eee; + list-style-type: decimal; + list-style-position: outside; + margin-top: 12px; + margin-bottom: 12px; + border: solid 1px #444 +} + +h1 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 6pt; +} + +h2 { + font-size: 12pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 8pt; +} + +h3 { + font-size: 10pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 5pt; +} + +h4 { + font-size: 9pt; + font-family: "Lucida Grande", Arial, "Sans Serif"; + padding-top: 4pt; +} + +/* index.html */ + +table.index { + padding-top: 20px; + width: 100%; +} + +td.banner { + padding: 20px; +} + +td.toc { + padding-top: 10px; + padding-bottom: 10px; + padding-left: 20px; + padding-right:20px; + border-left: 1px solid darkgray; +} + +p.toc { + line-height: 40px; +} + +/* other pages */ + +table { + border-collapse: separate; + border-spacing: 0px; +} + +th { + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + font-style: bold; + border-bottom: 1px solid gray; + padding-left: 10px; + padding-right: 10px; +} + +th.left { + text-align: left; +} + +td { + text-align: center; + vertical-align: top; + font-family: "Lucida Grande", Arial, "Sans Serif"; + font-size: 9pt; + padding-left: 10px; + padding-right: 10px; +} + +td.left { + text-align: left; +} + +td.right { + text-align: right; +} + +td.br { + border-right: 1px solid gray; +} + +td.bb { + border-bottom: 1px solid lightgray; +} + +td.bb_left { + text-align: left; + border-bottom: 1px solid lightgray; +} + +td.bbr { + border-bottom: 1px solid lightgray; + border-right: 1px solid gray; +} + +td.opcode { + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_right { + text-align: right; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_left { + text-align: left; + vertical-align: middle; + width: 40px; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlb { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-left: 1px solid black; + border-bottom: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border-top: 1px solid black; + border-bottom: 1px solid black; + border-right: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} + +td.opcode_tlbr { + vertical-align: middle; + background: lightgray; + width: 40px; + height: 40px; + border: 1px solid black; + padding-left: 0px; + padding-right: 0px; +} diff --git a/TSC8/English.lproj/io-info.plist b/TSC8/English.lproj/io-info.plist new file mode 100644 index 0000000..eb15882 --- /dev/null +++ b/TSC8/English.lproj/io-info.plist @@ -0,0 +1,47 @@ + + + + + + ioflags + + TSC8-75 + + ioaddresses + + 36 + + iots + + ETDS + ESKP + ECTF + ECDF + ERTB + ESME + ERIOT + ETEN + + + diff --git a/TSC8/Info.plist b/TSC8/Info.plist new file mode 100644 index 0000000..6071068 --- /dev/null +++ b/TSC8/Info.plist @@ -0,0 +1,32 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleExecutable + ${EXECUTABLE_NAME} + CFBundleHelpBookFolder + TSC8OnlineHelp + CFBundleHelpBookName + TSC8-75 Board Help + CFBundleIconFile + + CFBundleIdentifier + de.bernhard-baehr.pdp8e.TSC8 + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + ${PRODUCT_NAME} + CFBundlePackageType + BNDL + CFBundleSignature + ???? + CFBundleVersion + 2.0.2 + CFBundleShortVersionString + 2.0.2 + NSPrincipalClass + TSC8 + + diff --git a/TSC8/TSC8.h b/TSC8/TSC8.h new file mode 100644 index 0000000..7ef5a0f --- /dev/null +++ b/TSC8/TSC8.h @@ -0,0 +1,42 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * TSC8.h - TSC8-75 Board for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class KeepInMenuWindow, RegisterFormCell; + + +@interface TSC8 : PDP8Plugin +{ +@private + IBOutlet KeepInMenuWindow *window; + IBOutlet RegisterFormCell *ertbRegister; + IBOutlet RegisterFormCell *eriotRegister; + IBOutlet RegisterFormCell *ecdfRegister; + IBOutlet NSButton *esmeButton; +@public + // no registers here, the TSC8-75 registers are in pdp8->_tsc8 +} + +- (IBAction) esmeEnabledClicked:(id)sender; + +@end diff --git a/TSC8/TSC8.m b/TSC8/TSC8.m new file mode 100644 index 0000000..d6ca456 --- /dev/null +++ b/TSC8/TSC8.m @@ -0,0 +1,293 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * TSC8.m - TSC8-75 Board for the PDP-8/E Simulator + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PluginFramework/PluginAPI.h" +#import "PluginFramework/PDP8.h" +#import "PluginFramework/KeepInMenuWindow.h" +#import "PluginFramework/RegisterFormCell.h" +#import "PluginFramework/Utilities.h" + +#import "TSC8.h" +#import "TSC8iot.h" + + +#define CODER_KEY_TSC8_ERTB @"tsc8ERTB" +#define CODER_KEY_TSC8_ERIOT @"tsc8ERIOT" +#define CODER_KEY_TSC8_ECDF @"tsc8ECDF" +#define CODER_KEY_TSC8_ESME_ENABLED @"tsc8ESME" +#define CODER_KEY_TSC8_IOFLAG @"tsc8IOFLAG" +#define CODER_KEY_TSC8_IOMASK @"tsc8IOMASK" + +#define ERTB_CHANGED_NOTIFICATION @"tsc8ERTBChangedNotification" +#define ERIOT_CHANGED_NOTIFICATION @"tsc8ERIOTChangedNotification" +#define ECDF_CHANGED_NOTIFICATION @"tsc8ECDFChangedNotification" + + +@implementation TSC8 + + +API_VERSION + + +#pragma mark Register Access + + +- (unsigned short) getERTB +{ + return [pdp8 getTSC8ertb]; +} + + +- (void) setERTB:(ushort)ertb +{ + [pdp8 setTSC8ertb:ertb]; + [[NSNotificationCenter defaultCenter] postNotificationName:ERTB_CHANGED_NOTIFICATION object:self]; +} + + +- (unsigned short) getERIOT +{ + return [pdp8 getTSC8eriot]; +} + + +- (void) setERIOT:(ushort)eriot +{ + [pdp8 setTSC8eriot:eriot]; + [[NSNotificationCenter defaultCenter] postNotificationName:ERIOT_CHANGED_NOTIFICATION object:self]; +} + + +- (BOOL) getESMEenabled +{ + return [pdp8 getTSC8esmeEnabled]; +} + + +- (void) setESMEenabled:(BOOL)enabled +{ + [pdp8 setTSC8esmeEnabled:enabled]; + [esmeButton setIntValue:enabled]; +} + + +- (IBAction) esmeEnabledClicked:(id)sender +{ + [self setESMEenabled:[sender intValue]]; +} + + +- (unsigned short) getECDF +{ + return [pdp8 getTSC8ecdf]; +} + + +- (void) setECDF:(ushort)ecdf +{ + [pdp8 setTSC8ecdf:ecdf]; + [[NSNotificationCenter defaultCenter] postNotificationName:ECDF_CHANGED_NOTIFICATION object:self]; +} + + +#pragma mark Plugin Methods + + +- (NSArray *) iotsForAddress:(int)ioAddress +{ + return [NSArray arrayWithObjects: + [NSValue valueWithPointer:i6360], + [NSValue valueWithPointer:i6361], + [NSValue valueWithPointer:i6362], + [NSValue valueWithPointer:i6363], + [NSValue valueWithPointer:i6364], + [NSValue valueWithPointer:i6365], + [NSValue valueWithPointer:i6366], + [NSValue valueWithPointer:i6367], + nil]; +} + + +- (NSArray *) skiptestsForAddress:(int)ioAddress +{ + return [NSArray arrayWithObjects: + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6361], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6363], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:s6365], + [NSValue valueWithPointer:nil], + [NSValue valueWithPointer:nil], + nil]; + +} + + +- (void) setIOFlag:(unsigned long)flag forIOFlagName:(NSString *)name; +{ + [pdp8 setTSC8flag:flag]; +} + + +- (void) CAF:(int)ioAddress +{ + [pdp8 clearIOFlagBits:[pdp8 getTSC8flag]]; + [pdp8 clearInterruptMaskBits:[pdp8 getTSC8flag]]; + [pdp8 setTSC8ertb:0]; + [pdp8 setTSC8eriot:0]; + [pdp8 setTSC8ecdf:0]; +} + + +- (void) clearAllFlags:(int)ioAddress +{ + [pdp8 clearIOFlagBits:[pdp8 getTSC8flag]]; + [pdp8 clearInterruptMaskBits:[pdp8 getTSC8flag]]; + [self setERTB:0]; + [self setERIOT:0]; + [self setECDF:0]; +} + + +- (void) resetDevice +{ + [self clearAllFlags:0]; +} + + +#pragma mark Notifications + + +- (void) notifyGo:(NSNotification *)notification +{ + [ertbRegister setEnabled:NO]; + [eriotRegister setEnabled:NO]; + [ecdfRegister setEnabled:NO]; +} + + +- (void) notifyStep:(NSNotification *)notification +{ + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + [defaultCenter postNotificationName:ERTB_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:ERIOT_CHANGED_NOTIFICATION object:self]; + [defaultCenter postNotificationName:ECDF_CHANGED_NOTIFICATION object:self]; +} + + +- (void) notifyStop:(NSNotification *)notification +{ + [self notifyStep:notification]; + [ertbRegister setEnabled:YES]; + [eriotRegister setEnabled:YES]; + [ecdfRegister setEnabled:YES]; +} + + +#pragma mark Initialization + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + [self setERTB:[coder decodeIntForKey:CODER_KEY_TSC8_ERTB]]; + [self setERIOT:[coder decodeIntForKey:CODER_KEY_TSC8_ERIOT]]; + [self setECDF:[coder decodeIntForKey:CODER_KEY_TSC8_ECDF]]; + [self setESMEenabled:[coder decodeBoolForKey:CODER_KEY_TSC8_ESME_ENABLED]]; + unsigned long flag = [pdp8 getTSC8flag]; + [coder decodeBoolForKey:CODER_KEY_TSC8_IOFLAG] ? + [pdp8 setIOFlagBits:flag] : [pdp8 clearIOFlagBits:flag]; + [coder decodeBoolForKey:CODER_KEY_TSC8_IOMASK] ? + [pdp8 setInterruptMaskBits:flag] : [pdp8 clearInterruptMaskBits:flag]; + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + [coder encodeInt:[self getERTB] forKey:CODER_KEY_TSC8_ERTB]; + [coder encodeInt:[self getERIOT] forKey:CODER_KEY_TSC8_ERIOT]; + [coder encodeInt:[self getECDF] forKey:CODER_KEY_TSC8_ECDF]; + [coder encodeBool:[self getESMEenabled] forKey:CODER_KEY_TSC8_ESME_ENABLED]; + unsigned long flag = [pdp8 getTSC8flag]; + [coder encodeBool:[pdp8 getIOFlagBits:flag] ? YES : NO forKey:CODER_KEY_TSC8_IOFLAG]; + [coder encodeBool:[pdp8 getInterruptMaskBits:flag] ? YES : NO forKey:CODER_KEY_TSC8_IOMASK]; +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"TSC8 notifyApplicationWillTerminate"); + NSMutableData *data = [NSMutableData data]; + NSKeyedArchiver *archiver = [[NSKeyedArchiver alloc] initForWritingWithMutableData:data]; + [self encodeWithCoder:archiver]; + [archiver finishEncoding]; + [archiver release]; + [[NSUserDefaults standardUserDefaults] setObject:data forKey:[self pluginName]]; +} + + +- (void) notifyPluginsLoaded:(NSNotification *)notification +{ + [window orderBackFromDefaults:self]; + [window makeFirstResponder:window]; +} + + +- (void) pluginDidLoad +{ + [ertbRegister setupRegisterFor:self + getRegisterValue:@selector(getERTB) setRegisterValue:@selector(setERTB:) + changedNotificationName:ERTB_CHANGED_NOTIFICATION mask:07777 base:8]; + [eriotRegister setupRegisterFor:self + getRegisterValue:@selector(getERIOT) setRegisterValue:@selector(setERIOT:) + changedNotificationName:ERIOT_CHANGED_NOTIFICATION mask:07777 base:8]; + [ecdfRegister setupRegisterFor:self + getRegisterValue:@selector(getECDF) setRegisterValue:@selector(setECDF:) + changedNotificationName:ECDF_CHANGED_NOTIFICATION mask:01 base:8]; + NSData *data = [[NSUserDefaults standardUserDefaults] dataForKey:[self pluginName]]; + if (data) { + NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data]; + self = [self initWithCoder:unarchiver]; + [unarchiver finishDecoding]; + [unarchiver release]; + } + NSNotificationCenter *defaultCenter = [NSNotificationCenter defaultCenter]; + [defaultCenter addObserver:self selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; + [defaultCenter addObserver:self selector:@selector(notifyPluginsLoaded:) + name:PLUGINS_LOADED_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyGo:) name:PDP8_GO_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyStop:) name:PDP8_STOP_NOTIFICATION object:nil]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyStep:) name:PDP8_STEP_NOTIFICATION object:nil]; +} + + +@end diff --git a/TSC8/TSC8iot.c b/TSC8/TSC8iot.c new file mode 100644 index 0000000..c5dd9d5 --- /dev/null +++ b/TSC8/TSC8iot.c @@ -0,0 +1,120 @@ +/* + * PDP-8/E Simulator Source Code + * + * Copyright © 1994-2015 Bernhard Baehr + * + * TSC8iot.h - IOTs for the TSC8-75 plugin + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#define USE_PDP8_REGISTERS_DIRECTLY 1 + +#include "PluginFramework/PDP8.h" + +#include "TSC8iot.h" + + +void i6360 (void) /* ETDS 6360 */ +{ + pdp8->IMASK &= ~pdp8->_tsc8.flag; + pdp8->IOFLAGS &= ~pdp8->_tsc8.flag; + EXECUTION_TIME (12); +} + + +void i6361 (void) /* ESKP 6361 */ +{ + if (pdp8->IOFLAGS & pdp8->_tsc8.flag) + pdp8->PC++; + EXECUTION_TIME (12); +} + + +unsigned s6361 (void) /* ESKP 6361 skip test */ +{ + return pdp8->IOFLAGS & pdp8->_tsc8.flag; +} + + +void i6362 (void) /* ECTF 6362 */ +{ + pdp8->IOFLAGS &= ~pdp8->_tsc8.flag; + EXECUTION_TIME (12); +} + + +void i6363 (void) /* ECDF 6363 */ +{ + pdp8->AC |= (pdp8->_tsc8.eriot >> 3) & 00007; + if (pdp8->_tsc8.ecdf) + pdp8->PC++; + pdp8->_tsc8.ecdf = 0; + EXECUTION_TIME (12); +} + + +unsigned s6363 (void) /* ECDF 6363 skip test */ +{ + return pdp8->_tsc8.ecdf; +} + + +void i6364 (void) /* ERTB 6364 */ +{ + pdp8->AC = (pdp8->AC & 010000) | pdp8->_tsc8.ertb; + EXECUTION_TIME (12); +} + + +void i6365 (void) /* ESME */ +{ + if (pdp8->_tsc8.esmeEnabled) { + if (pdp8->_tsc8.ecdf && ((pdp8->_tsc8.eriot & 070) >> 3) == (pdp8->SF & 07)) { + pdp8->PC++; + pdp8->_tsc8.ecdf = 0; + } + } + EXECUTION_TIME (12); +} + + +unsigned s6365 (void) /* ESME (skip test) */ +{ + unsigned ret = 0; + if (pdp8->_tsc8.esmeEnabled) { + if (pdp8->_tsc8.ecdf && ((pdp8->_tsc8.eriot & 070) >> 3) == (pdp8->SF & 07)) + ret = 1; + } + return (ret); +} + + +void i6366 (void) /* ERIOT 6366 */ +{ + pdp8->AC = (pdp8->AC & 010000) | pdp8->_tsc8.eriot; + EXECUTION_TIME (12); +} + + +void i6367 (void) /* ETEN 6367 */ +{ + pdp8->IMASK |= pdp8->_tsc8.flag; + EXECUTION_TIME (12); +} diff --git a/TSC8/TSC8iot.h b/TSC8/TSC8iot.h new file mode 100644 index 0000000..3712e01 --- /dev/null +++ b/TSC8/TSC8iot.h @@ -0,0 +1,35 @@ +/* + * PDP-8/E Simulator Source Code + * + * Copyright © 1994-2015 Bernhard Baehr + * + * TSC8iots.c - IOTs for the TSC8-75 plugin + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +extern void i6360 (void); /* ETDS */ +extern void i6361 (void); /* ESKP */ +extern unsigned s6361 (void); /* ESKP (skip test) */ +extern void i6362 (void); /* ECTF */ +extern void i6363 (void); /* ECDF */ +extern unsigned s6363 (void); /* ECDF */ +extern void i6364 (void); /* ERTB */ +extern void i6365 (void); /* ESME */ +extern unsigned s6365 (void); /* ESME (skip test) */ +extern void i6366 (void); /* ERIOT */ +extern void i6367 (void); /* ETEN */ diff --git a/Utilities/Assembler.h b/Utilities/Assembler.h new file mode 100644 index 0000000..2e201ee --- /dev/null +++ b/Utilities/Assembler.h @@ -0,0 +1,39 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Assembler.h - Inline assembler for PDP-8/E instructions + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class Opcode; + + +@interface Assembler : NSObject +{ +@private + NSMutableDictionary *symtab; +} + ++ (Assembler *) sharedAssembler; + +- (Opcode *) assemble:(NSString *)source atAddress:(int)address error:(NSString **)error; +- (void) addMnemonic:(NSString *)mnemonic forIOT:(int)opcode; + +@end diff --git a/Utilities/Assembler.m b/Utilities/Assembler.m new file mode 100644 index 0000000..6a763c6 --- /dev/null +++ b/Utilities/Assembler.m @@ -0,0 +1,340 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Assembler.h - Inline assembler for PDP-8/E instructions + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "Assembler.h" +#import "Opcode.h" + + +@implementation Assembler + + +#define isNothing 0 +#define isNumber 1 +#define isIOT 2 +#define needsOperand 4 +#define isMRI 8 +#define isIndirect 16 +#define isOPR1 32 +#define isOPR2 64 +#define isOPR3a 128 +#define isOPR3b 256 +#define isRelativeAddress 512 + + +#define asmNoError nil +#define asmBadNumber NSLocalizedString(@"Invalid octal number.", @"") +#define asmUndefSymbol NSLocalizedString(@"Undefined opcode.", @"") +#define asmBadAddress NSLocalizedString(@"Illegal address.", @"") +#define asmBadRelativeAddress NSLocalizedString(@"Illegal relative address.", @"") +#define asmCannotStartWithThis NSLocalizedString(@"Opcode expected.", @"") +#define asmRelativeAddressNotAllowedHere NSLocalizedString(@"Relative address not allowed here.", @"") +#define asmIndirectNotAllowedHere NSLocalizedString(@"Indirect addressing not allowed here.", @"") +#define asmOffpageReference NSLocalizedString(@"Offpage reference.", @"") +#define asmEndExpected NSLocalizedString(@"End of line expected.", @"") +#define asmIllegalMicroprogramming NSLocalizedString(@"Invalid combination of opcodes.", @"") +#define asmOperandNotAllowedHere NSLocalizedString(@"Operand not allowed here.", @"") +#define asmBadFieldNumber NSLocalizedString(@"Bad field number.", @"") +#define asmNeedsOperand NSLocalizedString(@"Operand expected.", @"") +#define asmInputTooLong NSLocalizedString(@"Input too long.", @"") +#define asmInvalidCharacters NSLocalizedString(@"Input contains invalid characters.", @"") + + ++ (Assembler *) sharedAssembler +{ + static Assembler *sharedAssembler; + + if (! sharedAssembler) + sharedAssembler = [[self alloc] init]; + return sharedAssembler; +} + + +- (Assembler *) init +{ + NSString *key, *flagOrOpcode; + NSNumber *newFlag; + NSEnumerator *arrayEnum; + int opcode, flag, n; + char buf[128]; + + NSDictionary *dict = [NSDictionary dictionaryWithContentsOfFile: + [[NSBundle mainBundle] pathForResource:@"assembler" ofType:@"plist"]]; + NSEnumerator *dictEnum = [dict keyEnumerator]; + + NSDictionary *flags = [NSDictionary dictionaryWithObjectsAndKeys: + [NSNumber numberWithInt:isMRI], @"isMRI", + [NSNumber numberWithInt:isIOT], @"isIOT", + [NSNumber numberWithInt:isOPR1], @"isOPR1", + [NSNumber numberWithInt:isOPR2], @"isOPR2", + [NSNumber numberWithInt:isOPR3a], @"isOPR3a", + [NSNumber numberWithInt:isOPR3b], @"isOPR3b", + [NSNumber numberWithInt:isIndirect], @"isIndirect", + [NSNumber numberWithInt:needsOperand], @"needsOperand", + nil]; + + self = [super init]; + symtab = [[NSMutableDictionary alloc] init]; + while ((key = [dictEnum nextObject])) { + arrayEnum = [[dict valueForKey:key] objectEnumerator]; + flag = 0; + opcode = -1; + while ((flagOrOpcode = [arrayEnum nextObject])) { + newFlag = [flags objectForKey:flagOrOpcode]; + if (newFlag) + flag |= [newFlag intValue]; + else { + [flagOrOpcode getCString:buf + maxLength:(sizeof(buf) - 1) encoding:NSMacOSRomanStringEncoding]; + n = sscanf(buf, "%o", &opcode); + NSAssert1 (n == 1 && (opcode & ~07777) == 0, + @"Invalid parameter for opcode %@", key); + if (n) ; // to avoid Analyzer warning "Value of n never used" + } + } + NSAssert1 (flag != 0 && opcode != -1, @"Incomplete parameters for opcode %@", key); + [symtab setObject:[NSNumber numberWithInt:((flag << 12) | opcode)] forKey:key]; + } + return self; +} + + +- (char *) lookupSymbol:(char *)s getOctal:(long *)octal getFlags:(ushort *)flags error:(NSString **)err +{ + char *t, c; + unsigned long n; + NSNumber *sym; + + *err = asmNoError; + while (*s == ' ') + s++; + if (*s == '\0') { + *octal = 0; + *flags = isNothing; + return (s); + } + if (*s == '.') { + s++; + while (*s == ' ') + s++; + if (*s == '+' || *s == '-') { + c = *s++; + while (*s == ' ') + s++; + } else if (*s) { + *err = asmBadRelativeAddress; + return (s); + } else { + *flags = isRelativeAddress; + *octal = 0; + return (s); + } + } else + c = '\0'; + t = s; + while ('0' <= *t && *t <= '7') + t++; + if (t > s) { + t = s; + for (n = 0; '0' <= *s && *s <= '7'; s++) { + n = 8 * n + *s - '0'; + if (n & ~07777) { + *err = c ? asmBadRelativeAddress : asmBadNumber; + return (t); + } + } + if (c) { + *flags = isRelativeAddress; + *octal = (c == '+') ? n : -n; + } else { + *flags = isNumber; + *octal = n; + } + return (s); + } + if (c) { + *err = asmBadRelativeAddress; + return (s); + } + while (*t && *t != ' ') + t++; + c = *t; + *t = '\0'; + sym = [symtab objectForKey:[NSString stringWithCString:s encoding:NSMacOSRomanStringEncoding]]; + *t = c; + if (sym == nil) { + *err = (*s == '8' || *s == '9') ? asmBadNumber : asmUndefSymbol; + t = s; + } else { + *octal = [sym intValue] & 07777; + *flags = [sym intValue] >> 12; + } + return (t); +} + + +- (Opcode *) assemble:(NSString *)source atAddress:(int)address error:(NSString **)error +{ + char buf[128]; + char *bp, *oldbp; + long w, word, word1; + ushort cl, flags; + + int errpos = 0; + NSString *err = asmNoError; + Opcode *opcode = [Opcode opcodeWithAddress:address]; + + if (! [[source uppercaseString] getCString:buf + maxLength:(sizeof(buf) - 1) encoding:NSMacOSRomanStringEncoding]) { + err = [source canBeConvertedToEncoding:NSMacOSRomanStringEncoding] ? + asmInputTooLong : asmInvalidCharacters; + goto error; + } + bp = buf; + word = 0; + word1 = -1; + flags = isNothing; + for (;;) { + oldbp = bp; + bp = [self lookupSymbol:bp getOctal:&w getFlags:&cl error:&err]; + while (*oldbp == ' ') + oldbp++; + errpos = oldbp - buf; + if (err) + goto error; + if (cl == isNothing) + break; + if (flags == isNothing && + (cl & (isIndirect | isRelativeAddress))) { + err = asmCannotStartWithThis; + goto error; + } + if (cl == isRelativeAddress) { + if (! (flags & isMRI) || + (word != 04000 && word != 05000)) { + err = asmRelativeAddressNotAllowedHere; + goto error; + } + cl = isNumber; + w = (w + (long int) address) & 07777; + } + if (! (flags & isMRI) && (cl & isIndirect)) { + err = asmIndirectNotAllowedHere; + goto error; + } + if (flags & (isIndirect | isMRI)) { + if (flags & cl & isIndirect) { + err = asmIndirectNotAllowedHere; + goto error; + } + if (cl == isNumber) { + if (w < 0 || w > 07777) { + err = asmBadAddress; + goto error; + } + if (w >= 0200) { + if ((w & 07600) != (address & 07600)) { + err = asmOffpageReference; + goto error; + } + w = 0200 | (w & 0177); + } + flags &= ~needsOperand; + } else if (! (cl & isIndirect)) { + err = asmIllegalMicroprogramming; + goto error; + } + } + if (flags & isIOT) { + if (! (cl & (isIOT | isNumber))) { + err = asmIllegalMicroprogramming; + goto error; + } + if (cl == isNumber) { + if (! (flags & needsOperand)) { + err = asmOperandNotAllowedHere; + goto error; + } + if (w < 010) + w <<= 3; + if (w & ~070) { + err = asmBadFieldNumber; + goto error; + } + flags &= ~needsOperand; + } else if ((word & 07770) != (w & 07770)) { + err = asmIllegalMicroprogramming; + goto error; + } + } + if (flags & (isOPR1 | isOPR2 | isOPR3a | isOPR3b)) { + if (cl == isNumber) { + if (! (flags & needsOperand)) { + err = asmOperandNotAllowedHere; + goto error; + } + flags &= ~needsOperand; + word1 = w; + w = 0; + } else { + if (! (cl & flags)) { + err = asmIllegalMicroprogramming; + goto error; + } + cl &= flags | needsOperand; + } + } + if (flags & isNumber) { + err = asmEndExpected; + goto error; + } + flags |= cl; + word |= w; + } + if (flags & needsOperand) { + err = asmNeedsOperand; + goto error; + } + [opcode setWord0:(word & 07777)]; + if (word1 != -1) + [opcode setWord1:(word1 & 07777)]; +error : + if (err) { + if (error) + *error = [NSString stringWithFormat:@"%d %@", errpos, err]; + return nil; + } + return opcode; +} + + +- (void) addMnemonic:(NSString *)mnemonic forIOT:(int)opcode +{ + NSAssert1 ((opcode & ~00777) == 06000, @"Invalid IOT %o", opcode); + [symtab setObject:[NSNumber numberWithInt:((isIOT << 12) | opcode)] forKey:mnemonic]; +} + + +@end diff --git a/Utilities/Breakpoint.h b/Utilities/Breakpoint.h new file mode 100644 index 0000000..11da58b --- /dev/null +++ b/Utilities/Breakpoint.h @@ -0,0 +1,47 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Breakpoint.h - Class for a single breakpoint + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +// Enable bits for breakpoints and break opcodes; "value" of a breakpoint +#define BREAKPOINT 1 +#define USERMODE_BREAKOPCODE 1 +#define SYSTEMMODE_BREAKOPCODE 2 +#define BREAKOPCODE (USERMODE_BREAKOPCODE | SYSTEMMODE_BREAKOPCODE) + + +@interface Breakpoint : NSObject +{ +@private + unsigned identifier; // address for normal breakpoint, opcode for break-opcode + unsigned value; // see defines above +} + ++ (Breakpoint *) breakpointWithIdentifier:(unsigned)ident value:(unsigned)val; + +- (Breakpoint *) initWithIdentifier:(unsigned)ident value:(unsigned)val; +- (unsigned) identifier; +- (unsigned) value; +- (void) setValue:(unsigned)val; +- (NSComparisonResult) compareAddress:(Breakpoint *)breakpoint; + +@end diff --git a/Utilities/Breakpoint.m b/Utilities/Breakpoint.m new file mode 100644 index 0000000..8618ac5 --- /dev/null +++ b/Utilities/Breakpoint.m @@ -0,0 +1,92 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Breakpoint.m - Class for a single breakpoint + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "Breakpoint.h" + + +@implementation Breakpoint + + ++ (Breakpoint *) breakpointWithIdentifier:(unsigned)ident value:(unsigned)val +{ + return [[[self alloc] initWithIdentifier:ident value:val] autorelease]; +} + + +- (id) initWithCoder:(NSCoder *)coder +{ + self = [super init]; + identifier = [coder decodeIntForKey:@"id"]; + value = [coder decodeIntForKey:@"val"]; + return self; +} + + +- (void) encodeWithCoder:(NSCoder *)coder +{ + [coder encodeInt:identifier forKey:@"id"]; + [coder encodeInt:value forKey:@"val"]; +} + + +- (Breakpoint *) initWithIdentifier:(unsigned)ident value:(unsigned)val +{ + self = [super init]; + identifier = ident; + value = val; + return self; +} + + +- (unsigned) identifier +{ + return identifier; +} + + +- (unsigned) value +{ + return value; +} + + +- (void) setValue:(unsigned)val +{ + value = val; +} + + +- (NSComparisonResult) compareAddress:(Breakpoint *)breakpoint +{ + if (identifier < [breakpoint identifier]) + return NSOrderedAscending; + if (identifier > [breakpoint identifier]) + return NSOrderedDescending; + return NSOrderedSame; +} + + +@end diff --git a/Utilities/BreakpointArray.h b/Utilities/BreakpointArray.h new file mode 100644 index 0000000..388fb42 --- /dev/null +++ b/Utilities/BreakpointArray.h @@ -0,0 +1,58 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * BreakpointArray.h - Container for a sorted array of breakpoints + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class Breakpoint; + + +#define BREAKPOINTS_CHANGED_NOTIFICATION @"BreakpointsChangedNotification" + + +@interface BreakpointArray : NSObject +{ +@private + NSString *prefsKey; + NSMutableArray *breakpoints; +} + +- (void) loadFromPrefs:(NSString *)key; + +- (BOOL) hasBreakpointWithValueNotEqualTo:(unsigned)value; + +- (unsigned) valueForIdentifier:(unsigned)ident; +- (unsigned) setBreakpointWithIdentifier:(unsigned)ident value:(unsigned)val; +- (NSIndexSet *) setBreakpointsWithIdentifierArray:(NSArray *)idents value:(unsigned)val; + +- (unsigned) identifierAtIndex:(unsigned)index; +- (unsigned) valueAtIndex:(unsigned)index; +- (void) setBreakpointAtIndex:(unsigned)index value:(unsigned)val; +- (void) deleteBreakpointAtIndex:(unsigned)index; +- (void) deleteBreakpointsAtIndexes:(NSIndexSet *)indexes; + +- (void) setAllValues:(unsigned)val; + +- (int) numberOfBreakpoints; +- (NSEnumerator *) enumerator; + +@end + diff --git a/Utilities/BreakpointArray.m b/Utilities/BreakpointArray.m new file mode 100644 index 0000000..704766f --- /dev/null +++ b/Utilities/BreakpointArray.m @@ -0,0 +1,183 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * BreakpointArray.m - Container for a sorted array of breakpoints + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "BreakpointArray.h" +#import "Breakpoint.h" +#import "NSMutableArray+BinarySearch.h" + + +@implementation BreakpointArray + + +- (void) awakeFromNib +{ + breakpoints = [[NSMutableArray alloc] init]; + [[NSNotificationCenter defaultCenter] addObserver:self + selector:@selector(notifyApplicationWillTerminate:) + name:NSApplicationWillTerminateNotification object:nil]; +} + + +- (void) loadFromPrefs:(NSString *)key +{ + prefsKey = [key retain]; + NSData *data = [[NSUserDefaults standardUserDefaults] dataForKey:key]; + if (data) { + [breakpoints release]; + breakpoints = [[NSMutableArray alloc] + initWithArray:[NSKeyedUnarchiver unarchiveObjectWithData:data]]; + } + [[NSNotificationCenter defaultCenter] + postNotificationName:BREAKPOINTS_CHANGED_NOTIFICATION object:self]; +} + + +- (void) notifyApplicationWillTerminate:(NSNotification *)notification +{ + // NSLog (@"BreakpointArray notifyApplicationWillTerminate"); + [[NSUserDefaults standardUserDefaults] + setObject:[NSKeyedArchiver archivedDataWithRootObject:breakpoints] forKey:prefsKey]; +} + + +- (BOOL) hasBreakpointWithValueNotEqualTo:(unsigned)value +{ + Breakpoint *breakpoint; + + NSEnumerator *enumerator = [breakpoints objectEnumerator]; + while ((breakpoint = [enumerator nextObject])) { + if ([breakpoint value] != value) + return TRUE; + } + return FALSE; +} + + +- (unsigned) valueForIdentifier:(unsigned)ident +{ + int n = [breakpoints indexOfObject:[Breakpoint breakpointWithIdentifier:ident value:0] + inArraySortedBy:@selector(compareAddress:)]; + return (n == NSNotFound) ? 0 : [(Breakpoint *)[breakpoints objectAtIndex:n] value]; +} + + +- (unsigned) setBreakpointWithIdentifier:(unsigned)ident value:(unsigned)val +{ + unsigned index = [breakpoints indexOfObject:[Breakpoint breakpointWithIdentifier:ident value:0] + inArraySortedBy:@selector(compareAddress:)]; + if (index == NSNotFound) + index = [breakpoints addObject: + [Breakpoint breakpointWithIdentifier:ident value:val] + toArraySortedBy:@selector(compareAddress:) replaceExistingObject:YES]; + else + [[breakpoints objectAtIndex:index] setValue:val]; + [[NSNotificationCenter defaultCenter] + postNotificationName:BREAKPOINTS_CHANGED_NOTIFICATION object:self]; + return index; +} + + +- (NSIndexSet *) setBreakpointsWithIdentifierArray:(NSArray *)idents value:(unsigned)val +// mass insert to avoid performance problems with the BREAKPOINTS_CHANGED_NOTIFICATION +// idents must be sorted ascending to get a correct index set +{ + NSNumber *number; + + NSMutableIndexSet *index = [[[NSMutableIndexSet alloc] init] autorelease]; + NSEnumerator *enumerator = [idents objectEnumerator]; + while ((number = [enumerator nextObject])) + [index addIndex:[breakpoints addObject: + [Breakpoint breakpointWithIdentifier:[number intValue] value:val] + toArraySortedBy:@selector(compareAddress:) replaceExistingObject:YES]]; + [[NSNotificationCenter defaultCenter] + postNotificationName:BREAKPOINTS_CHANGED_NOTIFICATION object:self]; + return index; +} + + +- (unsigned) identifierAtIndex:(unsigned)index +{ + NSAssert (index < [breakpoints count], @"Index out of range"); + return [(Breakpoint *)[breakpoints objectAtIndex:index] identifier]; +} + + +- (unsigned) valueAtIndex:(unsigned)index +{ + NSAssert (index < [breakpoints count], @"Index out of range"); + return [(Breakpoint *)[breakpoints objectAtIndex:index] value]; +} + + +- (void) setBreakpointAtIndex:(unsigned)index value:(unsigned)val +{ + NSAssert (index < [breakpoints count], @"Index out of range"); + [[breakpoints objectAtIndex:index] setValue:val]; +} + + +- (void) deleteBreakpointAtIndex:(unsigned)index +{ + NSAssert (index < [breakpoints count], @"Index out of range"); + [breakpoints removeObjectAtIndex:index]; + [[NSNotificationCenter defaultCenter] + postNotificationName:BREAKPOINTS_CHANGED_NOTIFICATION object:self]; +} + + +- (void) deleteBreakpointsAtIndexes:(NSIndexSet *)indexes +{ + [breakpoints removeObjectsAtIndexes:indexes]; + [[NSNotificationCenter defaultCenter] + postNotificationName:BREAKPOINTS_CHANGED_NOTIFICATION object:self]; +} + + +- (void) setAllValues:(unsigned)val +{ + Breakpoint *breakpoint; + + NSEnumerator *enumerator = [breakpoints objectEnumerator]; + while ((breakpoint = [enumerator nextObject])) + [breakpoint setValue:val]; + [[NSNotificationCenter defaultCenter] + postNotificationName:BREAKPOINTS_CHANGED_NOTIFICATION object:self]; +} + + +- (int) numberOfBreakpoints +{ + return [breakpoints count]; +} + + +- (NSEnumerator *) enumerator +{ + return [breakpoints objectEnumerator]; +} + + +@end diff --git a/Utilities/Disassembler.h b/Utilities/Disassembler.h new file mode 100644 index 0000000..02c42c7 --- /dev/null +++ b/Utilities/Disassembler.h @@ -0,0 +1,46 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Disassembler.h - Disassembler for PDP-8/E instructions + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@class PDP8; + + +@interface Disassembler : NSObject +{ +@private + NSArray *mriOpcodes; + NSMutableArray *iotOpcodes; + NSArray *oprGroup1Opcodes; + NSArray *oprGroup2Opcodes; + NSArray *eaeModeAOpcodes; + NSArray *eaeModeBOpcodes; +} + ++ (Disassembler *) sharedDisassembler; + +- (NSString *) disassembleOpcodeForPDP8:(PDP8 *)pdp8 + atAddress:(int)address showOperandsAtPC:(BOOL)showOpAtPC; +- (NSString *) operandInfoForPDP8:(PDP8 *)pdp8 atAddress:(int)addr; +- (void) addMnemonic:(NSString *)mnemonic forIOT:(int)opcode; + +@end diff --git a/Utilities/Disassembler.m b/Utilities/Disassembler.m new file mode 100644 index 0000000..07886ec --- /dev/null +++ b/Utilities/Disassembler.m @@ -0,0 +1,281 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Disassembler.m - Disassembler for PDP-8/E instructions + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "Disassembler.h" +#import "Unicode.h" +#import "PDP8.h" + + +@implementation Disassembler + + ++ (Disassembler *) sharedDisassembler +{ + static Disassembler *sharedDisassembler; + + if (! sharedDisassembler) + sharedDisassembler = [[self alloc] init]; + return sharedDisassembler; +} + + +- (id) init +{ + NSDictionary *dict = [NSDictionary dictionaryWithContentsOfFile: + [[NSBundle mainBundle] pathForResource:@"disassembler" ofType:@"plist"]]; + + self = [super init]; + mriOpcodes = [[dict objectForKey:@"MRI"] retain]; + iotOpcodes = [[dict objectForKey:@"IOT"] retain]; + oprGroup1Opcodes = [[dict objectForKey:@"OPR Group 1"] retain]; + oprGroup2Opcodes = [[dict objectForKey:@"OPR Group 2"] retain]; + eaeModeAOpcodes = [[dict objectForKey:@"EAE Mode A"] retain]; + eaeModeBOpcodes = [[dict objectForKey:@"EAE Mode B"] retain]; + return self; +} + + +- (NSString *) disassembleOpcodeForPDP8:(PDP8 *)pdp8 + atAddress:(int)addr showOperandsAtPC:(BOOL)showOpAtPC +{ + short inst, word1, word2, ad, d, e, pc, field; + char str[128], *p; + + NSCAssert1 ((addr & ~077777) == 0, @"Bad address %o", addr); + if (addr >= [pdp8 memorySize]) + return NSLocalizedString(@"n/a", @""); + p = str; + pc = [pdp8 getProgramCounter]; + inst = [pdp8 memoryAt:addr]; + word1 = [pdp8 memoryAtNext:addr]; + switch (inst & 07000) { + case 00000 : /* AND */ + case 01000 : /* TAD */ + case 02000 : /* ISZ */ + case 03000 : /* DCA */ + case 04000 : /* JMS */ + case 05000 : /* JMP */ + [[mriOpcodes objectAtIndex:(inst >> 9)] + getCString:p maxLength:(sizeof(str) - 1) encoding:NSASCIIStringEncoding]; + p += strlen(p); + p += sprintf(p, " %s", (inst & 0400) ? "I " : ""); + ad = ((inst & 0200) ? (addr & 07600) : 0) | (inst & 0177); + d = ad - (addr & 07777); + if (inst >= 04000 && ! (inst & 0400)) { + if (d == 0) + p += sprintf(p, "."); + else if (-5 < d && d < 5) + p += sprintf(p, ".%+d" /* %d (not %o) to get sign */, d); + else + p += sprintf(p, "%o", ad); + } else + p += sprintf(p, "%o", ad); + if (addr == pc && showOpAtPC) { + field = ((inst >= 04000 && ! (inst & 0400) && [pdp8 getIB] != [pdp8 getIF]) ? + [pdp8 getIB] : [pdp8 getIF]) << 12; + d = ((inst & 0400) && ad > 07 && ad < 020) ? 1 : 0; + /* indirect auto index register access */ + word1 = field | ad; + ad = ([pdp8 memoryAt:(field | ad)] + d) & 07777; + if (inst < 05000 || inst >= 05400) + p += sprintf(p, " (%4.4o)", ad); + if (inst < 05000 && (inst & 0400)) { + field = ((inst < 04000) ? [pdp8 getDF] : [pdp8 getIB]) << 12; + d = (d && word1 == (field | ad)) ? 1 : 0; + ad = ([pdp8 memoryAt:(field | ad)] + d) & 07777; + p += sprintf(p, " ((%4.4o))", ad); + } + } + break; + case 06000 : /* IOT */ + [[iotOpcodes objectAtIndex:(inst & 0777)] + getCString:p maxLength:sizeof(str) encoding:NSASCIIStringEncoding]; + p += strlen(p); + break; + case 07000 : /* OPR */ + switch (inst & 07401) { + case 07000 : /* OPR Group I */ + case 07001 : + [[oprGroup1Opcodes objectAtIndex:(inst & 0377)] + getCString:p maxLength:sizeof(str) encoding:NSASCIIStringEncoding]; + p += strlen(p); + break; + case 07400 : /* OPR Group II */ + [[oprGroup2Opcodes objectAtIndex:((inst & 0377) >> 1)] + getCString:p maxLength:sizeof(str) encoding:NSASCIIStringEncoding]; + p += strlen(p); + break; +/* + * | | | | + * |---|---|---|---|---|---|---|---|---| + * | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10| 11| + * | 1 |CLA|MQA|SCA|MQL| | | | 1 | Group III Mode A + * |---|---|---|---|---|---|---|---|---| + * Sequence: 1 2 2 \____3____/ + * V + * 0 = NOP 2 = MUY# 4 = NMI 6 = ASR# + * 1 = SCL# 3 = DVI# 5 = SHL# 7 = LSR# + * + * | | | | + * |---|---|---|---|---|---|---|---|---| + * | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10| 11| + * | 1 |CLA|MQA| |MQL| | | | 1 | Group III Mode B + * |---|---|---|---|---|---|---|---|---| + * Sequence: 1 2 \ 2 / + * \_______3_______/ + * V + * 0 = NOP 4 = NMI 10 = SCA 14 = DPSZ + * 1 = ACS 5 = SHL# 11 = DAD# 15 = DPIC* + * 2 = MUY# 6 = ASR# 12 = DST# 16 = DCM* + * 3 = DVI# 7 = LSR# 13 = SWBA 17 = SAM + * # = 2-word instructions + * * = (MQL & MQA must be set) + */ + case 07401 : /* EAE */ + d = (inst & 0377) >> 1 ; + if ([pdp8 getEAEmode] == EAE_MODE_A) { + [[eaeModeAOpcodes objectAtIndex:d] + getCString:p maxLength:sizeof(str) encoding:NSASCIIStringEncoding]; + p += strlen(p); + switch (inst & 016) { + case 002 : /* SCL */ + case 004 : /* MUY */ + case 006 : /* DVI */ + case 012 : /* SHL */ + case 014 : /* ASR */ + case 016 : /* LSR */ + if (inst != 07447) { /* SWBA */ + p += sprintf(p, " %o", word1); + /* word1 is operand */ + } + break; + default : + break; + } + } else { /* EAE mode B */ + [[eaeModeBOpcodes objectAtIndex:d] + getCString:p maxLength:sizeof(str) encoding:NSASCIIStringEncoding]; + p += strlen(p); + switch (inst & 056) { + case 04 : /* MUY */ + case 06 : /* DVI */ + p += sprintf(p, " %o", word1); + /* DF|word1 points to operand word */ + if (addr == pc && showOpAtPC) { + ad = (addr & 070000) | ((addr + 1) & 07777); + d = ((ad & 07770) == 010) ? 1 : 0; /* autoindex? */ + word1 = ([pdp8 getDF] << 12) | ((word1 + d) & 07777); + d = (d && (ad == word1)) ? 1 : 0; + /* operand == autoindexed ptr? */ + p += sprintf(p, " (%4.4o)", + ([pdp8 memoryAt:word1] + d) & 07777); + } + break; + case 012 : /* SHL */ + case 014 : /* ASR */ + case 016 : /* LSR */ + p += sprintf(p, " %o", word1); + /* word1 is operand */ + break; + case 042 : /* DAD */ + case 044 : /* DST */ + p += sprintf(p, " %o", word1); + /* DF|word1 points to op double word */ + /* DAD adds op double word to AC'MQ */ + /* DST overwrites op dword with AC'MQ */ + if (addr == pc && showOpAtPC) { + ad = (addr & 070000) | ((addr + 1) & 07777); + d = ((ad & 07770) == 010) ? 1 : 0; /* autoindex? */ + word2 = ([pdp8 getDF] << 12) | ((word1 + d + 1) & 07777); + word1 = ([pdp8 getDF] << 12) | ((word1 + d) & 07777); + e = (d && (ad == word2)) ? 1 : 0; + /* operand == autoindexed ptr? */ + d = (d && (ad == word1)) ? 1 : 0; + p += sprintf(p, " (%4.4o%4.4o)", + ([pdp8 memoryAt:word2] + e) & 07777, + ([pdp8 memoryAt:word1] + d) & 07777); + } + break; + } + } + break; + } + break; + } + *p = '\0'; /* to avoid Xcode analyzer warning */ + return [NSString stringWithCString:str encoding:NSASCIIStringEncoding]; +} + + +- (NSString *) operandInfoForPDP8:(PDP8 *)pdp8 atAddress:(int)addr +{ + NSMutableString *string; + int inst, op, ad, oldad, field, d, d1, mark, i; + + inst = [pdp8 memoryAt:addr]; + if (inst >= 06000) + return nil; /* no MRI */ + if (05000 <= inst && inst < 05400) + return nil; /* direct JMP */ + ad = ((inst & 0200) ? (addr & 07600) : 0) | (inst & 0177); + d = ((inst & 0400) && ad > 07 && ad < 020) ? 1 : 0; /* indirect auto index register access */ + ad |= addr & 070000; + op = ([pdp8 memoryAt:ad] + d) & 07777; + string = [NSMutableString stringWithFormat:@"%5.5o: %4.4o", ad, op]; + if (inst < 05000 && (inst & 0400)) { + [string appendString:@"\n\n"]; + oldad = ad; + ad = op; + mark = ((inst < 04000) ? [pdp8 getDF] : [pdp8 getIB]) << 12; + for (i = 0; i < 4; i++) { + field = i << 12; + part2 : + d1 = (d && oldad == (field | ad)) ? 1 : 0; + op = ([pdp8 memoryAt:field | ad] + d1) & 07777; + [string appendFormat:@"%5.5o: %4.4o", field | ad, op]; + if (field == mark) + [string appendFormat:@"%C", UNICODE_DIAMOND]; + if (field & 040000) + [string appendString:@"\n"]; + else { + [string appendString:@"\t"]; + field |= 040000; + goto part2; + } + } + } + return string; +} + + +- (void) addMnemonic:(NSString *)mnemonic forIOT:(int)opcode +{ + NSAssert1 ((opcode & ~00777) == 06000, @"Invalid IOT %o", opcode); + [iotOpcodes replaceObjectAtIndex:opcode & 0777 withObject:mnemonic]; +} + + +@end diff --git a/Utilities/EnableDisableTextField.h b/Utilities/EnableDisableTextField.h new file mode 100644 index 0000000..56e0b30 --- /dev/null +++ b/Utilities/EnableDisableTextField.h @@ -0,0 +1,29 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * EnableDisableTextField.h - NSTextField that can be disabled (grayed) + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface EnableDisableTextField : NSTextField +{ +} + +@end diff --git a/Utilities/EnableDisableTextField.m b/Utilities/EnableDisableTextField.m new file mode 100644 index 0000000..bf50da4 --- /dev/null +++ b/Utilities/EnableDisableTextField.m @@ -0,0 +1,40 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * EnableDisableTextField.m - NSTextField that can be disabled (grayed) + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "EnableDisableTextField.h" + + +@implementation EnableDisableTextField + + +- (void) setEnabled:(BOOL)flag +{ + [self setTextColor:flag ? [NSColor controlTextColor] : [NSColor disabledControlTextColor]]; + [super setEnabled:flag]; +} + + +@end diff --git a/Utilities/FloatingPointNumber.h b/Utilities/FloatingPointNumber.h new file mode 100644 index 0000000..3a1af83 --- /dev/null +++ b/Utilities/FloatingPointNumber.h @@ -0,0 +1,50 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * FloatingPointNumber.h - Floating point numbers for format conversions + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface FloatingPointNumber : NSObject +{ +@private + int exponent; // Exponent of the floating point number + int bias; // Bias of the exponent + // Bias == 0 means that exponent is a 12-bit two complement number + BOOL negative; // Sign of the floating point number + BOOL twoComplementMantissa; // True iff mantissa is given in two complement + unsigned long long mantissa; // 64-bit mantissa +} + ++ (FloatingPointNumber *) floatingPointNumberWithExponent:(int)e bias:(int)b negative:(BOOL)n + twoComplementMantissa:(BOOL)tcm mantissa:(unsigned long long)m; ++ (FloatingPointNumber *) floatingPointNumberFromString:(NSString *)string withBias:(int)bias + withTwoComplementMantissa:(BOOL)tcm error:(NSString **)error; + +- (FloatingPointNumber *) initWithExponent:(int)e bias:(int)b negative:(BOOL)n + twoComplementMantissa:(BOOL)tcm mantissa:(unsigned long long)m; +- (NSString *) stringValueWithPrecision:(int)precision; +- (int) exponent; +- (int) bias; +- (BOOL) negative; +- (BOOL) twoComplementMantissa; +- (unsigned long long) mantissa; + +@end diff --git a/Utilities/FloatingPointNumber.m b/Utilities/FloatingPointNumber.m new file mode 100644 index 0000000..7953d6c --- /dev/null +++ b/Utilities/FloatingPointNumber.m @@ -0,0 +1,170 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * FloatingPointNumber.h - Floating point numbers for format conversions + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "FloatingPointNumber.h" + + +@implementation FloatingPointNumber + + ++ (FloatingPointNumber *) floatingPointNumberWithExponent:(int)e bias:(int)b negative:(BOOL)n + twoComplementMantissa:(BOOL)tcm mantissa:(unsigned long long)m +{ + return [[[self alloc] + initWithExponent:e bias:b negative:n twoComplementMantissa:tcm mantissa:m] autorelease]; +} + + ++ (FloatingPointNumber *) floatingPointNumberFromString:(NSString *)string + withBias:(int)bias withTwoComplementMantissa:(BOOL)tcm error:(NSString **)error +{ + decimal dec; + short ok; + int exponent; + BOOL negative; + unsigned long long mantissa; + + const char *p = [string cStringUsingEncoding:NSMacOSRomanStringEncoding]; + short ix = 0; + str2dec (p, &ix, &dec, &ok); + if (! ok) { + if (error) + *error = NSLocalizedString(@"Invalid floating point number.", @""); + return nil; + } + double d = dec2num(&dec); + if (! isfinite(d)) { + if (error) + *error = NSLocalizedString(@"IEEE overflow.", @""); + return nil; + } + if (d != 0.0 && ! isnormal(d)) { + if (error) + *error = NSLocalizedString(@"IEEE underflow.", @""); + return nil; + } + if (d < 0.0) { + negative = YES; + d = -d; + } else + negative = NO; + d = frexp(d, &exponent); + mantissa = (unsigned long long) ldexp(d, 64); + if (bias) { + if (d != 0.0) + exponent += bias; + if (exponent < 0 || 2 * bias <= exponent) { + if (error) + *error = NSLocalizedString(@"Floating point number out of range.", @""); + return nil; + } + } else { // exponent must be a 12-bit two complement integer + if ((exponent & ~07777) != 0 && (exponent & ~07777) != ~07777) { + if (error) + *error = NSLocalizedString(@"Floating point number out of range.", @""); + return nil; + } else + exponent &= 07777; + } + if (negative && tcm) + mantissa = ~mantissa + 1; + return [FloatingPointNumber floatingPointNumberWithExponent:exponent + bias:bias negative:negative twoComplementMantissa:tcm mantissa:mantissa]; +} + + +- (FloatingPointNumber *) initWithExponent:(int)e bias:(int)b negative:(BOOL)n + twoComplementMantissa:(BOOL)tcm mantissa:(unsigned long long)m +{ + self = [super init]; + exponent = e; + bias = b; + negative = n; + twoComplementMantissa = tcm; + mantissa = m; + return self; +} + + +- (NSString *) stringValueWithPrecision:(int)precision +{ + if (exponent == 0 && mantissa == 0) + return @"0.0"; + unsigned long long mant = (negative && twoComplementMantissa) ? (~mantissa + 1) : mantissa; + if ((mant >> 63) == 0) + return NSLocalizedString(@"(not normalized)", @""); + double d = ldexp((double) mant, -64); + if (negative) + d = -d; + int exp = exponent; + if (bias) + exp -= bias; + else { + if (exp == 04000) /* exponent -0 */ + exp = 0; + if (exp & 04000) /* negative 12-bit two complement exponent */ + exp |= ~07777; + } + d = ldexp(d, exp); + if (! isfinite(d)) + return NSLocalizedString(@"(IEEE overflow)", @""); + if (! isnormal(d)) + return NSLocalizedString(@"(IEEE underflow)", @""); + return [NSString stringWithFormat:@"%.*g", precision, d]; +} + + +- (int) exponent +{ + return exponent; +} + + +- (int) bias +{ + return bias; +} + + +- (BOOL) negative +{ + return negative; +} + + +- (BOOL) twoComplementMantissa +{ + return twoComplementMantissa; +} + + +- (unsigned long long) mantissa +{ + return mantissa; +} + + +@end diff --git a/Utilities/InputConsumerProtocol.h b/Utilities/InputConsumerProtocol.h new file mode 100644 index 0000000..1559cc9 --- /dev/null +++ b/Utilities/InputConsumerProtocol.h @@ -0,0 +1,29 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * InputConsumerProtocol.h - Protocol for consumer of device input + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@protocol InputConsumer + +- (void) canContinueInput; // signal that new device input is available + +@end diff --git a/Utilities/KeepInMenuWindow.h b/Utilities/KeepInMenuWindow.h new file mode 100644 index 0000000..38cc27e --- /dev/null +++ b/Utilities/KeepInMenuWindow.h @@ -0,0 +1,32 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * KeepInMenuWindow.h - Windows that are kept in the window menu when hidden + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface KeepInMenuWindow : NSWindow +{ +} + +- (void) orderFrontFromDefaults:(id)sender; +- (void) orderBackFromDefaults:(id)sender; + +@end diff --git a/Utilities/KeepInMenuWindow.m b/Utilities/KeepInMenuWindow.m new file mode 100644 index 0000000..db9356a --- /dev/null +++ b/Utilities/KeepInMenuWindow.m @@ -0,0 +1,103 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * KeepInMenuWindow.m - Windows that are kept in the window menu when hidden + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "KeepInMenuWindow.h" +#import "Unicode.h" + + +@implementation KeepInMenuWindow + + +#define WINDOW_VISIBILITY_DEFAULTS_KEY_SUFFIX @" Visible" // with leading space + + +- (void) saveVisibilityInDefaults +{ + NSString *frameAutosaveName = [self frameAutosaveName]; + if (frameAutosaveName) + [[NSUserDefaults standardUserDefaults] setBool:[self isVisible] forKey: + [frameAutosaveName stringByAppendingString:WINDOW_VISIBILITY_DEFAULTS_KEY_SUFFIX]]; +} + + +- (BOOL) getVisibilityFromDefaults +{ + NSNumber *visible = nil; + NSString *frameAutosaveName = [self frameAutosaveName]; + if (frameAutosaveName) + visible = [[NSUserDefaults standardUserDefaults] objectForKey: + [frameAutosaveName stringByAppendingString:WINDOW_VISIBILITY_DEFAULTS_KEY_SUFFIX]]; + else + NSLog (@"Missing autosave name for window %C%@%C", + UNICODE_LEFT_DOUBLEQUOTE, [self title], UNICODE_RIGHT_DOUBLEQUOTE); + // check existance of the key to make all windows visible at the very first launch of the simulator + return frameAutosaveName == nil || visible == nil || [visible boolValue]; +} + + +- (BOOL) windowShouldClose:(NSWindow *)window +// When the delegate allows the window to close, close it and then re-add it to the window menu +{ + id delegate = [window delegate]; + if (delegate == nil || ! [delegate respondsToSelector:@selector(windowShouldClose:)] || + [delegate windowShouldClose:self]) { + [window close]; + [self saveVisibilityInDefaults]; + [NSApp addWindowsItem:window title:[window title] filename:NO]; + } + return NO; +} + + +- (void) makeKeyAndOrderFront:(id)sender +{ + [super makeKeyAndOrderFront:sender]; + [super makeFirstResponder:self]; + [self saveVisibilityInDefaults]; +} + + +- (void) orderFrontFromDefaults:(id)sender +{ + if ([self getVisibilityFromDefaults]) + [self orderFront:sender]; + else + [NSApp addWindowsItem:self title:[self title] filename:NO]; + [self saveVisibilityInDefaults]; +} + + +- (void) orderBackFromDefaults:(id)sender +{ + if ([self getVisibilityFromDefaults]) + [self orderBack:sender]; + else + [NSApp addWindowsItem:self title:[self title] filename:NO]; + [self saveVisibilityInDefaults]; +} + + +@end diff --git a/Utilities/NonWrappingTableView.h b/Utilities/NonWrappingTableView.h new file mode 100644 index 0000000..51de565 --- /dev/null +++ b/Utilities/NonWrappingTableView.h @@ -0,0 +1,30 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NonWrappingTableView.h - NSTableView without wrap-around editing + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface NonWrappingTableView : NSTableView +{ +} +@end + + diff --git a/Utilities/NonWrappingTableView.m b/Utilities/NonWrappingTableView.m new file mode 100644 index 0000000..077d260 --- /dev/null +++ b/Utilities/NonWrappingTableView.m @@ -0,0 +1,70 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * NonWrappingTableView.h - NSTableView without wrap-around editing + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "NonWrappingTableView.h" +#import "Utilities.h" + + +@implementation NonWrappingTableView + + +- (void) textDidEndEditing:(NSNotification *)notification +// Avoid editing to wrap around from last available memory location to 0 and vice versa. +// Note the different behaviour of Tiger and Leopard: +// http://developer.apple.com/releasenotes/Cocoa/AppKit.html#NSTableView +{ + NSDictionary *userInfo = [notification userInfo]; + int textMovement = [[userInfo valueForKey:@"NSTextMovement"] intValue]; + int row = [self editedRow]; + int col = [self editedColumn]; + int newrow = (textMovement == NSBacktabTextMovement) ? row - 1 : row + 1; + + if (textMovement == NSTabTextMovement && runningOnLeopardOrNewer()) { + // default behaviour on Leopard: tab to next view + [super textDidEndEditing:notification]; + return; + } + if ((textMovement == NSReturnTextMovement || + textMovement == NSTabTextMovement || textMovement == NSBacktabTextMovement) + && [[self delegate] tableView:self shouldEditTableColumn:nil row:newrow]) + textMovement = (textMovement == NSBacktabTextMovement) ? + NSUpTextMovement : NSDownTextMovement; + else + textMovement = NSIllegalTextMovement; + NSMutableDictionary *newInfo = [NSMutableDictionary dictionaryWithDictionary:userInfo]; + [newInfo setObject:[NSNumber numberWithInt:textMovement] forKey:@"NSTextMovement"]; + [super textDidEndEditing:[NSNotification notificationWithName:[notification name] + object: [notification object] userInfo:newInfo]]; + if (textMovement != NSIllegalTextMovement) { + [self selectRowIndexes:[NSIndexSet indexSetWithIndex:newrow] byExtendingSelection:NO]; + [self editColumn:col row:newrow withEvent:nil select:YES]; + } +} + + +@end + + diff --git a/Utilities/OctalFormatter.h b/Utilities/OctalFormatter.h new file mode 100644 index 0000000..1974385 --- /dev/null +++ b/Utilities/OctalFormatter.h @@ -0,0 +1,39 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * OctalFormatter.m - Formatter for octal numbers + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface OctalFormatter : NSFormatter +{ +@private + BOOL wildcardAllowed; + unsigned bitMask; + NSString *outputFormat; + unsigned numberOfWords; +} + ++ (OctalFormatter *) formatterWithBitMask:(unsigned)mask wildcardAllowed:(BOOL)withWildcard; + +- (OctalFormatter *) initWithBitMask:(unsigned)mask wildcardAllowed:(BOOL)withWildcard; +- (void) setNumberOfWords:(unsigned)n; + +@end diff --git a/Utilities/OctalFormatter.m b/Utilities/OctalFormatter.m new file mode 100644 index 0000000..09b155b --- /dev/null +++ b/Utilities/OctalFormatter.m @@ -0,0 +1,159 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * OctalFormatter.m - Formatter for octal numbers + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "OctalFormatter.h" + + +@implementation OctalFormatter + + ++ (OctalFormatter *) formatterWithBitMask:(unsigned)mask wildcardAllowed:(BOOL)withWildcard +{ + return [[[OctalFormatter alloc] initWithBitMask:mask wildcardAllowed:withWildcard] autorelease]; +} + + +- (OctalFormatter *) initWithBitMask:(unsigned)mask wildcardAllowed:(BOOL)withWildcard +{ + if ((self = [super init])) { + wildcardAllowed = withWildcard; + bitMask = mask; + int digits = 0; + while (mask) { + digits++; + mask >>= 3; + } + outputFormat = [[NSString alloc] initWithFormat:@"%%%d.%do", digits, digits]; + numberOfWords = 1; + } + return self; +} + + +- (void) setNumberOfWords:(unsigned)n +{ + numberOfWords = n; +} + + +- (NSString *) stringForObjectValue:(id)value +{ + unsigned i; + + NSMutableString *string = nil; + if ([value isKindOfClass:[NSNumber class]]) + string = [NSString stringWithFormat:outputFormat, [value intValue]]; + else if ([value isKindOfClass:[NSArray class]]) { + unsigned count = [value count]; + if (numberOfWords < count) + count = numberOfWords; + string = [NSMutableString stringWithCapacity:5 * count]; + for (i = 0; i < count; i++) { + if (i > 0) + [string appendString:@" "]; + [string appendFormat:outputFormat, [[value objectAtIndex:i] intValue]]; + } + } + return string; +} + + +- (BOOL) getObjectValue:(id *)value forString:(NSString *)string errorDescription:(NSString **)error +/* For string without placeholder, value becomes a NSNumber (for numberOfWords == 1) or an + NSArray of NSNumbers (for numberOfWords > 1). For strings with placeholder, values becomes + an asencding sorted NSArray of NSNumbers (for numberOfWords == 1) or an NSArray of such NSArrays + (for numberOfWords > 1). */ +{ + char buf[128]; + char *bp = buf; + NSMutableArray *values = [NSMutableArray arrayWithCapacity:numberOfWords]; + if (! [string getCString:buf maxLength:(sizeof(buf) - 1) encoding:NSMacOSRomanStringEncoding]) { + if (error) + *error = [string canBeConvertedToEncoding:NSMacOSRomanStringEncoding] ? + NSLocalizedString(@"Input too long.", @"") : + NSLocalizedString(@"Input contains invalid characters.", @""); + return FALSE; + } + while (*bp == ' ') + bp++; + while (('0' <= *bp && *bp < '8') || (wildcardAllowed && *bp == '#')) { + unsigned val = 0; + unsigned pattern = 0; + while (('0' <= *bp && *bp < '8') || (wildcardAllowed && *bp == '#')) { + pattern <<= 3; + if ('0' <= *bp && *bp < '8') + val = val * 8 + (*bp - '0'); + else { + val *= 8; + pattern |= 7; + } + bp++; + } + while (*bp == ' ') + bp++; + if ((val | pattern) & ~bitMask) { + if (error) + *error = [NSString stringWithFormat:NSLocalizedString( + @"The octal number is of range. The largest allowed number is %o.", + @""), bitMask]; + return FALSE; + } + if (pattern) { + unsigned long mask = pattern; + NSMutableArray *patternValues = [NSMutableArray arrayWithCapacity:8]; + do { + [patternValues insertObject:[NSNumber numberWithInt:val + pattern] + atIndex:0]; + pattern = (pattern - 1) & mask; + } while (pattern != mask); + [values addObject:patternValues]; + } else + [values addObject:[NSNumber numberWithInt:val]]; + } + if (*bp || [values count] != numberOfWords) { + if (error) + *error = (numberOfWords == 1) ? + (wildcardAllowed ? + NSLocalizedString( + @"Invalid input. An octal number is expected. " + @"The wildcard character # is allowed.", @"") : + NSLocalizedString( + @"Invalid input. An octal number is expected.", @"")) : + [NSString stringWithFormat:wildcardAllowed ? + NSLocalizedString( + @"Invalid input. %d octal numbers are expected. " + @"The wildcard character # is allowed.", @"") : + NSLocalizedString( + @"Invalid input. %d octal numbers are expected.", @""), + numberOfWords]; + return FALSE; + } + *value = (numberOfWords == 1) ? [values objectAtIndex:0] : values; + return TRUE; +} + + +@end diff --git a/Utilities/Opcode.h b/Utilities/Opcode.h new file mode 100644 index 0000000..25b67d5 --- /dev/null +++ b/Utilities/Opcode.h @@ -0,0 +1,44 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Opcode.h - Class representing a PDP-8 opcode + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface Opcode : NSObject +{ +@private + int address; /* PDP-8 address used while assembly */ + int word0; /* first 12-bit word of the opcode, -1 == invalid */ + int word1; /* optional second word, -1 == not used */ +} + ++ (Opcode *) opcodeWithAddress:(int)addr; ++ (Opcode *) opcodeWithAddress:(int)addr value:(int)value; + +- (Opcode *) initWithAddress:(int)addr; +- (Opcode *) initWithAddress:(int)addr value:(int)value; +- (int) address; +- (int) word0; +- (void) setWord0:(int)w1; +- (int) word1; +- (void) setWord1:(int)w2; + +@end diff --git a/Utilities/Opcode.m b/Utilities/Opcode.m new file mode 100644 index 0000000..9219ce2 --- /dev/null +++ b/Utilities/Opcode.m @@ -0,0 +1,104 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Opcode.m - Class representing a PDP-8 opcode + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "Opcode.h" + + +@implementation Opcode + + ++ (Opcode *) opcodeWithAddress:(int)addr +{ + return [[[self alloc] initWithAddress:addr] autorelease]; +} + + ++ (Opcode *) opcodeWithAddress:(int)addr value:(int)value +{ + return [[[self alloc] initWithAddress:addr value:value] autorelease]; +} + + +- (id) copyWithZone:(NSZone *)zone +{ + Opcode *new = [[Opcode alloc] initWithAddress:address]; + + new->word0 = word0; + new->word1 = word1; + return new; +} + + +- (Opcode *) initWithAddress:(int)addr +{ + self = [super init]; + address = addr; + word0 = word1 = -1; + return self; +} + + +- (Opcode *) initWithAddress:(int)addr value:(int)value +{ + self = [super init]; + address = addr; + word0 = value; + word1 = -1; + return self; +} + + +- (int) address +{ + return address; +} + + +- (int) word0 +{ + return word0; +} + + +- (void) setWord0:(int)w0 +{ + word0 = w0; +} + + +- (int) word1 +{ + return word1; +} + + +- (void) setWord1:(int)w1 +{ + word1 = w1; +} + + +@end diff --git a/Utilities/OpcodeFormatter.h b/Utilities/OpcodeFormatter.h new file mode 100644 index 0000000..a4008cf --- /dev/null +++ b/Utilities/OpcodeFormatter.h @@ -0,0 +1,46 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * OpcodeFormatter.h - Formatter for the Opcode column of the CPU window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@protocol OpcodeFormatterAddressGetter + +- (int) getCurrentAddress; + +@end + + +@class PDP8; + + +@interface OpcodeFormatter : NSFormatter +{ +@private + PDP8 *pdp8; + id addressGetter; +} + ++ (OpcodeFormatter *) formatterWithPDP8:(PDP8 *)p8 addressGetter:(id )addrGetter; + +- (OpcodeFormatter *) initWithPDP8:(PDP8 *)p8 addressGetter:(id )addrGetter; + +@end diff --git a/Utilities/OpcodeFormatter.m b/Utilities/OpcodeFormatter.m new file mode 100644 index 0000000..e3b77d5 --- /dev/null +++ b/Utilities/OpcodeFormatter.m @@ -0,0 +1,78 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * OpcodeFormatter.m - Formatter for the Opcode column of the CPU window + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "OpcodeFormatter.h" +#import "Opcode.h" +#import "Assembler.h" +#import "Disassembler.h" + + +@implementation OpcodeFormatter + + ++ (OpcodeFormatter *) formatterWithPDP8:(PDP8 *)p8 addressGetter:(id )addrGetter +{ + return [[[OpcodeFormatter alloc] initWithPDP8:p8 addressGetter:addrGetter] autorelease]; +} + + +- (OpcodeFormatter *) initWithPDP8:(PDP8 *)p8 addressGetter:(id )addrGetter; +{ + pdp8 = p8; + addressGetter = addrGetter; + return self; +} + + +- (NSString *) stringForObjectValue:(Opcode *)opcode +{ + // with Leopard, the formatter is called once for a Text Cell - don't know why + if (! [opcode isKindOfClass:[Opcode class]]) + return nil; + return [[Disassembler sharedDisassembler] disassembleOpcodeForPDP8:pdp8 + atAddress:[opcode address] showOperandsAtPC:TRUE]; +} + + +- (NSString *) editingStringForObjectValue:(Opcode *)opcode +{ + // with Yosemite, after typing invalid input, this method is called with the invalid string, not with an Opcode + if ([opcode isKindOfClass:[NSString class]]) + return (NSString *) opcode; + return [[Disassembler sharedDisassembler] disassembleOpcodeForPDP8:pdp8 + atAddress:[opcode address] showOperandsAtPC:FALSE]; +} + + +- (BOOL) getObjectValue:(Opcode **)opcode forString:(NSString *)string errorDescription:(NSString **)error +{ + *opcode = [[Assembler sharedAssembler] + assemble:string atAddress:[addressGetter getCurrentAddress] error:error]; + return *opcode != nil; +} + + +@end diff --git a/Utilities/PaperTapeController.h b/Utilities/PaperTapeController.h new file mode 100644 index 0000000..1a757cb --- /dev/null +++ b/Utilities/PaperTapeController.h @@ -0,0 +1,46 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PaperTapeController.h - Controller for a paper tape reader and punch + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@protocol InputConsumer; +@class PaperTapeProgressIndicator, EnableDisableTextField; + + +@interface PaperTapeController : NSObject { +@private + IBOutlet NSControl *loadUnloadButton; // NSButton or NSSegmentedControl + IBOutlet NSSegmentedControl *onOffButton; + IBOutlet EnableDisableTextField *filenameField; + IBOutlet PaperTapeProgressIndicator *progressIndicator; + IBOutlet id inputConsumer; + NSFileHandle *fileHandle; + int kind; /* PAPER_TAPE_READER or PAPER_TAPE_PUNCH */ +} + +- (void) setEnabled:(BOOL)flag; +- (IBAction) loadUnloadClicked:(id)sender; +- (IBAction) onOffClicked:(id)sender; +- (int) getChar; +- (BOOL) putChar:(unsigned char)c handleBackspace:(BOOL)handleBackspace; + +@end diff --git a/Utilities/PaperTapeController.m b/Utilities/PaperTapeController.m new file mode 100644 index 0000000..4810daa --- /dev/null +++ b/Utilities/PaperTapeController.m @@ -0,0 +1,266 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PaperTapeController.m - Controller for a paper tape reader and punch + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "FileDropControlTargetProtocol.h" +#import "PaperTapeController.h" +#import "NSControl+FileDrop.h" +#import "NSThread+MainThread.h" +#import "Utilities.h" +#import "EnableDisableTextField.h" +#import "Unicode.h" +#import "InputConsumerProtocol.h" +#import "PaperTapeProgressIndicator.h" + + +@implementation PaperTapeController + + +#define PAPER_TAPE_ON_TAG 0 +#define PAPER_TAPE_OFF_TAG 1 + +#define PAPER_TAPE_READER 0 +#define PAPER_TAPE_PUNCH 1 + + +- (void) setEnabled:(BOOL)flag +{ + [loadUnloadButton setEnabled:flag]; + [filenameField setEnabled:flag]; + if (onOffButton) + [onOffButton setEnabled:flag && fileHandle != nil]; +} + + + +- (int) getChar +{ + NSAssert (kind == PAPER_TAPE_READER, @"Cannot read from paper tape punch"); + int c = EOF; + if (fileHandle) { + if (onOffButton == nil || [onOffButton selectedSegment] == PAPER_TAPE_ON_TAG) { + NSData *data = [fileHandle readDataOfLength:1]; + if ([data length] == 1) { + c = * (unsigned char *) [data bytes]; + if ([NSThread isMainThread]) + [progressIndicator incrementAndAnimate]; + else + [progressIndicator + performSelectorOnMainThread:@selector(incrementAndAnimate) + withObject:self waitUntilDone:NO]; + } else { + if ([NSThread isMainThread]) + [self loadUnloadClicked:self]; + else + [self performSelectorOnMainThread:@selector(loadUnloadClicked:) + withObject:self waitUntilDone:NO]; + } + } + } + return c; +} + + +- (BOOL) putChar:(unsigned char)c handleBackspace:(BOOL)handleBackspace +{ + NSAssert (kind == PAPER_TAPE_PUNCH, @"Cannot punch to paper tape reader"); + BOOL done = NO; + if (fileHandle && (onOffButton == nil || [onOffButton selectedSegment] == PAPER_TAPE_ON_TAG)) { + if (c == '\b' && handleBackspace) { + long size = (long) [fileHandle offsetInFile]; + if (size > 0) + [fileHandle truncateFileAtOffset:size - 1]; + } else + [fileHandle writeData:[NSData dataWithBytes:&c length:1]]; + if ([NSThread isMainThread]) + [progressIndicator incrementAndAnimate]; + else + [progressIndicator + performSelectorOnMainThread:@selector(incrementAndAnimate) + withObject:self waitUntilDone:NO]; + done = YES; + } + return done; +} + + +- (void) mountFile:(NSFileHandle *)handle withPath:(NSString *)path +{ + fileHandle = handle; + [fileHandle retain]; + [fileHandle seekToEndOfFile]; + unsigned long long offset = [fileHandle offsetInFile]; + [fileHandle seekToFileOffset:0]; + [progressIndicator setMaxValue:offset]; + [progressIndicator setDoubleValue:0]; + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + NSString *title = NSLocalizedStringFromTableInBundle(@"Unload", nil, bundle, @""); + if ([loadUnloadButton class] == [NSSegmentedControl class]) + [(NSSegmentedControl *) loadUnloadButton setLabel:title forSegment:0]; + else + [(NSButton *) loadUnloadButton setTitle:title]; + [loadUnloadButton unregisterAsFileDropTarget]; + if (onOffButton) + [onOffButton setEnabled:YES]; + [filenameField setStringValue:[[NSFileManager defaultManager] displayNameAtPath:path]]; + [filenameField setHidden:NO]; + [progressIndicator setHidden:NO]; +} + + +- (void) panelDidEnd:(NSSavePanel *)panel return:(int)ret context:(void *)context +{ + NSFileHandle *handle; + + if (ret == NSOKButton) { + NSString *path = [panel filename]; + if (kind == PAPER_TAPE_READER) + handle = [NSFileHandle fileHandleForReadingAtPath:path]; + else { + [[NSFileManager defaultManager] createFileAtPath:path contents:nil attributes:nil]; + handle = [NSFileHandle fileHandleForWritingAtPath:path]; + } + if (handle) + [self mountFile:handle withPath:path]; + else { + [panel close]; + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + NSAlert *alert = [[NSAlert alloc] init]; + [alert setMessageText:(kind == PAPER_TAPE_READER) ? + NSLocalizedStringFromTableInBundle( + @"Cannot open this paper tape file.", nil, bundle, @"") : + NSLocalizedStringFromTableInBundle( + @"Cannot create this paper tape file.", nil, bundle, @"")]; + [alert setInformativeText:path]; + [alert beginSheetModalForWindow:[loadUnloadButton window] + modalDelegate:nil didEndSelector:nil contextInfo:nil]; + [alert release]; + } + } + [[NSUserDefaults standardUserDefaults] setObject:[panel directory] forKey:LAST_FILE_PANEL_DIR_KEY]; +} + + +- (IBAction) loadUnloadClicked:(id)sender +{ + if (fileHandle) { + [fileHandle closeFile]; + [fileHandle release]; + fileHandle = nil; + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + NSString *title = NSLocalizedStringFromTableInBundle(@"Load", nil, bundle, @""); + if ([loadUnloadButton class] == [NSSegmentedControl class]) + [(NSSegmentedControl *) loadUnloadButton setLabel:title forSegment:0]; + else + [(NSButton *) loadUnloadButton setTitle:title]; + [loadUnloadButton setEnabled:onOffButton == nil ||[onOffButton isEnabled]]; + [loadUnloadButton registerAsFileDropTarget]; + if (onOffButton) { + [onOffButton setEnabled:NO]; + [onOffButton selectSegmentWithTag:PAPER_TAPE_OFF_TAG]; + } + [filenameField setHidden:YES]; + [progressIndicator setHidden:YES]; + } else { + NSSavePanel *panel = (kind == PAPER_TAPE_READER) ? + [NSOpenPanel openPanel] : [NSSavePanel savePanel]; + [panel beginSheetForDirectory: + [[NSUserDefaults standardUserDefaults] stringForKey:LAST_FILE_PANEL_DIR_KEY] + file:nil modalForWindow:[loadUnloadButton window] modalDelegate:self + didEndSelector:@selector(panelDidEnd:return:context:) contextInfo:nil]; + } +} + + +- (IBAction) onOffClicked:(id)sender +{ + if ([onOffButton selectedSegment] == PAPER_TAPE_ON_TAG) { + [loadUnloadButton setEnabled:NO]; + if (kind == PAPER_TAPE_READER) + [inputConsumer canContinueInput]; + } else { + [loadUnloadButton setEnabled:YES]; + [progressIndicator stopAnimation:sender]; + } +} + + +- (void) awakeFromNib +{ + kind = [loadUnloadButton tag]; + adjustToolbarControlForTiger (filenameField); + adjustToolbarControlForTiger (progressIndicator); + [loadUnloadButton registerAsFileDropTarget]; +} + + +#pragma mark FileDropControlTarget Protocol + + +- (BOOL) willAcceptFile:(NSString *)path +{ + NSFileHandle *handle = (kind == PAPER_TAPE_READER) ? + [NSFileHandle fileHandleForReadingAtPath:path] : + [NSFileHandle fileHandleForWritingAtPath:path]; + if (handle) { + [handle closeFile]; + // [handle release]; // dont'd release, it crashs + } + return handle != nil; +} + + +- (BOOL) acceptFile:(NSString *)path +{ + NSFileHandle *handle = nil; + if (kind == PAPER_TAPE_PUNCH) { + NSBundle *bundle = [NSBundle bundleForClass:[self class]]; + NSAlert *alert = [[NSAlert alloc] init]; + [alert setMessageText:[NSString stringWithFormat:NSLocalizedStringFromTableInBundle( + @"Do you really want to overwrite %C%@%C with the paper tape output?", + nil, bundle, @""), + UNICODE_LEFT_DOUBLEQUOTE, + [[NSFileManager defaultManager] displayNameAtPath:path], + UNICODE_RIGHT_DOUBLEQUOTE]]; + [alert setInformativeText:NSLocalizedStringFromTableInBundle( + @"The current content of the file will be lost.", nil, bundle, @"")]; + [[alert addButtonWithTitle:NSLocalizedStringFromTableInBundle( + @"Yes", nil, bundle, @"")] setKeyEquivalent:@"\r"]; + [[alert addButtonWithTitle:NSLocalizedStringFromTableInBundle( + @"No", nil, bundle, @"")] setKeyEquivalent:@"\e"]; + [alert setAlertStyle:NSCriticalAlertStyle]; + if ([alert runModal] == NSAlertFirstButtonReturn && + (handle = [NSFileHandle fileHandleForWritingAtPath:path])) + [handle truncateFileAtOffset:0]; + [alert release]; + } else + handle = [NSFileHandle fileHandleForReadingAtPath:path]; + if (handle) + [self mountFile:handle withPath:path]; + return handle != nil; +} + + +@end diff --git a/Utilities/PaperTapeProgressIndicator.h b/Utilities/PaperTapeProgressIndicator.h new file mode 100644 index 0000000..afa5aa3 --- /dev/null +++ b/Utilities/PaperTapeProgressIndicator.h @@ -0,0 +1,34 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PaperTapeProgressIndicator.h - Progress indicator for the paper tape reader and punch + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface PaperTapeProgressIndicator : NSProgressIndicator { +@private + BOOL isAnimating; + NSTimer *stopAnimationTimer; +} + +- (void) animateForSeconds:(NSTimeInterval)seconds; +- (void) incrementAndAnimate; + +@end diff --git a/Utilities/PaperTapeProgressIndicator.m b/Utilities/PaperTapeProgressIndicator.m new file mode 100644 index 0000000..364331d --- /dev/null +++ b/Utilities/PaperTapeProgressIndicator.m @@ -0,0 +1,82 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * PaperTapeProgressIndicator.m - Progress indicator for the paper tape reader and punch + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "PaperTapeProgressIndicator.h" + + +@interface NSProgressIndicator (HeartBeat) + +- (void) heartBeat:(id)sender; // Apple internal method for the animation + +@end + + +@implementation PaperTapeProgressIndicator + + +- (void) animateForSeconds:(NSTimeInterval)seconds +{ + [self startAnimation:self]; + if (stopAnimationTimer) + [stopAnimationTimer + setFireDate:[NSDate dateWithTimeIntervalSinceNow:seconds]]; + else + stopAnimationTimer = [NSTimer scheduledTimerWithTimeInterval:seconds + target:self selector:@selector(stopAnimation:) userInfo:nil repeats:NO]; +} + + +- (void) incrementAndAnimate +{ + [self incrementBy:1]; + [self animateForSeconds:1]; +} + + +- (void) startAnimation:(id)sender +{ + isAnimating = YES; + [super startAnimation:sender]; +} + + +- (void) stopAnimation:(id)sender +{ + isAnimating = NO; + [stopAnimationTimer invalidate]; + stopAnimationTimer = nil; + [super stopAnimation:sender]; +} + + +- (void) heartBeat:(id)sender +{ + if (isAnimating) + [super heartBeat:sender]; +} + + +@end diff --git a/Utilities/RegisterFormCell.h b/Utilities/RegisterFormCell.h new file mode 100644 index 0000000..e613182 --- /dev/null +++ b/Utilities/RegisterFormCell.h @@ -0,0 +1,37 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RegisterFormCell.h - NSFormCell subclass for PDP-8/E registers + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface RegisterFormCell : NSFormCell +{ +@private + id registerOwner; + SEL getRegisterValue; + SEL setRegisterValue; +} + +- (void) setupRegisterFor:(id)owner getRegisterValue:(SEL)getter setRegisterValue:(SEL)setter + changedNotificationName:(NSString *)notification + mask:(unsigned)mask base:(short)base; + +@end diff --git a/Utilities/RegisterFormCell.m b/Utilities/RegisterFormCell.m new file mode 100644 index 0000000..32ee662 --- /dev/null +++ b/Utilities/RegisterFormCell.m @@ -0,0 +1,97 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * RegisterFormCell.m - NSFormCell subclass for PDP-8/E registers + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "RegisterFormCell.h" +#import "OctalFormatter.h" +#import "Utilities.h" + + +@implementation RegisterFormCell + + +- (BOOL) control:(NSControl *)control textView:(NSTextView *)textView doCommandBySelector:(SEL)command +{ + if (command == @selector(cancelOperation:)) { + // ESC aborts editing of the cell + [control abortEditing]; + return YES; + } + return NO; +} + + +- (BOOL) control:(NSControl *)control didFailToFormatString:(NSString *)string + errorDescription:(NSString *)error +{ + NSRange range; + + NSAlert *alert = [[NSAlert alloc] init]; + + range.location = 0; + range.length = -1; + [[control currentEditor] setSelectedRange:range]; + [alert setMessageText:error]; + [alert beginSheetModalForWindow:[control window] + modalDelegate:nil didEndSelector:nil contextInfo:nil]; + [alert release]; + return NO; +} + + +- (void) controlTextDidEndEditing:(NSNotification *)notification +{ + [registerOwner performSelector:setRegisterValue withObject:(id)[self intValue]]; +} + + +- (void) notifyRegisterHasChanged:(NSNotification *)notification +{ + [self setIntValue:(unsigned)[registerOwner performSelector:getRegisterValue]]; +} + + +- (void) setupRegisterFor:(id)owner getRegisterValue:(SEL)getter setRegisterValue:(SEL)setter + changedNotificationName:(NSString *)notification + mask:(unsigned)mask base:(short)base +{ + NSAssert (base == 8, @"Currenty only base 8 is implemented for RegisterFormCell"); + [(NSForm *)[self controlView] setDelegate:self]; + [self setFormatter:[[[OctalFormatter alloc] initWithBitMask:mask wildcardAllowed:NO] autorelease]]; + [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(notifyRegisterHasChanged:) + name:notification object:nil]; + registerOwner = owner; + getRegisterValue = getter; + setRegisterValue = setter; + if (runningOnYosemiteOrNewer()) { + // with Helvetica Neue, the content digits are one pixel too small, so reset to Lucida Grande + [self setFont:[NSFont fontWithName:@"LucidaGrande" size:11]]; + // with Helvetica Neue, many titles are too long and characters are clipped, so reset to Lucida Grande + [self setTitleFont:[NSFont fontWithName:@"LucidaGrande" size:11]]; + } +} + + +@end diff --git a/Utilities/TableCornerView.h b/Utilities/TableCornerView.h new file mode 100644 index 0000000..d78fd47 --- /dev/null +++ b/Utilities/TableCornerView.h @@ -0,0 +1,35 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * TableCornerView.h - Status indicator and button corner view for a NSTableControl + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +@interface TableCornerView : NSControl +{ +@private + BOOL clickable; +} + +- (void) setImageNamed:(NSString *)name toolTip:(NSString *)toolTip; +- (BOOL) isClickable; +- (void) setClickable:(BOOL)flag; + +@end diff --git a/Utilities/TableCornerView.m b/Utilities/TableCornerView.m new file mode 100644 index 0000000..96e11ac --- /dev/null +++ b/Utilities/TableCornerView.m @@ -0,0 +1,167 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * TableCornerView.m - Status indicator and button corner view for a NSTableControl + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import + +#import "Utilities.h" +#import "TableCornerView.h" + + +@interface TableCornerCell : NSTableHeaderCell +{ +} +@end + + +@implementation TableCornerCell + + +- (void) setState:(int)state +{ + // ignore state setting caused by mouse klick, otherwise the cell switchs from white to gray + // send the action here because NSTableHeaderControl does not send any action + [NSApp sendAction:[self action] to:[self target] from:self]; +} + + +/* With Yosemie 10.10 14A389 and 10.10.1 14B25, there are some optical glitches with the TableCornerCell when it is + used with an image (initImageCell: and setImageNamed: methods) (Yosemite NSTableHeaderCell bugs?): + - the background is drawn in very light gray, not completely white (white only when the window is deactivated) + - the cell is not highlighted when clicked + - the left separator is not down, but the right one in the border of the scroll view (the borders appear + when you set scroll bars to always be visible in the General system preferences + Reported to Apple with bug ID 18848420, closed with the statement "this is the new look". + So we implement the correct Yosemite behaviour in the highlight:withFrame:inView and drawWithFram:inView: methods + These glitches are still present with 10.10.4, with a little different behaviour. (Even with Mavericks, there are + minor glitches: the right separator is drawn in the border of the scroll view.) The following implementation is + not absolute perfect, but the remaining glitches are not striking. +*/ + + +- (NSRect) framerect:(NSRect)frame +{ + NSRect rect; + rect.size = [[self image] size]; + unsigned width = frame.size.width; + if (width % 2 == 0) + width--; + rect.origin.x = (width - rect.size.width) / 2; + if (rect.origin.x >= 2) + rect.origin.x++; + rect.origin.y = (frame.size.height - rect.size.height) / 2; + return rect; +} + + +- (void) highlight:(BOOL)flag withFrame:(NSRect)frame inView:(NSView *)view +{ + // [super hightlight:NO ...] does not cause an unhighlight of the cell - Cocoa bug? + if (flag) { + if (runningOnYosemiteOrNewer()) { // else, there is no highlight of the wrongly gray background + // draw frame at the left (this is clipped when the column separator is visible) + [[NSColor secondarySelectedControlColor] set]; + NSRect rect = [self framerect:frame]; + rect.origin.x--; + rect.size.width++; + [NSBezierPath fillRect:rect]; + // draw content of the table corner view + [[NSColor controlHighlightColor] set]; + [NSBezierPath fillRect:[self framerect:frame]]; + [self drawWithFrame:frame inView:view]; + } else + [super highlight:YES withFrame:frame inView:view]; + } else { + [self drawWithFrame:frame inView:view]; + if (runningOnYosemiteOrNewer()) // when moving the cursor out of the frame with mouse key down + [view setNeedsDisplay:YES]; + } +} + + +- (void) drawWithFrame:(NSRect)frame inView:(NSView *)view +{ + if (runningOnYosemiteOrNewer()) { + // else the background is drawn in light gray and a separator is drawn at the right, not in the frame + [[NSColor secondarySelectedControlColor] set]; + [NSBezierPath fillRect:NSMakeRect(frame.origin.x, frame.origin.y, frame.size.width, 1)]; // bottom line + NSImage *image = [self image]; + if (image) + [image drawInRect:[self framerect:frame] fromRect:NSZeroRect + operation:NSCompositeSourceOver fraction:1]; + } else + [super drawWithFrame:frame inView:view]; +} + + +@end + + +@implementation TableCornerView + + +- (TableCornerView *) initWithFrame:(NSRect)frame +{ + if ((self = [super initWithFrame:frame])) { + [self setCell:[[TableCornerCell alloc] initImageCell:nil]]; + [self setClickable:NO]; + } + return self; +} + + +- (void) setImageNamed:(NSString *)name toolTip:(NSString *)toolTip +{ + [[self cell] setImage:[NSImage imageNamed:name]]; + [self setToolTip:toolTip]; +} + + +- (void) mouseDown:(NSEvent *)event +{ + if (clickable) + [super mouseDown:event]; +} + + +- (BOOL) isFlipped +// don't know why this is required - see http://zzot.net/2004/11/20/nstableheadercell/ +{ + return ! runningOnYosemiteOrNewer(); // see above for Yosemite drawing glitches + +} + + +- (BOOL) isClickable +{ + return clickable; +} + + +- (void) setClickable:(BOOL)flag +{ + clickable = flag; +} + + +@end diff --git a/Utilities/Unicode.h b/Utilities/Unicode.h new file mode 100644 index 0000000..87e6142 --- /dev/null +++ b/Utilities/Unicode.h @@ -0,0 +1,48 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Unicode.h - Some unicode character constants + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +/* Don't use Unicode string constants (concatenation of string constants using the UNICODE_..._UTF8 + defines) when compiling with Xcode 3.1 beta (iPhone SDK beta): with this version all Unicode strings + in a compilation unit are replaced with the first one. Reported to Apple with bug ID 5788599. */ + + +#define UNICODE_EM_DASH 0x2014 // — +#define UNICODE_EM_DASH_UTF8 "\xe2\x80\x94" // — + +#define UNICODE_LEFT_DOUBLEQUOTE 0x201c // “ +#define UNICODE_LEFT_DOUBLEQUOTE_UTF8 "\xe2\x80\x9c" // “ + +#define UNICODE_RIGHT_DOUBLEQUOTE 0x201d // ” +#define UNICODE_RIGHT_DOUBLEQUOTE_UTF8 "\xe2\x80\x9d" // ” + +#define UNICODE_MIDDLE_DOT 0x00b7 // · +#define UNICODE_MIDDLE_DOT_UTF8 "\xc2\xb7" // · + +#define UNICODE_BULLET 0x2022 // • +#define UNICODE_BULLET_UTF8 "\xe2\x80\xa2" // • + +#define UNICODE_DIAMOND 0x25c6 // ◆ +#define UNICODE_DIAMOND_UTF8 "\xe2\x97\x86" // ◆ + + diff --git a/Utilities/Utilities.c b/Utilities/Utilities.c new file mode 100644 index 0000000..59c806c --- /dev/null +++ b/Utilities/Utilities.c @@ -0,0 +1,96 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Utilities.c - Some general utilities and macros, esp. for Tiger compatibility + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +#import +#import + +#include "Utilities.h" + + +@interface NSProcessInfo (OSVersion) // available in NSProcessInfo.h since 10.10 + +typedef struct { + long majorVersion; + long minorVersion; + long patchVersion; +} NSOperatingSystemVersion; + +- (NSOperatingSystemVersion) operatingSystemVersion; + +@end + + +BOOL runningOnOSXVersion (long major, long minor, BOOL orBetter) +{ + if (NSAppKitVersionNumber < NSAppKitVersionNumber10_10) + return NO; // up to 10.10, we use the NSAppKitVersionNumber compare macros + NSOperatingSystemVersion vers = [[NSProcessInfo processInfo] operatingSystemVersion]; + return (vers.majorVersion == major && vers.minorVersion == minor) || + (orBetter && (vers.majorVersion > major || (vers.majorVersion == major && vers.minorVersion > minor))); +} + + +void adjustToolbarControlForTiger (NSView *view) +{ + if (runningOnTiger() && + [[[[(view) superview] superview] class] + isSubclassOfClass:NSClassFromString(@"NSToolbarItemViewer")]) { + NSPoint p = [(view) frame].origin; + p.x += (float) 2.0; + [(view) setFrameOrigin:p]; + } +} + + +void adjustTableHeaderForElCapitan (NSTableView *view) +// With El Capitan, the header of a table view is six pixel higher than with any OS X before. +// This El Capitan header adjustment causes scrolling anomalies in CPU memory view and in the +// memory inspector drawer, see [CPUMemoryViewControler updateVisibleMemoryRange] and +// [MemoryInspectorController visibleRange]. +{ + if (runningOnElCapitanOrNewer()) { + NSRect rect = [[view headerView] frame]; + rect.size.height -= 6; + [[view headerView] setFrame:rect]; + } +} + + +static mach_timebase_info_data_t timebaseInfo; + + +uint64_t nanoseconds2absolute (uint64_t nanoseconds) // see Technical Q&A QA1398 +{ + if (timebaseInfo.denom == 0) + mach_timebase_info (&timebaseInfo); + return nanoseconds * timebaseInfo.denom / timebaseInfo.numer; +} + + +uint64_t absolute2nanoseconds (uint64_t absolute) // see Technical Q&A QA1398 +{ + if (timebaseInfo.denom == 0) + mach_timebase_info (&timebaseInfo); + return absolute * timebaseInfo.numer / timebaseInfo.denom; +} diff --git a/Utilities/Utilities.h b/Utilities/Utilities.h new file mode 100644 index 0000000..25d3025 --- /dev/null +++ b/Utilities/Utilities.h @@ -0,0 +1,102 @@ +/* + * PDP-8/E Simulator + * + * Copyright © 1994-2015 Bernhard Baehr + * + * Utilities.h - Some general utilities and macros, esp. for Tiger compatibility + * + * This file is part of PDP-8/E Simulator. + * + * PDP-8/E Simulator 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 3 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, see . + */ + + +// Macro to print a log message when the code is compiled with asserts +#if defined(NS_BLOCK_ASSERTIONS) +#define LOG_ASSERTING() +#else +#define LOG_ASSERTING() NSLog (@"%@ - Compiled with assertions.", [self class]) +#endif + + +// Constants from NSApplication.h that are not in the 10.4 SDK +#define NSAppKitVersionNumber10_4 824 +#define NSAppKitVersionNumber10_5 949 +#define NSAppKitVersionNumber10_6 1038 +#define NSAppKitVersionNumber10_7 1138 +#define NSAppKitVersionNumber10_8 1187 +#define NSAppKitVersionNumber10_9 1265 +#define NSAppKitVersionNumber10_10 1343 // note 10.10.4 has NSAppKitVersionNumber == 1348.17 + +// for Yosemite and better, we don't rely on NSAppKitVersionNumber, but use [NSProcessInfo operatingSystemVersion] +BOOL runningOnOSXVersion (long major, long minor, BOOL orBetter); + +#define runningOnTiger() (floor(NSAppKitVersionNumber) == NSAppKitVersionNumber10_4) +#define runningOnTigerOrNewer() (NSAppKitVersionNumber >= NSAppKitVersionNumber10_4) +#define runningOnLeopard() (floor(NSAppKitVersionNumber) == NSAppKitVersionNumber10_5) +#define runningOnLeopardOrNewer() (NSAppKitVersionNumber >= NSAppKitVersionNumber10_5) +#define runningOnSnowLeopard() (floor(NSAppKitVersionNumber) == NSAppKitVersionNumber10_6) +#define runningOnSnowLeopardOrNewer() (NSAppKitVersionNumber >= NSAppKitVersionNumber10_6) +#define runningOnLion() (floor(NSAppKitVersionNumber) == NSAppKitVersionNumber10_7) +#define runningOnLionOrNewer() (NSAppKitVersionNumber >= NSAppKitVersionNumber10_7) +#define runningOnMountainLion() (floor(NSAppKitVersionNumber) == NSAppKitVersionNumber10_8) +#define runningOnMountainLionOrNewer() (NSAppKitVersionNumber >= NSAppKitVersionNumber10_8) +#define runningOnMavericks() (floor(NSAppKitVersionNumber) == NSAppKitVersionNumber10_9) +#define runningOnMavericksOrNewer() (NSAppKitVersionNumber >= NSAppKitVersionNumber10_9) +#define runningOnYosemite() runningOnOSXVersion(10, 10, NO) +#define runningOnYosemiteOrNewer() runningOnOSXVersion(10, 10, YES) +#define runningOnElCapitan() runningOnOSXVersion(10, 11, NO) +#define runningOnElCapitanOrNewer() runningOnOSXVersion(10, 11, YES) + + +void adjustToolbarControlForTiger (NSView *view); +void adjustTableHeaderForElCapitan (NSTableView *view); + + +#define NSAssertRunningOnMainThread() NSAssert ([NSThread isMainThread], @"Called from non-main thread") + + +#if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_5 +// NSCondition is available since 10.0 but missing in the headers until 10.5, see NSLock.h + +@interface NSCondition : NSObject +{ +@private + void *_priv; +} + +- (void) wait; +- (BOOL) waitUntilDate:(NSDate *)limit; +- (void) signal; +- (void) broadcast; + +@end + +#endif + + +// [[NSUserDefaults standardUserDefaults] stringForKey:LAST_FILE_PANEL_DIR_KEY] +// returns the default start directory for file dialogs +#define LAST_FILE_PANEL_DIR_KEY @"LastPanelDir" + + +// Minimum and maximum macro +#define min(a, b) ((a) < (b) ? (a) : (b)) +#define max(a, b) ((a) < (b) ? (b) : (a)) + + +// see Technical Q&A QA1398 +uint64_t nanoseconds2absolute (uint64_t nanoseconds); +uint64_t absolute2nanoseconds (uint64_t absolute); + diff --git a/pdp8e-simulator.xcodeproj/bb.mode1 b/pdp8e-simulator.xcodeproj/bb.mode1 new file mode 100644 index 0000000..dee1a47 --- /dev/null +++ b/pdp8e-simulator.xcodeproj/bb.mode1 @@ -0,0 +1,1637 @@ + + + + + ActivePerspectiveName + Project + AllowedModules + + + BundleLoadPath + + MaxInstances + n + Module + PBXSmartGroupTreeModule + Name + Groups and Files Outline View + + + BundleLoadPath + + MaxInstances + n + Module + PBXNavigatorGroup + Name + Editor + + + BundleLoadPath + + MaxInstances + n + Module + XCTaskListModule + Name + Task List + + + BundleLoadPath + + MaxInstances + n + Module + XCDetailModule + Name + File and Smart Group Detail Viewer + + + BundleLoadPath + + MaxInstances + 1 + Module + PBXBuildResultsModule + Name + Detailed Build Results Viewer + + + BundleLoadPath + + MaxInstances + 1 + Module + PBXProjectFindModule + Name + Project Batch Find Tool + + + BundleLoadPath + + MaxInstances + n + Module + PBXRunSessionModule + Name + Run Log + + + BundleLoadPath + + MaxInstances + n + Module + PBXBookmarksModule + Name + Bookmarks Tool + + + BundleLoadPath + + MaxInstances + n + Module + PBXClassBrowserModule + Name + Class Browser + + + BundleLoadPath + + MaxInstances + n + Module + PBXCVSModule + Name + Source Code Control Tool + + + BundleLoadPath + + MaxInstances + n + Module + PBXDebugBreakpointsModule + Name + Debug Breakpoints Tool + + + BundleLoadPath + + MaxInstances + n + Module + XCDockableInspector + Name + Inspector + + + BundleLoadPath + + MaxInstances + n + Module + PBXOpenQuicklyModule + Name + Open Quickly Tool + + + BundleLoadPath + + MaxInstances + 1 + Module + PBXDebugSessionModule + Name + Debugger + + + BundleLoadPath + + MaxInstances + 1 + Module + PBXDebugCLIModule + Name + Debug Console + + + Description + DefaultDescriptionKey + DockingSystemVisible + + Extension + mode1 + FavBarConfig + + PBXProjectModuleGUID + 218F4812085BA16600F01868 + XCBarModuleItemNames + + 1C08E77C0454961000C914BD + Errors and Warnings + 210F347C0BC79DEA00482109 + PluginFramework + 210F34810BC8F99F00482109 + Plugins + 21BC384B0BD5415500A37D35 + ASR33 + + XCBarModuleItems + + 21BC384B0BD5415500A37D35 + 210F34810BC8F99F00482109 + 210F347C0BC79DEA00482109 + 1C08E77C0454961000C914BD + + + FirstTimeWindowDisplayed + + Identifier + com.apple.perspectives.project.mode1 + MajorVersion + 31 + MinorVersion + 1 + Name + Default + Notifications + + OpenEditors + + PerspectiveWidths + + 946 + 300 + + Perspectives + + + ChosenToolbarItems + + active-target-popup + active-buildstyle-popup + action + NSToolbarFlexibleSpaceItem + buildOrClean + build-and-runOrDebug + build-and-debug + com.apple.ide.PBXToolbarStopButton + get-info + toggle-editor + NSToolbarFlexibleSpaceItem + com.apple.pbx.toolbar.searchfield + + ControllerClassBaseName + + IconName + WindowOfProjectWithEditor + Identifier + perspective.project + IsVertical + + Layout + + + BecomeActive + + ContentConfiguration + + PBXBottomSmartGroupGIDs + + 1C37FBAC04509CD000000102 + 1C37FAAC04509CD000000102 + 1C08E77C0454961000C914BD + 1C37FABC05509CD000000102 + 1C37FABC05539CD112110102 + E2644B35053B69B200211256 + 1C37FABC04509CD000100104 + 1CC0EA4004350EF90044410B + 1CC0EA4004350EF90041110B + 21B45D430BE343C000FB63A4 + + PBXProjectModuleGUID + 1CE0B1FE06471DED0097A5F4 + PBXProjectModuleLabel + Files + PBXProjectStructureProvided + yes + PBXSmartGroupTreeModuleColumnData + + PBXSmartGroupTreeModuleColumnWidthsKey + + 22 + 239 + + PBXSmartGroupTreeModuleColumnsKey_v4 + + TargetStatusColumn + MainColumn + + + PBXSmartGroupTreeModuleOutlineStateKey_v7 + + PBXSmartGroupTreeModuleOutlineStateExpansionKey + + 29B97314FDCFA39411CA2CEA + 21BC384B0BD5415500A37D35 + 2126BE0D09817D4B008BB678 + 210F347C0BC79DEA00482109 + 2109161609715798001F160B + 21F556130949FC9500DA4AB8 + 21CAB1F20876E7AE00E9005D + 080E96DDFE201D6D7F000001 + 210F34810BC8F99F00482109 + 21DC5BD909C8D398000F3908 + 29B97315FDCFA39411CA2CEA + 29B97317FDCFA39411CA2CEA + 2159F26E0869CE98002186B0 + 1C37FBAC04509CD000000102 + 1C37FAAC04509CD000000102 + 1CC0EA4004350EF90041110B + 21B45D430BE343C000FB63A4 + 2159F26E0869CE98002186B0 + + PBXSmartGroupTreeModuleOutlineStateSelectionKey + + + 4 + 1 + 0 + + + PBXSmartGroupTreeModuleOutlineStateVisibleRectKey + {{0, 0}, {261, 700}} + + PBXTopSmartGroupGIDs + + XCIncludePerspectivesSwitch + + XCSharingToken + com.apple.Xcode.GFSharingToken + + GeometryConfiguration + + Frame + {{0, 0}, {278, 718}} + GroupTreeTableConfiguration + + TargetStatusColumn + 22 + MainColumn + 239 + + RubberWindowFrame + 10 98 1006 780 0 0 1440 878 + + Module + PBXSmartGroupTreeModule + Proportion + 278pt + + + Dock + + + ContentConfiguration + + PBXProjectModuleGUID + 1CE0B20306471E060097A5F4 + PBXProjectModuleLabel + ASR33.m + PBXSplitModuleInNavigatorKey + + Split0 + + PBXProjectModuleGUID + 1CE0B20406471E060097A5F4 + PBXProjectModuleLabel + ASR33.m + _historyCapacity + 0 + bookmark + 21F5E5F60CD272320059D744 + history + + 21B048A20BA35E2A00F0F9A6 + 21229EEF0BA42AD500267020 + 21229EF00BA42AD500267020 + 21229EF10BA42AD500267020 + 21229EF20BA42AD500267020 + 21229EF30BA42AD500267020 + 21229EF40BA42AD500267020 + 21229EFC0BA42AD500267020 + 21229EFF0BA42AD500267020 + 21229F000BA42AD500267020 + 21229F010BA42AD500267020 + 21229F020BA42AD500267020 + 21229F060BA42AD500267020 + 21229F0B0BA42AD500267020 + 21229F0C0BA42AD500267020 + 21229F0E0BA42AD500267020 + 21229F0F0BA42AD500267020 + 21229F100BA42AD500267020 + 21229F110BA42AD500267020 + 21229F130BA42AD500267020 + 21229F140BA42AD500267020 + 21229F150BA42AD500267020 + 21229F160BA42AD500267020 + 21229F180BA42AD500267020 + 2122A0110BA452A300267020 + 2122A01A0BA452A300267020 + 2122A02E0BA452A300267020 + 21F9CB3F0BC59DDF004AEC89 + 21F9CB400BC59DDF004AEC89 + 210F35210BC9090000482109 + 210F35220BC9090000482109 + 210F35230BC9090000482109 + 210F35240BC9090000482109 + 210F35250BC9090000482109 + 210F35270BC9090000482109 + 21BC36750BD5083200A37D35 + 21BC37330BD50FAA00A37D35 + 21D1E4FC0BE1147500233E4B + 21B45DA90BE3489F00FB63A4 + 21B45DAB0BE3489F00FB63A4 + 2161C4D40BE53F670008E867 + 2161C60C0BE5FA6C0008E867 + 2161C6350BE5FCD20008E867 + 2161C6B50BE678B30008E867 + 2178687B0BF7A02400FC1DA7 + 211EF3B30BFC56CB00851FF1 + 2129B74A0C0B2FC600B91EE9 + 2187B04B0C97455C00CEE426 + 218980B30CA4262B0042F131 + 218980EE0CA428FF0042F131 + 218980EF0CA428FF0042F131 + 218980F20CA428FF0042F131 + 21BC47FE0CC2162000AA6F38 + 21BC488D0CC220F400AA6F38 + 217E49D60CC25B3F0014EDEE + 217E49D70CC25B3F0014EDEE + 217E4A590CC3A1020014EDEE + 217E4A6E0CC3A63A0014EDEE + 217E4A700CC3A63A0014EDEE + 217E4A710CC3A63A0014EDEE + 217E4AB10CC4F4360014EDEE + 217E4AB40CC4F4360014EDEE + 217E4B080CC5087D0014EDEE + 217E4B090CC5087D0014EDEE + 217E4B0A0CC5087D0014EDEE + 217E4B0B0CC5087D0014EDEE + 217E4B0C0CC5087D0014EDEE + 217E4B0D0CC5087D0014EDEE + 217E4B410CC51B110014EDEE + 217E4CB60CC54C1F0014EDEE + 217E4D930CC57BA90014EDEE + 217E4DC50CCB88C20014EDEE + 217E4DC60CCB88C20014EDEE + 217E4DC70CCB88C20014EDEE + 217E4DC80CCB88C20014EDEE + 217E4DC90CCB88C20014EDEE + 217E4DCA0CCB88C20014EDEE + 217E4DCB0CCB88C20014EDEE + 217E4DCC0CCB88C20014EDEE + 217E4DCD0CCB88C20014EDEE + 217E4DCE0CCB88C20014EDEE + 217E4DCF0CCB88C20014EDEE + 217E4DD00CCB88C20014EDEE + 217E4DD10CCB88C20014EDEE + 217E4DD20CCB88C20014EDEE + 217E4DD30CCB88C20014EDEE + 217E4DD40CCB88C20014EDEE + 217E4DD50CCB88C20014EDEE + 217E4DD60CCB88C20014EDEE + 217E4DD70CCB88C20014EDEE + 217E4DD80CCB88C20014EDEE + 217E4DD90CCB88C20014EDEE + 217E4DDA0CCB88C20014EDEE + 217E4DDB0CCB88C20014EDEE + 217E4DDC0CCB88C20014EDEE + 217E4DDD0CCB88C20014EDEE + 217E4DDE0CCB88C20014EDEE + 217E4DDF0CCB88C20014EDEE + 217E4DE00CCB88C20014EDEE + 217E4DE10CCB88C20014EDEE + 217E4DE20CCB88C20014EDEE + 217E4DE30CCB88C20014EDEE + 217E4DE40CCB88C20014EDEE + 217E4DE50CCB88C20014EDEE + 217E4DE60CCB88C20014EDEE + 217E4DE70CCB88C20014EDEE + 217E4DE80CCB88C20014EDEE + 217E4DE90CCB88C20014EDEE + 21F5E5EA0CD272320059D744 + 21F5E5EB0CD272320059D744 + 21F5E5EC0CD272320059D744 + 21F5E5ED0CD272320059D744 + 21F5E5EE0CD272320059D744 + 21F5E5EF0CD272320059D744 + + prevStack + + 211E89970B7A7B8F005673D4 + 211E89980B7A7B8F005673D4 + 211E89990B7A7B8F005673D4 + 211E899A0B7A7B8F005673D4 + 211E899B0B7A7B8F005673D4 + 21B047B60BA2EA6F00F0F9A6 + 21B047E80BA30BD000F0F9A6 + 21B0481C0BA31B6600F0F9A6 + 21B0482B0BA348AF00F0F9A6 + 21B0482C0BA348AF00F0F9A6 + 21B0482E0BA348AF00F0F9A6 + 21B048530BA34B0A00F0F9A6 + 21B048AF0BA35E2A00F0F9A6 + 21B048B00BA35E2A00F0F9A6 + 21B048B40BA35E2A00F0F9A6 + 21B048B70BA35E2A00F0F9A6 + 21B048B90BA35E2A00F0F9A6 + 21B048BD0BA35E2A00F0F9A6 + 21B048BF0BA35E2A00F0F9A6 + 21B048C10BA35E2A00F0F9A6 + 21B049040BA3673F00F0F9A6 + 21B049050BA3673F00F0F9A6 + 21B049080BA3673F00F0F9A6 + 21B049150BA368D300F0F9A6 + 21229F1D0BA42AD500267020 + 21229F1F0BA42AD500267020 + 21229F200BA42AD500267020 + 21229F230BA42AD500267020 + 21229F280BA42AD500267020 + 21229F2A0BA42AD500267020 + 21229F2B0BA42AD500267020 + 21229F2D0BA42AD500267020 + 21229F2E0BA42AD500267020 + 21229F2F0BA42AD500267020 + 21229F300BA42AD500267020 + 21229F310BA42AD500267020 + 21229F320BA42AD500267020 + 21229F330BA42AD500267020 + 21229F340BA42AD500267020 + 21229F350BA42AD500267020 + 21229F360BA42AD500267020 + 21229F370BA42AD500267020 + 21229F380BA42AD500267020 + 21229F390BA42AD500267020 + 21229F3A0BA42AD500267020 + 21229F3B0BA42AD500267020 + 21229F3C0BA42AD500267020 + 21229F3D0BA42AD500267020 + 21229F3E0BA42AD500267020 + 21229F3F0BA42AD500267020 + 21229F400BA42AD500267020 + 21229F410BA42AD500267020 + 21229F430BA42AD500267020 + 21229F440BA42AD500267020 + 21229F470BA42AD500267020 + 21229F490BA42AD500267020 + 21229F4B0BA42AD500267020 + 21229F4E0BA42AD500267020 + 21229F4F0BA42AD500267020 + 21229F500BA42AD500267020 + 21229F510BA42AD500267020 + 21229F520BA42AD500267020 + 21229F530BA42AD500267020 + 21229F540BA42AD500267020 + 21229F550BA42AD500267020 + 21229F560BA42AD500267020 + 21229F570BA42AD500267020 + 21229F580BA42AD500267020 + 21229F590BA42AD500267020 + 21229F5A0BA42AD500267020 + 21229F5B0BA42AD500267020 + 21229F5C0BA42AD500267020 + 21229F600BA42AD500267020 + 21229F610BA42AD500267020 + 21229F6C0BA42AD500267020 + 21229F700BA42AD500267020 + 21229F710BA42AD500267020 + 21229F720BA42AD500267020 + 21229F730BA42AD500267020 + 21229F740BA42AD500267020 + 21229F750BA42AD500267020 + 21229F760BA42AD500267020 + 21229F770BA42AD500267020 + 21229F780BA42AD500267020 + 21229F790BA42AD500267020 + 21229F7A0BA42AD500267020 + 21229F840BA42AD500267020 + 21F9CAB90BC5807E004AEC89 + 210F34AD0BC8FCD700482109 + 210F35F30BC90D2C00482109 + 21BC37CE0BD518D200A37D35 + 21287A300BDCECBE00F5FC00 + 2161C4940BE537070008E867 + 2161C4970BE537070008E867 + 2161C4B60BE539620008E867 + 2161C4B90BE539620008E867 + 2161C5A10BE5F0F50008E867 + 211EF1BC0BF8FFB400851FF1 + 211EF1BD0BF8FFB400851FF1 + 211EF1BE0BF8FFB400851FF1 + 211EF2310BF9071F00851FF1 + 211EF34B0BFB902300851FF1 + 211EF3910BFBB9A200851FF1 + 211EF3BA0BFC56CB00851FF1 + 211EF41C0BFC8AB600851FF1 + 2129B74C0C0B2FC600B91EE9 + 21BC482C0CC2177C00AA6F38 + 217E4A750CC3A63A0014EDEE + 217E4AC30CC4F4360014EDEE + 217E4B100CC5087D0014EDEE + 217E4D7F0CC573730014EDEE + 217E4D950CC57BA90014EDEE + 217E4E100CCB88C20014EDEE + 217E4E140CCB88C20014EDEE + 21F5E5F00CD272320059D744 + 21F5E5F10CD272320059D744 + 21F5E5F20CD272320059D744 + 21F5E5F30CD272320059D744 + 21F5E5F40CD272320059D744 + 21F5E5F50CD272320059D744 + + + SplitCount + 1 + + StatusBarVisibility + + + GeometryConfiguration + + Frame + {{0, 0}, {723, 713}} + RubberWindowFrame + 10 98 1006 780 0 0 1440 878 + + Module + PBXNavigatorGroup + Proportion + 713pt + + + ContentConfiguration + + PBXProjectModuleGUID + 1CE0B20506471E060097A5F4 + PBXProjectModuleLabel + Detail + + GeometryConfiguration + + Frame + {{0, 718}, {723, 0}} + RubberWindowFrame + 10 98 1006 780 0 0 1440 878 + + Module + XCDetailModule + Proportion + 0pt + + + Proportion + 723pt + + + Name + Project + ServiceClasses + + XCModuleDock + PBXSmartGroupTreeModule + XCModuleDock + PBXNavigatorGroup + XCDetailModule + + TableOfContents + + 21F5E5E30CCBB6330059D744 + 1CE0B1FE06471DED0097A5F4 + 21F5E5E40CCBB6330059D744 + 1CE0B20306471E060097A5F4 + 1CE0B20506471E060097A5F4 + + ToolbarConfiguration + xcode.toolbar.config.default + + + ChosenToolbarItems + + buildOrClean + build-and-runOrDebug + com.apple.ide.PBXToolbarStopButton + NSToolbarFlexibleSpaceItem + get-info + + ControllerClassBaseName + + IconName + WindowOfProject + Identifier + perspective.morph + IsVertical + + Layout + + + ContentConfiguration + + PBXBottomSmartGroupGIDs + + 1C37FBAC04509CD000000102 + 1C37FAAC04509CD000000102 + 1C08E77C0454961000C914BD + 1C37FABC05509CD000000102 + 1C37FABC05539CD112110102 + E2644B35053B69B200211256 + 1C37FABC04509CD000100104 + 1CC0EA4004350EF90044410B + 1CC0EA4004350EF90041110B + + PBXProjectModuleGUID + 11E0B1FE06471DED0097A5F4 + PBXProjectModuleLabel + Files + PBXProjectStructureProvided + yes + PBXSmartGroupTreeModuleColumnData + + PBXSmartGroupTreeModuleColumnWidthsKey + + 22 + 261 + + PBXSmartGroupTreeModuleColumnsKey_v4 + + TargetStatusColumn + MainColumn + + + PBXSmartGroupTreeModuleOutlineStateKey_v7 + + PBXSmartGroupTreeModuleOutlineStateExpansionKey + + 29B97314FDCFA39411CA2CEA + 2109161609715798001F160B + 21DC5BDC09C8D3E1000F3908 + 1C37FABC05509CD000000102 + + PBXSmartGroupTreeModuleOutlineStateSelectionKey + + + 10 + 8 + 3 + 0 + + + PBXSmartGroupTreeModuleOutlineStateVisibleRectKey + {{0, 0}, {283, 639}} + + PBXTopSmartGroupGIDs + + XCIncludePerspectivesSwitch + + XCSharingToken + com.apple.Xcode.GFSharingToken + + GeometryConfiguration + + Frame + {{0, 0}, {300, 657}} + GroupTreeTableConfiguration + + TargetStatusColumn + 22 + MainColumn + 261 + + + Module + PBXSmartGroupTreeModule + Proportion + 300pt + + + Name + Morph + PreferredWidth + 300 + ServiceClasses + + XCModuleDock + PBXSmartGroupTreeModule + + TableOfContents + + 21DC5C9A09CB4A12000F3908 + 11E0B1FE06471DED0097A5F4 + + ToolbarConfiguration + xcode.toolbar.config.default.short + + + PerspectivesBarVisible + + ShelfIsVisible + + SourceDescription + file at '/System/Library/PrivateFrameworks/DevToolsInterface.framework/Versions/A/Resources/XCPerspectivesSpecificationMode1.xcperspec' + StatusbarIsVisible + + TimeStamp + 0.0 + ToolbarDisplayMode + 2 + ToolbarIsVisible + + ToolbarSizeMode + 2 + Type + Perspectives + UpdateMessage + The Default Workspace in this version of Xcode now includes support to hide and show the detail view (what has been referred to as the "Metro-Morph" feature). You must discard your current Default Workspace settings and update to the latest Default Workspace in order to gain this feature. Do you wish to update to the latest Workspace defaults for project '%@'? + WindowJustification + 5 + WindowOrderList + + 1C0AD2B3069F1EA900FABCE6 + 218F483C085BB14400F01868 + /Users/bb/PDP-8/pdp8e-simulator/pdp8e-simulator.xcodeproj + + WindowString + 10 98 1006 780 0 0 1440 878 + WindowTools + + + FirstTimeWindowDisplayed + + Identifier + windowTool.build + IsVertical + + Layout + + + Dock + + + ContentConfiguration + + PBXProjectModuleGUID + 1CD0528F0623707200166675 + PBXProjectModuleLabel + + StatusBarVisibility + + + GeometryConfiguration + + Frame + {{0, 0}, {961, 362}} + RubberWindowFrame + 431 146 961 685 0 0 1440 878 + + Module + PBXNavigatorGroup + Proportion + 362pt + + + ContentConfiguration + + PBXBuildLogShowsTranscriptDefaultKey + {{0, 5}, {961, 272}} + PBXProjectModuleGUID + XCMainBuildResultsModuleGUID + PBXProjectModuleLabel + Build + XCBuildResultsTrigger_Collapse + 1021 + XCBuildResultsTrigger_Open + 1011 + + GeometryConfiguration + + Frame + {{0, 367}, {961, 277}} + RubberWindowFrame + 431 146 961 685 0 0 1440 878 + + Module + PBXBuildResultsModule + Proportion + 277pt + + + Proportion + 644pt + + + Name + Build Results + ServiceClasses + + PBXBuildResultsModule + + StatusbarIsVisible + + TableOfContents + + 218F483C085BB14400F01868 + 21F5E5E50CCBB6330059D744 + 1CD0528F0623707200166675 + XCMainBuildResultsModuleGUID + + ToolbarConfiguration + xcode.toolbar.config.build + WindowString + 431 146 961 685 0 0 1440 878 + WindowToolGUID + 218F483C085BB14400F01868 + WindowToolIsVisible + + + + FirstTimeWindowDisplayed + + Identifier + windowTool.debugger + IsVertical + + Layout + + + Dock + + + ContentConfiguration + + Debugger + + HorizontalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {436, 331}} + {{436, 0}, {489, 331}} + + + VerticalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {925, 331}} + {{0, 331}, {925, 308}} + + + + LauncherConfigVersion + 8 + PBXProjectModuleGUID + 1C162984064C10D400B95A72 + PBXProjectModuleLabel + Debug - GLUTExamples (Underwater) + + GeometryConfiguration + + DebugConsoleDrawerSize + {100, 120} + DebugConsoleVisible + None + DebugConsoleWindowFrame + {{200, 200}, {500, 300}} + DebugSTDIOWindowFrame + {{200, 200}, {500, 300}} + Frame + {{0, 0}, {925, 639}} + RubberWindowFrame + 177 198 925 680 0 0 1440 878 + + Module + PBXDebugSessionModule + Proportion + 639pt + + + Proportion + 639pt + + + Name + Debugger + ServiceClasses + + PBXDebugSessionModule + + StatusbarIsVisible + + TableOfContents + + 1CD10A99069EF8BA00B06720 + 2129B6F30C0B1B4A00B91EE9 + 1C162984064C10D400B95A72 + 2129B6F40C0B1B4A00B91EE9 + 2129B6F50C0B1B4A00B91EE9 + 2129B6F60C0B1B4A00B91EE9 + 2129B6F70C0B1B4A00B91EE9 + 2129B6F80C0B1B4A00B91EE9 + 2129B6F90C0B1B4A00B91EE9 + + ToolbarConfiguration + xcode.toolbar.config.debug + WindowString + 177 198 925 680 0 0 1440 878 + WindowToolGUID + 1CD10A99069EF8BA00B06720 + WindowToolIsVisible + + + + FirstTimeWindowDisplayed + + Identifier + windowTool.find + IsVertical + + Layout + + + Dock + + + Dock + + + ContentConfiguration + + PBXProjectModuleGUID + 1CDD528C0622207200134675 + PBXProjectModuleLabel + + StatusBarVisibility + + + GeometryConfiguration + + Frame + {{0, 0}, {781, 212}} + RubberWindowFrame + 580 224 781 470 0 0 1440 878 + + Module + PBXNavigatorGroup + Proportion + 781pt + + + Proportion + 212pt + + + BecomeActive + + ContentConfiguration + + PBXProjectModuleGUID + 1CD0528E0623707200166675 + PBXProjectModuleLabel + Project Find + + GeometryConfiguration + + Frame + {{0, 217}, {781, 212}} + RubberWindowFrame + 580 224 781 470 0 0 1440 878 + + Module + PBXProjectFindModule + Proportion + 212pt + + + Proportion + 429pt + + + Name + Project Find + ServiceClasses + + PBXProjectFindModule + + StatusbarIsVisible + + TableOfContents + + 1C530D57069F1CE1000CFCEE + 2161C5460BE5EBB90008E867 + 2161C5470BE5EBB90008E867 + 1CDD528C0622207200134675 + 1CD0528E0623707200166675 + + WindowString + 580 224 781 470 0 0 1440 878 + WindowToolGUID + 1C530D57069F1CE1000CFCEE + WindowToolIsVisible + + + + Identifier + MENUSEPARATOR + + + FirstTimeWindowDisplayed + + Identifier + windowTool.debuggerConsole + IsVertical + + Layout + + + Dock + + + ContentConfiguration + + PBXProjectModuleGUID + 1C78EAAC065D492600B07095 + PBXProjectModuleLabel + Debugger Console + + GeometryConfiguration + + Frame + {{0, 0}, {631, 367}} + RubberWindowFrame + 784 135 631 408 0 0 1440 878 + + Module + PBXDebugCLIModule + Proportion + 367pt + + + Proportion + 367pt + + + Name + Debugger Console + ServiceClasses + + PBXDebugCLIModule + + StatusbarIsVisible + + TableOfContents + + 21AE274D0864ABA9007C009E + 2129B6FC0C0B1C5D00B91EE9 + 1C78EAAC065D492600B07095 + + WindowString + 784 135 631 408 0 0 1440 878 + WindowToolGUID + 21AE274D0864ABA9007C009E + WindowToolIsVisible + + + + FirstTimeWindowDisplayed + + Identifier + windowTool.run + IsVertical + + Layout + + + Dock + + + ContentConfiguration + + LauncherConfigVersion + 3 + PBXProjectModuleGUID + 1CD0528B0623707200166675 + PBXProjectModuleLabel + Run + Runner + + HorizontalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {367, 168}} + {{0, 173}, {367, 270}} + + + VerticalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {406, 443}} + {{411, 0}, {517, 443}} + + + + + GeometryConfiguration + + Frame + {{0, 0}, {610, 228}} + RubberWindowFrame + 794 107 610 269 0 0 1440 878 + + Module + PBXRunSessionModule + Proportion + 228pt + + + Proportion + 228pt + + + Name + Run Log + ServiceClasses + + PBXRunSessionModule + + StatusbarIsVisible + + TableOfContents + + 1C0AD2B3069F1EA900FABCE6 + 21F5E5E60CCBB6330059D744 + 1CD0528B0623707200166675 + 21F5E5E70CCBB6330059D744 + + ToolbarConfiguration + xcode.toolbar.config.run + WindowString + 794 107 610 269 0 0 1440 878 + WindowToolGUID + 1C0AD2B3069F1EA900FABCE6 + WindowToolIsVisible + + + + Identifier + windowTool.scm + Layout + + + Dock + + + ContentConfiguration + + PBXProjectModuleGUID + 1C78EAB2065D492600B07095 + PBXProjectModuleLabel + <No Editor> + PBXSplitModuleInNavigatorKey + + Split0 + + PBXProjectModuleGUID + 1C78EAB3065D492600B07095 + + SplitCount + 1 + + StatusBarVisibility + 1 + + GeometryConfiguration + + Frame + {{0, 0}, {452, 0}} + RubberWindowFrame + 743 379 452 308 0 0 1280 1002 + + Module + PBXNavigatorGroup + Proportion + 0pt + + + BecomeActive + 1 + ContentConfiguration + + PBXProjectModuleGUID + 1CD052920623707200166675 + PBXProjectModuleLabel + SCM + + GeometryConfiguration + + ConsoleFrame + {{0, 259}, {452, 0}} + Frame + {{0, 7}, {452, 259}} + RubberWindowFrame + 743 379 452 308 0 0 1280 1002 + TableConfiguration + + Status + 30 + FileName + 199 + Path + 197.09500122070312 + + TableFrame + {{0, 0}, {452, 250}} + + Module + PBXCVSModule + Proportion + 262pt + + + Proportion + 266pt + + + Name + SCM + ServiceClasses + + PBXCVSModule + + StatusbarIsVisible + 1 + TableOfContents + + 1C78EAB4065D492600B07095 + 1C78EAB5065D492600B07095 + 1C78EAB2065D492600B07095 + 1CD052920623707200166675 + + ToolbarConfiguration + xcode.toolbar.config.scm + WindowString + 743 379 452 308 0 0 1280 1002 + + + FirstTimeWindowDisplayed + + Identifier + windowTool.breakpoints + IsVertical + + Layout + + + Dock + + + ContentConfiguration + + PBXBottomSmartGroupGIDs + + 1C77FABC04509CD000000102 + + PBXProjectModuleGUID + 1CE0B1FE06471DED0097A5F4 + PBXProjectModuleLabel + Files + PBXProjectStructureProvided + no + PBXSmartGroupTreeModuleColumnData + + PBXSmartGroupTreeModuleColumnWidthsKey + + 168 + + PBXSmartGroupTreeModuleColumnsKey_v4 + + MainColumn + + + PBXSmartGroupTreeModuleOutlineStateKey_v7 + + PBXSmartGroupTreeModuleOutlineStateExpansionKey + + 1C77FABC04509CD000000102 + + PBXSmartGroupTreeModuleOutlineStateSelectionKey + + + 0 + + + PBXSmartGroupTreeModuleOutlineStateVisibleRectKey + {{0, 0}, {168, 350}} + + PBXTopSmartGroupGIDs + + XCIncludePerspectivesSwitch + + + GeometryConfiguration + + Frame + {{0, 0}, {185, 368}} + GroupTreeTableConfiguration + + MainColumn + 168 + + RubberWindowFrame + 256 104 744 409 0 0 1056 770 + + Module + PBXSmartGroupTreeModule + Proportion + 185pt + + + BecomeActive + + ContentConfiguration + + PBXProjectModuleGUID + 1CA1AED706398EBD00589147 + PBXProjectModuleLabel + Detail + + GeometryConfiguration + + Frame + {{190, 0}, {554, 368}} + RubberWindowFrame + 256 104 744 409 0 0 1056 770 + + Module + XCDetailModule + Proportion + 554pt + + + Proportion + 368pt + + + MajorVersion + 2 + MinorVersion + 0 + Name + Breakpoints + ServiceClasses + + PBXSmartGroupTreeModule + XCDetailModule + + StatusbarIsVisible + + TableOfContents + + 21CAB18D0876C92D00E9005D + 21CAB18E0876C92D00E9005D + 1CE0B1FE06471DED0097A5F4 + 1CA1AED706398EBD00589147 + + ToolbarConfiguration + xcode.toolbar.config.breakpoints + WindowString + 256 104 744 409 0 0 1056 770 + WindowToolGUID + 21CAB18D0876C92D00E9005D + WindowToolIsVisible + + + + Identifier + windowTool.debugAnimator + Layout + + + Dock + + + Module + PBXNavigatorGroup + Proportion + 100% + + + Proportion + 100% + + + Name + Debug Visualizer + ServiceClasses + + PBXNavigatorGroup + + StatusbarIsVisible + 1 + ToolbarConfiguration + xcode.toolbar.config.debugAnimator + WindowString + 100 100 700 500 0 0 1280 1002 + + + Identifier + windowTool.bookmarks + Layout + + + Dock + + + Module + PBXBookmarksModule + Proportion + 100% + + + Proportion + 100% + + + Name + Bookmarks + ServiceClasses + + PBXBookmarksModule + + StatusbarIsVisible + 0 + WindowString + 538 42 401 187 0 0 1280 1002 + + + FirstTimeWindowDisplayed + + Identifier + windowTool.classBrowser + IsVertical + + Layout + + + Dock + + + ContentConfiguration + + OptionsSetName + Hierarchy, all classes + PBXProjectModuleGUID + 1CA6456E063B45B4001379D8 + PBXProjectModuleLabel + Class Browser - NSTextView + + GeometryConfiguration + + ClassesFrame + {{0, 0}, {622, 220}} + ClassesTreeTableConfiguration + + PBXClassNameColumnIdentifier + 208 + PBXClassBookColumnIdentifier + 22 + + Frame + {{0, 0}, {874, 608}} + MembersFrame + {{0, 225}, {622, 383}} + MembersTreeTableConfiguration + + PBXMemberTypeIconColumnIdentifier + 22 + PBXMemberNameColumnIdentifier + 216 + PBXMemberTypeColumnIdentifier + 345 + PBXMemberBookColumnIdentifier + 22 + + RubberWindowFrame + 108 120 874 628 0 0 1056 770 + + Module + PBXClassBrowserModule + Proportion + 608pt + + + Proportion + 608pt + + + Name + Class Browser + ServiceClasses + + PBXClassBrowserModule + + StatusbarIsVisible + + TableOfContents + + 21DC5D1109CB8B23000F3908 + 21DC5D1209CB8B23000F3908 + 1CA6456E063B45B4001379D8 + + ToolbarConfiguration + xcode.toolbar.config.classbrowser + WindowString + 108 120 874 628 0 0 1056 770 + WindowToolGUID + 21DC5D1109CB8B23000F3908 + WindowToolIsVisible + + + + + diff --git a/pdp8e-simulator.xcodeproj/bb.perspective b/pdp8e-simulator.xcodeproj/bb.perspective new file mode 100644 index 0000000..51a71b2 --- /dev/null +++ b/pdp8e-simulator.xcodeproj/bb.perspective @@ -0,0 +1,1482 @@ + + + + + ActivePerspectiveName + Project + AllowedModules + + + BundleLoadPath + + MaxInstances + n + Module + PBXSmartGroupTreeModule + Name + Groups and Files Outline View + + + BundleLoadPath + + MaxInstances + n + Module + PBXNavigatorGroup + Name + Editor + + + BundleLoadPath + + MaxInstances + n + Module + XCTaskListModule + Name + Task List + + + BundleLoadPath + + MaxInstances + n + Module + XCDetailModule + Name + File and Smart Group Detail Viewer + + + BundleLoadPath + + MaxInstances + 1 + Module + PBXBuildResultsModule + Name + Detailed Build Results Viewer + + + BundleLoadPath + + MaxInstances + 1 + Module + PBXProjectFindModule + Name + Project Batch Find Tool + + + BundleLoadPath + + MaxInstances + n + Module + PBXRunSessionModule + Name + Run Log + + + BundleLoadPath + + MaxInstances + n + Module + PBXBookmarksModule + Name + Bookmarks Tool + + + BundleLoadPath + + MaxInstances + n + Module + PBXClassBrowserModule + Name + Class Browser + + + BundleLoadPath + + MaxInstances + n + Module + PBXCVSModule + Name + Source Code Control Tool + + + BundleLoadPath + + MaxInstances + n + Module + PBXDebugBreakpointsModule + Name + Debug Breakpoints Tool + + + BundleLoadPath + + MaxInstances + n + Module + XCDockableInspector + Name + Inspector + + + BundleLoadPath + + MaxInstances + n + Module + PBXOpenQuicklyModule + Name + Open Quickly Tool + + + BundleLoadPath + + MaxInstances + 1 + Module + PBXDebugSessionModule + Name + Debugger + + + BundleLoadPath + + MaxInstances + 1 + Module + PBXDebugCLIModule + Name + Debug Console + + + Description + AIODescriptionKey + DockingSystemVisible + + Extension + perspective + FavBarConfig + + PBXProjectModuleGUID + 21AE0EF1085B43480051FF07 + XCBarModuleItemNames + + XCBarModuleItems + + + FirstTimeWindowDisplayed + + Identifier + com.apple.perspectives.project.default + MajorVersion + 33 + MinorVersion + 0 + Name + All-In-One + Notifications + + OpenEditors + + PerspectiveWidths + + 963 + 963 + 963 + + Perspectives + + + ChosenToolbarItems + + XCToolbarPerspectiveControl + active-target-popup + action + NSToolbarFlexibleSpaceItem + buildOrClean + build-and-runOrDebug + com.apple.ide.PBXToolbarStopButton + clean-target + clean + get-info + toggle-editor + Quick Model + NSToolbarFlexibleSpaceItem + com.apple.pbx.toolbar.searchfield + + ControllerClassBaseName + + IconName + WindowOfProject + Identifier + perspective.project + IsVertical + + Layout + + + ContentConfiguration + + PBXBottomSmartGroupGIDs + + 1C37FBAC04509CD000000102 + 1C37FAAC04509CD000000102 + 1C08E77C0454961000C914BD + 1C37FABC05509CD000000102 + 1C37FABC05539CD112110102 + E2644B35053B69B200211256 + 1C37FABC04509CD000100104 + 1CC0EA4004350EF90044410B + 1CC0EA4004350EF90041110B + 1C77FABC04509CD000000102 + + PBXProjectModuleGUID + 1CA23ED40692098700951B8B + PBXProjectModuleLabel + Files + PBXProjectStructureProvided + yes + PBXSmartGroupTreeModuleColumnData + + PBXSmartGroupTreeModuleColumnWidthsKey + + 219 + + PBXSmartGroupTreeModuleColumnsKey_v4 + + MainColumn + + + PBXSmartGroupTreeModuleOutlineStateKey_v7 + + PBXSmartGroupTreeModuleOutlineStateExpansionKey + + 29B97314FDCFA39411CA2CEA + 2109161609715798001F160B + 21F556130949FC9500DA4AB8 + 29B97317FDCFA39411CA2CEA + 2144299F09EAE8B800271635 + 214429A009EAE8B800271635 + + PBXSmartGroupTreeModuleOutlineStateSelectionKey + + + 54 + 46 + 45 + 15 + 3 + 0 + + + PBXSmartGroupTreeModuleOutlineStateVisibleRectKey + {{0, 494}, {219, 713}} + + PBXTopSmartGroupGIDs + + XCIncludePerspectivesSwitch + + + GeometryConfiguration + + Frame + {{0, 0}, {236, 731}} + GroupTreeTableConfiguration + + MainColumn + 219 + + RubberWindowFrame + 10 87 963 772 0 0 1440 878 + + Module + PBXSmartGroupTreeModule + Proportion + 236pt + + + Dock + + + BecomeActive + + ContentConfiguration + + PBXProjectModuleGUID + 21AE0EEC085B43480051FF07 + PBXProjectModuleLabel + MemoryInspectorOS8Packed8BitASCII.m + PBXSplitModuleInNavigatorKey + + Split0 + + PBXProjectModuleGUID + 21AE0EED085B43480051FF07 + PBXProjectModuleLabel + MemoryInspectorOS8Packed8BitASCII.m + _historyCapacity + 0 + bookmark + 216D89FB0ACC5F200099A5AA + history + + 217A3E080A93849C0033839E + 21D4DE500A98FB3700F8FAED + 21D4DE510A98FB3700F8FAED + 21D4DE870A99EE5900F8FAED + 21D4DE890A99EE5900F8FAED + 21D4DE8F0A99EE8E00F8FAED + 21D4DE9A0A9A022E00F8FAED + 21D4DEB60A9A059D00F8FAED + 21D4DEB70A9A059D00F8FAED + 21D4DEB80A9A059D00F8FAED + 216D89FA0ACC5F200099A5AA + 216D89F90ACC5F1A0099A5AA + + prevStack + + 217A3E0F0A93849C0033839E + 217A3E100A93849C0033839E + 217A3E120A93849C0033839E + 217A3E880A95FEE50033839E + 21D4DE3D0A98E09A00F8FAED + 21D4DE3F0A98E09A00F8FAED + 21D4DE410A98E09A00F8FAED + 21D4DE580A98FB3700F8FAED + 21D4DE630A98FB3700F8FAED + 21D4DE8C0A99EE5900F8FAED + 216D89F80ACC5F1A0099A5AA + + + SplitCount + 1 + + StatusBarVisibility + + XCSharingToken + com.apple.Xcode.CommonNavigatorGroupSharingToken + + GeometryConfiguration + + Frame + {{0, 0}, {722, 726}} + RubberWindowFrame + 10 87 963 772 0 0 1440 878 + + Module + PBXNavigatorGroup + Proportion + 726pt + + + Proportion + 0pt + Tabs + + + ContentConfiguration + + PBXProjectModuleGUID + 1CA23EDF0692099D00951B8B + PBXProjectModuleLabel + Detail + + GeometryConfiguration + + Frame + {{10, 27}, {722, -27}} + RubberWindowFrame + 10 87 963 772 0 0 1440 878 + + Module + XCDetailModule + + + ContentConfiguration + + PBXProjectModuleGUID + 1CA23EE00692099D00951B8B + PBXProjectModuleLabel + Project Find + + GeometryConfiguration + + Frame + {{10, 31}, {603, 297}} + + Module + PBXProjectFindModule + + + ContentConfiguration + + PBXProjectModuleGUID + 1CA23EE10692099D00951B8B + PBXProjectModuleLabel + SCM Results + + GeometryConfiguration + + Frame + {{10, 31}, {603, 297}} + + Module + PBXCVSModule + + + + + Proportion + 722pt + + + Name + Project + ServiceClasses + + XCModuleDock + PBXSmartGroupTreeModule + XCModuleDock + PBXNavigatorGroup + XCDockableTabModule + XCDetailModule + PBXProjectFindModule + PBXCVSModule + + TableOfContents + + 216D89EE0ACC5E820099A5AA + 1CA23ED40692098700951B8B + 216D89EF0ACC5E820099A5AA + 21AE0EEC085B43480051FF07 + 216D89F00ACC5E820099A5AA + 1CA23EDF0692099D00951B8B + 1CA23EE00692099D00951B8B + 1CA23EE10692099D00951B8B + + ToolbarConfiguration + xcode.toolbar.config.default + + + ChosenToolbarItems + + XCToolbarPerspectiveControl + NSToolbarSeparatorItem + active-target-popup + active-executable-popup + active-buildstyle-popup + NSToolbarFlexibleSpaceItem + clean-target + clean + build + build-and-run + run + debug + + ControllerClassBaseName + + IconName + BuildTabIcon + Identifier + perspective.build + IsVertical + + Layout + + + ContentConfiguration + + PBXBottomSmartGroupGIDs + + PBXProjectModuleGUID + 1CA23EE50692099D00951B8B + PBXProjectModuleLabel + Files + PBXProjectStructureProvided + yes + PBXSmartGroupTreeModuleColumnData + + PBXSmartGroupTreeModuleColumnWidthsKey + + 217 + + PBXSmartGroupTreeModuleColumnsKey_v4 + + MainColumn + + + PBXSmartGroupTreeModuleOutlineStateKey_v7 + + PBXSmartGroupTreeModuleOutlineStateExpansionKey + + 29B97314FDCFA39411CA2CEA + 2126BE0D09817D4B008BB678 + 2109160309715677001F160B + 2109161609715798001F160B + 21DC5BDC09C8D3E1000F3908 + 29B97317FDCFA39411CA2CEA + 2144299F09EAE8B800271635 + 214429A009EAE8B800271635 + 216D89C30ACC5A900099A5AA + 216D89C40ACC5A900099A5AA + 29B97323FDCFA39411CA2CEA + 19C28FACFE9D520D11CA2CBB + + PBXSmartGroupTreeModuleOutlineStateSelectionKey + + + 24 + 18 + 13 + 0 + + + PBXSmartGroupTreeModuleOutlineStateVisibleRectKey + {{0, 4}, {217, 713}} + + PBXTopSmartGroupGIDs + + XCIncludePerspectivesSwitch + + + GeometryConfiguration + + Frame + {{0, 0}, {234, 731}} + GroupTreeTableConfiguration + + MainColumn + 217 + + + Module + PBXSmartGroupTreeModule + Proportion + 234pt + + + Dock + + + ContentConfiguration + + PBXProjectModuleGUID + 21AE0EEC085B43480051FF07 + PBXProjectModuleLabel + MemoryInspectorOS8Packed8BitASCII.m + PBXSplitModuleInNavigatorKey + + Split0 + + PBXProjectModuleGUID + 21AE0EED085B43480051FF07 + PBXProjectModuleLabel + MemoryInspectorOS8Packed8BitASCII.m + _historyCapacity + 0 + bookmark + 216D89FC0ACC5F200099A5AA + history + + 217A3E080A93849C0033839E + 21D4DDCD0A96365800F8FAED + 21D4DE2E0A98E09A00F8FAED + 21D4DE340A98E09A00F8FAED + 21D4DEC50A9A062800F8FAED + 21D4DEC80A9A0F5900F8FAED + 21D4DECD0A9A12B600F8FAED + 21D4DED60A9A15BC00F8FAED + 216D89E30ACC5DDF0099A5AA + 216D89E40ACC5DDF0099A5AA + 216D89F60ACC5F1A0099A5AA + 216D89F70ACC5F1A0099A5AA + + prevStack + + 217A3E0F0A93849C0033839E + 217A3E100A93849C0033839E + 217A3E120A93849C0033839E + 217A3E880A95FEE50033839E + 21D4DE390A98E09A00F8FAED + 21D4DE3D0A98E09A00F8FAED + 21D4DE3F0A98E09A00F8FAED + 21D4DE410A98E09A00F8FAED + 21D4DE580A98FB3700F8FAED + 21D4DE8C0A99EE5900F8FAED + 216D89E60ACC5DDF0099A5AA + 216D89E70ACC5DDF0099A5AA + 216D89F80ACC5F1A0099A5AA + + + SplitCount + 1 + + StatusBarVisibility + + XCSharingToken + com.apple.Xcode.CommonNavigatorGroupSharingToken + + GeometryConfiguration + + Frame + {{0, 0}, {724, 612}} + + Module + PBXNavigatorGroup + Proportion + 612pt + + + Proportion + 114pt + Tabs + + + ContentConfiguration + + PBXProjectModuleGUID + XCMainBuildResultsModuleGUID + PBXProjectModuleLabel + Build + XCBuildResultsTrigger_Collapse + 1021 + XCBuildResultsTrigger_Open + 1011 + + GeometryConfiguration + + Frame + {{10, 27}, {724, 301}} + + Module + PBXBuildResultsModule + + + ContentConfiguration + + LauncherConfigVersion + 3 + PBXProjectModuleGUID + 1CA23EE80692099D00951B8B + PBXProjectModuleLabel + Run + Runner + + HorizontalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {367, 168}} + {{0, 173}, {367, 270}} + + + VerticalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {406, 443}} + {{411, 0}, {517, 443}} + + + + + GeometryConfiguration + + Frame + {{10, 27}, {724, 87}} + + Module + PBXRunSessionModule + + + + + Proportion + 724pt + + + Name + Build + ServiceClasses + + XCModuleDock + PBXSmartGroupTreeModule + XCModuleDock + PBXNavigatorGroup + XCDockableTabModule + PBXBuildResultsModule + PBXRunSessionModule + XCConsole + + TableOfContents + + 216D89F20ACC5E820099A5AA + 1CA23EE50692099D00951B8B + 216D89F30ACC5E820099A5AA + 21AE0EEC085B43480051FF07 + 216D89F40ACC5E820099A5AA + XCMainBuildResultsModuleGUID + 1CA23EE80692099D00951B8B + 216D89F50ACC5E820099A5AA + + ToolbarConfiguration + xcode.toolbar.config.buildAndRun + + + ChosenToolbarItems + + XCToolbarPerspectiveControl + NSToolbarSeparatorItem + build-and-debug + debug + NSToolbarFlexibleSpaceItem + debugger-fix-and-continue + NSToolbarSpaceItem + debugger-restart-executable + debugger-pause + debugger-continue + debugger-step-over + debugger-step-into + debugger-step-out + NSToolbarFlexibleSpaceItem + com.apple.ide.XCBreakpointsToolbarItem + servicesModulebreakpoints + debugger-show-console-window + + ControllerClassBaseName + PBXDebugSessionModule + IconName + DebugTabIcon + Identifier + perspective.debug + IsVertical + + Layout + + + ContentConfiguration + + PBXProjectModuleGUID + 1CCC7628064C1048000F2A68 + PBXProjectModuleLabel + Debugger Console + + GeometryConfiguration + + Frame + {{0, 0}, {963, 283}} + + Module + PBXDebugCLIModule + Proportion + 283pt + + + ContentConfiguration + + Debugger + + HorizontalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {469, 215}} + {{469, 0}, {494, 215}} + + + VerticalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {963, 215}} + {{0, 215}, {963, 228}} + + + + LauncherConfigVersion + 8 + PBXProjectModuleGUID + 1CCC7629064C1048000F2A68 + PBXProjectModuleLabel + Debug + + GeometryConfiguration + + DebugConsoleDrawerSize + {100, 120} + DebugConsoleVisible + None + DebugConsoleWindowFrame + {{200, 200}, {500, 300}} + DebugSTDIOWindowFrame + {{200, 200}, {500, 300}} + Frame + {{0, 288}, {963, 443}} + + Module + PBXDebugSessionModule + Proportion + 443pt + + + Name + Debug + ServiceClasses + + XCModuleDock + PBXDebugCLIModule + PBXDebugSessionModule + PBXDebugProcessAndThreadModule + PBXDebugProcessViewModule + PBXDebugThreadViewModule + PBXDebugStackFrameViewModule + PBXNavigatorGroup + XCConsole + + TableOfContents + + 21D4DEBC0A9A059D00F8FAED + 1CCC7628064C1048000F2A68 + 1CCC7629064C1048000F2A68 + 21D4DEBD0A9A059D00F8FAED + 21D4DEBE0A9A059D00F8FAED + 21D4DEBF0A9A059D00F8FAED + 21D4DEC00A9A059D00F8FAED + 21AE0EEC085B43480051FF07 + 21D4DEC10A9A059D00F8FAED + + ToolbarConfiguration + xcode.toolbar.config.debug + + + PerspectivesBarVisible + + ShelfIsVisible + + SourceDescription + file at '/System/Library/PrivateFrameworks/DevToolsInterface.framework/Versions/A/Resources/XCPerspectivesSpecification.xcperspec' + StatusbarIsVisible + + TimeStamp + 0.0 + ToolbarDisplayMode + 2 + ToolbarIsVisible + + ToolbarSizeMode + 2 + Type + Perspectives + UpdateMessage + + WindowJustification + 5 + WindowOrderList + + /Users/bb/PDP-8/pdp8e-simulator/pdp8e-simulator.xcodeproj + + WindowString + 10 87 963 772 0 0 1440 878 + WindowTools + + + Identifier + windowTool.find + Layout + + + Dock + + + Dock + + + ContentConfiguration + + PBXProjectModuleGUID + 1CDD528C0622207200134675 + PBXProjectModuleLabel + <No Editor> + PBXSplitModuleInNavigatorKey + + Split0 + + PBXProjectModuleGUID + 1CD0528D0623707200166675 + + SplitCount + 1 + + StatusBarVisibility + 1 + + GeometryConfiguration + + Frame + {{0, 0}, {781, 167}} + RubberWindowFrame + 62 385 781 470 0 0 1440 878 + + Module + PBXNavigatorGroup + Proportion + 781pt + + + Proportion + 50% + + + BecomeActive + 1 + ContentConfiguration + + PBXProjectModuleGUID + 1CD0528E0623707200166675 + PBXProjectModuleLabel + Project Find + + GeometryConfiguration + + Frame + {{8, 0}, {773, 254}} + RubberWindowFrame + 62 385 781 470 0 0 1440 878 + + Module + PBXProjectFindModule + Proportion + 50% + + + Proportion + 428pt + + + Name + Project Find + ServiceClasses + + PBXProjectFindModule + + StatusbarIsVisible + 1 + TableOfContents + + 1C530D57069F1CE1000CFCEE + 1C530D58069F1CE1000CFCEE + 1C530D59069F1CE1000CFCEE + 1CDD528C0622207200134675 + 1C530D5A069F1CE1000CFCEE + 1CE0B1FE06471DED0097A5F4 + 1CD0528E0623707200166675 + + WindowString + 62 385 781 470 0 0 1440 878 + WindowToolGUID + 1C530D57069F1CE1000CFCEE + WindowToolIsVisible + 0 + + + Identifier + windowTool.run + Layout + + + Dock + + + ContentConfiguration + + LauncherConfigVersion + 3 + PBXProjectModuleGUID + 1CD0528B0623707200166675 + PBXProjectModuleLabel + Run - cocoapp112 - cocoapp112 + Runner + + HorizontalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {365, 167}} + {{0, 176}, {365, 267}} + + + VerticalSplitView + + _collapsingFrameDimension + 0.0 + _indexOfCollapsedView + 0 + _percentageOfCollapsedView + 0.0 + isCollapsed + yes + sizes + + {{0, 0}, {405, 443}} + {{414, 0}, {514, 443}} + + + + + GeometryConfiguration + + Frame + {{0, 0}, {456, 192}} + RubberWindowFrame + 741 130 456 234 0 0 1280 1002 + + Module + PBXRunSessionModule + Proportion + 192pt + + + Proportion + 192pt + + + Name + Run Log + ServiceClasses + + PBXRunSessionModule + + StatusbarIsVisible + 1 + TableOfContents + + 1C78EAAF065D492600B07095 + 1C78EAB0065D492600B07095 + 1CD0528B0623707200166675 + 1C78EAB1065D492600B07095 + + ToolbarConfiguration + xcode.toolbar.config.run + WindowString + 741 130 456 234 0 0 1280 1002 + + + Identifier + windowTool.scm + Layout + + + Dock + + + ContentConfiguration + + PBXProjectModuleGUID + 1C78EAB2065D492600B07095 + PBXProjectModuleLabel + <No Editor> + PBXSplitModuleInNavigatorKey + + Split0 + + PBXProjectModuleGUID + 1C78EAB3065D492600B07095 + + SplitCount + 1 + + StatusBarVisibility + 1 + + GeometryConfiguration + + Frame + {{0, 0}, {452, 0}} + RubberWindowFrame + 743 379 452 308 0 0 1280 1002 + + Module + PBXNavigatorGroup + Proportion + 0pt + + + BecomeActive + 1 + ContentConfiguration + + PBXProjectModuleGUID + 1CD052920623707200166675 + PBXProjectModuleLabel + SCM + + GeometryConfiguration + + ConsoleFrame + {{0, 259}, {452, 0}} + Frame + {{0, 7}, {452, 259}} + RubberWindowFrame + 743 379 452 308 0 0 1280 1002 + TableConfiguration + + Status + 30 + FileName + 199 + Path + 197.09500122070312 + + TableFrame + {{0, 0}, {452, 250}} + + Module + PBXCVSModule + Proportion + 262pt + + + Proportion + 266pt + + + Name + SCM + ServiceClasses + + PBXCVSModule + + StatusbarIsVisible + 1 + TableOfContents + + 1C78EAB4065D492600B07095 + 1C78EAB5065D492600B07095 + 1C78EAB2065D492600B07095 + 1CD052920623707200166675 + + ToolbarConfiguration + xcode.toolbar.config.scm + WindowString + 743 379 452 308 0 0 1280 1002 + + + Identifier + windowTool.breakpoints + IsVertical + 0 + Layout + + + Dock + + + BecomeActive + 1 + ContentConfiguration + + PBXBottomSmartGroupGIDs + + 1C77FABC04509CD000000102 + + PBXProjectModuleGUID + 1CE0B1FE06471DED0097A5F4 + PBXProjectModuleLabel + Files + PBXProjectStructureProvided + no + PBXSmartGroupTreeModuleColumnData + + PBXSmartGroupTreeModuleColumnWidthsKey + + 168 + + PBXSmartGroupTreeModuleColumnsKey_v4 + + MainColumn + + + PBXSmartGroupTreeModuleOutlineStateKey_v7 + + PBXSmartGroupTreeModuleOutlineStateExpansionKey + + 1C77FABC04509CD000000102 + + PBXSmartGroupTreeModuleOutlineStateSelectionKey + + + 0 + + + PBXSmartGroupTreeModuleOutlineStateVisibleRectKey + {{0, 0}, {168, 350}} + + PBXTopSmartGroupGIDs + + XCIncludePerspectivesSwitch + 0 + + GeometryConfiguration + + Frame + {{0, 0}, {185, 368}} + GroupTreeTableConfiguration + + MainColumn + 168 + + RubberWindowFrame + 315 424 744 409 0 0 1440 878 + + Module + PBXSmartGroupTreeModule + Proportion + 185pt + + + ContentConfiguration + + PBXProjectModuleGUID + 1CA1AED706398EBD00589147 + PBXProjectModuleLabel + Detail + + GeometryConfiguration + + Frame + {{190, 0}, {554, 368}} + RubberWindowFrame + 315 424 744 409 0 0 1440 878 + + Module + XCDetailModule + Proportion + 554pt + + + Proportion + 368pt + + + MajorVersion + 2 + MinorVersion + 0 + Name + Breakpoints + ServiceClasses + + PBXSmartGroupTreeModule + XCDetailModule + + StatusbarIsVisible + 1 + TableOfContents + + 1CDDB66807F98D9800BB5817 + 1CDDB66907F98D9800BB5817 + 1CE0B1FE06471DED0097A5F4 + 1CA1AED706398EBD00589147 + + ToolbarConfiguration + xcode.toolbar.config.breakpoints + WindowString + 315 424 744 409 0 0 1440 878 + WindowToolGUID + 1CDDB66807F98D9800BB5817 + WindowToolIsVisible + 1 + + + Identifier + windowTool.debugAnimator + Layout + + + Dock + + + Module + PBXNavigatorGroup + Proportion + 100% + + + Proportion + 100% + + + Name + Debug Visualizer + ServiceClasses + + PBXNavigatorGroup + + StatusbarIsVisible + 1 + ToolbarConfiguration + xcode.toolbar.config.debugAnimator + WindowString + 100 100 700 500 0 0 1280 1002 + + + Identifier + windowTool.bookmarks + Layout + + + Dock + + + Module + PBXBookmarksModule + Proportion + 166pt + + + Proportion + 166pt + + + Name + Bookmarks + ServiceClasses + + PBXBookmarksModule + + StatusbarIsVisible + 0 + WindowString + 538 42 401 187 0 0 1280 1002 + + + Identifier + windowTool.classBrowser + Layout + + + Dock + + + BecomeActive + 1 + ContentConfiguration + + OptionsSetName + Hierarchy, all classes + PBXProjectModuleGUID + 1CA6456E063B45B4001379D8 + PBXProjectModuleLabel + Class Browser - NSObject + + GeometryConfiguration + + ClassesFrame + {{0, 0}, {369, 96}} + ClassesTreeTableConfiguration + + PBXClassNameColumnIdentifier + 208 + PBXClassBookColumnIdentifier + 22 + + Frame + {{0, 0}, {616, 353}} + MembersFrame + {{0, 105}, {369, 395}} + MembersTreeTableConfiguration + + PBXMemberTypeIconColumnIdentifier + 22 + PBXMemberNameColumnIdentifier + 216 + PBXMemberTypeColumnIdentifier + 94 + PBXMemberBookColumnIdentifier + 22 + + PBXModuleWindowStatusBarHidden2 + 1 + RubberWindowFrame + 597 125 616 374 0 0 1280 1002 + + Module + PBXClassBrowserModule + Proportion + 354pt + + + Proportion + 354pt + + + Name + Class Browser + ServiceClasses + + PBXClassBrowserModule + + StatusbarIsVisible + 0 + TableOfContents + + 1C78EABA065D492600B07095 + 1C78EABB065D492600B07095 + 1CA6456E063B45B4001379D8 + + ToolbarConfiguration + xcode.toolbar.config.classbrowser + WindowString + 597 125 616 374 0 0 1280 1002 + + + + diff --git a/pdp8e-simulator.xcodeproj/project.pbxproj b/pdp8e-simulator.xcodeproj/project.pbxproj new file mode 100644 index 0000000..97d05fa --- /dev/null +++ b/pdp8e-simulator.xcodeproj/project.pbxproj @@ -0,0 +1,3468 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXAggregateTarget section */ + 21BC38940BD5693600A37D35 /* All */ = { + isa = PBXAggregateTarget; + buildConfigurationList = 21BC389D0BD5696200A37D35 /* Build configuration list for PBXAggregateTarget "All" */; + buildPhases = ( + ); + dependencies = ( + 21BC38960BD5694400A37D35 /* PBXTargetDependency */, + ); + name = All; + productName = All; + }; +/* End PBXAggregateTarget section */ + +/* Begin PBXBuildFile section */ + 210857240D6B81500084490C /* ASR33OnlineHelp in Resources */ = {isa = PBXBuildFile; fileRef = 210857230D6B81500084490C /* ASR33OnlineHelp */; }; + 210857830D6B90E90084490C /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 210857600D6B8B630084490C /* InfoPlist.strings */; }; + 210910C9096042D5001F160B /* BootstrapPanelController.m in Sources */ = {isa = PBXBuildFile; fileRef = 210910C8096042D5001F160B /* BootstrapPanelController.m */; }; + 210911680962BC43001F160B /* binLoader.rim in Resources */ = {isa = PBXBuildFile; fileRef = 210911670962BC43001F160B /* binLoader.rim */; }; + 210911BF0962F734001F160B /* lowspeedRIM.bin in Resources */ = {isa = PBXBuildFile; fileRef = 210911BE0962F734001F160B /* lowspeedRIM.bin */; }; + 210911C10962F74D001F160B /* highspeedRIM.bin in Resources */ = {isa = PBXBuildFile; fileRef = 210911C00962F74D001F160B /* highspeedRIM.bin */; }; + 210911E209640856001F160B /* rk8eBootcode.bin in Resources */ = {isa = PBXBuildFile; fileRef = 210911E109640856001F160B /* rk8eBootcode.bin */; }; + 210913B60966A3BA001F160B /* resetToolbarIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 210913B50966A3BA001F160B /* resetToolbarIcon.tiff */; }; + 21091513096C30A5001F160B /* PreferencesController.m in Sources */ = {isa = PBXBuildFile; fileRef = 21091512096C30A5001F160B /* PreferencesController.m */; }; + 210915F7097154D7001F160B /* PreferencePanes.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 210915F6097154D7001F160B /* PreferencePanes.framework */; }; + 210916B309716681001F160B /* GeneralPreferences.prefPane in CopyFiles */ = {isa = PBXBuildFile; fileRef = 210915E909715375001F160B /* GeneralPreferences.prefPane */; }; + 21098E1F086595E1005945C4 /* breakpoint.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21098E1A086595E1005945C4 /* breakpoint.tiff */; }; + 21098E20086595E1005945C4 /* breakOpcode.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21098E1B086595E1005945C4 /* breakOpcode.tiff */; }; + 21098E23086598AD005945C4 /* breakOpcodeS.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21098E21086598AD005945C4 /* breakOpcodeS.tiff */; }; + 21098E24086598AD005945C4 /* breakOpcodeU.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21098E22086598AD005945C4 /* breakOpcodeU.tiff */; }; + 21098E2A0865AFCE005945C4 /* pcArrowBlue.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21098E290865AFCE005945C4 /* pcArrowBlue.tiff */; }; + 210D334010933D71002CF77D /* tty-backspace.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 210D333B10933D71002CF77D /* tty-backspace.mp3 */; }; + 210D334110933D71002CF77D /* tty-bell.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 210D333C10933D71002CF77D /* tty-bell.mp3 */; }; + 210D334210933D71002CF77D /* tty-carriage-return.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 210D333D10933D71002CF77D /* tty-carriage-return.mp3 */; }; + 210D334310933D71002CF77D /* tty-keystroke1.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 210D333E10933D71002CF77D /* tty-keystroke1.mp3 */; }; + 210D334410933D71002CF77D /* tty-space.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 210D333F10933D71002CF77D /* tty-space.mp3 */; }; + 210D3379109347DF002CF77D /* SpeakerLoud.png in Resources */ = {isa = PBXBuildFile; fileRef = 210D3377109347DF002CF77D /* SpeakerLoud.png */; }; + 210D337A109347DF002CF77D /* SpeakerQuiet.png in Resources */ = {isa = PBXBuildFile; fileRef = 210D3378109347DF002CF77D /* SpeakerQuiet.png */; }; + 210F34870BC8F9EC00482109 /* PluginManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 210F34850BC8F9EC00482109 /* PluginManager.m */; }; + 2115DC310D539FCC00102889 /* FileDropControlTargetProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 2115DC2D0D539B5500102889 /* FileDropControlTargetProtocol.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 2115DE250D55FF2D00102889 /* NSControl+FileDrop.h in Headers */ = {isa = PBXBuildFile; fileRef = 2115DE240D55FF2D00102889 /* NSControl+FileDrop.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 211638560D48082E00F5B564 /* ASR33.nib in Resources */ = {isa = PBXBuildFile; fileRef = 211638550D48082E00F5B564 /* ASR33.nib */; }; + 211639F40D4B8F7B00F5B564 /* FloatingPointNumber.h in Headers */ = {isa = PBXBuildFile; fileRef = 21FC26B109D6DAF3006625FE /* FloatingPointNumber.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 211639F50D4B8F7C00F5B564 /* FloatingPointNumber.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC26B209D6DAF3006625FE /* FloatingPointNumber.m */; }; + 21163A560D4BA32F00F5B564 /* MemoryInspectorPascalSFloatingPoint.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC28AE09DD9040006625FE /* MemoryInspectorPascalSFloatingPoint.m */; }; + 21163B360D4BDCC600F5B564 /* Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 210F35E20BC90C8500482109 /* Info.plist */; }; + 21163B5C0D4BE3EF00F5B564 /* MemoryInspectorProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 2133910009B8E2B300F2C028 /* MemoryInspectorProtocol.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 21163E210D4D2C6B00F5B564 /* NSMutableArray+BinarySearch.h in Headers */ = {isa = PBXBuildFile; fileRef = 21CAB2940877DC7800E9005D /* NSMutableArray+BinarySearch.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 21163E220D4D2C6F00F5B564 /* NSTableView+Scrolling.h in Headers */ = {isa = PBXBuildFile; fileRef = 21F556080949FC6500DA4AB8 /* NSTableView+Scrolling.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 21163FA30D4E3DA600F5B564 /* KeepInMenuWindow.h in Headers */ = {isa = PBXBuildFile; fileRef = 21163F870D4E3A3000F5B564 /* KeepInMenuWindow.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 211C61BE198BE6420005DA7D /* NSThread+MainThread.m in Sources */ = {isa = PBXBuildFile; fileRef = 211C61BC198BE6420005DA7D /* NSThread+MainThread.m */; }; + 211DAA8E0BC9246E00F042A3 /* PluginAPI.h in Headers */ = {isa = PBXBuildFile; fileRef = 210F34920BC8FC3400482109 /* PluginAPI.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 211EF3AB0BFC561000851FF1 /* ASR33TextView.m in Sources */ = {isa = PBXBuildFile; fileRef = 211EF3AA0BFC561000851FF1 /* ASR33TextView.m */; }; + 21207555116A63DB007C1A7E /* ASR 33 Console Teletype.pdp8Plugin in CopyFiles */ = {isa = PBXBuildFile; fileRef = 2139F8B00D6763BF00836D7B /* ASR 33 Console Teletype.pdp8Plugin */; }; + 21207556116A63DC007C1A7E /* RK8-E Disk Cartridge System.pdp8Plugin in CopyFiles */ = {isa = PBXBuildFile; fileRef = 21E8F9A10D7338BF00634911 /* RK8-E Disk Cartridge System.pdp8Plugin */; }; + 21207660116A643A007C1A7E /* TSC8-75 Board.pdp8Plugin in CopyFiles */ = {isa = PBXBuildFile; fileRef = 2128EA4E109786FD00CA858C /* TSC8-75 Board.pdp8Plugin */; }; + 2126BE0409817C6D008BB678 /* PreferencePanes.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 210915F6097154D7001F160B /* PreferencePanes.framework */; }; + 2126BE1309817D4B008BB678 /* CPUPreferences.m in Sources */ = {isa = PBXBuildFile; fileRef = 2126BE0F09817D4B008BB678 /* CPUPreferences.m */; }; + 2126BE1409817D4B008BB678 /* CPUPreferences.nib in Resources */ = {isa = PBXBuildFile; fileRef = 2126BE1009817D4B008BB678 /* CPUPreferences.nib */; }; + 2126BE4109818341008BB678 /* CPUPreferences.prefPane in CopyFiles */ = {isa = PBXBuildFile; fileRef = 2126BE0909817C6D008BB678 /* CPUPreferences.prefPane */; }; + 2126DEC71052F0E2003B4706 /* RK8E.nib in Resources */ = {isa = PBXBuildFile; fileRef = 2126DEC61052F0E2003B4706 /* RK8E.nib */; }; + 2126E0FA10580DA5003B4706 /* RK8EOnlineHelp in Resources */ = {isa = PBXBuildFile; fileRef = 2126E0F710580DA5003B4706 /* RK8EOnlineHelp */; }; + 2128E94F109505FB00CA858C /* tty-keystroke2.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 2128E94E109505FB00CA858C /* tty-keystroke2.mp3 */; }; + 2128E95E109612C200CA858C /* tty-keystroke3.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 2128E95C109612C200CA858C /* tty-keystroke3.mp3 */; }; + 2128E95F109612C200CA858C /* tty-keystroke4.mp3 in Resources */ = {isa = PBXBuildFile; fileRef = 2128E95D109612C200CA858C /* tty-keystroke4.mp3 */; }; + 2128E9D11096379400CA858C /* NSControl+FileDrop.m in Sources */ = {isa = PBXBuildFile; fileRef = 2115DC2E0D539B5500102889 /* NSControl+FileDrop.m */; }; + 2128E9D21096379500CA858C /* NSFileManager+Additions.m in Sources */ = {isa = PBXBuildFile; fileRef = 2139F73C0D67433700836D7B /* NSFileManager+Additions.m */; }; + 2128E9D31096379600CA858C /* NSTableView+Scrolling.m in Sources */ = {isa = PBXBuildFile; fileRef = 21F556090949FC6500DA4AB8 /* NSTableView+Scrolling.m */; }; + 2128E9D41096379700CA858C /* NSMutableArray+BinarySearch.m in Sources */ = {isa = PBXBuildFile; fileRef = 21CAB2950877DC7800E9005D /* NSMutableArray+BinarySearch.m */; }; + 2128EA31109773AA00CA858C /* bracket.png in Resources */ = {isa = PBXBuildFile; fileRef = 2128EA30109773AA00CA858C /* bracket.png */; }; + 2128EA47109786FD00CA858C /* PluginFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 211DA8380BC91C5500F042A3 /* PluginFramework.framework */; }; + 2128EB0210978DA300CA858C /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 2128EB0110978DA300CA858C /* InfoPlist.strings */; }; + 2128EB1110978E5A00CA858C /* TSC8.m in Sources */ = {isa = PBXBuildFile; fileRef = 2128EB1010978E5A00CA858C /* TSC8.m */; }; + 2133910909B8E43900F2C028 /* MemoryInspectorController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2133910709B8E43900F2C028 /* MemoryInspectorController.m */; }; + 2133917209BA24FF00F2C028 /* MemoryInspector6BitASCII.m in Sources */ = {isa = PBXBuildFile; fileRef = 2133917009BA24FF00F2C028 /* MemoryInspector6BitASCII.m */; }; + 2133AE720D78A1630023A41A /* RK05Controller.m in Sources */ = {isa = PBXBuildFile; fileRef = 2133AE710D78A1630023A41A /* RK05Controller.m */; }; + 2133AED20D78B9940023A41A /* RK05.m in Sources */ = {isa = PBXBuildFile; fileRef = 2133AED10D78B9940023A41A /* RK05.m */; }; + 2133B3450D7F22260023A41A /* EnableDisableTextField.h in Headers */ = {isa = PBXBuildFile; fileRef = 2133B3420D7F22200023A41A /* EnableDisableTextField.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 2133B3960D7F2B150023A41A /* RK8Eiot.c in Sources */ = {isa = PBXBuildFile; fileRef = 2133B3950D7F2B150023A41A /* RK8Eiot.c */; }; + 2134E97C0986C14F00D74DC4 /* generalPrefIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 2134E97B0986C14F00D74DC4 /* generalPrefIcon.tiff */; }; + 2139F73F0D6744A200836D7B /* NSFileManager+Additions.h in Headers */ = {isa = PBXBuildFile; fileRef = 2139F73B0D67433700836D7B /* NSFileManager+Additions.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 213AE24C09F422E50028A0E7 /* pdp8e.icns in Resources */ = {isa = PBXBuildFile; fileRef = 213AE24B09F422E50028A0E7 /* pdp8e.icns */; }; + 213AE2C509F6D7750028A0E7 /* Credits.html in Resources */ = {isa = PBXBuildFile; fileRef = 213AE2C309F6D7750028A0E7 /* Credits.html */; }; + 214362F50860D45700DB186F /* stepToolbarIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 214362F20860D45700DB186F /* stepToolbarIcon.tiff */; }; + 214362F60860D45700DB186F /* stopToolbarIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 214362F30860D45700DB186F /* stopToolbarIcon.tiff */; }; + 214362F70860D45700DB186F /* traceToolbarIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 214362F40860D45700DB186F /* traceToolbarIcon.tiff */; }; + 214363010860D9BE00DB186F /* goToolbarIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 214363000860D9BE00DB186F /* goToolbarIcon.tiff */; }; + 214429A409EAE8B800271635 /* OnlineHelp in Resources */ = {isa = PBXBuildFile; fileRef = 2144299F09EAE8B800271635 /* OnlineHelp */; }; + 2147854009F6F32500A32CFE /* bb.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 2147853F09F6F32500A32CFE /* bb.tiff */; }; + 2149F83A0D82AD930084F33F /* Utilities.c in Sources */ = {isa = PBXBuildFile; fileRef = 2149F8380D82AD930084F33F /* Utilities.c */; }; + 2159F23C08689ACF002186B0 /* mri.c in Sources */ = {isa = PBXBuildFile; fileRef = 2159F23B08689ACF002186B0 /* mri.c */; }; + 2159F2470868A3B8002186B0 /* eae.c in Sources */ = {isa = PBXBuildFile; fileRef = 2159F2450868A3B8002186B0 /* eae.c */; }; + 2159F24A0868A442002186B0 /* opr.c in Sources */ = {isa = PBXBuildFile; fileRef = 2159F2480868A442002186B0 /* opr.c */; }; + 2159F2550868A639002186B0 /* iot.c in Sources */ = {isa = PBXBuildFile; fileRef = 2159F2530868A639002186B0 /* iot.c */; }; + 2159F26F0869CE98002186B0 /* disassembler.plist in Resources */ = {isa = PBXBuildFile; fileRef = 2159F26E0869CE98002186B0 /* disassembler.plist */; }; + 2159F2740869DB1A002186B0 /* Disassembler.m in Sources */ = {isa = PBXBuildFile; fileRef = 2159F2730869DB1A002186B0 /* Disassembler.m */; }; + 2159F315086DFFAD002186B0 /* Assembler.m in Sources */ = {isa = PBXBuildFile; fileRef = 2159F314086DFFAD002186B0 /* Assembler.m */; }; + 2159F50C086EBCCF002186B0 /* Opcode.m in Sources */ = {isa = PBXBuildFile; fileRef = 2159F50B086EBCCF002186B0 /* Opcode.m */; }; + 2159F52C086EEEFC002186B0 /* assembler.plist in Resources */ = {isa = PBXBuildFile; fileRef = 2159F52B086EEEFC002186B0 /* assembler.plist */; }; + 2161C49F0BE537A30008E867 /* ASR33iot.c in Sources */ = {isa = PBXBuildFile; fileRef = 2161C49E0BE537A30008E867 /* ASR33iot.c */; }; + 2161C6620BE66DCC0008E867 /* ASR33WindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2161C6610BE66DCC0008E867 /* ASR33WindowController.m */; }; + 2165B00D109795D900E61A92 /* TSC8iot.c in Sources */ = {isa = PBXBuildFile; fileRef = 2165B00C109795D900E61A92 /* TSC8iot.c */; }; + 2165B01910979BCA00E61A92 /* io-info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 2165B01710979BCA00E61A92 /* io-info.plist */; }; + 2165B05B1098D0B500E61A92 /* TSC8.nib in Resources */ = {isa = PBXBuildFile; fileRef = 2165B05A1098D0B500E61A92 /* TSC8.nib */; }; + 216792D40D45067700666543 /* io-info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 216792D30D45067700666543 /* io-info.plist */; }; + 216962620D1C220100822F9C /* Utilities.h in Headers */ = {isa = PBXBuildFile; fileRef = 216962610D1C21E200822F9C /* Utilities.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 216B74FB0D6F4AEF00124930 /* HelpMenuManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 216B74FA0D6F4AEF00124930 /* HelpMenuManager.m */; }; + 216B75C80D70E16A00124930 /* GeneralPreferences.m in Sources */ = {isa = PBXBuildFile; fileRef = 216B75C70D70E16A00124930 /* GeneralPreferences.m */; }; + 216B75E10D70E7D200124930 /* ASR33Preferences.m in Sources */ = {isa = PBXBuildFile; fileRef = 216B75E00D70E7D200124930 /* ASR33Preferences.m */; }; + 2171819009FA879800754508 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 2171818F09FA879800754508 /* libz.dylib */; }; + 217868690BF7A00A00FC1DA7 /* RegisterFormCell.h in Headers */ = {isa = PBXBuildFile; fileRef = 21CF5C9E09194DC700377059 /* RegisterFormCell.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 2178686C0BF7A01D00FC1DA7 /* OctalFormatter.h in Headers */ = {isa = PBXBuildFile; fileRef = 21CAB1FA0876E9DD00E9005D /* OctalFormatter.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 217C9F9A08746FBA009F9D30 /* BreakpointArray.m in Sources */ = {isa = PBXBuildFile; fileRef = 217C9F9908746FBA009F9D30 /* BreakpointArray.m */; }; + 2181CDC6109E21550026FAA5 /* TSC8OnlineHelp in Resources */ = {isa = PBXBuildFile; fileRef = 2181CDC0109E21550026FAA5 /* TSC8OnlineHelp */; }; + 2181CE31109EDC480026FAA5 /* PluginFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 211DA8380BC91C5500F042A3 /* PluginFramework.framework */; }; + 2181CE97109EE1E30026FAA5 /* KC8EA.nib in Resources */ = {isa = PBXBuildFile; fileRef = 2181CE96109EE1E30026FAA5 /* KC8EA.nib */; }; + 2181CEA7109EE2D80026FAA5 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 2181CEA5109EE2D80026FAA5 /* InfoPlist.strings */; }; + 2181CEB4109EE3690026FAA5 /* io-info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 2181CEB3109EE3690026FAA5 /* io-info.plist */; }; + 2181CEDF109EE3CA0026FAA5 /* KC8-EA Programmer’s Console.pdp8Plugin in CopyFiles */ = {isa = PBXBuildFile; fileRef = 2181CE38109EDC480026FAA5 /* KC8-EA Programmer’s Console.pdp8Plugin */; }; + 2181CF00109EE4130026FAA5 /* KC8EA.m in Sources */ = {isa = PBXBuildFile; fileRef = 2181CEFF109EE4130026FAA5 /* KC8EA.m */; }; + 2181CF22109EEE5F0026FAA5 /* BackgroundView.m in Sources */ = {isa = PBXBuildFile; fileRef = 2181CF21109EEE5F0026FAA5 /* BackgroundView.m */; }; + 2181CF46109EF7940026FAA5 /* background.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181CF45109EF7940026FAA5 /* background.png */; }; + 2181CFED109F1D170026FAA5 /* light_off.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181CFEB109F1D170026FAA5 /* light_off.png */; }; + 2181CFEE109F1D170026FAA5 /* light_on.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181CFEC109F1D170026FAA5 /* light_on.png */; }; + 2181D05B10A0C41A0026FAA5 /* sr0down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D03810A0C41A0026FAA5 /* sr0down.png */; }; + 2181D05C10A0C41A0026FAA5 /* sr0up_sr1down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D03910A0C41A0026FAA5 /* sr0up_sr1down.png */; }; + 2181D05D10A0C41A0026FAA5 /* sr0up_sr1up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D03A10A0C41A0026FAA5 /* sr0up_sr1up.png */; }; + 2181D05E10A0C41A0026FAA5 /* sr1down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D03B10A0C41A0026FAA5 /* sr1down.png */; }; + 2181D05F10A0C41A0026FAA5 /* sr1up_sr2down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D03C10A0C41A0026FAA5 /* sr1up_sr2down.png */; }; + 2181D06010A0C41A0026FAA5 /* sr1up_sr2up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D03D10A0C41A0026FAA5 /* sr1up_sr2up.png */; }; + 2181D06210A0C41A0026FAA5 /* sr2up_sr3down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D03F10A0C41A0026FAA5 /* sr2up_sr3down.png */; }; + 2181D06310A0C41A0026FAA5 /* sr2up_sr3up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04010A0C41A0026FAA5 /* sr2up_sr3up.png */; }; + 2181D06410A0C41A0026FAA5 /* sr3down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04110A0C41A0026FAA5 /* sr3down.png */; }; + 2181D06510A0C41A0026FAA5 /* sr3up_sr4down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04210A0C41A0026FAA5 /* sr3up_sr4down.png */; }; + 2181D06610A0C41A0026FAA5 /* sr3up_sr4up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04310A0C41A0026FAA5 /* sr3up_sr4up.png */; }; + 2181D06710A0C41A0026FAA5 /* sr4down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04410A0C41A0026FAA5 /* sr4down.png */; }; + 2181D06810A0C41A0026FAA5 /* sr4up_sr5down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04510A0C41A0026FAA5 /* sr4up_sr5down.png */; }; + 2181D06910A0C41A0026FAA5 /* sr4up_sr5up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04610A0C41A0026FAA5 /* sr4up_sr5up.png */; }; + 2181D06A10A0C41A0026FAA5 /* sr5down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04710A0C41A0026FAA5 /* sr5down.png */; }; + 2181D06B10A0C41A0026FAA5 /* sr5up_sr6down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04810A0C41A0026FAA5 /* sr5up_sr6down.png */; }; + 2181D06C10A0C41A0026FAA5 /* sr5up_sr6up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04910A0C41A0026FAA5 /* sr5up_sr6up.png */; }; + 2181D06D10A0C41A0026FAA5 /* sr6down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04A10A0C41A0026FAA5 /* sr6down.png */; }; + 2181D06E10A0C41A0026FAA5 /* sr6up_sr7down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04B10A0C41A0026FAA5 /* sr6up_sr7down.png */; }; + 2181D06F10A0C41A0026FAA5 /* sr6up_sr7up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04C10A0C41A0026FAA5 /* sr6up_sr7up.png */; }; + 2181D07010A0C41A0026FAA5 /* sr7down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D04D10A0C41A0026FAA5 /* sr7down.png */; }; + 2181D07310A0C41A0026FAA5 /* sr8down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05010A0C41A0026FAA5 /* sr8down.png */; }; + 2181D07410A0C41A0026FAA5 /* sr8up_sr9down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05110A0C41A0026FAA5 /* sr8up_sr9down.png */; }; + 2181D07510A0C41A0026FAA5 /* sr8up_sr9up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05210A0C41A0026FAA5 /* sr8up_sr9up.png */; }; + 2181D07610A0C41A0026FAA5 /* sr9down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05310A0C41A0026FAA5 /* sr9down.png */; }; + 2181D07710A0C41A0026FAA5 /* sr9up_sr10down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05410A0C41A0026FAA5 /* sr9up_sr10down.png */; }; + 2181D07810A0C41A0026FAA5 /* sr9up_sr10up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05510A0C41A0026FAA5 /* sr9up_sr10up.png */; }; + 2181D07910A0C41A0026FAA5 /* sr10down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05610A0C41A0026FAA5 /* sr10down.png */; }; + 2181D07A10A0C41A0026FAA5 /* sr10up_sr11down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05710A0C41A0026FAA5 /* sr10up_sr11down.png */; }; + 2181D07B10A0C41A0026FAA5 /* sr10up_sr11up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D05810A0C41A0026FAA5 /* sr10up_sr11up.png */; }; + 2181D0AA10A0CAF20026FAA5 /* sr2down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D0A910A0CAF20026FAA5 /* sr2down.png */; }; + 2181D0AC10A0CC550026FAA5 /* sr11down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D0AB10A0CC550026FAA5 /* sr11down.png */; }; + 2181D0B610A0D2E10026FAA5 /* sr11up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D0B510A0D2E10026FAA5 /* sr11up.png */; }; + 2181D0C410A0D61E0026FAA5 /* sr7up_sr8down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D0C210A0D61E0026FAA5 /* sr7up_sr8down.png */; }; + 2181D0C510A0D61E0026FAA5 /* sr7up_sr8up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D0C310A0D61E0026FAA5 /* sr7up_sr8up.png */; }; + 2181D1A110A0FF3D0026FAA5 /* ConsoleSwitchCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2181D1A010A0FF3D0026FAA5 /* ConsoleSwitchCell.m */; }; + 2181D41910A2072E0026FAA5 /* sw_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D41710A2072E0026FAA5 /* sw_down.png */; }; + 2181D41A10A2072E0026FAA5 /* sw_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D41810A2072E0026FAA5 /* sw_up.png */; }; + 2181D53510A475770026FAA5 /* addrload_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D53210A475770026FAA5 /* addrload_down.png */; }; + 2181D53610A475770026FAA5 /* addrload_up_extdaddrload_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D53310A475770026FAA5 /* addrload_up_extdaddrload_down.png */; }; + 2181D53710A475770026FAA5 /* addrload_up_extdaddrload_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D53410A475770026FAA5 /* addrload_up_extdaddrload_up.png */; }; + 2181D59D10A47E010026FAA5 /* extdaddrload_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D59B10A47E010026FAA5 /* extdaddrload_down.png */; }; + 2181D59E10A47E010026FAA5 /* extdaddrload_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D59C10A47E010026FAA5 /* extdaddrload_up.png */; }; + 2181D5D810A4A0550026FAA5 /* clear_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5D510A4A0550026FAA5 /* clear_down.png */; }; + 2181D5D910A4A0550026FAA5 /* clear_up_cont_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5D610A4A0550026FAA5 /* clear_up_cont_down.png */; }; + 2181D5DA10A4A0550026FAA5 /* clear_up_cont_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5D710A4A0550026FAA5 /* clear_up_cont_up.png */; }; + 2181D5E210A4A1400026FAA5 /* cont_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5DF10A4A1400026FAA5 /* cont_down.png */; }; + 2181D5E310A4A1400026FAA5 /* cont_up_exam_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5E010A4A1400026FAA5 /* cont_up_exam_down.png */; }; + 2181D5E410A4A1400026FAA5 /* cont_up_exam_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5E110A4A1400026FAA5 /* cont_up_exam_up.png */; }; + 2181D5E810A4A2760026FAA5 /* exam_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5E510A4A2760026FAA5 /* exam_down.png */; }; + 2181D5E910A4A2760026FAA5 /* exam_up_halt_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5E610A4A2760026FAA5 /* exam_up_halt_down.png */; }; + 2181D5EA10A4A2760026FAA5 /* exam_up_halt_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5E710A4A2760026FAA5 /* exam_up_halt_up.png */; }; + 2181D5EE10A4A2F90026FAA5 /* halt_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5EB10A4A2F90026FAA5 /* halt_down.png */; }; + 2181D5EF10A4A2F90026FAA5 /* halt_up_singstep_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5EC10A4A2F90026FAA5 /* halt_up_singstep_down.png */; }; + 2181D5F010A4A2F90026FAA5 /* halt_up_singstep_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5ED10A4A2F90026FAA5 /* halt_up_singstep_up.png */; }; + 2181D5F410A4A39C0026FAA5 /* singstep_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5F110A4A39C0026FAA5 /* singstep_down.png */; }; + 2181D5F510A4A39C0026FAA5 /* singstep_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D5F210A4A39C0026FAA5 /* singstep_up.png */; }; + 2181D63810A5E2210026FAA5 /* dep_down.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D63610A5E2210026FAA5 /* dep_down.png */; }; + 2181D63910A5E2210026FAA5 /* dep_up.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D63710A5E2210026FAA5 /* dep_up.png */; }; + 2181D69D10A6196D0026FAA5 /* knob0.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D69710A6196D0026FAA5 /* knob0.png */; }; + 2181D69E10A6196D0026FAA5 /* knob1.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D69810A6196D0026FAA5 /* knob1.png */; }; + 2181D69F10A6196D0026FAA5 /* knob2.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D69910A6196D0026FAA5 /* knob2.png */; }; + 2181D6A010A6196D0026FAA5 /* knob3.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D69A10A6196D0026FAA5 /* knob3.png */; }; + 2181D6A110A6196D0026FAA5 /* knob4.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D69B10A6196D0026FAA5 /* knob4.png */; }; + 2181D6A210A6196D0026FAA5 /* knob5.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D69C10A6196D0026FAA5 /* knob5.png */; }; + 2181D6AF10A620E30026FAA5 /* KnobCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2181D6AE10A620E30026FAA5 /* KnobCell.m */; }; + 2181D7BE10A706870026FAA5 /* key0.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D7BB10A706870026FAA5 /* key0.png */; }; + 2181D7BF10A706870026FAA5 /* key1.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D7BC10A706870026FAA5 /* key1.png */; }; + 2181D7C010A706870026FAA5 /* key2.png in Resources */ = {isa = PBXBuildFile; fileRef = 2181D7BD10A706870026FAA5 /* key2.png */; }; + 2189C6D508707ABA00BA6C42 /* BreakpointController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2189C6D408707ABA00BA6C42 /* BreakpointController.m */; }; + 218BA93A09B0EC1600ABA09E /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */; }; + 21909698198FDA16003AD39C /* PC8EOnlineHelp in Resources */ = {isa = PBXBuildFile; fileRef = 21909692198FDA16003AD39C /* PC8EOnlineHelp */; }; + 219097D619912B13003AD39C /* plugin.icns in Resources */ = {isa = PBXBuildFile; fileRef = 219097D519912B13003AD39C /* plugin.icns */; }; + 219097DC199134EE003AD39C /* papertape.icns in Resources */ = {isa = PBXBuildFile; fileRef = 219097DB199134EE003AD39C /* papertape.icns */; }; + 219097EC1991452A003AD39C /* decpack.icns in Resources */ = {isa = PBXBuildFile; fileRef = 219097EB1991452A003AD39C /* decpack.icns */; }; + 2190D60310A98F50004E5E38 /* StateMachine.m in Sources */ = {isa = PBXBuildFile; fileRef = 2190D60210A98F50004E5E38 /* StateMachine.m */; }; + 2191521E1991796A0033DC01 /* NSThread+MainThread.h in Headers */ = {isa = PBXBuildFile; fileRef = 211C61BB198BE6420005DA7D /* NSThread+MainThread.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 21919F080879CD8300DC0727 /* Breakpoint.m in Sources */ = {isa = PBXBuildFile; fileRef = 21919F070879CD8300DC0727 /* Breakpoint.m */; }; + 219FBCE81983ED89005C5220 /* io-info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 219FBCE61983ED89005C5220 /* io-info.plist */; }; + 219FBD2E1983F98B005C5220 /* PluginFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 211DA8380BC91C5500F042A3 /* PluginFramework.framework */; }; + 219FBDA01984064A005C5220 /* InputConsumerProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 21FFB01D0D623295000B4CA5 /* InputConsumerProtocol.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 219FBDA11984064C005C5220 /* PaperTapeController.h in Headers */ = {isa = PBXBuildFile; fileRef = 21BC481E0CC216E200AA6F38 /* PaperTapeController.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 219FBDA21984064D005C5220 /* PaperTapeController.m in Sources */ = {isa = PBXBuildFile; fileRef = 21BC47F30CC214CB00AA6F38 /* PaperTapeController.m */; }; + 219FBDA31984064E005C5220 /* PaperTapeProgressIndicator.h in Headers */ = {isa = PBXBuildFile; fileRef = 21D9432C13F7E4C600086135 /* PaperTapeProgressIndicator.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 219FBDA41984064F005C5220 /* PaperTapeProgressIndicator.m in Sources */ = {isa = PBXBuildFile; fileRef = 21D9432D13F7E4C600086135 /* PaperTapeProgressIndicator.m */; }; + 21A683460D68631B000D5B59 /* ASR33Preferences.nib in Resources */ = {isa = PBXBuildFile; fileRef = 21A683440D68631B000D5B59 /* ASR33Preferences.nib */; }; + 21A683660D6865F9000D5B59 /* PreferencePanes.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 210915F6097154D7001F160B /* PreferencePanes.framework */; }; + 21A683950D686C17000D5B59 /* asr33PrefIcon.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 21A683940D686C17000D5B59 /* asr33PrefIcon.jpg */; }; + 21A683A00D68758E000D5B59 /* cpuPrefIcon.jpg in Resources */ = {isa = PBXBuildFile; fileRef = 21A6839F0D68758E000D5B59 /* cpuPrefIcon.jpg */; }; + 21A683D00D688C48000D5B59 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 21A683CF0D688C48000D5B59 /* InfoPlist.strings */; }; + 21A683D40D688D38000D5B59 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 21A683D30D688D38000D5B59 /* InfoPlist.strings */; }; + 21A683F20D688DEC000D5B59 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 21A683F10D688DEC000D5B59 /* InfoPlist.strings */; }; + 21A684390D69C05F000D5B59 /* ASR33Preferences.prefPane in CopyFiles */ = {isa = PBXBuildFile; fileRef = 21A682FF0D685C73000D5B59 /* ASR33Preferences.prefPane */; }; + 21AAEE4C09B6522300E55A42 /* memoryInspectorToolbarIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21AAEE4B09B6522300E55A42 /* memoryInspectorToolbarIcon.tiff */; }; + 21AE0F0F085B43A00051FF07 /* CPUWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 21AE0F0E085B43A00051FF07 /* CPUWindowController.m */; }; + 21AE0F12085B43A60051FF07 /* MainController.m in Sources */ = {isa = PBXBuildFile; fileRef = 21AE0F11085B43A60051FF07 /* MainController.m */; }; + 21B36BE01982EE0200EE4AD8 /* PluginFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 211DA8380BC91C5500F042A3 /* PluginFramework.framework */; }; + 21B36C551982F0ED00EE4AD8 /* PC8E.m in Sources */ = {isa = PBXBuildFile; fileRef = 21B36C541982F0ED00EE4AD8 /* PC8E.m */; }; + 21B36CBB1983CE4500EE4AD8 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 21B36CBA1983CE4500EE4AD8 /* InfoPlist.strings */; }; + 21B36CCC1983D55600EE4AD8 /* PC8E.nib in Resources */ = {isa = PBXBuildFile; fileRef = 21B36CCA1983D55600EE4AD8 /* PC8E.nib */; }; + 21B36CE21983ECA700EE4AD8 /* PC8-E Paper Tape Reader & Punch.pdp8Plugin in CopyFiles */ = {isa = PBXBuildFile; fileRef = 21B36BE81982EE0200EE4AD8 /* PC8-E Paper Tape Reader & Punch.pdp8Plugin */; }; + 21B8420C0D454D3100BD583A /* auxtty-io-info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 21B8420A0D454D3100BD583A /* auxtty-io-info.plist */; }; + 21BC366F0BD506C400A37D35 /* PDP8.h in Headers */ = {isa = PBXBuildFile; fileRef = 211589090868764B0007B9B0 /* PDP8.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 21BC384E0BD541A700A37D35 /* ASR33.m in Sources */ = {isa = PBXBuildFile; fileRef = 21BC384D0BD541A700A37D35 /* ASR33.m */; }; + 21C7F23109BCB2B2002BBEB7 /* MemoryInspector8BitASCII.m in Sources */ = {isa = PBXBuildFile; fileRef = 21C7F22F09BCB2B2002BBEB7 /* MemoryInspector8BitASCII.m */; }; + 21CAB0E50876A61C00E9005D /* OpcodeFormatter.m in Sources */ = {isa = PBXBuildFile; fileRef = 21CAB0E40876A61C00E9005D /* OpcodeFormatter.m */; }; + 21CAB17E0876C7E000E9005D /* breakpointsToolbarIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21CAB17D0876C7E000E9005D /* breakpointsToolbarIcon.tiff */; }; + 21CF5F9D091CF61F00377059 /* CPUMemoryViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 21CF5F9C091CF61F00377059 /* CPUMemoryViewController.m */; }; + 21CF5FA8091D089600377059 /* IOFlagController.m in Sources */ = {isa = PBXBuildFile; fileRef = 21CF5FA7091D089600377059 /* IOFlagController.m */; }; + 21CF60CF09200C9D00377059 /* itab.c in Sources */ = {isa = PBXBuildFile; fileRef = 21CF60CD09200C9D00377059 /* itab.c */; }; + 21D473E1108A4430006A5154 /* PDP8.m in Sources */ = {isa = PBXBuildFile; fileRef = 2115890A0868764B0007B9B0 /* PDP8.m */; }; + 21D4741D108A458C006A5154 /* PluginAPI.m in Sources */ = {isa = PBXBuildFile; fileRef = 21BC37B70BD515C000A37D35 /* PluginAPI.m */; }; + 21D47420108A458E006A5154 /* KeepInMenuWindow.m in Sources */ = {isa = PBXBuildFile; fileRef = 21163E020D4D278800F5B564 /* KeepInMenuWindow.m */; }; + 21D47421108A458F006A5154 /* EnableDisableTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 2133B3430D7F22200023A41A /* EnableDisableTextField.m */; }; + 21D47422108A4593006A5154 /* OctalFormatter.m in Sources */ = {isa = PBXBuildFile; fileRef = 21CAB1FB0876E9DD00E9005D /* OctalFormatter.m */; }; + 21D47430108A4664006A5154 /* RegisterFormCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 21CF5C9D09194DC700377059 /* RegisterFormCell.m */; }; + 21D47449108A46C3006A5154 /* PluginFramework.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = 211DA8380BC91C5500F042A3 /* PluginFramework.framework */; }; + 21D47462108A48AD006A5154 /* PluginFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 211DA8380BC91C5500F042A3 /* PluginFramework.framework */; }; + 21DC5A4A09C77583000F3908 /* alignMemoryArrow.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21DC5A4909C77583000F3908 /* alignMemoryArrow.tiff */; }; + 21DC5DC409CC3E4A000F3908 /* NonWrappingTableView.m in Sources */ = {isa = PBXBuildFile; fileRef = 21DC5DC209CC3E4A000F3908 /* NonWrappingTableView.m */; }; + 21E1D4AE198550F6002E2DDC /* PC8Eiot.c in Sources */ = {isa = PBXBuildFile; fileRef = 21E1D4AC198550F6002E2DDC /* PC8Eiot.c */; }; + 21E6757B1500D997006F9F91 /* Unicode.h in Headers */ = {isa = PBXBuildFile; fileRef = 21DC5FDF09D0B3CA000F3908 /* Unicode.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 21E8F8F90D721A7B00634911 /* pcArrowGraphite.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21E8F8F80D721A7B00634911 /* pcArrowGraphite.tiff */; }; + 21E8F9990D7338BF00634911 /* PluginFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 211DA8380BC91C5500F042A3 /* PluginFramework.framework */; }; + 21E8F9F80D733C3300634911 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 21E8F9F70D733C3300634911 /* InfoPlist.strings */; }; + 21E8FAB20D73603D00634911 /* RK8E.m in Sources */ = {isa = PBXBuildFile; fileRef = 21E8FAB10D73603D00634911 /* RK8E.m */; }; + 21E8FAD90D73622100634911 /* io-info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 21E8FAD70D73622100634911 /* io-info.plist */; }; + 21E8FBD60D75FF2400634911 /* RK8EController.m in Sources */ = {isa = PBXBuildFile; fileRef = 21E8FBD50D75FF2400634911 /* RK8EController.m */; }; + 21EE4D39098168D5002FF438 /* GeneralPreferences.nib in Resources */ = {isa = PBXBuildFile; fileRef = 21EE4D38098168D5002FF438 /* GeneralPreferences.nib */; }; + 21F568CC0956152900DA4AB8 /* bootstrapToolbarIcon.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21F568CB0956152900DA4AB8 /* bootstrapToolbarIcon.tiff */; }; + 21F96F1410B08D1E00D51223 /* KC8EAOnlineHelp in Resources */ = {isa = PBXBuildFile; fileRef = 21F96F0E10B08D1E00D51223 /* KC8EAOnlineHelp */; }; + 21FC250109D32AF0006625FE /* MemoryInspectorOS8Packed8BitASCII.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC250009D32AF0006625FE /* MemoryInspectorOS8Packed8BitASCII.m */; }; + 21FC259209D36137006625FE /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 21FC259109D36137006625FE /* Carbon.framework */; }; + 21FC261E09D5E76B006625FE /* MemoryInspectorSignedInteger.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC261D09D5E76B006625FE /* MemoryInspectorSignedInteger.m */; }; + 21FC267E09D6AC74006625FE /* MemoryInspectorUnsignedInteger.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC267D09D6AC74006625FE /* MemoryInspectorUnsignedInteger.m */; }; + 21FC26A609D6B6C1006625FE /* MemoryInspectorDWSignedInteger.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC26A509D6B6C1006625FE /* MemoryInspectorDWSignedInteger.m */; }; + 21FC26AE09D6C2A8006625FE /* MemoryInspectorDWUnsignedInteger.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC26AD09D6C2A8006625FE /* MemoryInspectorDWUnsignedInteger.m */; }; + 21FC26D009D85F91006625FE /* MemoryInspectorFPP8AFPFloatingPoint.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC26CF09D85F91006625FE /* MemoryInspectorFPP8AFPFloatingPoint.m */; }; + 21FC281509DB1B54006625FE /* MemoryInspectorFPP8AEPFloatingPoint.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC281409DB1B54006625FE /* MemoryInspectorFPP8AEPFloatingPoint.m */; }; + 21FC282109DC7545006625FE /* MemoryInspectorFortranIIFloatingPoint.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FC282009DC7545006625FE /* MemoryInspectorFortranIIFloatingPoint.m */; }; + 21FFA87909379A9800BA35C5 /* TableCornerView.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FFA87809379A9800BA35C5 /* TableCornerView.m */; }; + 21FFA8DD0937B46800BA35C5 /* SkipController.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FFA8DC0937B46800BA35C5 /* SkipController.m */; }; + 21FFAA970938A8A600BA35C5 /* skipArrow.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21FFAA960938A8A600BA35C5 /* skipArrow.tiff */; }; + 21FFAAC00938C04700BA35C5 /* interruptArrow.tiff in Resources */ = {isa = PBXBuildFile; fileRef = 21FFAABF0938C04700BA35C5 /* interruptArrow.tiff */; }; + 21FFAF860D62287D000B4CA5 /* TypeaheadBuffer.m in Sources */ = {isa = PBXBuildFile; fileRef = 21FFAF850D62287D000B4CA5 /* TypeaheadBuffer.m */; }; + 8D11072A0486CEB800E47090 /* MainMenu.nib in Resources */ = {isa = PBXBuildFile; fileRef = 29B97318FDCFA39411CA2CEA /* MainMenu.nib */; }; + 8D11072B0486CEB800E47090 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */; }; + 8D11072D0486CEB800E47090 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 29B97316FDCFA39411CA2CEA /* main.m */; settings = {ATTRIBUTES = (); }; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 210916C7097168E7001F160B /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 210915E809715375001F160B; + remoteInfo = GeneralPreferences; + }; + 210F36350BC9177B00482109 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 210F34680BC79DC000482109; + remoteInfo = Plugin.framework; + }; + 2126BE4D098183AA008BB678 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 2126BDFE09817C6D008BB678; + remoteInfo = CPUPreferences; + }; + 2128EA3A109786FD00CA858C /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 210F34680BC79DC000482109; + remoteInfo = Plugin.framework; + }; + 2139F84B0D6760D500836D7B /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 21BC383D0BD5402D00A37D35; + remoteInfo = ASR33; + }; + 2165B0971098D5CB00E61A92 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 2128EA38109786FD00CA858C; + remoteInfo = TSC8; + }; + 2181CE27109EDC480026FAA5 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 210F34680BC79DC000482109; + remoteInfo = Plugin.framework; + }; + 2181CEB7109EE3820026FAA5 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 2181CE25109EDC480026FAA5; + remoteInfo = KC8EA; + }; + 21A683AC0D68760C000D5B59 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 210F34680BC79DC000482109; + remoteInfo = Plugin.framework; + }; + 21A683AE0D68760F000D5B59 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 21A682FE0D685C73000D5B59; + remoteInfo = ASR33Preferences; + }; + 21B36BC61982EE0200EE4AD8 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 210F34680BC79DC000482109; + remoteInfo = Plugin.framework; + }; + 21B36CD61983EC6500EE4AD8 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 21B36BC41982EE0200EE4AD8; + remoteInfo = "PC8-E"; + }; + 21BC38950BD5694400A37D35 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 8D1107260486CEB800E47090; + remoteInfo = Simulator; + }; + 21E8F9870D7338BF00634911 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 210F34680BC79DC000482109; + remoteInfo = Plugin.framework; + }; + 21E8FA040D733CD200634911 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 29B97313FDCFA39411CA2CEA /* Project object */; + proxyType = 1; + remoteGlobalIDString = 21E8F9850D7338BF00634911; + remoteInfo = RK8E; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXCopyFilesBuildPhase section */ + 210916B10971665E001F160B /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 12; + files = ( + 2126BE4109818341008BB678 /* CPUPreferences.prefPane in CopyFiles */, + 210916B309716681001F160B /* GeneralPreferences.prefPane in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 210F36090BC9157B00482109 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 10; + files = ( + 21D47449108A46C3006A5154 /* PluginFramework.framework in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2128EA48109786FD00CA858C /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 12; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2139F8600D67610900836D7B /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 13; + files = ( + 21207555116A63DB007C1A7E /* ASR 33 Console Teletype.pdp8Plugin in CopyFiles */, + 21207556116A63DC007C1A7E /* RK8-E Disk Cartridge System.pdp8Plugin in CopyFiles */, + 2181CEDF109EE3CA0026FAA5 /* KC8-EA Programmer’s Console.pdp8Plugin in CopyFiles */, + 21207660116A643A007C1A7E /* TSC8-75 Board.pdp8Plugin in CopyFiles */, + 21B36CE21983ECA700EE4AD8 /* PC8-E Paper Tape Reader & Punch.pdp8Plugin in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2181CE32109EDC480026FAA5 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 12; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21A684360D69C012000D5B59 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 12; + files = ( + 21A684390D69C05F000D5B59 /* ASR33Preferences.prefPane in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21B36BE11982EE0200EE4AD8 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 12; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21E8F99A0D7338BF00634911 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = ""; + dstSubfolderSpec = 12; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 089C165DFE840E0CC02AAC07 /* English */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = ""; }; + 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = /System/Library/Frameworks/Cocoa.framework; sourceTree = ""; }; + 2108571F0D6B813D0084490C /* English */ = {isa = PBXFileReference; comments = "Stylesheet and icon are hard links to resources in the simulators online help"; lastKnownFileType = folder; name = English; path = ASR33/English.lproj/ASR33OnlineHelp; sourceTree = ""; }; + 2108575E0D6B8B540084490C /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = ASR33/English.lproj/InfoPlist.strings; sourceTree = ""; }; + 210910C7096042D5001F160B /* BootstrapPanelController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BootstrapPanelController.h; sourceTree = ""; }; + 210910C8096042D5001F160B /* BootstrapPanelController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BootstrapPanelController.m; sourceTree = ""; }; + 210911670962BC43001F160B /* binLoader.rim */ = {isa = PBXFileReference; lastKnownFileType = file; path = binLoader.rim; sourceTree = ""; }; + 210911BE0962F734001F160B /* lowspeedRIM.bin */ = {isa = PBXFileReference; lastKnownFileType = archive.macbinary; path = lowspeedRIM.bin; sourceTree = ""; }; + 210911C00962F74D001F160B /* highspeedRIM.bin */ = {isa = PBXFileReference; lastKnownFileType = archive.macbinary; path = highspeedRIM.bin; sourceTree = ""; }; + 210911E109640856001F160B /* rk8eBootcode.bin */ = {isa = PBXFileReference; lastKnownFileType = archive.macbinary; path = rk8eBootcode.bin; sourceTree = ""; }; + 210913B50966A3BA001F160B /* resetToolbarIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = resetToolbarIcon.tiff; sourceTree = ""; }; + 21091511096C30A5001F160B /* PreferencesController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PreferencesController.h; sourceTree = ""; }; + 21091512096C30A5001F160B /* PreferencesController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PreferencesController.m; sourceTree = ""; }; + 210915E909715375001F160B /* GeneralPreferences.prefPane */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = GeneralPreferences.prefPane; sourceTree = BUILT_PRODUCTS_DIR; }; + 210915EA09715375001F160B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = Info.plist; path = GeneralPreferences/Info.plist; sourceTree = ""; }; + 210915F6097154D7001F160B /* PreferencePanes.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = PreferencePanes.framework; path = /System/Library/Frameworks/PreferencePanes.framework; sourceTree = ""; }; + 21091606097156F3001F160B /* GeneralPreferences.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GeneralPreferences.h; path = GeneralPreferences/GeneralPreferences.h; sourceTree = ""; }; + 2109163E09715B0B001F160B /* PDP-8:E Simulator.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "PDP-8:E Simulator.app"; sourceTree = BUILT_PRODUCTS_DIR; }; + 210916D609716A38001F160B /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = GeneralPreferences/English.lproj/GeneralPreferences.nib; sourceTree = ""; }; + 21098E1A086595E1005945C4 /* breakpoint.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = breakpoint.tiff; sourceTree = ""; }; + 21098E1B086595E1005945C4 /* breakOpcode.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = breakOpcode.tiff; sourceTree = ""; }; + 21098E21086598AD005945C4 /* breakOpcodeS.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = breakOpcodeS.tiff; sourceTree = ""; }; + 21098E22086598AD005945C4 /* breakOpcodeU.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = breakOpcodeU.tiff; sourceTree = ""; }; + 21098E290865AFCE005945C4 /* pcArrowBlue.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = pcArrowBlue.tiff; sourceTree = ""; }; + 210D333B10933D71002CF77D /* tty-backspace.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; name = "tty-backspace.mp3"; path = "ASR33/tty-backspace.mp3"; sourceTree = ""; }; + 210D333C10933D71002CF77D /* tty-bell.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; name = "tty-bell.mp3"; path = "ASR33/tty-bell.mp3"; sourceTree = ""; }; + 210D333D10933D71002CF77D /* tty-carriage-return.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; name = "tty-carriage-return.mp3"; path = "ASR33/tty-carriage-return.mp3"; sourceTree = ""; }; + 210D333E10933D71002CF77D /* tty-keystroke1.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; name = "tty-keystroke1.mp3"; path = "ASR33/tty-keystroke1.mp3"; sourceTree = ""; }; + 210D333F10933D71002CF77D /* tty-space.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; name = "tty-space.mp3"; path = "ASR33/tty-space.mp3"; sourceTree = ""; }; + 210D3377109347DF002CF77D /* SpeakerLoud.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = SpeakerLoud.png; path = ASR33/SpeakerLoud.png; sourceTree = ""; }; + 210D3378109347DF002CF77D /* SpeakerQuiet.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = SpeakerQuiet.png; path = ASR33/SpeakerQuiet.png; sourceTree = ""; }; + 210F34840BC8F9EC00482109 /* PluginManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = PluginManager.h; path = Plugins/PluginManager.h; sourceTree = ""; }; + 210F34850BC8F9EC00482109 /* PluginManager.m */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 8; lastKnownFileType = sourcecode.c.objc; name = PluginManager.m; path = Plugins/PluginManager.m; sourceTree = ""; tabWidth = 8; usesTabs = 1; }; + 210F34920BC8FC3400482109 /* PluginAPI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = PluginAPI.h; path = Plugins/PluginAPI.h; sourceTree = ""; }; + 210F35E20BC90C8500482109 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = Plugins/Info.plist; sourceTree = ""; }; + 211589090868764B0007B9B0 /* PDP8.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PDP8.h; sourceTree = ""; }; + 2115890A0868764B0007B9B0 /* PDP8.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PDP8.m; sourceTree = ""; }; + 2115891C08687E3D0007B9B0 /* mri.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mri.h; sourceTree = ""; }; + 2115895F086887E80007B9B0 /* pdp8defines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = pdp8defines.h; sourceTree = ""; }; + 2115DC2D0D539B5500102889 /* FileDropControlTargetProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileDropControlTargetProtocol.h; sourceTree = ""; }; + 2115DC2E0D539B5500102889 /* NSControl+FileDrop.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSControl+FileDrop.m"; sourceTree = ""; }; + 2115DE240D55FF2D00102889 /* NSControl+FileDrop.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSControl+FileDrop.h"; sourceTree = ""; }; + 21163E020D4D278800F5B564 /* KeepInMenuWindow.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = KeepInMenuWindow.m; path = Utilities/KeepInMenuWindow.m; sourceTree = ""; }; + 21163F470D4D51EF00F5B564 /* NonWrappingTableView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NonWrappingTableView.h; sourceTree = ""; }; + 21163F870D4E3A3000F5B564 /* KeepInMenuWindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = KeepInMenuWindow.h; path = Utilities/KeepInMenuWindow.h; sourceTree = ""; }; + 211C61BB198BE6420005DA7D /* NSThread+MainThread.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSThread+MainThread.h"; sourceTree = ""; }; + 211C61BC198BE6420005DA7D /* NSThread+MainThread.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSThread+MainThread.m"; sourceTree = ""; }; + 211DA8380BC91C5500F042A3 /* PluginFramework.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = PluginFramework.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 211EF3A90BFC561000851FF1 /* ASR33TextView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ASR33TextView.h; path = ASR33/ASR33TextView.h; sourceTree = ""; }; + 211EF3AA0BFC561000851FF1 /* ASR33TextView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ASR33TextView.m; path = ASR33/ASR33TextView.m; sourceTree = ""; }; + 2126BE0909817C6D008BB678 /* CPUPreferences.prefPane */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = CPUPreferences.prefPane; sourceTree = BUILT_PRODUCTS_DIR; }; + 2126BE0E09817D4B008BB678 /* CPUPreferences.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CPUPreferences.h; sourceTree = ""; }; + 2126BE0F09817D4B008BB678 /* CPUPreferences.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CPUPreferences.m; sourceTree = ""; }; + 2126BE1109817D4B008BB678 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = English.lproj/CPUPreferences.nib; sourceTree = ""; }; + 2126BE1209817D4B008BB678 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 2126E0F810580DA5003B4706 /* English */ = {isa = PBXFileReference; lastKnownFileType = folder; name = English; path = RK8E/English.lproj/RK8EOnlineHelp; sourceTree = ""; }; + 212879F90BD574BE00F5FC00 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = ASR33/Info.plist; sourceTree = ""; }; + 2128E94E109505FB00CA858C /* tty-keystroke2.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; name = "tty-keystroke2.mp3"; path = "ASR33/tty-keystroke2.mp3"; sourceTree = ""; }; + 2128E95C109612C200CA858C /* tty-keystroke3.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; name = "tty-keystroke3.mp3"; path = "ASR33/tty-keystroke3.mp3"; sourceTree = ""; }; + 2128E95D109612C200CA858C /* tty-keystroke4.mp3 */ = {isa = PBXFileReference; lastKnownFileType = audio.mp3; name = "tty-keystroke4.mp3"; path = "ASR33/tty-keystroke4.mp3"; sourceTree = ""; }; + 2128EA30109773AA00CA858C /* bracket.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = bracket.png; sourceTree = ""; }; + 2128EA4E109786FD00CA858C /* TSC8-75 Board.pdp8Plugin */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "TSC8-75 Board.pdp8Plugin"; sourceTree = BUILT_PRODUCTS_DIR; }; + 2128EAE410978B2B00CA858C /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = TSC8/Info.plist; sourceTree = ""; }; + 2128EAFF10978D9900CA858C /* InfoPlist.strings */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = InfoPlist.strings; path = TSC8/English.lproj/InfoPlist.strings; sourceTree = ""; }; + 2128EB0F10978E5A00CA858C /* TSC8.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TSC8.h; path = TSC8/TSC8.h; sourceTree = ""; }; + 2128EB1010978E5A00CA858C /* TSC8.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TSC8.m; path = TSC8/TSC8.m; sourceTree = ""; }; + 2133910009B8E2B300F2C028 /* MemoryInspectorProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MemoryInspectorProtocol.h; path = MemoryInspector/MemoryInspectorProtocol.h; sourceTree = ""; }; + 2133910609B8E43900F2C028 /* MemoryInspectorController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MemoryInspectorController.h; path = MemoryInspector/MemoryInspectorController.h; sourceTree = ""; }; + 2133910709B8E43900F2C028 /* MemoryInspectorController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorController.m; path = MemoryInspector/MemoryInspectorController.m; sourceTree = ""; }; + 2133917009BA24FF00F2C028 /* MemoryInspector6BitASCII.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspector6BitASCII.m; path = MemoryInspector/MemoryInspector6BitASCII.m; sourceTree = ""; }; + 2133AE700D78A1630023A41A /* RK05Controller.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RK05Controller.h; path = RK8E/RK05Controller.h; sourceTree = ""; }; + 2133AE710D78A1630023A41A /* RK05Controller.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RK05Controller.m; path = RK8E/RK05Controller.m; sourceTree = ""; }; + 2133AED00D78B9940023A41A /* RK05.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RK05.h; path = RK8E/RK05.h; sourceTree = ""; }; + 2133AED10D78B9940023A41A /* RK05.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RK05.m; path = RK8E/RK05.m; sourceTree = ""; }; + 2133B3420D7F22200023A41A /* EnableDisableTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = EnableDisableTextField.h; path = Utilities/EnableDisableTextField.h; sourceTree = ""; }; + 2133B3430D7F22200023A41A /* EnableDisableTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = EnableDisableTextField.m; path = Utilities/EnableDisableTextField.m; sourceTree = ""; }; + 2133B3950D7F2B150023A41A /* RK8Eiot.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = RK8Eiot.c; path = RK8E/RK8Eiot.c; sourceTree = ""; }; + 2133B3970D7F2B7E0023A41A /* RK8Eiot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RK8Eiot.h; path = RK8E/RK8Eiot.h; sourceTree = ""; }; + 2134E97B0986C14F00D74DC4 /* generalPrefIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; name = generalPrefIcon.tiff; path = GeneralPreferences/generalPrefIcon.tiff; sourceTree = ""; }; + 2139F73B0D67433700836D7B /* NSFileManager+Additions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSFileManager+Additions.h"; sourceTree = ""; }; + 2139F73C0D67433700836D7B /* NSFileManager+Additions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSFileManager+Additions.m"; sourceTree = ""; }; + 2139F8B00D6763BF00836D7B /* ASR 33 Console Teletype.pdp8Plugin */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "ASR 33 Console Teletype.pdp8Plugin"; sourceTree = BUILT_PRODUCTS_DIR; }; + 213AE24B09F422E50028A0E7 /* pdp8e.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = pdp8e.icns; sourceTree = ""; }; + 213AE2C409F6D7750028A0E7 /* English */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.html; name = English; path = English.lproj/Credits.html; sourceTree = ""; }; + 214362F20860D45700DB186F /* stepToolbarIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = stepToolbarIcon.tiff; sourceTree = ""; }; + 214362F30860D45700DB186F /* stopToolbarIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = stopToolbarIcon.tiff; sourceTree = ""; }; + 214362F40860D45700DB186F /* traceToolbarIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = traceToolbarIcon.tiff; sourceTree = ""; }; + 214363000860D9BE00DB186F /* goToolbarIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = goToolbarIcon.tiff; sourceTree = ""; }; + 214429A009EAE8B800271635 /* English */ = {isa = PBXFileReference; lastKnownFileType = folder; name = English; path = English.lproj/OnlineHelp; sourceTree = ""; }; + 2147853F09F6F32500A32CFE /* bb.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = bb.tiff; sourceTree = ""; }; + 2149F8380D82AD930084F33F /* Utilities.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = Utilities.c; path = Utilities/Utilities.c; sourceTree = ""; }; + 2159F23B08689ACF002186B0 /* mri.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = mri.c; sourceTree = ""; }; + 2159F2450868A3B8002186B0 /* eae.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = eae.c; sourceTree = ""; }; + 2159F2460868A3B8002186B0 /* eae.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = eae.h; sourceTree = ""; }; + 2159F2480868A442002186B0 /* opr.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = opr.c; sourceTree = ""; }; + 2159F2490868A442002186B0 /* opr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = opr.h; sourceTree = ""; }; + 2159F2530868A639002186B0 /* iot.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = iot.c; sourceTree = ""; }; + 2159F2540868A639002186B0 /* iot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iot.h; sourceTree = ""; }; + 2159F26C0869CE7D002186B0 /* English */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.plist.xml; name = English; path = English.lproj/disassembler.plist; sourceTree = ""; }; + 2159F2720869DB1A002186B0 /* Disassembler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Disassembler.h; sourceTree = ""; }; + 2159F2730869DB1A002186B0 /* Disassembler.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Disassembler.m; sourceTree = ""; }; + 2159F313086DFFAD002186B0 /* Assembler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Assembler.h; sourceTree = ""; }; + 2159F314086DFFAD002186B0 /* Assembler.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Assembler.m; sourceTree = ""; }; + 2159F50A086EBCCF002186B0 /* Opcode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Opcode.h; sourceTree = ""; }; + 2159F50B086EBCCF002186B0 /* Opcode.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Opcode.m; sourceTree = ""; }; + 2159F52B086EEEFC002186B0 /* assembler.plist */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = text.plist.xml; path = assembler.plist; sourceTree = ""; }; + 2161C49D0BE537A30008E867 /* ASR33iot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ASR33iot.h; path = ASR33/ASR33iot.h; sourceTree = ""; }; + 2161C49E0BE537A30008E867 /* ASR33iot.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = ASR33iot.c; path = ASR33/ASR33iot.c; sourceTree = ""; }; + 2161C64A0BE605AF0008E867 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = ASR33/English.lproj/ASR33.nib; sourceTree = ""; }; + 2161C6600BE66DCC0008E867 /* ASR33WindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ASR33WindowController.h; path = ASR33/ASR33WindowController.h; sourceTree = ""; }; + 2161C6610BE66DCC0008E867 /* ASR33WindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ASR33WindowController.m; path = ASR33/ASR33WindowController.m; sourceTree = ""; }; + 2165B0051097924100E61A92 /* TSC8iot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TSC8iot.h; path = TSC8/TSC8iot.h; sourceTree = ""; }; + 2165B00C109795D900E61A92 /* TSC8iot.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = TSC8iot.c; path = TSC8/TSC8iot.c; sourceTree = ""; }; + 2165B01810979BCA00E61A92 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = English; path = "TSC8/English.lproj/io-info.plist"; sourceTree = ""; }; + 2165B0431098C80500E61A92 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = TSC8/English.lproj/TSC8.nib; sourceTree = ""; }; + 216792D00D4505A200666543 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = English; path = "ASR33/English.lproj/io-info.plist"; sourceTree = ""; }; + 216962610D1C21E200822F9C /* Utilities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Utilities.h; path = Utilities/Utilities.h; sourceTree = ""; }; + 216B74F90D6F4AEF00124930 /* HelpMenuManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = HelpMenuManager.h; path = Plugins/HelpMenuManager.h; sourceTree = ""; }; + 216B74FA0D6F4AEF00124930 /* HelpMenuManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = HelpMenuManager.m; path = Plugins/HelpMenuManager.m; sourceTree = ""; }; + 216B75C70D70E16A00124930 /* GeneralPreferences.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GeneralPreferences.m; path = GeneralPreferences/GeneralPreferences.m; sourceTree = ""; }; + 216B75E00D70E7D200124930 /* ASR33Preferences.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ASR33Preferences.m; path = ASR33Preferences/ASR33Preferences.m; sourceTree = ""; }; + 2171818F09FA879800754508 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = /usr/lib/libz.dylib; sourceTree = ""; }; + 217C9F9808746FBA009F9D30 /* BreakpointArray.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BreakpointArray.h; sourceTree = ""; }; + 217C9F9908746FBA009F9D30 /* BreakpointArray.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BreakpointArray.m; sourceTree = ""; }; + 2181CDC1109E21550026FAA5 /* English */ = {isa = PBXFileReference; lastKnownFileType = folder; name = English; path = TSC8/English.lproj/TSC8OnlineHelp; sourceTree = ""; }; + 2181CE38109EDC480026FAA5 /* KC8-EA Programmer’s Console.pdp8Plugin */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "KC8-EA Programmer’s Console.pdp8Plugin"; sourceTree = BUILT_PRODUCTS_DIR; }; + 2181CE39109EDC480026FAA5 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = Info.plist; path = KC8EA/Info.plist; sourceTree = ""; }; + 2181CE82109EE1D10026FAA5 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = KC8EA/English.lproj/KC8EA.nib; sourceTree = ""; }; + 2181CEA6109EE2D80026FAA5 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = KC8EA/English.lproj/InfoPlist.strings; sourceTree = ""; }; + 2181CEAB109EE3130026FAA5 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = English; path = "KC8EA/English.lproj/io-info.plist"; sourceTree = ""; }; + 2181CEFE109EE4130026FAA5 /* KC8EA.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = KC8EA.h; path = KC8EA/KC8EA.h; sourceTree = ""; }; + 2181CEFF109EE4130026FAA5 /* KC8EA.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = KC8EA.m; path = KC8EA/KC8EA.m; sourceTree = ""; }; + 2181CF20109EEE5F0026FAA5 /* BackgroundView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BackgroundView.h; path = KC8EA/BackgroundView.h; sourceTree = ""; }; + 2181CF21109EEE5F0026FAA5 /* BackgroundView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = BackgroundView.m; path = KC8EA/BackgroundView.m; sourceTree = ""; }; + 2181CF45109EF7940026FAA5 /* background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = background.png; path = KC8EA/background.png; sourceTree = ""; }; + 2181CFEB109F1D170026FAA5 /* light_off.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = light_off.png; path = KC8EA/light_off.png; sourceTree = ""; }; + 2181CFEC109F1D170026FAA5 /* light_on.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = light_on.png; path = KC8EA/light_on.png; sourceTree = ""; }; + 2181D03810A0C41A0026FAA5 /* sr0down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr0down.png; path = KC8EA/sr0down.png; sourceTree = ""; }; + 2181D03910A0C41A0026FAA5 /* sr0up_sr1down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr0up_sr1down.png; path = KC8EA/sr0up_sr1down.png; sourceTree = ""; }; + 2181D03A10A0C41A0026FAA5 /* sr0up_sr1up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr0up_sr1up.png; path = KC8EA/sr0up_sr1up.png; sourceTree = ""; }; + 2181D03B10A0C41A0026FAA5 /* sr1down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr1down.png; path = KC8EA/sr1down.png; sourceTree = ""; }; + 2181D03C10A0C41A0026FAA5 /* sr1up_sr2down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr1up_sr2down.png; path = KC8EA/sr1up_sr2down.png; sourceTree = ""; }; + 2181D03D10A0C41A0026FAA5 /* sr1up_sr2up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr1up_sr2up.png; path = KC8EA/sr1up_sr2up.png; sourceTree = ""; }; + 2181D03F10A0C41A0026FAA5 /* sr2up_sr3down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr2up_sr3down.png; path = KC8EA/sr2up_sr3down.png; sourceTree = ""; }; + 2181D04010A0C41A0026FAA5 /* sr2up_sr3up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr2up_sr3up.png; path = KC8EA/sr2up_sr3up.png; sourceTree = ""; }; + 2181D04110A0C41A0026FAA5 /* sr3down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr3down.png; path = KC8EA/sr3down.png; sourceTree = ""; }; + 2181D04210A0C41A0026FAA5 /* sr3up_sr4down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr3up_sr4down.png; path = KC8EA/sr3up_sr4down.png; sourceTree = ""; }; + 2181D04310A0C41A0026FAA5 /* sr3up_sr4up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr3up_sr4up.png; path = KC8EA/sr3up_sr4up.png; sourceTree = ""; }; + 2181D04410A0C41A0026FAA5 /* sr4down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr4down.png; path = KC8EA/sr4down.png; sourceTree = ""; }; + 2181D04510A0C41A0026FAA5 /* sr4up_sr5down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr4up_sr5down.png; path = KC8EA/sr4up_sr5down.png; sourceTree = ""; }; + 2181D04610A0C41A0026FAA5 /* sr4up_sr5up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr4up_sr5up.png; path = KC8EA/sr4up_sr5up.png; sourceTree = ""; }; + 2181D04710A0C41A0026FAA5 /* sr5down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr5down.png; path = KC8EA/sr5down.png; sourceTree = ""; }; + 2181D04810A0C41A0026FAA5 /* sr5up_sr6down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr5up_sr6down.png; path = KC8EA/sr5up_sr6down.png; sourceTree = ""; }; + 2181D04910A0C41A0026FAA5 /* sr5up_sr6up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr5up_sr6up.png; path = KC8EA/sr5up_sr6up.png; sourceTree = ""; }; + 2181D04A10A0C41A0026FAA5 /* sr6down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr6down.png; path = KC8EA/sr6down.png; sourceTree = ""; }; + 2181D04B10A0C41A0026FAA5 /* sr6up_sr7down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr6up_sr7down.png; path = KC8EA/sr6up_sr7down.png; sourceTree = ""; }; + 2181D04C10A0C41A0026FAA5 /* sr6up_sr7up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr6up_sr7up.png; path = KC8EA/sr6up_sr7up.png; sourceTree = ""; }; + 2181D04D10A0C41A0026FAA5 /* sr7down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr7down.png; path = KC8EA/sr7down.png; sourceTree = ""; }; + 2181D05010A0C41A0026FAA5 /* sr8down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr8down.png; path = KC8EA/sr8down.png; sourceTree = ""; }; + 2181D05110A0C41A0026FAA5 /* sr8up_sr9down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr8up_sr9down.png; path = KC8EA/sr8up_sr9down.png; sourceTree = ""; }; + 2181D05210A0C41A0026FAA5 /* sr8up_sr9up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr8up_sr9up.png; path = KC8EA/sr8up_sr9up.png; sourceTree = ""; }; + 2181D05310A0C41A0026FAA5 /* sr9down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr9down.png; path = KC8EA/sr9down.png; sourceTree = ""; }; + 2181D05410A0C41A0026FAA5 /* sr9up_sr10down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr9up_sr10down.png; path = KC8EA/sr9up_sr10down.png; sourceTree = ""; }; + 2181D05510A0C41A0026FAA5 /* sr9up_sr10up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr9up_sr10up.png; path = KC8EA/sr9up_sr10up.png; sourceTree = ""; }; + 2181D05610A0C41A0026FAA5 /* sr10down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr10down.png; path = KC8EA/sr10down.png; sourceTree = ""; }; + 2181D05710A0C41A0026FAA5 /* sr10up_sr11down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr10up_sr11down.png; path = KC8EA/sr10up_sr11down.png; sourceTree = ""; }; + 2181D05810A0C41A0026FAA5 /* sr10up_sr11up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr10up_sr11up.png; path = KC8EA/sr10up_sr11up.png; sourceTree = ""; }; + 2181D0A910A0CAF20026FAA5 /* sr2down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr2down.png; path = KC8EA/sr2down.png; sourceTree = ""; }; + 2181D0AB10A0CC550026FAA5 /* sr11down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr11down.png; path = KC8EA/sr11down.png; sourceTree = ""; }; + 2181D0B510A0D2E10026FAA5 /* sr11up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr11up.png; path = KC8EA/sr11up.png; sourceTree = ""; }; + 2181D0C210A0D61E0026FAA5 /* sr7up_sr8down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr7up_sr8down.png; path = KC8EA/sr7up_sr8down.png; sourceTree = ""; }; + 2181D0C310A0D61E0026FAA5 /* sr7up_sr8up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sr7up_sr8up.png; path = KC8EA/sr7up_sr8up.png; sourceTree = ""; }; + 2181D19F10A0FF3D0026FAA5 /* ConsoleSwitchCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ConsoleSwitchCell.h; path = KC8EA/ConsoleSwitchCell.h; sourceTree = ""; }; + 2181D1A010A0FF3D0026FAA5 /* ConsoleSwitchCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ConsoleSwitchCell.m; path = KC8EA/ConsoleSwitchCell.m; sourceTree = ""; }; + 2181D41710A2072E0026FAA5 /* sw_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sw_down.png; path = KC8EA/sw_down.png; sourceTree = ""; }; + 2181D41810A2072E0026FAA5 /* sw_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = sw_up.png; path = KC8EA/sw_up.png; sourceTree = ""; }; + 2181D53210A475770026FAA5 /* addrload_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = addrload_down.png; path = KC8EA/addrload_down.png; sourceTree = ""; }; + 2181D53310A475770026FAA5 /* addrload_up_extdaddrload_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = addrload_up_extdaddrload_down.png; path = KC8EA/addrload_up_extdaddrload_down.png; sourceTree = ""; }; + 2181D53410A475770026FAA5 /* addrload_up_extdaddrload_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = addrload_up_extdaddrload_up.png; path = KC8EA/addrload_up_extdaddrload_up.png; sourceTree = ""; }; + 2181D59B10A47E010026FAA5 /* extdaddrload_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = extdaddrload_down.png; path = KC8EA/extdaddrload_down.png; sourceTree = ""; }; + 2181D59C10A47E010026FAA5 /* extdaddrload_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = extdaddrload_up.png; path = KC8EA/extdaddrload_up.png; sourceTree = ""; }; + 2181D5D510A4A0550026FAA5 /* clear_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = clear_down.png; path = KC8EA/clear_down.png; sourceTree = ""; }; + 2181D5D610A4A0550026FAA5 /* clear_up_cont_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = clear_up_cont_down.png; path = KC8EA/clear_up_cont_down.png; sourceTree = ""; }; + 2181D5D710A4A0550026FAA5 /* clear_up_cont_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = clear_up_cont_up.png; path = KC8EA/clear_up_cont_up.png; sourceTree = ""; }; + 2181D5DF10A4A1400026FAA5 /* cont_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = cont_down.png; path = KC8EA/cont_down.png; sourceTree = ""; }; + 2181D5E010A4A1400026FAA5 /* cont_up_exam_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = cont_up_exam_down.png; path = KC8EA/cont_up_exam_down.png; sourceTree = ""; }; + 2181D5E110A4A1400026FAA5 /* cont_up_exam_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = cont_up_exam_up.png; path = KC8EA/cont_up_exam_up.png; sourceTree = ""; }; + 2181D5E510A4A2760026FAA5 /* exam_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = exam_down.png; path = KC8EA/exam_down.png; sourceTree = ""; }; + 2181D5E610A4A2760026FAA5 /* exam_up_halt_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = exam_up_halt_down.png; path = KC8EA/exam_up_halt_down.png; sourceTree = ""; }; + 2181D5E710A4A2760026FAA5 /* exam_up_halt_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = exam_up_halt_up.png; path = KC8EA/exam_up_halt_up.png; sourceTree = ""; }; + 2181D5EB10A4A2F90026FAA5 /* halt_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = halt_down.png; path = KC8EA/halt_down.png; sourceTree = ""; }; + 2181D5EC10A4A2F90026FAA5 /* halt_up_singstep_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = halt_up_singstep_down.png; path = KC8EA/halt_up_singstep_down.png; sourceTree = ""; }; + 2181D5ED10A4A2F90026FAA5 /* halt_up_singstep_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = halt_up_singstep_up.png; path = KC8EA/halt_up_singstep_up.png; sourceTree = ""; }; + 2181D5F110A4A39C0026FAA5 /* singstep_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = singstep_down.png; path = KC8EA/singstep_down.png; sourceTree = ""; }; + 2181D5F210A4A39C0026FAA5 /* singstep_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = singstep_up.png; path = KC8EA/singstep_up.png; sourceTree = ""; }; + 2181D63610A5E2210026FAA5 /* dep_down.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = dep_down.png; path = KC8EA/dep_down.png; sourceTree = ""; }; + 2181D63710A5E2210026FAA5 /* dep_up.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = dep_up.png; path = KC8EA/dep_up.png; sourceTree = ""; }; + 2181D69710A6196D0026FAA5 /* knob0.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = knob0.png; path = KC8EA/knob0.png; sourceTree = ""; }; + 2181D69810A6196D0026FAA5 /* knob1.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = knob1.png; path = KC8EA/knob1.png; sourceTree = ""; }; + 2181D69910A6196D0026FAA5 /* knob2.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = knob2.png; path = KC8EA/knob2.png; sourceTree = ""; }; + 2181D69A10A6196D0026FAA5 /* knob3.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = knob3.png; path = KC8EA/knob3.png; sourceTree = ""; }; + 2181D69B10A6196D0026FAA5 /* knob4.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = knob4.png; path = KC8EA/knob4.png; sourceTree = ""; }; + 2181D69C10A6196D0026FAA5 /* knob5.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = knob5.png; path = KC8EA/knob5.png; sourceTree = ""; }; + 2181D6AD10A620E30026FAA5 /* KnobCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = KnobCell.h; path = KC8EA/KnobCell.h; sourceTree = ""; }; + 2181D6AE10A620E30026FAA5 /* KnobCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = KnobCell.m; path = KC8EA/KnobCell.m; sourceTree = ""; }; + 2181D7BB10A706870026FAA5 /* key0.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = key0.png; path = KC8EA/key0.png; sourceTree = ""; }; + 2181D7BC10A706870026FAA5 /* key1.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = key1.png; path = KC8EA/key1.png; sourceTree = ""; }; + 2181D7BD10A706870026FAA5 /* key2.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = key2.png; path = KC8EA/key2.png; sourceTree = ""; }; + 2189C6D308707ABA00BA6C42 /* BreakpointController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BreakpointController.h; sourceTree = ""; }; + 2189C6D408707ABA00BA6C42 /* BreakpointController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BreakpointController.m; sourceTree = ""; }; + 21909693198FDA16003AD39C /* English */ = {isa = PBXFileReference; lastKnownFileType = folder; name = English; path = PC8E/English.lproj/PC8EOnlineHelp; sourceTree = ""; }; + 219097D519912B13003AD39C /* plugin.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = plugin.icns; sourceTree = ""; }; + 219097DB199134EE003AD39C /* papertape.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = papertape.icns; sourceTree = ""; }; + 219097EB1991452A003AD39C /* decpack.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = decpack.icns; sourceTree = ""; }; + 2190D60110A98F50004E5E38 /* StateMachine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = StateMachine.h; path = KC8EA/StateMachine.h; sourceTree = ""; }; + 2190D60210A98F50004E5E38 /* StateMachine.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = StateMachine.m; path = KC8EA/StateMachine.m; sourceTree = ""; }; + 21919F060879CD8300DC0727 /* Breakpoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Breakpoint.h; sourceTree = ""; }; + 21919F070879CD8300DC0727 /* Breakpoint.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Breakpoint.m; sourceTree = ""; }; + 219FBCE71983ED89005C5220 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = English; path = "PC8E/English.lproj/io-info.plist"; sourceTree = ""; }; + 21A682FF0D685C73000D5B59 /* ASR33Preferences.prefPane */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ASR33Preferences.prefPane; sourceTree = BUILT_PRODUCTS_DIR; }; + 21A683000D685C73000D5B59 /* Info.plist */ = {isa = PBXFileReference; explicitFileType = text.xml; name = Info.plist; path = ASR33Preferences/Info.plist; sourceTree = ""; }; + 21A683410D6862FF000D5B59 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = ASR33Preferences/English.lproj/ASR33Preferences.nib; sourceTree = ""; }; + 21A683940D686C17000D5B59 /* asr33PrefIcon.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; name = asr33PrefIcon.jpg; path = ASR33Preferences/asr33PrefIcon.jpg; sourceTree = ""; }; + 21A6839F0D68758E000D5B59 /* cpuPrefIcon.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = cpuPrefIcon.jpg; sourceTree = ""; }; + 21A683CD0D688C32000D5B59 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = English.lproj/InfoPlist.strings; sourceTree = ""; }; + 21A683D10D688D2A000D5B59 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = GeneralPreferences/English.lproj/InfoPlist.strings; sourceTree = ""; }; + 21A683EF0D688DE4000D5B59 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = ASR33Preferences/English.lproj/InfoPlist.strings; sourceTree = ""; }; + 21A6853F0D6A0EF2000D5B59 /* ASR33Preferences.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ASR33Preferences.h; path = ASR33Preferences/ASR33Preferences.h; sourceTree = ""; }; + 21AAEE4B09B6522300E55A42 /* memoryInspectorToolbarIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = memoryInspectorToolbarIcon.tiff; sourceTree = ""; }; + 21AE0F0D085B43A00051FF07 /* CPUWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CPUWindowController.h; sourceTree = ""; }; + 21AE0F0E085B43A00051FF07 /* CPUWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CPUWindowController.m; sourceTree = ""; }; + 21AE0F10085B43A60051FF07 /* MainController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MainController.h; sourceTree = ""; }; + 21AE0F11085B43A60051FF07 /* MainController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MainController.m; sourceTree = ""; }; + 21B36BE81982EE0200EE4AD8 /* PC8-E Paper Tape Reader & Punch.pdp8Plugin */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "PC8-E Paper Tape Reader & Punch.pdp8Plugin"; sourceTree = BUILT_PRODUCTS_DIR; }; + 21B36C531982F0ED00EE4AD8 /* PC8E.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = PC8E.h; path = PC8E/PC8E.h; sourceTree = ""; }; + 21B36C541982F0ED00EE4AD8 /* PC8E.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = PC8E.m; path = PC8E/PC8E.m; sourceTree = ""; }; + 21B36C5E1983C64D00EE4AD8 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = PC8E/Info.plist; sourceTree = ""; }; + 21B36CB81983CE2800EE4AD8 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = PC8E/English.lproj/InfoPlist.strings; sourceTree = ""; }; + 21B36CCB1983D55600EE4AD8 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = PC8E/English.lproj/PC8E.nib; sourceTree = ""; }; + 21B8420B0D454D3100BD583A /* auxtty-io-info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "auxtty-io-info.plist"; path = "ASR33/English.lproj/auxtty-io-info.plist"; sourceTree = ""; }; + 21BC37B70BD515C000A37D35 /* PluginAPI.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = PluginAPI.m; path = Plugins/PluginAPI.m; sourceTree = ""; }; + 21BC384C0BD541A700A37D35 /* ASR33.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ASR33.h; path = ASR33/ASR33.h; sourceTree = ""; }; + 21BC384D0BD541A700A37D35 /* ASR33.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ASR33.m; path = ASR33/ASR33.m; sourceTree = ""; }; + 21BC47F30CC214CB00AA6F38 /* PaperTapeController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = PaperTapeController.m; path = Utilities/PaperTapeController.m; sourceTree = ""; }; + 21BC481E0CC216E200AA6F38 /* PaperTapeController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = PaperTapeController.h; path = Utilities/PaperTapeController.h; sourceTree = ""; }; + 21C7F22F09BCB2B2002BBEB7 /* MemoryInspector8BitASCII.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspector8BitASCII.m; path = MemoryInspector/MemoryInspector8BitASCII.m; sourceTree = ""; }; + 21CAB0E30876A61C00E9005D /* OpcodeFormatter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OpcodeFormatter.h; sourceTree = ""; }; + 21CAB0E40876A61C00E9005D /* OpcodeFormatter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = OpcodeFormatter.m; sourceTree = ""; }; + 21CAB17D0876C7E000E9005D /* breakpointsToolbarIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = breakpointsToolbarIcon.tiff; sourceTree = ""; }; + 21CAB1FA0876E9DD00E9005D /* OctalFormatter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OctalFormatter.h; path = Utilities/OctalFormatter.h; sourceTree = ""; }; + 21CAB1FB0876E9DD00E9005D /* OctalFormatter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OctalFormatter.m; path = Utilities/OctalFormatter.m; sourceTree = ""; }; + 21CAB2940877DC7800E9005D /* NSMutableArray+BinarySearch.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSMutableArray+BinarySearch.h"; sourceTree = ""; }; + 21CAB2950877DC7800E9005D /* NSMutableArray+BinarySearch.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSMutableArray+BinarySearch.m"; sourceTree = ""; }; + 21CF5C9D09194DC700377059 /* RegisterFormCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RegisterFormCell.m; path = Utilities/RegisterFormCell.m; sourceTree = ""; }; + 21CF5C9E09194DC700377059 /* RegisterFormCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RegisterFormCell.h; path = Utilities/RegisterFormCell.h; sourceTree = ""; }; + 21CF5F97091CF4ED00377059 /* CPUMemoryViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CPUMemoryViewController.h; sourceTree = ""; }; + 21CF5F9C091CF61F00377059 /* CPUMemoryViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CPUMemoryViewController.m; sourceTree = ""; }; + 21CF5FA6091D089600377059 /* IOFlagController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IOFlagController.h; sourceTree = ""; }; + 21CF5FA7091D089600377059 /* IOFlagController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = IOFlagController.m; sourceTree = ""; }; + 21CF60CD09200C9D00377059 /* itab.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = itab.c; sourceTree = ""; }; + 21CF60CE09200C9D00377059 /* itab.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = itab.h; sourceTree = ""; }; + 21D9432C13F7E4C600086135 /* PaperTapeProgressIndicator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = PaperTapeProgressIndicator.h; path = Utilities/PaperTapeProgressIndicator.h; sourceTree = ""; }; + 21D9432D13F7E4C600086135 /* PaperTapeProgressIndicator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = PaperTapeProgressIndicator.m; path = Utilities/PaperTapeProgressIndicator.m; sourceTree = ""; }; + 21DC5A4909C77583000F3908 /* alignMemoryArrow.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = alignMemoryArrow.tiff; sourceTree = ""; }; + 21DC5DC209CC3E4A000F3908 /* NonWrappingTableView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NonWrappingTableView.m; sourceTree = ""; }; + 21DC5FDF09D0B3CA000F3908 /* Unicode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Unicode.h; path = Utilities/Unicode.h; sourceTree = ""; }; + 21E1D4AC198550F6002E2DDC /* PC8Eiot.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = PC8Eiot.c; path = PC8E/PC8Eiot.c; sourceTree = ""; }; + 21E1D4AD198550F6002E2DDC /* PC8Eiot.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = PC8Eiot.h; path = PC8E/PC8Eiot.h; sourceTree = ""; }; + 21E8F8F80D721A7B00634911 /* pcArrowGraphite.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = pcArrowGraphite.tiff; sourceTree = ""; }; + 21E8F9A10D7338BF00634911 /* RK8-E Disk Cartridge System.pdp8Plugin */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "RK8-E Disk Cartridge System.pdp8Plugin"; sourceTree = BUILT_PRODUCTS_DIR; }; + 21E8F9CF0D73398E00634911 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = RK8E/English.lproj/RK8E.nib; sourceTree = ""; }; + 21E8F9F10D733BFC00634911 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = RK8E/Info.plist; sourceTree = ""; }; + 21E8F9F50D733C2B00634911 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = English; path = RK8E/English.lproj/InfoPlist.strings; sourceTree = ""; }; + 21E8FAB00D73603D00634911 /* RK8E.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RK8E.h; path = RK8E/RK8E.h; sourceTree = ""; }; + 21E8FAB10D73603D00634911 /* RK8E.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RK8E.m; path = RK8E/RK8E.m; sourceTree = ""; }; + 21E8FAD80D73622100634911 /* English */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = English; path = "RK8E/English.lproj/io-info.plist"; sourceTree = ""; }; + 21E8FBD40D75FF2400634911 /* RK8EController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = RK8EController.h; path = RK8E/RK8EController.h; sourceTree = ""; }; + 21E8FBD50D75FF2400634911 /* RK8EController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = RK8EController.m; path = RK8E/RK8EController.m; sourceTree = ""; }; + 21F556080949FC6500DA4AB8 /* NSTableView+Scrolling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSTableView+Scrolling.h"; sourceTree = ""; }; + 21F556090949FC6500DA4AB8 /* NSTableView+Scrolling.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSTableView+Scrolling.m"; sourceTree = ""; }; + 21F568CB0956152900DA4AB8 /* bootstrapToolbarIcon.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = bootstrapToolbarIcon.tiff; sourceTree = ""; }; + 21F96F0F10B08D1E00D51223 /* English */ = {isa = PBXFileReference; lastKnownFileType = folder; name = English; path = KC8EA/English.lproj/KC8EAOnlineHelp; sourceTree = ""; }; + 21FC250009D32AF0006625FE /* MemoryInspectorOS8Packed8BitASCII.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorOS8Packed8BitASCII.m; path = MemoryInspector/MemoryInspectorOS8Packed8BitASCII.m; sourceTree = ""; }; + 21FC259109D36137006625FE /* Carbon.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Carbon.framework; path = /System/Library/Frameworks/Carbon.framework; sourceTree = ""; }; + 21FC261D09D5E76B006625FE /* MemoryInspectorSignedInteger.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorSignedInteger.m; path = MemoryInspector/MemoryInspectorSignedInteger.m; sourceTree = ""; }; + 21FC267D09D6AC74006625FE /* MemoryInspectorUnsignedInteger.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorUnsignedInteger.m; path = MemoryInspector/MemoryInspectorUnsignedInteger.m; sourceTree = ""; }; + 21FC26A509D6B6C1006625FE /* MemoryInspectorDWSignedInteger.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorDWSignedInteger.m; path = MemoryInspector/MemoryInspectorDWSignedInteger.m; sourceTree = ""; }; + 21FC26AD09D6C2A8006625FE /* MemoryInspectorDWUnsignedInteger.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorDWUnsignedInteger.m; path = MemoryInspector/MemoryInspectorDWUnsignedInteger.m; sourceTree = ""; }; + 21FC26B109D6DAF3006625FE /* FloatingPointNumber.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = FloatingPointNumber.h; path = Utilities/FloatingPointNumber.h; sourceTree = ""; }; + 21FC26B209D6DAF3006625FE /* FloatingPointNumber.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = FloatingPointNumber.m; path = Utilities/FloatingPointNumber.m; sourceTree = ""; }; + 21FC26CF09D85F91006625FE /* MemoryInspectorFPP8AFPFloatingPoint.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorFPP8AFPFloatingPoint.m; path = MemoryInspector/MemoryInspectorFPP8AFPFloatingPoint.m; sourceTree = ""; }; + 21FC281409DB1B54006625FE /* MemoryInspectorFPP8AEPFloatingPoint.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorFPP8AEPFloatingPoint.m; path = MemoryInspector/MemoryInspectorFPP8AEPFloatingPoint.m; sourceTree = ""; }; + 21FC282009DC7545006625FE /* MemoryInspectorFortranIIFloatingPoint.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorFortranIIFloatingPoint.m; path = MemoryInspector/MemoryInspectorFortranIIFloatingPoint.m; sourceTree = ""; }; + 21FC28AE09DD9040006625FE /* MemoryInspectorPascalSFloatingPoint.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MemoryInspectorPascalSFloatingPoint.m; path = MemoryInspector/MemoryInspectorPascalSFloatingPoint.m; sourceTree = ""; }; + 21FFA87709379A9800BA35C5 /* TableCornerView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TableCornerView.h; sourceTree = ""; }; + 21FFA87809379A9800BA35C5 /* TableCornerView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TableCornerView.m; sourceTree = ""; }; + 21FFA8DB0937B46800BA35C5 /* SkipController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SkipController.h; sourceTree = ""; }; + 21FFA8DC0937B46800BA35C5 /* SkipController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SkipController.m; sourceTree = ""; }; + 21FFAA960938A8A600BA35C5 /* skipArrow.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = skipArrow.tiff; sourceTree = ""; }; + 21FFAABF0938C04700BA35C5 /* interruptArrow.tiff */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = interruptArrow.tiff; sourceTree = ""; }; + 21FFAF840D62287D000B4CA5 /* TypeaheadBuffer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TypeaheadBuffer.h; path = ASR33/TypeaheadBuffer.h; sourceTree = ""; }; + 21FFAF850D62287D000B4CA5 /* TypeaheadBuffer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = TypeaheadBuffer.m; path = ASR33/TypeaheadBuffer.m; sourceTree = ""; }; + 21FFB01D0D623295000B4CA5 /* InputConsumerProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = InputConsumerProtocol.h; path = Utilities/InputConsumerProtocol.h; sourceTree = ""; }; + 29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; + 29B97319FDCFA39411CA2CEA /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = English.lproj/MainMenu.nib; sourceTree = ""; }; + 8D1107310486CEB800E47090 /* Info.plist */ = {isa = PBXFileReference; explicitFileType = text.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 210915E709715375001F160B /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 210915F7097154D7001F160B /* PreferencePanes.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 210F34670BC79DC000482109 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2126BE0309817C6D008BB678 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 2126BE0409817C6D008BB678 /* PreferencePanes.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2128EA46109786FD00CA858C /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 2128EA47109786FD00CA858C /* PluginFramework.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2181CE30109EDC480026FAA5 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 2181CE31109EDC480026FAA5 /* PluginFramework.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21A682FD0D685C73000D5B59 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 21A683660D6865F9000D5B59 /* PreferencePanes.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21B36BDF1982EE0200EE4AD8 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 21B36BE01982EE0200EE4AD8 /* PluginFramework.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21BC383C0BD5402D00A37D35 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 21D47462108A48AD006A5154 /* PluginFramework.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21E8F9980D7338BF00634911 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 21E8F9990D7338BF00634911 /* PluginFramework.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 8D11072E0486CEB800E47090 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 218BA93A09B0EC1600ABA09E /* Cocoa.framework in Frameworks */, + 21FC259209D36137006625FE /* Carbon.framework in Frameworks */, + 2171819009FA879800754508 /* libz.dylib in Frameworks */, + 219FBD2E1983F98B005C5220 /* PluginFramework.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 080E96DDFE201D6D7F000001 /* Panels */ = { + isa = PBXGroup; + children = ( + 2189C6D308707ABA00BA6C42 /* BreakpointController.h */, + 2189C6D408707ABA00BA6C42 /* BreakpointController.m */, + 210910C7096042D5001F160B /* BootstrapPanelController.h */, + 210910C8096042D5001F160B /* BootstrapPanelController.m */, + 21091511096C30A5001F160B /* PreferencesController.h */, + 21091512096C30A5001F160B /* PreferencesController.m */, + ); + path = Panels; + sourceTree = ""; + }; + 19C28FACFE9D520D11CA2CBB /* Products */ = { + isa = PBXGroup; + children = ( + 2126BE0909817C6D008BB678 /* CPUPreferences.prefPane */, + 210915E909715375001F160B /* GeneralPreferences.prefPane */, + 211DA8380BC91C5500F042A3 /* PluginFramework.framework */, + 21A682FF0D685C73000D5B59 /* ASR33Preferences.prefPane */, + 2139F8B00D6763BF00836D7B /* ASR 33 Console Teletype.pdp8Plugin */, + 21E8F9A10D7338BF00634911 /* RK8-E Disk Cartridge System.pdp8Plugin */, + 2128EA4E109786FD00CA858C /* TSC8-75 Board.pdp8Plugin */, + 2181CE38109EDC480026FAA5 /* KC8-EA Programmer’s Console.pdp8Plugin */, + 21B36BE81982EE0200EE4AD8 /* PC8-E Paper Tape Reader & Punch.pdp8Plugin */, + 2109163E09715B0B001F160B /* PDP-8:E Simulator.app */, + ); + name = Products; + sourceTree = ""; + }; + 2109160309715677001F160B /* GeneralPreferences */ = { + isa = PBXGroup; + children = ( + 21091606097156F3001F160B /* GeneralPreferences.h */, + 216B75C70D70E16A00124930 /* GeneralPreferences.m */, + 21EE4D38098168D5002FF438 /* GeneralPreferences.nib */, + 2134E97B0986C14F00D74DC4 /* generalPrefIcon.tiff */, + 210915EA09715375001F160B /* Info.plist */, + 21A683D30D688D38000D5B59 /* InfoPlist.strings */, + ); + name = GeneralPreferences; + sourceTree = ""; + }; + 2109161609715798001F160B /* Simulator */ = { + isa = PBXGroup; + children = ( + 21F556130949FC9500DA4AB8 /* Categories */, + 21CAB1F20876E7AE00E9005D /* Utilities */, + 080E96DDFE201D6D7F000001 /* Panels */, + 210F34810BC8F99F00482109 /* Plugins */, + 21DC5BD909C8D398000F3908 /* CPUWindow */, + 21DC5BDC09C8D3E1000F3908 /* MemoryInspector */, + 2115892608687E540007B9B0 /* Emulation */, + 29B97315FDCFA39411CA2CEA /* Main */, + 29B97317FDCFA39411CA2CEA /* Resources */, + ); + name = Simulator; + sourceTree = ""; + }; + 210D333910933D50002CF77D /* Resources */ = { + isa = PBXGroup; + children = ( + 212879F90BD574BE00F5FC00 /* Info.plist */, + 210857600D6B8B630084490C /* InfoPlist.strings */, + 21B8420A0D454D3100BD583A /* auxtty-io-info.plist */, + 216792D30D45067700666543 /* io-info.plist */, + 211638550D48082E00F5B564 /* ASR33.nib */, + 210D333B10933D71002CF77D /* tty-backspace.mp3 */, + 210D333C10933D71002CF77D /* tty-bell.mp3 */, + 210D333D10933D71002CF77D /* tty-carriage-return.mp3 */, + 210D333E10933D71002CF77D /* tty-keystroke1.mp3 */, + 2128E94E109505FB00CA858C /* tty-keystroke2.mp3 */, + 2128E95C109612C200CA858C /* tty-keystroke3.mp3 */, + 2128E95D109612C200CA858C /* tty-keystroke4.mp3 */, + 210D333F10933D71002CF77D /* tty-space.mp3 */, + ); + name = Resources; + sourceTree = ""; + }; + 210F34810BC8F99F00482109 /* Plugins */ = { + isa = PBXGroup; + children = ( + 210F34840BC8F9EC00482109 /* PluginManager.h */, + 210F34850BC8F9EC00482109 /* PluginManager.m */, + 216B74F90D6F4AEF00124930 /* HelpMenuManager.h */, + 216B74FA0D6F4AEF00124930 /* HelpMenuManager.m */, + ); + name = Plugins; + sourceTree = ""; + }; + 2115892608687E540007B9B0 /* Emulation */ = { + isa = PBXGroup; + children = ( + 211589090868764B0007B9B0 /* PDP8.h */, + 2115890A0868764B0007B9B0 /* PDP8.m */, + 2115895F086887E80007B9B0 /* pdp8defines.h */, + 21CF60CE09200C9D00377059 /* itab.h */, + 21CF60CD09200C9D00377059 /* itab.c */, + 2159F2460868A3B8002186B0 /* eae.h */, + 2159F2450868A3B8002186B0 /* eae.c */, + 2159F2540868A639002186B0 /* iot.h */, + 2159F2530868A639002186B0 /* iot.c */, + 2115891C08687E3D0007B9B0 /* mri.h */, + 2159F23B08689ACF002186B0 /* mri.c */, + 2159F2490868A442002186B0 /* opr.h */, + 2159F2480868A442002186B0 /* opr.c */, + ); + path = Emulation; + sourceTree = ""; + }; + 2126BE0D09817D4B008BB678 /* CPUPreferences */ = { + isa = PBXGroup; + children = ( + 2126BE0E09817D4B008BB678 /* CPUPreferences.h */, + 2126BE0F09817D4B008BB678 /* CPUPreferences.m */, + 2126BE1009817D4B008BB678 /* CPUPreferences.nib */, + 21A6839F0D68758E000D5B59 /* cpuPrefIcon.jpg */, + 2126BE1209817D4B008BB678 /* Info.plist */, + 21A683CF0D688C48000D5B59 /* InfoPlist.strings */, + ); + path = CPUPreferences; + sourceTree = ""; + }; + 2128EA8E109787F800CA858C /* TSC8 */ = { + isa = PBXGroup; + children = ( + 2128EAE410978B2B00CA858C /* Info.plist */, + 2128EB0110978DA300CA858C /* InfoPlist.strings */, + 2165B01710979BCA00E61A92 /* io-info.plist */, + 2128EB0F10978E5A00CA858C /* TSC8.h */, + 2128EB1010978E5A00CA858C /* TSC8.m */, + 2165B0051097924100E61A92 /* TSC8iot.h */, + 2165B00C109795D900E61A92 /* TSC8iot.c */, + 2165B05A1098D0B500E61A92 /* TSC8.nib */, + 2181CDC0109E21550026FAA5 /* TSC8OnlineHelp */, + ); + name = TSC8; + sourceTree = ""; + }; + 2181CE16109EDC1B0026FAA5 /* KC8EA */ = { + isa = PBXGroup; + children = ( + 2181CE39109EDC480026FAA5 /* Info.plist */, + 2181CEA5109EE2D80026FAA5 /* InfoPlist.strings */, + 2181CEB3109EE3690026FAA5 /* io-info.plist */, + 2181CEFE109EE4130026FAA5 /* KC8EA.h */, + 2181CEFF109EE4130026FAA5 /* KC8EA.m */, + 2190D60110A98F50004E5E38 /* StateMachine.h */, + 2190D60210A98F50004E5E38 /* StateMachine.m */, + 2181D19F10A0FF3D0026FAA5 /* ConsoleSwitchCell.h */, + 2181D1A010A0FF3D0026FAA5 /* ConsoleSwitchCell.m */, + 2181D6AD10A620E30026FAA5 /* KnobCell.h */, + 2181D6AE10A620E30026FAA5 /* KnobCell.m */, + 2181CF20109EEE5F0026FAA5 /* BackgroundView.h */, + 2181CF21109EEE5F0026FAA5 /* BackgroundView.m */, + 2181CE96109EE1E30026FAA5 /* KC8EA.nib */, + 2181D03410A0C3F70026FAA5 /* Images */, + 21F96F0E10B08D1E00D51223 /* KC8EAOnlineHelp */, + ); + name = KC8EA; + sourceTree = ""; + }; + 2181D03410A0C3F70026FAA5 /* Images */ = { + isa = PBXGroup; + children = ( + 2181D7BB10A706870026FAA5 /* key0.png */, + 2181D7BC10A706870026FAA5 /* key1.png */, + 2181D7BD10A706870026FAA5 /* key2.png */, + 2181D69710A6196D0026FAA5 /* knob0.png */, + 2181D69810A6196D0026FAA5 /* knob1.png */, + 2181D69910A6196D0026FAA5 /* knob2.png */, + 2181D69A10A6196D0026FAA5 /* knob3.png */, + 2181D69B10A6196D0026FAA5 /* knob4.png */, + 2181D69C10A6196D0026FAA5 /* knob5.png */, + 2181D63610A5E2210026FAA5 /* dep_down.png */, + 2181D63710A5E2210026FAA5 /* dep_up.png */, + 2181D5F110A4A39C0026FAA5 /* singstep_down.png */, + 2181D5F210A4A39C0026FAA5 /* singstep_up.png */, + 2181D5EB10A4A2F90026FAA5 /* halt_down.png */, + 2181D5EC10A4A2F90026FAA5 /* halt_up_singstep_down.png */, + 2181D5ED10A4A2F90026FAA5 /* halt_up_singstep_up.png */, + 2181D5E510A4A2760026FAA5 /* exam_down.png */, + 2181D5E610A4A2760026FAA5 /* exam_up_halt_down.png */, + 2181D5E710A4A2760026FAA5 /* exam_up_halt_up.png */, + 2181D5DF10A4A1400026FAA5 /* cont_down.png */, + 2181D5E010A4A1400026FAA5 /* cont_up_exam_down.png */, + 2181D5E110A4A1400026FAA5 /* cont_up_exam_up.png */, + 2181D5D510A4A0550026FAA5 /* clear_down.png */, + 2181D5D610A4A0550026FAA5 /* clear_up_cont_down.png */, + 2181D5D710A4A0550026FAA5 /* clear_up_cont_up.png */, + 2181D59B10A47E010026FAA5 /* extdaddrload_down.png */, + 2181D59C10A47E010026FAA5 /* extdaddrload_up.png */, + 2181D53210A475770026FAA5 /* addrload_down.png */, + 2181D53310A475770026FAA5 /* addrload_up_extdaddrload_down.png */, + 2181D53410A475770026FAA5 /* addrload_up_extdaddrload_up.png */, + 2181CF45109EF7940026FAA5 /* background.png */, + 2181CFEB109F1D170026FAA5 /* light_off.png */, + 2181CFEC109F1D170026FAA5 /* light_on.png */, + 2181D03810A0C41A0026FAA5 /* sr0down.png */, + 2181D03910A0C41A0026FAA5 /* sr0up_sr1down.png */, + 2181D03A10A0C41A0026FAA5 /* sr0up_sr1up.png */, + 2181D03B10A0C41A0026FAA5 /* sr1down.png */, + 2181D03C10A0C41A0026FAA5 /* sr1up_sr2down.png */, + 2181D03D10A0C41A0026FAA5 /* sr1up_sr2up.png */, + 2181D0A910A0CAF20026FAA5 /* sr2down.png */, + 2181D03F10A0C41A0026FAA5 /* sr2up_sr3down.png */, + 2181D04010A0C41A0026FAA5 /* sr2up_sr3up.png */, + 2181D04110A0C41A0026FAA5 /* sr3down.png */, + 2181D04210A0C41A0026FAA5 /* sr3up_sr4down.png */, + 2181D04310A0C41A0026FAA5 /* sr3up_sr4up.png */, + 2181D04410A0C41A0026FAA5 /* sr4down.png */, + 2181D04510A0C41A0026FAA5 /* sr4up_sr5down.png */, + 2181D04610A0C41A0026FAA5 /* sr4up_sr5up.png */, + 2181D04710A0C41A0026FAA5 /* sr5down.png */, + 2181D04810A0C41A0026FAA5 /* sr5up_sr6down.png */, + 2181D04910A0C41A0026FAA5 /* sr5up_sr6up.png */, + 2181D04A10A0C41A0026FAA5 /* sr6down.png */, + 2181D04B10A0C41A0026FAA5 /* sr6up_sr7down.png */, + 2181D04C10A0C41A0026FAA5 /* sr6up_sr7up.png */, + 2181D04D10A0C41A0026FAA5 /* sr7down.png */, + 2181D0C210A0D61E0026FAA5 /* sr7up_sr8down.png */, + 2181D0C310A0D61E0026FAA5 /* sr7up_sr8up.png */, + 2181D05010A0C41A0026FAA5 /* sr8down.png */, + 2181D05110A0C41A0026FAA5 /* sr8up_sr9down.png */, + 2181D05210A0C41A0026FAA5 /* sr8up_sr9up.png */, + 2181D05310A0C41A0026FAA5 /* sr9down.png */, + 2181D05410A0C41A0026FAA5 /* sr9up_sr10down.png */, + 2181D05510A0C41A0026FAA5 /* sr9up_sr10up.png */, + 2181D05610A0C41A0026FAA5 /* sr10down.png */, + 2181D05710A0C41A0026FAA5 /* sr10up_sr11down.png */, + 2181D05810A0C41A0026FAA5 /* sr10up_sr11up.png */, + 2181D0AB10A0CC550026FAA5 /* sr11down.png */, + 2181D0B510A0D2E10026FAA5 /* sr11up.png */, + 2181D41710A2072E0026FAA5 /* sw_down.png */, + 2181D41810A2072E0026FAA5 /* sw_up.png */, + ); + name = Images; + sourceTree = ""; + }; + 219FBDB719840683005C5220 /* PluginFramework */ = { + isa = PBXGroup; + children = ( + 210F35E20BC90C8500482109 /* Info.plist */, + 210F34920BC8FC3400482109 /* PluginAPI.h */, + 21BC37B70BD515C000A37D35 /* PluginAPI.m */, + 21DC5FDF09D0B3CA000F3908 /* Unicode.h */, + 216962610D1C21E200822F9C /* Utilities.h */, + 2149F8380D82AD930084F33F /* Utilities.c */, + 21FFB01D0D623295000B4CA5 /* InputConsumerProtocol.h */, + 21BC481E0CC216E200AA6F38 /* PaperTapeController.h */, + 21BC47F30CC214CB00AA6F38 /* PaperTapeController.m */, + 21D9432C13F7E4C600086135 /* PaperTapeProgressIndicator.h */, + 21D9432D13F7E4C600086135 /* PaperTapeProgressIndicator.m */, + 21FC26B109D6DAF3006625FE /* FloatingPointNumber.h */, + 21FC26B209D6DAF3006625FE /* FloatingPointNumber.m */, + 21CAB1FA0876E9DD00E9005D /* OctalFormatter.h */, + 21CAB1FB0876E9DD00E9005D /* OctalFormatter.m */, + 21CF5C9E09194DC700377059 /* RegisterFormCell.h */, + 21CF5C9D09194DC700377059 /* RegisterFormCell.m */, + 21163F870D4E3A3000F5B564 /* KeepInMenuWindow.h */, + 21163E020D4D278800F5B564 /* KeepInMenuWindow.m */, + 2133B3420D7F22200023A41A /* EnableDisableTextField.h */, + 2133B3430D7F22200023A41A /* EnableDisableTextField.m */, + ); + name = PluginFramework; + sourceTree = ""; + }; + 21A6830E0D685C88000D5B59 /* ASR33Preferences */ = { + isa = PBXGroup; + children = ( + 21A6853F0D6A0EF2000D5B59 /* ASR33Preferences.h */, + 216B75E00D70E7D200124930 /* ASR33Preferences.m */, + 21A683440D68631B000D5B59 /* ASR33Preferences.nib */, + 21A683940D686C17000D5B59 /* asr33PrefIcon.jpg */, + 21A683000D685C73000D5B59 /* Info.plist */, + 21A683F10D688DEC000D5B59 /* InfoPlist.strings */, + 210D3377109347DF002CF77D /* SpeakerLoud.png */, + 210D3378109347DF002CF77D /* SpeakerQuiet.png */, + ); + name = ASR33Preferences; + sourceTree = ""; + }; + 21B36C4E1982F08C00EE4AD8 /* PC8E */ = { + isa = PBXGroup; + children = ( + 21B36C5E1983C64D00EE4AD8 /* Info.plist */, + 21B36CBA1983CE4500EE4AD8 /* InfoPlist.strings */, + 219FBCE61983ED89005C5220 /* io-info.plist */, + 21B36C531982F0ED00EE4AD8 /* PC8E.h */, + 21B36C541982F0ED00EE4AD8 /* PC8E.m */, + 21E1D4AD198550F6002E2DDC /* PC8Eiot.h */, + 21E1D4AC198550F6002E2DDC /* PC8Eiot.c */, + 21B36CCA1983D55600EE4AD8 /* PC8E.nib */, + 21909692198FDA16003AD39C /* PC8EOnlineHelp */, + ); + name = PC8E; + sourceTree = ""; + }; + 21BC384B0BD5415500A37D35 /* ASR33 */ = { + isa = PBXGroup; + children = ( + 21BC384C0BD541A700A37D35 /* ASR33.h */, + 21BC384D0BD541A700A37D35 /* ASR33.m */, + 2161C49D0BE537A30008E867 /* ASR33iot.h */, + 2161C49E0BE537A30008E867 /* ASR33iot.c */, + 2161C6600BE66DCC0008E867 /* ASR33WindowController.h */, + 2161C6610BE66DCC0008E867 /* ASR33WindowController.m */, + 211EF3A90BFC561000851FF1 /* ASR33TextView.h */, + 211EF3AA0BFC561000851FF1 /* ASR33TextView.m */, + 21FFAF840D62287D000B4CA5 /* TypeaheadBuffer.h */, + 21FFAF850D62287D000B4CA5 /* TypeaheadBuffer.m */, + 210D333910933D50002CF77D /* Resources */, + 210857230D6B81500084490C /* ASR33OnlineHelp */, + ); + name = ASR33; + sourceTree = ""; + }; + 21CAB1F20876E7AE00E9005D /* Utilities */ = { + isa = PBXGroup; + children = ( + 21919F060879CD8300DC0727 /* Breakpoint.h */, + 21919F070879CD8300DC0727 /* Breakpoint.m */, + 217C9F9808746FBA009F9D30 /* BreakpointArray.h */, + 217C9F9908746FBA009F9D30 /* BreakpointArray.m */, + 2159F50A086EBCCF002186B0 /* Opcode.h */, + 2159F50B086EBCCF002186B0 /* Opcode.m */, + 21CAB0E30876A61C00E9005D /* OpcodeFormatter.h */, + 21CAB0E40876A61C00E9005D /* OpcodeFormatter.m */, + 2159F313086DFFAD002186B0 /* Assembler.h */, + 2159F314086DFFAD002186B0 /* Assembler.m */, + 2159F2720869DB1A002186B0 /* Disassembler.h */, + 2159F2730869DB1A002186B0 /* Disassembler.m */, + 21FFA87709379A9800BA35C5 /* TableCornerView.h */, + 21FFA87809379A9800BA35C5 /* TableCornerView.m */, + 21163F470D4D51EF00F5B564 /* NonWrappingTableView.h */, + 21DC5DC209CC3E4A000F3908 /* NonWrappingTableView.m */, + ); + path = Utilities; + sourceTree = ""; + }; + 21DC5BD909C8D398000F3908 /* CPUWindow */ = { + isa = PBXGroup; + children = ( + 21AE0F0D085B43A00051FF07 /* CPUWindowController.h */, + 21AE0F0E085B43A00051FF07 /* CPUWindowController.m */, + 21CF5F97091CF4ED00377059 /* CPUMemoryViewController.h */, + 21CF5F9C091CF61F00377059 /* CPUMemoryViewController.m */, + 21CF5FA6091D089600377059 /* IOFlagController.h */, + 21CF5FA7091D089600377059 /* IOFlagController.m */, + 21FFA8DB0937B46800BA35C5 /* SkipController.h */, + 21FFA8DC0937B46800BA35C5 /* SkipController.m */, + ); + path = CPUWindow; + sourceTree = ""; + }; + 21DC5BDC09C8D3E1000F3908 /* MemoryInspector */ = { + isa = PBXGroup; + children = ( + 2133910009B8E2B300F2C028 /* MemoryInspectorProtocol.h */, + 2133910609B8E43900F2C028 /* MemoryInspectorController.h */, + 2133910709B8E43900F2C028 /* MemoryInspectorController.m */, + 2133917009BA24FF00F2C028 /* MemoryInspector6BitASCII.m */, + 21C7F22F09BCB2B2002BBEB7 /* MemoryInspector8BitASCII.m */, + 21FC250009D32AF0006625FE /* MemoryInspectorOS8Packed8BitASCII.m */, + 21FC261D09D5E76B006625FE /* MemoryInspectorSignedInteger.m */, + 21FC267D09D6AC74006625FE /* MemoryInspectorUnsignedInteger.m */, + 21FC26A509D6B6C1006625FE /* MemoryInspectorDWSignedInteger.m */, + 21FC26AD09D6C2A8006625FE /* MemoryInspectorDWUnsignedInteger.m */, + 21FC26CF09D85F91006625FE /* MemoryInspectorFPP8AFPFloatingPoint.m */, + 21FC281409DB1B54006625FE /* MemoryInspectorFPP8AEPFloatingPoint.m */, + 21FC282009DC7545006625FE /* MemoryInspectorFortranIIFloatingPoint.m */, + 21FC28AE09DD9040006625FE /* MemoryInspectorPascalSFloatingPoint.m */, + ); + name = MemoryInspector; + sourceTree = ""; + }; + 21E8F95F0D73387F00634911 /* RK8E */ = { + isa = PBXGroup; + children = ( + 21E8F9F10D733BFC00634911 /* Info.plist */, + 21E8F9F70D733C3300634911 /* InfoPlist.strings */, + 21E8FAD70D73622100634911 /* io-info.plist */, + 21E8FAB00D73603D00634911 /* RK8E.h */, + 21E8FAB10D73603D00634911 /* RK8E.m */, + 2133B3970D7F2B7E0023A41A /* RK8Eiot.h */, + 2133B3950D7F2B150023A41A /* RK8Eiot.c */, + 21E8FBD40D75FF2400634911 /* RK8EController.h */, + 21E8FBD50D75FF2400634911 /* RK8EController.m */, + 2133AED00D78B9940023A41A /* RK05.h */, + 2133AED10D78B9940023A41A /* RK05.m */, + 2133AE700D78A1630023A41A /* RK05Controller.h */, + 2133AE710D78A1630023A41A /* RK05Controller.m */, + 2126DEC61052F0E2003B4706 /* RK8E.nib */, + 2126E0F710580DA5003B4706 /* RK8EOnlineHelp */, + ); + name = RK8E; + sourceTree = ""; + }; + 21F556130949FC9500DA4AB8 /* Categories */ = { + isa = PBXGroup; + children = ( + 211C61BB198BE6420005DA7D /* NSThread+MainThread.h */, + 211C61BC198BE6420005DA7D /* NSThread+MainThread.m */, + 21CAB2940877DC7800E9005D /* NSMutableArray+BinarySearch.h */, + 21CAB2950877DC7800E9005D /* NSMutableArray+BinarySearch.m */, + 21F556080949FC6500DA4AB8 /* NSTableView+Scrolling.h */, + 21F556090949FC6500DA4AB8 /* NSTableView+Scrolling.m */, + 2139F73B0D67433700836D7B /* NSFileManager+Additions.h */, + 2139F73C0D67433700836D7B /* NSFileManager+Additions.m */, + 2115DE240D55FF2D00102889 /* NSControl+FileDrop.h */, + 2115DC2E0D539B5500102889 /* NSControl+FileDrop.m */, + 2115DC2D0D539B5500102889 /* FileDropControlTargetProtocol.h */, + ); + path = Categories; + sourceTree = ""; + }; + 29B97314FDCFA39411CA2CEA /* pdp8e-simulator2 */ = { + isa = PBXGroup; + children = ( + 2181CE16109EDC1B0026FAA5 /* KC8EA */, + 2128EA8E109787F800CA858C /* TSC8 */, + 21E8F95F0D73387F00634911 /* RK8E */, + 21BC384B0BD5415500A37D35 /* ASR33 */, + 21A6830E0D685C88000D5B59 /* ASR33Preferences */, + 21B36C4E1982F08C00EE4AD8 /* PC8E */, + 2126BE0D09817D4B008BB678 /* CPUPreferences */, + 2109160309715677001F160B /* GeneralPreferences */, + 219FBDB719840683005C5220 /* PluginFramework */, + 2109161609715798001F160B /* Simulator */, + 29B97323FDCFA39411CA2CEA /* Frameworks */, + 19C28FACFE9D520D11CA2CBB /* Products */, + ); + name = "pdp8e-simulator2"; + sourceTree = ""; + }; + 29B97315FDCFA39411CA2CEA /* Main */ = { + isa = PBXGroup; + children = ( + 29B97316FDCFA39411CA2CEA /* main.m */, + 21AE0F10085B43A60051FF07 /* MainController.h */, + 21AE0F11085B43A60051FF07 /* MainController.m */, + ); + path = Main; + sourceTree = ""; + }; + 29B97317FDCFA39411CA2CEA /* Resources */ = { + isa = PBXGroup; + children = ( + 8D1107310486CEB800E47090 /* Info.plist */, + 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */, + 213AE24B09F422E50028A0E7 /* pdp8e.icns */, + 219097D519912B13003AD39C /* plugin.icns */, + 219097DB199134EE003AD39C /* papertape.icns */, + 219097EB1991452A003AD39C /* decpack.icns */, + 2159F52B086EEEFC002186B0 /* assembler.plist */, + 2159F26E0869CE98002186B0 /* disassembler.plist */, + 210911670962BC43001F160B /* binLoader.rim */, + 210911C00962F74D001F160B /* highspeedRIM.bin */, + 210911BE0962F734001F160B /* lowspeedRIM.bin */, + 210911E109640856001F160B /* rk8eBootcode.bin */, + 2128EA30109773AA00CA858C /* bracket.png */, + 21098E290865AFCE005945C4 /* pcArrowBlue.tiff */, + 21E8F8F80D721A7B00634911 /* pcArrowGraphite.tiff */, + 21098E1A086595E1005945C4 /* breakpoint.tiff */, + 21098E1B086595E1005945C4 /* breakOpcode.tiff */, + 21098E21086598AD005945C4 /* breakOpcodeS.tiff */, + 21098E22086598AD005945C4 /* breakOpcodeU.tiff */, + 21CAB17D0876C7E000E9005D /* breakpointsToolbarIcon.tiff */, + 21F568CB0956152900DA4AB8 /* bootstrapToolbarIcon.tiff */, + 214363000860D9BE00DB186F /* goToolbarIcon.tiff */, + 210913B50966A3BA001F160B /* resetToolbarIcon.tiff */, + 214362F20860D45700DB186F /* stepToolbarIcon.tiff */, + 214362F30860D45700DB186F /* stopToolbarIcon.tiff */, + 214362F40860D45700DB186F /* traceToolbarIcon.tiff */, + 21AAEE4B09B6522300E55A42 /* memoryInspectorToolbarIcon.tiff */, + 21FFAA960938A8A600BA35C5 /* skipArrow.tiff */, + 21FFAABF0938C04700BA35C5 /* interruptArrow.tiff */, + 21DC5A4909C77583000F3908 /* alignMemoryArrow.tiff */, + 2147853F09F6F32500A32CFE /* bb.tiff */, + 213AE2C309F6D7750028A0E7 /* Credits.html */, + 29B97318FDCFA39411CA2CEA /* MainMenu.nib */, + 2144299F09EAE8B800271635 /* OnlineHelp */, + ); + path = Resources; + sourceTree = ""; + }; + 29B97323FDCFA39411CA2CEA /* Frameworks */ = { + isa = PBXGroup; + children = ( + 21FC259109D36137006625FE /* Carbon.framework */, + 1058C7A1FEA54F0111CA2CBB /* Cocoa.framework */, + 2171818F09FA879800754508 /* libz.dylib */, + 210915F6097154D7001F160B /* PreferencePanes.framework */, + ); + name = Frameworks; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXHeadersBuildPhase section */ + 210F34640BC79DC000482109 /* Headers */ = { + isa = PBXHeadersBuildPhase; + buildActionMask = 2147483647; + files = ( + 211DAA8E0BC9246E00F042A3 /* PluginAPI.h in Headers */, + 21BC366F0BD506C400A37D35 /* PDP8.h in Headers */, + 217868690BF7A00A00FC1DA7 /* RegisterFormCell.h in Headers */, + 2178686C0BF7A01D00FC1DA7 /* OctalFormatter.h in Headers */, + 216962620D1C220100822F9C /* Utilities.h in Headers */, + 211639F40D4B8F7B00F5B564 /* FloatingPointNumber.h in Headers */, + 21163B5C0D4BE3EF00F5B564 /* MemoryInspectorProtocol.h in Headers */, + 21163FA30D4E3DA600F5B564 /* KeepInMenuWindow.h in Headers */, + 2115DC310D539FCC00102889 /* FileDropControlTargetProtocol.h in Headers */, + 2115DE250D55FF2D00102889 /* NSControl+FileDrop.h in Headers */, + 2139F73F0D6744A200836D7B /* NSFileManager+Additions.h in Headers */, + 21163E210D4D2C6B00F5B564 /* NSMutableArray+BinarySearch.h in Headers */, + 21163E220D4D2C6F00F5B564 /* NSTableView+Scrolling.h in Headers */, + 2133B3450D7F22260023A41A /* EnableDisableTextField.h in Headers */, + 21E6757B1500D997006F9F91 /* Unicode.h in Headers */, + 219FBDA01984064A005C5220 /* InputConsumerProtocol.h in Headers */, + 219FBDA11984064C005C5220 /* PaperTapeController.h in Headers */, + 219FBDA31984064E005C5220 /* PaperTapeProgressIndicator.h in Headers */, + 2191521E1991796A0033DC01 /* NSThread+MainThread.h in Headers */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXHeadersBuildPhase section */ + +/* Begin PBXNativeTarget section */ + 210915E809715375001F160B /* GeneralPreferences */ = { + isa = PBXNativeTarget; + buildConfigurationList = 210915EC09715377001F160B /* Build configuration list for PBXNativeTarget "GeneralPreferences" */; + buildPhases = ( + 210915E509715375001F160B /* Resources */, + 210915E609715375001F160B /* Sources */, + 210915E709715375001F160B /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = GeneralPreferences; + productName = GeneralPreferences; + productReference = 210915E909715375001F160B /* GeneralPreferences.prefPane */; + productType = "com.apple.product-type.bundle"; + }; + 210F34680BC79DC000482109 /* Plugin.framework */ = { + isa = PBXNativeTarget; + buildConfigurationList = 210F346B0BC79DC100482109 /* Build configuration list for PBXNativeTarget "Plugin.framework" */; + buildPhases = ( + 210F34640BC79DC000482109 /* Headers */, + 210F34650BC79DC000482109 /* Resources */, + 210F34660BC79DC000482109 /* Sources */, + 210F34670BC79DC000482109 /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Plugin.framework; + productName = PluginFramework; + productReference = 211DA8380BC91C5500F042A3 /* PluginFramework.framework */; + productType = "com.apple.product-type.framework"; + }; + 2126BDFE09817C6D008BB678 /* CPUPreferences */ = { + isa = PBXNativeTarget; + buildConfigurationList = 2126BE0509817C6D008BB678 /* Build configuration list for PBXNativeTarget "CPUPreferences" */; + buildPhases = ( + 2126BDFF09817C6D008BB678 /* Resources */, + 2126BE0109817C6D008BB678 /* Sources */, + 2126BE0309817C6D008BB678 /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = CPUPreferences; + productName = GeneralPreferences; + productReference = 2126BE0909817C6D008BB678 /* CPUPreferences.prefPane */; + productType = "com.apple.product-type.bundle"; + }; + 2128EA38109786FD00CA858C /* TSC8 */ = { + isa = PBXNativeTarget; + buildConfigurationList = 2128EA4A109786FD00CA858C /* Build configuration list for PBXNativeTarget "TSC8" */; + buildPhases = ( + 2128EA3B109786FD00CA858C /* Resources */, + 2128EA40109786FD00CA858C /* Sources */, + 2128EA46109786FD00CA858C /* Frameworks */, + 2128EA48109786FD00CA858C /* CopyFiles */, + 2128EA49109786FD00CA858C /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + 2128EA39109786FD00CA858C /* PBXTargetDependency */, + ); + name = TSC8; + productName = ASR33; + productReference = 2128EA4E109786FD00CA858C /* TSC8-75 Board.pdp8Plugin */; + productType = "com.apple.product-type.bundle"; + }; + 2181CE25109EDC480026FAA5 /* KC8EA */ = { + isa = PBXNativeTarget; + buildConfigurationList = 2181CE34109EDC480026FAA5 /* Build configuration list for PBXNativeTarget "KC8EA" */; + buildPhases = ( + 2181CE28109EDC480026FAA5 /* Resources */, + 2181CE2D109EDC480026FAA5 /* Sources */, + 2181CE30109EDC480026FAA5 /* Frameworks */, + 2181CE32109EDC480026FAA5 /* CopyFiles */, + 2181CE33109EDC480026FAA5 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + 2181CE26109EDC480026FAA5 /* PBXTargetDependency */, + ); + name = KC8EA; + productName = ASR33; + productReference = 2181CE38109EDC480026FAA5 /* KC8-EA Programmer’s Console.pdp8Plugin */; + productType = "com.apple.product-type.bundle"; + }; + 21A682FE0D685C73000D5B59 /* ASR33Preferences */ = { + isa = PBXNativeTarget; + buildConfigurationList = 21A683040D685C74000D5B59 /* Build configuration list for PBXNativeTarget "ASR33Preferences" */; + buildPhases = ( + 21A682FB0D685C73000D5B59 /* Resources */, + 21A682FC0D685C73000D5B59 /* Sources */, + 21A682FD0D685C73000D5B59 /* Frameworks */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = ASR33Preferences; + productName = ASR33Preferences; + productReference = 21A682FF0D685C73000D5B59 /* ASR33Preferences.prefPane */; + productType = "com.apple.product-type.bundle"; + }; + 21B36BC41982EE0200EE4AD8 /* PC8-E */ = { + isa = PBXNativeTarget; + buildConfigurationList = 21B36BE41982EE0200EE4AD8 /* Build configuration list for PBXNativeTarget "PC8-E" */; + buildPhases = ( + 21B36BC91982EE0200EE4AD8 /* Resources */, + 21B36BD71982EE0200EE4AD8 /* Sources */, + 21B36BDF1982EE0200EE4AD8 /* Frameworks */, + 21B36BE11982EE0200EE4AD8 /* CopyFiles */, + 21B36BE31982EE0200EE4AD8 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + 21B36BC51982EE0200EE4AD8 /* PBXTargetDependency */, + ); + name = "PC8-E"; + productName = ASR33; + productReference = 21B36BE81982EE0200EE4AD8 /* PC8-E Paper Tape Reader & Punch.pdp8Plugin */; + productType = "com.apple.product-type.bundle"; + }; + 21BC383D0BD5402D00A37D35 /* ASR33 */ = { + isa = PBXNativeTarget; + buildConfigurationList = 21BC38470BD5402E00A37D35 /* Build configuration list for PBXNativeTarget "ASR33" */; + buildPhases = ( + 21BC383A0BD5402D00A37D35 /* Resources */, + 21BC383B0BD5402D00A37D35 /* Sources */, + 21BC383C0BD5402D00A37D35 /* Frameworks */, + 21A684360D69C012000D5B59 /* CopyFiles */, + 21BC387B0BD567BA00A37D35 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + 21A683AD0D68760C000D5B59 /* PBXTargetDependency */, + 21A683AF0D68760F000D5B59 /* PBXTargetDependency */, + ); + name = ASR33; + productName = ASR33; + productReference = 2139F8B00D6763BF00836D7B /* ASR 33 Console Teletype.pdp8Plugin */; + productType = "com.apple.product-type.bundle"; + }; + 21E8F9850D7338BF00634911 /* RK8E */ = { + isa = PBXNativeTarget; + buildConfigurationList = 21E8F99D0D7338BF00634911 /* Build configuration list for PBXNativeTarget "RK8E" */; + buildPhases = ( + 21E8F98A0D7338BF00634911 /* Resources */, + 21E8F9900D7338BF00634911 /* Sources */, + 21E8F9980D7338BF00634911 /* Frameworks */, + 21E8F99A0D7338BF00634911 /* CopyFiles */, + 21E8F99C0D7338BF00634911 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + 21E8F9860D7338BF00634911 /* PBXTargetDependency */, + ); + name = RK8E; + productName = ASR33; + productReference = 21E8F9A10D7338BF00634911 /* RK8-E Disk Cartridge System.pdp8Plugin */; + productType = "com.apple.product-type.bundle"; + }; + 8D1107260486CEB800E47090 /* Simulator */ = { + isa = PBXNativeTarget; + buildConfigurationList = 21AE0EF2085B43480051FF07 /* Build configuration list for PBXNativeTarget "Simulator" */; + buildPhases = ( + 8D1107290486CEB800E47090 /* Resources */, + 8D11072C0486CEB800E47090 /* Sources */, + 8D11072E0486CEB800E47090 /* Frameworks */, + 210916B10971665E001F160B /* CopyFiles */, + 210F36090BC9157B00482109 /* CopyFiles */, + 2139F8600D67610900836D7B /* CopyFiles */, + 21232F180D6767DF009E21A6 /* ShellScript */, + ); + buildRules = ( + ); + comments = "Debug Product Name without \"/\", otherwise gdb cannot find the symbol files\n"; + dependencies = ( + 2126BE4E098183AA008BB678 /* PBXTargetDependency */, + 210916C8097168E7001F160B /* PBXTargetDependency */, + 210F36360BC9177B00482109 /* PBXTargetDependency */, + 2139F84C0D6760D500836D7B /* PBXTargetDependency */, + 21E8FA050D733CD200634911 /* PBXTargetDependency */, + 2165B0981098D5CB00E61A92 /* PBXTargetDependency */, + 2181CEB8109EE3820026FAA5 /* PBXTargetDependency */, + 21B36CD71983EC6500EE4AD8 /* PBXTargetDependency */, + ); + name = Simulator; + productInstallPath = "$(HOME)/Applications"; + productName = "pdp8e-simulator2"; + productReference = 2109163E09715B0B001F160B /* PDP-8:E Simulator.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 29B97313FDCFA39411CA2CEA /* Project object */ = { + isa = PBXProject; + buildConfigurationList = 21AE0EF6085B43480051FF07 /* Build configuration list for PBXProject "pdp8e-simulator" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 1; + knownRegions = ( + English, + Japanese, + French, + German, + ); + mainGroup = 29B97314FDCFA39411CA2CEA /* pdp8e-simulator2 */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 2126BDFE09817C6D008BB678 /* CPUPreferences */, + 210915E809715375001F160B /* GeneralPreferences */, + 210F34680BC79DC000482109 /* Plugin.framework */, + 21A682FE0D685C73000D5B59 /* ASR33Preferences */, + 21BC383D0BD5402D00A37D35 /* ASR33 */, + 21E8F9850D7338BF00634911 /* RK8E */, + 2128EA38109786FD00CA858C /* TSC8 */, + 2181CE25109EDC480026FAA5 /* KC8EA */, + 21B36BC41982EE0200EE4AD8 /* PC8-E */, + 8D1107260486CEB800E47090 /* Simulator */, + 21BC38940BD5693600A37D35 /* All */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 210915E509715375001F160B /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 21EE4D39098168D5002FF438 /* GeneralPreferences.nib in Resources */, + 2134E97C0986C14F00D74DC4 /* generalPrefIcon.tiff in Resources */, + 21A683D40D688D38000D5B59 /* InfoPlist.strings in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 210F34650BC79DC000482109 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 21163B360D4BDCC600F5B564 /* Info.plist in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2126BDFF09817C6D008BB678 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2126BE1409817D4B008BB678 /* CPUPreferences.nib in Resources */, + 21A683A00D68758E000D5B59 /* cpuPrefIcon.jpg in Resources */, + 21A683D00D688C48000D5B59 /* InfoPlist.strings in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2128EA3B109786FD00CA858C /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2165B05B1098D0B500E61A92 /* TSC8.nib in Resources */, + 2128EB0210978DA300CA858C /* InfoPlist.strings in Resources */, + 2165B01910979BCA00E61A92 /* io-info.plist in Resources */, + 2181CDC6109E21550026FAA5 /* TSC8OnlineHelp in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2181CE28109EDC480026FAA5 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2181CE97109EE1E30026FAA5 /* KC8EA.nib in Resources */, + 2181CEA7109EE2D80026FAA5 /* InfoPlist.strings in Resources */, + 2181CEB4109EE3690026FAA5 /* io-info.plist in Resources */, + 2181CF46109EF7940026FAA5 /* background.png in Resources */, + 2181CFED109F1D170026FAA5 /* light_off.png in Resources */, + 2181CFEE109F1D170026FAA5 /* light_on.png in Resources */, + 2181D05B10A0C41A0026FAA5 /* sr0down.png in Resources */, + 2181D05C10A0C41A0026FAA5 /* sr0up_sr1down.png in Resources */, + 2181D05D10A0C41A0026FAA5 /* sr0up_sr1up.png in Resources */, + 2181D05E10A0C41A0026FAA5 /* sr1down.png in Resources */, + 2181D05F10A0C41A0026FAA5 /* sr1up_sr2down.png in Resources */, + 2181D06010A0C41A0026FAA5 /* sr1up_sr2up.png in Resources */, + 2181D06210A0C41A0026FAA5 /* sr2up_sr3down.png in Resources */, + 2181D06310A0C41A0026FAA5 /* sr2up_sr3up.png in Resources */, + 2181D06410A0C41A0026FAA5 /* sr3down.png in Resources */, + 2181D06510A0C41A0026FAA5 /* sr3up_sr4down.png in Resources */, + 2181D06610A0C41A0026FAA5 /* sr3up_sr4up.png in Resources */, + 2181D06710A0C41A0026FAA5 /* sr4down.png in Resources */, + 2181D06810A0C41A0026FAA5 /* sr4up_sr5down.png in Resources */, + 2181D06910A0C41A0026FAA5 /* sr4up_sr5up.png in Resources */, + 2181D06A10A0C41A0026FAA5 /* sr5down.png in Resources */, + 2181D06B10A0C41A0026FAA5 /* sr5up_sr6down.png in Resources */, + 2181D06C10A0C41A0026FAA5 /* sr5up_sr6up.png in Resources */, + 2181D06D10A0C41A0026FAA5 /* sr6down.png in Resources */, + 2181D06E10A0C41A0026FAA5 /* sr6up_sr7down.png in Resources */, + 2181D06F10A0C41A0026FAA5 /* sr6up_sr7up.png in Resources */, + 2181D07010A0C41A0026FAA5 /* sr7down.png in Resources */, + 2181D07310A0C41A0026FAA5 /* sr8down.png in Resources */, + 2181D07410A0C41A0026FAA5 /* sr8up_sr9down.png in Resources */, + 2181D07510A0C41A0026FAA5 /* sr8up_sr9up.png in Resources */, + 2181D07610A0C41A0026FAA5 /* sr9down.png in Resources */, + 2181D07710A0C41A0026FAA5 /* sr9up_sr10down.png in Resources */, + 2181D07810A0C41A0026FAA5 /* sr9up_sr10up.png in Resources */, + 2181D07910A0C41A0026FAA5 /* sr10down.png in Resources */, + 2181D07A10A0C41A0026FAA5 /* sr10up_sr11down.png in Resources */, + 2181D07B10A0C41A0026FAA5 /* sr10up_sr11up.png in Resources */, + 2181D0AA10A0CAF20026FAA5 /* sr2down.png in Resources */, + 2181D0AC10A0CC550026FAA5 /* sr11down.png in Resources */, + 2181D0B610A0D2E10026FAA5 /* sr11up.png in Resources */, + 2181D0C410A0D61E0026FAA5 /* sr7up_sr8down.png in Resources */, + 2181D0C510A0D61E0026FAA5 /* sr7up_sr8up.png in Resources */, + 2181D41910A2072E0026FAA5 /* sw_down.png in Resources */, + 2181D41A10A2072E0026FAA5 /* sw_up.png in Resources */, + 2181D53510A475770026FAA5 /* addrload_down.png in Resources */, + 2181D53610A475770026FAA5 /* addrload_up_extdaddrload_down.png in Resources */, + 2181D53710A475770026FAA5 /* addrload_up_extdaddrload_up.png in Resources */, + 2181D59D10A47E010026FAA5 /* extdaddrload_down.png in Resources */, + 2181D59E10A47E010026FAA5 /* extdaddrload_up.png in Resources */, + 2181D5D810A4A0550026FAA5 /* clear_down.png in Resources */, + 2181D5D910A4A0550026FAA5 /* clear_up_cont_down.png in Resources */, + 2181D5DA10A4A0550026FAA5 /* clear_up_cont_up.png in Resources */, + 2181D5E210A4A1400026FAA5 /* cont_down.png in Resources */, + 2181D5E310A4A1400026FAA5 /* cont_up_exam_down.png in Resources */, + 2181D5E410A4A1400026FAA5 /* cont_up_exam_up.png in Resources */, + 2181D5E810A4A2760026FAA5 /* exam_down.png in Resources */, + 2181D5E910A4A2760026FAA5 /* exam_up_halt_down.png in Resources */, + 2181D5EA10A4A2760026FAA5 /* exam_up_halt_up.png in Resources */, + 2181D5EE10A4A2F90026FAA5 /* halt_down.png in Resources */, + 2181D5EF10A4A2F90026FAA5 /* halt_up_singstep_down.png in Resources */, + 2181D5F010A4A2F90026FAA5 /* halt_up_singstep_up.png in Resources */, + 2181D5F410A4A39C0026FAA5 /* singstep_down.png in Resources */, + 2181D5F510A4A39C0026FAA5 /* singstep_up.png in Resources */, + 2181D63810A5E2210026FAA5 /* dep_down.png in Resources */, + 2181D63910A5E2210026FAA5 /* dep_up.png in Resources */, + 2181D69D10A6196D0026FAA5 /* knob0.png in Resources */, + 2181D69E10A6196D0026FAA5 /* knob1.png in Resources */, + 2181D69F10A6196D0026FAA5 /* knob2.png in Resources */, + 2181D6A010A6196D0026FAA5 /* knob3.png in Resources */, + 2181D6A110A6196D0026FAA5 /* knob4.png in Resources */, + 2181D6A210A6196D0026FAA5 /* knob5.png in Resources */, + 2181D7BE10A706870026FAA5 /* key0.png in Resources */, + 2181D7BF10A706870026FAA5 /* key1.png in Resources */, + 2181D7C010A706870026FAA5 /* key2.png in Resources */, + 21F96F1410B08D1E00D51223 /* KC8EAOnlineHelp in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21A682FB0D685C73000D5B59 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 21A683460D68631B000D5B59 /* ASR33Preferences.nib in Resources */, + 21A683950D686C17000D5B59 /* asr33PrefIcon.jpg in Resources */, + 21A683F20D688DEC000D5B59 /* InfoPlist.strings in Resources */, + 210D3379109347DF002CF77D /* SpeakerLoud.png in Resources */, + 210D337A109347DF002CF77D /* SpeakerQuiet.png in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21B36BC91982EE0200EE4AD8 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 21B36CCC1983D55600EE4AD8 /* PC8E.nib in Resources */, + 21B36CBB1983CE4500EE4AD8 /* InfoPlist.strings in Resources */, + 219FBCE81983ED89005C5220 /* io-info.plist in Resources */, + 21909698198FDA16003AD39C /* PC8EOnlineHelp in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21BC383A0BD5402D00A37D35 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 211638560D48082E00F5B564 /* ASR33.nib in Resources */, + 216792D40D45067700666543 /* io-info.plist in Resources */, + 21B8420C0D454D3100BD583A /* auxtty-io-info.plist in Resources */, + 210857240D6B81500084490C /* ASR33OnlineHelp in Resources */, + 210857830D6B90E90084490C /* InfoPlist.strings in Resources */, + 210D334010933D71002CF77D /* tty-backspace.mp3 in Resources */, + 210D334110933D71002CF77D /* tty-bell.mp3 in Resources */, + 210D334210933D71002CF77D /* tty-carriage-return.mp3 in Resources */, + 210D334310933D71002CF77D /* tty-keystroke1.mp3 in Resources */, + 210D334410933D71002CF77D /* tty-space.mp3 in Resources */, + 2128E94F109505FB00CA858C /* tty-keystroke2.mp3 in Resources */, + 2128E95E109612C200CA858C /* tty-keystroke3.mp3 in Resources */, + 2128E95F109612C200CA858C /* tty-keystroke4.mp3 in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21E8F98A0D7338BF00634911 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2126DEC71052F0E2003B4706 /* RK8E.nib in Resources */, + 21E8F9F80D733C3300634911 /* InfoPlist.strings in Resources */, + 21E8FAD90D73622100634911 /* io-info.plist in Resources */, + 2126E0FA10580DA5003B4706 /* RK8EOnlineHelp in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 8D1107290486CEB800E47090 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 8D11072A0486CEB800E47090 /* MainMenu.nib in Resources */, + 8D11072B0486CEB800E47090 /* InfoPlist.strings in Resources */, + 214362F50860D45700DB186F /* stepToolbarIcon.tiff in Resources */, + 214362F60860D45700DB186F /* stopToolbarIcon.tiff in Resources */, + 214362F70860D45700DB186F /* traceToolbarIcon.tiff in Resources */, + 214363010860D9BE00DB186F /* goToolbarIcon.tiff in Resources */, + 21098E1F086595E1005945C4 /* breakpoint.tiff in Resources */, + 21098E20086595E1005945C4 /* breakOpcode.tiff in Resources */, + 21098E23086598AD005945C4 /* breakOpcodeS.tiff in Resources */, + 21098E24086598AD005945C4 /* breakOpcodeU.tiff in Resources */, + 21098E2A0865AFCE005945C4 /* pcArrowBlue.tiff in Resources */, + 2159F26F0869CE98002186B0 /* disassembler.plist in Resources */, + 2159F52C086EEEFC002186B0 /* assembler.plist in Resources */, + 21CAB17E0876C7E000E9005D /* breakpointsToolbarIcon.tiff in Resources */, + 21FFAA970938A8A600BA35C5 /* skipArrow.tiff in Resources */, + 21FFAAC00938C04700BA35C5 /* interruptArrow.tiff in Resources */, + 21F568CC0956152900DA4AB8 /* bootstrapToolbarIcon.tiff in Resources */, + 210911680962BC43001F160B /* binLoader.rim in Resources */, + 210911BF0962F734001F160B /* lowspeedRIM.bin in Resources */, + 210911C10962F74D001F160B /* highspeedRIM.bin in Resources */, + 210911E209640856001F160B /* rk8eBootcode.bin in Resources */, + 210913B60966A3BA001F160B /* resetToolbarIcon.tiff in Resources */, + 21AAEE4C09B6522300E55A42 /* memoryInspectorToolbarIcon.tiff in Resources */, + 21DC5A4A09C77583000F3908 /* alignMemoryArrow.tiff in Resources */, + 214429A409EAE8B800271635 /* OnlineHelp in Resources */, + 213AE24C09F422E50028A0E7 /* pdp8e.icns in Resources */, + 213AE2C509F6D7750028A0E7 /* Credits.html in Resources */, + 2147854009F6F32500A32CFE /* bb.tiff in Resources */, + 21E8F8F90D721A7B00634911 /* pcArrowGraphite.tiff in Resources */, + 2128EA31109773AA00CA858C /* bracket.png in Resources */, + 219097D619912B13003AD39C /* plugin.icns in Resources */, + 219097DC199134EE003AD39C /* papertape.icns in Resources */, + 219097EC1991452A003AD39C /* decpack.icns in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXShellScriptBuildPhase section */ + 21232F180D6767DF009E21A6 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "# index the online help\n#/Developer/Applications/Utilities/Help\\ Indexer.app/Contents/MacOS/Help\\ Indexer \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/OnlineHelp\" -PantherIndexing NO -Tokenizer 1 -ShowProgress NO -UseRemoteRoot NO -LogStyle 2 -IndexAnchors YES -TigerIndexing YES -GenerateSummaries YES -MinTermLength 3\n/usr/bin/hiutil -C -m 3 -a -f \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/OnlineHelp/OnlineHelp.helpindex\" \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/OnlineHelp\"\n\n# copy the console teletype to the disabled auxiliary teletype\n/bin/rm -rf \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/PlugIns Disabled\"\n/bin/mkdir \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/PlugIns Disabled\"\n/bin/cp -rp \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/PlugIns/ASR 33 Console Teletype.pdp8plugin\" \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/PlugIns Disabled/ASR 33 Auxiliary Teletype.pdp8Plugin\"\n\n# make the plugins to appear as bundles in the Finder\n/usr/bin/SetFile -a B \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/PlugIns/\"* \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/PlugIns Disabled/\"*"; + showEnvVarsInLog = 0; + }; + 2128EA49109786FD00CA858C /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "# index the online help\n#/Developer/Applications/Utilities/Help\\ Indexer.app/Contents/MacOS/Help\\ Indexer \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/TSC8OnlineHelp\" -PantherIndexing NO -Tokenizer 1 -ShowProgress NO -UseRemoteRoot NO -LogStyle 2 -IndexAnchors YES -TigerIndexing YES -GenerateSummaries YES -MinTermLength 3\n/usr/bin/hiutil -C -m 3 -a -f \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/TSC8OnlineHelp/TSC8OnlineHelp.helpindex\" \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/TSC8OnlineHelp\"\n\n# make the plugin to appear as bundles in the Finder\n/usr/bin/SetFile -a B \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}\""; + showEnvVarsInLog = 0; + }; + 2181CE33109EDC480026FAA5 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "# index the online help\n#/Developer/Applications/Utilities/Help\\ Indexer.app/Contents/MacOS/Help\\ Indexer \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/TSC8OnlineHelp\" -PantherIndexing NO -Tokenizer 1 -ShowProgress NO -UseRemoteRoot NO -LogStyle 2 -IndexAnchors YES -TigerIndexing YES -GenerateSummaries YES -MinTermLength 3\n/usr/bin/hiutil -C -m 3 -a -f \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/KC8EAOnlineHelp/KC8EAOnlineHelp.helpindex\" \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/KC8EAOnlineHelp\"\n\n# make the plugin to appear as bundles in the Finder\n/usr/bin/SetFile -a B \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}\""; + showEnvVarsInLog = 0; + }; + 21B36BE31982EE0200EE4AD8 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "# index the online help\n#/Developer/Applications/Utilities/Help\\ Indexer.app/Contents/MacOS/Help\\ Indexer \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/ASR33OnlineHelp\" -PantherIndexing NO -Tokenizer 1 -ShowProgress NO -UseRemoteRoot NO -LogStyle 2 -IndexAnchors YES -TigerIndexing YES -GenerateSummaries YES -MinTermLength 3\n/usr/bin/hiutil -C -m 3 -a -f \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/ASR33OnlineHelp/ASR33OnlineHelp.helpindex\" \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/ASR33OnlineHelp\"\n\n# make the plugin to appear as bundles in the Finder\n/usr/bin/SetFile -a B \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}\""; + showEnvVarsInLog = 0; + }; + 21BC387B0BD567BA00A37D35 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "# index the online help\n#/Developer/Applications/Utilities/Help\\ Indexer.app/Contents/MacOS/Help\\ Indexer \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/ASR33OnlineHelp\" -PantherIndexing NO -Tokenizer 1 -ShowProgress NO -UseRemoteRoot NO -LogStyle 2 -IndexAnchors YES -TigerIndexing YES -GenerateSummaries YES -MinTermLength 3\n/usr/bin/hiutil -C -m 3 -a -f \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/ASR33OnlineHelp/ASR33OnlineHelp.helpindex\" \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/ASR33OnlineHelp\"\n\n# make the plugin to appear as bundles in the Finder\n/usr/bin/SetFile -a B \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}\""; + showEnvVarsInLog = 0; + }; + 21E8F99C0D7338BF00634911 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "# index the online help\n#/Developer/Applications/Utilities/Help\\ Indexer.app/Contents/MacOS/Help\\ Indexer \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/RK8EOnlineHelp\" -PantherIndexing NO -Tokenizer 1 -ShowProgress NO -UseRemoteRoot NO -LogStyle 2 -IndexAnchors YES -TigerIndexing YES -GenerateSummaries YES -MinTermLength 3\n/usr/bin/hiutil -C -m 3 -a -f \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/RK8EOnlineHelp/RK8EOnlineHelp.helpindex\" \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}/Contents/Resources/English.lproj/RK8EOnlineHelp\"\n\n# make the plugin to appear as bundles in the Finder\n/usr/bin/SetFile -a B \"${CONFIGURATION_BUILD_DIR}/${FULL_PRODUCT_NAME}\""; + showEnvVarsInLog = 0; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 210915E609715375001F160B /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 216B75C80D70E16A00124930 /* GeneralPreferences.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 210F34660BC79DC000482109 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 211639F50D4B8F7C00F5B564 /* FloatingPointNumber.m in Sources */, + 2149F83A0D82AD930084F33F /* Utilities.c in Sources */, + 21D4741D108A458C006A5154 /* PluginAPI.m in Sources */, + 21D47420108A458E006A5154 /* KeepInMenuWindow.m in Sources */, + 21D47421108A458F006A5154 /* EnableDisableTextField.m in Sources */, + 21D47422108A4593006A5154 /* OctalFormatter.m in Sources */, + 21D47430108A4664006A5154 /* RegisterFormCell.m in Sources */, + 2128E9D11096379400CA858C /* NSControl+FileDrop.m in Sources */, + 2128E9D21096379500CA858C /* NSFileManager+Additions.m in Sources */, + 2128E9D31096379600CA858C /* NSTableView+Scrolling.m in Sources */, + 2128E9D41096379700CA858C /* NSMutableArray+BinarySearch.m in Sources */, + 219FBDA21984064D005C5220 /* PaperTapeController.m in Sources */, + 219FBDA41984064F005C5220 /* PaperTapeProgressIndicator.m in Sources */, + 211C61BE198BE6420005DA7D /* NSThread+MainThread.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2126BE0109817C6D008BB678 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2126BE1309817D4B008BB678 /* CPUPreferences.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2128EA40109786FD00CA858C /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2128EB1110978E5A00CA858C /* TSC8.m in Sources */, + 2165B00D109795D900E61A92 /* TSC8iot.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 2181CE2D109EDC480026FAA5 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2181CF00109EE4130026FAA5 /* KC8EA.m in Sources */, + 2181CF22109EEE5F0026FAA5 /* BackgroundView.m in Sources */, + 2181D1A110A0FF3D0026FAA5 /* ConsoleSwitchCell.m in Sources */, + 2181D6AF10A620E30026FAA5 /* KnobCell.m in Sources */, + 2190D60310A98F50004E5E38 /* StateMachine.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21A682FC0D685C73000D5B59 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 216B75E10D70E7D200124930 /* ASR33Preferences.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21B36BD71982EE0200EE4AD8 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 21B36C551982F0ED00EE4AD8 /* PC8E.m in Sources */, + 21E1D4AE198550F6002E2DDC /* PC8Eiot.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21BC383B0BD5402D00A37D35 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 21BC384E0BD541A700A37D35 /* ASR33.m in Sources */, + 2161C49F0BE537A30008E867 /* ASR33iot.c in Sources */, + 2161C6620BE66DCC0008E867 /* ASR33WindowController.m in Sources */, + 211EF3AB0BFC561000851FF1 /* ASR33TextView.m in Sources */, + 21FFAF860D62287D000B4CA5 /* TypeaheadBuffer.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 21E8F9900D7338BF00634911 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 21E8FAB20D73603D00634911 /* RK8E.m in Sources */, + 21E8FBD60D75FF2400634911 /* RK8EController.m in Sources */, + 2133AE720D78A1630023A41A /* RK05Controller.m in Sources */, + 2133AED20D78B9940023A41A /* RK05.m in Sources */, + 2133B3960D7F2B150023A41A /* RK8Eiot.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 8D11072C0486CEB800E47090 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 8D11072D0486CEB800E47090 /* main.m in Sources */, + 21AE0F0F085B43A00051FF07 /* CPUWindowController.m in Sources */, + 21AE0F12085B43A60051FF07 /* MainController.m in Sources */, + 2159F23C08689ACF002186B0 /* mri.c in Sources */, + 2159F2470868A3B8002186B0 /* eae.c in Sources */, + 2159F24A0868A442002186B0 /* opr.c in Sources */, + 2159F2550868A639002186B0 /* iot.c in Sources */, + 2159F2740869DB1A002186B0 /* Disassembler.m in Sources */, + 2159F315086DFFAD002186B0 /* Assembler.m in Sources */, + 2159F50C086EBCCF002186B0 /* Opcode.m in Sources */, + 2189C6D508707ABA00BA6C42 /* BreakpointController.m in Sources */, + 217C9F9A08746FBA009F9D30 /* BreakpointArray.m in Sources */, + 21CAB0E50876A61C00E9005D /* OpcodeFormatter.m in Sources */, + 21919F080879CD8300DC0727 /* Breakpoint.m in Sources */, + 21CF5F9D091CF61F00377059 /* CPUMemoryViewController.m in Sources */, + 21CF5FA8091D089600377059 /* IOFlagController.m in Sources */, + 21CF60CF09200C9D00377059 /* itab.c in Sources */, + 21FFA87909379A9800BA35C5 /* TableCornerView.m in Sources */, + 21FFA8DD0937B46800BA35C5 /* SkipController.m in Sources */, + 210910C9096042D5001F160B /* BootstrapPanelController.m in Sources */, + 21091513096C30A5001F160B /* PreferencesController.m in Sources */, + 2133910909B8E43900F2C028 /* MemoryInspectorController.m in Sources */, + 2133917209BA24FF00F2C028 /* MemoryInspector6BitASCII.m in Sources */, + 21C7F23109BCB2B2002BBEB7 /* MemoryInspector8BitASCII.m in Sources */, + 21DC5DC409CC3E4A000F3908 /* NonWrappingTableView.m in Sources */, + 21FC250109D32AF0006625FE /* MemoryInspectorOS8Packed8BitASCII.m in Sources */, + 21FC261E09D5E76B006625FE /* MemoryInspectorSignedInteger.m in Sources */, + 21FC267E09D6AC74006625FE /* MemoryInspectorUnsignedInteger.m in Sources */, + 21FC26A609D6B6C1006625FE /* MemoryInspectorDWSignedInteger.m in Sources */, + 21FC26AE09D6C2A8006625FE /* MemoryInspectorDWUnsignedInteger.m in Sources */, + 21FC26D009D85F91006625FE /* MemoryInspectorFPP8AFPFloatingPoint.m in Sources */, + 21FC281509DB1B54006625FE /* MemoryInspectorFPP8AEPFloatingPoint.m in Sources */, + 21FC282109DC7545006625FE /* MemoryInspectorFortranIIFloatingPoint.m in Sources */, + 210F34870BC8F9EC00482109 /* PluginManager.m in Sources */, + 21163A560D4BA32F00F5B564 /* MemoryInspectorPascalSFloatingPoint.m in Sources */, + 216B74FB0D6F4AEF00124930 /* HelpMenuManager.m in Sources */, + 21D473E1108A4430006A5154 /* PDP8.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 210916C8097168E7001F160B /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 210915E809715375001F160B /* GeneralPreferences */; + targetProxy = 210916C7097168E7001F160B /* PBXContainerItemProxy */; + }; + 210F36360BC9177B00482109 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 210F34680BC79DC000482109 /* Plugin.framework */; + targetProxy = 210F36350BC9177B00482109 /* PBXContainerItemProxy */; + }; + 2126BE4E098183AA008BB678 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 2126BDFE09817C6D008BB678 /* CPUPreferences */; + targetProxy = 2126BE4D098183AA008BB678 /* PBXContainerItemProxy */; + }; + 2128EA39109786FD00CA858C /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 210F34680BC79DC000482109 /* Plugin.framework */; + targetProxy = 2128EA3A109786FD00CA858C /* PBXContainerItemProxy */; + }; + 2139F84C0D6760D500836D7B /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 21BC383D0BD5402D00A37D35 /* ASR33 */; + targetProxy = 2139F84B0D6760D500836D7B /* PBXContainerItemProxy */; + }; + 2165B0981098D5CB00E61A92 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 2128EA38109786FD00CA858C /* TSC8 */; + targetProxy = 2165B0971098D5CB00E61A92 /* PBXContainerItemProxy */; + }; + 2181CE26109EDC480026FAA5 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 210F34680BC79DC000482109 /* Plugin.framework */; + targetProxy = 2181CE27109EDC480026FAA5 /* PBXContainerItemProxy */; + }; + 2181CEB8109EE3820026FAA5 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 2181CE25109EDC480026FAA5 /* KC8EA */; + targetProxy = 2181CEB7109EE3820026FAA5 /* PBXContainerItemProxy */; + }; + 21A683AD0D68760C000D5B59 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 210F34680BC79DC000482109 /* Plugin.framework */; + targetProxy = 21A683AC0D68760C000D5B59 /* PBXContainerItemProxy */; + }; + 21A683AF0D68760F000D5B59 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 21A682FE0D685C73000D5B59 /* ASR33Preferences */; + targetProxy = 21A683AE0D68760F000D5B59 /* PBXContainerItemProxy */; + }; + 21B36BC51982EE0200EE4AD8 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 210F34680BC79DC000482109 /* Plugin.framework */; + targetProxy = 21B36BC61982EE0200EE4AD8 /* PBXContainerItemProxy */; + }; + 21B36CD71983EC6500EE4AD8 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 21B36BC41982EE0200EE4AD8 /* PC8-E */; + targetProxy = 21B36CD61983EC6500EE4AD8 /* PBXContainerItemProxy */; + }; + 21BC38960BD5694400A37D35 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 8D1107260486CEB800E47090 /* Simulator */; + targetProxy = 21BC38950BD5694400A37D35 /* PBXContainerItemProxy */; + }; + 21E8F9860D7338BF00634911 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 210F34680BC79DC000482109 /* Plugin.framework */; + targetProxy = 21E8F9870D7338BF00634911 /* PBXContainerItemProxy */; + }; + 21E8FA050D733CD200634911 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 21E8F9850D7338BF00634911 /* RK8E */; + targetProxy = 21E8FA040D733CD200634911 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 089C165DFE840E0CC02AAC07 /* English */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 210857230D6B81500084490C /* ASR33OnlineHelp */ = { + isa = PBXVariantGroup; + children = ( + 2108571F0D6B813D0084490C /* English */, + ); + name = ASR33OnlineHelp; + sourceTree = ""; + }; + 210857600D6B8B630084490C /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 2108575E0D6B8B540084490C /* English */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 211638550D48082E00F5B564 /* ASR33.nib */ = { + isa = PBXVariantGroup; + children = ( + 2161C64A0BE605AF0008E867 /* English */, + ); + name = ASR33.nib; + sourceTree = ""; + }; + 2126BE1009817D4B008BB678 /* CPUPreferences.nib */ = { + isa = PBXVariantGroup; + children = ( + 2126BE1109817D4B008BB678 /* English */, + ); + name = CPUPreferences.nib; + sourceTree = ""; + }; + 2126DEC61052F0E2003B4706 /* RK8E.nib */ = { + isa = PBXVariantGroup; + children = ( + 21E8F9CF0D73398E00634911 /* English */, + ); + name = RK8E.nib; + sourceTree = ""; + }; + 2126E0F710580DA5003B4706 /* RK8EOnlineHelp */ = { + isa = PBXVariantGroup; + children = ( + 2126E0F810580DA5003B4706 /* English */, + ); + name = RK8EOnlineHelp; + sourceTree = ""; + }; + 2128EB0110978DA300CA858C /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 2128EAFF10978D9900CA858C /* InfoPlist.strings */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 213AE2C309F6D7750028A0E7 /* Credits.html */ = { + isa = PBXVariantGroup; + children = ( + 213AE2C409F6D7750028A0E7 /* English */, + ); + name = Credits.html; + sourceTree = ""; + }; + 2144299F09EAE8B800271635 /* OnlineHelp */ = { + isa = PBXVariantGroup; + children = ( + 214429A009EAE8B800271635 /* English */, + ); + name = OnlineHelp; + sourceTree = ""; + }; + 2159F26E0869CE98002186B0 /* disassembler.plist */ = { + isa = PBXVariantGroup; + children = ( + 2159F26C0869CE7D002186B0 /* English */, + ); + name = disassembler.plist; + sourceTree = ""; + }; + 2165B01710979BCA00E61A92 /* io-info.plist */ = { + isa = PBXVariantGroup; + children = ( + 2165B01810979BCA00E61A92 /* English */, + ); + name = "io-info.plist"; + sourceTree = ""; + }; + 2165B05A1098D0B500E61A92 /* TSC8.nib */ = { + isa = PBXVariantGroup; + children = ( + 2165B0431098C80500E61A92 /* English */, + ); + name = TSC8.nib; + sourceTree = ""; + }; + 216792D30D45067700666543 /* io-info.plist */ = { + isa = PBXVariantGroup; + children = ( + 216792D00D4505A200666543 /* English */, + ); + name = "io-info.plist"; + sourceTree = ""; + }; + 2181CDC0109E21550026FAA5 /* TSC8OnlineHelp */ = { + isa = PBXVariantGroup; + children = ( + 2181CDC1109E21550026FAA5 /* English */, + ); + name = TSC8OnlineHelp; + sourceTree = ""; + }; + 2181CE96109EE1E30026FAA5 /* KC8EA.nib */ = { + isa = PBXVariantGroup; + children = ( + 2181CE82109EE1D10026FAA5 /* English */, + ); + name = KC8EA.nib; + sourceTree = ""; + }; + 2181CEA5109EE2D80026FAA5 /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 2181CEA6109EE2D80026FAA5 /* English */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 2181CEB3109EE3690026FAA5 /* io-info.plist */ = { + isa = PBXVariantGroup; + children = ( + 2181CEAB109EE3130026FAA5 /* English */, + ); + name = "io-info.plist"; + sourceTree = ""; + }; + 21909692198FDA16003AD39C /* PC8EOnlineHelp */ = { + isa = PBXVariantGroup; + children = ( + 21909693198FDA16003AD39C /* English */, + ); + name = PC8EOnlineHelp; + sourceTree = ""; + }; + 219FBCE61983ED89005C5220 /* io-info.plist */ = { + isa = PBXVariantGroup; + children = ( + 219FBCE71983ED89005C5220 /* English */, + ); + name = "io-info.plist"; + sourceTree = ""; + }; + 21A683440D68631B000D5B59 /* ASR33Preferences.nib */ = { + isa = PBXVariantGroup; + children = ( + 21A683410D6862FF000D5B59 /* English */, + ); + name = ASR33Preferences.nib; + sourceTree = ""; + }; + 21A683CF0D688C48000D5B59 /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 21A683CD0D688C32000D5B59 /* English */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 21A683D30D688D38000D5B59 /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 21A683D10D688D2A000D5B59 /* English */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 21A683F10D688DEC000D5B59 /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 21A683EF0D688DE4000D5B59 /* English */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 21B36CBA1983CE4500EE4AD8 /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 21B36CB81983CE2800EE4AD8 /* English */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 21B36CCA1983D55600EE4AD8 /* PC8E.nib */ = { + isa = PBXVariantGroup; + children = ( + 21B36CCB1983D55600EE4AD8 /* English */, + ); + name = PC8E.nib; + sourceTree = ""; + }; + 21B8420A0D454D3100BD583A /* auxtty-io-info.plist */ = { + isa = PBXVariantGroup; + children = ( + 21B8420B0D454D3100BD583A /* auxtty-io-info.plist */, + ); + name = "auxtty-io-info.plist"; + sourceTree = ""; + }; + 21E8F9F70D733C3300634911 /* InfoPlist.strings */ = { + isa = PBXVariantGroup; + children = ( + 21E8F9F50D733C2B00634911 /* English */, + ); + name = InfoPlist.strings; + sourceTree = ""; + }; + 21E8FAD70D73622100634911 /* io-info.plist */ = { + isa = PBXVariantGroup; + children = ( + 21E8FAD80D73622100634911 /* English */, + ); + name = "io-info.plist"; + sourceTree = ""; + }; + 21EE4D38098168D5002FF438 /* GeneralPreferences.nib */ = { + isa = PBXVariantGroup; + children = ( + 210916D609716A38001F160B /* English */, + ); + name = GeneralPreferences.nib; + sourceTree = ""; + }; + 21F96F0E10B08D1E00D51223 /* KC8EAOnlineHelp */ = { + isa = PBXVariantGroup; + children = ( + 21F96F0F10B08D1E00D51223 /* English */, + ); + name = KC8EAOnlineHelp; + sourceTree = ""; + }; + 29B97318FDCFA39411CA2CEA /* MainMenu.nib */ = { + isa = PBXVariantGroup; + children = ( + 29B97319FDCFA39411CA2CEA /* English */, + ); + name = MainMenu.nib; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 210915ED09715377001F160B /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES; + INFOPLIST_FILE = GeneralPreferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = GeneralPreferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = YES; + }; + name = Debug; + }; + 210915EE09715377001F160B /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES; + INFOPLIST_FILE = GeneralPreferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = GeneralPreferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = NO; + }; + name = Release; + }; + 210915EF09715377001F160B /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = GeneralPreferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = GeneralPreferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = YES; + }; + name = Default; + }; + 210F346C0BC79DC100482109 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = NO; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + FRAMEWORK_VERSION = A; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INSTALL_PATH = "@executable_path/../Frameworks"; + LD_DYLIB_INSTALL_NAME = "$(DYLIB_INSTALL_NAME_BASE:standardizepath)/$(EXECUTABLE_PATH)"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = PluginFramework; + ZERO_LINK = YES; + }; + name = Debug; + }; + 210F346D0BC79DC100482109 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = YES; + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + FRAMEWORK_VERSION = A; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INSTALL_PATH = "@executable_path/../Frameworks"; + LD_DYLIB_INSTALL_NAME = "$(DYLIB_INSTALL_NAME_BASE:standardizepath)/$(EXECUTABLE_PATH)"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = PluginFramework; + SDKROOT = macosx10.4; + ZERO_LINK = NO; + }; + name = Release; + }; + 210F346E0BC79DC100482109 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + DYLIB_COMPATIBILITY_VERSION = 1; + DYLIB_CURRENT_VERSION = 1; + FRAMEWORK_VERSION = A; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INSTALL_PATH = "@executable_path/../Frameworks"; + LD_DYLIB_INSTALL_NAME = "$(DYLIB_INSTALL_NAME_BASE:standardizepath)/$(EXECUTABLE_PATH)"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = PluginFramework; + ZERO_LINK = YES; + }; + name = Default; + }; + 2126BE0609817C6D008BB678 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES; + INFOPLIST_FILE = CPUPreferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = CPUPreferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = YES; + }; + name = Debug; + }; + 2126BE0709817C6D008BB678 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES; + INFOPLIST_FILE = CPUPreferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = CPUPreferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = NO; + }; + name = Release; + }; + 2126BE0809817C6D008BB678 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INFOPLIST_FILE = CPUPreferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = CPUPreferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = YES; + }; + name = Default; + }; + 2128EA4B109786FD00CA858C /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = TSC8/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "TSC8-75 Board"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Debug; + }; + 2128EA4C109786FD00CA858C /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INFOPLIST_FILE = TSC8/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "TSC8-75 Board"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = NO; + }; + name = Release; + }; + 2128EA4D109786FD00CA858C /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INFOPLIST_FILE = TSC8/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "TSC8-75 Board"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Default; + }; + 2181CE35109EDC480026FAA5 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = KC8EA/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "KC8-EA Programmer’s Console"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Debug; + }; + 2181CE36109EDC480026FAA5 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INFOPLIST_FILE = KC8EA/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "KC8-EA Programmer’s Console"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = NO; + }; + name = Release; + }; + 2181CE37109EDC480026FAA5 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = KC8EA/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "KC8-EA Programmer’s Console"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Default; + }; + 21A683010D685C74000D5B59 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = ASR33Preferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = ASR33Preferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = YES; + }; + name = Debug; + }; + 21A683020D685C74000D5B59 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INFOPLIST_FILE = ASR33Preferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = ASR33Preferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = NO; + }; + name = Release; + }; + 21A683030D685C74000D5B59 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = ASR33Preferences/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = ASR33Preferences; + WRAPPER_EXTENSION = prefPane; + ZERO_LINK = YES; + }; + name = Default; + }; + 21AE0EF3085B43480051FF07 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = NO; + FRAMEWORK_SEARCH_PATHS = ( + "$(FRAMEWORK_SEARCH_PATHS)", + "$(SYSTEM_DEVELOPER_DIR)/SDKs/MacOSX10.4u.sdk/System/Library/Frameworks", + ); + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_INPUT_FILETYPE = sourcecode.c.objc; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "pdp8e-simulator_Prefix.pch"; + GCC_PREPROCESSOR_DEFINITIONS = ""; + GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNINITIALIZED_AUTOS = NO; + GCC_WARN_UNUSED_VARIABLE = YES; + INFOPLIST_FILE = Resources/Info.plist; + INSTALL_PATH = "$(HOME)/Applications"; + OTHER_CPLUSPLUSFLAGS = ( + "-Wno-nonportable-cfstrings", + "$(OTHER_CFLAGS)", + ); + PREBINDING = NO; + PRODUCT_NAME = "PDP-8E Simulator"; + WRAPPER_EXTENSION = app; + ZERO_LINK = YES; + }; + name = Debug; + }; + 21AE0EF4085B43480051FF07 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = YES; + FRAMEWORK_SEARCH_PATHS = ( + "$(FRAMEWORK_SEARCH_PATHS)", + "$(SYSTEM_DEVELOPER_DIR)/SDKs/MacOSX10.4u.sdk/System/Library/Frameworks", + ); + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_INPUT_FILETYPE = sourcecode.c.objc; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "pdp8e-simulator2_Prefix.pch"; + GCC_VERSION = 4.0; + GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + INFOPLIST_FILE = Resources/Info.plist; + INSTALL_PATH = "$(HOME)/Applications"; + OTHER_LDFLAGS = ""; + PREBINDING = NO; + PRODUCT_NAME = "PDP-8:E Simulator"; + WRAPPER_EXTENSION = app; + ZERO_LINK = NO; + }; + name = Release; + }; + 21AE0EF5085B43480051FF07 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + FRAMEWORK_SEARCH_PATHS = ( + "$(FRAMEWORK_SEARCH_PATHS)", + "$(SYSTEM_DEVELOPER_DIR)/SDKs/MacOSX10.4u.sdk/System/Library/Frameworks", + ); + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_INPUT_FILETYPE = sourcecode.c.objc; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "pdp8e-simulator2_Prefix.pch"; + GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + INFOPLIST_FILE = Resources/Info.plist; + INSTALL_PATH = "$(HOME)/Applications"; + PRODUCT_NAME = "PDP-8:E Simulator"; + WRAPPER_EXTENSION = app; + }; + name = Default; + }; + 21AE0EF7085B43480051FF07 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ARCHS = "$(NATIVE_ARCH)"; + GCC_ENABLE_OBJC_EXCEPTIONS = YES; + GCC_INPUT_FILETYPE = sourcecode.c.objc; + GCC_PFE_FILE_C_DIALECTS = ""; + GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = NO; + GCC_TREAT_NONCONFORMANT_CODE_ERRORS_AS_WARNINGS = NO; + GCC_TREAT_WARNINGS_AS_ERRORS = NO; + GCC_VERSION = 4.0; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_INVALID_OFFSETOF_MACRO = YES; + GCC_WARN_ABOUT_MISSING_NEWLINE = YES; + GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_CHECK_SWITCH_STATEMENTS = YES; + GCC_WARN_EFFECTIVE_CPLUSPLUS_VIOLATIONS = YES; + GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES; + GCC_WARN_HIDDEN_VIRTUAL_FUNCTIONS = YES; + GCC_WARN_INITIALIZER_NOT_FULLY_BRACKETED = YES; + GCC_WARN_MISSING_PARENTHESES = YES; + GCC_WARN_NON_VIRTUAL_DESTRUCTOR = YES; + GCC_WARN_PEDANTIC = NO; + GCC_WARN_PROTOTYPE_CONVERSION = NO; + GCC_WARN_SHADOW = NO; + GCC_WARN_SIGN_COMPARE = YES; + GCC_WARN_TYPECHECK_CALLS_TO_PRINTF = YES; + GCC_WARN_UNINITIALIZED_AUTOS = NO; + GCC_WARN_UNKNOWN_PRAGMAS = YES; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_LABEL = YES; + GCC_WARN_UNUSED_PARAMETER = NO; + GCC_WARN_UNUSED_VALUE = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + LD_GENERATE_MAP_FILE = NO; + MACOSX_DEPLOYMENT_TARGET = 10.4; + OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)"; + RUN_CLANG_STATIC_ANALYZER = YES; + SDKROOT = macosx10.4; + WARNING_CFLAGS = ""; + ZERO_LINK = YES; + }; + name = Debug; + }; + 21AE0EF8085B43480051FF07 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ARCHS = ( + ppc, + i386, + ); + GCC_ENABLE_OBJC_EXCEPTIONS = YES; + GCC_INPUT_FILETYPE = sourcecode.c.objc; + GCC_PFE_FILE_C_DIALECTS = ""; + GCC_PREPROCESSOR_DEFINITIONS = NS_BLOCK_ASSERTIONS; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_INVALID_OFFSETOF_MACRO = YES; + GCC_WARN_ABOUT_MISSING_FIELD_INITIALIZERS = YES; + GCC_WARN_ABOUT_MISSING_NEWLINE = YES; + GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES; + GCC_WARN_CHECK_SWITCH_STATEMENTS = YES; + GCC_WARN_EFFECTIVE_CPLUSPLUS_VIOLATIONS = YES; + GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES; + GCC_WARN_HIDDEN_VIRTUAL_FUNCTIONS = YES; + GCC_WARN_INITIALIZER_NOT_FULLY_BRACKETED = YES; + GCC_WARN_MISSING_PARENTHESES = YES; + GCC_WARN_MULTIPLE_DEFINITION_TYPES_FOR_SELECTOR = NO; + GCC_WARN_NON_VIRTUAL_DESTRUCTOR = YES; + GCC_WARN_PEDANTIC = NO; + GCC_WARN_PROTOTYPE_CONVERSION = NO; + GCC_WARN_SHADOW = NO; + GCC_WARN_SIGN_COMPARE = YES; + GCC_WARN_STRICT_SELECTOR_MATCH = NO; + GCC_WARN_TYPECHECK_CALLS_TO_PRINTF = YES; + GCC_WARN_UNDECLARED_SELECTOR = NO; + GCC_WARN_UNINITIALIZED_AUTOS = YES; + GCC_WARN_UNKNOWN_PRAGMAS = YES; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_LABEL = YES; + GCC_WARN_UNUSED_PARAMETER = NO; + GCC_WARN_UNUSED_VALUE = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + LD_GENERATE_MAP_FILE = NO; + MACOSX_DEPLOYMENT_TARGET = 10.4; + OTHER_LDFLAGS = ""; + RUN_CLANG_STATIC_ANALYZER = YES; + SDKROOT = macosx10.4; + }; + name = Release; + }; + 21AE0EF9085B43480051FF07 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + ARCHS = ( + ppc, + i386, + ); + GCC_ENABLE_OBJC_EXCEPTIONS = YES; + GCC_INPUT_FILETYPE = sourcecode.c.objc; + GCC_PFE_FILE_C_DIALECTS = ""; + GCC_VERSION = 4.0; + LD_GENERATE_MAP_FILE = NO; + MACOSX_DEPLOYMENT_TARGET = 10.4; + RUN_CLANG_STATIC_ANALYZER = YES; + SDKROOT = macosx10.4; + }; + name = Default; + }; + 21B36BE51982EE0200EE4AD8 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = PC8E/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "PC8-E Paper Tape Reader & Punch"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Debug; + }; + 21B36BE61982EE0200EE4AD8 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INFOPLIST_FILE = PC8E/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "PC8-E Paper Tape Reader & Punch"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = NO; + }; + name = Release; + }; + 21B36BE71982EE0200EE4AD8 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = PC8E/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "PC8-E Paper Tape Reader & Punch"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Default; + }; + 21BC38480BD5402E00A37D35 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = ASR33/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "ASR 33 Console Teletype"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Debug; + }; + 21BC38490BD5402E00A37D35 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_SYMBOLS_PRIVATE_EXTERN = NO; + GCC_VERSION = 4.0; + INFOPLIST_FILE = ASR33/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "ASR 33 Console Teletype"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = NO; + }; + name = Release; + }; + 21BC384A0BD5402E00A37D35 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = ASR33/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "ASR 33 Console Teletype"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Default; + }; + 21BC389E0BD5696200A37D35 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + MACOSX_DEPLOYMENT_TARGET = 10.4; + PRODUCT_NAME = All; + SDKROOT = macosx10.4; + }; + name = Debug; + }; + 21BC389F0BD5696200A37D35 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + PRODUCT_NAME = All; + ZERO_LINK = NO; + }; + name = Release; + }; + 21BC38A00BD5696200A37D35 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + PRODUCT_NAME = All; + }; + name = Default; + }; + 21E8F99E0D7338BF00634911 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_MODEL_TUNING = G5; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = RK8E/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "RK8-E Disk Cartridge System"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Debug; + }; + 21E8F99F0D7338BF00634911 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + COPY_PHASE_STRIP = YES; + GCC_ENABLE_FIX_AND_CONTINUE = NO; + GCC_GENERATE_DEBUGGING_SYMBOLS = NO; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + GCC_VERSION = 4.0; + INFOPLIST_FILE = RK8E/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "RK8-E Disk Cartridge System"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = NO; + }; + name = Release; + }; + 21E8F9A00D7338BF00634911 /* Default */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_MODEL_TUNING = G5; + GCC_PRECOMPILE_PREFIX_HEADER = YES; + GCC_PREFIX_HEADER = "$(SYSTEM_LIBRARY_DIR)/Frameworks/AppKit.framework/Headers/AppKit.h"; + INFOPLIST_FILE = RK8E/Info.plist; + INSTALL_PATH = "$(HOME)/Library/Bundles"; + OTHER_LDFLAGS = ( + "-framework", + Foundation, + "-framework", + AppKit, + ); + PREBINDING = NO; + PRODUCT_NAME = "RK8-E Disk Cartridge System"; + SKIP_INSTALL = YES; + WRAPPER_EXTENSION = pdp8Plugin; + ZERO_LINK = YES; + }; + name = Default; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 210915EC09715377001F160B /* Build configuration list for PBXNativeTarget "GeneralPreferences" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 210915ED09715377001F160B /* Debug */, + 210915EE09715377001F160B /* Release */, + 210915EF09715377001F160B /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 210F346B0BC79DC100482109 /* Build configuration list for PBXNativeTarget "Plugin.framework" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 210F346C0BC79DC100482109 /* Debug */, + 210F346D0BC79DC100482109 /* Release */, + 210F346E0BC79DC100482109 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 2126BE0509817C6D008BB678 /* Build configuration list for PBXNativeTarget "CPUPreferences" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2126BE0609817C6D008BB678 /* Debug */, + 2126BE0709817C6D008BB678 /* Release */, + 2126BE0809817C6D008BB678 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 2128EA4A109786FD00CA858C /* Build configuration list for PBXNativeTarget "TSC8" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2128EA4B109786FD00CA858C /* Debug */, + 2128EA4C109786FD00CA858C /* Release */, + 2128EA4D109786FD00CA858C /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 2181CE34109EDC480026FAA5 /* Build configuration list for PBXNativeTarget "KC8EA" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2181CE35109EDC480026FAA5 /* Debug */, + 2181CE36109EDC480026FAA5 /* Release */, + 2181CE37109EDC480026FAA5 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 21A683040D685C74000D5B59 /* Build configuration list for PBXNativeTarget "ASR33Preferences" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 21A683010D685C74000D5B59 /* Debug */, + 21A683020D685C74000D5B59 /* Release */, + 21A683030D685C74000D5B59 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 21AE0EF2085B43480051FF07 /* Build configuration list for PBXNativeTarget "Simulator" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 21AE0EF3085B43480051FF07 /* Debug */, + 21AE0EF4085B43480051FF07 /* Release */, + 21AE0EF5085B43480051FF07 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 21AE0EF6085B43480051FF07 /* Build configuration list for PBXProject "pdp8e-simulator" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 21AE0EF7085B43480051FF07 /* Debug */, + 21AE0EF8085B43480051FF07 /* Release */, + 21AE0EF9085B43480051FF07 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 21B36BE41982EE0200EE4AD8 /* Build configuration list for PBXNativeTarget "PC8-E" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 21B36BE51982EE0200EE4AD8 /* Debug */, + 21B36BE61982EE0200EE4AD8 /* Release */, + 21B36BE71982EE0200EE4AD8 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 21BC38470BD5402E00A37D35 /* Build configuration list for PBXNativeTarget "ASR33" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 21BC38480BD5402E00A37D35 /* Debug */, + 21BC38490BD5402E00A37D35 /* Release */, + 21BC384A0BD5402E00A37D35 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 21BC389D0BD5696200A37D35 /* Build configuration list for PBXAggregateTarget "All" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 21BC389E0BD5696200A37D35 /* Debug */, + 21BC389F0BD5696200A37D35 /* Release */, + 21BC38A00BD5696200A37D35 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; + 21E8F99D0D7338BF00634911 /* Build configuration list for PBXNativeTarget "RK8E" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 21E8F99E0D7338BF00634911 /* Debug */, + 21E8F99F0D7338BF00634911 /* Release */, + 21E8F9A00D7338BF00634911 /* Default */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Default; + }; +/* End XCConfigurationList section */ + }; + rootObject = 29B97313FDCFA39411CA2CEA /* Project object */; +} diff --git a/pdp8e-simulator.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/pdp8e-simulator.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..d2b7301 --- /dev/null +++ b/pdp8e-simulator.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + +