de Crocodile Clips
Crocodile ICT es una potente herramienta para la enseñanza de la programación y el control. Una sencilla interfaz de diagramas de flujo permite escribir programas que controlan personajes humanos o animaciones en pantalla, facilitando el acceso a los complejos conceptos de programación.
Crocodile ICT's user-interface allows novice users to control the on-screen characters and animations. Simple flowcharts are used to give commands and define control routines, while the advanced programming commands read naturally. For example, when controlling one of the human characters, instead of the old command ‘walk left(3)’ you can now use ‘walk 3 steps to the left’.
It’s now easy to edit commands on-screen. Each part of the command 'walk 3 steps to the left' is editable on-screen, with ordered lists of the possible actions and parameters to choose from. The improved on-screen animations include ready-made animation sequences linked to specific actions - such as ‘open car park barrier’ or ‘turn on red traffic light’. This makes controlling the context animations a lot more intuitive, even for novice users.
Meet the humans
The human characters in Crocodile ICT can be used to teach control concepts - such as programs, variables and loops - in a very accessible way. The actions for these characters are programmed using the ‘Action’ command. Simply add this to your flowchart, link it to the human you want to control, and choose the action you want from the list. Some actions have simple parameters: for example, the direction the character walks in, or the number of times a dance step is repeated.
The human characters are engaging, and will interest all students - irrespective of their curiosity about systems and programming. Using these characters, you can introduce the concepts of writing logical command sequences, starting with simple flowcharts and moving on to more complex concepts. For example, the process of setting up a simple dance routine conceals a wealth of valuable programming experience. Choreographing the steps for a chorus is an ideal opportunity to introduce functions - which can be called repeatedly during the song routine.
You can use an event handler to start them both dancing at the same time: flowcharts can be started on the press of a button, or when the characters receive an instruction that has been throughout the whole scene. A recursive loop will let the characters dance right up to the edge of the stage - but checks that they don’t fall off. And a map variable is exactly what's required to store the words of the song.
The human characters offer many such opportunities to teach control in an involving and accessible way. One of the most frequent barriers for students learning abstract concepts - like those involved in good programming - is that most don’t feel a desire to learn the subject. Most students won’t instinctively see the use for programming. Using human characters in teaching ICT, however, introduces understandable goals, and involves even the most reluctant students - giving them an interesting reason to learn about control.
Program the characters using simple flowcharts. Commands are now written in simple english - such as 'walk 3 steps to the right'. A range of commands can be dragged onto the screen and linked with the mouse. Once they're in place, you can edit their properties by simply clicking on them.
- Defining variables and making decisions
Crocodile ICT lets you define a limitless range of variables. They can store inputs or outputs for your context, or be used to perform mathematical operations. The 'Set variable' command lets you assign a value to a variable, or relate it to another variable using a mathematical expression - for example, "y <-- x + 2". The 'Test variable' command lets you specify a condition, and change how your program flows depending on whether the outcome is true or false. You can compare a variable to a number, another variable or an expression, and use different comparison operators.
- Getting and setting on-screen properties
The parts in your context all have properties - such as position or orientation. The 'Get property' command reads these values. To define which part's property you want to get, simply drag a target symbol from the flowchart element to that part. Once the property has been assigned to a variable, you can change its value - for example, adding 10 to the x-position to move an on-screen image to the right. You can use these techniques to check the properties - such as position - of the human charaters as well. When combined with the Test Variable command, this lets you - for example - check if a moving part has reached the edge of the screen. The 'Set property' command takes a value - either a number or a variable - and sets a chosen on-screen property to equal that value. For example, you can set the x-position of your image to a new value, 10 higher than it was previously, to move it to the right by 10 pixels. Choosing the part whose properties you're setting is simple: as with Setting properties, you just drag a target symbol onto that part.
- Using functions
To simplify your program, you can use an unlimited number of functions. There are flowchart elements to define a function and to return to the main program, and also to call the function. Functions are programmed in the same way as the main program.
Setting up a loop is easy: simply draw a link from the bottom of the loop back to the start. This guides the program flow. You can define a variable to count how many times the loop has been executed, and increment it by 1 each time the loop runs. A conditional statement at the end can then decide when to break out of the loop.
Inputs and outputs
Crocodile ICT has customisable inputs and outputs, with accessible commands like 'open car park barrier'. The inputs and outputs are found in the 'Presentation' menu in the software, and also in the ready-made Lesson Kits.
Buttons can be used to start or control programs. We provide some standard images for your buttons, or you can import your own pictures - so they can look however you want.
- Text and number inputs
The 'Get property' flowchart command can be linked to the values of text and number inputs by simply dragging the target symbol onto them. After this is done, it will assign the value of that input to a variable.
- Text and number outputs
The same text and number parts can be used as outputs. By dragging a target symbol from a 'Set Property' command in the flowchart, the value of a variable can be sent to the text or number part. This value will then be displayed.
There's a range of animation sequences - such as opening a car park barrier, or turning on a fan. Each one is named in an understandable way - like 'turn on amber traffic light'. Each animation can hold a number of these sequences. When the 'Action' flowchart part is connected to an animation, it can be set to play any one of these sequences.
- Context Parts
The Context Parts found in the presentation section are a selection of animations and buttons that we've created for you to use. They go together with the background images we provide to make contexts for your programs to control. These contexts model a real-life situation, and you can customise them or create your own from scratch. In future versions, we're planning to add more contexts and context parts to Crocodile ICT.
Context animations give you different environments to control, and are customisable. They are environments in which you can run your program. You can control animated inputs and outputs using the flowcharts. In the latest version, we've made them much easier to use, with simple commands. You can place the animated inputs and outputs anywhere you like - you could even, for example, put traffic lights on the car park, or an intruder alarm in the greenhouse, if you wish. You can also modify our context parts, or create your own contexts from scratch.
Monitoring and debugging
Testing and debugging your program is easy - it runs on-screen in front of you, and errors are highlighted and explained. Crocodile ICT gives user-friendly feedback on construction errors, runtime errors and bugs. The software also offers a monitor box, to help you follow the program's flow.
- Feedback on construction errors
When you try to run your program, Crocodile ICT will tell you if a part is not connected properly. This helps you to see any fixes you need to make.
- Feedback on runtime errors
Even if everything is connected properly, the program may not run properly - for example, if you've forgotten to define a variable, as in the example below. Crocodile ICT gives feedback on these problems as the program runs.
- Monitoring program flow
The monitor box can be added to your program to let you monitor the values of variables in the program as it runs. This helps you to work out how to fix or improve your program if it's not giving the desired results. The 'Fast' control executes the statements as quickly as possible, whereas the 'slow' control runs the program step-by-step so you can see what's happening. The 'Pause' control lets you step through the program at your own pace.
- Other bugs
The Contexts in Crocodile ICT, and the inputs and outputs, give a highly visual and interactive environment which lets you check that your program is giving the desired results.
Crocodile ICT is much more flexible than most control programs, meaning you can investigate complex concepts like functions, map variables or mathematical algorithms. The software includes some more advanced tools to let you write more complex programs.
The Delay command lets you pause the program flow for a period of time. You can set how long you want the program to wait before moving on.
The Sound command plays a sound. You can either make a simple beep, or play a sound file of your choice from your computer.
Each part in Crocodile ICT has a popup associated with it. This is a small window which floats above the scene, and can contain all of the standard parts. You can use popups to hide your programs or subroutines, or to add notes about your programs.
- Send & Receive
The Send command transmits the value of a variable so that it can be read by other programs in the scene. The Receive command listens for these transmitted values from other programs, and when it finds one assigns that value to a new variable of its own.
- Scene variables
The scene is the overall area that you're working with. A Crocodile ICT file can contain several scenes, and you can make links between them. Normally, variables are only valid within one program. However, the Scene Variables part allows you to define global variables that are available to all programs running in your scene.
- Test bit
The Test Bit command makes decisions based on the condition of a certain bit of a variable, when expressed in binary form. For example, the binary equivalent of the variable “x”, decimal number 7, is 0111, which has bit 3 off and bits 2, 1 and 0 on. So the test “x has bit 2 on?” would return a “yes” answer, while “x has bit 3 on?” would return a “no” answer.