Difference between revisions of "Exercise - Building a Complex Component"
From Flowcode Help
Jump to navigationJump to searchJohnVerrill (talk | contribs) |
JohnVerrill (talk | contribs) |
||
Line 61: | Line 61: | ||
* Drag and drop a cone onto System Panel. | * Drag and drop a cone onto System Panel. | ||
− | * Select it, and set its 'Position' co-ordinates to X=0, Y=-35, Z=0, | + | * Select it, and set its 'Position' co-ordinates to X=0, Y=-35, Z=0, 'Scale' to 'Wi...'=45, 'He...'=35, 'De...'=80 and 'Rotation' to X=-90, Y=0, Z=0. |
* Change its 'color' to red (e.g. 0x0000C0). | * Change its 'color' to red (e.g. 0x0000C0). |
Revision as of 13:00, 25 May 2013
This exercise shows how to create a traffic cone with a double flashing lamp, using the 'newLED' component.
- Open a new Flowcode flowchart.
- Ensure that the System Panel is visible. If not use the View menu.
- The following assumes that you have built, and exported a LED component, as described in Exercise - Create a LED component and Exercise - Exporting the LED component.
- Open the 'Outputs' toolbox, where you stored the exported 'newLED' component.
- Locate the 'newLED' component, and use the down-arrow next to it to add it to the System Panel.
- Click on the LED to select it. Change the 'color' property to orange (e.g. 0x0080FF).
- Using the Panel Properties, with the LED still selected, set its 'Position' to X=0, Y=0, Z=10, and its 'Scale' to 'Wi...'=1, 'He...'=1, 'De...'=0.25.
- The component should resemble the picture opposite, (depending on the 'camera' zoom.)
- Click on the head of the vertical arrow, (green), to rotate the camera to give an 'edge-on' view.
- The LED should still be selected. If not, click on it. Right-click and select the 'Copy' option. Then right-click and select the 'Paste' option.
- A second identical LED appears.
- Set its 'Position' co-ordinates to X=0, Y=0, Z=-10, and the 'Rotation' settings to X=0, Y=180, Z=0.
- The System panel should now resemble the one shown opposite:
- Drag and drop a cube onto the System Panel.
- Select it, and set its 'Position' co-ordinates to X=0, Y=0, Z=0, and 'Scale' to 'Wi...'=32, 'He...'=12, 'De...'=32.
- Change its 'color' property to mid-grey (e.g. 0x5A5A5A).
- The System Panel looks like:
- Drag across all three shapes and group them by clicking on the 'Group' icon.30px
- Notice that the 'Component Handle' and 'Type' have changed to 'Group'. Rename the 'Handle' as "flasher".
- Click on the head of the vertical arrow, (blue), to rotate the camera back to the 'head-on' view.
- Drag and drop a cone onto System Panel.
- Select it, and set its 'Position' co-ordinates to X=0, Y=-35, Z=0, 'Scale' to 'Wi...'=45, 'He...'=35, 'De...'=80 and 'Rotation' to X=-90, Y=0, Z=0.
- Change its 'color' to red (e.g. 0x0000C0).
- View it from different 'camera' directions by clicking on the heads of the red, green and blue arrows. It should resemble the picture shown below:
gen_exerciseBuildComplexComp_complex4_01.png gen_exerciseBuildComplexComp_complex5_01.png gen_exerciseBuildComplexComp_complex6_01.png