Abstract - Amy Delman and Adiba Ishak

The importance of using robots in teaching CS1 has been noted, but the programming languages that have been devised for this purpose are limited. Languages such as NotQuiteC (NQC) or NoteXactlyC (NXC), while similar to C, do not have the structures needed to teach a full range of C++ in CS1. Furthermore, the environments for developing programs that have been developed (BrickOS with BricxCC) have no debugging capability nor do they contain a simulator, which is necessary if students wish to work on robot programming at home. Without these features, such environments are limited and cannot be effectively used to teach CS1 to students who are novices.

Here, we describe a system we developed, which consolidates a regular ANSI C/C++ compiler, debugger, and simulator and configured them within an open source integrated development environment (IDE) called Code::Blocks. A first iteration of the system used older Lego™ RCX robot and has been successfully used in teaching C/C++ to science and engineering students. One deficiency of the system was difficulty in controlling the outdated hardware. For example, the infra-red towers that are used to communicate with the robot are susceptible to noise and there is interference if one would like to control multiple robots or control robots in real time. The main contribution of this work was the development of a programming environment for beginning students to learn programming in C/C++ using the newer Lego TM  NXT robot., which has an up-to-date processor, more efficient hardware communication, and is easier to assemble. The challenge was to design a general purpose environment for developing and debugging C/C++ programs and a simulator for the NXT robot, which was not available as for the older Lego™ RCX robot. This was accomplished using Code::Blocks, and utilizing an open source firmware platform, nxtOSEK, a real-time system, devised for controlling the NXT robot.

Our testing of the system shows that the NXT and this environment are more reliable. The simulator that we developed is easy to use and was incorporated into the environment. We have also configured the system to run on a virtual computer (Sun VirtualBox), which has been configured for a wide range of platforms (Windows, MacOS, and Unix/Linux). More importantly, the system is pre-configured with an operating system and all the tools installed. The use of robots in CS1 is a highly motivating tool for learning to program, affords students the opportunity to learn sensory-motor based control, work with an integrated development environment (IDE) early in their careers, and gain experience with development and debugging tools that can be utilized throughout the students’ academic and professional  careers.

Supported by: NSF CCLI grant, Brooklyn College, PSC-CUNY grant 

printer friendly