6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Sat Nov 23, 2024 4:59 am

All times are UTC




Post new topic Reply to topic  [ 842 posts ]  Go to page Previous  1 ... 27, 28, 29, 30, 31, 32, 33 ... 57  Next
Author Message
PostPosted: Sat Mar 26, 2016 12:04 am 
Offline

Joined: Mon Mar 02, 2009 7:27 pm
Posts: 3258
Location: NC, USA
BigEd wrote:
(The advantage of hex is that each digit maps exactly to four bits, and you soon get to recognise what the values are. It becomes obvious that 8000 has just the top bit set, FFF0 has the twelve top bits set. It becomes natural to AND and OR these values in your head. Bits are important because it's bits which are dealt with in address decoders - the fewer the better.)

Brad lose decimal, hex is most efficient! I realized this when modding Arlet's core for added instruxins. Learning hex is like learning how to ride a bike, you never forget once you learn it. Not looking down, just my .02$ Going back to lurking...

_________________
65Org16:https://github.com/ElEctric-EyE/verilog-6502


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 26, 2016 12:53 am 
Offline

Joined: Sun Apr 10, 2011 8:29 am
Posts: 597
Location: Norway/Japan
Yep, another +1 for hex. Hex maps to bits, and decimal doesn't. Octal maps to bits as well and was common back in the mini computer age. Fewer values to remember and thus faster to learn, but as octal maps to three and three bits it's less convenient for a lot of what we do. Works well for front panels though..


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 26, 2016 2:49 am 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 690
Location: Gillies, Ontario, Canada
White Flame wrote:
I'd think that instead of using a ROM chip, you would be one to wire up bits of ROM individually using wire jumpers from an address multiplexer to the data bus. ;)


Indeed, but 1500 74HC254's and 187 multiplexers may be pushing it, even for this project!
I am at a standstill while I decide on the boot method now.

Looking at having logic stuff the 6502 memory from a 32k serial eeprom now.
Will only need maybe 2k of code to get a boot program running though.
The 6502 needs enough code to be able to initialize an SD card in Raw format.

I am also considering using modern parts for the external cartridge.
The cart. would use any available technology to stuff the SRAMs.
AVR with SDCard, ARM with config ROM, uC with serial PROM, etc
This would mean that as technology evolves, so could the cartridge.
This does not "really" violate my goals since the cart. is external, but it's not as cool.

Much to consider.
Too bad I have 20 dead ROMs!

Brad


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 26, 2016 10:54 am 
Offline

Joined: Sat Jan 02, 2016 10:22 am
Posts: 197
Diode rom ??

http://hackaday.com/2013/10/18/making-a-diode-matrix-rom/


How short a boot loader can you write ??

The Elliot 803 managed it in 4 words!

http://www.billp.org/ccs/ElliottAlgol/initialinstructions.html


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 26, 2016 2:33 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 690
Location: Gillies, Ontario, Canada
Martin A wrote:
Diode rom ??

http://hackaday.com/2013/10/18/making-a-diode-matrix-rom/

How short a boot loader can you write ??
The Elliot 803 managed it in 4 words!

http://www.billp.org/ccs/ElliottAlgol/initialinstructions.html


Now that is cool indeed!
My 6502 will need enough code just to perform 2 tasks...

1) Get an SPI Flash initialized for read.
2) Fill it's own 64K program Memory from the Flash.

If I could get the code down to something like 64 bytes, I would actually consider Diode ROM, or just muxed Bytes.
That would certainly add some over-the-top real retro cool to this project.



This is one of those large decisions to be made... (A) Boot Logic on the board, or (B) Boot Logic on the External Cartridge.
Here are my thoughts so far on both, and how each one effects my original goals...


(A) Boot Logic on the board...
Obviously, this jives perfectly with my retro goals, as I only need common logic and ROM.
The easiest path would be a small 1K ROM mapped to Address Space.
The ROM would fill the 6502 with enough code to read the Cart. memory (probably SPI Flash).
From there the 6502 would fill all 4MB with Sound and Graphics data from the Cart. memory.
Another advantage to this system is that more then 4MB can be accessed.
The downside is that the Cart. memory has to be a certain type, like Flash only.
As memory technology changes (it always does), Vulcan Boot Logic goes obsolete.



(B) Boot Logic on the External Cartridge...
This is obviously the most flexible and obsolescence proof system possible.
Any conceivable type of storage can be used; flash, prom, uC, SSD, etc.
This will also be the fastest system, as the 6502 will only have a single 10ns 64K program memory.
Another plus is that others can create cartridges using technology they have available and know.
Another advantage... easy transfer from PC to Cartridge. An SD card is an obvious contender.
The one downside to this system is that modern components are required on the External Cartridge.
A simple AVR Tiny and a huge Flash could be used for instance, or something much more complex.
This doesn't really violate my rules as the Cartridge is external to the system.
The Cartridge can actually be yanked after bootup, so Vulcan would still be running off internal guidance.


Something is telling me that Option (B) is bar far the best choice, and perhaps my ROM failure is a sign.
I already have this system working, as this is how I booted the system during testing... AVR + SDCard.
Being able to cross develop easily on a PC and then use an SD card is certainly a bonus.
In 3-5 years when NOR and NAND flash is extinct (yes, it will happen), I won't need a redesign.


Hmmm... nothing like answering your own question by rambling on in a Forum! Option (B) it will be!
I shall bolt the 64K back onto the 6502, and run an external Cartridge Port again.

Development is back on track.
My next post will show the 6502 moving some Sprites around.

Cheers!
Radical Brad


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 8:48 am 
Offline
User avatar

Joined: Tue Nov 16, 2010 8:00 am
Posts: 2353
Location: Gouda, The Netherlands
You can make a very compact diode ROM by mounting the diodes vertically between two pieces of stripboard in 'cordwood' technique. If you run the copper strips at 90 degree angles, you have easy row and column access, and 100 bits per square inch. Just make sure you don't make any mistakes because they'll be almost impossible to fix.


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 10:06 am 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10986
Location: England
If you go down to half the density, you could have two-pin sockets in adjacent perfboard holes, and plug diodes in vertically as needed. This does mean wiring up at least one direction - could perhaps use stripboard for the other, by tearing off alternate strips.

For historical context, I just read this about the 41-instruction bootstrap for EDSAC from 1949:
Quote:
The next major advance demonstrated by this machine, was a continuation of Wheeler's subroutine idea. He invented the concept of a bootstrap - a program that is run every time the machine is turned on. The first was put in the read only memory, (ROM) of the system in August 1949. This was an extremely advanced system which loaded in the programs to be executed, and also allowed the programs to be relocated in different parts of memory, (main program, sub-routine and data). This helped prevent the computer storing many copies of the same sub-routine, and was used enormously later in operating systems, especially in multi-programming and multi-user systems. It no doubt forms an essential part of the operating system on your computer.

Wheeler has often been credited as one of the most creative programmers ever, due to his achieving all this despite the ROM space of only 41 instructions. Not only did he achieve this, he even optimised it with the 1 space he had left over, which he used to store optimising constants for the programs.


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 10:17 am 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 690
Location: Gillies, Ontario, Canada
I am liking the Diode Matrix idea a lot!
Will have to see how minimal the code would be to read an SPI Flash memory once I get my hands on one.

Brad


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 1:10 pm 
Offline
User avatar

Joined: Sun Oct 13, 2013 2:58 pm
Posts: 491
Location: Switzerland
Oneironaut wrote:
The Rules...

- Only 7400 logic gates that were available in the 1980's may be used. Chips like 7404, 74688, etc.



How's a SPI flash going to be compatible with this rule :?


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 1:45 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 690
Location: Gillies, Ontario, Canada
cbscpe wrote:
Oneironaut wrote:
The Rules...

- Only 7400 logic gates that were available in the 1980's may be used. Chips like 7404, 74688, etc.



How's a SPI flash going to be compatible with this rule :?


The cartridge is external to the unit.
Anything not part of the actual board is not counted (VGA Monitor, Speakers, Cartridge, etc).

Brad


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 5:55 pm 
Offline
User avatar

Joined: Fri Dec 11, 2009 3:50 pm
Posts: 3367
Location: Ontario, Canada
Oneironaut wrote:
I am liking the Diode Matrix idea a lot!
Will have to see how minimal the code would be to read an SPI Flash memory
I'm guessing a good chunk of the code in the diode matrix ROM will be devoted to initialization of the memory chip (before the real work of copying bytes begins). So, simpler initialization means a smaller diode ROM. Perhaps you'd like to consider this SPI EEPROM (datasheet attached) and see how its initialization compares with Flash.
Attachment:
M95M02-DR SPI EEPROM 256kx8.pdf [741.77 KiB]
Downloaded 63 times

Speaking of ROM, don't forget that authentically retro TTL PROM's are still available (although no longer in production). For example a 16-pin DIP that contains 32 bytes. (74S188 and 82S23 are open-collector versions; 74S288 and 82S123 are tri-state output. Many other numbers are equivalent to these.) Access time is around 50 ns.

Diode matrix ROMs are cool, too, but will probably require wait states. If you're going that route anyway (wait states, I mean) then you can consider a matrix ROM storing multiple bits per element. IE: at each junction of the matrix, instead of having just a simple diode or no diode, have a single resistor or zener whose value conveys more than just a zero-one decision. Using four different values you get 2 bits per element. Using eight different values you get 3 bits per element, and so on. As the number of bits rises it rapidly becomes more challenging to build a reliable circuit. Even so, if you were crazy enough to build a large ROM this way then 3 or more bits per element might be justified. But IMO for a small ROM there's no sense going beyond 2. I admit it's pretty whimsical. But I have some notes on how it could be not-too-inefficiently done... 8)

It's best if you know how many bytes will be required first. That'l affect you decision re ROM type.

cheers,
Jeff

_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html


Last edited by Dr Jefyll on Mon Mar 28, 2016 6:12 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 6:08 pm 
Offline
User avatar

Joined: Tue Nov 16, 2010 8:00 am
Posts: 2353
Location: Gouda, The Netherlands
Quote:
Diode matrix ROMs are cool, too, but will probably require wait states

I assume this is because you have the diode to provide a '1', but need a pull-down resistor to provide the '0' (or the other way around), and the resistor adds an RC delay. You should be able to speed it up by adding a low impedance n-type MOSFET parallel to each resistor, and turning that on during idle phase of the clock to precharge all the outputs to '0'.


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 6:14 pm 
Offline
User avatar

Joined: Tue Nov 16, 2010 8:00 am
Posts: 2353
Location: Gouda, The Netherlands
I was also thinking that you could attach a SPI memory chip to the VGA output of a PC, and program it by displaying an image.


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 6:16 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10986
Location: England
That's a great idea!


Top
 Profile  
Reply with quote  
PostPosted: Mon Mar 28, 2016 7:02 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8544
Location: Southern California
Jeff's idea could be extended to use an 8-bit flash, or half-flash, A/D converter which has no setup requirement and can be read like a memory location. Very simple. For vintage's sake, I think the ADC0820 has been out for three decades, and it'll do something like three-quarters of a million conversions per second this way. The small integral nonlinearity (INL) error (like all converters have) and the resistor tolerance and the resistor inventory you'll need to buy may pretty much rule out getting 8 bits per resistor, but four is well within reach. Modern carbon-film resistors marked for a tolerance of 5% are usually within 1%, and you could use a logarithmic scale anyway to ensure dependability. If you don't want to use the A/D converter (like because you want to be even more self-sufficient), you could make a 4-bit flash converter yourself with four common quad op amps.

_________________
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 842 posts ]  Go to page Previous  1 ... 27, 28, 29, 30, 31, 32, 33 ... 57  Next

All times are UTC


Who is online

Users browsing this forum: Google [Bot] and 27 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: