This is amazing! I’m so glad that I found your videos (someone posted the link in the Facebook group). I am eagerly awaiting my x16, and I’m learning all that I can about how to program for it and how it works. I am very excited for the rest of your videos! Thank you for doing these.
Good luck! As cool as the Commander X16 is, I'm a sucker for the 65C816. And since I also prefer the combined keyboard/computer slab form-factor, I ordered a Foenix Retro Systems F256K instead.
I'll have to look into that and see how much work it would be to port my library (and any games I make) to work with both. At a glance, the specs look similar, so maybe it wouldn't be too hard. But my focus will definitely be on the CX16 for now. I wish I had more time for this stuff, but limited time necessitates a narrow focus.
@@dr.jstudio It's a *really* eloquent platform and very well designed. I try to spread the word as much as I can because it doesn't get the exposure it deserves. Fortunately that seems to be improving though.
Great presentation. I am in a similar boat, where I love making games, but feel very daunted by the demands of working with low level languages and toolchains. I will look forward to seeing what help you can share. If you can end up sharing a repo of a project template one might use to make games for the Commander X16 with your techniques, I’d love to check it out.
good luck my friend! I ordered a dev CX16 myself, it looks really intense so im not sure how much deving ill do just yet. I got too many projects Im already working on. haha.
I didn't know there were other options for C compilers that target the 6502. I'm unlikely to switch because cc65 has been working well for me and I might have to rewrite a lot of stuff if I changed to a different compiler, but even so I'm curious, what differentiates LLVM-MOS from cc65?
The biggest differences are the possibilities that it opens up in terms of compiler frontends, and code generation quality. It plugs into any frontend that supports LLVM, which opens up the possibility of using Clang as a compiler, which supports the latest C and C++ standards. Even C++23 should work just fine. You can even use Rust, since its compiler uses LLVM. But even just sticking with C, it means you can go beyond C99. In terms of code generation, it supports all of the aggressive LLVM optimization passes, notably link-time optimization which is a big deal on an 8-bit system with limited memory, where eliminating dead code is really useful. The developers have also added 6502-specific optimization passes, such as moving local variables into static memory locations to take the pressure off of the 6502’s incredibly limited stack. That lets you write more idiomatic code full of local variables without worrying that it will kill your performance. It all adds up to a sizeable difference in performance. I think it does pretty favourably in benchmarks because of that.
Does ZSMKit not work with C? ZSound is great but not currently maintained. The alternative ZSMKit should part of the official ROM and is newer, active and updated.
And I take it back - ZSMKit does not appear to be in the ROM itself, so it still needs to be linked in. But the person who maintains the ROM (MooingLemur) developed it and is great about answering questions in the Discord.
Hey, glad Zsound proved so useful for you. Sound can be pretty arcane, even on modern systems. Yes I have left it undeveloped for a while. My friend MooingLemur forked it to create ZSMkit. I was collaborating with him about the sound support bank in the Kernal about the time I fell out of the hobby for a bit. He’s added PCM support to ZSM in ZSMkit, which was an item I was kind of stuck in analysis paralysis over. He’s done a good job honoring the format specs with it but ZSMKit took a few things that were a bit counter to my own design goals for Zsound - I’ll probably update Zsound some time again to include the PCM support.
@@jc33353ZSMkit uses several routines that got put into the Kernal ROM (and Zsound will do so as well whenever I get back into maintaining it) Probably the nicest thing the ROM does is maintain a YM register shadow for you as long as you use its ym_write routine. There was free space for that in the Kernal’s bank of HiRAM that you really couldn’t use in “user space” without risking incompatibility and crashes if the Kernal changes.
This is a fantastic tutorial and breakdown of the Commander X16. Thank you and please keep it up.
This is amazing! I’m so glad that I found your videos (someone posted the link in the Facebook group). I am eagerly awaiting my x16, and I’m learning all that I can about how to program for it and how it works. I am very excited for the rest of your videos! Thank you for doing these.
Nice, glad you're finding them helpful!
Good luck! As cool as the Commander X16 is, I'm a sucker for the 65C816. And since I also prefer the combined keyboard/computer slab form-factor, I ordered a Foenix Retro Systems F256K instead.
I'll have to look into that and see how much work it would be to port my library (and any games I make) to work with both. At a glance, the specs look similar, so maybe it wouldn't be too hard.
But my focus will definitely be on the CX16 for now. I wish I had more time for this stuff, but limited time necessitates a narrow focus.
@@dr.jstudio It's a *really* eloquent platform and very well designed. I try to spread the word as much as I can because it doesn't get the exposure it deserves. Fortunately that seems to be improving though.
Great presentation. I am in a similar boat, where I love making games, but feel very daunted by the demands of working with low level languages and toolchains. I will look forward to seeing what help you can share. If you can end up sharing a repo of a project template one might use to make games for the Commander X16 with your techniques, I’d love to check it out.
I've got to do a little work to clean it up for general use, but I'll be happy to do that once I have the time. Thanks for watching!
good luck my friend! I ordered a dev CX16 myself, it looks really intense so im not sure how much deving ill do just yet. I got too many projects Im already working on. haha.
Have you looked at LLVM-MOS as opposed to CC65? I have found it really useful so far.
I didn't know there were other options for C compilers that target the 6502. I'm unlikely to switch because cc65 has been working well for me and I might have to rewrite a lot of stuff if I changed to a different compiler, but even so I'm curious, what differentiates LLVM-MOS from cc65?
The biggest differences are the possibilities that it opens up in terms of compiler frontends, and code generation quality.
It plugs into any frontend that supports LLVM, which opens up the possibility of using Clang as a compiler, which supports the latest C and C++ standards. Even C++23 should work just fine. You can even use Rust, since its compiler uses LLVM. But even just sticking with C, it means you can go beyond C99.
In terms of code generation, it supports all of the aggressive LLVM optimization passes, notably link-time optimization which is a big deal on an 8-bit system with limited memory, where eliminating dead code is really useful. The developers have also added 6502-specific optimization passes, such as moving local variables into static memory locations to take the pressure off of the 6502’s incredibly limited stack. That lets you write more idiomatic code full of local variables without worrying that it will kill your performance. It all adds up to a sizeable difference in performance. I think it does pretty favourably in benchmarks because of that.
@@noname4422 Great info, thanks.
Does ZSMKit not work with C? ZSound is great but not currently maintained. The alternative ZSMKit should part of the official ROM and is newer, active and updated.
Wasn't even aware of ZSMKit. Thanks for bringing it up, I'll have to check it out.
Looking forward to the devlog! @@dr.jstudio
And I take it back - ZSMKit does not appear to be in the ROM itself, so it still needs to be linked in. But the person who maintains the ROM (MooingLemur) developed it and is great about answering questions in the Discord.
Hey, glad Zsound proved so useful for you. Sound can be pretty arcane, even on modern systems.
Yes I have left it undeveloped for a while. My friend MooingLemur forked it to create ZSMkit.
I was collaborating with him about the sound support bank in the Kernal about the time I fell out of the hobby for a bit.
He’s added PCM support to ZSM in ZSMkit, which was an item I was kind of stuck in analysis paralysis over. He’s done a good job honoring the format specs with it but ZSMKit took a few things that were a bit counter to my own design goals for Zsound - I’ll probably update Zsound some time again to include the PCM support.
@@jc33353ZSMkit uses several routines that got put into the Kernal ROM (and Zsound will do so as well whenever I get back into maintaining it) Probably the nicest thing the ROM does is maintain a YM register shadow for you as long as you use its ym_write routine. There was free space for that in the Kernal’s bank of HiRAM that you really couldn’t use in “user space” without risking incompatibility and crashes if the Kernal changes.
You sound like one of the GDevelop guys "Helper Wesley" or some such