top | item 29321637

C64

182 points| amasad | 4 years ago |replit.com | reply

39 comments

order
[+] dark-star|4 years ago|reply
I'm confused. So... someone figured out that you can use cc65 to compile C code for the C64, and then he stuck it into an Emscripten version of VICE and put it on the web? I can click on "run" and it looks like it's compiling the two programs, puts them on a floppy, and then runs VICE with that floppy... What's the point of this?

I can see the source code when I click on "show files", but I cannot edit anything, I think I'm obviously missing something here... how is that an IDE? Or is the IDE running inside VICE and I can load it somehow?

Can someone enlighten me?

[+] 19wintersp|4 years ago|reply
It's a read-only "IDE" of sorts; it's effectively a disk image stored in the cloud, which when run will create a VM and send the output back to you. If you create an account, you can fork that repl to create your own editable version of it, and access the full IDE.
[+] flerovium|4 years ago|reply
Similarly confused. This seems to be running on a remote box, but:

(1) How is the information is getting to the frontend?

(2) How is it being rendered when it gets there?

(3) What is being run on the box?

[+] pwrrr|4 years ago|reply
Same. It is very slow, and I can't figure out how to do anyhting useful.
[+] 300bps|4 years ago|reply
Seems to be VICE running in a web client? VICE is a well-known Commodore 64 emulator that's been around for 28 years. I'm not sure why I wouldn't just run this locally? Serious question - what is the advantage of this?

Running it on Replit I had to answer a multi-stage CAPTCHA identifying all trucks and then it was so slow I couldn't even type without holding the keys down for several seconds before they would register.

[+] djmips|4 years ago|reply
Very nice. Some ideas... that you already thought of ;-) For a REPL it's a little too slow...

- Automatically do the LOAD "CPROG",8 and RUN

- Even better. Load the CPROG directly into the memory image and bypass the drive load completely

- Optimize Emulator startup

[+] amelius|4 years ago|reply
It's so slow, it's even missing keystrokes.
[+] sixothree|4 years ago|reply
It doesn't fit the frame properly on my system.
[+] flerovium|4 years ago|reply
We can't really know why it's slow without knowing how it works.

If it were sending keystrokes to a box, you should expect latency <100ms and no bandwidth limitations. It must be a problem with the emulation server. Without knowing more, we can't really know.

[+] ataylor284_|4 years ago|reply
Very cool. One of the c64's glaring omissions for a hackable machine is a built-in monitor. My suggestion: throw a monitor program (my favorite: https://github.com/jblang/supermon64) onto the one of the disks and you'd have a just enough to do some actual debugging.
[+] rzzzt|4 years ago|reply
VICE has a monitor. It can also resolve symbols in KERNAL, IIRC.
[+] pomian|4 years ago|reply
Brilliant! Now if I could find my old cassettes, with the programs I wrote, and record them onto a computer, I wonder if they would run?
[+] flerovium|4 years ago|reply
Warning: if you try the "Snapshot" option, it will open a window that can't (?) be closed?
[+] spullara|4 years ago|reply
I was hoping this was one of their IDEs / runtimes not just a program that happens to be on Replit.
[+] amasad|4 years ago|reply
If you fork it you can program it in the IDE including writing C and ASM programs.

But it’s a good idea — will make it a template!

[+] ChrisArchitect|4 years ago|reply
Descriptive title: Functional Commodore 64 development environment on Replit
[+] bouncycastle|4 years ago|reply
Cool! Is there a way to save as a d64 file and export out of the browser?
[+] flerovium|4 years ago|reply
Is this open source?
[+] amasad|4 years ago|reply
Yes, most things on Replit are open-source. Just click "show files" on the top-left corner. Also it's powered by Nix, and we wrote a ton about it here: https://blog.replit.com/