6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Thu Oct 03, 2024 10:17 pm

All times are UTC




Post new topic Reply to topic  [ 117 posts ]  Go to page Previous  1 ... 3, 4, 5, 6, 7, 8  Next
Author Message
 Post subject: Re: Stand-Alone Devices
PostPosted: Wed Aug 23, 2017 1:09 am 
Offline

Joined: Mon Jan 11, 2016 3:32 am
Posts: 34
Location: Rochester, NY 14626
EugeneNine,

It's for exchanging data with flash drives.

_________________
Jim Adrian

https://www.futurebeacon.com/jamesadrian.htm


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Wed Aug 23, 2017 4:59 pm 
Offline

Joined: Sat Jun 04, 2016 10:22 pm
Posts: 483
Location: Australia
jamesadrian wrote:
There are several, if not many, projects that can profitably use the 6502, slow as it it.
I'm not disputing that. I've got a project that uses/will use a 65c02, and WDC is still afloat, so it's clearly profitable. And I'd be inclined to say that it's fairly quick for its clock speed. It's just that the discrete chips only go up to 14MHz, and more modern processors can go into the GHz range.

jamesadrian wrote:
I am interested in the ones that involve a USB port. If the 6502 were a tenth as fast as it is, it could still run a USB port.
I know of a way that the 6502 can act as a USB host; the CH376 can do that(with FAT support out of the box, and it appears that it might possibly have multiple interface options. I haven't been able to find any in-depth information(particularly an actual datasheet, or the company that makes them) by googling a bit, so it might be iffy.
This looks like it's meant to be an answer to my request for proof. This is not proof. This is a statement without proof. And I wasn't actually asking for the 6502's ability with USB. I was asking about the 6502's ability regarding your intended application. I didn't phrase my question all that well. Speaking of which, what is your intended application?
jamesadrian wrote:
We have a different idea about the hardware design.
This sounds interesting. Please, tell me more.
jamesadrian wrote:
I am looking for people who like programming in 6502 assembly language, and also some who understand the USB port. This site is called 6502.org. To me, it makes sense to try to find people here.
Ok... That seems to be saying that you're looking to recruit a team. If that's the case, why didn't you say so plainly?

jamesadrian wrote:
If nobody thinks it is sane to use a 6502 for a USB port device, then I have had another question: Would you like the device better if it used a faster processor and a cross assembler for 6502 programmers?
Cross-assembler? I don't know quite what you're driving at here. A cross-assembler is a program running on one type of processor, that takes in assembly code for a different type of processor, and produces machine code for that second type of processor. What you seem to be describing is something that takes in assembly code for one type of processor and produces machine code for a different type of processor. I'm no expert, but that doesn't seem feasible unless there's an emulator involved.

Mind you, I'm not saying you shouldn't pursue your idea; it's your hobby. Nor am I saying that you should go away; I daresay that you'll be able to get help here. But I don't think you'll get any recruits for a team here, assuming that's what you're trying to do.
My recommendation is this: If we've given you enough information to get started, start designing and prototyping your device.


Last edited by DerTrueForce on Wed Aug 23, 2017 6:26 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Wed Aug 23, 2017 9:44 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8521
Location: Southern California
The MAX3421 is a USB controller, interfaced by SPI.
https://www.maximintegrated.com/en/prod ... 3421E.html
http://www.mouser.com/Search/Refine.asp ... d=MAX3421E
data sheet: http://www.mouser.com/ds/2/256/MAX3421E-103260.pdf
But if you just want to do the little flash memory cards, I expect SD card would be much easier to interface to than USB thumb drives.

_________________
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  
 Post subject: Re: Stand-Alone Devices
PostPosted: Wed Aug 23, 2017 10:46 pm 
Offline

Joined: Sat Dec 13, 2003 3:37 pm
Posts: 1004
If you're looking for ubiquitous interoperability, the USB thumb drive is the way to go. Otherwise, yea, you can drive an SD card pretty much directly (though it seems that some cards behave better than others, which is curious, at least when interfaced vis SPI -- but perhaps not using another method).

That CH376 probably has a CPU several times faster than the 6502 buried in it, since it claims to support up to the 12MBs rate, is also mentions it supports SPI up to 24MHz.

I honestly don't know much about USB interfacing. I assume that MAX chip handles the bulk of the details and the device will basically be a passive participant, even with a slow partner like a 6502? Would be interesting to see some block read/write code that talks to a USB drive using that chip. (The file system itself would come later).

All that said, the CH376 chip is pretty black boxy magical in what it does. Offers a lot of utility in that space I think. Shame it only seems to be available on breakout boards off eBay.


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Thu Aug 24, 2017 2:10 am 
Offline

Joined: Fri Apr 15, 2016 1:03 am
Posts: 139
MPJA has a board with the CH376 (and some documentation).
The CH376 is from wch-ic.com (or wch.cn ).

jamesadrian: more questions...

On the CH376 interface to USB or SD storage:
Is FAT12 & FAT16 & FAT32 (but not NTFS or anything Linux) OK?
Is a maximum file size of 1GB OK?

On the video display:
What did you have in mind? 64x16 character text? 640x480 monochrome graphics? something else?

No network connection?

Maybe 32KB flash memory?

Maybe 32KB RAM?

Maybe a 65816 CPU?



Or, starting from one of these, what would you change?
W65C265SXB board - wdc65xx.com/boards/w65c265sxb-engineering-development-system
BDDs POC board
Raspberry PI


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Thu Aug 24, 2017 9:12 pm 
Offline

Joined: Mon Jan 11, 2016 3:32 am
Posts: 34
Location: Rochester, NY 14626
leepivonka,

I think that the 65816 is an excellent suggetion.

_________________
Jim Adrian

https://www.futurebeacon.com/jamesadrian.htm


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Fri Aug 25, 2017 2:35 pm 
Offline

Joined: Mon Jan 11, 2016 3:32 am
Posts: 34
Location: Rochester, NY 14626
Does anybody think that a 65816 could not use a USB port for mass storage?

_________________
Jim Adrian

https://www.futurebeacon.com/jamesadrian.htm


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Fri Aug 25, 2017 2:57 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10943
Location: England
I suspect it's mostly a question of how much work it would be, and partly a question of how much memory would be needed. USB is a complex protocol stack, normally coded in C, and there's something of a shortage of quality C compilers for 65xx family. This repo has 12k lines of C code. The standards document for USB has 650 pages, apparently.


Last edited by BigEd on Fri Aug 25, 2017 5:23 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Fri Aug 25, 2017 4:46 pm 
Offline

Joined: Sat Dec 13, 2003 3:37 pm
Posts: 1004
USB is certainly complicated, but that code doesn't look too awful. And you can be selective as to what parts of that code base you want. If you want just the MSC part for mass storage (and that's simply block I/O, not a file system), then I bet that MSC and the core driver code compiles down to < 4K of actual code.

4K is still a lot for a device drive on an 8-Bit machine, but c'est la vie. That's the protocol's fault, not so much the CPUs.

But this code is just the protocol, I'm guessing would need something like that MAX3421 chip for the actual interfacing. You'd also need to code to handle the file system aspects.

So, there's no reason that a 6502 can't drive a USB based peripheral. I don't see anything to suggest that there's a minimum performance requirement (so you should be able to talk to a modern USB device from a 1MHz 6502 -- it'll just be slow).

The 65816 would be "better" solely for the fact that it can address more memory, so having a large software stack to drive a complicated protocol would be less impactful to the overall resource footprint. (4K from 64K is a lot more heavy handed than 4K from 16MB.) Plus you could have denser code on the '816.


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Fri Aug 25, 2017 6:12 pm 
Offline

Joined: Tue Jun 08, 2004 11:51 pm
Posts: 213
Most damage to small business has nothing to do with hacking messages.
It is hacking the OS, like Windows, that does the most damage.
There is little effort to hack email from "Joe's Donuts" because no
one cares what email Joe sends.
There is major efforts to hack mail by "Bank of America".
The best way to send a key is to split it into several pieces and use
several trusted transporters to send the parts of the key.
Even if several parts of the key are compromised in transport, the remaining pieces
are sufficient to ensure secure communications.
The advantage of using the current quantum entanglement methods of sending keys
is that it is impossible to examine the keys without being detected.


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Fri Aug 25, 2017 9:39 pm 
Offline

Joined: Mon Jan 11, 2016 3:32 am
Posts: 34
Location: Rochester, NY 14626
Can anybody here design and specify to a foundry a peripheral controller for a 65816 that will access a one terabyte flash drive?

_________________
Jim Adrian

https://www.futurebeacon.com/jamesadrian.htm


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Fri Aug 25, 2017 10:29 pm 
Offline

Joined: Sat Dec 13, 2003 3:37 pm
Posts: 1004
Could you be less elusive? You seem to be posting what you think are solutions, rather than stating problems. If you state the problem and end goal, the discussion is much more fruitful.

Modern USB will easily support that size of drive. Are you talking about USB? There are other interfaces.

As to your question, that MAX3421 chip, and that source code that was linked to, should easily be able to access a 1TB flash drive over USB, as it seems 1TB is well within the limits of USB 2.0 MSC, which is limited to 2TB.

is there any good reason to reinvent this wheel?


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Fri Aug 25, 2017 11:22 pm 
Offline

Joined: Mon Jan 11, 2016 3:32 am
Posts: 34
Location: Rochester, NY 14626
whartung,

My often repeated goal is to enjoy the 6502 instruction set in a device that has a USB port.

Can we get there from here?

_________________
Jim Adrian

https://www.futurebeacon.com/jamesadrian.htm


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Fri Aug 25, 2017 11:41 pm 
Offline

Joined: Mon Jan 11, 2016 3:32 am
Posts: 34
Location: Rochester, NY 14626
Here is one of many products not yet on the market that could be done with a 6502 device having a USB port:

https://www.youtube.com/watch?v=dGUD58gp6Fk

_________________
Jim Adrian

https://www.futurebeacon.com/jamesadrian.htm


Top
 Profile  
Reply with quote  
 Post subject: Re: Stand-Alone Devices
PostPosted: Sat Aug 26, 2017 1:10 am 
Offline

Joined: Sat Dec 13, 2003 3:37 pm
Posts: 1004
jamesadrian wrote:
whartung,

My often repeated goal is to enjoy the 6502 instruction set in a device that has a USB port.

Can we get there from here?


Yup. A 6502 and that MAX3421 chip will fill this requirement. Looks like a neat little chip.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 117 posts ]  Go to page Previous  1 ... 3, 4, 5, 6, 7, 8  Next

All times are UTC


Who is online

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