unbibium: (Default)
At Heatsync Labs, my grandfather's Commodore 64 was hooked up to an SD card reader, using it as its main disk storage for about two years. That SD card reader broke.

Now, we used to leave the C64 running a little demo I threw together. It switches between a cyberpunk message generator, which shows random "VERB TO NOUN" calls to action in a large pixel font, and a Matrix rain effect screensaver. I've recently added images of my Oswald stencils to the screensaver part; people seemed to like it. These were on the SD card reader, and I never moved it to a real floppy disk, though I did put it on github.

We have a real 1541 disk drive set up, but there wasn't much on it. so last Saturday I looked through my storage box that I keep at HSL, and fished out all the floppy disks. Maybe one of them would have something comparable we could run as a demo. I found a lot of old pre-BBS stuff, including a random PETSCII face generator for the PET from 1978. And I found a copy of Screen Headliner, the program from Compute I used to make the large pixel font in my demo. I knew it was the one my grandfather typed in, because I remember having to find the Compute article online and type it in myself two years ago.

I did find one disk that had "Musicterm 3+" on it. I thought I could use it to download files to floppy disk. I was discouraged at first, because Musicterm only went up to 1200 baud, and the WiFi modem was set up to receive commands at 2400 baud. Getting the commodore 64 serial port to work even at 1200 baud is chancy, most terminal programs have custom timing to make higher baud rates work. Regardless, I wrote a quick hail-mary BASIC program to open the RS-232 device at 2400 baud, and print#5,"at$sb=1200" to it. To make a long story short, that worked, and I got the modem back into 1200 baud mode. Now I just had to figure out how to send files to it. If I could upload CCGMS, then I could switch back to higher baud rates.

I got out my aging MacBook Air and tried to install telnetd. After some trouble I did get it working, and was able to use Musicterm to telnet to the MacBook. I tried to use lrzsz from the command line to send files with XMODEM one by one, but the Telnet protocol has all these control codes that mess with the transfer, so it locked up.

I looked in the man page for lrzsz and there's a --tcp-server option that will open up a TCP port and listen for connections. So I put in my SD card, and in the MacBook Air, I typed lsx --tcp-server CCGMS. It annoucned that it was listening on port 49700. On Musicterm, I entered terminal mode and typed atdt flatty:49700 and it responded connect 1200. I activated Musicterm's Xmodem download, and the transfer succeeded without a hitch.

So right now, in the 1541 disk drive at Heatsync Labs, there is a disk called "Games #1" that contains some games I mostly downloaded from BBSes back in the day, and a cheesy menu program I wrote back then too. I copied the cyberpunk demo to that disk, and listed it as the first game in the menu. I also optimized the menu program and got rid of a custom font that nobody would have noticed. The back side of the disk has CCGMS and some other stuff on it.

I copied a few things off the disk onto the MacBook Air too, so I could delete them off the floppy disk and make room for more games. these included instructions for a TV descrambler and an application form for a BBS that I don't remember calling. I'm such a packrat.
unbibium: (Default)
So, the 8-Bit Guy's dream computer, the Commander X16, has reached a physical prototype stage, and seems to borrow so heavily from the Commodore 64 that I've already got SpeedScript kinda-sorta working.

It even works in the X16's 80-column mode, but it's much much slower in that mode, because it turns out SpeedScript redraws the entire screen constantly. In fact, that's how it blinks the cursor: it changes the letter your cursor is pointing at to an inverse version of itself, and just draws that whole section of the document to the screen. If you reset whil the cursor is visible, then the c64 version actualy has an NMI that smooths things out.

i need to figure out how to detect shift-ctrl commands, there's a lot of that
unbibium: (animated pacman)
I think I started writing the BASIC port just so it could run this program.  Now it can.

10 PRINT CHR$(205.5+RND(1));:GOTO 10

In more frustrating news, the comparison operators are having trouble remembering the data type on the left side of the equals sign.  The original program used the carry bit, so now I need to figure out where exactly it pulled and stashed it.
unbibium: (Default)
So, in order for me to claim that I got the startup screen working, I have to get the CPU to walk through all the same subroutines that it did on the real Commodore 64, to bring up "38911 BASIC BYTES FREE".

Now, I can write a native subroutine that'll take a 16-bit byte and write the decimal equivalent to the screen, but the real Commodore 64 converts the number to a float, and calls the routine to print a floating point number. Since I'll have to get this thing to print numbers eventually, I might as well do it now. It'll be easier to do it before the point where I'm typing in test programs.

So, what I've been doing is setting parallel breakpoints on a Commodore 64 emulator and DTDB, and checking that the CPU and memory are at similar states at various points.

