6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Fri Sep 20, 2024 5:44 am

All times are UTC




Post new topic Reply to topic  [ 23 posts ]  Go to page Previous  1, 2
Author Message
PostPosted: Sat Sep 12, 2015 3:31 pm 
Offline
User avatar

Joined: Tue Nov 16, 2010 8:00 am
Posts: 2353
Location: Gouda, The Netherlands
cr1901 wrote:
I don't think your core provides enough control signals to the outside world for me to do that

What signals would you need ?


Top
 Profile  
Reply with quote  
PostPosted: Sat Sep 12, 2015 9:21 pm 
Offline

Joined: Wed Feb 05, 2014 7:02 pm
Posts: 158
I'd have to think whether I need more, but at the very least, I'd need a signal that denotes whether your core is "ready or not ready" to fetch the next address. Something akin to a pipeline stall signal.

But this is later. I can live with the halved performance on the Wishbone bus for now.


Top
 Profile  
Reply with quote  
PostPosted: Sun Sep 13, 2015 5:08 am 
Offline
User avatar

Joined: Tue Nov 16, 2010 8:00 am
Posts: 2353
Location: Gouda, The Netherlands
By "next address", do you mean the previous + 1 ?


Top
 Profile  
Reply with quote  
PostPosted: Sun Sep 13, 2015 8:18 am 
Offline
User avatar

Joined: Sun Dec 29, 2002 8:56 pm
Posts: 452
Location: Canada
In the FPGA, Block RAM's are incredibly fast. It's possible to use the synchronous RAM in an asynchronous fashion by clocking the RAM at a higher clock frequency than the processor core. For instance using a 3x core clock to clock the block RAM. This avoids the need to use a next-address output from the core and instead the normal address bus can be used.

_________________
http://www.finitron.ca


Top
 Profile  
Reply with quote  
PostPosted: Sun Sep 13, 2015 8:49 am 
Offline
User avatar

Joined: Tue Nov 16, 2010 8:00 am
Posts: 2353
Location: Gouda, The Netherlands
Rob Finch wrote:
For instance using a 3x core clock to clock the block RAM. This avoids the need to use a next-address output from the core and instead the normal address bus can be used.

My problem with that approach is that I wouldn't know where to begin with the proper timing specification for that. Do you have experience with this ?


Top
 Profile  
Reply with quote  
PostPosted: Sun Sep 13, 2015 10:55 am 
Offline
User avatar

Joined: Sun Dec 29, 2002 8:56 pm
Posts: 452
Location: Canada
Quote:
My problem with that approach is that I wouldn't know where to begin with the proper timing specification for that. Do you have experience with this ?


Yes, specifying timing may be the problem.
I had the FISA64 cache setup this way for a while and it seemed to work, but I switched it to using the negative clock edge instead. It may have been giving me timing error messages which I ignored.
I didn't use an explicit timing spec in a constraints file as the clocks are all related to (synchronous to) a master clock. The tools check for proper timing automagically.

It's the same idea as using the negative edge of the clock to clock the BRAM. Using the negative edge of the clock is similar to using a 2x clock. It gives 1/2 the time to access the BRAM.

It does mean you have to generate another clock and pass the clock signal around, so it's not pretty in code.

The reason to use a 3x clock (or higher) is that the BRAM should be guaranteed to have a full access time even if the clock synchronization is off a bit.

_________________
http://www.finitron.ca


Top
 Profile  
Reply with quote  
PostPosted: Sun Sep 13, 2015 1:48 pm 
Offline

Joined: Wed Feb 05, 2014 7:02 pm
Posts: 158
Arlet wrote:
By "next address", do you mean the previous + 1 ?
Yes. That said, I think I need to finish designing my current "toy" system and upload the code (I have your code linked as a git submodule).


Top
 Profile  
Reply with quote  
PostPosted: Sat Sep 19, 2015 8:36 am 
Offline

Joined: Wed Feb 05, 2014 7:02 pm
Posts: 158
Decided to compromise... I created a bus that's compatible with Arlet's core and then created peripherals that respond to this bus. For the purposes of creating 6502 SoCs, all peripherals I create- except for those emulating 65xx chips- will use Arlet's core timing; the toolbox I use to write HDL doesn't really allow negedge clocks, save for faking it by inverting a posedge clock.

If I need Wishbone or ASIC 6502 timing, then I'll create bridges between each bus to convert bus timings from one format for another (6 different permutations :/).

Ah well, this works and it's a start (as of the first commit, this really only works for one dev board. I'll fix that in the upcoming days.

https://github.com/cr1901/n6502fpga


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 23 posts ]  Go to page Previous  1, 2

All times are UTC


Who is online

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