11 comments

  • FLT815 hours ago
    I credit the C64 that I had as a kid and magazines like COMPUTE! &#x2F; Compute&#x27;s Gazette for my career in software. I taught myself 6510 assembler and started writing some simple demo-like things on that machine, and got hooked on the feeling of creativity that it unlocked.<p>Funnily enough I&#x27;d been thinking that it&#x27;s about time I tried (again, as an older person) to write a game or a demo for the old 64.<p>It&#x27;s absolutely amazing what people are able to get out of these 40+ year old machines now, and I love that there&#x27;s still a vibrant scene.<p>In addition to the tools specified in the article, I would also recommend &quot;retro debugger&quot;, it&#x27;s an amazing tool for single stepping through code and seeing what&#x27;s going on, even letting you follow the raster down the screen to see what code is executing on given scaliness.<p>Also, there are some really good youtubers out there helping to demystify how various games&#x2F;demos work.. Martin Piper comes to mind as a good example.
    • breput14 hours ago
      I credit the BASIC and machine language byte code type-in programs for reinforcing my attention to detail and being able to track down software problems.<p>Kids these days[0] will never know the &quot;pleasure&quot; of spending hours typing in some cheesy BASIC game only to have to track down any number of syntax errors!<p>[0] Get off my lawn!
      • lstodd10 hours ago
        A9 LDA# A0 LDY#<p>your lawn may stay.
        • selcuka10 hours ago
          It&#x27;s amazing that I still remember some opcodes like the ones you posted (and others, such as 0xAD for LDA$, 0x78 for SEI, 0x58 for CLI) after all these years. Brains are weird.
          • giamma4 hours ago
            I don&#x27;t remember the numeric codes unfortunately, but BEQ, BNE, JMP, JSR, ROL, ASL...
    • Lance_ET_Compte13 hours ago
      I had a C64 as well. My school had a programming class and we all shared a TRS80 (I think). I remember writing a program to find prime numbers and thinking about various optimizations. Mine was fastest, and I was proud. Then the boy that wrote directly in assembly ran his... That was the moment I decided to get good. :-)
    • agentdrek1 hour ago
      I still keep the Reference Guide on my desk to remind me of my roots and how far things have come and yet how much they remain the same.
    • ddingus12 hours ago
      Definitely try as an older person!<p>I have similar experiences and sentiments myself. One difference is I was into Apple and Atari computers, but that does not seem to matter all that much.<p>As a younger person, I did demos and explored the tech plenty without actually building finished applications and or games.<p>Learned a ton! And had major league fun. Great times filled with bits of understanding I draw on all the time.<p>And YES! Good grief, the pixels are dancing in ways nobody would have predicted back then.<p>When I hop on the machines today I find them simpler than I remember and fun to program.
    • nurettin9 hours ago
      POKE 53280, 0
  • Manuel_D15 hours ago
    Retro game coders achieve some pretty astounding results sometimes. One of my favorite examples is one who optimized super Mario 64 to such a degree that it runs with much better framerate on the original hardware. Also, multiplayer was added: <a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=t_rzYnXEQlE" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=t_rzYnXEQlE</a>
    • bitwize7 hours ago
      <a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=QB3oHdSjfCE" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=QB3oHdSjfCE</a><p>Dragon&#x27;s Lair. DRAGON&#x27;S fucking LAIR. On TI-99&#x2F;4A. The original laserdisc FMV version, albeit heavily bitcrushed, on a 16-bit home computer from 1981.
    • pipes4 hours ago
      Kaze? Yeah he&#x27;s being doing insane things, like getting mario sunshine levels to run on his modded engine. Sounds like he&#x27;s accomplished much much more too:<p><a href="https:&#x2F;&#x2F;m.youtube.com&#x2F;watch?v=Drame-4ufso&amp;pp=ygUEa2F6ZQ%3D%3D" rel="nofollow">https:&#x2F;&#x2F;m.youtube.com&#x2F;watch?v=Drame-4ufso&amp;pp=ygUEa2F6ZQ%3D%3...</a>
  • tbensky15 hours ago
    One of my favorite retro projects in this real-time TRS-80 (Model I assembler and emulator that assembles and runs Z80, literally with each key press. Mind boggling how today&#x27;s CPUs can emulate and entire 8-bit computer dev-process all between key presses in a browser. <a href="https:&#x2F;&#x2F;www.teamten.com&#x2F;lawrence&#x2F;projects&#x2F;assembly-language-ide&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.teamten.com&#x2F;lawrence&#x2F;projects&#x2F;assembly-language-...</a>.&quot; The author even says &quot;How about: With every keystroke in the IDE’s code editor, we assemble the whole program, reset a virtual TRS-80 to a known state, install the program, and run it??
  • rob746 hours ago
    &gt; <i>My favourite feature, however is being able to use labels instead of line numbers.</i><p>I guess that&#x27;s less of a feature and more of a necessity? Actually, this was one of the questions on my mind when I started reading the article. If you remember how those old BASIC dialects worked, you basically decided the line numbers for each line by yourself. The common strategy was to increment by 10, then you had some space to insert additional lines if needed without having to renumber everything (including the destinations of GOTOs and GOSUBs). Subroutines got line numbers in the 1000+ range so they didn&#x27;t interfere with your main program (example here: <a href="https:&#x2F;&#x2F;www.c64-wiki.com&#x2F;wiki&#x2F;GOSUB" rel="nofollow">https:&#x2F;&#x2F;www.c64-wiki.com&#x2F;wiki&#x2F;GOSUB</a>). Of course this system would be extremely confusing in an IDE that shows the actual line numbers of the source code by default.
    • codeflo4 hours ago
      From a nostalgia viewpoint, adding labels feels a bit &quot;impure&quot;. You might as well want to introduce other syntactic sugar, but at some point, you&#x27;re no longer writing C64 BASIC.<p>But what if you had an IDE with convenient&#x2F;native editing support for BASIC line numbers? It could auto-number on pressing enter, and it could have refactoring&#x2F;renumbering support so that you can&#x27;t miss a GOTO somewhere. But you&#x27;d always see and edit plain BASIC code. It feels like that might be fun.
      • rob743 hours ago
        That would be possible actually, but it would probably require support from the IDE for letting language plugins filter which lines are shown in the editor (which I don&#x27;t think VS Code supports currently). Then the line numbers shown in the editor&#x27;s gutter would be the line numbers defined in your code, and if you typed a new line starting with a line number, it could insert it at the location specified by the line number.
  • larodi6 hours ago
    Is not worth learning 6502 much better and even relevant since 6502s are still printed, rather than God-forsaken BASIC?<p>Besides as I tried as a child and all the magic is hidden behind POKE&#x2F;PEEK commands, the basic itself is unlike Apple II basic or DOS basic. And with all the peek&#x2F;pokes it implies going on the assembly level.<p>I did go on the assembly level for x86 when I was 14 and never regretted it. One of the top coder ppl that I knew started x86 assembly when he was 10-12 and only got into the Java bandwagon when he got in university, meanwhile mixing C and Asm.<p>I have many other reasons to believe such knowledge is not too hard for children to understand.
    • nubinetwork6 hours ago
      If you know x86, then 6502 should be easy... on the other hand, you&#x27;d have to be interested in making homebrew for legacy systems because there&#x27;s nothing really new that uses it.
      • richrichardsson4 hours ago
        I know my way around m68k assembler, so in &quot;theory&quot; 6502 should be easy, but damn it&#x27;s actually quite tricky.<p>* way fewer registers to play with (understatement)<p>* You want to mul&#x2F;div? lol...<p>* Logical Shift Left? Why do you want to do that?<p>that&#x27;s all I&#x27;ve come up against after a couple of hours last night, I&#x27;m sure there are a load more &quot;problems&quot; I&#x27;ll face.
        • nubinetwork2 hours ago
          You know 68k, but 6502 is hard? I always figured it would be the other way around... doesn&#x27;t the 68k have various MMU&#x2F;&quot;protected mode&quot;-like stuff? Edit: i could also be confusing it with PPC.
          • richrichardsson1 hour ago
            My 68k knowledge is from Amiga 500 days, no MMU to worry about there.
        • tom_3 hours ago
          Logical shift left is covered by ASL.
        • chillingeffect1 hour ago
          True. Ppl nostalgize aboutbthe 6502 but it&#x27;s a PITA. Still i believe the answer toyour question is use a Macro Assembler. To collect dozens of library routines like sort, copies, fills, yoyos, etc. And work at that slightly higher level. I wish did that at the beginning of my career :) but nowadays theyre easy to find.
  • flohofwoe3 hours ago
    Shameless plug: I cobbled together a simple VSCode extension for (so far) KC85, C64 and CPC - only for assembly coding&#x2F;debugging though.<p>The &#x27;special sauce&#x27; is that the assembler and emulators compiled to WASM and directly integrated into the extension (e.g. the emulator is running in a VSCode tab, everything is properly sandboxed):<p><a href="https:&#x2F;&#x2F;marketplace.visualstudio.com&#x2F;items?itemName=floooh.vscode-kcide" rel="nofollow">https:&#x2F;&#x2F;marketplace.visualstudio.com&#x2F;items?itemName=floooh.v...</a><p>...and it even works in the VSCode browser version, e.g. you can go here and press &#x27;dot&#x27; to start into VSCode:<p><a href="https:&#x2F;&#x2F;github.com&#x2F;floooh&#x2F;kcide-sample-kc854">https:&#x2F;&#x2F;github.com&#x2F;floooh&#x2F;kcide-sample-kc854</a><p>It *is* really quite amazing how productive 8-bit assembly coding feels with modern tooling (e.g. when you have a tight edit-build-debug loop, and having a debugger that lets you inspect the state of the entire hardware, not just CPU registers).<p>Here&#x27;s the accompanying blog post: <a href="https:&#x2F;&#x2F;floooh.github.io&#x2F;2023&#x2F;12&#x2F;31&#x2F;vscode-wasm-wasi.html" rel="nofollow">https:&#x2F;&#x2F;floooh.github.io&#x2F;2023&#x2F;12&#x2F;31&#x2F;vscode-wasm-wasi.html</a>
    • wiz21c2 hours ago
      hey flooooh thanks for your 6502 cycle accurate emulation :-) signed:some emulator author :-)
  • rbanffy14 hours ago
    What I love about this is that it should be relatively trivial to extend it to, at least, all emulators supported by VICE.
  • ryandrake12 hours ago
    Cool project, looks like they support a number of assemblers and compilers, too. It’s not clear if it also supports the ca65 macro assembler as a standalone assembler as part of their cc65 support, or if it only supports the c compiler.
  • karmakaze11 hours ago
    Amazing to see this alive and kicking in this day and age.<p>I grew up programming the 8-bit Atari and it was such a great time to experience. Information was scarce without internet, so magazines and word-of-mouth was so important. Once you collected enough information, you could pretty much hold a mental model of the entire machine in your head, and the only limitations were the number of cycles you had per second or the effort you were willing to put in. I firmly believe this is how I developed the mindset of stepping outside of the problem and readily looking for out-of-the-box solutions that pays dividends to this day.<p>Programming was a mix of BASIC and machine language routines (not even assembly as you hand-assembled to machine bytes) similar to how someone might use Python with C calls but at lower levels of both. Later on I tried compiled languages like Pascal but it ran like a dog, not tuned for the slow floppy or memory constraints of these machines. Getting a macro assembler was next-level, where you could write everything to be as fast or small as possible. Self-modifying code for wasn&#x27;t only common practice, it was quite necessary for performance.<p>Other great pastimes were reverse-engineering games and copy protection in an arms-race. Most were pretty simple and it was always exciting to see completely new techniques or super-complicated multi-pass self-modifying or otherwise obfuscated code.<p>The filesystem on the floppy disks were also easily understood with sector chaining and a free sector bitmap, so you could write low-level routines like undelete or a defragger. Modifying the floppy drive with custom sector sequencing and RPM tuning could improve timings to get higher throughput and finding that you can add SRAM to buffer an entire track really sped things up. The simplest and cheapest thing was to punch a hole in floppy disks and write to the other side (of a single-sided floppy).<p>Having this level of understanding made you believe that you could do pretty much anything and everything (just not always fast enough) and makes you program without boundaries except the hardware. Even then it was simple enough to modify parts of the hardware like ROMs or extend it with helpers plugged into the bus or PIO (parallel I&#x2F;O joystick) ports much like the GPIO on a Raspberry Pi.<p>The graphics system on the Atari was really something else, with &#x27;display lists&#x27; of data that defined memory addresses and display modes (character or raster) that could be defined for each (character or raster) row, along with color palette lookup tables that you could modify to change all the colors using those values. Even the serial SIO daisy chain on the Atari was the basis of what is now how USB enumeration and command&#x2F;reply works.<p>Shout-out to Bill Budge&#x27;s Pinball Construction Set (PCS) originally for the Apple ][ and also on Atari. Of course being a kid I mostly made video games and tools for making video games like sprite editors, character&#x2F;tileset editors, font editors, and level editors. PCS blew my mind and later got me into making programs that build applications, following the likes of Visual Basic (but running on OS&#x2F;2 PM).
    • bitwize9 hours ago
      &gt; Having this level of understanding made you believe that you could do pretty much anything and everything (just not always fast enough) and makes you program without boundaries except the hardware. Even then it was simple enough to modify parts of the hardware like ROMs or extend it with helpers plugged into the bus or PIO (parallel I&#x2F;O joystick) ports much like the GPIO on a Raspberry Pi.<p>Some of my favorite bits of The 8 Bit Guy&#x27;s channel involve when he explains how the NES and SNES controllers work, and to demonstrate he goes &quot;I wrote a little program on my C64 to poll the NES controller through the user port...&quot; and proceeds to run it and what do you know, the C64 can read NES controller input, it just needs to be taught how.<p>I&#x27;m still a bit miffed about him dremeling out the screws on that rare IBM prototype, but he&#x27;s still done some really cool stuff.
  • jansan5 hours ago
    Maybe this is a good place to ask a question regarding the hardware that is required to transfer code from and to your C64. I have a C64 and a 1541 sitting in my basement in a box and I sometimes take it out to check if it still works (it does).<p>After watching one particularly insane demo [1] I decided that I need to run them on my own machine for full experience. The question is what hardware is necessary to run them. After a little research it seems that something like a Kung Fu Flash cardridge and an SD card is all that I need to put on my Christmas wish list. Can anyone with more insight tell me if this is the right way to go?<p>[1] <a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=KPb6y44HagI" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=KPb6y44HagI</a>
    • FLT84 hours ago
      Kung Fu flash is probably all you need, with a few caveats (eg. With KFF the drive is &quot;emulated&quot; by intercepting kernal vectors rather than acting as a 1541 on the serial bus, so some software that eg. uses fast loaders or relies on the disk drive for offloading computation won&#x27;t work).<p>If you want to get fancy you could go for something like an Ultimate II+ and a usb key, which will get you a bunch of extra functionally like network connectivity, extra SID support, pretty solid compatibility, REU emulation etc (but UII+ will also cost a lot more).<p>Given you&#x27;ve got a real 1541, maybe you could just copy files&#x2F;disk images across to the real thing if KFF doesn&#x27;t work for a particular program I guess?