6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Sun May 05, 2024 3:06 am

All times are UTC




Post new topic Reply to topic  [ 119 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6, 7, 8  Next
Author Message
PostPosted: Mon Sep 23, 2013 4:58 pm 
Offline
User avatar

Joined: Sat Sep 29, 2012 10:15 pm
Posts: 899
The subject really is a can of worms. So here is my problem with the whole thing. Imagine a conversation with a really smart young person:

-Hey son! Check out my cool 6502 system, made from actual chips!
-Hmm. Kind of cool. (Watches me for 15 minutes as I debug and flash ROMs). See you later, dad.
or

-Hey son, Check out my cool 6502 system! It's an AVR chip emulating a 6502!
-Why not just run AVR code at 10 time the speed?
-But 6502 is really cool, I grew up with it!
-AVR seems much cooler, with all the registers and all that IO...

or

-Hey son! Check out my cool 6502 system. It's an FPGA running an actual 6502 configuration at 45MHz!
-But I read that these FPGA could fit a 32-bit system running Linux at a higher speed.
-Yeah, but...

Now in reality it's not likely that your son is that well informed, and hopefully loves you enough to sit with you through some kind of 'demo'. I am sorry to say that you need instant gratification here - that's probably why Arduino is doing so well. My toolchain right now is something that only a masochist can put up with.

I guess the thing to do is not worry so much about what kind of a 6502 system we have, but what the user experience is for:

- Loading off-the shelf apps - this better be really easy!
- Building small example apps - this better be really easy too!
- Creating your own code - may be harder but not much. We will lose people here, so this board can be a support mechanism.

I hate to say it because I am somewhat of a purist, but Daryl's avr solution is certainly the most cost-effective way to provide a 6502 experience. However my imaginary son has a point.

_________________
In theory, there is no difference between theory and practice. In practice, there is. ...Jan van de Snepscheut


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 5:09 pm 
Offline
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10797
Location: England
The advantages which spring to mind of a 6502-flavour kit are
- 6502 machine code is moderately easy to write - the programmer's model is simple. This give insight into the lowest level that a programmer can see.
- hooking up devices to the bus is moderately straightforward. This teaches buses and address decoding
- a computer can be simple enough to breadboard and you can see what each chip is for. This is systems design.
- hooking up devices to a parallel port is straightforward and rewarding - your code causes effects in the real world

Not all of these apply to all the models being discussed...


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 6:40 pm 
Offline

Joined: Thu Mar 03, 2011 5:56 pm
Posts: 277
enso wrote:
Here is a brief analysis of a 3 different options.

1) WDC 65C02, RAM, ROM, discrete logic IO decoder.
2) WDC 65C02, maybe RAM, 'magic chip'
3) FPGA



There's one more:

1.5) WDC 65C134 or 65C265, with some sort of interface chips for RS-232 or USB. This gives you a small machine-code monitor (4K or 8K), 192 or 576 bytes of RAM and various I/O and timer functionality. Using this as a base, you can add RAM, ROM and I/O and enable them in favour of the internal resources. This makes it possible to start with a single-chip system, add RAM and possibly a flash EPROM socket. So, starting with a single chip and a minimal amount of supporting components (oscillator, RS-232 buffers, discrete components, ...) you can incrementally build a more complex 65Cxxx system.

I'm not sure how much sense this makes if the bigger system is your immediate goal, but for learning about the architecture of a 65Cxxx system, I think this might be useful.

Caveat: I have not studied the 65C134/65C265 datasheets in detail.


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 6:49 pm 
Offline

Joined: Sat Dec 13, 2003 3:37 pm
Posts: 1004
enso wrote:
- Loading off-the shelf apps - this better be really easy!
- Building small example apps - this better be really easy too!
- Creating your own code - may be harder but not much. We will lose people here, so this board can be a support mechanism.

So, how about something like this then.

An authentic, BDD approved, Garth Wilson circuit design. So, we're classic 6502, discrete logic, etc.

The design has an expansion header. And the design has an EEROM. (I don't know if EEROMs and EPROM could be pin compatible, I'm assuming they can't).

So, the EEROM can be programmed using an external programmer.

But, as an optional feature, there is a small card that clicks on the header, and it provides a serial/USB connector to a host computer to allow it to program the EEROM in place. This is some dedicated microcontroller/SoC. So, the download/update experience can be as suggested, but when you yank the card off, you're back to a generic 6502 based system, that's none the wiser.

There may need to be some extra logic to give the add on card better access to the ROM. This auxiliary card could even BE an Raspberry Pi.

It can be a host to the board, offer all the dev tools, etc. It's $25 (plus shipping and handling, not a food, do not eat, your mileage may very, not available in Iran) for crying out loud.

So you have a 6502 kit, a header for the R-Pi, a header for random 6502 expansion stuff, add keyboard and monitor. Best of both worlds.

The R-Pi can later act as the "ultimate peripheral" if you want for some things (cheap graphics), or simply a host. Or it can drive a separate ROM programmer if you want to detach the board completely. Lots of flexibility here, and it doesn't ruin the "spirit" of it any more than a Wyse 50 does, frankly.


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 7:11 pm 
Offline
User avatar

Joined: Sat Sep 29, 2012 10:15 pm
Posts: 899
65C134 appears to have a mask-programmed ROM. That is you would have to have WDC create a mask which generally means you have to order tens of thousands of these at once and possibly pay upfront programming costs.

_________________
In theory, there is no difference between theory and practice. In practice, there is. ...Jan van de Snepscheut


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 7:28 pm 
Offline
User avatar

Joined: Sat Sep 29, 2012 10:15 pm
Posts: 899
whartung wrote:
...It can be a host to the board, offer all the dev tools, etc. It's $25 (plus shipping and handling, not a food, do not eat, your mileage may very, not available in Iran) for crying out loud.

whartung, your idea could work.

(Devil's Advocate Section)
However, for $25 you can have my CHOCHI board, which is infinitely more flexible and can be configured exactly as what you describe. Or as a Picoblaze or anything else that fits.

When pre-configured correctly, you can expand it in very much the same fashion as a hard 6502 system (although it's easier to do it inside the FPGA). It's not likely someone will desolder the EEPROM or the IO chip anyway, so does it really matter? Adding LEDs and IO gizmos to a pin header is all the same.

And user experience can be identical (CHOCHI would have to be slowed down - it runs at 45MHz).

Or, take Daryl's avr system. You can run FIG-FORTH on it, just like on any other system. It's on a separate board/chip, so it won't crash when you turn on the laserprinter (like it may on a PC-based emulator) - so you will get the 'separate computer' experience. And for under $10 you can't beat the price.

I am not trying to be argumentative, but it is good to question the motives here. For me:
- A real 6502/65C02 experience;
- No emulation on PC/Pi - it should never stumble due to multitasking;
- Emulation on-chip is actually not too bad;
- Easy software development;
- Possible to reconfigure after sale (from experience - it's nice to be able to fix an SPI port problem without having to ship boards back and forth across the world)

So I find myself being heavily biased toward FPGAs and surprisingly tolerant of Daryl's on-chip emulation. The real hardware solution is tempting, but it is a false temptation, I believe (not that there is anything wrong with it). To me, with my personal experience, the hard 6502 system is extremely sexy and reminds me of being young and excited about the future of computers. Does the shape of the chip matter to a newcomer, especially a kid? No, it's all about the experience.

_________________
In theory, there is no difference between theory and practice. In practice, there is. ...Jan van de Snepscheut


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 7:54 pm 
Offline

Joined: Thu Mar 03, 2011 5:56 pm
Posts: 277
enso wrote:
65C134 appears to have a mask-programmed ROM. That is you would have to have WDC create a mask which generally means you have to order tens of thousands of these at once and possibly pay upfront programming costs.

Yes, it is mask-programmable, but if you don't supply your own code (and order a large amount of chips), it appears that you get a standard monitor in the ROM. See http://www.westerndesigncenter.com/wdc/datasheets/134monrom.pdf; it appears that the standard ROM includes a mechanism for downloading S-records.

I just noticed that the 65C134S has been discussed on 6502 earlier (which I guess should be no surprise): http://forum.6502.org/viewtopic.php?f=4&t=2452.


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 8:42 pm 
Offline
User avatar

Joined: Tue Nov 16, 2010 8:00 am
Posts: 2353
Location: Gouda, The Netherlands
enso wrote:
the hard 6502 system is extremely sexy and reminds me of being young and excited about the future of computers.


Exactly. But the young kids of today have a different mindset. Why would they get excited by an old relic that can't do anything, after just having watched an HD movie on their smart phone, streamed in real time over a wireless connection to the internet ?


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 9:24 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8432
Location: Southern California
On something like the smart phone, they can't do anything, unless it's a pre-canned application; and the phone does not have the I/O to control a project. The real things that young people with the brains will want to do will be somewhere between the extremes of blinking a light at watching a movie.

It bugged me a little that in the 6502 class in 1982 using AIM-65's, we were using a monitor program (which to us was a black box) to enter our own hand-assembled routines. I'm not sure the teacher could have gotten things to any lower level than that, but a few years later when I made my own, I started from scratch, and it was all mine. :mrgreen: :mrgreen:

I'm a firm believer that FPGAs should be left completely out of this, at least from the standpoint of the user having to load or update any hardware configurations for example.

Quote:
If I was designing a simple 65(C)02 board I'd opt for more RAM and a smaller boot ROM (say 4K) with a simple monitor.

A bigger ROM would be appropriate for the possibility of offering a few different ROMs having a language available immediately on boot-up, like BASIC or Forth. Newbies aren't going to be needing a lot of RAM. I'm no newbie, and my workbench computer has 32KB of ROM and only 16KB of RAM, and with the full-featured Forth in ROM, I've never needed more than a few KB of RAM for application programs except that sometimes I've wanted a lot more for data (many megabytes) where I'm gathering it at possibly tens of thousands of bytes per second.

Quote:
A 32K RAM/32K ROM split is simple from an address decoding perspective but means you need to reprogram (E)EPROMs to make full use of memory or develop your own. Given that you are probably using a more powerful PC as a terminal to the 6502 and you can easily download ROM images. Alternatively include an option for an I2C/SPI memory on the board to copy from on reset.

I do like the SPI / I²C idea. I²C could be in tiny modules using the I2C-6 connector. Daryl already has these available for sale. SPI could be in something similar.

Quote:
(I don't know if EEROMs and EPROM could be pin-compatible, I'm assuming they can't).

A board can be designed with jumper options to allow either one. This is shown in my basic computer diagram at http://wilsonminesco.com/6502primer/pot ... ml#BAS_CPU slightly below and to the left of center, JW3, although this one does not make the computer able to write to its own EEPROM while it's running like Daryl does.

Quote:
There may need to be some extra logic to give the add on card better access to the ROM. This auxiliary card could even BE an Raspberry Pi.

Again, no need, as the computer can write to its own EEPROM while running (it's just that the program to do it will have to be copied into RAM to run while the EEPROM is unavailable for a few ms at each write).

_________________
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: Mon Sep 23, 2013 9:53 pm 
Offline
User avatar

Joined: Thu May 28, 2009 9:46 pm
Posts: 8173
Location: Midwestern USA
enso wrote:
65C134 appears to have a mask-programmed ROM. That is you would have to have WDC create a mask which generally means you have to order tens of thousands of these at once and possibly pay upfront programming costs.

Ditto for the 65C256.

_________________
x86?  We ain't got no x86.  We don't NEED no stinking x86!


Top
 Profile  
Reply with quote  
PostPosted: Mon Sep 23, 2013 11:35 pm 
Offline

Joined: Sat Dec 13, 2003 3:37 pm
Posts: 1004
Ok, so how about something like this.

GW/BDD design with a supplied EEPROM monitor and a jumper/switch that lets a host computer download a new EEPROM through the available serial interface.

User must be well aware that if they "break" the EEPROM (i.e. overwrite the serial upload code), they have bricked the computer and will need to reprogram the EEPROM using a more conventional mechanism.

Next, the design will be able to use either discrete logic OR a pre-programmed CPLD (bought from the same place the pre-programmed EEPROM is) thing that replaces it.

This is done to lower complexity and component count. The CPLD holds the identical logic that could readily be done with discrete logic, it's simply easier.

The machine would then have a CPU, RAM chip, ROM chip, an ideally single chip Serial/Parallel/Timer(s) chip for I/O, a MAX-232 I guess, and either a single CPLD chip or the decode chips.

Interaction with the device is through a standard Serial line, and blinken-lighten-button-pokin-motor-spinnins are done through the I/O channels.

This lets folks make it as complicated as they want, or simpler if they want. I think the decode logic is really off-putting.


Top
 Profile  
Reply with quote  
PostPosted: Tue Sep 24, 2013 1:38 am 
Offline
User avatar

Joined: Sat Sep 29, 2012 10:15 pm
Posts: 899
That seems like closer to something that could work. Depending on how the EEPROM works... If it's like flash in modern SOCs, it is probably possible to write small 'sectors' or even individual bytes.

However, I would like to remind you that by the time all is said and done, it's not going to be super cheap. Do you think anyone would pay a premium (compared to an Arduino clone or an ARM SOC) for the privilege of working with a 6502?

_________________
In theory, there is no difference between theory and practice. In practice, there is. ...Jan van de Snepscheut


Top
 Profile  
Reply with quote  
PostPosted: Tue Sep 24, 2013 2:10 am 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8432
Location: Southern California
Flash is a special type of EEPROM which speed up the erasing and sometimes the writing by dealing with entire blocks at once to make it fast-- hence the name. Non-flash EEPROMs usually let you erase and write one byte at a time.

Since this would not be a consumer market, price may not be such a driving factor. What we could supply would have more I/O than an Arduino or a Pi, and probably more memory than an Arduino, and not have the appearance of being a toy. While I think $200 is too much, I anticipate the parts costing well under $100 including the power supply, and we would not be in this for profit, so there would not be a big mark-up. To me, the tool-up for the PCB is the big consideration, since it would be hundreds of dollars for a good board and then a very small amount per board after that. Depending on the board size, getting 100 PCBs may not be much more expensive than getting one; so then you're left wondering how long it will take to recover your investment. (On my 4Mx8 10ns 5V SRAM memory modules, the tool-up was something like $300, and then each board was something like fifty cents after that. I still need to sell a few more complete modules to break even. I can buy the SRAM ICs in smaller quantities, so I don't have so much money tied up in inventory there.) I don't expect the trainer to be a big market at all; and depending on what Daryl has in stock, it might be good to add a board with keypad and LCD.

_________________
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 Sep 24, 2013 4:15 am 
Offline

Joined: Sat Dec 13, 2003 3:37 pm
Posts: 1004
enso wrote:
However, I would like to remind you that by the time all is said and done, it's not going to be super cheap. Do you think anyone would pay a premium (compared to an Arduino clone or an ARM SOC) for the privilege of working with a 6502?

At the level and ubiquity that computing is at today, why any but the tiniest minority of users even care about the underlying processor is beyond me. The efforts of things like Chrome OS and Firefox OS are striving to make the entire platform choice (processor, OS, runtime) pretty much agnostic. They've moved far beyond caring what processor they run on.

I don't think the R-Pi producers chose the ARM because they had some affinity for the architecture, rather it was likely a concordance of price, capability, availability, and after market support (drivers, tool chains, etc.).

I find the ARM machines marvels of functionality. From the R-Pi, to my cell phone, to the pack of gum sized devices running Linux, a browser window, and a Python (or is it Ruby? Does it matter?) server driving our big screen TVs at the office with projects, issues, and build stats.

So, I think the market for a project like this is someone that wants to get there hands dirty, at least a little bit. They don't want the "one chip" experience. My question is what could this offer that the Micro KIM doesn't. And if folks at all interested in this kind of thing are not choosing the KIM, why not? Marketing? Cost? Complexity? Functionality?

The Arduinos et al are the center of an ad hoc electronics Lego set, where stand alone automation is the "fun" part, not the CPU. Plug and play lights, sensors and motors for kinetic sculpture, robots, and science fairs. Not ground plane ring, circuit noise, and lead wire capacitance. These folks are not engineers. They're certainly not electronic engineers, more likely they're mechanical engineers and computer scientists, if anything.

The computer controller is the means.

I'd like to see the circuit discussed here, with the downloading monitor and EEPROM, tested on a breadboard. I think that would be an interesting kit. I think I could pull the trigger on a zip bag full of parts that takes a generic wall wart for a power supply, a usb-serial cable, and a couple of breadboards. Not really interested in getting prom programmers and such to make it work. If I like the results of that, maybe I'll solder it up on to a PC board.

Add in a step by step "build this, test that" incremental assembly approach, and I think that could be an interesting month of weekends putting it together, learning something interesting, and making it do something before it ends up in a box somewhere.

I had thought of getting a Micro KIM and eventually turning it in to a likely so-so accurate digital clock for the office. Day, date, calendar stuff, push a button, highlight something on the LEDs...kinda neat. But I'd need to reburn the EPROM for that, which means more tooling, more equipment, etc.

The game I think is to present enough to see if someone is interested at all, with as little of an investment as practical. Not just in the parts themselves, but the infrastructure. Mostly tools. Tools they may likely never use again if they're not interesting. If they find it doesn't take. That investment, to me, is a deterrent for taking the next step. I know me too well, and I have enough languishing things, "I guess that's not that interesting", hanging around, that I don't need more.

An Arduino needs a usb cable. That's pretty compelling. Those I have.


Top
 Profile  
Reply with quote  
PostPosted: Tue Sep 24, 2013 4:57 am 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8432
Location: Southern California
whartung wrote:
So, I think the market for a project like this is someone that wants to get there hands dirty, at least a little bit. They don't want the "one chip" experience. My question is what could this offer that the Micro KIM doesn't. And if folks at all interested in this kind of thing are not choosing the KIM, why not? Marketing? Cost? Complexity? Functionality?

Part of it is just awareness. I alluded earlier to reluctance to come up with a new board if suitable ones might already be out there. I had kind of forgotten about the Micro KIM, so I went on a search for our recent topic about it to review what it had. Although I haven't found the topic I'm thinking of yet, I did find the "SBC kit for education" topic at viewtopic.php?f=1&t=2283. It's 7 pages--kind of long--but we keep the archives for a reason, and I intend to read it all again before wasting too many more words. I think the micro KIM topic I was looking for had something about avoiding a copyright infringement.

Edit: Thanks to DrJeffyl for finding it: it was the SYM, not the KIM, at viewtopic.php?f=3&t=2445&start=16. A quick web search for "Micro KIM" turned up as the first result http://www.brielcomputers.com/wordpress/?cat=24, where it says, "With a projected selling price of $99 the micro-KIM is one of the most affordable 8 bit computer kits available today. As a matter of fact, the micro-KIM was designed around the student market in an effort to offer students and schools a low-cost 8 bit CPU trainer."

Image

It does however use RIOT ICs which are no longer made, and has very little memory. I guess the point really was to bring back the original 1975 KIM computer.

_________________
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  [ 119 posts ]  Go to page Previous  1, 2, 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: