6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Mon Apr 29, 2024 3:24 am

All times are UTC




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: 65Org16 - silicon pi
PostPosted: Sun Aug 28, 2011 11:21 am 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10793
Location: England
I've updated the bootrom on the proof-of-concept 65Org16 system project which sits in an OHO module. I've just got to the point of loading and running a first non-trivial application program using the hex loader:
Code:
Send 65Org16 code in variant Intel Hex format at 19200,n,8,1 ->

############



Download Successful!

Jumping to location $0200

3.141592653589793238462643383279502884197169399375105820974944592307816406286208
99862803482534211706798214808651328230664709384460955058223172535940812848111745
02841027019385211055596446229489549303819644288109756659334461284756482337867831
65271201909145648566923460348610454326648213393607260249141273724587006606315588
1748815209209628292540917153643678925903


This is an important milestone because it means I (we!) can test code without needing to re-synthesise from verilog and re-load the FPGA each time (3 min to re-synth, 20 sec to re-load)

It's Bruce's latest pi program - I've line-wrapped the output for the forum. It came out in no time at all, except I've got some flow control issue with the I/O so there's a second or so's pause after the first 8 digits.

The CPU is running at just under 50MHz, and with on-FPGA RAM, so there's only 4k words.

This is the hex I loaded:
Code:
;06020000004C0B5C000045
;200B5C0000200BD7000000A2016700A004A900850B5B0098004800A50B5B004800850B5B17
;200B6C00008A004800A50B5B00850B5B00A9000000850B5500A50B5B009800AA008A00201C
;200B7C000BE1000000850B5900A9000A00850B5500B5020200200BE10000001800650B5946
;200B8C0000850B55008A000A003800E9000100200BF100000095020200CA00D0FFDF00A9D8
;200B9C00000A00200BF100000085020300850B5B006800AA00A50B5B006800A40B5500C055
;200BAC00000A0090000400A000000069000000E001660090000700D000080020FFEEFFFFC1
;200BBC0000A9002E0020FFEEFFFF00980049003000850B5B006800A800A50B5B00E00166D9
;200BCC0000B0000300880088008800CA00D0FF8F004CFFEEFFFF00A9000200A204A80095D1
;200BDC00020300CA0010FFFB006000850B5700A00010000A00060B550090000300180065A9
;200BEC000B57008800D0FFF5006000850B5700A0001000A9000000060B55002A00C50B57E4
;140BFC000090000200E50B5700260B55008800D0FFF40060DB
;00000001FF


Thanks of course to Bruce, and to BitWise and Teamtempest for the assemblers, and Ross for the hexloader, and Mike for the emulator, and Arlet for the core, and to OHO for the nifty modules! (And to Garth and Electric Eye and other forum members for various input and encouragement - the core is named to reflect the forum's parentage. And VBR for starting that thread!)

Cheers
Ed


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Aug 28, 2011 1:06 pm 
Offline

Joined: Mon Mar 02, 2009 7:27 pm
Posts: 3258
Location: NC, USA
Hi BigEd, very interesting stuff!

Is the hexloader is inside the OHO module's Spartan 3 Block RAM? (ROM)
How are you transferring the HEX from your computer to the hexloader in the OHO Module?

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


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Aug 28, 2011 1:14 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10793
Location: England
Hi EE

ElEctric_EyE wrote:
Is the hexloader is inside the OHO module's Spartan 3 Block RAM? (ROM)

It's a standalone hard-coded ROM, so it doesn't consume any block RAM resources. It's 640 words.

Quote:
How are you transferring the HEX from your computer to the hexloader in the OHO Module?
I have a USB connection, which looks to the computer like a serial port. To the 65Org16 code it looks like a UART. To the FPGA it looks like a pair of i2c devices. On my photo you'll see the interface board which is easy to use and bread-board friendly.

Cheers
Ed


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Aug 28, 2011 1:43 pm 
Offline

Joined: Mon Mar 02, 2009 7:27 pm
Posts: 3258
Location: NC, USA
One last question...
You had to install windows drivers for the USBtoI2C device?
What baud-rate do you have it set at?

I am doing something similar on the dev boards by using a Microchip MCP2200. I've been reading up on it from other folks who have used it and have commented that it's error free up to a 200K baud rate. I may be looking for an alternative for V1.1...

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


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Aug 28, 2011 2:01 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10793
Location: England
ElEctric_EyE wrote:
One last question...
You had to install windows drivers for the USBtoI2C device?
What baud-rate do you have it set at?

I am doing something similar on the dev boards by using a Microchip MCP2200. I've been reading up on it from other folks who have used it and have commented that it's error free up to a 200K baud rate. I may be looking for an alternative for V1.1...
I don't remember needing to install a driver, although the docs do suggest that one should. I have used the board both from windows and linux (and we've used it from Mac too)

My present python script talks to the board at 19200, which is what the docs recommend for this board. Note that I'm not using RS232 at all, anywhere - this is i2c and USB, with serial being an emulation layer at the host computer side. It's not efficient, but it is easy and electrically forgiving, and I had all the parts.

I see the T65 project comes with a 16450 model, so putting a UART on-FPGA shouldn't be an obstacle. So, as you've done, using some USB-serial converter chip finishes the job. (In fact, the USB-i2c module I have only does that conversion, but the later USB-iss module on the same page and for the same price also converts to SPI and to serial, so that would also do the trick.)

Cheers
Ed


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Aug 28, 2011 2:41 pm 
Offline

Joined: Mon Mar 02, 2009 7:27 pm
Posts: 3258
Location: NC, USA
Ok cool, Thx.

Back to on-topic.

Is there a way to count the digits it is calculating out to?
That way we can use this as a base test to compare performance of a 65Org16.x variant core. We would just need some sort of timer to keep track. Maybe a hand held one would work?

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


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Aug 28, 2011 4:53 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10793
Location: England
Bruce's program calculates to a fixed number of digits. To turn this into a benchmark that we could time, we'd probably want to:
- change the output to just store to RAM so we're not measuring i/o speed
- loop the whole thing to run several times so it takes enough time to get an accurate reading
- light an LED at the end
- time it with a stopwatch

A 65Org16 running at 50MHz should be more than 3 times faster than a 65816 at 14MHz because it has more memory bandwidth - it's not fetching and storing in 8-bit lumps. Otherwise, the two programs are very similar. I do have a 65816 which I could in theory run on, but there are lots of other interesting things to do.

Cheers
Ed


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

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: