I'm actually more excited to see a new Ben Eater video on youtube than anything else.<p>His stuff is just fantastic. Even though it's lower level than I've ever worked, it's extremely entertaining and educational.<p>His 6502 series is just great, but I want to highlight another couple of videos he did:<p>"Let's build a circuit that displays an image on a VGA monitor! In this video, I talk about how VGA signals work and build a circuit that provides the correct timing of sync signals so that a monitor recognizes the signal."<p><a href="https://www.youtube.com/watch?v=l7rce6IQDWs" rel="nofollow">https://www.youtube.com/watch?v=l7rce6IQDWs</a>
Skimming through this, this is the first piece of code that my eyes drilled into more deeply:<p><pre><code> LCD__clear_video_ram:
pha ; preserve A via stack
tya ; same for Y
pha
ldy #$20 ; set index to 32
.loop:
lda #$20 ; set character to 'space'
sta VIDEO_RAM,Y ; clean video ram
dey ; decrease index
bne .loop ; are we done? no, repea
sta VIDEO_RAM ; yes, write zero'th location manually
pla ; restore Y
tay
pla ; restore A
rts
</code></pre>
Surely we don't need to keep loading the space character into A on every iteration?<p>Since Y starts at a hard-coded value that is (well) below $80, this could use "bpl .loop" and drop the "sta VIDEO_RAM" special case.<p>In .select_option, I'd looking into doing a jump table. Ideas here: <a href="https://wiki.nesdev.com/w/index.php/Jump_table" rel="nofollow">https://wiki.nesdev.com/w/index.php/Jump_table</a>
Semi-related, I've been enjoying Robert Baruch's videos[1] on creating a FPGA implementation of the 6800, using nMigen and formal verification. First videos are almost like live coding, then he skips to a more compact format.<p>As a regular programmer, it's quite interesting to get into how the bits actually end up getting the work done.<p>[1]: <a href="https://www.youtube.com/watch?v=85ZCTuekjGA&list=PLEeZWGE3PwbbjxV7_XnPSR7ouLR2zjktw" rel="nofollow">https://www.youtube.com/watch?v=85ZCTuekjGA&list=PLEeZWGE3Pw...</a>
Watching Ben Eater's videos renewed my interest in making some simple computers out of old hardware, mainly because the older hardware is simple enough that you can work with it on a breadboard.<p>The interest eventually morphed into doing something with all of the old parts I've hoarded. Going through the bins of parts, I've found things like 8051 microcontrollers (P80C550) and UARTs (AM85C30) and some old RTC units (MC146818). I ended up picking up a few 68010's (among other things) off of eBay with the hope of building a breadboard Linux computer, as slow as that may be. I believe the 68010 may be the <i>only</i> CPU in a DIP package still supported in some capacity by Linux (as long as you provide an MMU).<p>Hopefully this will actually get me back into writing/making videos about my projects.
I love, love, love Ben's videos, and this is an awesome project.<p>But to be as painfully pedantic as possible: can we please use the word 'monitor', here? Calling it a 'microkernel' really gives one the wrong initial impression.<p>Still, very neat. Now write a BASIC!
Are there any good resources for learning electronics for someone with a strong programming background and understand digital logic? Ben Eater videos assume knowledge of electronics and would like to know more
This reminds me of C64 tape loaders or "turboa" that need to load the program to RAM.<p><a href="https://www.atarimagazines.com/compute/issue57/turbotape.html" rel="nofollow">https://www.atarimagazines.com/compute/issue57/turbotape.htm...</a><p>Also let's not forget Bill Gates's 17 bytes loader<p><a href="https://hackaday.com/2017/03/24/doing-it-with-fewer-bytes-than-bill-gates/" rel="nofollow">https://hackaday.com/2017/03/24/doing-it-with-fewer-bytes-th...</a>
I just read your source code a bit, and there are a lot of things wrong.
First, you should ALWAYS clear the carry when using ADC or set the carry when using SBC<p>For example:
.increase:
adc #1
sta POSITION_MENU<p>I have no idea if you increment or add two, since the carry is not cleared.<p><pre><code> clc
lda CURRENT_RAM_ADDRESS_L
adc #$01
sta CURRENT_RAM_ADDRESS_L
lda CURRENT_RAM_ADDRESS_H
adc #$00
sta CURRENT_RAM_ADDRESS_H
</code></pre>
this is done by the usual INC CURRENT_RAM_ADDRESS_L BNE *+2 INC CURRENT_RAM_ADDRESS_H<p><pre><code> ldy POSITION_CURSOR
cpy #0 </code></pre>
cpy #0 is useless.<p>lda POSITION_CURSOR
cmp #0
cmp #0 is useless<p>jsr / rts can be replaced by jmp<p>clear_ram is super slow