background image

Connect the infinite repeat block in the control block group to 
A. To drive. To travel to where the drone is not seen as a click.

To have the drone repeat bouncing on the wall without disappearing out of 
the screen: Use Block 

12

2) Move drones (move drones continuously)

Summary of Contents for CoDrone Mini

Page 1: ...CoDrone Mini Rokit Brick ENG for ...

Page 2: ...Controlling CoDrone Mini with Rokit Brick Introduction ...

Page 3: ...ad Micro 5 pin may prevent COM PORT number from appearing In this case please replace Cable USB serial device COM 13 Windows 10 The UBB driver will be installed automatically Windows 7 8 UBB drivers must be installed manually The name of the device manager may be marked STM32 virtual COMport Put a battery in the drone turn on the power and connect the controller to the drone With Rokit brick codin...

Page 4: ...existing Scratch programs such as robots drones and others Scratched SW developed by combining various control functions The method used is almost the same as Scratch HWs such as Rokit Smart Series and CoDrone can be controlled in Scratch format 4 Rokit Brick Icon ...

Page 5: ...or CoDrone 1 Run RBCodrone exe in the installation path of Rokit Brick for CoDrone 2 When the program is running Run Rokit Brick with the Button on the left screen 3 Rokit Brick runs normally as shown in the image on the right ...

Page 6: ...tte to see the drone control blocks and check the two buttons Connect the controller to the PC then press the Connect to drone button to connect the PC and the drone Even if the drone is turned off by removing the battery during use there is no need to disconnect the drone and it is automatically connected when the drone is switched back on CAUTION Before pressing the Connect to Drone button the d...

Page 7: ...7 5 Screen configuration for Rokit Brick The basic menu and screen layout is similar to Scratches in MIT Start Stop Zoomin Out Stage SpriteList Tablist ScriptWindow BlockPalette Menu ...

Page 8: ...Control CoDrone with motion block CoDrone Block Description ...

Page 9: ...9 1 Import Image From the menu you can get the desired image using the look tab You can resize the stage by dragging the boundary line with the mouse ...

Page 10: ...motion block group to the script screen Each time the mouse clicks on the block on the script screen the drone moves forward by as much as 10 10 2 Example of moving sprites 1 Move drone sprite Go straight to CoDrone 10 ...

Page 11: ... control block group You start driving using or 11 DroneHomewardMovement If the drone disappears to the point where it cannot be seen then it s on the tab Move to x 0 y 0 Click on block to start the home position return to Connect Block to and click on the green flag to move ...

Page 12: ...ck in the control block group to A To drive To travel to where the drone is not seen as a click To have the drone repeat bouncing on the wall without disappearing out of the screen Use Block 12 2 Move drones move drones continuously ...

Page 13: ...hange the x y coordinate values Similarly the amount of time to wait is entered for the desired time can be changed into If the drone is to move as shown in Figure 1 it can be coded using the coordinate values and Delay as shown in Figure 2 그림3 13 그림2 3 Move drones take off and landing 그림1 ...

Page 14: ...rones Usevariables Let s create a program that only repeats three times the following movements rather than no uniform Try to minimize the number of blocks used 14 Variable A variable especially one used a lot in a program is a non numeric character that creates space for storing numbers and allows you to put the desired number at any time e g A 5 Value 0 ...

Page 15: ...der 15 And after you ve run the stage you can move the A variable slider on the stage with your mouse and you can change the variable in real time You can see that the rotating radius of the drone has become larger and smaller as the value changes Creating a variable named A creates a variable block group as shown below and creates a variable on the stage ...

Page 16: ...the number of blocks used 3 After creating a landing site through the addition of a new sprite Implementing the drone landing at the landing site in a variety of ways 16 3 Move drones take off and landing 1 Create a Drone moves back and forth motion reflecting the wall and make a variable Use to adjust the moving speed ...

Page 17: ...To control CoDrone with motion blocks CoDrone Block Description To control a CoDrone with an operating blocks of motion ...

Page 18: ...s block Drone landings Drones Stop Motion Up down altitude vertical movement Left turn right turn Forward and backward forward backward movement Left hand right hand movement The control block value below has a value between 100 and 100 and the output Used to change multiple values at the same time ...

Page 19: ...icult to use over time you can change several values at the same time to one block below Values left blank without input are considered zero And when you add a waiting block delay block the specified control value is maintained for a specified period of time before the next block is operated With the pitch value set to 50 it remains intact regardless of the wait block below no trailing blocks Set ...

Page 20: ...0 throttle Vertical Move Up and Down Rise yaw Turn left move right Turn right pitch Forward Reverse Movement Forward roll Left right right Rightward movement 1 CoDrone Mini Block Description Motion Block ...

Page 21: ...Shows the current status of the drone according to the angle measuring sensor Normal Start Flipping Flip Shows the remaining battery percentage of the drone Shows how much the drone s gas is tilted from side to side Shows how much the drone s gas is tilted up and down Shows how the drone s fuselage rotates left and right Shows the internal temperature of the drone Shows the air pressure measured b...

Page 22: ...ne tuning block Hovering drone moving backwards Click to adjust Hovering drone moving forwards Click to adjust Hoverling drone moving right Click to adjust Resets fine adjustment values back to 0 Hoverling drone moving left Click to adjust ...

Page 23: ...should be learnt first Mastering the Hovering Steps for Correct Hovering a take off b make sure the drone does not move in any direction Fine tuned values are CoDrone Mini control Appears on the block palette P pitch value R roll value When the drone goes to the left When the drone goes to the right When the drone runs back When the drone goes forward 3 CoDrone Mini block description fine tuning b...

Page 24: ...peed control Demonstrating dexterity dumbling Block forward back right left The speed level values are displayed on the CoDrone Mini Control Block palette SPD T I P Equal pitch value for speed level 1 and 3 Even if it s 50 it s a big difference in speed If you want to control it at dynamic speed you need to set the speed level at 3 If you want a safe speed you can control it by 1 ...

Page 25: ...e s LED in the specified color Flashes the drone s LED twice Dims the drone s LED Brightens the drone s LED Turns on the drone s LED and then slowly dim it Blinks the drone s LED to assigned colors 5 CoDrone Mini Block Description LED Control Block ...

Page 26: ...g CoDrone Mini with Rokit Brick Example of CoDrone Mini Lab Make sure to check the items below before practicing CoDrone 1 Check the hover status 2 Check the gas mode 3 Clear the angle value of the block to zero ...

Page 27: ...ode your own drones 5 Sec Take off 5s Landing Example of a green flag button popping up in the air for a while and then stopping take it by hand 27 Spacebar Emergency Landing Key Five seconds After take off Landing 1 Example of flying CoDrone Mini spaces T I P Wait five seconds after the take off block meaning after the drone has received the take off order ...

Page 28: ...ick take off order 3 seconds later Pitch 30 One second after the command Landing T I P Even with the same 30 pitch output the speed of the drones may vary depending on the speed level setting An example of a green flag button that pops up in the air for a while and lands in the hand ...

Page 29: ...c Landing 1 5 s movement in forward direction pitch Clear the forward direction output pitch to zero Move left roll for 1 5 seconds Clear left hand output roll to zero Different time or pitch output values can be used to adjust the travel distance When you click on the green flag button the drone takes off moves forward and then moves on I want you to fly sideways left ...

Page 30: ...e direction of movement of the drone to the left why did you clear the value of the forward direction to zero Advance if not cleared to zero when turning like this peach The velocity of the direction is still left so we give it a left hand roll value to the left As you move you move diagonally Therefore the forward speed must be zero ...

Page 31: ... of the drone fine tuning exercise Take off Hoverling Condition observation Adjust by pressing the w a s d key Landing fine adjustment For precise control using coding after the drone takes off and is in place wait and make sure that it does not move in any direction as much as possible Use the fine tuning blocks to adjust the hover W A S D ...

Page 32: ...ple of flying and landing in a circle right after CoDrone take off 32 5 Example of flying CoDrone acrobatics Take off 2 sec Rotary Flight 4 Repetitions Landing Changing the yaw value and the deviation value at the same time Make it rotate in a circle ...

Page 33: ...Control the LEDs in a drone for different color and animation effects 33 6 LED Animation Example Example of slowly turning on and off changing colors at intervals of 2 seconds ...

