background image

4. USAGE

 

 

 

22 

Kilobot User Manual 

   

Overhead Controller (OHC) Interface Overview  

1.

 

Select File: browse your files to select the firmware to upload.  

 

 

Figure 4.9: browse your files 

 

2.

 

Bootload: place the Kilobot in programing mode 

 

Figure 4.10: Connection Status 

  

Содержание KILOBOT

Страница 1: ...Kilobot User manual Version 2 0 JANUARY 2016 ...

Страница 2: ... First draft Trademark Acknowledgements Kilobot Harvard University Khepera K Team SA V REP Coppelia Robotics LEGAL NOTICE The contents of this manual are subject to change without notice All efforts have been made to ensure the accuracy of the content of this manual However should any error be detected please inform K Team The above notwithstanding K Team can assume no responsibility for any error...

Страница 3: ...ALLATION 12 4 2 1 INSTALL THE SOFTWARE 12 4 2 2 OVERHEAD CONTROLLER OHC SOFTWARE INSTALLATION 13 4 2 3 OVERHEAD CONTROLLER OHC HARDWARE INSTALLATION 14 4 2 4 KILOBOT BOOTLOADER PROGRAMMING 15 4 3 USAGE 18 4 3 1 PROGRAMMING ONLINE KILOBOTICS COM 18 4 3 2 PROGRAMMING WITH ECLIPSE 19 4 3 3 UPLOADING CODE IN A GROUP OF KILOBOT 20 4 3 4 OHC USE 21 4 3 5 CHARGER 25 4 3 6 DEBUGGING 26 4 3 7 KILOBOTS API ...

Страница 4: ......

Страница 5: ... of Kilobots easy whether there are 10 or 1000 in the group You can find more information directly on the designer website http www eecs harvard edu ssr projects progSA kilobot html This version of manual explain how to use the new version of Kilobot firmware developed by Harvard More information on this version can be found on the website https www kilobotics com If you already own Kilobot robot ...

Страница 6: ... when the board power is off Keep the board away of conducting materials To avoid any short circuit and damage to the robots avoid contact with metallic lonely wires and other conducting materials 1 3 Recycling Think about the end of life of your product Parts of the board can be recycled and it is important to do so By recycling you can help to create a cleaner and safer environment for generatio...

Страница 7: ... Kilobot charger for 10 robots simultaneously optional Communication IR up to 7cm up to 32kb s and 1kbyte s with 25 robots serial 256000 baud Sensing 1 IR and 1 light intensity Movement forward rotation 1cm s 45deg s Light one RGB led Software Kilobot Controller software for controlling the robot Programming C language with WinAVR compiler combined with Eclipse or the online Kilobotics editor Dime...

Страница 8: ...separately They are containing the following items The robot package 1 CD ROM 10 Kilobot robots The overhead controller package 1 overhead controller 1 CD ROM 3 cables 1 usb a 6 wire cable and a 2 wire cable The charger package 1 charger 1 transformer 1 CD ROM If multiple packages are ordered together only one CD ROM will be shipped ...

Страница 9: ...legs are not bended The charging tab also must not be bended The jumper and the battery should be present see figure 3 1 The battery should be plugged with the negative on top opposite of the battery holder marks For the Overhead controller check that the LEDS are not bended or broken The jumper for firmware programming should be present see figure 3 2 ...

Страница 10: ... depicted in the Figure 3 1 The locations of various key elements are indicated for later references Figure 3 1 Kilobot overview 3 7 Volt Battery up down Power jumper Vibration motors LED Red Green Blue Ambient light sensor Serial output header Direct programming socket Charging Tab IR Transmitter IR Receiver Robot leg ov ...

Страница 11: ...ted in the Figure 3 1 The locations of various key elements are indicated for later references Figure 3 2 Overhead controller overview Overhead controller board Connector for USB cable Connector for debug cable Connector for firmware programming Firmware programming jumper Diode for OHC connection test Power on LED IR LED ov ...

Страница 12: ... when 6 volts is applied to any of the legs and GND is applied to the charging tab Charging Kilobot charger optional Communication Kilobots can communicate with neighbors up to 7 cm away by reflecting infrared IR light off the ground surface Sensing When receiving a message distance to the transmitting Kilobot can be determined using received signal strength The distance depends on the surface use...

Страница 13: ...ng the controller board sending program files to the robots and controlling them Programming For programming the open source development software WinAVR combined with Eclipse gives a C programming environment An API with basic functions such as motor speed led control distance measurement is available and some examples are provided Debug A serial output header is available on each robot for debugg...

Страница 14: ...bot Over head controller OHC Kilobot charger 4 1 2 Required software To start programming the Kilobot with the new version from kilobotics you have two solutions You can either use the online editor and compile without the need of any installation https www kilobotics com editor Or you can install WinAVR and Eclipse to compile the whole library on your computer https github com mgauci kilobot_note...

