6 ms·
Programming the Commodore 64 with .NET
- indianlolcow 11mo ago[flagged]
- lloydatkinson 11mo agoWhat a dumb comment
- sigspec 11mo agoI think you're in the wrong place for that sort of nonsense
- metadata 11mo agoSuch a cool side project. And with LiveReload!
- indigodaddy 11mo agoSuper cool, this is what HN is all about for me.
- lysace 11mo agoIt would have been cool to get some subset of the dotnet runtime running on the C64. This is not it. It's a desktop IDE built using dotnet that just assembles 6502 instructions with some extra awkward syntax. Many more elaborate projects exist. My favorite is the one that compiles something similar to Turbo Pascal to C64 6502. It's implemented in C++/Qt, but noone ever tried to market it that way, because why would they? https://github.com/leuat/TRSE https://github.com/leuat/TRSE Turbo Rascal Syntax Error
- indigodaddy 11mo agoImo, this is actually way more interesting.
- bmn__ 11mo agoProgramming for the C64 CPU is terrible. You couldn't even attempt to port a dotnet subset. There isn't a multiplication instruction, so you have to painstakingly reinvent all useful algorithms from the last 40 years from nearly scratch and by the time you want to implement a hash you notice you're running out of RAM.
- lysace 11mo ago> You couldn't even attempt to port a dotnet subset. Because of the lack of a multiplication op code? Hmm.
- chillingeffect 11mo agoYeah it pays to have a huge library of routines...e.g. multiplication for every size combo of number sizes, signedness. Also sorts...everything, but if you scour youll find many :)
- emptybits 11mo agoA generation of programmers might disagree with you. Multiplication instructions and hash tables (!) are easily worked around, as evidenced by decades of art and innovation programmed on that "terrible" CPU. There are still 6502 programmers today delivering games, art, demoscene, etc. That CPU was a foundation of the home computer and console revolution: BBC, Commodore, Atari (consoles and computers), Apple, and Nintendo (NES).
- moring 11mo agoI don't think that games, art and the demoscene can be used as evidence here. Implementing something like C# means you have a spec to implement. You have to be creative with the implementation without violating that spec. All the three of games/art/demoscene on something like the C64 have a rough idea as the spec, but then you'll get creative about how much of that "spec" you can bend and violate to meet the technical limitations of the C64, while still being fun.
- zozbot234 11mo agoIt's just not the same class of devices. The tiniest IoT-focused subsets of .NET will still require more than 64KB of RAM and 192KB or so of mass storage. You could try and implement some minimum viable WASM subset (I think the issues that made WASM non-viable on microcontrollers and the like have been addressed by now) since the overall architecture is likely simpler, but even that is rather dubious and more like something that could be appropriate on slightly newer 16-bit machines.
- pizza234 11mo ago> Many more elaborate projects exist. My favorite is the one that compiles something similar to Turbo Pascal to C64 6502 It depends on the purpose. The reference IDE is intended to produce real-world programs (it includes tools for sprites, music etc.), while high level language compilers are mostly academic, as they're not performant enough.
- zozbot234 11mo agollvm-mos https://github.com/llvm-mos/llvm-mos https://github.com/llvm-mos/llvm-mos seems to generate good enough code - more than competitive with other high-level languages for the 6502, though perhaps not so much with manual assembly coders.
- bnchrch 11mo agoQuestion to HN .NET Devs Its been a long time since I was in the MSFT ecosystem (left just as wsl was getting popular). I remember thinking C#, F#, .NET and LINQ was a pretty robust set of tooling that was ahead of its time and certainly ahead of Java. At the time, the things that were holding it back was: - Poor to non existant linux support - A confusing labyrinth of MSFT web frameworks that were nonsensically named and often deprecated - A very GUI heavy dev and production setup I know a lot has changed since then. So how is it in 2025?
- vips7L 11mo agoEverybody's gotta bring Java into it.
- bnchrch 11mo agoKind of like if im talking about VRBO, I should mention Airbnb. Similar in the heavy weight enterprise programming language space. If im talking about .NET I should mention Java.
- vips7L 11mo agoNot really. They're independent languages with different design goals. You're exact questions in this thread would have been just as relevant without bringing it up.
- bnchrch 11mo agoOpen to you educating me here! I (maybe naively) see their design goals being very similar: - Enterprise Devs as the core user (Type safety, great stdlib) - High level OO based interfaces - Allows for low enough level programming that you can reasonably use in place of C/C++ The differences seem to be more minor: - opinionated (C#) vs unopinionated (Java) when it comes to what tools / libraries you reach for. - Conservative (Java) vs Experimental (C#) when it comes to releasing new language features - Execution model: Java seems like a better choice for "run anywhere" but C# has been indexing more in this direction
- weinzierl 11mo agoIt is only the .NET tooling. The software that runs on the C64 is still Commodore BASIC or 6502 assembly. Similarly a couple of years ago someone claimed to be able to play MP3 on the C64, but it was just a custom compression using some modern knowledge. Ultimately it had next to nothing in common with real MP3.
- zahlman 11mo ago> Ultimately it had next to nothing in common with real MP3. Designing a custom compression format that could be decompressed with C64 resources while still achieving good compression is still a very meaningful achievement. Which reminds me, maybe I should think more about that idea for a custom compression for GBA 4bpp graphics....
- weinzierl 11mo agoAbsolutely and so is enabling people to program the C64 with modern tooling many are familiar with. The misleading is not only uncalled for but also completely unnecessary - and that is the saddest part.
- Razengan 11mo agoI've sworn to myself I will learn 6510/6502 assembly and make 1 simple game for the C64 before I die. And the ZX Spectrum, and hopefully the SNES/GBA too. As an exercise to "catch up" with gaming/computing history if nothing else :')
- teddyalbina 11mo agoDotnet is an incredible platform ahead of its time. I use it for everything and never get disappointed. Also, i'm currently building a startup and everything is dotnet.
- snoman 11mo agoSame. I will say that dotnet for mobile development hasn’t kept up so I’ve gone react-native on that front for my startup. All dotnet on the backend though, and it’s great.