My son has one to encourage exploration and for use as an augmentative comm device. My wife has one to preview some apps and books for him. I refuse to drink that brand of kool aid. They are great devices if you can accept apples my way or no way (highway not optional) approach to ipad use and apps. Want to save video you just shot to jump drive? Save a file to same or worse read one like a file system ? You get to experience the NO way! Just waiting for the right pad to evolve.........
Has anyone run Catalina under Mac OS X recently? Any tips on building it? I got LCC to build but I had trouble getting the catalina driver program to build. I'll have to look at it more closely later. I just wondered if anyone else had tried and had any advice.
With a little fooling around I got everything except payload to compile on the Mac. I'm now trying to build the demos. If I run the build_all script in the demos folder I get lots of instances of this error:
Catalina Compiler 3.4
lcc: fatal error in /Users/dbetz/Catalina_3.4/bin/rcc
With a little fooling around I got everything except payload to compile on the Mac. I'm now trying to build the demos. If I run the build_all script in the demos folder I get lots of instances of this error:
Catalina Compiler 3.4
lcc: fatal error in /Users/dbetz/Catalina_3.4/bin/rcc
Any idea what might be causing this?
Hi David,
One of the 2.X releases was built on OS/X - but I now no longer remember who built it, and I never heard any more about it.
Also, remember that LCC supports other targets. To test out LCC independently of the Catlaina components, try a command like:
lcc -target=x86/linux hello_world.c -v -c
Note 1: the assembly language output will be put in hello_world.obj (remember that Catalina uses assembly language as its object format).
Note 2: you need the -c flag as there is no assembler, linker or libraries provided for any target other than the Propeller - but this command will at least test out the lcc, cpp and rcc components. Once you have those working I can help you with the Catalina components.
One of the 2.X releases was built on OS/X - but I now no longer remember who built it, and I never heard any more about it.
Also, remember that LCC supports other targets. To test out LCC independently of the Catlaina components, try a command like:
lcc -target=x86/linux hello_world.c -v -c
Note 1: the assembly language output will be put in hello_world.obj (remember that Catalina uses assembly language as its object format).
Note 2: you need the -c flag as there is no assembler, linker or libraries provided for any target other than the Propeller - but this command will at least test out the lcc, cpp and rcc components. Once you have those working I can help you with the Catalina components.
Ross.
I guess I'm in trouble because lcc even failed generating x86 code. Here is the output I got from the command line you suggested:
lcc: fatal error in /Users/dbetz/Catalina_3.4/bin/rcc
...
Yup - that looks bad. Run it under gdb and trap any exceptions - it's probably a memory violation or something. If you can narrow it down to a particular line of code (or library function call) then I'll take a look and see if I can think of anything.
Is it possible that my problems running on the Mac have to do with the fact that the Mac is running a 64 bit compiler? Is there anything special that needs to be done to LCC to run in 64 bits?
Is it possible that my problems running on the Mac have to do with the fact that the Mac is running a 64 bit compiler? Is there anything special that needs to be done to LCC to run in 64 bits?
Hi David,
I doub it. But if you are using gcc, just tell it to compiler the program in 32 bit mode. Can't remember the exact option - maybe -m32?
I downloaded Catalina 3.4 for some testing. The InnoIDE installer does a nice job - I use it too.
Some comments, then a question: Codeblocks makes Catalina look more attractive. Good job.
I selected the C3 and Tiny mode, did a build, and hub download.
After 1 minute 15 second download, I finally see the traditional greeting on my TV.
Question:
I almost never use TV, so I set the build options to select PC expecting to use a serial terminal.
How do I open a serial port to work with that?
That helped. Somehow the baud-rate got set to 57600 though - no idea how that happened.
There are only a few ways to avoid needing to use an extra terminal window.
Built into the loader seems easiest and let's you see all output without struggling.
Guess I'm forced to use TV for some things for now especially since I can't modify some code.
After 1 minute 15 second download, I finally see the traditional greeting on my TV.
... and ...
There are only a few ways to avoid needing to use an extra terminal window.
TINY programs don't need a special loader. They can be downloaded with Propellent, or with the Parallax Spin tool if you prefer. Or, if you prefer a downloader that comes combined with a terminal emulator, use PropTerm (compile your program with -D PROPTERM).
I think I may have a problem with dynamic memory management in this version of Catalina. Not sure exactly which version the bug crept in, but it will only affect programs that use malloc() etc.
I need to do some more investigating. I'll post an update when I know more.
I think I may have a problem with dynamic memory management in this version of Catalina. Not sure exactly which version the bug crept in, but it will only affect programs that use malloc() etc.
I need to do some more investigating. I'll post an update when I know more.
Ross.
Ok - on further investigation it appears I was just running out of memory
I'm working on some code generaotr optimizations to allow Catalina to squeeze more C code into Hub RAM, and I think I just miscalculated. Sorry for the false alarm!
I need to be able to define preprocessor symbols on the Catalina command line and it doesn't seem that -D does what I expect. How do I define the symbol PROPELLER_CAT such that I can use the following conditional code in my C files?
#ifdef PROPELLER_CAT
// stuff that is only used for Catalina compiles.
#endif
I need to be able to define preprocessor symbols on the Catalina command line and it doesn't seem that -D does what I expect. How do I define the symbol PROPELLER_CAT such that I can use the following conditional code in my C files?
#ifdef PROPELLER_CAT
// stuff that is only used for Catalina compiles.
#endif
I tried this and it didn't work:
catalina -c -DPROPELLER_CAT my_file.c
Never mind. I figured it out. For Catalina, I need -W-DPROPELLER_CAT rather than just -DPROPELLER_CAT. While this works it is different than every other C compiler I have ever used.
Never mind. I figured it out. For Catalina, I need -W-DPROPELLER_CAT rather than just -DPROPELLER_CAT. While this works it is different than every other C compiler I have ever used.
Hi David,
Yes, I had the choice of using -D for PASM symbols or for C symbols (there are various technical reasons why I didn't want the same flag to define a symbol for both). I suppose I could revert to using -D for C symbols and use another flag for PASM symbols.
It seems a minor point, but if there is enough opinion one way or another it is easy to change. It seems to me that not many people use the command line anyway. You and I are probably the last of a dying breed
Yes, I had the choice of using -D for PASM symbols or for C symbols (there are various technical reasons why I didn't want the same flag to define a symbol for both). I suppose I could revert to using -D for C symbols and use another flag for PASM symbols.
It seems a minor point, but if there is enough opinion one way or another it is easy to change. It seems to me that not many people use the command line anyway. You and I are probably the last of a dying breed
Ross.
It certainly isn't a blocking issue but I will say that I ran into this the last time I used Catalina as well. It's hard to break the habit of assuming -D can be used for C defines like most other C compilers allow. Keeping it this way may cause minor startup problems for people who want to port C code from another platform if the code uses conditional compilation.
Wouldn't you still have this problem with the GUI? When I use Xcode or Visual C++ I often use conditional compilation and have to define symbols for the compile. Does the Code::Blocks GUI automatically supply the needed -W in front of any definitions that the user asks for?
Wouldn't you still have this problem with the GUI? When I use Xcode or Visual C++ I often use conditional compilation and have to define symbols for the compile. Does the Code::Blocks GUI automatically supply the needed -W in front of any definitions that the user asks for?
Yes - adding <symbol> in the #define tab in Code::Blocks defines a C symbol as you would expect. If you ever need to add a PASMsymbol you must specify -D<symbol> on the other options tab - but since Catalina is integrated fully in Code::Blocks, you hardly ever need to do this (you just select the appropriate build option instead).
So using -D vs -W-D to define a C symbol really only affects command line users. My only hesitation in changing it is the amount of places I need to update documentation :frown: - but if I get one more request for this change then I will do so for the next release
Oh boy, I guess I just need to create another forum account and make another request! :-)
Blast! I obviously need to be more specific - I'll do it if I get "one more request from a person registered on these forums prior to 2/11/2011 who sends me a certified extract of their birth certificate and who is unrelated to David Betz"
Ross, I wouldn't spend any time updating command line stuff. The GUI is great, I'd focus on that.
Command-line people are used to suffering anyway...
I don't feel as though using command line tools is suffering. They offer far more flexiblity than GUI tools. Pretty much every company I've ever worked for built their systems using command line tools. Do you think Microsoft uses Visual Studio to build Windows? Is Linux built using a GUI? I doubt that Mac OS X is. Command line tools are still used by many people for important work. They aren't just a relic of the past.
Comments
Guilty as charged. My kids don't know what to do with a ">" prompt. They just tell me to get online and buy them an ipad touch.
Obviously they don't frequent your workshop much if they don't know what an ">" means!
I need to get the kids to learn C
Frank
Sorry to deviate...
Thanks,
David
Hi David,
One of the 2.X releases was built on OS/X - but I now no longer remember who built it, and I never heard any more about it.
Also, remember that LCC supports other targets. To test out LCC independently of the Catlaina components, try a command like:
Note 1: the assembly language output will be put in hello_world.obj (remember that Catalina uses assembly language as its object format).
Note 2: you need the -c flag as there is no assembler, linker or libraries provided for any target other than the Propeller - but this command will at least test out the lcc, cpp and rcc components. Once you have those working I can help you with the Catalina components.
Ross.
Hi David,
rcc is the actual compiler - the various code generators (including Catalina's) are just part of it.
lcc is really just a wrapper program that marshalls all the arguments to rcc and then invokes it.
Similarly, catalina is really just a wrapper program that marshalls all the arguments to lcc and then invokes it.
Ross.
I guess I'm in trouble because lcc even failed generating x86 code. Here is the output I got from the command line you suggested:
Yup - that looks bad. Run it under gdb and trap any exceptions - it's probably a memory violation or something. If you can narrow it down to a particular line of code (or library function call) then I'll take a look and see if I can think of anything.
Ross.
Hi David,
I doub it. But if you are using gcc, just tell it to compiler the program in 32 bit mode. Can't remember the exact option - maybe -m32?
Ross.
Some comments, then a question: Codeblocks makes Catalina look more attractive. Good job.
I selected the C3 and Tiny mode, did a build, and hub download.
After 1 minute 15 second download, I finally see the traditional greeting on my TV.
Question:
I almost never use TV, so I set the build options to select PC expecting to use a serial terminal.
How do I open a serial port to work with that?
http://www.rayslogic.com/Propeller/Products/FlashPoint/Catalina/Catalina_InstallGuide.htm
Rayman this <test_suite> program works nicely with my demoboard ( in fact I have no large memory board)
Hope some other simple programs for beginners.
For leds , servos or ping ?
I used Arduino before because it comes with a lot of small programs and explanations.
Jean Paul
That helped. Somehow the baud-rate got set to 57600 though - no idea how that happened.
There are only a few ways to avoid needing to use an extra terminal window.
Built into the loader seems easiest and let's you see all output without struggling.
Guess I'm forced to use TV for some things for now especially since I can't modify some code.
TINY programs don't need a special loader. They can be downloaded with Propellent, or with the Parallax Spin tool if you prefer. Or, if you prefer a downloader that comes combined with a terminal emulator, use PropTerm (compile your program with -D PROPTERM).
Ross.
Just a heads up!
I think I may have a problem with dynamic memory management in this version of Catalina. Not sure exactly which version the bug crept in, but it will only affect programs that use malloc() etc.
I need to do some more investigating. I'll post an update when I know more.
Ross.
Ok - on further investigation it appears I was just running out of memory
I'm working on some code generaotr optimizations to allow Catalina to squeeze more C code into Hub RAM, and I think I just miscalculated. Sorry for the false alarm!
Ross.
I tried this and it didn't work:
Hi David,
Yes, I had the choice of using -D for PASM symbols or for C symbols (there are various technical reasons why I didn't want the same flag to define a symbol for both). I suppose I could revert to using -D for C symbols and use another flag for PASM symbols.
It seems a minor point, but if there is enough opinion one way or another it is easy to change. It seems to me that not many people use the command line anyway. You and I are probably the last of a dying breed
Ross.
Wouldn't you still have this problem with the GUI? When I use Xcode or Visual C++ I often use conditional compilation and have to define symbols for the compile. Does the Code::Blocks GUI automatically supply the needed -W in front of any definitions that the user asks for?
Yes - adding <symbol> in the #define tab in Code::Blocks defines a C symbol as you would expect. If you ever need to add a PASM symbol you must specify -D<symbol> on the other options tab - but since Catalina is integrated fully in Code::Blocks, you hardly ever need to do this (you just select the appropriate build option instead).
So using -D vs -W-D to define a C symbol really only affects command line users. My only hesitation in changing it is the amount of places I need to update documentation :frown: - but if I get one more request for this change then I will do so for the next release
Ross.
Blast! I obviously need to be more specific - I'll do it if I get "one more request from a person registered on these forums prior to 2/11/2011 who sends me a certified extract of their birth certificate and who is unrelated to David Betz"
Ross.
Command-line people are used to suffering anyway...