65VM02

Topics relating to PALs, CPLDs, FPGAs, and other PLDs used for the support or creation of 65-family processors, both hardware and HDL.
User avatar
Rob Finch
Posts: 465
Joined: 29 Dec 2002
Location: Canada
Contact:

Re: 65VM02

Post by Rob Finch »

Just following along the 65VM02.

If a goal is to be a byte-code interpreter engine I think a 128kB design would be somewhat limiting. I think if it was possible to use a 24 bit address space that would be good. This would mainly affect the IP instructions. Several small JVM’s are larger than 128kB. Of course this might mean supporting a long address mode (‘C816 compatible).

This bit my two cents on interrupt handling. – Use a cause code. An interrupt cause code register is present in the RISC-V and other newer designs. It moves vectoring from a hardware task into the software one where more flexibility is available. The cause code could be present on a dedicated input bus to the core.
User avatar
BigDumbDinosaur
Posts: 9428
Joined: 28 May 2009
Location: Midwestern USA (JB Pritzker’s dystopia)
Contact:

Re: 65VM02

Post by BigDumbDinosaur »

Hugh Aguilar wrote:
The only reason you wouldn't want INC and DEC to affect the carry flag, is that you already have something in the carry flag and you don't want the carry flag to get clobbered by the INC and DEC. I can't think of any case in which this would be true however. That is why I say that it is a design flaw in the 65C02 that INC and DEC don't affect the carry flag
This statement indicates that your hands-on experience with the 6502 is limited. Cases which an earlier instruction affected carry and one or more intermediate instructions have been executed before the state of carry is evaluated are more common than you think. I have several such sequences in the firmware of POC V1, including one in the M/L monitor where an entered assembler mnemonic is compared to the built-in mnemonic list. For an increment or decrement to tamper with carry would automatically make your design 6502-incompatible in my world.
x86?  We ain't got no x86.  We don't NEED no stinking x86!
Hugh Aguilar
Posts: 158
Joined: 03 Jun 2016

Re: 65VM02

Post by Hugh Aguilar »

GARTHWILSON wrote:
Quote:
they have since upgraded to the PIC18
I would say that in many senses, that's just an update, not an upgrade. It does have nice I/O and processor-support features on board, and it has a lot of kludges to address deficiencies in the PIC16's, but it still has problems. At least it's more suitable for HLL compilers.
The PIC18 has all of its memory internal to the chip, so it is hella fast. This also makes it inexpensive. The major limitation of the PIC18 (and PIC24, etc.) is that they don't support external memory, so if the internal RAM isn't enough, then you are out of luck.

The Dallas 80c320 had 2KB of RAM internal to the chip (plus the 256 bytes of low memory). The '320 was really the standard of the early 1990s --- the 65c02, with external memory, was considered to be obsolete.

With my 65VM02 I'm expecting to have all the memory internal to the chip.
User avatar
BigDumbDinosaur
Posts: 9428
Joined: 28 May 2009
Location: Midwestern USA (JB Pritzker’s dystopia)
Contact:

Re: 65VM02

Post by BigDumbDinosaur »

Hugh Aguilar wrote:
The '320 was really the standard of the early 1990s --- the 65c02, with external memory, was considered to be obsolete.
Considered to be obsolete by whom? Millions are produced every year according to WDC (a claim that is indirectly supported by their approximate $10 million US annual sales made predominantly from licensing royalties—at an estimated 5 cents royalty per chip produced, WDC's volume claims are reasonable). Where are all those obsolete 65C02s going? Clearly someone is using them, else the tree-huggers would be up in arms about too much silicon going into landfills.

BTW, Mouser has a total of 582 pieces of the 65C02 in stock as I write, that is, ready for immediate shipment. Most are PDIP40 and PLCC44. If the 65C02 were truly obsolete, none of that inventory would be there, especially the recently-stocked QFP44 packages (38 on hand).

Also, I see Mouser has plenty of that other obsolete WDC processor in stock as well, also in QFP44. :D Plus they have nearly 2000 pieces of the W65C22S VIA on hand, in PDIP and PLCC.

All-in-all, that's quite a bit of inventory to keep around for old, creaky pieces of silicon that were considered obsolete by someone 25 years ago. :shock:
x86?  We ain't got no x86.  We don't NEED no stinking x86!
Hugh Aguilar
Posts: 158
Joined: 03 Jun 2016

Re: 65VM02

Post by Hugh Aguilar »

BigDumbDinosaur wrote:
Hugh Aguilar wrote:
The '320 was really the standard of the early 1990s --- the 65c02, with external memory, was considered to be obsolete.
Considered to be obsolete by whom? Millions are produced every year according to WDC (a claim that is indirectly supported by their approximate $10 million US annual sales made predominantly from licensing royalties—at an estimated 5 cents royalty per chip produced, WDC's volume claims are reasonable). Where are all those obsolete 65C02s going?
Most likely there are products that were designed in the 1980s with a 65c02 inside of them --- they are still being sold today.

There hasn't been any new work done with the 65c02 since the early 1990s --- the same is true of Forth programming --- no jobs; it is just a hobby.
User avatar
BigDumbDinosaur
Posts: 9428
Joined: 28 May 2009
Location: Midwestern USA (JB Pritzker’s dystopia)
Contact:

Re: 65VM02

Post by BigDumbDinosaur »

Hugh Aguilar wrote:
Most likely there are products that were designed in the 1980s with a 65c02 inside of them --- they are still being sold today.
Possibly. Many non-consumer embedded applications are not designed with automatic obsolescence in mind. A product only becomes obsolete when no one uses it. There are so many applications for small, low-power, eight bit processors they will be around for a long time.
Quote:
There hasn't been any new work done with the 65c02 since the early 1990s --- the same is true of Forth programming --- no jobs; it is just a hobby.
I'd agree with Forth. It's the ultimate in niche programming environments. The only users of Forth I know of are right here.

In the case of the 65C02, there is new work being done with it all the time—you mostly can't see it. Do you really think that every digital gadget in production right now is powered by an ARM or PIC? Think again. Those extra el-cheapo cell phones that some 10 dollar a month providers give away are powered by ASICs with a 65C02 core. That's why the phone is so cheap. At a royalty to WDC of 5 cents or so per unit shipped, the manufacturer can practically afford to give away the phone.

How about those cute, little digital picture frames you sometimes see on someone's desk? Many of those are 6502-powered. It doesn't take a lot to occasionally plaster an image on an LCD display, especially one that has built-in intelligence. My doctor has one in his office with pictures of his family, which I helped him set up when he got it about a year ago. The instructions that came with it include a copyright acknowledgement to Western Design Center. You know what that means, right?
x86?  We ain't got no x86.  We don't NEED no stinking x86!
User avatar
GARTHWILSON
Forum Moderator
Posts: 8775
Joined: 30 Aug 2002
Location: Southern California
Contact:

Re: 65VM02

Post by GARTHWILSON »

Quote:
the same is true of Forth programming --- no jobs; it is just a hobby.
Forth, Inc. might have a different view. Forth is their bread & butter. You might like to sign up for EuroForth 2017. (At €337.00 though, I kind of doubt you'll find many hobbyists.)
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?
User avatar
Arlet
Posts: 2353
Joined: 16 Nov 2010
Location: Gouda, The Netherlands
Contact:

Re: 65VM02

Post by Arlet »

BigDumbDinosaur wrote:
In the case of the 65C02, there is new work being done with it all the time—you mostly can't see it. Do you really think that every digital gadget in production right now is powered by an ARM or PIC? Think again. Those extra el-cheapo cell phones that some 10 dollar a month providers give away are powered by ASICs with a 65C02 core. That's why the phone is so cheap. At a royalty to WDC of 5 cents or so per unit shipped, the manufacturer can practically afford to give away the phone.
ARM royalties are only 1% of the chip, so easily cheaper. And the STM8 is even less than that. The STM8 is very popular in cheapo gadgets right now.
User avatar
BigDumbDinosaur
Posts: 9428
Joined: 28 May 2009
Location: Midwestern USA (JB Pritzker’s dystopia)
Contact:

Re: 65VM02

Post by BigDumbDinosaur »

Arlet wrote:
ARM royalties are only 1% of the chip, so easily cheaper. And the STM8 is even less than that. The STM8 is very popular in cheapo gadgets right now.
Yet WDC keeps chugging along. How do you explain it?
x86?  We ain't got no x86.  We don't NEED no stinking x86!
User avatar
Arlet
Posts: 2353
Joined: 16 Nov 2010
Location: Gouda, The Netherlands
Contact:

Re: 65VM02

Post by Arlet »

BigDumbDinosaur wrote:
Yet WDC keeps chugging along. How do you explain it?
The STM8 growth is fairly recent. They went from 1 billion units in 2014 to 2 billion in 2016, representing 12% of the microcontroller market. With such a big market, WDC only needs 0.01% to keep the lights on. It's a small outfit, and they don't seem to be spending money on development.
Hugh Aguilar
Posts: 158
Joined: 03 Jun 2016

Re: 65VM02

Post by Hugh Aguilar »

BigDumbDinosaur wrote:
Hugh Aguilar wrote:
Most likely there are products that were designed in the 1980s with a 65c02 inside of them --- they are still being sold today.
Possibly. Many non-consumer embedded applications are not designed with automatic obsolescence in mind. A product only becomes obsolete when no one uses it. There are so many applications for small, low-power, eight bit processors they will be around for a long time.
Well, the 8051 has been going strong for decades, and will continue for a long time. Intel succeeded with this mostly because they found a reasonably good design and then stuck with it. Motorola failed because they kept changing their design and abandoning their old designs. When the 6808 came out, the 6805 users got told to upgrade. When the 6812 came out, the 6809 and 6811 users got told to upgrade. Nobody wants to upgrade. They have a product that sells, and if it doesn't need a more powerful processor, then they want to just keep selling their product without any upgrade.

WDC seems to be doing the same thing with their 65c02. They don't change the design. They just continue supporting their existing customers, and they don't worry about the fact that new customers are pretty rare.

MicroChip most likely makes the majority of their money on the PIC16, although the PIC18, PIC24 and PIC32 are a lot more powerful.

All of these processors that we are talking about are 8-bit, and they have a small amount of memory (maybe 512 bytes at the most, but usually only 128 bytes which is what the basic 8051 has).

Also, a lot of these processors are PLCs that are programmed with ladder-diagrams. This is why the 8051 has those 256 1-bit variables (a 32-byte block in low memory). This is also why the W65c02 has those instructions for accessing 1-bit variables. A PLC is basically a state-machine in a paced-loop. A lot of factory equipment use PLCs. They have the product moving around in a carousel or on an assembly-line, and at every stage the product gets something done to it, and then it falls into the bin as a completed product.

Anyway, this is not what the 65VM02 is for. I'm expecting it to have 128KB of memory and run a high-level language (Forth for me, although it should support any language).
These would be larger applications than those done on an 8-bit or 16-bit processor with less than 64KB of memory.
These would be smaller applications than those done on a 32-bit processor, which require megabytes of memory and high-speed.
The 65VM02 would be a niche processor --- not too small and not too big.
User avatar
GARTHWILSON
Forum Moderator
Posts: 8775
Joined: 30 Aug 2002
Location: Southern California
Contact:

Re: 65VM02

Post by GARTHWILSON »

Arlet wrote:
ARM royalties are only 1% of the chip, so easily cheaper. And the STM8 is even less than that. The STM8 is very popular in cheapo gadgets right now.
Just musing: I don't how much it really costs, but for the sake of discussion, let's say it's 25 cents for the ARM part of an ASIC and 10 for the '02 part of one, and WDC wants—let's go ten times as much—10% instead of 1%. Now the ARM costs 25.25¢, and the '02 costs 11¢.

This article might have another key though. It says,
"The upfront license fee depends on the complexity of the design you’re licensing. An older ARM11 will have a lower up front fee than a Cortex A57. The upfront fee generally ranges from $1M - $10M, although there are options lower or higher than that"
(emphasis added). That might be one reason the '02 becomes more attractive. The up-front cost of the '02 is a fraction of that, only a few thousand IIRC.

The up-front cost does not have to be repeated though for every new product you make after the first one; so it's interesting that Nuvoton uses both in their ICs, ARM and '02. Their N539TP340(OTP) high-quality-speech synthesizer and graphic LCD driver uses the '02.

Good point Hugh about the 8051 and others.

I think the '02 is still economically viable in the market today, but I don't particularly need it to be, for myself. If WDC announced they were shutting down, I would buy a lifetime supply for myself and just enjoy it. This is an interest group, and I got into electronics for fun, not money. Microprocessors is part of my electronics interest, to control and analyze the analog which is the other part. If microprocessors were an end in themselves, my approach and position would be different. I like what you're doing, Hugh (and others here exploring their own variations). I can't dedicate enough time to it to do it myself.
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?
User avatar
Arlet
Posts: 2353
Joined: 16 Nov 2010
Location: Gouda, The Netherlands
Contact:

Re: 65VM02

Post by Arlet »

Quote:
WDC wants—let's go ten times as much—10% instead of 1%
BDD claims that WDC makes $10 million, selling millions of designs. Something doesn't compute, because at 1 cent/piece they would have to sell a billion of them, and I'm sure they would love to advertise that number. And to be honest, I think 1 cent is too expensive, especially in the last couple of years, where there are so many alternatives, including free ones.
Hugh Aguilar
Posts: 158
Joined: 03 Jun 2016

Re: 65VM02

Post by Hugh Aguilar »

GARTHWILSON wrote:
Quote:
the same is true of Forth programming --- no jobs; it is just a hobby.
Forth, Inc. might have a different view. Forth is their bread & butter.
You seem to be very concerned that my 65VM02 will steal the bread and butter from Forth Inc.'s table.

This is your forum. If you want to support Forth Inc., then just say so and I will never post another message on your forum again. You do what you think is best.
Tor
Posts: 597
Joined: 10 Apr 2011
Location: Norway/Japan

Re: 65VM02

Post by Tor »

Hugh Aguilar wrote:
GARTHWILSON wrote:
Quote:
the same is true of Forth programming --- no jobs; it is just a hobby.
Forth, Inc. might have a different view. Forth is their bread & butter.
You seem to be very concerned that my 65VM02 will steal the bread and butter from Forth Inc.'s table.

This is your forum. If you want to support Forth Inc., then just say so and I will never post another message on your forum again. You do what you think is best.
? That's not what Garth meant at all (as he'll comment when his timezone comes around again) - your 65VM02 is extremely welcome on this forum.
Post Reply