Shop OBEX P1 Docs P2 Docs Learn Events
Run up to 2MB C programs on your Propeller with FlashPoint and Catalina! — Parallax Forums

Run up to 2MB C programs on your Propeller with FlashPoint and Catalina!

RaymanRayman Posts: 14,865
edited 2011-10-18 20:37 in Propeller 1
The free ANSI C compiler, Catalina, now supports the low-cost Rayslogic.com memory modules, FlashPoint SuperQuad and FlashPoint RamPage as of version 3.3. This allows you to run C code up to 2 Megabytes in size on your Propeller. All you need is six free pins for SuperQuad or eight free pins for RamPage.

A guide to using Catalina with FlashPoint is complete.

The "LARGE" Star Trek example really shows the capabilities of Catalina combined with RamPage.
Catalina seemlessly integrates keyboard, SD card and VGA to form what is essentially an OS for the program to run in.
Here's a screen shot of this program running on a VGA monitor:
sst.jpg


Another great thing about programming in ANSI C is that you can compile the exact same code with the free version of Visual Studio and debug/run on your PC before compiling for the Propeller...
1024 x 768 - 47K
sst.jpg 47.3K

Comments

  • RaymanRayman Posts: 14,865
    edited 2011-10-14 13:57
    BTW: The guide may also be very helpful if you don't have a Flashpoint module, but want a quick guide to getting started with Catalina.

    There's a step-by-step guide to installation and running a "tiny" example that should run on most Propeller setups.
  • RossHRossH Posts: 5,516
    edited 2011-10-14 14:37
    Good stuff, Ray. I may pinch some of your "quick quide" for incorporation into the next release!

    Ross.
  • Cluso99Cluso99 Posts: 18,069
    edited 2011-10-14 15:08
    Rayman: Nice work Ray. This is exactly what I was looking for to just get the serial terminal working. It is exactly what I normally do when testing out a new board (as I suppose you do too). You dont require any other hardware that way. And it is great for someone breadboarding a new prop system.

    BTW I noticed this error in your writeup "These examples can be ran without a FlashPoint module, because they are tiny. Let's get our feet wet by running the "test_suite" example. We using this example ..."

    Now, off to test this today!
  • RaymanRayman Posts: 14,865
    edited 2011-10-14 15:39
    Thanks Cluso. I suppose I should have actually proof-read before posting...
  • RaymanRayman Posts: 14,865
    edited 2011-10-14 15:44
    Ross, you have my permission to use any thing there for Catalina.
  • Cluso99Cluso99 Posts: 18,069
    edited 2011-10-14 16:04
    Ray: Just ran through your writeup with my board and great, it works nicely!

    Where you say...
    Now, the left window should show a tree with "test_suite" at the top and "Release" under it and highlighted. Unfortunately, this window always comes up with "Release" selected, but it's better if we select all our build options with "test_suite" selected. You can see that no options are selected under "Release". Now, click on "test_suite" in the left window and you'll see the same options, but now "libc" and "TINY" are selected.

    Mine came up with "test_suite" but that may be because I already ran Code::Blocks last night.

    Where you say...

    Optionally, especially if you intend to use the Propeller Serial Terminal to view the output, you might want to also scroll down and select the "Enable automatic CR on LF (on output)" option. Otherwise the text won't show up exactly right on the terminal.

    You may want to add "Now click OK to accept these parameters and close this window."

    When the program completes, it reboots whatever is stored in the EEPROM. I received some interesting QUadCopter code results ;)

    You may want to add a section to now download to EEPROM (dont forget to advise it will take some time like 20s because I initially thought it had locked up). The use PST and select DTR to reboot.

    This is a really neat instructional. Thanks!
  • RaymanRayman Posts: 14,865
    edited 2011-10-14 17:15
    Thanks for testing it out Cluso, glad it worked.

    Strange that your CodeBlocks selects "test_suite" instead of "release" in the Build Options window...
    I've installed on 2 PCs and they both always come up with "release". Maybe there's some setting I'm not seeing...

    I'll add notes regarding your other findings.
  • RaymanRayman Posts: 14,865
    edited 2011-10-15 06:03
    Ok, I've installed Catalina on a third PC and I think I see what's going on with the "Build Options"...
    The very first time you run CodeBlocks, before you build anything, it will show build settings for, e.g., the "test_suite" project root of the tree.
    But, after you build, it will then always show with build settings for "Release".
    I think it's writing something to the registry to save this setting, but not 100% sure.
    Anyway, this is a very unfortunate "feature" of CodeBlocks and it's easy to make a mistake there, if you're not careful.

    I think perhaps it might be better to have all settings under "Release" and also select "Use target options only".
    But, this is a problem now because all the examples come with settings set in the project, not the target.
  • prof_brainoprof_braino Posts: 4,313
    edited 2011-10-15 09:15
    Very cool!

    Can this be used with a regular flash module, like an SD card?
  • RaymanRayman Posts: 14,865
    edited 2011-10-15 09:43
    Catalina inherently supports the SD card for file I/O.

    You cannot use the SD as expanded system memory though.
    (But, a few of us have asked Ross to look into that option and it may come one day).
  • Cluso99Cluso99 Posts: 18,069
    edited 2011-10-15 16:00
    Ray: If you wrote new memory drivers to use a preallocated section of the SD card (like we do on ZiCog/CPM for the disk drives), you could fool Catalina and remove the requirement for Ross to do it.
  • RossHRossH Posts: 5,516
    edited 2011-10-15 16:04
    Cluso99 wrote: »
    Ray: If you wrote new memory drivers to use a preallocated section of the SD card (like we do on ZiCog/CPM for the disk drives), you could fool Catalina and remove the requirement for Ross to do it.
    Happy for someone else to do it! Just preallocate a contiguous "swap" file in a fixed location.

    Ross.
  • RaymanRayman Posts: 14,865
    edited 2011-10-15 16:29
    I think running off of SD is a nice idea and would open up a lot of people to "small" mode with existing setups.
    But, right now, I'm concentrating on getting Flashpoint with Catalina understood and written up...
  • RaymanRayman Posts: 14,865
    edited 2011-10-17 18:50
    Finally finished the guide for running an XMM program (Super Star Trek) with CodeBlocks, Catalina and FlashPoint:

    http://www.rayslogic.com/Propeller/Products/FlashPoint/Catalina/Catalina_FlashPoint.htm
  • RossHRossH Posts: 5,516
    edited 2011-10-17 19:14
    Very nice, Rayman!

    If you come up with a "definitive" set of Flashpoint configuration files, just let me know and I will include them in the next release. The set I included (as you pointed out) is for the C3, and the C3 always needs a lot of special configuration.

    It is very unlikely anyone except me would ever use the C3 with a FlashPoint module, so I'm happy to include more "generic" set of files.

    Ross.
  • RaymanRayman Posts: 14,865
    edited 2011-10-18 19:05
    Ross, thanks, I think those files are as close to a "definite set" as I can make right now. So, if you could use them in the next version, that would be great.

    BTW: I just finished a guide to running the "LARGE" Super Star Trek example, sst, with RamPage:
    http://www.rayslogic.com/Propeller/Products/FlashPoint/Catalina/Catalina_Large.htm

    Maybe tomorrow I'll get around to trying out that Toledo confuscated chess program...
  • RossHRossH Posts: 5,516
    edited 2011-10-18 20:37
    Rayman wrote: »
    Ross, thanks, I think those files are as close to a "definite set" as I can make right now. So, if you could use them in the next version, that would be great.

    BTW: I just finished a guide to running the "LARGE" Super Star Trek example, sst, with RamPage:
    http://www.rayslogic.com/Propeller/Products/FlashPoint/Catalina/Catalina_Large.htm

    Maybe tomorrow I'll get around to trying out that Toledo confuscated chess program...

    Great. Are these files specifically for the "Gadget Gangster" board with a FlashPoint module attached? I've been thinking about getting one of those boards, so I'd be able to support this platform better.

    Ross.

    EDIT: What, you don't like my "green on green" color scheme???? Bah!
Sign In or Register to comment.