How to Program

how to program


1 Moving a chip

2 Chips on top of each other

3 Throwing away chips

4 Insert a chip in the middle of a program

5 Ditching the chip in the middle of the program

6 Copy/Paste Chip

7 Hide Chips

8 Download and run


Additional function


9.1 RogicEditor Open

9.1.1 Full Screen

9.1.2 Viewer Mode

9.1.3 Editor Mode

9.1.3.1 Saving rpj Files in Editor Mode

9.2 PrintScreen

9.3 Comment

1. Move the Chips

All chips move in the order of click - move - click.


Click to select the chip you want to program from the left menu, and then click again at the destination.

2. Attach the Chips

The user places the chips one by one and programs them in the order in which the robot will operate. At this time, each chip must be connected to each other. If it is not connected, it will not be downloaded. If the chip is connected correctly, will pop up between the chips.


If you take the delay chip over the DC Motor chip and click it, the DC Motor chip and the Delay chip are connected as shown in the picture above

3. Dispose the Chips

You can throw the chips you want to erase into the trash bin at the bottom left of the logic program. Click the chip you want to discard, and then click the trash bin, and the OK dialog box will appear. Click the OK button to delete the chip.


Alternatively, drag the chip you want to discard to select, and press the Delete key on the keyboard to delete the selected chip.

4. Inserting a chip in the middle of a program

If you click where you want to insert a new chip, it will automatically be inserted between the chips. Here is an example of inserting a DC Motor chip between Delay chips.


First, take the chip you want to insert (DC Motor Chip) to the location where you want to insert it.


When clicked at the location to insert, a new chip is inserted between the chips.

5. Disposing the chip in the middle of the program

To discard the chip in the middle, you must first select the chip you want to discard and then place it anywhere in the next space. You can then discard the chip in the middle by adding the chips on the bottom of the chip you want to discard back to the existing program. This is an example of discarding a delay chip in the middle of a program.


Let's throw away the first delay chip in the program on the left.


First, click on the chip you want to discard and move it. The chips that are connected below will also move together. Then, click on the appropriate location to move the chips.


After that, click again on the chips you don't want to delete to bring them back to where they were, and then click again to link them to an existing program. You can throw any remaining delay chips in the trash.

6. Copy/Paste the Chips


You can copy the chips that you set. Here is an example of copying a DC Motor chip. Right-click and drag to select the DC Motor chip. When the chip is selected, the color of the chip becomes darker than that of the unselected chip.


After confirming that the DC Motor chip is selected, press Ctrl+C to copy the selected chip. The copied chip follows the mouse cursor.


Copy chips are moved to the desired location and pasted. Chip copy allows you to select and copy multiple chips by dragging one chip as well as one chip.

Hide the chips

If you click the inverted triangle at the top left of the While, If Else, Function chip, as shown in the figure on the left, it hides all of the subchips it contains. If you click the triangle again, you will see all of the subchips it contains.

Download and Run the program

In order to download the created chip program to the robot, the cable must first be connected to the robot and then the robot must be powered on. Then, press the 'Download' button at the top right of the Rogic program. When the 'Download' button is pressed, the transmission status window will appear and the robot-written chip program will be sent from the PC. If sent correctly, a message box 'Download Complete!' will appear, as shown in the image below.



If the download does not complete successfully, refer to the Document when it does not.

▶Additional Features

_____________________________________________________________

9.1 RogicEditor Open

9.1.1 Full Screen

Save the file you are working on as an extension of the rpj, c, and Avr Studio projects.


Compile the currently working program to create a hex file.


Compile the currently working program and download it through the ISP board.


Change the currently working program to a logic chip and save it as an rpj file.


This is the list box that changes the Viewer/Editor mode.


Header file: A file in which a constant or function used in the source file is written.


Source file : The part where a program created by a chip in Viewer mode is displayed as a code, or a program is created in Editor mode.

_____________________________________________________________



9.1.2 Viewer Mode

Viewer mode changes a program created with a chip to a C language program in real time.

_____________________________________________________________



9.1.3 Editor Mode

 Editor mode is a mode that allows you to write C language programs directly in text.

<Caution> The program must be written between Start(); and end(); for normal operation.

If you enter text as shown above, you will see a list and description of the keywords in the C language and the constants or functions contained in "schoolkits.h".

For more information, see the C Language Manual document

_____________________________________________________________



9.1.3.1 Saving rpg Files in Editor Mode

1. Change the mode of RogicEditor to Editor.


2. Create a program.


3. Click Change to blocks to select a storage location and save it.

*Code in grammar that is incompatible with or does not support the Rogic chips will not be converted.


4. Open the saved file to verify that it has been successfully converted.


9.2 PrintScreen

A print preview window appears and outputs chip programs and comments.


 Print button : Prints a preview screen..

Zoom in and down buttons: Zoom in or out of the preview screen.

 Number of pages button : Sets the number of pages to be displayed on the preview screen.

 Close button : Close the print preview window.

9.3 Comment

Provides a memo function that allows you to enter comments and add additional comments.

Type a title for the comment and click the [confirm] button to create a memo.


 Click the M button to modify the title. Double-click the title to display a window where you can create a supplementary description.


Right-click on the title to display a dialog box asking if you want to delete it. Click the 'Yes' button to delete the comment you created.