Post Reply 
WIP: 16C firmware hack for more memory
01-22-2023, 02:53 AM (This post was last modified: 01-22-2023 02:59 AM by brouhaha.)
Post: #1
WIP: 16C firmware hack for more memory
Back in 2005 when I came up with the first microcode patch for 15C extended memory (which was incomplete, and expanded upon by Hrast Programmer and J-F Garnier), I also wanted to expand the memory of the 16C. At the time, the 16C microcode to translate a user register number to a hardware register number and nibble offset seemed really complicated, and I couldn't figure out how the code dealt with the user registers staring at hardware 0xe0. I gave up on that, and haven't touched it until recently. Having spent time recently digging into the microcode of all Voyager models, I thought maybe it was time to try 16C expanded memory again.

I don't have it completely sorted out, but I did figure out how the 0xe0 RAM base works in both the register addressing, and in limiting the size of a program. I'm able to make that 0xc0, which allows for 427 program steps, or 854 registers (if word size is <= 4 bits). In principle I should be able to expand it even further. but I haven't tried yet.

What works is:
1. STO/RCL direct (0-F, .0-.F) work correctly, and the hardware address is computed correctly.
2. STO/RCL(i) work fine up to some limit that is computed incorrectly, Beyond that they give Error 3. For register numbers below the incorect limit, the STO/RCL (i) works correctly, using the correctly computed hardware address.
3. Can enter, SST, and BST through programs up to 427 steps
4. Label search seems to work correctly throughout the expanded program space.

What doesn't work is:
1. f MEM display of the count of available registers is very wrong
2. The limit for STO/RCL (i) is wrong
3. GTO . nnn doesn't work for 204 and above
4. The display of program line numbers above 210 (not 203!) wrap around, such that 211 is 99, etc., and wrap around again each time the number hits 210.

If I get these issues fixed, I'll try even more memory. Displaying program steps beyond 999 can't easily be made to work, so I'll probably put in a hard limit of 999.

STO/RCL (i) similarly can't easily be made to support register numbers beyond 999, and I'm not going to attempt to do anything beyond that. I'll probably clip the limit of registers displayed by f MEM to 999, even if there is in principle more memory that could be available.

The 16C with the standard-sized Voyager R2D2 ROM (6K words) has only 8 words left over, of which there are no more than 3 consecutive. This patch will require a larger ROM size. That's not a problem in simulation, but I don't know that extra-large ROM would work with HP firmware in an HP ARM 12C (either AT91SAM7L or ATSAM4C). It _might_ fit in the HP 15C LE, because it looks like their image includes the gap between the two ROMs. I've heard that other models don't really work in the HP firmware, but I haven't confirmed that myself. I'm only testing in my own Nonpareil.

Disclaimer: I'm not promising that I'll complete this work or publish it at any particular time. I'm mentioning it for amusement purposes only.
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
WIP: 16C firmware hack for more memory - brouhaha - 01-22-2023 02:53 AM
More labels? - brouhaha - 01-30-2023, 06:40 AM
statistical registers - brouhaha - 04-22-2023, 06:00 AM



User(s) browsing this thread: 1 Guest(s)