So far, I've gotten the right behavior up to the point where it calls FOUT. On a real Commodore 64, it hits MUL10 at least once, and I need to figure out why.

By the way, the Atari 8-bit version would have been much harder, because its OS stores its digits in BCD format, and the target CPU has no BCD math mode. The Commodore OS uses binary for everything, hence all the multiplying and dividing by 10.
unbibium: (animated pacman)

import math

def cbm2float(e, m):
    if m==0:
        return 0
    m2 = (1 + ((m & 0x7FFFFFFF) / 0x80000000))
    e2 = (2 ** (e-129))
    print (m2, e2)
    if m & 0x80000000:
        return -(m2 * e2)
    else:
        return m2 * e2

def float2cbm(f):
    if f == 0: return (0, 0)
    e = int(math.log(f, 2))
    e2 = e + 129
    m2 = int(((f / (2 ** e))-1)  * 0x80000000) 
    if f < 0:
        return (e2, m2 + 0x80000000)
    else:
        return (e2, m2)

print(cbm2float(0x84, 0x20000000))
print("%x %x" % float2cbm(10))

print("PI in the C64 rom is at AEA8: $82,$49,$0F,$DA,$A1")
print("PI found by this program is: %x %x" % float2cbm(math.pi))
unbibium: (Default)
I want to mod my Atari 800XL with the super-video mod, and then maybe put Ape Warp+ OS in it.

but I would hate to spend all that money on equipment and parts, and discover that I'm too blind to do it, and break my Atari in the process.

also, nobody else cares about those old games.
unbibium: (Default)
I watched a Cracked video discussion of Teenage Mutant Ninja Turtles, and realized something about its internationalization.

In the UK they were called "Teenage Mutant Hero Turtles" because "Ninja" was a violent and subversive concept. However, they didn't bother to change "turtle", which in the UK refers only to sea turtles, to "tortoise".
unbibium: (Default)
I'm reading iWoz, in audiobook form.

I'm glad it's unabridged. Even though I'm not a hardware guy, I'm fascinated by all the technical details about the stuff Woz built.

Also, the longevity of the Apple 2 was already impressive, as I'd seen them installed in my high school as late as 1996. But then I learned that the design was completed before Woz even left Hewlett-Packard.

It woke me up a little. The dawn of home computing was exciting enough for me when I was a little kid. But to people who were grown up at the time, it must have been even more magical. Could you imagine being the first person in your city to buy Visicalc?
unbibium: (Default)
We may have an heir to the Super Mario Frustration throne.

マリオっぽい自作ゲームを先輩にやらせてみた1

unbibium: (Default)
This demo played in stores in 1982.

unbibium: (Default)
I was unpacking a box in the closet, and in a late 1990s paperback edition of "The Restaurant at the End of the Universe", I found as a bookmark, the first concert ticket I'd ever purchased. I bought it at Dillard's, and got it for $20 with my KUPD Red Card.



It was for Ozzy Osbourne, and it was actually postponed at the last minute because Ozzy had gotten ill, so my best friend Donnie and I had to wait in the parking lot for his gigantic Ford Galaxie to cool down. He wore a T-shirt from the "Filthy Smelly Puking Habit" anti-smoking campaign of the time, which he proudly described to other concert-goers while smoking. I ended up getting a cheap (though possibly bootleg) T-shirt in the parking lot, and we met up with some other pissed off concert-goers while we waited for Donnie's car to cool down. Some of them had driven in from Tucson. But since I hadn't, I had fun anyway. It's also the first time I peed outside within the Phoenix city limits.

And a few months later, we got our concert, though the opening act had changed. It was just Sepultura then, which I didn't really care for.

The reason for the poor condition of the ticket could be the ravages of time, but it could also be because I dropped it in a puddle of beer. I actually left it at my seat while I went out to get refreshments, and had to sneak past a security gate as a result.

And just as Ozzy was about to come on stage, the lights to the seats went out, and I still hadn't found my seat yet, and as a result I crashed into some guy and made him drop his beer. He got angry enough to raise the attention of security, but before he got there, I'd diffused the situation by covering the cost of the beer, with a $20 bill. I didn't care about making change, I just wanted to not get in a fight, not get kicked out, and not miss the beginning of the show.

I don't really remember much else about the concert, except it being my first concert I didn't really know how to emote properly.

Funny, now that I'm working for Ticketmaster, I don't see many concerts anymore.
unbibium: (Default)
Know the AppleTV? Well, Commodore makes one too.

But I think it's only available in Europe.

Profile

unbibium: (Default)
unbibium

June 2025

S M T W T F S
1234567
891011121314
151617 18192021
22232425262728
2930     

Syndicate

RSS Atom

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jul. 9th, 2025 06:00 am
Powered by Dreamwidth Studios