Страница 15: ...our system or test actual demo program KiloGUI Kilobot Controller program Kilolib master Source code of the Kilobot Library Kilobot_update doc documentation to upgrade your old Kilobot system to this new version Zadig_2 1 2 exe Software to modify the USB driver to work with new controller Firmware bootloader hex Bootloader of the Kilobot Useful if an upgrade is needed or if the Kilobot firmware is...

Страница 16: ...ware source_code Kilobot VERSION Eclipse on your computer In this directory the kilolib is already compiled by K Team renamed libkilolib a 3 Install also Eclipse IDE for C C Developers http www eclipse org downloads packages eclipse ide cc developers lunasr2 4 Setup Eclipse As the source file were already compiled under Eclipse you just need to select your software source_code Kilobot VERSION Ecli...

Страница 17: ...otics com download 4 2 2 1 Updating driver of the OHC If your OHC is not recognize by the KiloGUI interface you will need to modify the driver Execute the software zadig_2 1 1 exe Option list all device Select LUFA AVRISP MkII Clone and libusb win32 V1 2 6 0 Click Replace Drive or Reinstall Driver if already done once Select FT232R USB UART and libusb win32 V1 2 6 0 Click Replace Driver Close Zadi...

Страница 18: ...ct the USB cable to the PC the power LED of the OHC should turn green 3 Run the kilogui exe program the message connected must appears at the bottom of the windows 4 Press the LedToggle button to validate the communication a Green LED on the OHC must change its state at each pressing 5 If the message connected didn t appear please follow the steps in chapter 4 2 2 1 ...

Страница 19: ...tloader or install a newer one follow the instructions below 1 In AVR Studio select Tools ProgramAVR Autoconnect 2 In the window that pops up under the program tab in the flash category select the input hex file to be bootloader hex 3 Put the firmware programming jumper of the OHC in the firmware mode position and connect the firmware cable figure 4 3 Figure 4 3 firmware cable and jumper in firmwa...

Страница 20: ... in figure 4 4 Figure 4 4 power jumper 5 Connect the AVRisp programmer to the robot as shown in figure 4 5 Make sure that the programmer pins do not touch the motor on the back side Gently press the program cable to the side to ensure a good connection Figure 4 5 communication connector ...

Страница 21: ..._CKSEL int RC Osc 8 MHz start up time PWRDWN RESET 6 CK 14CK 65 ms This should result in the following fuse values extended 0xFF high 0xD1 low 0xE2 7 In the Autoconnect pop up window in AVRstudio press program It should take a few seconds to program the robot and the robot may vibrate 8 Put the firmware programming jumper of the OHC in the back to the standard position Figure 4 6 firmware jumper n...

Страница 22: ...loGUI to upload the hex file to your kilobots Here are some resources on writing programs 1 The manual for C programming language and the AVR specific functions TBA 2 Kilobot Library API All the robot functions and their usage http www kilobotics com docs 3 Labs A tutorial will step by step example programs great for a class or to get new students started http www kilobotics com labs Note that you...

Страница 23: ...cated with the RGB LED the distance of the other Robot This is the default factory demo code If you want to keep the initial behavior and add your code find the text below to see where you need to add your code user program code goes here this code needs to exit in a reasonable amount of time so the special message controller can also run Once you own code added you can compile the source code Pro...

Страница 24: ...blue to indicate that they are ready to be programmed 3 Then press the Upload button to start programming The Kilobot will flash Green and Blue alternatively 4 Once the Kilobot programmed they will return to PAUSE state LED flashing green 5 To run the program on the robot press the Run button in KiloGUI The new program should execute 6 Press the Pause button in KiloGUI to stop the program Note the...

Страница 25: ...he surface should be glossy or reflective A mirror or dry erase whiteboard oriented horizontally is recommended The overhead controller should be hung above the Kilobots at a distance of about one meter The robots beneath the OHC in a about a one meter diameter region will be able to receive communication from the OHC as shown in figure 4 8 Figure 4 8 System setup ...

Страница 26: ...r Manual Overhead Controller OHC Interface Overview 1 Select File browse your files to select the firmware to upload Figure 4 9 browse your files 2 Bootload place the Kilobot in programing mode Figure 4 10 Connection Status ...

Страница 27: ...4 USAGE Kilobot User Manual 23 3 Upload start programming the Kilobot Figure 4 11 upload button ...

Страница 28: ...t left off Use Reset if you want to stop the robots and start the program from the beginning 4 Sleep Switch to low power sleep mode leds will flash white once every 8 seconds 5 Voltage Display voltage level using LED blue green fully charged yellow red need battery to be recharged 6 LedToggle Toggle LEDs on controller used to check communication between PC and controller 7 Serial Input Display rec...

Страница 29: ...charger or the robots 3 Switch the Kilobots on put the power jumper as in figure 4 4 4 Pay attention to respect the bar side and the cable polarization as explained above in 1 and 2 Then hang the Kilobots as specified in the figure below The bar with the red indicator is in contacts of the legs of the robots and is the positive Note in this new version of software there s no more Charge status on ...

Страница 30: ...2 wire cable respecting the polarity on the robot as shown in the figure below see figures 3 1 and 3 2 for the connectors place Figure 4 14 Debug settings 1 Open KiloGUI interface 2 Launch your program with the Run button of the KiloGUI 3 Press the serial input button to open a pop up where all the message sent by the Robot will appear debug cable red black ...

Страница 31: ...ght for turning left set_motors kilo_turn_left 0 for turning right set_motors 0 c kilo_turn_right Note that there are 4 calibration values used with the motors kilo_turn_left value for left motor to turn the robot ccw in place note right motor should be off kilo_turn_right value for right motor to turn the robot cw in place note left motor should be off kilo_straight_left value for the left motor ...

Страница 32: ...urn 1 if there is an incoming message which also uses a d note turns off interrupts for a short while to sample a d Example local_brightness get_ambient_light get_temperature Read the temperature of the Kilobot note will return 1 if there is an incoming message which also uses a d note turns off interrupts for a short while to sample a d Example local_temperature get_ temperature ...

Страница 33: ... ID in your Kilobot This can be useful if you want to save all calibration value for each Kilobot 4 The second line Turn Left will configure the kilo_turn_left parameter to set the CCW movement Set a value for the motor approximately 70 and press the Test button The Kilobot must start turning left Adjust the value to obtain a smooth move 5 Do the same as explain in point 4 for the right motor Turn...

Страница 34: ...e Kilobot robot with V REP a power physics simulator software An educational version is available for free at http www coppeliarobotics com downloads html The Kilobot model is already available for V REP inside the simulator All the functions explained in chapter 4 3 7 ...

Страница 35: ... _delay_ms x function as it must be non blocking you need to implement it like this for example _delay_ms 50 use a state variable here substate substate 0 function user_prgm wait 50 ms if substate 0 then delay_start simGetSimulationTime elseif substate 1 then if _delay_ms 50 1 then waited substate 0 here put the following of your code end You can find some V REP scenes with Kilobot examples there ...

Страница 36: ... Kilobot User Manual Kilobots_ messages ttt 4 robots send messages to each other to determinate the one that has the biggest id number Kilobots_ around ttt robots move around other static robots keeping distance ...

Страница 37: ...d after the data has been set otherwise it would be wrong and the message would be dropped by the receiver message crc message_crc message Register the message_tx callback function kilo_message_tx message_tx Register the message_tx_success callback function kilo_message_tx_success message_tx_success check for message if new_message 1 new_message 0 set_color 1 1 1 turn RGB LED white printf Mess0 se...

Страница 38: ... Set the LED red set_color RGB 1 0 0 Spinup the motors to overcome friction spinup_motors Turn left for 2 seconds 2000 ms set_motors kilo_turn_left 0 delay 2000 Set the LED blue set_color RGB 0 0 1 Spinup the motors to overcome friction spinup_motors Turn right for 2 seconds 2000 ms set_motors 0 kilo_turn_right delay 2000 Set the LED off set_color RGB 0 0 0 Stop for half a second 500 ms set_motors...

Страница 39: ...e problem If no answers have been received within two working days Customer can contact K TEAM support by phone or by electronic mail with the full reference of its order and Kilobot serial number K TEAM shall then at K TEAM s sole discretion either repair such Product or replace it with the equivalent product without charging any technical labour fee and repair parts cost to Customer on the condi...

Страница 40: ...ded or any indirect or consequential damages resulting therefore IF DURING THE REPAIR OF THE PRODUCT THE CONTENTS OF THE FLASH MEMORY ARE ALTERED DELETED OR IN ANY WAY MODIFIED K TEAM IS NOT RESPONSIBLE WHATEVER CUSTOMER S PRODUCT WILL BE RETURNED TO CUSTOMER CONFIGURED AS ORIGINALLY PURCHASED SUBJECT TO AVAILABILITY OF SOFTWARE Be sure to remove all third parties hardware software features parts ...

Страница 41: ... SPECIAL INCIDENTAL OR CONSEQUENTIAL DAMAGES RESULTING FROM PERFORMANCE OR FAILURE TO PERFORM UNDER THE CONTRACT OR FROM THE FURNISHING PERFORMANCE OR USE OF ANY GOODS OR SERVICE SOLD OR PROVIDED PURSUANT HERETO WHETHER DUE TO A BREACH OF CONTRACT BREACH OF WARRANTY NEGLIGENCE OR OTHERWISE SAVE THAT NOTHING HEREIN SHALL LIMIT EITHER PARTY S LIABILITY FOR DEATH OR PERSONAL INJURY ARISING FROM ITS N...

Страница 42: ......

Страница 43: ......

Страница 44: ...K Team S A Z I Plans Praz 1337 Vallorbe Switzerland ...

Отзывы: