Archive for 2009

There is now a C compiler for Morpheus – and it supports XMM!

Sunday, December 13th, 2009

Ross has worked really hard on the latest release of his Catalina C compiler for the Propeller.

He added FULL support for Morpheus with XMM, and even modified Chip’s text driver for 128×64 / 100×50 / 80×40 characters/lines!

You can find a link to his official repository for Catalina on the Downloads page.
Included below is his announcement:

Here is Catalina 2.2. Catalina is a FREE ANSI compliant C compiler for the Propeller.

This release of Catalina adds significantly improved support for Multi-CPU Propeller systems. It adds support for Morpheus, and adds proxy driver support for all multi-CPU systems (currently supported are Morpheus and the TriBladeProp).

In multi-CPU systems, proxy drivers allow all devices to be used by a Catalina program as if they were local devices – even if those devices are physically connected to another CPU. For example, on Morpehus CPU 1 has a keyboard, mouse and SD Card interface, while CPU 2 has XMM RAM and a VGA display. You can now run a Catalina LMM program on CPU 1 and give it access to the VGA display on CPU 2, or (probably more common) you can run an XMM program on CPU 2 and give it access to the SD card, keyboard and mouse attached to CPU 1. Catalina provides a proxy device server to run on the CPU that has the devices physically attached.

The commands to build proxy programs are slightly more complex than normal, but not too difficult once you get used to it. Here is an example:

To compile a client program for Morpheus that will run on CPU 2 but use the devices connected to CPU 1, the command would be something like:


To compile a proxy device server program to run on CPU 1, the command would be something like:

bind -p -D MORPHEUS -D CPU_1
homespun Generic_Proxy_Server

Loading the resulting programs can be complex, but the Catalina SD Card and Serial I/O program loaders can be used to do this. The Catalina documentation has been updated and the tutorial now includes examples of using proxy devices.

Here is a summary of recent fixes/improvements to Catalina.


The main changes in this release are Morpheus and proxy driver support:

  • Added Morpheus support. XMM is supported on CPU #2. The Mem+ board is also supported, but Morpheus and the Mem+ have to be configured to provide a contiguous block of XMM RAM for Catalina to use.
  • Added support for a HiRes VGA display on Morpheus CPU #2. This is identical to the HiRes VGA display on other platforms except that on Morpheus it supports 256 colours (only 64 on other platforms). Also, note that this driver uses 3 cogs on Morpheus, whereas it requires only 2 cogs on other platforms – this may affect some programs that need to use other plugins as well.
  • Added error messages if you try to specify incompatible HMI options. For example, on Morpheus, you cannot use the TV HMI plugins, and Catalina will now generate an error messages if you try to compile programs that try to do so. Note that this is not guaranteed to detect all incompatible options.
  • Implemented the fseek options SEEK_CUR and SEEK_END (this was actually fixed by a patch to Release 2.1).
  • Fixed a bug that caused Catalina to crash if a command line option that required a value was not followed by one (e.g. -D at the end of the line).
  • The XMM support code in all files that need it is now identical – the particular XMM functions required are now specified using #defines instead of commenting out parts of the code.
  • Added an XMM memory tester – see the ‘ram_test’ subdirectory. Useful for testing ports to new XMM hardware – this is a normal SPIN/PASM program which tests out XMM RAM – if this program runs ok, chances are good that Catalina XMM support will work fine.
  • Catalina can now initialize and run all 8 cogs on startup. Previous versions could only initialize and run 7 cogs on startup – the 8th cog could only be used by starting it manually from within the C program.
  • Individual CPUs are now called “CPU_1”, “CPU_2”, “CPU_3” (etc) on all multi-CPU systems. Previously on the TriBladeProp they were called “BLADE_1”, “BLADE_2” etc, but this makes less sense on other platforms so Catalina now uses a consistent terminology across all multi-CPU systems. The CPU should now be specified on all compiles on multi-CPU systems – this will help reduce confusion, and also allow Catalina to detect and report incompatible options.
  • Added proxy drivers for all HMI devices (keyboard, mouse and screen) as well as the SD Card on multi-CPU systems. This allows programs running on one CPU to use the HMI devices or SD card attached to another CPU. A proxy server program must be run on the CPU with the physical devices connected, and proxy drivers must be used on the client CPU. The use of these proxy drivers is documented in the Catalina Reference Manual.
  • Some of the TriBladeProp documentation (e.g. the README.TriBladeProp file in the target directory) was out of date and has been rewritten.
  • Fixed a problem in the keyboard support that could cause a program to read incorrect data from the keyboard, or crash.

New: Morpheus Text mode driver!

Saturday, December 12th, 2009

RossH was kind enough to port Chip’s high resolution VGA text driver to Morpheus!

This driver supports the following modes:

  • XGA 1024×768 with 128 characters by 64 lines
  • SVGA 800×600 with 100 characters by 50 lines
  • VGA 640×480 with 80 characters by 40 lines

The driver does NOT use XMM, and is ideal for running LMM Catalina text mode programs as fast as possible – which is why RossH ported it.
The driver is alsos the perfect companion for emulations such as ZiCog, MotoCog etc.

As usual, you can find the driver on the Downloads page.
Thanks Ross!


Catalina is coming to Morpheus Real Soon Now!

LCD Fix – new release of all existing Morpheus video drivers

Wednesday, December 2nd, 2009

Sorry for the recent lack of posts, I have been working on PropellerBasic :-)

Today I uploaded newer versions of the four released Morpheus video drivers, and of the Game of Life. This version should resolve compatibility issues with some LCD monitors.

In my lab, I test the drivers with a 19″ Viewsonic 1400×900 LCD, a 22″ Acer 1680×1050 monitor, and a 5″ 640×480 industrial OEM display.

The new drivers were a response to a compatability issue with the industrial OEM display – which will soon be available for sale here at Mikronauts!

60Hz VGA driver released

Thursday, October 29th, 2009

In case your monitor does not like the 69Hz vertical sync rate of my other 640×480 driver, I have created a 60Hz (actually 59.7Hz) driver.

This driver makes the graphics a bit faster, which never hurts :-)

You can find it on the Downloads page.

256 color per pixel 256×192 driver released!

Thursday, October 22nd, 2009


I have just uploaded the preliminary release of the 256 color per pixel 256×192 driver – you can find it on the Downloads page.

The driver uses XGA timing, and your monitor must support a 41Khz Hsync and 51Hz Vsync for you to be able to use the driver.

The following functions are currently supported in the new QXGA 256 driver:

PUB Config(drawscreenaddr,xres,yres,bitsperpix)
PUB WaitMS(n)
PUB PlotC(x,y,cl)
PUB Plot(x,y)
PUB Pen(c)
PUB Cls(c)
PUB Hline(xsrc,ysrc,xtwo)
PUB Line(x0,y0,x1,y1)
PUB DrawRect(x,y,w,h)
PUB FilledRect(x,y,w,h)
PUB DrawCircle(x,y,r)
PUB FilledCircle(x,y,r)

The following functions are present for compatibility with my other drivers, but they don’t do anything as this mode does not use palettes!

PUB SetPalette(y,c,r,g,b)
PUB SetPaletteRange(y1,y2,c,r,g,b)
PUB FillPalette(c,r,g,b)

The following functions are not available yet, I need to write a new pasm putchar routine:

PUB PutChar(xsrc,ysrc,ch)
PUB PutStr(xsrc,ysrc,strptr)
PUB PutBytes(xsrc,ysrc,bptr,bsiz)