User:RHansen: Difference between revisions
(Added info on ND-110 compact and refactored the information slighlty.) |
(Updated page with current status) |
||
Line 22: | Line 22: | ||
== ND-100 Emulator == | == ND-100 Emulator == | ||
I have successfully (with some help) created an ND-100 emulator in .NET/C# with peripherals such as TeleType, Floppy and HardDrive. | I have successfully (with some help) created an ND-100 emulator in .NET/C# with peripherals such as TeleType, Serial Ports, Floppy and HardDrive. | ||
The emulator contains a debugger, disassembler and code tracer in addition to logic to mount different floppy-image, read/write hardddrive, loading BPUN and PROG files directly into memory. | The emulator contains a debugger, disassembler and code tracer in addition to logic to mount different floppy-image, read/write hardddrive, loading BPUN and PROG files directly into memory. | ||
I have successfully dumped and booted SINTRAN | I have successfully dumped and booted SINTRAN versions H, K, L and M in ND-100 mode. | ||
This YouTube video shows a boot of SINTRAN L in the emulator [https://www.youtube.com/watch?v=HdVbfdQeWOk&ab_channel=RonnyHansen] | |||
Line 33: | Line 34: | ||
[[File:Disk-choice-m.png|200px|thumb|right|Possible disk choices to install SIII M on]] | [[File:Disk-choice-m.png|200px|thumb|right|Possible disk choices to install SIII M on]] | ||
Line 44: | Line 42: | ||
=== What's working in the ND-100 emulator === | === What's working in the ND-100 emulator === | ||
* SINTRAN H boots and runs (with a minor hardcode in the emulator to fix ABSTR bug (?)) | * SINTRAN H boots and runs (with a minor hardcode in the emulator to fix ABSTR bug (?)) | ||
* SINTRAN K,L and M boots and runs (with a minor "workaround" in the Memory Management system because of a bug somewhere) | |||
* Test programs that validates the opcodes so far | * Test programs that validates the opcodes so far | ||
** ONE—CHECK, TWO—CHECK, THREE—CHECK | ** ONE—CHECK, TWO—CHECK, THREE—CHECK | ||
Line 61: | Line 60: | ||
=== What's NOT working in the ND-100 emulator === | === What's NOT working in the ND-100 emulator === | ||
* SINTRAN K,L and M | * SINTRAN K,L and M triggers a "Memory protection" after a "Page-not-in-memory". This happens to just one specific page, so at the moment "Memory protection" is disabled while I am trying to identify the reason. | ||
* MON 131 ABSTR behaves "buggy" in SINTRAN H | * MON 131 ABSTR behaves "buggy" in SINTRAN H | ||
** Something odd happens with zero-pointers for some logical devices sending the CPU into a loop at P=0 | ** Something odd happens with zero-pointers for some logical devices sending the CPU into a loop at P=0 | ||
* | ** Guessing there is an opcode not working 100% that failed some initialisation. | ||
* Copying file from papertape driver to SINTRAN disk with "COPY 'FILE:BPUN' PT1' fails after 129 bytes. It just stops, and I have to cancel the copy with ESC key. | |||
* Copying file from papertape driver to SINTRAN H disk with "COPY 'FILE:BPUN' PT1' fails after 129 bytes. It just stops, and I have to cancel the copy with ESC key. | |||
===I am looking for the following=== | ===I am looking for the following=== | ||
* | * SINTRAN N (the newest version of SINTRAN) and patch files for Y2K. | ||
* Other binary images (Tape, PaperTape, HDD, Floppy,+++) | * All SINTRAN III versions are of interrest. And PATCH files. Did i mention PATCH files? | ||
* Other binary images (Tape, PaperTape, HDD, Floppy,+++) | |||
* Source Code. Any source code. Especially test programs and IO drivers. | * Source Code. Any source code. Especially test programs and IO drivers. | ||
===Things I am working on=== | ===Things I am working on=== | ||
* | * Finding the bugs that forces me to have workaround for ABSTR and Memory Management (Guessing: opcodes and/or ALU flags) | ||
* Implementing the missing opcodes | * Implementing the missing opcodes | ||
** «Commercial Extended» (CE) option (BCD) | ** «Commercial Extended» (CE) option (BCD) | ||
** CX opcodes (Stack, Segment,) | ** CX opcodes (Stack, Segment,) | ||
** ND-110 Specific opcodes | ** ND-110 Specific opcodes | ||
*** Since I now have the ND-110 emulator working, I should be able do decode how the missing opcodes work and get them working. | *** Since I now have the ND-110 emulator working, I should be able do decode how the missing opcodes work and get them working. But in reality I dont think I need the ND-110 specific opcodes, as they are mostly added for performance reasons. | ||
===ND-100 Running in the browser=== | ===ND-100 Running in the browser=== | ||
Line 95: | Line 88: | ||
** You can test by going to [https://retrocore.hackercorp.no/ https://retrocore.hackercorp.no/] and selecting machine=ND100 then powering on the Emulator. | ** You can test by going to [https://retrocore.hackercorp.no/ https://retrocore.hackercorp.no/] and selecting machine=ND100 then powering on the Emulator. | ||
** Feedback, comments, and help is much appreciated | ** Feedback, comments, and help is much appreciated | ||
*** I am able to mount HDD for code running in the browser, but booting and running SINTRAN is painfully slow. So maybe not so good idea to do that.. | |||
===Open Source=== | ===Open Source=== | ||
Line 109: | Line 103: | ||
*** MicroCode retrieved from PDF document using OCR techniques mixed with some "text washing" gives me a file with 16600 lines of microcode I manually have validate against the PDF. After retriving a copy of a ROM for a ND-110 cpu board, I could compare the compiled result with the ROM and found 150+ errors in the source file. Now that is fixed, and the compiled microcode is identical to the ROM. | *** MicroCode retrieved from PDF document using OCR techniques mixed with some "text washing" gives me a file with 16600 lines of microcode I manually have validate against the PDF. After retriving a copy of a ROM for a ND-110 cpu board, I could compare the compiled result with the ROM and found 150+ errors in the source file. Now that is fixed, and the compiled microcode is identical to the ROM. | ||
*** | *** | ||
*** MicroCode CPU working. I have implemented registers, ALU ( | *** MicroCode CPU working. I have implemented registers, ALU (actually its 4x Am2901 chips) and interrupts (Am2914 chip) | ||
**** The remaining parts are to get the interrupt subsystem 100% correct, then add memory management and implement Traps. | **** The remaining parts are to get the interrupt subsystem 100% correct, then add memory management and implement Traps. | ||
*** Macro code execution works, except interrupts and traps. | *** Macro code execution works, except interrupts and traps. | ||
*** This CPU is definitively slower than the ND-100 emulator, but hopefully behave 100% like the original. This way I can verify behavior differences between the ND-100 opcodes and the ND-110 opcodes. | *** This CPU is definitively slower than the ND-100 emulator, but hopefully behave 100% like the original. This way I can verify behavior differences between the ND-100 opcodes and the ND-110 opcodes. | ||
Line 120: | Line 113: | ||
** Creating a new CPU emulator at hardware level using the original design documents from 1988 | ** Creating a new CPU emulator at hardware level using the original design documents from 1988 | ||
*** Draw the digital logic using Logisim Evolution. | *** Draw the digital logic using Logisim Evolution. | ||
**** | **** Finished : CGA (CPU Gate Array) | ||
**** Started | **** Started : DGA (Decoder Gate Array) | ||
**** Remaining: PCB, PAL's and some special chips (like the UART). | **** Remaining: PCB, PAL's and some special chips (like the UART). | ||
**** I have secured a dump of the microcode from EPROM on a real ND-120 CPU. | **** I have secured a dump of the microcode from EPROM on a real ND-120 CPU. | ||
Line 130: | Line 123: | ||
*** When CPU PCB is finished, with serial port access to OPCOM the next step is to implement support for IO devices like floppy and harddrive. | *** When CPU PCB is finished, with serial port access to OPCOM the next step is to implement support for IO devices like floppy and harddrive. | ||
== ND Controller card Emulator== | |||
* Controller card for HDD emulated in hardware FPGA | |||
** Today you need an real working HDD or an MFM emulator with MFM controller card in an ND machine to boot. | |||
** This project aims to solve this by emulating a real controller using FPGA, and having the "HHD DISK" as an image on a SD card. | |||
** Emulation of floppy controller is also planned. | |||
** This way we will be able to run test programs and boot ND hardware that doesnt have working disk/disk-controllers. | |||
==TDV 2215 Emulator== | ==TDV 2215 Emulator== | ||
[[File:Tdv-2215-boot-emul-err.png|200px|thumb|right|TDV2215 booting with error]] | |||
* Creating an emulator of the TDV2215 terminal. | * Creating an emulator of the TDV2215 terminal. | ||
** Using the original schematics, an emulated 8085 CPU and ROM dumps from an original TDV. | ** Using the original schematics, an emulated 8085 CPU and ROM dumps from an original TDV. | ||
Line 138: | Line 140: | ||
** I am still working on mapping the original HW to my emulator. | ** I am still working on mapping the original HW to my emulator. | ||
** Using Ghidra to reverse engineer the ROM code, but its hard to understand what the ROM code really tries to do, and why it fails. Having had the source code with comments would have been helpful :) | ** Using Ghidra to reverse engineer the ROM code, but its hard to understand what the ROM code really tries to do, and why it fails. Having had the source code with comments would have been helpful :) | ||
** YouTube video showing boot here: [https://youtu.be/-MwsB6Yzs94] | |||
* Added TD2200 support directly in the emulators "graphic" mode | |||
** Decoding ESC sequences and sending ESQ sequences based on TDV manuals describing some of them. Adding in som VT100 emulation to make the rest work. Mapping special keys (arrow keys) to send ESC codes. | |||
** YouTube video showing TDV emulation running S3-CONF program under SINTRAN [https://youtu.be/-DP_Q-nxQQw] | |||
Line 179: | Line 186: | ||
* Reading head 4-7 fails on all tracks with error "Address mismatch" | * Reading head 4-7 fails on all tracks with error "Address mismatch" | ||
I also got a TDV 1200 terminal, which upon startup had a capacitor in the powersupply to burn. I | After buying an MFM emulator from [https://www.pdp8online.com/mfm/] and getting help and support, including firmware extension to identify and read ND disk format I have been able to partially dump the contents of the disk. | ||
To connect to the ND machine I use a serial-to-current loop adapter i bought from Mouser. | The challenge is that the heads 4-7 is reading the "next" track because they are misaligned - and I need to add some HW to try to make the disk adjust how it reads it heads - as described here [http://www.pdp8online.com/mfm/head_servo/] | ||
Using the MFM emulator I am now able to boot the ND-100/CX machine from an disk image I have prepared in my emulator. | |||
I also got a TDV 1200 terminal, which upon startup had a capacitor in the powersupply to burn. I have replaced the capacitors in the powersupply, but there is some unstability that I believe is related to heat (read:old chips - or more capacitors that needs to be replaced) | |||
Short YouTube video showing the problem: [https://youtube.com/shorts/uek6hpqzYvE] | |||
To connect to the ND machine I use a serial-to-current loop adapter i bought from Mouser. [https://no.mouser.com/ProductDetail/Advantech/BB-232CL9R?qs=zW32dvEIR3vYFmSSVfM7ig%3D%3D&countryCode=NO¤cyCode=NOK] | |||
==References== | |||
<references /> |
Revision as of 16:29, 28 November 2023
Real name: | Ronny Hansen |
Role: | Developer, Architect, Geek |
Interrested in: | Everything between Embedded and Cloud |
A long time ago, in another universe it seems, I was using SINTRAN on an ND-100 at our electronics/computer school. We configured and ran the machine after we inherited it.
These days I am a Cloud Architect, Developer and Geek - and the last years I have been spending an unhealthy amount of time writing emulators. You can read how this crazy journey started here [1]
ND-100 Emulator
I have successfully (with some help) created an ND-100 emulator in .NET/C# with peripherals such as TeleType, Serial Ports, Floppy and HardDrive.
The emulator contains a debugger, disassembler and code tracer in addition to logic to mount different floppy-image, read/write hardddrive, loading BPUN and PROG files directly into memory.
I have successfully dumped and booted SINTRAN versions H, K, L and M in ND-100 mode.
This YouTube video shows a boot of SINTRAN L in the emulator [2]
What's working in the ND-100 emulator
- SINTRAN H boots and runs (with a minor hardcode in the emulator to fix ABSTR bug (?))
- SINTRAN K,L and M boots and runs (with a minor "workaround" in the Memory Management system because of a bug somewhere)
- Test programs that validates the opcodes so far
- ONE—CHECK, TWO—CHECK, THREE—CHECK
- FOUR—CHECK (a few bugs still)
- INSTRUCTION-B.BPUN (PROGRAM NUMBER: 204384B DATE ISSUED : 83.11.01)
- PAGING-B.BPUN (PROGRAM NUMBER: 203098B 1982)
- FLOPPY-FU-1986F (All tests work except Test 2 "Format Decoder Test" on my PIO floppy driver)
- Test programs on floppy "210523E00-XX-01D"
- INSTRUCTION - Version: C00 - 1986-10-30
- "48 BITS FLOATING INSTRUCTIONS" - not working as I am only emulating 32 bits FPU
- PAGING - Version: C00 - 1986-10-16
- All tests report success in MMS-1 and MMS-2 mode.
- INSTRUCTION - Version: C00 - 1986-10-30
What's NOT working in the ND-100 emulator
- SINTRAN K,L and M triggers a "Memory protection" after a "Page-not-in-memory". This happens to just one specific page, so at the moment "Memory protection" is disabled while I am trying to identify the reason.
- MON 131 ABSTR behaves "buggy" in SINTRAN H
- Something odd happens with zero-pointers for some logical devices sending the CPU into a loop at P=0
- Guessing there is an opcode not working 100% that failed some initialisation.
- Copying file from papertape driver to SINTRAN H disk with "COPY 'FILE:BPUN' PT1' fails after 129 bytes. It just stops, and I have to cancel the copy with ESC key.
I am looking for the following
- SINTRAN N (the newest version of SINTRAN) and patch files for Y2K.
- All SINTRAN III versions are of interrest. And PATCH files. Did i mention PATCH files?
- Other binary images (Tape, PaperTape, HDD, Floppy,+++)
- Source Code. Any source code. Especially test programs and IO drivers.
Things I am working on
- Finding the bugs that forces me to have workaround for ABSTR and Memory Management (Guessing: opcodes and/or ALU flags)
- Implementing the missing opcodes
- «Commercial Extended» (CE) option (BCD)
- CX opcodes (Stack, Segment,)
- ND-110 Specific opcodes
- Since I now have the ND-110 emulator working, I should be able do decode how the missing opcodes work and get them working. But in reality I dont think I need the ND-110 specific opcodes, as they are mostly added for performance reasons.
ND-100 Running in the browser
- Working on making the emulator(s) working in the browser by compiling C# to WebAssembly
- CPU is running nicely, working on giving access to IO devices
- You can test by going to https://retrocore.hackercorp.no/ and selecting machine=ND100 then powering on the Emulator.
- Feedback, comments, and help is much appreciated
- I am able to mount HDD for code running in the browser, but booting and running SINTRAN is painfully slow. So maybe not so good idea to do that..
Open Source
- When I have a stable working version, I am planning to put the source code on GitHub under a BSD License. Then everyone can look at the code, modify it or just run it.
- I have been playing with the idea on porting my C# code to C - when its stable. And integrate it in the SIMH projects [3]. For this I may need help :)
ND-110 Emulator
- ND-110 MicroCode CPU
- Creating a new CPU emulator at the MicroCode level to teach me more about the internals of the opcodes, but also to (hopefully) help me identify "features" in my ND-100 Emulator
- Everything is written in C#/.NET7
- MicroCode compiler works.
- MicroCode retrieved from PDF document using OCR techniques mixed with some "text washing" gives me a file with 16600 lines of microcode I manually have validate against the PDF. After retriving a copy of a ROM for a ND-110 cpu board, I could compare the compiled result with the ROM and found 150+ errors in the source file. Now that is fixed, and the compiled microcode is identical to the ROM.
- MicroCode CPU working. I have implemented registers, ALU (actually its 4x Am2901 chips) and interrupts (Am2914 chip)
- The remaining parts are to get the interrupt subsystem 100% correct, then add memory management and implement Traps.
- Macro code execution works, except interrupts and traps.
- This CPU is definitively slower than the ND-100 emulator, but hopefully behave 100% like the original. This way I can verify behavior differences between the ND-100 opcodes and the ND-110 opcodes.
- If you want to test the emulator/debugger, its available at https://nd110.hackercorp.no/
- Creating a new CPU emulator at the MicroCode level to teach me more about the internals of the opcodes, but also to (hopefully) help me identify "features" in my ND-100 Emulator
ND-120 Emulator
- ND-120 FPGA CPU
- Creating a new CPU emulator at hardware level using the original design documents from 1988
- Draw the digital logic using Logisim Evolution.
- Finished : CGA (CPU Gate Array)
- Started : DGA (Decoder Gate Array)
- Remaining: PCB, PAL's and some special chips (like the UART).
- I have secured a dump of the microcode from EPROM on a real ND-120 CPU.
- Convert the schematics to Verilog (Built in functionality in Logisim).
- Make test programs using Verilator to test the logic, then program that into an FPGA HW Device to test.
- Development is done in the open, check out https://github.com/RonnyA/nd-120
- Help is much appreciated as I am new to Verilog and FPGA programming
- When CPU PCB is finished, with serial port access to OPCOM the next step is to implement support for IO devices like floppy and harddrive.
- Draw the digital logic using Logisim Evolution.
- Creating a new CPU emulator at hardware level using the original design documents from 1988
ND Controller card Emulator
- Controller card for HDD emulated in hardware FPGA
- Today you need an real working HDD or an MFM emulator with MFM controller card in an ND machine to boot.
- This project aims to solve this by emulating a real controller using FPGA, and having the "HHD DISK" as an image on a SD card.
- Emulation of floppy controller is also planned.
- This way we will be able to run test programs and boot ND hardware that doesnt have working disk/disk-controllers.
TDV 2215 Emulator
- Creating an emulator of the TDV2215 terminal.
- Using the original schematics, an emulated 8085 CPU and ROM dumps from an original TDV.
- The ROM code does some HW validation and fails with "ERROR NO.: qt" -There are multiple areas it can fail: Z80SIO UART emulation, Interrupt handling and memory mapping.
- I am still working on mapping the original HW to my emulator.
- Using Ghidra to reverse engineer the ROM code, but its hard to understand what the ROM code really tries to do, and why it fails. Having had the source code with comments would have been helpful :)
- YouTube video showing boot here: [4]
- Added TD2200 support directly in the emulators "graphic" mode
- Decoding ESC sequences and sending ESQ sequences based on TDV manuals describing some of them. Adding in som VT100 emulation to make the rest work. Mapping special keys (arrow keys) to send ESC codes.
- YouTube video showing TDV emulation running S3-CONF program under SINTRAN [5]
ND-110 Compact
I have beeen so lucky that I have gotten a real ND-110/CX Compact with the following HW configuration
SLOT | ID | PCB | Description | Print and ECO |
---|---|---|---|---|
12 | 324113 | PCB 3042 | 1 MB Memory | Print A ECO D |
11 | 322623 | PCB 3023 | ND100 MEGALINK IF | Print D ECO K |
10 | 324534 | PCB 3094 | ETHERNET IF. II | Print C |
9 | 324011 | PCB 3111 | 8 TERM IF W/FIFO | Print C |
8 | 324012 | PCB 3112 | 8" + 5 1/4 FLOPPY | Print B |
7 | 322671 | PCB 3041 | N-100 ST 506 DISK CONTR. | Print E ECO K |
6 | 322623 | PCB 3023 | ND100 MEGALINK IF | Print D ECO K |
5 | 322623 | PCB 3023 | ND100 MEGALINK IF | Print D ECO G |
4 | 322615 | PCB 3015 | ND100 HDLC W/A.LO | Print <unknown> |
3 | 322615 | PCB 3015 | ND100 HDLC W/A.LO. | Print S ECO V |
2 | 324137 | PCB 3090 | ND110 - CPU&MM 32B | Print K ECO R |
1 | 322672 | PCB 3042 | N100 2MB RAM | Print A ECO D |
The machine also has a Micropolis 1325 ST506 74MB drive. Sadly there is some issues with reading data from it.
- Reading head 0-3 works on all tracks
- Reading head 4-7 fails on all tracks with error "Address mismatch"
After buying an MFM emulator from [6] and getting help and support, including firmware extension to identify and read ND disk format I have been able to partially dump the contents of the disk. The challenge is that the heads 4-7 is reading the "next" track because they are misaligned - and I need to add some HW to try to make the disk adjust how it reads it heads - as described here [7]
Using the MFM emulator I am now able to boot the ND-100/CX machine from an disk image I have prepared in my emulator.
I also got a TDV 1200 terminal, which upon startup had a capacitor in the powersupply to burn. I have replaced the capacitors in the powersupply, but there is some unstability that I believe is related to heat (read:old chips - or more capacitors that needs to be replaced) Short YouTube video showing the problem: [8]
To connect to the ND machine I use a serial-to-current loop adapter i bought from Mouser. [9]