IECHost: PRG import in the making

In the evening today I implemented the PRG import feature in IECHost: I can now copy data from a PC to a real disk.
However, the work on this is not yet finished as I’ve been copying a chunk of memory initialised to a sample program, instead of a user-picked PRG file, for simplicity.

In order to further troubleshoot new features that write back to disk, I felt compelled to step back a bit and add some useful features before finishing the PRG import one.

In particular I added a quite flexible interface to IECHost that enables users to send commands to serial devices through the command channel. On my first attempt I roughly implemented the equivalent of:

OPEN 15,8,15,"<command>"

In case you have not tried the above before in direct mode, it might surprise you that control is returned to the BASIC interpreter immediately while the disk is busy executing <command>, which might take a while if e.g. the command is about formatting a disk.

However, if you issue a CLOSE command while the disk is busy, you might appreciate the fact that control is not returned to the BASIC interpreter until the disk command completes:


This is due to the fact that a serial device on the IEC bus (e.g. a printer or floppy drive) might be busy performing a long job. In that case it will take a while to signal it’s ready to receive when the IEC host signals it’s ready to send by releasing the clock line. There’s no time limit when it comes to waiting for a device to become ready: that’s why CLOSE will not return to the BASIC interpreter until that happens.


This entry was posted in Retrocomputing, Technical and tagged , , , , , , , . Bookmark the permalink.

One Response to IECHost: PRG import in the making

  1. Pingback: IECHost: write features being worked at | Luigi Di Fraia's e-Footsteps

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s