Sunday, October 1, 2023

Mastodon for Apple II

If you’re interested in retro computing, you may be happy to read that I’ve made a binary release of my Mastodon client for the Apple 2. It has been mostly tested on an Apple //c, and works on ][+, IIe, //c, //c+, IIe enhanced, IIe Platinum and IIgs according to emulator testing.

The login screen

Features:

This Mastodon client features:

  • 2 factor authentication login
  • Home, local and global timelines view
  • Infinite scroll
  • Profile view
  • Thread view for toots with replies
  • Notifications view
  • Image viewer (toots and profiles), with description
  • Favouriting and Retooting
  • Toot writing (with images)
  • Toot edition
  • Replying
  • Content Warning (both reading and sending)
  • (Un)following people
  • (Un)blocking and (un)masking people
  • Bookmarks

Most obviously missing things:

  • Polls
  • Profile edition (bio, images etc)
  • Account creation

To get a good idea of what you can do with this client, check the Mastodon for Apple II User guide.

What people say about it:

  • “I will never use this and yet I love that it exists.”
  • “Absolutely pointless, beautiful work here”

Screenshots:

(You will find detailed installation instructions just below these)

Installing the proxy:

Download surl-server-buster-YYYY-MM-DD-lite.img.gz from the Github Releases page.

Uncompress it and copy it to a micro-SD card. You can do it using command-line on most platforms, or use a tool like Balena Etcher to do it interactively. Here is how to do it via command-line (substitute YYYY-MM-DD for the file you downloaded, and /dev/mmcblk0 for your microSD’s device file):

gunzip surl-server-buster-YYYY-MM-DD-lite.img.gz
sudo dd if=surl-server-buster-YYYY-MM-DD-lite.img of=/dev/mmcblk0

You can now insert the microSD card in a Raspberry, plug it into your Ethernet network, and put it away for now.

Transferring the floppy:

Download the floppy image from the Github Releases page. Use the image corresponding to your Apple II:

Apple II model Floppy image
][+, IIe without a 80-column card mastodon-oldii.dsk
IIgs mastodon-iigs.dsk
//c, //c+, IIe enhanced or platinum mastodon.dsk

Download ADTPro from ADTPro’s releases page, and install it.

Put the mastodon.dsk file in ADTPro’s disks/ subdirectory.

(Note: there is a very good video documenting the following process, if you prefer this format).

Get a DIN-5 to DB-9 null modem cable (from RetroFloppy for example, from 8bitclassics, or on Ebay), and a DB-9 to USB serial adapter (from RetroFloppy for example, or just about any other place. Some chipsets are better than others and an FTDI-based cable will work great).

Connect your Apple II to your modern computer via the serial cables, then turn on the Apple II without a floppy. Get to BASIC prompt, pressing Ctrl-Reset if necessary, then type:

IN#2

The number here depends on where your cable is plugged: On an Apple //c, it’s 2 for the modem port, 1 for the printer port. On an Apple IIe, it depends on your Super Serial Card’s installation slot.

You can now configure the serial port on the Apple II: At the command prompt, type Ctrl-A, then, without typing Enter, space or anything, continue with 14B. This is all.

On your modern computer, start ADTPro. Click on the Serial button; select your serial port (usually COM1 on Windows, ttyUSB0 on Linux). Click Bootstrapping / ProDOS / Speediboot. You will see ADTPro suggests to perform the Apple II setup we just did, so you can click OK.

Once the bootstrapping is done (a few minutes), the Apple II ADTPro client will open. You can now insert a blank floppy disk in the Apple II, then hit R to receive a disk image, then either type MASTODON.DSK, or Enter to get the list of available disk images and select MASTODON.DSK.

(Note: if you plan on using ADTPro for more, you can and should create an ADTPro floppy too, to avoid all the bootstrapping in the future. Just receive the ADTPRO-2.1.0.DSK file to a floppy).

Your Mastodon floppy is now ready. You can unplug the serial cable from your PC, plug it into the Raspberry, and boot the Raspberry.

You can now reset the Apple II (either by turning it off and on, or via Ctrl-Open-Apple-Reset), and login into your Mastodon instance!

Final step: enjoy!

After this, everything should work. If not, log onto the Raspberry using ssh and the pi/raspberry login. You can investigate the logs in /var/log/syslog.

Once in the Mastodon application on the Apple 2, make sure to configure it (using the O key) if you have a french keyboard, for charset conversion to/from UTF-8 (and I’d be glad to add other layouts if you know their charsets!), and configure the image conversion algorithm for monochrome or color monitors.

Upgrading:

If you want to upgrade following a new release, you will have to re-transfer a floppy image using ADTPro. For the proxy part, you can either start fresh with a new Raspberry image, or ssh into your existing Pi to upgrade the package:

ssh pi@<ip-address-of-the-pi>
$ sudo apt update
$ sudo apt install --reinstall surl-server

Troubleshooting:

If you have serial communication issues, you can try lowering the serial speed in the proxy’s /etc/a2tools/tty.conf file – although the default 19.2kbps should be completely safe. After changing this configuration file, restart the proxy service using

sudo systemctl restart surl-server.service

You can also try to change the serial port you use on your Apple II. The Mastodon client will suggest reconfiguring the default serial settings at startup, if it can not connect to the proxy.

Note: The serial speed has been upgraded from 9600bps to 19200bps at release 1.5.0. Make sure to update the surl-server settings in /etc/a2tools/tty.conf.

Note: By default, the surl-server proxy on the Raspberry runs without hardware line handshaking, which is not ideal for the Apple II, but is the most compatible solution: hardware handshaking support depends on your adapter cable. If you know it supports it, or want to give it a test, update /etc/a2tools/tty.conf and set hw_handshake: on. Then restart the service using:

sudo systemctl restart surl-server.service

If you have questions or suggestions, I’d be happy to hear from you, either by email or on Mastodon.



from Hacker News https://ift.tt/pvBst48

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.