[sebhc] Emulator fix
Carroll Waddell
CarrollWaddell at sc.rr.com
Sat May 1 18:42:32 CDT 2004
For the tape software that I've used on H8, when you hit GO on the
keypad, it will output to the H8-5 if present and present you with some
options for Lower case characters, etc, then write an updated copy of
that program to the output tape recorder. CEW
Steven Parker wrote:
>> I found the port address that is causing the problem. According to
>> the log
>> file, it's I/O address 0373 (251 or 0xFB), the code says it's related to
>> the console being connected via the H8-5 card:
>>
>> Log File: "***Port 373 is not implemented.***"
>
>
> I'm guessing the tape s/w is polling ports to find the terminal. It's
> been a while since I played with any tape s/w but I seem to recall it
> waits for you to hit a key, right? So the fix would be to simulate the
> port by returning a value that would look like the usart has empty
> buffers and an un-asserted DSR ("nobody home").
>
> Ideally, the emulator should do this (simulate idle or unconnected
> device) for all ports that might be associated with common devices.
> And perhaps accesses to any other port could simply be logged but not
> stop execution (as it would not stop a real CPU). Just return a fixed
> value (like zero).
>
>> Simply commenting out the bNotImplemented Line so
>> that the output goes no where didn't seem to help.
>
>
> I would have expected it to keep the CPU going, at least - did it? But
> returning an unitialized value may have confused the polling routine.
> Try this:
>
>
> // Ports 372 and 373 were the console USART ports if the console was
> connected
> // via the H8-5's serial I/O port. Not used.
> // 2004.05.01.sp - Checked by tape software, so simulate in idle status.
>
> case 0372:
> nData = 0;
> break;
> case 0373:
> nData = USART_STATUS_TXE | USART_STATUS_TXRDY;
> break;
>
>
> Then, down at the end of the routine, to keep it from halting on
> unimplemented inputs entirely (but still log them and display the
> status window):
>
>
> // 2004.05.01.sp - Continue execution anyway (as a real CPU would)
> nData = 0;
> // Sleep(5000);
> // SetEvent(theApp.m_IPC.hShutdown);
>
>
> Let me know if that fixes it!
>
> Cheers,
>
> - Steven
>
> _________________________________________________________________
> MSN Toolbar provides one-click access to Hotmail from any Web page –
> FREE download! http://toolbar.msn.com/go/onm00200413ave/direct/01/
>
> --
> Delivered by the SEBHC Mailing List
>
--
Delivered by the SEBHC Mailing List
More information about the Sebhc
mailing list