Page 34: ...k or treating in the air 34 7 to Queen during the flight to Dumpling Forward Front Flip Reverse 3 repetitions Forward at 40 power for 2 Seconds Exceeding week requires waiting time set to 2 seconds Reverse to 40 output for 2 seconds Exceeding week requires waiting time set to 2 seconds Back Flip ...

Page 35: ...m of the CoDrone If there is an object that stands out The YAW angle is continuous There can be a growing and decreasing phenomenon 2 Receive the attitude control value of the CoDrone and rotate the sprites Before coding I d like to put the sprite on it Upload CoDrone Image It should 3 Receiving the attitude control value of the CoDrone Depending on the sensor state of the CoDrone The angle you ne...

Page 36: ...36 Click T I P Create Variable Block To use a variable you must create a variable block Click on Variables tab Create Variables Block Enter variable name Create variable block ...

Page 37: ...Status 1 Receiving Codrone Mini s battery value On the Variables tab before coding The battery value variable you want to save You must create a new one 2 Controlling CoDrone Mini with Rokit Brick Variables printed on canvas We re receiving battery values and we re going to use a variety of blocks to check the flight status You can check it ...

Page 38: ...Controlling CoDrone Mini with Rokit Brick Manipulate Using the Controller Use the controller buttons or joysticks to create a script that performs interesting actions ...

Page 39: ...n status notification UP No button on the controller is pressed PRESS One of the controller s buttons is pressed DOWN One of the controller s buttons is just being pressed Tells which buttons are pressed see figure above Y X Y X PAIRING RESET SPPED LED FLIP UP DOWN LEFT RIGHT ON OFF ...

Page 40: ... joystick towards is abbreviated as shown below Reminders Event Detects and displays the direction of the joystick changing IN OUT STAY Controller color change block Change the LED color of the controller Block to change the color of the drone as shown below Set the same LED color for the controller and the drone when used in conjunction with I can do it TM MR ML TL TR BM BL BR ...

Page 41: ... sprite with the directional key of the controller Click on the button Appearance click on the rollink Select harry_1 2 Take off R1 Button L1 Button Landing H Button Return to Origin R1 L1 H Confirm the button first ...

Page 42: ...er Left joystick Y axis Drone sprite take off or landing control Left joystick X axis Drone sprite left and right rotation Right joystick X axis Drone sprite left and right parallel shift Right joystick Y axis Drone sprite back and forth movement Sprite is click Shap Click on rollink select codron2_up Create Right Joystick Partial Script Pre Left and Left A ...

Page 43: ...cript take off and left hand rotation B To make a sprite smaller or larger The effect of the drone rising or falling Create a startup script C Adjusting sprit size and orientation Zeroed Left Right Joystick Script Runs at the same time ...

Page 44: ...Full Screen D 4 Write a script to control a drone like RC mode with the controller Create a script to adjust the value of the Euler angle with the left and right joysticks A X pitch Y roll X throttle Y yaw ...

Page 45: ...ecuted during the next run can affect the flight If it doesn t clear up to zero when it lands and takes off again The remaining values may cause the drone to fly in an unintended direction Script is executed when the controller s button is pressed L1 Button All Euler values are set to zero before landing R1 button After takeoff adjust the oiler angle and run the script Joystick controlled ...

Page 46: ...Controlling CoDrone Mini with Rokit Brick Appendix ...

Page 47: ...e communication settings Pairing allows only two devices to communicate without interference from other devices Pairing may be disabled during use or a drone or controller must be purchased and used with the existing device To pair shake the drone five to six times as shown in the picture below When the drone is ready for pairing the LED on the top of the drone is red and blue It flashes as it rep...

Page 48: ...ndication such as the controller If charging is required the battery must be charged using the specified battery charger See image below When the battery is connected the LED on the charger illuminates and turns off when the charge is complete 48 Charger Battery Charging cable Charger Battery Charger smartphone adapter PC USB Port Charging Cable Drone Battery Specifications ...

Page 49: ... Download manuals and programs from online sites Please check educational materials Robolink SW Arduino is provided as an open source www RobolinkSW com Youtube com CoDrone ...

Reviews: