6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Tue Nov 12, 2024 6:26 pm

All times are UTC




Post new topic Reply to topic  [ 804 posts ]  Go to page Previous  1 ... 28, 29, 30, 31, 32, 33, 34 ... 54  Next
Author Message
PostPosted: Mon Mar 28, 2016 7:05 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 673
Location: Gillies, Ontario, Canada
For the Diode Matrix, I won't have any issues with speed because of the implementation I plan to use.
Instead of being mapped directly to the 6502 address space, it will be copied to SRAM.

On power on, a counter will simply run address while the 6502 is held off the bus.
Once the small SPI code (and reset vector data) is in the SRAM, the 6502 is engaged.

From there, the 6502 will now have the brain power to fill the rest of its SRAM from the SPI.

This is how my AVR Boot Loader is currently working, so it should work with the Matrix as well.

Brad


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

Joined: Mon May 25, 2015 2:25 pm
Posts: 673
Location: Gillies, Ontario, Canada
I wasn't sure how my stock of diodes was, but upon examination it would appear I am all good...

Image
A stock of 500 1N914 Diodes.

With what looks like 500 or more diodes, I could create a Matrix of 128 Bytes or so.
This considers using approximately 4 diodes per byte.

Now I will have to see how small I can make an SPI loader in 6502 assembly.
I thought the Diode Matrix was so damn retro cool, it became a must have.

Thanks for suggesting such a crazy idea!

Brad


Top
 Profile  
Reply with quote  
PostPosted: Tue Mar 29, 2016 7:45 am 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10977
Location: England
Glad you're going to tackle it - look forward to seeing the results!


Top
 Profile  
Reply with quote  
PostPosted: Tue Mar 29, 2016 12:42 pm 
Offline
User avatar

Joined: Wed Feb 13, 2013 1:38 pm
Posts: 589
Location: Michigan, USA
Yet another whimsical machination... If you build in a way to enable and disable the CPU clock and address decoder, you could build a Paper Tape Reader (blind loader) that could reset the CPU, supply both <clock> and <data> (instructions) for loading memory, and finally release the CPU via the reset vector. The Paper Tape Reader would need to supply the <clock> signals and <data> for each cycle in each instruction and turn the address decoder on and off during the correct cycle during each STA instruction. Other subtleties include generating six clock cycles after the Tape Reader releases the 65C02 from reset before the CPU reads the $FFFC and $FFFD vector bytes.

Crazy idea, yes, no (grin)?

Cheerful regards, Mike


Top
 Profile  
Reply with quote  
PostPosted: Tue Mar 29, 2016 1:06 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 673
Location: Gillies, Ontario, Canada
I actually kicked the card reader idea around this week!

Since mechanical devices are certainly my thing, I considered making a letter sized printed card reader. By using an array of say 64 photo-transistors, I could laser print pages that would be capable of storing 64 rows of 64 bits, for 512 bytes.

The paper reader would be more expensive and complex than the same size diode matrix, but does have the advantage of being able to make code edits by simply printing out a new page.

For this project, I will probably use the Diode Matrix.

Brad


Top
 Profile  
Reply with quote  
PostPosted: Tue Mar 29, 2016 7:19 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8540
Location: Southern California
The bar-code idea is what we talked about at viewtopic.php?f=1&t=3573&p=42930#p42930 . The ability to get going with as little as a marker and quadrille paper definitely holds some appeal! :D

_________________
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  
PostPosted: Tue Mar 29, 2016 7:51 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 673
Location: Gillies, Ontario, Canada
The mechanical scanner / reader is definitely over the top DIY retro cool.
I would have no problem fabricating a mechanical reader that could hold 512 bytes or more.

Making something that someone else could duplicate has been one of my goals though.
This is why I am only including active parts that are available from multiple sources.

I could easily reconstitute an old printer to make a paper feeder, but I am not sure if I want to include CNC machined components in this build.
The Diode Matrix is well within reach of anyone crazy enough to try building this thing from the plans I am making though.
My Boot Logic design also allows the Matrix to be replaced by any old ROM as well.

But then there is that cool factor! Imagine printing out an 8.5x11 page of dots to see it magically boot up a 6502!
Nah... I have to stick to semiconductors this time!

I do enjoy mechanical beasts though. Sometimes a welder is just as fun as a soldering iron!
It's been a while since I cobbled together electronics and mechanical bits...

http://lucidscience.com/gal-showall.aspx

The shack I weld from collapsed a few years ago, so it's mainly table top projects these days.

But imagine that DIY code reader humming along as the servo pulls the page through... so cool!
No... I must stick to the plan. Even the Diode Matrix is an over-the-top late addition!

Brad


Top
 Profile  
Reply with quote  
PostPosted: Thu Apr 07, 2016 12:58 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10977
Location: England
There's an interesting project with a diode matrix ROM on hackaday - see my post over here.

Also, for reference, there's a photodiode-based paper tape reader project here.


Top
 Profile  
Reply with quote  
PostPosted: Thu Apr 07, 2016 2:05 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 673
Location: Gillies, Ontario, Canada
Nice post, and it confirms my thinking that 1MHz would be no problem for this type of diode (same as what I have).

Time has been scarce lately, but I do know what my next steps are at least...

1) Code a simple SDCard Raw reader in AVR Assembly and test.
2) Convert said code to 6502 and test.
3) Optimize the hell out of said code, and count the number of diodes required.
4) Build the largest Diode Matrix ever seen in the last 40 years!
5) Watch my 6502 boot form the Matrix and then read the SDCard.

A little more explanation of the above insanity...

I have decided to use an SDCard as the external cartridge as a bare SPI Flash memory is just too expensive.
In order to keep the boot code ultra small, I will read the SDCard in SPI mode (Raw data only).
But to be tricky, I have made a PC program that adds a secret "key" to the 6502 memory image.
This will allow the PC to use FAT16, FAT32, or EXFAT and read the SDCard as normal.
The 6502 code will simply hunt through the sectors until it finds the key.
Finding the key will let the 6502 know that what follows is 64K of memory to write to SRAM.
The key will be a sequence of 256 values starting from 0, and ending on 255.
It is unlikely that this sequence could just accidentally exist, and makes sensing code ultra small.

So that is the basic plan so far.
It may be mid summer before I have any time again, so I will just think it over until then!

Cheers!
Radical Brad


Top
 Profile  
Reply with quote  
PostPosted: Thu Apr 07, 2016 2:16 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10977
Location: England
Interesting - I've opened a new thread about your SDcard idea.


Top
 Profile  
Reply with quote  
PostPosted: Thu Apr 07, 2016 3:14 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 673
Location: Gillies, Ontario, Canada
BigEd wrote:
Interesting - I've opened a new thread about your SDcard idea.


Thanks.

I should also expand on this a bit then.

Once the minimal boot code is clocked from the Diode Matrix to the 6502's SRAM, the 6502 will then "hunt" for the 64K program image on the SDCard, sequentially looking at all sectors starting at zero. This will basically ignore whatever file system may be on the card.

Once the secret key is identified, the 6502 then fills the rest of its 64K program memory based on the 64k that follows.

I know this could be a slow process, but if the cards are kept as FAT16, then this limits them to 4GB in size.
Reading every sector of a 4GB card would still be faster than the load time of Epyx Summer Games on a 1541!

Now within that 64K program image could be a much more functional SDCard reading routine that ca handle FAT or FAT32.
The rest of the Graphics and Sound data come from the SDCard, so the 6502 must continue to access it after booting.

I will probably force format my cards to FAT16 using DiskPart and then write a simple FAT16 set for the 6502.
4GB is more than enough room to store many games for this system!

Brad


Top
 Profile  
Reply with quote  
PostPosted: Thu Apr 07, 2016 6:42 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8540
Location: Southern California
Oneironaut wrote:
I have decided to use an SDCard as the external cartridge as a bare SPI Flash memory is just too expensive.

There's Microchip's SST25VF064 8MB SPI flash in an SO-8 for $3.79 in singles, at http://www.mouser.com/ProductDetail/Mic ... rUXA%3d%3d (I've used this one), and Cypress/Spansion's S25FL512S 64MB SPI flash in an SO-16 for $5.89 in singles, at http://www.mouser.com/ProductDetail/Spa ... %2fuMH8%3d . Spansion has another one that's 128MB in an SO-16, but it has two dice, so I think you'd handle it like two separate 64MB flash memories. I suspect 64 megabytes will be plenty for a 6502 system though. :)

_________________
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  
PostPosted: Thu Apr 07, 2016 6:59 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 673
Location: Gillies, Ontario, Canada
GARTHWILSON wrote:
Oneironaut wrote:
I have decided to use an SDCard as the external cartridge as a bare SPI Flash memory is just too expensive.

There's Microchip's SST25VF064 8MB SPI flash in an SO-8 for $3.79 in singles, at http://www.mouser.com/ProductDetail/Mic ... rUXA%3d%3d (I've used this one), and Cypress/Spansion's S25FL512S 64MB SPI flash in an SO-16 for $5.89 in singles, at http://www.mouser.com/ProductDetail/Spa ... %2fuMH8%3d . Spansion has another one that's 128MB in an SO-16, but it has two dice, so I think you'd handle it like two separate 64MB flash memories. I suspect 64 megabytes will be plenty for a 6502 system though. :)


The SPI has the advantage of lesser boot code on the Diode Matrix, but the SDCard option allows easy cross development on the PC.
With the SDCard, you can just save images and graphics directly to the card and then drop it into the Vulcan Cartridge Port.

It would also be cool to see the 6502 handle FAT32 and exFAT.

Another option I am tossing around is having a "KickStart" SDCard. Here is how that would work...

1) On power up, Vulcan loads the Diode Matrix Micro-Boot program and lets the 6502 start running.
2) The Micro-Boot program reads 64K worth of Program Memory code in RAW mode from a FAT16 formatted SDCard.
3) Vulcan would then display "Insert Cartridge" and wait for a large SDCard (FAT16, 32, or EX) to be inserted.
4) From there, Vulcan has full access to the entire SDCard using a proper file system.

The KickStart plan removes all speed issues, and offers unlimited storage.
Vulcan-74 has more than enough power to play fullscreen video and stream 4 channal audio, so extra storage space is good!

Just an idea.

Brad


Top
 Profile  
Reply with quote  
PostPosted: Mon Apr 11, 2016 11:44 am 
Offline

Joined: Thu Oct 29, 2015 8:07 am
Posts: 6
Oneironaut wrote:
It would also be cool to see the 6502 handle FAT32 and exFAT.

Feel free to borrow my old boot code from the C1: http://c1boot.cvs.sourceforge.net/viewv ... oot-alpha/


Top
 Profile  
Reply with quote  
PostPosted: Mon Apr 11, 2016 1:00 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 673
Location: Gillies, Ontario, Canada
I had some time yesterday to test some AVR SDCard code, and it was kind of a success.
Code was minimal, and just read raw data, streaming it out as PWM audio.
I recorded an hour of music and wrote it as raw 8 bit data to the card.

I tested about a dozen various cards from my collection...

Every 2GB card worked perfectly. File system was FAT16.
Some medium sized (2GB to 8GB) cards worked. 50% success rate.
Most larger cards failed. Even when force formatted to FAT16 with DiskPart.

Seems the SDHC cards refuse to operate in SD Mode.
For this reason, I have decided to not pursue the SD Card route any further.


This may sound a bit crazy, but I am going to retire from my electronics hobby.

Lately I have not been enjoying it much. Vulcan was fun, but that's about it.
In a world of Arduinos, Raspberry Pi, and non-hackable technologies, it's just not the same.
The days of jacking into a modern keyboard or display are gone. You need FPGA for anything.
Code is bloated, pre-made hi level cores and libraries. Not my kind of thing.
All of the reasons that made me start Vulcan-74 (see first post) are now overwhelming.

No big deal really, I have a LOT of other interests!
I change my life like this when I feel things getting stale. It was a long time coming!

Anyhow, I hope this thread will inspire others, it has been a slice.
I won't be returning, and all of my boards, parts, and tools are boxed and put away.

For the next decade, I intend to pursue self sustainable living (old technology mixed with new).
Also working on several other new web ventures that have zero to to with hacking or electronics.

This forum was a great source of community for me, and I enjoyed y stay here.
I would ask that this thread be locked now. The series is going off the air indefinitely.

6502.og.... Please keep the Old Spirit alive!!!!

Cheers!
Radical Brad


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

All times are UTC


Who is online

Users browsing this forum: No registered users and 26 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: