NOXROM Cartridge

For experts to discuss very technical stuff and newbies to ask why the Spectrum they bought off ebay doesn't work.
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

NOXROM Cartridge

Post by RMartins »

As some of you might know/remember, I have been developing my NOXROM cartridge.

After a few iterations, I have a working prototype, some firmware and some software adapted to work with it.
Meanwhile during this last year I did a presentation of it to a few coworkers, in a technology sharing session at work.

From this, sparked the idea of presenting this to a broader/wider set of people, and in a twist of fate, a friend proposed to submit it as a talk to FOSDEM (Open Source Conference), which got it's first RetroComputing DevRoom for 2018.

So, I submitted it for appreciation, and "I got in". (kudos to anyone who recognizes this movie quote)

So here is my talk, along with some videos of a game (R-Type) that as been converted to not only run from NOXROM cartridge, but also loads all levels seamlessly from it.
https://fosdem.org/2018/schedule/event/ ... millenium/

Finaly, I would suggest you all to come to FOSDEM, since it's a very nice conference, with great subject matter, in several areas and the entrance is free.
User avatar
Seven.FFF
Manic Miner
Posts: 735
Joined: Sat Nov 25, 2017 10:50 pm
Location: USA

Re: NOXROM Cartridge

Post by Seven.FFF »

I hope your talk goes well, Rui! Will you post a video afterwards?
Robin Verhagen-Guest
SevenFFF / Threetwosevensixseven / colonel32
NXtel NXTP ESP Update ESP Reset CSpect Plugins
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

As far as I'm aware, all talks are saved in video for posterity.
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

Bumping this, since the Conference is next weekend.

Anyone expecting to atend or watch the live streams of the event ?
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

Just finished my talk, a while ago, and there was live streaming of it.
I hope some of you guys watched it.

If not, the video downloads will probably be available, in a few days

P.S.
Thank you Bob :)
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

For everyone that was unable to attend or see the live streaming, the video of my talk "ZX Spectrum in the new Millenium" at FOSDEM 2018 is now available.
https://fosdem.org/2018/schedule/event/ ... millenium/

Alternative link:
MP4 https://video.fosdem.org/2018/AW1.121/z ... lenium.mp4

WebM https://video.fosdem.org/2018/AW1.121/z ... enium.webm
User avatar
Spud
Manic Miner
Posts: 372
Joined: Sun Nov 12, 2017 8:50 pm
Contact:

Re: NOXROM Cartridge

Post by Spud »

Thanks for posting. I understood some of it but the majority went over my head :) Good on Bob Pape for assisting with the modifications needed to R-Type.
User avatar
Seven.FFF
Manic Miner
Posts: 735
Joined: Sat Nov 25, 2017 10:50 pm
Location: USA

Re: NOXROM Cartridge

Post by Seven.FFF »

I am looking forward to watching this :) I got derailed on Sunday.
Robin Verhagen-Guest
SevenFFF / Threetwosevensixseven / colonel32
NXtel NXTP ESP Update ESP Reset CSpect Plugins
Bizzley
Microbot
Posts: 124
Joined: Thu Nov 16, 2017 10:47 am

Re: NOXROM Cartridge

Post by Bizzley »

Thanks for posting the link, it's good to see you 'in the flesh' as it were.

It looked like the talk went very well, most of the hardware stuff was way over my head also but at least I understood the part about R-Type :D
"He made eloquent speeches to an audience consisting of a few depressed daffodil roots, and sometimes the cat from next door."
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

Due to several organisational/setup issues, the hardware was not visible in the video.

But here is a picture from a tweet of someone in the audience, that shows the hardware working.
Image

If you noticed, the video, was not correctly framed, so the top part of every presentation in that room, has the top part clipped unfortunately.
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

The room was full, but not packed, since there were a few seats available (4 or 5).
However, I wasn't aware that there was a line waiting to get in ...

Tweet about waiting to enter the talk
User avatar
NeoStuey
Drutt
Posts: 12
Joined: Wed Feb 07, 2018 3:39 pm

Re: NOXROM Cartridge

Post by NeoStuey »

Very informative and exceptional work demonstrated, though my understanding of it all was limited.

And dare I say it? But in my own opinion by expanding the original 48k to 512k usable this feels more Spectrum Next than the actual Spectrum Next with all it's extras which don't quite feel close enough to the old skool Speccy to me.

I wish you well on your continued development of the project and hope one day to be a Noxrom owner.

And a final question at the end during the Q&A you mentioned being able to port it to the ZX81, would the Noxrom work on a 128k Spectrum running 48k mode or would a new set of instructions have to be written to run on the 128 hardware? Thinking 128k RGB > 48k composite video capabilities.
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

The only issue I forsee with a 128KB (+2A, +2B, +3) Spectrum, is not related with the Cartridge per se, but with the expansion port.
The 128KB (variants) expansion port changed some of the lines (ROMCS in particular), because an extra ROM enable was added, since 128KB models have 2 ROMs.

Any compatible interface that provides a compatible cartridge connector, that triggers correctly both ROM enable lines that exist on the 128KB boards will work as expected.
An example is the Spectra Interface
For the special cases (+2A and +3), there is an adapter.

I may eventually create a new compatible Interface, that could work in 48 and 128 computers, but this could be tricky and prone to failures if connections require some physical user action/selection. Still have to work that out.
In the worst case, a slightly different interface could be required for each ZX model.

Extra info available on Wikipedia
https://faqwiki.zxnet.co.uk/wiki/ZX_Spe ... _connector

NOTE: There are also differences to a ZX80 or ZX81 expansion port, so a proper interface is also needed.
https://faqwiki.zxnet.co.uk/wiki/ZX80/81_edge_connector

IMPORTANT: ZX80 will not work from stock version, since the ROMCS line IS NOT routed to the expansion port.
But nothing stops you to add it, in the same place as the ZX81, since they are compatible on the remaining pins :)

Regarding instructions to page in the cartridge, they are exactly the same.

However, since the display rendering is different on ZX80/ZX81, and ZX48 and 128, any firmware or software to run in the cartridge, must have this into consideration, i.e. specific code to run/display in ZX80/81 distinct from code to run/display in ZX48 and 128.
hikoki
Manic Miner
Posts: 576
Joined: Thu Nov 16, 2017 10:54 am

Re: NOXROM Cartridge

Post by hikoki »

Could 48K machines load any 128K game with this interface ?
..without touching their innards :)
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

hikoki wrote: Sun Feb 11, 2018 11:12 am Could 48K machines load any 128K game with this interface ?
..without touching their innards :)
Nope.

It uses a different way to swap pages, in fact, just one page, the ROM page.
However, probably most 128K Games could be ported to it, as long, as they do not need more than48K active memory.
Usually, games are more about data (Sprites, music and stuff) than code, and more ROM is good for immutable data.
It's also possible to copy ROM to RAM, and then change the contents if needed.

So existing games, need to be converted.
hikoki
Manic Miner
Posts: 576
Joined: Thu Nov 16, 2017 10:54 am

Re: NOXROM Cartridge

Post by hikoki »

^^^
I think converting 128K games to be played with Sinclair machines would be quite appealing!
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

hikoki wrote: Mon Feb 12, 2018 10:09 am ^^^
I think converting 128K games to be played with Sinclair machines would be quite appealing!
Yes, and also converting multi-level games, like R-Type. Which currently are hard to play using any of the serial replacement interfaces (DIV-IDE, DIV-MMC, etc...).

It's also good to make new, larger games, like my planned remake of P.O.W. or like the new "The Sword of Iana", which was also released on another cartridge like system.
hikoki
Manic Miner
Posts: 576
Joined: Thu Nov 16, 2017 10:54 am

Re: NOXROM Cartridge

Post by hikoki »

Could 128K games be converted on the fly from original cassette tapes?
in some way that audio output from cassette player can be transformed by the interface
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

hikoki wrote: Mon Feb 12, 2018 11:08 am Could 128K games be converted on the fly from original cassette tapes?
in some way that audio output from cassette player can be transformed by the interface
Maybe you are dreaming too much :)

The Cartridge is just a ROM(FLASH) device, with paging capabilities.
It's not an interface per see, just a cartridge.

Converting any game, requires analysis of the code structure, data and 128K page addressing, and an eventual rewrite, as well as relocating code, etc...
I wouldn't say it's impossible to convert it automatically, but it probably requires a full thesis on disassembly and compiler work, to pull it off. :D

The good part, is that once a game code and data structure is known, a reasonable coder can probably move the code around to make it work, with the new restrictions, since usually, the code is structured in 16KB blocks, due to the 128K paging features, which is a perfect match for the ROM page (also 16KB).
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

I have though about, the possibility of addressing the ROM, in 4K pages, but this would require 4 registers of 5 bits each, to keep the pages completely separate from each other.

Alternatively, some mixed mode, where the pages would share some of the higher bits could be done, hence reducing the total amount of required bits.

For example, since we need 5 extra bits to address 512KB, having 8 bits, if we share 2 bits and then use another 3, we can have 2 pages, in just 8 bits.
pageA = 7, 6, 2, 1, 0
PageB = 7, 6, 5, 4, 3

The FLASH memory is structured in 4KB pages, so to make the most use of this setup, two 8 bit registers would be required, for a total of 4 * 4KB = 16KB of addressable ROM. But all this would make the address decoding more complex.

I don't see it has bringing many advantages, over the single 16K page, that would warrant the extra effort and hardware.
But someone might convince me otherwise :)

For example: it could be useful, to access a mixed set of Sprites, depending on current screen needs, without having to constantly be swapping ROM page(s). However, we can carefully bundle these close together, so that they fit inside the same 16K page.

If I ever add an external paging register, to be able to have 1MB instead of 512KB, I may think about this a bit more.

EDIT:
Actually, if we brake the 16K page into 4 x 4K pages, we need another 2 extra bits per page, which would require a total of 7 bits (5+2) per page :(
Last edited by RMartins on Mon Feb 12, 2018 8:08 pm, edited 1 time in total.
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

It would be interesting, to know, how many developers would be interested in having a sample cartridge, to play around, and make a game exploring the new possibilities.
hikoki
Manic Miner
Posts: 576
Joined: Thu Nov 16, 2017 10:54 am

Re: NOXROM Cartridge

Post by hikoki »

RMartins wrote: Mon Feb 12, 2018 7:32 pm
hikoki wrote: Mon Feb 12, 2018 11:08 am Could 128K games be converted on the fly from original cassette tapes?
in some way that audio output from cassette player can be transformed by the interface
Maybe you are dreaming too much :)

The Cartridge is just a ROM(FLASH) device, with paging capabilities.
It's not an interface per see, just a cartridge.
I would rather take my coffee with Sincclairin instead of Sugar. I've been told that it is impossible to plug anything into a 48k machine to convert it to 128K. It is necessary to open it and disconnect the upper 32K RAM.

This reminds me of one idea for a toy cartridge on the speccy.org forums, something with speaker like those used in greeting cards :mrgreen: Mcleod_ideafix suggested the idea of playing one tap/tzx from some STM32F0 microcontroller with 256KB flash : http://uk.farnell.com/stmicroelectronic ... dp/2488281
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

hikoki wrote: Mon Feb 12, 2018 9:21 pm ---
I've been told that it is impossible to plug anything into a 48k machine to convert it to 128K. It is necessary to open it and disconnect the upper 32K RAM.
...
If you really want to do that, you can start with a 16K Spectrum, and then add an external interface with the required RAM and paging registers to make it "compatible" with a 128K version.
However, besides RAM addressing, you would have other concerns to work around, like the dual ROM, not having an AY, Sinclair joystick ports or serial line capabilities.

It all depends exactly what you are trying to do, and to what extent you want it "compatible".
User avatar
RMartins
Manic Miner
Posts: 776
Joined: Thu Nov 16, 2017 3:26 pm

Re: NOXROM Cartridge

Post by RMartins »

I have been thinking on something for some time, which is to find a way to make use of the actual extra memory on a ZX Spectrum 48K.

To save some bucks, ZX spectrums use 8 times 64Kx1 bit memory chips, but they either user the lower or the upper part of the chip (only 32K, since the other part is flawed, hence why it was cheaper), and all chips must be identically flawed (upper or lower) in the same computer to be able to work.

However, it's possible to buy a new set of 64K memories, that are not flawed at all.
So with some clever trickery, we could eventually use the extra 32K available, transforming the 48K into a 80K computer :)
hikoki
Manic Miner
Posts: 576
Joined: Thu Nov 16, 2017 10:54 am

Re: NOXROM Cartridge

Post by hikoki »

^^^
Sounds good.. you mean an interface to make Sinclair macines manage up to 80K? I assume games which are based on that limit would work on Amstrad machines too
Post Reply