My Garden

My Garden

aaron-baugher

subscribers

Honestly, this one's pretty light on coding, so unless you're determined to watch every minute, it might be one to skip. I started on what I think will be the hardest part of the algorithm, preparing the message schedule, which operates on a sliding window of memory locations, so I spent most of this one thinking about and discarding different ideas for doing that. Next time I'll have that nailed down so we can get back to the easier parts and make better progress.

You can find related resources and a link to the code repository for the series here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

If you would like to contribute to support these videos, please see my Patreon at https://patreon.com/aaronbaugher . Thank you!

Demostrated how attributes -- color, flash, underline, etc. -- work on in the VDC 8563 text display. Then shifted to the VDC's graphics bitmap and started writing routines to clear/fill the bitmap display and plot points on it. Stopped with a couple bugs in the code that we'll fix first thing next time.

If you would like to contribute to support these videos, please see my Patreon at https://patreon.com/aaronbaugher . Thank you!

You can find related resources and a link to the code repository for the series here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

It's too muddy to get in the garden for real yet, but I thought I'd move these marshmallow herb plants now that the ground was thawed. We planted them in this little flower bed a couple years ago, not realizing how big they'd get, and they kind of crowd everything out. The digging was harder than I expected, because they grew down into a pretty thick layer of rock, so I couldn't bring them up with a nice dirtball. That probably won't hurt anything, since herbs, especially perennials, tend to be pretty tough.

Once I had this one dug up, it started falling apart into several different plants, so it was already dividing itself. I planted five of them along a concrete wall where I've been wanting to put some cover. I have a feeling the remaining roots will come up again, so I may have to put plastic or something down for a while to snuff them out.

Also planted a few peas and radishes right behind these a couple days previously, just pressing them into the mud, but it's too soon for them to be up. I saw some chickens loafing there the next day, so they may have gobbled up the seeds already.

Continuing on the SHA-256 program, we create more low-level routines for copying chunks of data in different ways, and the remaining low-level SHA functions.

If you would like to contribute to support these videos, please see my Patreon at https://patreon.com/aaronbaugher . Thank you!

You can find related resources and a link to the code repository for the series here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

The chickens are enjoying the warmer weather, now that the ground is thawed and they can scratch for worms again.

Started writing routines to drive the 80-column display, starting with the most basic ones to write to the registers, and then building on those. The routines here are all for the text screen, and next time we'll start on bitmap graphics. I expect to use these for the Farm game, but they will make up a library that many programs could use.

You can find related resources and a link to the code repository for the series here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

Here's a whiteboard tutorial on programming the 80-column screen on the Commodore 128. It's very different from the 40-column VIC display, since you have no direct access to 80-column screen memory and have to program it indirectly by reading and writing to the VDC's registers, which requires a handshaking process through a pair of registers at $D600 and $D601 in the C128's I/O block.

There will be another video soon demonstrating how to use the little routines here to do actual work.

You can find related resources and a link to the code repository for the series here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

I'm starting two new programs, and this should be the shorter one (the other will be a game, first video coming soon). I thought it'd be interesting to see how well an 8-bit machine could handle work designed for 32-bit (or more) processors. So far so good; the low-level functions went faster than I expected, but next time we'll get into the harder stuff. See the "part 0" video (#24) for details on what SHA-256 is all about; this one dives straight into the programming.

You can find related resources and a link to the code repository for the series here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

Memory management (banking) in the C128 is unlike the C64 or other 8-bit Commodores, since it uses the MMU to switch blocks of ROM and RAM in and out of service. This can seem kind of complicated at first, but it's essential to taking full advantage of the resources that the C128 provides, so I thought I'd do a whiteboard tutorial on how banking works and how to do it in assembly.

Looks like I still need to work on lighting. I added a lamp, but there are still some shadows. I hope that doesn't make it too hard to read my handwriting.

You can find related resources and a link to the code repository for the series here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

Finished the Worm game! Added the score display and the choice to play again or exit to a Ready prompt, and made it auto-boot from a disk image. Created and fixed bugs along the way, as usual.

It now functions pretty much identically to the BSD version. It could be dressed up with more features, like sound or more colors, so if anyone wants to fork the source code from the repository and do that kind of thing, please feel free. I'm going to move on to a more elaborate game and some other projects. Suggestions are welcome as always.

You can find related resources and a link to the code repository here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

Continuing on the Worm game, we change the colors, adding a routine to fill color RAM the same way screen RAM is filled. We put a delay in the keyboard routine, and a time limit so it repeats your last move if you take too long to press a key.

You can find related resources and a link to the code repository here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

The stack gets a lot of use in 6502 programming, so I thought I'd walk through a demonstration of how it works, the pitfalls to look out for, and how to manipulate the stack pointer when necessary.

One note on the last example: instead of TSX / 6xINX / TXS, it would be faster to simply PLA six times to move the stack pointer down six bytes. But this demonstrates how to manipulate the pointer directly, when that makes more sense.

Continuing on with the Worm game, we add code to keep the tail pointer-to-pointer (TAILP) up to date, to extend the length of the worm when necessary, and to handle collisions with numbers on the screen.

You can find related resources and a link to the code repository here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

Another mid-week bonus video in between working on the game series. I covered the indirect addressing methods in video #14 along with the others, but I've seen a couple questions about them, so I thought a whiteboard demonstration focused on the indirect methods alone might help.

I know the production quality on these isn't very good. Seems like the audio is better in this one, recording it with my phone in my shirt pocket and muxing that with the video later. Lighting could still be better, though. I'll keep working on it.

You can find related resources and a link to the code repository here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

While coding on the Worm program in video #16, I realized we would need pointers to pointers, or double-pointers. I didn't think my explanation with code was very clear, so I thought it'd be useful to draw it out visually. We will use this method to keep track of segments of the worm in order from head to tail as it moves around the screen, so we can drop the correct tail segment on each move.

You can find related resources and a link to the code repository here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

Continuing on with the Worm program. Spent quite a bit of this one realizing that we have to keep track of the position of each piece of the worm from head to tail, in a list, which means we get to do pointers to pointers. I think double-pointers might be easier to understand in 6502 assembly than in C, because you can see what's happening down to the specific addresses, but it's a mental workout either way. I may do a separate whiteboard video to draw it out.

You can find related resources and a link to the code repository here: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

It's time to start getting ready for this year's garden. First thing is to go through the saved and leftover seeds from last year, figure out what we have on hand to plant and what we need to buy. So Guy helped me do a quick inventory.

Played through the end of Summer, started construction on a barn, got into the Secret Woods, and generally grinding on skills.

Continuing our Worm game from #13, we first improve the code's efficiency in a couple spots, then add collision detection and a routine to place a number randomly on the screen for our worm to seek out. Next time: debugging why the random number is always 5 instead of 1-8 and why it lands in the same quadrant of the screen each time.

This is sort of a bonus video that I wish I'd done after #3. The topic of addressing modes came up in an assembly forum, and someone said they seemed complicated, so I wished I had a video I could point to that explains them. Now here it is.

More information for this series of videos and related materials can be found at: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

Did a lot of mining, trying to reach the bottom. Built a coop. Talked about furnaces and cold houses, BASIC (the programming language) and how older systems are making a comeback. Maybe a few other things.

Starting a new project on the Commodore 128: the game Worm, an old game for text-based terminals. In this part, we lay out the screen border and write the code to move the head of the worm around.

More information for this series of videos and related materials can be found at: https://aaron.baugher.biz/pages/6502-assembly-language-programming/

Started playing a new game of Autoduel on the Commodore 64 (emulated with Vice). Unfortunately, the game locked up the first time I got killed and it tried to activate my clone. But before that, I got to show how to make money gambling, build a car, win an arena competition, and haul courier tasks between cities to make money and gain prestige.

We convert a famous one-line BASIC program to 6502 assembly language on the Commodore 128. (Would work on other 8-bit Commodore systems with small changes.) More technical details at: https://aaron.baugher.biz/post/6502-assembly-language-12-10print/

Recorded this one Jan. 11, 2018. Lots of mining, took forever to find the fire quartz I was after.

SHOW MORE

Created 1 year, 7 months ago.

86 videos

CategoryVlogging

Videos from my garden and related topics, showing the progress throughout the year.