forum

You got a 6502 processor

posted
Total Posts
22
Topic Starter
McEndu

Picture by Morkork, from Wikimedia Commons

A mysterious man gifted you a 6502 processor. It is one of the few legendary processors that dominated the 8-bit age, powering Commodore and Apple computers at its time, yet you feel that its power is lacking.

You can add components, like a motherboard, to the processor, and construct a computer that just works (TM). Or maybe an arcade machine. Possibly make it the heart of a nuke. While you can't do everything, there are still a lot of things that can be done.
Stomiks
Is this an interactable thread?
HoosierTransfer
Topic Starter
McEndu

Stomiks wrote:

Is this an interactable thread?
yes

HoosierTransfer wrote:

do this

https://youtube.com/playlist?list=PLowKtXNTBypFbtuVMUVXNR0z1mu7dp7eH
Nice video for understanding hardware design
Stomiks

McEndu wrote:

Stomiks wrote:

Is this an interactable thread?
yes
Ok thanks
z0z
i actually have no idea on what to do with this
Topic Starter
McEndu

z0z wrote:

i actually have no idea on what to do with this
You don't need to program it. Just go on and describe what you want to program.

Assembly code are allowed, though.
Manishh
Upgrade the cpu
Topic Starter
McEndu

Manishh wrote:

Upgrade the cpu
Instructions unclear. You are gifted a 65C02. It is an iteration on 6502 that requires less power than the original, yet works largely the same.

This don't feel like an upgrade.

(65C02 is still produced to date in real life, mainly for embedded systems that do not require much computing power.)
abraker
Jokes on you I have an original Pentium processor
abraker
10       .TITLE
20       .OPT OBJ
30       *=  $8000
40 START LDA #0
50       STA $022F
60       STA $D40E
70       STA $D20E
80       SEI
90       LDA #$C0
0100     STA $C1
0110     LDY #0
0120     STY $C0
0130 L3  LDA ($C0),Y
0140     TAX 
0150     LDA #$FE
0160     AND $D301
0170     STA $D301
0180     TXA 
0190     STA ($C0),Y
0200     LDA #$01
0210     ORA $D301
0220     STA $D301
0230     INY
0240     CPY #0
0250     BNE L3
0260 NOK INC $C1
0270     CLC 
0280     LDA $C1
0290     CMP #$D0
0300     BCC T1
0310     CMP #$D8
0320     BCC NOK
0330 T1  CMP #$00
0340     BNE L3
0350     CLC 
0360     LDA #$FF
0370     STA $D40E
0380     LDA #$F7
0390     STA $D20E
0400     LDA #$22
0410     STA $022F
0420     CLI 
0430     RTS 
0440     .END 
Corne2Plum3
Run this (numbers at the left are line numbers)
1  .CODE
2  .END 
Scyla
Can it play rickroll?
Stomiks
Break it
Topic Starter
McEndu

abraker wrote:

<assembly listing>

Corne2Plum3 wrote:

Run this (numbers at the left are line numbers)
1  .CODE
2  .END 
The size of the ROM chip is not specified. But...

An 8 kilobit EEPROM chip magically appeared! You copied your program onto it, and mapped the chip to the memory address range $FC00-$FFFF.

Actual code for Corne2Plum3's program:

00000000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
*
00000400:

Disassembled:

    brk
    brk
    ...
interrupt_vector:
    .word   $0000
    .word   $0000
    .word   $0000

You connected two AA batteries as power supply, then turned on the system. You sat there, imagining what is being run. You then turned it off.

(Hint: There is no display nor RAM.)

Stomiks wrote:

Break it
You broke it. You are gifted another 65C02.
Topic Starter
McEndu
Well, it appears that nerds dominated this thread...
z0z
the average layman does not know how to use a processor
abraker
hey no fair why did an 8 kilobit EEPROM chip magically appeared for Corne but not me?!?
Topic Starter
McEndu

abraker wrote:

hey no fair why did an 8 kilobit EEPROM chip magically appeared for Corne but not me?!?
It appeared for everyone. I gave the assembled result of Corne's program because it is a rather interesting case. Your program is quite conventional compared to Corne's, so I don't think I need to give the assembled result.

The result of the programs being run appears to be the same for everyone because there is nowhere to display the results of the program to.

I do believe that in both cases, the program ran erratically due to having no RAM.
Topic Starter
McEndu
(You got 32 kilobit of RAM on a chip and an breadboard-mountable RS-232 serial socket.)
show more
Please sign in to reply.

New reply