Hands on with CodeWarrior Learning Edition 2.0

So, you want to learn to program your Mac. Indeed, this is laudable and potentially lucrative goal. But, how do you go about doing this without the expense and long hours of attending university? Metrowerks has given the hobbyist/student a useful and inexpensive tool with its CodeWarrior Learning Edition Version 2.0. This, coupled with Metrowerks' free online classes at CodeWarriorU.com, should give a dedicated student enough information to get started.

CodeWarrior Learning Edition 2.0 retails for about US$50 and comes as a Mac OS/Windows product. It requires a PowerPC 601 or later processor and at least Mac OS 8.6. Mac OS 9.0.4 or Mac OS 9.1 is recommended. CodeWarrior Learning Edition 2.0 will install CarbonLib 1.0.4 if you do not have it or a later version of the CarbonLib on your Mac.

Programming is a complex art, and anyone serious about it will need to dedicate a good deal of time to it. The CodeWarrior Learning Edition product is intended to expose beginning users to the CodeWarrior IDE (Integrated Development Environment) and allow them to have a powerful tool to work with as they learn. The Learning edition provides the full CodeWarrior IDE and allows you to begin learning to code in C, C++ and Java.

CodeWarrior Learning Edition is not intended to be a stand-alone programming instructor. It is intended to be a tool that fits with a class or book that provides programming instruction. Metrowerks offers free online programming classes at CodeWarriorU.com. Classes like Learn Programming with C or Introduction to Java use CodeWarrior Learning Edition or the full version of CodeWarrior for students to code with.

Over the past fifteen years or so, ease of programming a computer has given way to ease of use. The Mac's Graphical User Interface (GUI) can make programming more difficult to learn, as you will need to learn how to call the parts of the Mac OS that manage the GUI for your application to use it.

The Macintosh toolbox is the set of hard-wired commands and data that, say, draws a window or makes the mouse pointer look like it does. For a Mac application to look and work like a Mac application, you need to have your program call the toolbox.

The good news is that you will not need to learn the entirety of the Macintosh toolbox in order to begin coding with the CodeWarrior Learning Edition. Standard C, C++, Java and ~SIOUX consoles are provided which beginning users can include in their earliest programs. These consoles allow you to create programs that do things in a text only format -- which is far easier for beginning programmers than having to create windows and dialog boxes.

Using the console, budding coders can learn the absolute fundamentals of coding and the syntax of the language they are pursuing. Typical exercises include using the console to add numbers that have been asked for, find prime numbers or square roots and the ubiquitous "Hello World!!!" application -- where neophyte coders create a program that displays the text "Hello World!!!" in the console.

CodeWarrior Learning Edition 2.0 is a simplified version of the standard CodeWarrior tool. Projects created with the learning edition can have at most 32 project files, and the Learning Edition's compiler does not use the compiler optimizations that are used in the Professional CodeWarrior and the Learning Edition can only create applications. Essentially, you won't be able to make money with the Learning Edition unless you can write very small applications for fun and profit. But, you will be learning using the same IDE that professionals use.

This is one of the best features of CodeWarrior Learning Edition. Metrowerks provides the entirety of the CodeWarrior IDE within the Learning Edition. While you may not take full advantage of CodeWarrior's powerful set of development tools, it makes sense for students top be exposed to the whole CodeWarrior IDE. This ensures that they will have a great deal of experience with it as they move into more serious or professional coding positions.

The drawback to this is that compilers, linkers, debuggers and the whole CodeWarrior IDE can be overwhelming for beginning users. The CodeWarrior IDE can open up many more windows than the average Mac user is used to, and learning how to handle all of them can be frustrating for beginning users. The Learning Edition provides a getting started card that walks you through creating a "Hello World!!!" application. This should provide enough information for new users to understand that basic process of creating a console application -- their instructor or textbook should be able to guide them from there.

Another point to bring up is that CodeWarrior Learning Edition installs MacsBug to help you debug your, eventually, complex and subtle code. Unfortunately, users new to programming may not understand what this is. Whenever your Mac crashes, instead of freezing or a bomb dialog, it will drop into MacsBug. This is a very techy looking debugging application that allows you look at the memory of your Mac, even though the actual OS crashed. Accidentally dropping into MacsBug could terrify beginning Mac programmers who simply have a crash when browsing or doing something else other than learning to code. If this happens to you, don't fret. Hit ~ or ESC to get back to the crashed Mac OS and then restart the Mac. Or, explore MacsBug and then restart the Mac.

Metrowerks provides a great deal of documentation about their IDE. There is also a multimedia tutorial that helps users become accustomed to the IDE. However, there is no information on how to program provided. For this, students and hobbyists will need to take a class at CodeWarriorU.com or buy a book. Previous editions of the Learning Edition included a great deal of instructional information on learning how to program. However, it was not tailored to the CodeWarrior IDE, and could be frustrating for users. In my opinion, signing up for an online class at CodeWarriorU is one of the best ways to learn to program other than a college class.

CodeWarrior Learning edition is a good, inexpensive tool for learning how to program. It provides every tool you will need to do the job. However, it by itself will not teach you how to program. We have yet to get to the point of a CD in a box that will easily walk you through the arcana of coding. Nevertheless, if you are serious and dedicated, CodeWarrior Learning Edition 2.0, coupled with a class at CodeWarriorU.com or a good book, is probably the best way to learn how to program your Macintosh.

This story, "Hands on with CodeWarrior Learning Edition 2.0" was originally published by PCWorld.

Shop Tech Products at Amazon