77
Robonova-1 Instruction Manual v2.0 Written by Meena Seralathan

Robonova-1 Instruction Manual v2.0

Embed Size (px)

DESCRIPTION

Written by Meena Seralathan. Robonova-1 Instruction Manual v2.0. Overview. - PowerPoint PPT Presentation

Citation preview

Page 1: Robonova-1 Instruction Manual v2.0

Robonova-1 Instruction Manual v2.0

Written by Meena Seralathan

Page 2: Robonova-1 Instruction Manual v2.0

Overview

• The Robonova-1 is a humanoid robot able to execute a number of pre-programmed moves, as well as execute new moves through use of the RoboBASIC programming language, and the RoboBASIC’s catch-and-play feature, which allows for real-time recording of servo positions for even simpler routine coding. While there are also a program designed for emulating the remote control (roboRemocon) and a program designed to be a version of RoboBASIC that is coded more like a script and less like a program(roboScript), it is generally easier to program in the RoboBASIC program.

Page 3: Robonova-1 Instruction Manual v2.0

What the Robonova-1 Comes With

• 16 servos• MR-C3024 controller board• 5-cell NiMH rechargeable battery and charger• IR sensor on head for use with included remote control• 8 AD ports• PIEZO speaker for basic sound capabilities• CD with RoboBASIC, roboRemocon, and roboScript (all v2.5)

for programming the robot’s moves; also comes with code demonstrating various movements the Robonova-1 can do, such as walking, sitting, and punching, and an instruction PDF (in English, Japanese, or Korean)

Page 4: Robonova-1 Instruction Manual v2.0

What the Robonova-1 Can Be Modified To Have

• Up to 8 additional servos• Touch Sensors• Sound Sensors• IR Sensors• Sonar Sensors• Light Sensors• Tilt Sensors• Accelerometer• Gyro• Gripper Hands (to replace hands included with robot)• Camera• Different-colored head/brackets

Page 5: Robonova-1 Instruction Manual v2.0

List of Actions Included with the Robonova-1

• Standard Pose

• Sit

• Bend

• Raise hands

• Left/Right/Front punch

• Tumble forward/backward

• Cartwheel left/right

• Turn left/right

• Step forward/backward/left/right

• Stand up (useful if the robot falls on its back or its stomach)

• Left/Right kick

• Left/Right hand attack

• Fast walk

• “Fly”

• Handstand

• Dance

Page 6: Robonova-1 Instruction Manual v2.0

How to program the Robonova-1 The Robonova-1 does not come with a board that is easily programmable in any language other than its

provided language, RoboBASIC. The firmware on the robot is specially designed to work with this language (not even normal BASIC), and programming in another language would essentially require wiping the board and creating one's own code for the board to read in the language of choice. Thus there are mainly two methods of programming the robot:

Using the included interfaces and language

Using another board with better language compatibility as a master board, and then using this board to send signals to the robot’s board

First, this manual will deal with RoboBASIC and how to use it to program simple and not-so-simple routines. Then it will provide a general method of controlling the Robonova-1 with another board.

NOTE: This manual assumes you have a 3000-series board,. Though the parameters and general concepts provided in this manual will work with the 2000-series, some of the functions have different names (especially in the sound and serial communications categories). If working with the 2000-series, refer to the .pdf file provided with your hardware to make sure you are using the right names for your commands.

NOTE: This program was meant to be used under Windows, and is designed to work with Windows 98, ME, 2000, or XP. Using this with Vista will give you errors, and the program cannot be (easily) installed on Mac or Linux systems. If working under Vista, go to the Appendix to find out a fix to the incompatibility issue.

Page 7: Robonova-1 Instruction Manual v2.0

Initializing Your Robonova-1• In order to start your first

program, you need to first make sure your robot is properly connected to your computer. Make sure you follow this procedure before attempting to program the Robonova-1. You should not have to do this again, unless you reinstall the software.

• (1) Connect the provided serial cable to the robot and to the correct port on your computer. Turn the robot on.

• (2) Open RoboBASICv2.5. Go to Set -> Controller Type. Make sure the selected controller is the right one for your robot.

• (3) Go to Set ->Set Port. Make sure Com Port (Serial Type) is selected in the Port box.

• (4) Find out what COM port the serial cable is connected to. If you do not know how to do this, refer to the Appendix at the end of this manual.

• (5) Select the correct COM port in the drop-down box next to Port No. You can leave the rest of the information alone for now.

• (6) Now go to Controller -> Controller Information. Make sure your robot is connected and on; if it is not, you will probably receive an error code of -4 (-4 generally means the robot is not connected to the computer). You should see a window that displays a variety of information. If you get a window with no information, this means your computer is not properly connected to the robot. Check the cable again, and make sure the robot is on and running.

• (7) If all went well and you saw information in the text windows, then you’re set!

Page 8: Robonova-1 Instruction Manual v2.0

Using RoboBASIC v2.5

Page 9: Robonova-1 Instruction Manual v2.0

A Snapshot of RoboBASIC v2.5

Page 10: Robonova-1 Instruction Manual v2.0

Overview of RoboBASIC

RoboBASIC is the only program of the three where users code in a traditional-looking environment. RoboBASIC is also the main program to use with the Robonova-1’s catch-and-play features.

Page 11: Robonova-1 Instruction Manual v2.0

Using RoboBASIC• The buttons in the toolbar that you

will use most are the Download and the Run All buttons. These are the second and third encircled buttons, respectively. Download will send the code to the robot, while Run All will execute it once on the robot. Both options will automatically compile the code before sending it to the robot.

• If you prefer, you can also compile the code separately using the Make Object Code button (first encircled button).

Page 12: Robonova-1 Instruction Manual v2.0

More on Using RoboBASIC• These three buttons are shortcuts to

the text menu choices. Starting from the left, they are:

• Controller Information (which you should already know something about)

• Servo Motor Real-Time Control (used for the catch-and-play feature, and discussed later in this manual)

• Direct Line Control (used to execute a single line of code; only for OUT, MOVE, SERVO, POS, MOVEPOS commands).

Page 13: Robonova-1 Instruction Manual v2.0

Even More on Using RoboBASIC• These are more shortcuts, dealing more

specifically with the robot controller. Starting from the left, they are:

• Clear Memory (this should clear any old programs off the robot’s memory; useful for when the robot starts accidentally running old code)

• Controller Reset Mode (should reset the board back to its factory defaults; may require re-initializing board, and should clear everything done to the board after receiving it)

• Controller Run Mode (have not actually used this command)

• Controller Stop Mode (this one either)• ROBONOVA (or this one)

Page 14: Robonova-1 Instruction Manual v2.0

A Glimpse of RoboBASIC

Writing Code for a Single Action

Page 15: Robonova-1 Instruction Manual v2.0

Writing Code for a Single Action

• On the right is an example of what roboBASIC code looks like. This code tells the robot to move to its standard position. Before giving a more detailed explanation of how to program using this language, we will explain what this code block does.

GETMOTORSET G24, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0

SPEED 5

MOTOR G24

MOVE G6A,100, 76, 145, 93, 100, 100

MOVE G6D,100, 76, 145, 93, 100, 100

MOVE G6B,100, 30, 80, 100, 100, 100

MOVE G6C,100, 30, 80, 100, 100, 100

WAIT

Page 16: Robonova-1 Instruction Manual v2.0

Writing Code for a Single Action• This command is used to read the

position of a set of servos, and to then set the servo positions. In this line, GETMOTORSET reads the positions of all servos (G24 refers to all servos under the control of the board), and then sets each to the values listed after G24. A “1” tells the Robonova-1 to keep the position of the servo as-is, while a “0” tells the Robonova-1 to change the servo to its initial position. It is best to put this at the beginning of all programs, because it sets the servos to positions that will ensure that it starts moving safely.

GETMOTORSET G24, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0

Page 17: Robonova-1 Instruction Manual v2.0

Writing Code for a Single Action

• This command is rather straightforward; it sets the speed of the servo movement. The higher the value after SPEED, the faster the robot will move. Values can range between 1 and 20, but it is best to keep most movements at 10 or lower for stability (any value higher than 15 is likely to cause problems with an unmodded robot). For very fast movements there is a HIGHSPEED command, which will be touched on later.

SPEED 5

Page 18: Robonova-1 Instruction Manual v2.0

Writing Code for a Single Action

• This command turns on the output port of the specified servo set (in this case, all of them). In other words, it opens the servo ports so that your code can talk to the servos and tell them to move. If planning on having all body parts of the robot move during your routine, this is a must-have piece of code at the beginning of the file.

MOTOR G24

Page 19: Robonova-1 Instruction Manual v2.0

Writing Code for a Single Action

• These lines are what actually move the Robonova-1. The command MOVE is followed by the set of servos you want to move (more info about what G6A, etc mean on the next slide).

• 100 is the initial value for servo positions; values above 100 move the servos clockwise, while values below 100 move the servos anti-clockwise.

MOVE G6A,100, 76, 145, 93, 100, 100MOVE G6D,100, 76, 145, 93, 100, 100MOVE G6B,100, 30, 80, 100, 100, 100MOVE G6C,100, 30, 80, 100, 100, 100

Page 20: Robonova-1 Instruction Manual v2.0

Writing Code for a Single Action

• Besides the group G24, there are 4 subsets of servos that one can concentrate on. Each set can control six servos at a time.

• A: Servos 0-5

• B: Servos 6-11

• C: Servos 12-17

• D: Servos 18-23

Page 21: Robonova-1 Instruction Manual v2.0

Writing Code for a Single Action

To the right is a diagram to show what servo corresponds to what number in the motor group. As you can see:

• Group A mostly controls the left leg

• Group B mostly controls the left arm

• Group C mostly controls the right arm

• Group D mostly controls the right leg

Page 22: Robonova-1 Instruction Manual v2.0

Writing Code for a Single Action

• Last but not least is the WAIT command. This command tells the servos to wait until every specified motor set has finished moving before going onto whatever code comes after the movement. This is particularly useful if you plan on having multiple movements in one routine.

WAIT

Page 23: Robonova-1 Instruction Manual v2.0

A Glimpse of RoboBASIC

Using Multiple Commands in a Single Program

Page 24: Robonova-1 Instruction Manual v2.0

Using Multiple Commands in a Single Program

• There are ways to program the Robonova-1 to execute multiple movements in succession, as well as ways to program it to loop through commands, or to read input from the remote control and act accordingly. Each will be described briefly.

Page 25: Robonova-1 Instruction Manual v2.0

Programming a Chain of Movements

• This program will cause the robot to move to its standard pose, take a bow, then return to its standard pose. Putting a quotation mark before a line is how one comments out a line of code. As you can see, having one move succeed another is as easy as putting the new servo values after the previous move.

GETMOTORSET G24, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0SPEED 5MOTOR G24

‘standard poseMOVE G6A,100, 76, 145, 93, 100, 100MOVE G6D,100, 76, 145, 93, 100, 100MOVE G6B,100, 30, 80, 100, 100, 100MOVE G6C,100, 30, 80, 100, 100, 100WAIT

‘bendSPEED 8MOVE G6A, 100, 58, 135, 160, 100, 100MOVE G6D, 100, 58, 135, 160, 100, 100MOVE G6B, 100, 30, 80, , , ,MOVE G6C, 100, 30, 80, , , ,WAIT

‘standard poseMOVE G6A,100, 76, 145, 93, 100, 100MOVE G6D,100, 76, 145, 93, 100, 100MOVE G6B,100, 30, 80, 100, 100, 100MOVE G6C,100, 30, 80, 100, 100, 100WAIT

Page 26: Robonova-1 Instruction Manual v2.0

Using For Loops, If Statements• For loops and if statements are included in

RoboBASIC and are similar to their BASIC parallels.

• For the interval in the for loop one has to take a predefined variable (in this case, I), set it to an initial value (0), and choose a value to increase the initial value to (10). The end of the for loop is signified by the NEXT command.

• For the if statement, one chooses a predefined variable with a value (X), determines the condition of the statement (X < 10), then gives a command for the program should that condition be fulfilled. If statements are then ended by the ENDIF command.

• This is a good time to also point out how to declare variables in RoboBASIC. The syntax is basically, DIM (variable letter) AS (variable type; only bytes and integers are supported). Assigning variables is rather similar to most other languages: variable name = value.

DIM I AS INTEGERDIM X AS INTEGERX = 2

FOR I = 0 TO 10IF X < 10 THEN

‘bendSPEED 8MOVE G6A, 100, 58, 135, 160, 100, 100MOVE G6D, 100, 58, 135, 160, 100, 100MOVE G6B, 100, 30, 80, , , ,MOVE G6C, 100, 30, 80, , , ,WAIT

‘standard poseMOVE G6A,100, 76, 145, 93, 100, 100MOVE G6D,100, 76, 145, 93, 100, 100MOVE G6B,100, 30, 80, 100, 100, 100MOVE G6C,100, 30, 80, 100, 100, 100WAIT

ENDIFX = X + 4

NEXT

Page 27: Robonova-1 Instruction Manual v2.0

Reading from the Remote Control

• RoboBASIC already has commands to read in values for sensors, and has a command that specifically reads the input sent from the remote to the robot. In this code we are trying to have the robot bow if the user presses 1 on the remote control pad. A is a predefined variable that stores the value coming from the first instance of REMOCON (in other words, the first controller to send data to it). If A isn’t 1 (A <> 1), then the code restarts at the beginning of MAIN (GOTO MAIN); otherwise, it goes to another function that defines the bow position, delays the robot’s movement for a second (DELAY 1000), then moves the robot to its standard position and loops back to the beginning of MAIN.

MAIN:

A = REMOCON(1)IF A <> 1 THEN GOTO MAIN

SPEED 8GOSUB bow_poseDELAY 1000SPEED 6GOSUB standard_pose

GOTO MAIN

Page 28: Robonova-1 Instruction Manual v2.0

Reading from Serial Device

• This bit of code will read and store a byte sent over a serial connection with a baud rate of 57600, and will loop back to the beginning of read_bluetooth until it gets a byte. When it does get a byte, it stores it in X and then returns to the part of the code that called the function.

• ERX (baud rate), (predefined byte variable), (location in code to go to if byte is not read)

read_bluetooth:ERX 57600, X, read_bluetoothRETURN

Page 29: Robonova-1 Instruction Manual v2.0

Things to Note When Reading From a Bluetooth Device

• ETX/ERX can only send and receive byte values. Make sure the variables for these are initiated accordingly.

The Robonova-1 works with TTL, not RS-232. Be sure to use a device that is TTL-compatible, else find a converter for the devices.

Page 30: Robonova-1 Instruction Manual v2.0

Using the Catch-and-Play Features

Via RoboBasic v2.5

Page 31: Robonova-1 Instruction Manual v2.0

Catch-and-Play• You can pull up this screen by going to the

menu and clicking Control -> Servo Motor Real-Time Control.

• To use the catch-and-play feature, you first unselect all of the servos that you want to move. This is about the equivalent of MOTOR. After that, you move the robot into the position you want, then make sure that all boxes are checked again. This is the equivalent of GETMOTORSET. Finally, to add the new position to your code, press the Move Insert button of each motor group. Don’t forget to add a WAIT command at the end!

• You can also use this window to learn more about servo position values, in case you’re interested in correctly coding these values without having to use the catch-and-play interface.

Page 32: Robonova-1 Instruction Manual v2.0

A Deeper Glimpse at RoboBASIC

Quick Index of RoboBASIC Commands

Page 33: Robonova-1 Instruction Manual v2.0

General Program Commands• GOTO [function]• GOSUB [function]• RETURN• END• STOP• RUN• WAIT• DELAY [time]• BREAK

• Jumps to a specified part of program and executes all code henceforth

• Jumps to specified part of program and executes code until a RETURN is reached

• Returns from a subroutine to the point where the subroutine was called

• End the program• Stop the program• Run the program continuously• Wait until the program has finished

before moving on• Delay the execution of the next line

of code (value in milliseconds)• Pause the program and switch to

debug mode

Page 34: Robonova-1 Instruction Manual v2.0

Commands Related to Variables

• DIM [variable] AS [type]

• CONST• INTEGER• BYTE

• Declare a variable as a type

• Declare a constant variable

• Used with DIM...AS to declare an integer variable

• Used with DIM...AS to declare a byte variable

Page 35: Robonova-1 Instruction Manual v2.0

For Loops/If Statements

• IF...THEN• ELSEIF...THEN• ELSE• ENDIF• FOR...TO• NEXT

• Start a conditional statement• Start a secondary

conditional statement• Set a default statement for

when no conditions have been met

• End a set of conditional statements

• Start a for loop• End a for loop or iterate

variable to next value

Page 36: Robonova-1 Instruction Manual v2.0

Supported Logical Expressions

• AND• OR• XOR• NOT

• <• >• <=• >=• =• <>

Page 37: Robonova-1 Instruction Manual v2.0

Digital Signal Commands• IN [port#]

• OUT [port#], [outputValue]

• BYTEIN [port#]

• BYTEOUT [port#], [outputValue]

• INKEY [port#]

• STATE [port#]

• PULSE [port#]

• TOGGLE [port#]

• KEYIN [ADPort], [#keys]

• Read signal from input port

• Send signal to output port

• Read a byte from input port

• Send a byte to the output port

• Reduce chattering

• Get status of output port

• Send pulse signal to output port

• Reverse status of output port

• Receive input from analog keyboard

Page 38: Robonova-1 Instruction Manual v2.0

Memory Commands

• PEEK [region]• POKE [region], [byteData]

• ROMPEEK [region]

• ROMPOKE [region], [byteData]

• Read data from controller RAM

• Write data to controller RAM

• Read data from external EEPROM RAM

• Write data to external EEPROM RAM

Page 39: Robonova-1 Instruction Manual v2.0

LCD Screen Commands• LCDINIT

• CLS

• LOCATE [x],[y]

• PRINT [charString], [ASCIInumber]

• FORMAT [var], [type], [position]

• CSON

• CSOFF

• CONT

• DEC

• HEX

• BIN

• Initialize LCD module

• Clear all characters displayed on LCD

• Set x/y coordinates of the characters displayed in the LCD

• Display letter in LCD

• Set type format of characters on LCD

• Turn cursor in LCD on

• Turn cursor in LCD off

• Set letter contrast

• Send decimal character to LCD (used with FORMAT)

• Send hexadecimal character to LCD (used with FORMAT)

• Send binary character to LCD (used with FORMAT)

Page 40: Robonova-1 Instruction Manual v2.0

Motor/Servo Commands• ZERO

[motor0_neutral]... [motorN_neutral]

• MOTOR [motor#]• MOTOROFF [motor#]• MOVE [motor0_angle]...

[motorN_angle]• SPEED• DIR• PTP• SERVO

• Set neutral angle of servo• Turn on the output port of the

servo• Turn off the output port of the

servo• Move a set of servos to

specified positions• Set the speed of the servos (1-

15; 3 is initial)• Set the direction of the servos• Turn simultaneous control of

servos on/off• Control a particular servo

Page 41: Robonova-1 Instruction Manual v2.0

Even More Motor/Servo Commands

• PWM• FPWM• HIGHSPEED• FASTSERVO• POS• MOVEPOS• MOVE24• MOTORIN• GETMOTORSET• INIT

• Set pulse width control for DC motor• Set pulse width and frequency• Allow/disable servos to move in “fast

mode”• Operate servos at maximum speed• Set a position for the robot• Move to specified POS• Move all 24 servos at the same time• Read in the motor values for the current

position• Get the current servo values and determine

whether to keep them or set them to their initial positions (1 = keep, 0 = initialize)

• Set initial pose

Page 42: Robonova-1 Instruction Manual v2.0

Last Batch of Motor/Servo Commands

• AIMOTOR• AIMOTOROFF• AIMOTORIN• SETON• SETOFF• ALLON• ALLOFF

• Control motors via an AI motor

• Turn off AI motor

• Read position values from AI motor

• Use in conjunction with other commands to enter setup mode

• Cancel setup mode

• Use in conjunction with other commands to enter setup mode for all servos

• Cancel setup mode for all servos

Page 43: Robonova-1 Instruction Manual v2.0

Assigning Motor Group Commands

• G6A

• G6B

• G6C

• G6D

• G6E

• G8A

• G8B

• G8C

• G8D

• G12

• G16

• G24

• G32

• Assign servos 0-5 to group A

• Assign servos 6-11 to group B

• Assign servos 12-17 to group C

• Assign servos 18-23 to group D (not available for original robot)

• Assign servos 24-29 to group E (not available for original robot)

• Assign servos 0-7 to group A

• Assign servos 8-15 to group B

• Assign servos 16-23 to group C

• Assign servos 24-31 to group D (not available for original robot)

• Assign servos 0-11

• Assign servos 0-15

• Assign servos 0-23

• Assign servos 0-31 (not available for original robot)

Page 44: Robonova-1 Instruction Manual v2.0

Sound Commands

• SOUND [pitch],[length]

• MUSIC [stringOfNotes]

• TEMPO [value]

• Plays a note based on inputted frequency/duration

• Plays a string of notes based on inputted note information

• Sets the tempo of the song/sound

Page 45: Robonova-1 Instruction Manual v2.0

MUSIC Command (More Detail)

• Scale starts at, C (CDEFGAB)

• # = sharp note• $ = flat note• <space>, P = rest• > = raise an octave• < = lower an octave• L = Low Octave• M = Middle Octave• H = High Octave• T = change tempo

• 1 = whole note• 2 = half note• 3 = dotted half note• 4 = quarter note• 5 = dotted quarter note• 8 = 8th note• 9 = dotted 8th note• 6 = 16th note• 7 = dotted 16th note• 0 = 32nd note

Page 46: Robonova-1 Instruction Manual v2.0

MUSIC Command (Even More Detail)

• Extra notation is placed before the actual note

• Song is written as a string of notes

• MUSIC “M4GGAA GGE GGEED”

• MUSIC “DE#FGAB>#CD”

Page 47: Robonova-1 Instruction Manual v2.0

External Communication Commands

• ERX [baudRate],[byteVar],[ErrorProcessFunction]

• ETX [baudRate], [byteVar]• AD(<ADPort>)• REMOCON(1)• SONAR(<UltrasoundPort>)• RCIN(<RCPort>)• GYRODIR [group],

[motorDirection]• GYROSET [group],

[gyroPort]• GYROSENSE [group],

[byteSensitivityValue]

• Reads a byte from a RS-232 connection through the RX port (goes to ErrorProcessFunction if byte is either not received or is invalid)

• Sends a byte through the TX port using the RS-232 connection

• Reads analog signal from device connected to specified AD port

• Reads signal from remote control/virtual REMOCON

• Reads distance being measured by the ultrasonic wave port (lower controller port = output ultrasound port, higher controller port = input ultrasound port)

• Reads signal from RC remote control• Sets direction of motor group when they are

connected to a specified gyro• Assigns gyro to particular set of servos• Sets sensitivity of servo group to the gyro

Page 48: Robonova-1 Instruction Manual v2.0

Ultrasound Port Information

• Digital In/Out Controller Port #

• Ultrasound Port #

Port #0 #0 Ultra-sonic Port output Port #1 #0 Ultra-sonic Port input Port #2 #1 Ultra-sonic Port output Port #3 #1 Ultra-sonic Port input Port #4 #2 Ultra-sonic Port output Port #5 #2 Ultra-sonic Port input Port #6 #3 Ultra-sonic Port output Port #7 #3 Ultra-sonic Port input Port #8 #4 Ultra-sonic Port output Port #9 #4 Ultra-sonic Port input Port #10 #5 Ultra-sonic Port output Port #11 #5 Ultra-sonic Port input Port #12 #6 Ultra-sonic Port output Port #13 #6 Ultra-sonic Port input Port #14 #7 Ultra-sonic Port output Port #15 #7 Ultra-sonic Port input Port #16 #8 Ultra-sonic Port output Port #17 #8 Ultra-sonic Port input Port #18 #9 Ultra-sonic Port output Port #19 #9 Ultra-sonic Port input Port #20 #10 Ultra-sonic Port output Port #21 #10 Ultra-sonic Port input Port #22 #11 Ultra-sonic Port output Port #23 #11 Ultra-sonic Port input

Page 49: Robonova-1 Instruction Manual v2.0

Gyro Port Information

• AD Port # • Gyro Port # Port #0 (Port #32) Gyro #1 channel output Port Port #1 (Port #33) Gyro #2 channel output Port Port #2 (Port #34) Gyro #3 channel output Port Port #3 (Port #35) Gyro #4 channel output Port Port #4 (Port #36) Gyro #1 channel input Port Port #5 (Port #37) Gyro #2 channel input Port Port #6 (Port #38) Gyro #3 channel input Port Port #7 (Port #39) Gyro #4 channel input Port

Page 50: Robonova-1 Instruction Manual v2.0

Baud Rates SupportedAll with 8-bit data, no parity, 1 stop bit

• 2400

• 4800

• 9600

• 14400

• 19200

• 28800

• 38400

• 57600

• 76800

• 115200

• 230400

Page 51: Robonova-1 Instruction Manual v2.0

Random Commands• RND• REMARK [Description]• ON [variable] GOTO

[function]• $DEVICE [Controller]• $LIMIT [Motor#],

[MinValue],[MaxValue]

• Get a random byte number• Another way of commenting code• Go to a specified section of the

code when a variable is of a certain value (simpler version of long if/elseif block)

• Set controller that will run the program once compiled

• Set a servos' maximum rotation angle (default 10-190)

Page 52: Robonova-1 Instruction Manual v2.0

Using RoboScript v2.5

Page 53: Robonova-1 Instruction Manual v2.0

Snapshot of RoboScript Interface

Page 54: Robonova-1 Instruction Manual v2.0

Overview of RoboScript v2.5

RoboScript is very similar to RoboBASIC, with the exception being that code is displayed in a script format, rather than a normal code format. This is can be useful for people who want a simpler way of organizing and reading the roboBASIC code.

Page 55: Robonova-1 Instruction Manual v2.0

Initialize the Robonova-1

As with RoboBASIC, your work will go much more smoothly if you make sure your robot is properly connected and is corrctly recognized by the software. Use the same initialization procedure outlined for RoboBASIC; the only difference is that under Port Settings, there will not be a Port section on the left of the window.

Page 56: Robonova-1 Instruction Manual v2.0

More on Using RoboScript This program relies almost exclusively on catch-and-play movement code, with only

a couple of commands provided (PTP ALLON, PTP ALLOFF, DELAY, GOTO, and MOVE24). To use RoboScript, you turn the robot on, move the dials located at the bottom of the screen until the robot has moved to a desirable position, then use the Insert Move button to place that movement in the code. You can also press the buttons for the other commands and change the parameters in the text boxes/drop-down menus in order to change the speed, insert delays, go to specific lines of code, and to turn simultaneous control of servos on or off.

The dials all correspond to specific servos (look back at the Catch-And-Play section to get an idea of which dial will affect what body part). In addition, each dial starts at the Robonova’s initial position. If you read the RoboBASIC section, you know that values above 100 turn the servos clockwise, and values below turn the servos anti-clockwise. Be very careful about using these dials; this method of getting positions makes it much easier to spin a servo too far in a particular position. Make sure you are watching your robot carefully as you make adjustments, to ensure that you do not blow out a servo trying to move it too far into a dangerous position.

Page 57: Robonova-1 Instruction Manual v2.0

Using RoboRemocon v2.5

Page 58: Robonova-1 Instruction Manual v2.0

Snapshot of RoboRemocon v2.5

Page 59: Robonova-1 Instruction Manual v2.0

Overview of RoboRemocon v2.5

This program is not meant for programming the robot; rather, it is meant to set the actions that will be carried out when specific buttons are pressed on the included remote control. It is also meant to serve as a virtual remote control, where the user presses the buttons on the image on-screen rather than the actual remote control in order to carry out the same action (this option being useful if one runs out of batteries or simply loses the remote).

Page 60: Robonova-1 Instruction Manual v2.0

Initializing the Robot

As with the other two programs, it is useful to make sure the program is talking correctly to the robot. For RoboRemocon, simply make sure the port settings are correct under Setting Port, and you should be fine.

Page 61: Robonova-1 Instruction Manual v2.0

Using RoboRemocon To assign actions to the remote, you need to have created the files

describing the action in RoboScript (or have made a valid .rsf file). Press the Setting Buttons button. A window like the one in the image

should appear. To set the buttons, double-click on the File column in the row of the button you are setting. You will see a screen with text boxes for a label, an .rsf file name (with buttons to clear this box and to browse for the file), and a tag description. Get the RoboScript action you want set to this button, and change the label or tag information if desired.

Click Download to send this information to the robot. You should now be able to press buttons on the PC image of the remote and have the robot carry out the actions. To switch control to the IR remote, select the IR Remote Control option in the bottom-left corner of the Setting Buttons screen, then re-download the program. You should then be able to press buttons on the IR remote and have your robot act accordingly.

You can also use these settings in a RoboBASIC command by downloading this information and then using the REMOCON command in your RoboBASIC code.

Page 62: Robonova-1 Instruction Manual v2.0

Using Another Board to Program With the Robonova-1

Page 63: Robonova-1 Instruction Manual v2.0

General Procedure

To use another board, you will of course need some sort of way to connect the new board to the Robonova-1’s board. You will also need to find a way to have the computer talk to the new board, plus a method of sending byte signals from the new board to the Robonova-1 board. Then you will need a program on the Robonova-1’s board that can process that byte and carry out an action based on what it received.

Page 64: Robonova-1 Instruction Manual v2.0

Sample Code for The Robonova-1 Program

‘Put initialization code here

MAIN:

GOSUB READ_BOARD

IF X = 65 THEN

GOSUB STANDARD_POSE 'A

ELSEIF X = 66 THEN

GOSUB BEND 'B

ELSEIF X = 67 THEN

GOSUB SIT 'C

ELSEIF X = 68 THEN

GOSUB STEP_FORWARD 'D

ELSEIF X = 69 THEN

GOSUB STEP_BACKWARD 'E

ELSE

MUSIC “CC”

ENDIF

GOSUB STANDARD_POSE

GOSUB MAINB

READ_BOARD:

ERX 57600, X, READ_BOARD

RETURN

‘Put movement code functions here

Page 65: Robonova-1 Instruction Manual v2.0

Using the Robonova-1 With Myro

Page 66: Robonova-1 Instruction Manual v2.0

Overview on Myro Myro is meant to be a Python-based environment with

which students can program robots to act without having to learn a language like BASIC right off the bat. It allows students to use short commands to carry out actions, rather than writing out the position of every servo in order to carry out the same task. It also allows them to do this in a relatively user-friendly programming language, so that when they start learning about more than just the basic movement commands they will still be using a relatively simple interface for programming more complicated routines.

For the skeleton code for this interface, visit the Humanoid Robotics section of IPRE’s wiki site.

Page 67: Robonova-1 Instruction Manual v2.0

Myro vs. RoboBASIC

<turn on robot><connect robot to PC>openPort()bend()standardPose()closePort()<turn off robot>

<turn on robot><connect robot to PC>

GETMOTORSET G24, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0SPEED 5MOTOR G24

‘standard poseMOVE G6A,100, 76, 145, 93, 100, 100MOVE G6D,100, 76, 145, 93, 100, 100MOVE G6B,100, 30, 80, 100, 100, 100MOVE G6C,100, 30, 80, 100, 100, 100WAIT

‘bendSPEED 8MOVE G6A, 100, 58, 135, 160, 100, 100MOVE G6D, 100, 58, 135, 160, 100, 100MOVE G6B, 100, 30, 80, , , ,MOVE G6C, 100, 30, 80, , , ,WAIT

‘standard poseMOVE G6A,100, 76, 145, 93, 100, 100MOVE G6D,100, 76, 145, 93, 100, 100MOVE G6B,100, 30, 80, 100, 100, 100MOVE G6C,100, 30, 80, 100, 100, 100WAIT

<download to robot><turn off robot>

Page 68: Robonova-1 Instruction Manual v2.0

Parting Words About the Robonova-1

Comments On Various Aspects of the Robonova-1 That Are Useful to

Know

Page 69: Robonova-1 Instruction Manual v2.0

Battery Life Battery life ranges from forty-five minutes to an hour and twenty minutes, depending on what you do with

the robot. The latter lifetime is achievable if the robot is only standing the entire time; likewise, if it is constantly moving (for example, if it is running a continuous walking program), the former lifetime will probably be more common. When the robot moves, it is rare to get a battery life above an hour, and difficult to even hit the 60-minute mark.

The battery should be allowed at least two hours to charge (four or five is optimal). As the battery is a lithium battery, it is not advisable to leave the battery plugged into the charger all the time, as this will in time degrade the quality of the battery

Some people have stated that it is also unwise to leave the robot connected to an external power supply while operating it, for this can lead to the robot getting more power than it ought to, which can lead to a number of issues.

The instruction manual indicates that the LED light on the charger’s plug should turn green when the robot is fully charged; however, like many other devices, this might not always be an accurate indicator of whether the battery is fully charged. Additionally, the blue LEDs in the robot’s head are supposed to blink when the battery is low, but this does not always happen (sometimes they might blink just minutes after you fully charged the battery, sometimes they might not blink at all). Try to remember how long you have charged or used your robot so that you can estimate the battery’s power status more accurately.

As the battery does not last very long after the robot moves, it is safe to assume that the robot requires a considerable amount of its battery power to carry out its code. It is therefore not recommended to attach devices to the Robonova-1 that will require a large amount of the robot’s battery power. Not only will the robot have even less time until its battery runs out, but adequate power might not be given to either device, which will affect the performance of both devices.

Page 70: Robonova-1 Instruction Manual v2.0

Stability Without a gyro, the Robonova-1 is not particularly stable, especially on carpeted or otherwise uneven floors. Do not try the

provided walking program on uneven floors unless you don’t mind your robot falling over quite often, or unless you have purchased a gyro.

When creating new movements, you must keep many things in mind. Can the Robonova-1 balance sufficiently in the pose you specified? If the Robonova-1 cannot keep the pose, even in the catch-and-play mode, then it is likely that the pose will be equally unstable when put into a routine. Also, what speed must you set the motion to in order to maintain that balance? Even if the robot can stand in a particular position just fine, the movement might become problematic if the robot is moving too slow or too fast when it tries to attain that position. Momentum is also an even greater issue when dealing with the Robonova-1 than it is with wheeled robots; one has to make sure that the momentum from a movement will not send the robot on its back, or in some other undesirable position.

The Robonova-1 is rather top-heavy; its chest area is clearly the heaviest part of its body, and movements must be planned accordingly. It helps to bend the legs whenever possible to increase the stability of a move. Try not to have it bend much farther than the movement provided with the robot. Try to keep the legs in a wide stance if the robot is doing fast moves, such as fighting moves. If the robot is to be on one leg, be sure to gauge whether its movements should slow down considerably or speed up considerably; many of the provided programs demonstrate that slower can often be better, depending on what you are trying to accomplish.

While it is humanoid, it does not have half the joints of the average human being, so program turns accordingly. It does not have rotating ankles, so to turn the robot you will have to use the same concept that is shown in the provided code: have one foot move out in a way that makes the robot wobble to a particular side, thus causing it to “turn” in that particular direction. Keep these turns somewhat slow.

On the same token, as it is a humanoid, it is helpful to think about the human body at least a little bit when thinking about stability. Balancing on one leg involves more than knee movement or hip movement; try to remember that when trying to get the robot to balance properly. Sometimes it might help even to try the pose yourself; just keep in mind that the Robonova-1 is not as fortunate as you when it comes to twisting and turning.

Page 71: Robonova-1 Instruction Manual v2.0

Range of Motion While stability might often be an issue with making new moves, one has to admit that the

Robonova-1 still has a pretty good range of motion.

Like human legs, the Robonova-1 can bend its knees forward to the point where its mechanical thighs will meet its mechanical calves. Similarly, it is not designed to allow the knees to bend backward. However, the robot cannot rotate each leg in a roughly 108° angle, as humans can. Also, the robot’s ankles cannot rotate (though they can bend up or down).

The Robonova-1’s hip and waist movement is limited. It can bend forward or backward (not necessarily advisable, for stability reasons), and it allows for the legs to come up high enough to attempt the splits, but other than that there is no rotation or movement in this section of the body. As the robot does not have a spine, this also means that the waist is not going to move at all, along with the rest of the lower back.

The arms move fairly well. They rotate a bit better than the legs; like human arms, they can rotate inwards, with the limit being up or down. Unlike humans, however, the arms have to be away from the body (generally perpendicular) in order to rotate up and down. The arms can be brought up to shoulder height from either the front or the back; to raise them higher, one must move the arms perpendicular to the body and then raise them up. This makes lifting something up higher than the shoulders difficult, though doing moves like the half-sun are not completely impossible.

The head will not move at all. It is a decoration that houses the blue LED lights for the battery and the IR sensor on top of its head, and nothing more.

Page 72: Robonova-1 Instruction Manual v2.0

Kinds of Actions It is Suitable For

• If you do a search for the Robonova-1, you are likely to find a variety of things the Robonova-1 is capable of. On the left is a list of activities one could do with the robot even without the extra sensors that can be bought for the robot. Some are as easy to execute as using the catch-and-play feature, while some only require the addition of using the remote control.

• Martial Arts (simplified versions of Kung-fu, Tai Chi, Karate...)

• Ballet/Dancing• Boxing• Yoga (simpler moves)• Soccer• Volleyball• Walking around an

environment• Talking to people in Morse

Code

Page 73: Robonova-1 Instruction Manual v2.0

Appendix

Trouble-Shooting and Other Random But Important Information

Page 74: Robonova-1 Instruction Manual v2.0

Getting RoboBASIC to Work in Vista

regsvr32 /u c:\windows\system32\mscomm32.ocx regsvr32 /u c:\windows\system32\COMCT332.ocx regsvr32 /u c:\windows\system32\MSCOMCTL.ocx regsvr32 /u c:\windows\system32\MSCOMCTL.ocx regsvr32 c:\windows\system32\mscomm32.ocx regsvr32 c:\windows\system32\COMCT332.ocx regsvr32 c:\windows\system32\MSCOMCTL.ocx regsvr32 c:\windows\system32\MSCOMCTL.ocx regsvr32 /u c:\windows\system32\COMDLG32.ocx regsvr32 c:\windows\system32\COMDLG32.ocx

* For more information on this, visit the RoboSavvy Forums.

To get RoboBASIC working on a Vista machine, paste the following into Notepad, then save as a .bat file. You should then be able to double-click it, and your RoboBASIC program should work.

Page 75: Robonova-1 Instruction Manual v2.0

Finding Out What COM Port You Need

XP and below: • Control Panel (under Start ->

Settings)• System• Hardware• Device Manager• Ports• Communications Port Next to this choice should be the

number of the COM port being used by the serial cable.

Vista:• Control Panel (under Start)• System And Maintenance• View Hardware and Devices

(under Device Manager)• Ports• Communications PortNext to this choice should be the

number of the COM port being used by the serial cable

Note: If you could not plug the serial cable into your computer, then you do not have the correct physical COM Port, and will not be able to find the port using these paths. You will have to use a computer that you

can plug the cable into before either of these paths will work.

Page 76: Robonova-1 Instruction Manual v2.0

Acknowledgements/Sources The RoboSavvy forums and the RoboSavvy wiki page were

very helpful for figuring out hardware information, such as modifications that could be used with the robot, and for determining what sort of procedure one would have to go through to use bluetooth with the Robonova-1, or to program it directly using a language other than RoboBASIC. It also provided the solution for getting RoboBASIC and Vista to work with each other.

The included instruction manual: while it did not explain how to use some features in its programs and was often difficult to understand, it did provide a comprehensive list of commands that can be used in RoboBASIC, as well as instructions on how to initialize the robot.

Page 77: Robonova-1 Instruction Manual v2.0

Finit