Home
3. Robot mOway
Contents
1. Encoder PIC18f86j50 PIC16F687 SPEAKER Encoder Image 1 Diagram of mOway s parts 3 1 Processor mOways are governed by a 4 Mhz PICISF86J50 2 0 1 version or PICISF87J50 2 0 2 version microcontrollers manufactured by Microchip Technologies All of the peripherals distributed throughout the whole robot are connected to its input output ports Some of them need a digital input or output others need an analog input or output and others instead are controlled by one of the I2C SPI communication buses The table below describes how the microcontroller pins are distributed www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 8 of 84 Jz Drive system To be able to move the mOway uses a double servo motor group It includes both an electronic part and a mechanical one The electronic part is mainly in charge of controlling the motor s speed and the mechanical part allow the mOway to move unhindered over different terrains with adequate power Engrane Encoder PIC16F687 Encoder Engrane Image 2 Drive system electronic and mechanical The servo motor group includes different features Speed control controls the speed of each motor Time control controls the time for each command with a 100 ms precision 3 Travelled
2. 3 7 mOway Camera Board mOway Camera Board is the video receptor It receives the images from the Camera Module through RF and sends them to PC through USB Image 19 mOway Camera Board video receptor It has a channel selector for choosing the RF communication channel with Camera Module channels 1 to 4 Both Camera Module and video receptor must have selected the same channel Image 20 Channel selector Video receptor is connected to a USB port of the PC First time it 1s connected a message for installing drivers can appear In this case select the option of installing software automatically NOTE While video receptor is receiving images the casing heats up This is a normal functioning www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 22 of 84 4 First Steps 4 I mOway Pack installation In mOwayPack available in the webpage www moway robot com or in the installation CD you will find the software mOway s libraries test programs and documentation Following setup steps you will have all the resources e Beginner s and User manual o Beginner s manual includes all you need to start working with mOway o User manual contains detailed description of the robot e MowayWorld software o This software controls all aspects of the robot program download battery charge control radio control RFUSB management and C or assembler programs download e Reference
3. e Moway RF LISB Click Finish to close the wizard Image 24 Driver installed in Windows XP e Check if mOway s software has detected the RFUSB www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 26 of 84 4 4 mOway Camera Board drivers installation As with RFUSB device a driver that it s included in mOwayPack is required to use video receptor e The first time the mOway Camera Board is connected the PC will detect it as a new device Driver installation runs automatically If it doesn t an Assistant for new hardware found message will be displayed Select the No not this time option e In the following window select the recommended option Install software automatically e Now the installation process will begin e Assistant will then indicate that the hardware 1s installed e Check if mOway s software has detected the mOway Camera Board www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 27 of 84 www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 28 of 84 5 MowayWorld programming MowayWorld application makes it possible to design programs by means of flowchart diagrams so that mOway robot can be programmed very easily Different modules represent functions that control robot s sensors and actuators These modules are joined by means of arrows to define the program flow Previo
4. Movement Straight configuration window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 38 of 84 e Movement Free Free movement is similar to straight movement but in this case the speed of each motor can be adjusted separately E Movement Module Free Le 9 jJ In this Movement Module you can give mOway the command to move around freely by controlling its two wheels individually Need help Settings Left wheel Speed Right wheel Speed Constant Speed c Constant Speed 50 100 50 01002 Left wheel Direction Right wheel Direction e go forward Cn go forward D go backward D go backward Flowchart Control commands run continiously until next movement module in flowchart Q for Constant Time 0 1 seconds 0 1to 25 5 for Constant Distance Em o2 E centimeters 0 1 to 25 5 O finish time distance limit before continuing with the next action in flowchart w Save Image 41 Movement Free configuration window e Movement Turn In this function drive system will calculate the speed of the motors in order to be able to trace a curve indicating the speed and turning curvature Movement Module Turn In this Movement Moudle you can give mOway the command to make a turn Need Help Commands for mOway Wheel Speed Constant Speed Direction e go forward Turn
5. be found in the Scratch projects folder in mOway Pack named moway square sb and moway traingle sb The geometric shape is achieved by varying the number or iterations the polygon sides rotation mOway rotation angles and distance side length mOway reproduces the same geometric figure than Scratch in the real world when clicked broadcast reset distance go to x y point in direction Ela clear set pen color to set pen size to pen down speed to distance to rotation to ER rotation axis te repeat broadcast golstraight wait E secs move distance steps broadcast rotate lett turn 4 rotation degrees wait 1 secs EE The result 1s the following it is observed that the mOway odometer marks about with a margin of error 200 mm x 4 sides covered by mOway www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 79 of 84 Distance sensor value speed ETI distance ETT retation ETD retation axis EST If the variable rotation is changed to 120 and the number of iterations of the repeat block is changed to 3 the result will be an equilateral triangle I Distance sensor value 11171 speed BETEB distance ETT rotation EET rotation axis EEE www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 80 of 84 8 5 2 Enclosed The purpose of this exercise is that mOway move forward un
6. electronic circuits the user may choose As shown in the above table it is possible to connect commercial SPI devices On the other hand the RF BZI RF2GH4 module available in the market is totally compatible with mOway and with specific libraries This module enables the mOway to communicate with other robots and with a PC via the RFUSB With this module it is possible to create complex collaboration applications without having to worry about complicated wireless communications Top two color LED has to be switched off to have a valid measure www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 14 of 84 Image 12 RF modules into expansion connector 3 3 5 Temperature sensor mOway has installed as a temperature measurer an NTC thermistor from Murata a semiconductor whose electrical variable resistance decreases as temperature increases The sensor is located in the front part of the robot very close to obstacle sensor The thermistor is connected to the analog port of the microcontroller so that with a simple reading of the ADC it 1s possible to get the temperature value in that moment and notice any change in it since the last reading 3 3 6 Speaker The CMT 1102 speaker from CUI INC directly connected to the microcontroller is capable to play tones from 250 Hz to 65 KHz 3 3 7 Microphone The CMC 5042PF AC microphone from CUI INC enables the robot to detect sounds from 100 Hz
7. mowing the lawn or keeping the swimming pool clean As technology keeps improving these small devices which blend mechanics electronics and software are performing more and more complex tasks They are slowly introducing themselves into our lives in a useful manner and reducing the burden of unpleasant jobs It s not too far fetched to think that the revolution which took place in the IT or telecommunications fields will be repeated with robotics in the next decade Enough technology is currently available to manufacture these devices and society is also ready to receive them in the market Yet a specific catalyst 1s needed to start this revolution People also need to be ready and prepared to identify in what fields microrobotics may have an opportunity and which new applications may be interesting to implement Up till now processors weren t able to move But today things have changed Software is one of the fundamental elements in the world of mobile robotics The main difference between developing a program for these robots and running it with a personal computer is interaction with the environment The environment isn t changing randomly in PC applications so decision making and programming are simplified On the other hand when running commands for a minirobot application usually the result is unknown therefore algorithms have to consider situations with a wider range of possibilities some of them unexpected The mOway robots are tools
8. 2013 Page 51 of 84 5 4 Variables For more flexible programs some modules make it possible to use variables Variables makes possible to save values into robot internal memory A variable contains a value that can change during the execution of the program This is useful to read the values of the mOway s internal sensors for example speed value pause time read analog obstacle sensor values etc Then these values can be compared transmitted through RF to check sensor status etc Variables can be created from some modules They can also be defined from the toolbar by clicking on Variables and then clicking on New variable A name and an initial value have to be declared The name must not have more than 14 letters Moway Subroutines Variables Help New Variable Variables Image 53 Creation of a new variable from toolbar gd Compare Variable In this Module you can compare a constant variable with the value of another variable Need Help Comparison I 2H Constant Value Geale Tey E reate Variable 0 n Dto 255 Output True If is equal to 0 False Otherwise Image 54 Creation of a new variable from a module www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 52 of 84 ta Variables Variables store any information From here you can create modify or delete them but remember to always have a unique name V
9. 5 3 3 Data This group of modules make it possible to read write and modify data that mOway robot can provide from sensors and internal memory Data is stored in user defined variables A variable 1s created by clicking on Variable on the toolbar and then clicking on New variable A name and an initial value have to be defined for this new variable see Variables chapter Some of the modules allow to create these variables directly from their configuration window This permits to configure the module with values that can be modified during the execution of the program NOTE Each variable is stored in one byte of mOway s internal memory which means that the value of the variable can be from O to 255 e Calculate This module adds or subtract two values First parameter is always a variable and it stores the operation result Second parameter can be a constant or a variable e Reset mOway Data This module initializes time and distance counters stored in mOway s internal memory e Assign Variable This group of modules makes it possible to assign a value to a user defined variable This value can be constant or the analog value of mOway s sensors o Value assigns a constant value to a variable o Time assigns elapsed time to a variable Value goes from 0 to 255 tenths of a second o Speed assigns the speed value of one of the wheels to a variable Value goes from 0 stopped to 100 maximum spee
10. B port There is no need to wait for the battery to be completely discharged Advanced users only www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 17 of 84 as it can be plugged in any time since these batteries do not have memory effect also known as lazy battery effect These batteries are a perfect power source for mOway due to their small size lightness and flexibility Battery duration depends to a great extent on the active sensors and the amount of time the motors are used Charging lasts about 2h Power supply system controls two LED located in the back part of the robot Green LED indicates that mOway is switched on and red LED indicates that the battery is charging When the battery is full red LED will switch off Image 15 Charging red and switched on green ID RF module and RFUSB RF module establishes communication between other mOways or with PC using RFUSB These LEDs can t be controlled by the user 8 This LED can swap between on and off when the battery is fully charge because there is energy consumption when mOway is plugged Available in some packs 10 Available in some packs www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 18 of 84 Image 16 RF module RF module is connected in expansion connector and it is very easy to use with MowayWorld Image 17 RFUSB The BZI RF2GHA radio frequency c
11. Distance 0 0 cm Properties Simulation Image 70 Simulator side panel www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 63 of 84 The modes available in the simulator are the following E Run In Run mode the simulator executes the program in real time 1 e the speed at which the program would execute in the real robot p Animate In Animate mode the simulator executes the program step by step pausing for a second in each block The block that 1s running the simulator at each time is indicated by a yellow arrow Pause Stops the simulation at the current block Reset Pressing the reset button the simulation returns to the initial state 1 e the beginning of the program Also resets the value of the variables s Step In In this mode the simulator moves through the program step by step stopping at each block It also moves through the functions created by the user Step Over In this mode the simulator moves through the program step by step stopping at each block Unlike the previous mode the simulator does not advance into the user functions 7 2 Functioning In the simulator the user can vary the mOway sensors value and see how this affects the operation of the robot depending on the program it s being simulated The sections of the robot that can be viewed and controlled in the simulation are the following e Movement lights and sound shows
12. Lights and Sound mOway movements Travelled Distance 0 0cm Lights ums Sound While the simulator executes the block Straight it indicates the direction of the rotation of the wheels and the travelled distance 1s 1ncreased um Simulation ts s gt Db D s gt b Eg cs s Movement Lights and Sound c Movement Lights and Sound ceni mOway movements Travelled Diareo Y Lights Travelled Distance 12 0cm www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 68 of 84 Once the block Straight has finished the robot would travel 12cm the simulator executes the block Lights and the front LED lights This done the simulator ends Simulation I gt gs gE Travelled Distance www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 69 of 84 8 mOway Scratch 8 1 Introduction Now mOway is also compatible with Scratch The communication between Scratch and mOway is bidirectional Scratch receives the mOway detectors value and at the same time mOway receives Scratch commands This functionality uses Scratch sockets connection to obtain data from remote sensors and uses send to all commands for sending orders to mOway In this case mOway Scratch application works as data gateway between Scratch and mOway we Scratch MowayWorld Robot mOway The conne
13. established by means of arrows In order to connect the modules following steps must be taken e Place the cursor over a module until red and white marks appear e Click on one of these marks e Click on one of the next module mark x Image 30 Arrow drawing Connector tool makes easier to draw arrows It is located on Toolbar For selecting diagram elements it is necessary to change to the default Cursor tool Image 31 Cursor tool and Connector tool icons All the modules of the diagram must have at least one input arrow In addition they must have one output arrow two output arrows in case it is a conditional module The conditional modules oval shaped have two outputs depending on the condition If the condition is true the program will flow through true path arrow with a green mark If the condition is false the program will flow through false path arrow with a red cross www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 32 of 84 In order to describe a loop the procedure is similar but in this case the arrow starts on a module mark and finishes on another mark of the same block Image 32 Arrow drawing for a loop The arrow track can be modified dragging the marks that appear when the cursor is over the arrow Image 33 Modifying arrow track 5 1 7 Language change and updates The language of MowayWorld can be changed from toolbar L
14. of sensors which aid it to move in a real environment It also includes a drive unit which moves over smooth terrain commanded by a I2C communications bus All these peripherals are connected to a microcontroller responsible for governing the robot This small robot incorporates I2C SPI expansion bus options As an example a wireless communications module a video camera or a prototype card can be connected to it as well as any other device considered interesting to perform a certain task mOway s external design is very compact intended to move with grace and style avoiding standstills due to obstacles or corners This small mobile device has been fittingly called a pocket robot mOway is a perfect tool for those who want to both learn and teach minirobotics The user will be pleasantly surprised by the speed in achieving results even if this is the first time he she comes into contact with mobile robots www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 7 of 84 3 Robot mOway This chapter describes each of the parts that constitute the mOway It is important to highlight that it is not necessary to know the total functioning of the robot to be able to program it at least not at the level of detail explained here The following elements are to be found inside mOway Processor Drive system Sensors and indicators group Power supply system An expansion connector
15. projects in assembler C and MowayWorld o Example projects to start working with mOway easily e RFUSB Driver o Driver for RFUSB that establishes the communication between robots and PC e mOway Camera Board Driver o Driver for mOway Camera Board that makes it possible to grab images from mOway camera to display on PC If a security warning message appears during installation please click on install driver anyway MowayWorld software is safe 13 Module not available in all kits Module not available in all kits www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 23 of 84 MENU CD Setup MOWAY CD MENU lO Open CD Image 21 CD menu 4 2 Download a program to mOway Program download process is executed in MowayWorld This application can download to the robot MowayWorld projects assembler projects compiled with MPLAB or gputils and C C18 compiler projects Steps to download a program to mOway e Connect mOway to the PC through USB The robot doesn t need any driver e Open MowayWorld application e Open or create a project in MowayWorld or import a hex file from assembler or C project e Click on Program mOway icon If a hex file has been imported the download progress will start automatically e Disconnect the robot and turn it on mOwayPack provide several compiled projects to check sensors drive system RF communication and camera usage 4
16. to 20 KHz The output is directly connect to an analog input of the microcontroller so that it is capable to detect not only if there is sound or not digital mode but also the intensity of the sound with a simple reading of the ADC analog mode Temperature measured by the sensor can be 5 C higher than external temperature www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 15 of 84 3 3 8 Accelerometer An accelerometer is a device that measures acceleration and the gravity induced forces the movement and rotation There are many types of accelerometers most of them based on piezoelectric crystals but their size is too big Because of that 1t was tried to design a small device in the field of microelectronics which might improve the applicability Then the MEMS Microelectromechanical Systems accelerometers were created An easy way to create an accelerometer is measuring changes in a capacitor Capacitors can work as sensors or as actuators In the case of mOway it 1s a capacitive accelerometer which consists of two capacitors displaced in differential mode whose electrical capacity changes as the acceleration varies By measuring X Y Z axes of the MMA7455L accelerometer from FREESCALE Semiconductor it is possible to know if mOway is correctly positioned inverted or tilted 3 3 9 Battery level The robot has a LiPo cell battery rechargeable For proper operation of the mic
17. well change the channel and try again In case the robot is not programmed with mOway RC Client it can be programmed pressing Program mOway button 6 3 2 Movements Once the RFUSB is connected mOway can be sent commands The robot s movements can be controlled by means of the panel buttons or keyboard W S A D keys There also are two bars to determine the speed and turning curvature The covered distance can be reset with Reset distance button 6 3 3 LED In this section mOway s four LEDs are switched on and off www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 59 of 84 6 3 4 Speaker In this section 1s checked the switched on and off of the robot s speaker in a particular frequency He robot can also reproduce music notes 6 3 5 Sensor status This section describes the values returned by the sensors at all times updated every second e ine sensors the darker is the surface the higher is the value e mOway environment brightness temperature and noise detected by the robot e Obstacles the closer is the obstacle the higher is the value e Acceleration 3 axis acceleration values 6 3 6 Camera It activates mOway camera on the selected channel for a maximum of 15 seconds While the camera is on the communication between mOway and PC stops in order to avoid interferences Once the activation time finishes the communication automatically starts again In ord
18. 3 RFUSB installation This 1s a device that makes it possible to communicate the PC and mOway A driver that is included in mOwayPack is required e The first time the RFUSB is connected the PC will detect it as a new device and an Assistant for new hardware found message will be displayed Select the No not this time option www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 24 of 84 e In the following window select the recommended option Install software automatically Found New Hardware Wizard Welcome to the Found New Hardware Wizard This wizard helps you install software for Moway RF USB e If your hardware came with an installation CD lt 4 or floppy disk insert it now What do you want the wizard to do Install the software automatically Recommended Install from a list or specific location Advanced Click Next to continue Image 22 Driver installation Wizard e Now the installation process will begin Found New Hardware Wizard Please wait while the wizard installs the software e Moway RF LISB EE libusbO dll AC AWINDOWS system32 Image 23 Windows XP driver installation e Assistant will then indicate that the hardware 1s installed www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 25 of 84 Completing the Found New Hardware Wizard The wizard has finished installing the software for
19. MOWAY BEGINNERS MANUAL Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 2 of 84 Copyright c 2013 Bizintek Innova S L Permission is granted to copy distribute and or modify this document under the terms of the GNU Free Documentation License Version 2 0 or any later version published by the Free Software Foundation with no Invariant Sections no Front Cover Texts and no Back Cover Texts A copy of the license is included in the section entitled GNU Free Documentation License www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 3 of 84 Index lu E C m 3 MEME u e 5 2 Wy UE bud rc e 6 I WROD OE DUCERE 7 SWEET m 7 aD MTN IAM UU acess E 8 3 3 Sensor and indicators SrOUP ccccssccccccccceseeseeeccceeeeeaeeeseeeceeeeeeeaaeaseeeeeeeeeeaaas 9 5E MEMBER 10 3 3 2 ODstacle d tection SENS OS sssrds esa A aas 12 SOSA LE O e E E E A EO 13 Dis Epa on on O e A Le oe ndo LENUDUE 13 Sx Zonipctablte Se MS OP ieira Ea SE E DU SUE RN Ud 14 DOO WC ACF TEE 14 Fade NI OPINION ay crtcenteereeet ices moines aera Dictum maus Bu cum nexu a cci mu ene 14 ane EMME ee seil MEO 15 5 BAU ee ra a E E E E T E E A 15 3 3 10 PON EED eere eT CR ES 15 3 3 11 a a A D b A E E E A A E E E 15 9 9412 loriq Br br A rt srerer TT 16 3 3 13 TEP e eee ee 16 Ds Power Supply System sesiis n E R aai 16 33 RP modul rds rec ee est
20. Sensors Check This group of modules makes it possible to get the mOway s sensors values These are conditional modules so that they have two different outputs if the condition configured in the module is true the output will be true green mark on the flowchart Otherwise if the condition 1s false the output will be false red cross on the flowchart e Obstacle This module checks the digital value of the four obstacle sensors Each sensor can perform one of the following conditions o obstacle detected o no obstacle detected o detection inactive In addition it makes it possible to check the AND or OR boolean operation If AND option is checked all the conditions must be true to get a true output On the other hand if OR is checked just one of all the condition has to be true to get a true output Sensors Obstacle Detection Configure mOways four different obstacle sensors and connect them with the and or operator to set the condition for a true and false output Need help Settings Left Central Sensor Right Central Sensor Obstacle detected Ez Obeincle deiected Left Side Sensor j Right Side Sensor No Obstacle as IN Detection inactive AND Q OR Output TRUE If obstacle detected on upper right corner AND no obstacle detected on right corner FALSE Otherwise w Save Cancel Image 46 Sensors Check Obstacles configuration window w
21. anguage tab It 1s also possible to check if MowayWorld needs to be updated in Help Check for updates www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 33 of 84 3 2 First program in MowayWorld This first basic program will make mOway avoid obstacles Once MowayWorld is launched save this project as first program 1 Once the project is saved the program starts with a 2 second delay Just drag and drop a Pause module and configure it with a constant value of 2 seconds 2 The command to make green LED blink is added with the Lights module Configuration of both modules are shown below In the Light Mod blink Need help Commands for mOway Here the application programmer have to write a little description of Front No Change v the window NU No Change 7 Settings Pause time Constant Time 2 00 seconds 0 05to 12 Image 34 Pause and LED configuration ule you can control mOway s four LED lights Switch them on off or let them Top green Let Blink c Topired No Change F AAM Cancel 3 The end of the program is added Finish module so that the application can be compiled 4 The program is compiled and recorded into the robot clicking on Program mOway button in the toolbox shown in the next image 5 Test the program and check that after waiting 2 second th
22. ariables Name Init Value ObstacDetect o SpeedVal 50 Image 55 Variables window 5 5 Functions Subroutines A function or subroutine is a piece of program that can be used in another program For example a user can develop a diagram that turns on the front LED waits one second then turns off the LED and finally waits one more second If this program is defined as a Function it can be called from the main diagram In order to create a new function click on icon and give it a name for example MyFunction A new tab called MyFunction will appear on the top of the flowchart editor lain Image 56 Creation of a new function The functionality described above can be developed in the MyFunction flowchart editor www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 53 of 84 Main MyFunction Image 57 MyFunction diagram In order to go back to the main diagram click on Main tab There the MyFunction function can be called Flowchart Control Call Function In the Call Function configuration window MyFunction is selected In this example it 1s called three times so that the front LED will blink three times once per second Main MyFunction T Image 58 Calling MyFunction three times from main diagram www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 54 of 84 6 Applic
23. ariation of the accelerometer value in its 3 axis The value of the accelerometer in each axis varies between 2g and 42g being g the acceleration of gravity 9 81m s For example if we simulate that mOway is on an even surface the values are the following gt i UE meer i www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 66 of 84 e Communications it simulates the transmitting of RF data to the mOway robot and also the receiving data sent by the robot Emitter data field simulates the data sending to the robot mOway data field shows the data sent by the simulated robot Simulation gt ib es s Communications m Emitter data Emitter Address 2 1b 4a Channel 0 e e e o e e e e Send Transmitter Data 7 Data prose e Registers it shows a list of the variables created in the program with its values at all times Simulation gt Ib gg EH E Registers Name Value aenasorvalue1 0 sensorvaluez 13 www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 67 of 84 7 3 Simulation example The following example shows the simulation of a program in which the robot moves straight for 12cm and then lights the front LED Pressing the button Animate or Step In a yellow arrow indicates where the simulator is in the diagram Simulation 9 3 s Flowchart C Movement
24. ations 6 1 Communications Window The Communications Window makes it possible to send and receive RF messages using RFUSB device connected to PC In order to start RF communication press the Communications icon mOway World Edit Project Functions Variables Window Help paola O UOlo e COME t O Image 59 Communications icon The Communications Window will appear on the right side of the workspace In order to start RF communication choose an address and a RF channel for the RFUSB 2 and 0 in this example and press Start button Communications RFUSB Config Address 2 Channel 0 gt Start E Stop RFUSB gt Moway Moway Address 1 olojolojo oj oj o 7 Send Transmitter Data7 Data dm time 16h 5b4m 10s 378ms 1 183 0 0 19 60 91 143 136 3 time 16h 54m 10s 88ms 1 182 0 0 16 60 22 0 0 time 16h 54m 8s 810ms 1 181 0 0 86 249 251 0 0 Image 60 Communications window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 55 of 84 In order to send a message from PC to mOway select mOway robot address 1 in this example write the data to be sent from Data 7 to Data 0 and press Send button If a 0 is selected for Moway Address the message will be received by all the robots near the PC When RFUSB receives a message from mOway the communication window displays the time when the message was received an
25. ators equal different lt gt greater gt greater or equal gt less lt less or equal lt o Data compares a variable with a constant value or a user variable o Time compares elapsed time Values goes from 0 1 to 25 5 seconds o Speed compares one of the wheels speed value Values www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 45 of 84 goes from stopped to 100 maximum speed o Distance compares distance value covered by mOway to a variable Value goes from 0 to 255 centimetres o Angle compares the value of mOway turning angle Value goes from 0 0 degrees to 100 corresponding to 360 degrees Only changes with Rotate module o Brightness compares the light sensor value Value goes from O dark to 100 light o Line compares one of the line sensors value to a variable Value goes from 0 white colour detection to 100 black colour detection o Obstacle compares one of the obstacle sensors value to a variable Value goes from 0 no detection to 100 closest detection o Accelerometer compares one of accelerometer axis value Value goes from 2g negative acceleration limit to 2g positive acceleration limit When there is not acceleration the value is 0 NOTE g value is 9 81m s o Noise compares microphone value Value goes from 0 silence to 100 loud noise o Temperature compares the robot temperature va
26. ction between mOway and Scratch is done by the mOway RF modules and the RFUSB module connected to the computer Therefore it is necessary having the RE module placed in the mOway expansion slot and the RFUSB module connected to a computer USB port 8 2 Functioning The mOway Scratch communication is activated by opening mOway Scratch application o mOway Scratch E RF channel www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 70 of 84 The Program button programs the needed firmware in mOway for a right connection with Scratch In this case mOway robot should be connected to a USB port The firmware will be programmed to work in the selected channel in the RF channel box Once the firmware is programmed in a certain channel this channel should be selected when we get connected to Scratch To initiate communication the Connect to channel button is pressed mOway robot should have the Scratch firmware previously programmed the RFUSB module should be connected to PC and Scratch must be opened with a mOway sample program Once the connection from Scratch is started it is possible to obtain the value of any of the mOway sensors and also it is possible to send moving orders to mOway or switch on off the LEDs and buzzer To configure these actions we use variables in Scratch 8 3 Step by step 1 Connect RF module into the expansion connector of mOway robo
27. d o Distance assigns distance value covered by mOway to a www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 44 of 84 variable Value goes from 0 to 255 centimetres o Angle assigns the value of mOway turning angle to a variable Value goes from 0 0 degrees to 100 corresponding to 360 degrees Only changes with Rotate module o Brightness assigns the light sensor value to a variable Value goes from O dark to 100 light o Line assigns one of the line sensors value to a variable Value goes from 0 white colour detection to 100 black colour detection o Obstacle assigns one of the obstacle sensors value to a variable Value goes from 0 no detection to 100 closest detection o Accelerometer assigns one of accelerometer axis value to a variable Value goes from 0 negative acceleration limit to 255 positive acceleration limit When there is not acceleration the value is 127 range mid point o Noise assigns the microphone value to a variable Value goes from O silence to 100 loud noise o Temperature assigns the robot temperature value to a variable Value goes from 0 C to 255 C o Battery assigns battery level to a variable Value goes from 0 to 100 e Compare This group of modules makes it possible to compare a variable or a sensor value with another value constant value or user variable The following are the comparison oper
28. d the data The format of the data 1S e Address of transmitter mOway is displayed in brackets e Data arranged from Data 7 to Data 0 6 2 Moway Cam MowayCam application displays the camera images and lets the user to save a static image in a storage device connected to the computer This application can be launched from MowayWorld toolbar View gt mOway Cam or clicking this icon 2 QN x Image 61 MowayCam access from MowayWorld Once the icon is pressed MowayCam lateral panel appears www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 56 of 84 Camera Viewer Device M oway Videoc Li m gt Play B Stop T Capture Location Browser Name Capture1 jpg v Auto Inc Image 62 MowayCam panel This window displays camera images and allows the user to control the video receptor and to save a static image on PC e Click on Refresh button to see all the video devices connected to PC Depending on the driver version Moway video receptor may be named as Moway Videocap STK1160 Grabber or USB2 0 ATV e Click on Play button to start displaying camera images e Click on Stop button to deactivate video receptor Moway Camera Board e Click on Save button to save the current image in the path and name displayed on that fields IMPORTANT Video receptor Moway Camera Board MUST NOT be disconnected from USB port while MowayCam is showing camera ima
29. distance control Controls the distance travelled by each command with a precision of 1 mm aprox 4 General speedometer counts distances travelled since the initial command 5 Angle control controls the angle when the mOway rotates NO m The microcontroller sends the I2C command to the drive system that controls the motors and therefore releasing the main microcontroller so it can carry out other tasks Speed control is carried out by means of proportional control with negative feedback from the encoders signal The illustration displays the controlling system The microcontroller feeds the motors through an H bridge controlled by pulse width modulation PWM signals Wheel rotation is monitored by an encoding sticker and an infrared sensor When the sticker shows its black segment the logical output shall be 1 and when it shows the white sector the output shall be 0 The microcontroller analyzes these signals 1t can determine the exact wheel speed by measuring the pulse width and www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 9 of 84 acts on the motors This way the mOway will be able to keep the speed constant on any surface PIC16F687 Mecanic Diver system Image 3 Motor control To send a movement command to the robot via the main microcontroller all we need to do is send the movement command parameters To this end some libraries were designed in assembly and C lang
30. e w 0 255 ConstantValue m 0 0259 ConstantValue v o 6j 259 ConstantValue E o i 0255 ConstanVeue m 0 amp j 0259 ConstantValue E p 5j 0259 Image 51 Communicate Send configuration window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 50 of 84 e Communicate Receive This module makes it possible to receive a frame from a specific address It must be indicated at least two variables one for collecting the transmitter address and the other for the data If the data sent by the transmitter has been received correctly the output is true Otherwise the output is false Before using this conditional the RF communication must be configured using the Communicate Start module All the robots taking part in the RF communication must have the same channel and different addresses gD Communicate Receive a message In this module you can tell Moway to reveice a message from another Moway Meed help Commands for mOway VariabTxer VariRxed1 VariRxed2 No Variable No Variable Mo Variable Mo Variable INo Va ri able l i Image 52 Communicate Receive configuration window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February
31. e E E Oi 17 30 MOway Camera Modul eserse na a S E RU nio UD 20 3d MMO WA NC SCREEN mm 2 LE es RE UU 27 Behe wuOway Pack Ta8StallallOD sssrinin tron ar cesssasanaadacoenetesusewanneeendendeawes 22 4 2 Download a program to mOway sessseeeeseeeeeeeeeee nennen nee 23 dos RFO B fnsallatlollssstee epa eto EE 23 4 4 mOway Camera Board drivers installation cc cceccecccccccceesseeeeeceeeeeeeeaeeeees 26 5 MowayWortld programming osi imapitue Re quOBesqex ieena Eeen n S pU MASON DUE 28 5 MowayWorld workspace ccccccccccccccccceesseseeeceeeeeeeeeeseeecceseessaaeeesseeeeeeeeeaaas 28 MEME FU C 28 J2 Flowchart POOL eesse assure edes uvam ostec nea RM ceeereoesceedossee 28 AP MEE e 20 IE POS aaa cst deut dades idu eM citet Mu ietciuim Pa 30 XP TMT MIRI Um 30 As AO T E 31 JJ AAS WAC CMAN SS and Updates esrus iesen EEE EER 32 5 2 First program in MowayWorld ssssssssseeeeeeeeeeeeeeee enne eene 33 Su M 37 Jods MOWI E COIT 37 209 25 SSEBSORS C TEC Eoo E E E DIU EOE 4 55352228827 N 43 www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 4 of 84 5 94 Blowechirt C ON 0 Ih asco forsee east osceopes bos edesistesdern esent TE 46 sx MEE SUL e 46 x ES ANON RN EE 5 Su Func
32. e green LED blinks www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 34 of 84 Image 35 Flowchart of the program and Program mOway button 6 In order to detect obstacles four Sensor Check Obstacle has to be added and configured one for each obstacle sensor Configure mOways four different obstacle sensors and connect them with the and or operator to set the Configure mOways four different obstacle sensors and connect them with the and or operator to set the condition for a true and false output Need help condition for a true and false output Need help Settings Settings Left Central Sensor Right Central Sensor Left Central Sensor Right Central Sensor Detection inactive c Detection inactive Obstacle detected Zz Detection inactive c Left Side Sensor Right Side Sensor Left Side Sensor 7 Right Side Sensor Obstacle detected F Detection inactive Detection inactive J Detection inactive Configure mOways four different obstacle sensors and connect them with the and or operator to set the condition for a true and false output Need help Configure mOways four different obstacle sensors and connect them with the and or operator to set the condition for a true and false output Need help Settings Settings Right Central Sensor Left Central Sensor A Right Central Sens
33. ed It makes it possible to control mOway movements LEDs and read some sensor values www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 61 of 84 e Moway Web Server C fi 169 254 3 1 amp extendd Mis enlaces Robots Moviles Infr minirobots es Moway server Light sensor 72 Motion control Obstacle sensors i 7 a Battery level 69 2011 Bizintek Innova L Image 68 A Moway Web Server NOTE Connecting to MowayNet or web server displaying can take a while depending on the wifi connection and on the web browser www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 62 of 84 7 Simulation 7 1 Introduction MowayWorld simulator allows testing the working of a program before programming it in mOway robot In this way you can detect any errors you could have in the program and fix them quickly The simulator is opened from the toolbar NOTE When you activate the simulator the side panels remain inactive ject Functions Variables Simulation Moway RC Language Help Tile Deactivate Run Simulation F5 F Ctrl F5 Animate Pause Simulation Reset Simulation Step In F10 F11 Step Over Image 69 Simulator access By activating the simulator it will appear in the side panel Simulation gt ib BH Movement Lights and Sound mOway movements Travelled
34. eflective IR beam the light reflected in the terrain In the images below the three possible cases can be observed 1 Clear surface A white surface reflects all the infrared light and therefore we obtain a low voltage reading at the transistor s output when in regular mode www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 11 of 84 Image 5 Line tracking sensor on a clear surface e Colour surface A colour surface reflects part of the emitted light obtaining an intermediate voltage at the microcontroller s analog channel input This way colours are easily identified Es ES iiz Image 6 Line tracking sensor on a colour surface 1 Dark surface A dark surface reflects very little light obtaining a high voltage reading at the sensor s output Image 7 Line tracking sensor on a dark surface Due to CNY70 tolerance two different sensor can differ www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 12 of 84 Image Location of line sensors 3 3 2 Obstacle detection sensors Similar to line tracking sensors obstacle detection sensors also use infrared light to detect objects located in front of the mOway The sensor includes two infrared light emitting source Kingbright KPA3010 F3C and four receivers placed on both sides of mOway The output of the Sharp PTIOOFOMP receivers are connected to the microco
35. eginners Manual Rev v3 1 0 February 2013 Page 84 of 84 www moway robot com
36. er to watch camera images it is necessary to launch Camera panel 6 4 MowayServer This application allows mOway to communicate with other devices such as phones tables and PCs through Wifi technology These devices can connect to the net established by mOway by means of Moway Wifi Module Once they are connected the robot can be controlled from device web browser The application is launched from toolbar Communications Moway Cam Results Window mOway Scratch Image 66 Access to Moway Web Server P Module not available in all kits www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 60 of 84 The lateral panel appears Web Server 1 Select IP and program 1692543 1 amp Program web server 2 Conect to the wifi net MowayNet 001 3 Launch web browser Moway web server Image 67 Moway Web Server panel In order to communicate with mOway Web Server it is necessary to follow these steps 1 Select an IP only the last field can be modified and press Program web server button 2 The robot will establish an adhoc wifi net with the name MowayNet is the selected number for IP in the previous step 3 If the web server will be accessed from PC press Moway web server button to launch web browser with the selected IP If another device 1s used launch web browser and introduce the selected IP Once this 1s done the mOway Web Server will be display
37. es are grouped by a more specific type Movement Sound This is represented by a little black arrow in the toolbox module types www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 30 of 84 5 1 4 Properties When a module in Flowchart Editor is selected the Properties window will appear on the right side of the workspace This makes it easier and faster to change the modules configuration Movement Straight Wheel Speed Constant Speed 50 E 0 100 Direction go forward C go backward Command run 1 continiously CJ for time limit Constant Time 01 j 01255s for distance limit Constant Distance 02 01255m finish limit before continuing Image 28 Straight module properties 5 1 5 Error List Error List window shows the errors found in the diagram It includes a description of the error Description and the diagram in which the error has produced Diagram A diagram with errors will not be downloaded to the robot Error List Description Diagram j X Error 410 Action element has to have one or more previous Main X Error 422 Action element has to have one next Main M Error 421 Start element has to have one next MyFunction z Image 29 Error List window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 31 of 84 5 1 6 Arrows Modules execution order is
38. ges If it is disconnected while showing camera images some computers could restart Click on Stop button or close MowayCam panel before disconnecting it www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 57 of 84 6 3 MowayRC MowayRC is an application to control mOway as if it was a radio control device and to monitor all the robot s sensors This tool which uses RF BZI RF2GH4 modules and RFUSB mOway Base is compatible is very useful for all those users wishing to explore the field where the microbot will perform Its functioning concept is as follows the application transmits commands by means of the USB to the RFUSB which transmits them to mOway where a recorded program interprets those commands Moway RC Client included in Moway Pack Image 63 Moway RC Diagram mOway World Edit Window Help beeper o mOway RC Radio Control Settings Movements mOway Enviroment 100 ape 402 N A Brightness Program mOway LL T EOS d I j 18396 Temperature roe X HG on a E Battery Change channel 23 0 C bo m zm EM uu I Channel 0 mOway Control Speed um 7 Donis Distance 0 0cm Obstacles Front Light On Top Green Light On Left Central Value Right Central Value O Brake Light On L Top Red Light On 0 0 Line Sensors Ij NN Left Side Value a EN Right Side Value 0 Hj N 0 Left Sensor Value Right Sensor Value urs 248 252 dad Sou
39. ing radius Constant Radius Turning direction 9 turn right Flowchart Control Commands run e continiously until next movement module in flowchart Q for Constant Time X 0 1 s seconds 0 1 to 25 5 for Constant Distance 0 2 centimeters 0 1 to 25 5 O finish time distance limit before continuing with the next action in flowchart w Save X Cancel Image 42 Movement Turn configuration window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 39 of 84 e Movement Rotate With this command mOway will rotate either on its centre or on one of its two wheels Turning direction and rotation speed can be defined Movement Module Rotate in this Movement Module you can let mOway rotate around its own axis rotate center or around one wheel rotate wheel Need help Commands for mOway Rotate Speed Constant Speed 50 H ox 100 Rotation Mode 9 Rotate about the center of Moway right CW Rotate ona Moway wheel right wheel forward E Flowchart Control commands run continiously until next movement module in flowchart O for Constant Time 0 1 seconds 0 1 to 25 5 for Constant Angle p 3 6 degrees 3 6 to 360 O finish time angle limit before continuing with the next action in flowchart Image 43 Movement Rotate configuration window e Movemen
40. initely with a speed of 50 mOway goes straight backward indefinitely with a back speed of 50 mOway tums 90 degrees ef Ftumaround mOwayumsaomd SSS op mOmysps 7 reset distance To reset the total distance counter motors mOway goes straight at a certain speed for the m distance distance or time time If time and go straight ee T distance distance are same than zero mOway will move indefinitely ume speed mOway goes back straight It s behaviour is identical to eo straight but in the opposite way distance back straight time www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 75 of 84 mOway moves in a curve to the left of a certain HE o left radius at a certain speed for the distance distance radius or the time time If time and distance are distance same than zero mOway will move indefinitely UE speed TTE mOway moves in a curve to the right Identical but radius ec in the opposite direction of go left distance hme speed mOway goes back in a curve to the left Identical radius back left o u go left but going backwards distance hme speed EINER mOway goes back in a curve to the right Identical radius but in the opposite direction back left distance hme mOway rotates at a certain speed in a certain angle speed rotate left to the left on its axis or on a wheel If the angle
41. ions eo 010 46 UL 10 2 een ee EE E EE A E DUE LDUR 52 APPR AU ONS assoc esisctataar ocr E E E E E E E 54 6 1 CommunicdHdonBs WIHdOW seien etat tetistesedoosres tutes de ETE OEA 54 052 Mona aa ssc cs assets esas E E Poo ea esp ea DEMOS CR Ra UC ea dU PME 55 Dos MRE e E E E E E E A AE 57 Odi RECO AO e EEE SA UUENE 58 oris PEL Me LEN RO ee ee ee 58 du MEE LP 58 QT EE A ahaa acess E E 50 ede MEE S 11018 GS 12 1 NR 59 GC Pa Rc Rom 59 Di MON Y onsectetuer Muret M UN MAD EI Re REEL ME P DM DEI REN NELUMUE 50 SRE LOM NET E E A A 62 dAl T Ode dam E TE 62 Di seno DANN OL 63 Vide SMM ATOM S CUL DI SORT c m 67 AWA ESTE 2I TUNER LT 69 VM EE etr 69 8 2 NUON ie o cease ete ede satan cesi instet E 69 Be ECD DY SLC O S 70 5 4 Commands ANG SCOSOTS icsscrsesccracdiatecdoassccacptacsheceseasastedietecionasaiaiaceicerivescesents 74 O IS RTT 78 5M PREME GS o UIC RES SERRE mmm 78 8 5 2 Enclosed acerca es danas acnesends fecgacisesn tone dene dneseuniatienese ED E DNE LIEU E DEM e UE SO INOW E Sl RA ACC 21 0 16 1 T NIRE 82 www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 5 of 84 1 Prologue The dawning of a new era the era of the minirobots Increasingly more mobile robotics applications enter our daily life We can currently find robots which help us with simple tasks like cleaning household floors
42. lue Value goes from 0 C to 255 C o Battery compares battery level Value goes from 0 to 100 www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 46 of 84 5 3 4 Flowchart Control e Pause This module makes it possible to insert a pause in the program with a duration set in multiples of 0 05 seconds The pause parameter may be a constant or a variable e Call Function This module makes it possible to call a function or subroutine defined by user Subroutines will be explained on chapter Functions Subroutines e Finish This module sets the program end If the program consist of an infinite loop this module 1s not necessary 5 3 5 Expansion This group of functions makes it possible to control the expansion connector of mOway robot either to use radiofrequency RF communication mOway camera module or user expansion modules WARNING Only advanced users can use the pinout configuration Any incorrect connection of electronic elements to the expansion connector may damage the robot irreversibly or the user circuitry e Module IO Configuration This module configures the expansion connector pins as inputs or outputs and assigns a initial value for outputs www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 47 of 84 a IO Module Configuration In this module you can configure expansion ports as inputs or outpu
43. n when g key pressed when n key pressed broadcast frontled off broadcast buzzer aff www moway robot com Light sensor value ET Temperature sensor value 27 Line Left sensor value EU X Axis g sensor value Z Axis g sensor value ETEN 8 5 4 Accelerometer Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 82 of 84 Battery sensor value EUN Distance sensor value Line Right sensor value EET Y Axis g sensor value In this exercise mOway acts as a remote control of a console game using the accelerometer This program can be found in the Scratch projects folder in mOway Pack named moway accel sb The purpose is to keep mOway inside the square Tilting mOway the Scratch objet will move across the screen In the case we touch the edge mOway will activate the buzzer and the front LED www moway robot com when clicked go to x i LE n pen down set frequency to forever TF me D 0S Bette Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 83 of 84 set x to x position 4 Axis g sensor value set y to y position T AXis g sensor value if touching dge broadcast frontled on broadcast buzzer on wait 0 2 secs broadcast frontled off broadcast buzzer aoff EE i We can change the exercise adding more obstacles and more difficulty www moway robot com Title mOway B
44. nd Acceleration 244 14 Hz 244 14to 62499 84 P Start Beep Acceleration in X axis 0 453125 G D mera Acceleration in Y axis 0 1875G Channel gt Start Acceleration in Z axis Activation time seconds 5 0 90625 G Image 64 Moway RC Center F www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 58 of 84 You can access the application in View Moway RC The program mOway RC Client is downloaded in the robot and the application starts The fields of the RC Center will be explained on the next lines Functions Variables Window Help C MemRc Moway Cam Communications mOwayserver St im Image 65 Access to Moway RC 6 3 1 RF configuration In this part the RFUSB module is configured with a 2 default address and 0 for the communications channel default mOway RC program channel Once connected the communications channel can be changed if WI FI Bluetooth Microwaves other mOways etc interferences are detected in this first channel Click on the change channel button to select up to 16 channels To change the channel the robot has to be switched on and be in communication with the RFUSB Every time the RFUSB is disconnected the default channel shall be 0 The recommended procedure is as follows 1 Turn the robot on 2 Connect the RFUSB 3 Test the channel sending mOway commands 4 If the robot does not react
45. ntroller s analog inputs so it can detect the presence of any object digital mode and also measure how far away it 1s analog mode The sensor functions similarly to the line tracking sensor The light emitter generates a 70us pulse which makes the receiver to capture any obstacle using a filtering and amplifying stage Once the signal 1s processed electronically the PIC can measure it by means of the ADC or as a digital input The digital distance range is close to 3cm and a bright environment is recommended to enhance infrared light reflection Image 9 Obstacle detection sensor Due to tolerance two different sensors can differ from each other www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 13 of 84 Image 10 Location of Obstacle Sensor 3 3 3 Light sensor This sensor makes mOway to recognize the light intensity that enters through a small half moon shaped opening on the top part of the chassis Since it 1s facing forward it enables it to detect where the light source is located and to act accordingly The output of the AVAGO APDS 9002 sensor is connected to the analog port of the microcontroller so that with a simple reading of the ADC we can register the light intensity level and any change in intensity levels based on the last reading Image 11 Location of Light Sensor 3 3 4 Expansion connector This connector allows the mOway to connect with any commercial modules or
46. ommunications module is based on the nRF24L01 transceptor manufactured by Nordic Semiconductors This integrated circuit has been fitted with all the logic required to establish wireless bidirectional communications with acknowledgement of receipt Communications with the microcontroller 1s made via an SPI bus The main characteristics of the BZI RF2GH4 module are as follows Low consumption Working frequency 2 4GHz Transmitting power between 18 and 0 dBm Transmission speed between 1 and 2 Mbps 128 in transmission channels selectable by the SPI bus In addition to the CI nRF24L01 the BZI RF2GH4 is also fitted with all the associated electronics for its correct operation plus a microstrip antenna on the same board with the impedance adaptation network In this way the user can forget completely about the hardware required to implement the radio part of his application As interface the device has four pins available for the SPI bus two more pins for controlling the module and another two for the supply www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 19 of 84 In order to facilitate the handling of the module a number of libraries have been developed to simplify and shorten the development time of wireless applications with these modules www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 20 of 84 3 6 mOway Camera module Thanks to
47. on Mode 9 Rotate about the center of Moway let cow M Rotate on a Moway wheel right wheel forward X Flowchart Control commands run continiously until next movement module in flowchart O for Constant Time 0 1 seconds 0 1 to 25 5 for Constant Angle 180 0 degrees 3 6to 360 M finish time angle limit before continuing with the next action in flowchart Ww Save Cancel Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 36 of 84 Movement Module Straight In this Movement Module you can give mOway the command to move straight Need help Commands for mOway Wheel Speed ConstantSpeed w 70 100 Direction e go forward Oo go backward Flowchart Control commands run continiously until next movement module in flowchart seconds 0 1 to 25 5 centimeters 0 1 to 25 5 for Constant Time o 1 for Constant Distance x 0 2 O finish time distance limit before continuing with the next action in flowchart IT Image 38 Movement and Rotation configuration Image 39 End of first program in MowayWorld www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 37 of 84 5 3 Modules The mOway programming consist of functions or actions that control the robot Modules are these functions or ac
48. or Left Central Sensor A Detection inactive Z IM Obstacle detected Detection inactive S Detection inactive Left Side Sensor i ERN amp Right Side Sensor Left Side Sensor ERN amp Right Side Sensor Detection inactive Detection inactive F Detection inactive Obstacle detected x AND OOR Image 36 Check Obstacles configuration www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 35 of 84 7 Condition modules have a true output and false output When the obstacle is detected the condition is true green mark and the corresponding LED turns on If the obstacle is not detected the condition is false red mark and the corresponding LED turns off LED control is done with Lights modules 8 Test the program and check that the front LEDs light up when an obstacle is detected Image 37 First MowayWorld program obstacle detection 9 We add an straight forward movement indefinitely until an obstacle is found 10 When an obstacle is found a command is sent to the robot to rotate 180 The robot will continue to move in a straight line when the rotation 1s completed www moway robot com in this Movement Module you can let mOway rotate around its own axis rotate center or around one wheel rotate wheel Need help Commands for mOway Rotate Speed Constant Speed H 30 100 Rotati
49. robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 73 of 84 Laht sensor value BERI Merophone sensor value BERI Distance sensor value 7773 36 Line Left sensor value arm Line Right sensor value Em gt BERE X Axis g sensor value ETT Z Axis g sensor value EEB Y Axis g sensor value EE In case several robots are used in different PCs it is necessary to assign a different channel for each one in order to avoid interferences between them These are the steps to follow 1 Ifthe communication with Scratch has been started press the Disconnect button 2 Assign a different channel to each robot in this case the channel 4 is selected RF channel www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 74 of 84 3 Reprogram the robot by pressing the Program button 4 Once the robot has been programmed disconnect it from the PC and switch the robot on 5 Press the Connect to channel button 8 4 Commands and Sensors The actions available to run from the Scratch environment are displayed below as well as the variables for each action The command sending to mOway is done by using the control broadcast block beoadcast rotate lett For example the message rotate left would make a left rotation Action Description Used variables mOway goes straight forward indef
50. rocontroller the battery is connected to one of its analog inputs through a splitter Thus with a reading of the ADC battery level can be measured 3 3 10 Front LED The front LED is a white LED placed on the front side of mOway The output of the OSRAM LW A6SG LED is connected to a digital output of the microcontroller 3 3 11 Top two colour LED This double indicator and the light sensor share the same opening on the top part of the robot They are connected to two microcontroller digital outputs Please note that since they share the same opening as the light sensor it is fundamental to switch them off when wanting to perform a light intensity reading www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 16 of 84 Image 13 Robot with Front LED and red LED switched on 3 3 12 Brake LED The brake LED is double indicator placed on the back side of mOway The output is connected to one digital outputs of the microcontroller Image 14 Brake LED location Switch on green LED 3 3 13 Free Pad mOway has implemented a free Pad to allow expert users to connect their electronics It is accessible opening the robot and it s located near brake LED 3 4 Power Supply System mOway s battery is located inside and accessible only by disassembling the product It is a small rechargeable LiPo cell The battery can be charged via a computer s USB port through the mOway s MINI USB
51. rotation rotation is same than zero it rotates indefinitely EDU speed mOway rotates to the right Identical but in the opposite direction rotate left rotate right rotation rotation axis fondo Activates the tront LED fontledoft Deactivates the fro LED fontled btink Blinks the from LED Tbraketed on Activates the brake LED Tbrakeled oft Deactivates the brake LED weed Blinks the brake LED semledon AciaesegmenlED oo _ E Do a Tao Activates all the LEDs www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 76 of 84 leds off Deactivates all the LEDs Los leds blink Blinks all the LEDs Se Activates the buzzer with a sound in a certain buzzer on meday frequency buzzer off To deactivate the buzzer Subprogram for enclosing mOway into a black enclosed circle It goes forward when it is on a white surface and it turns around when it reaches a black line uh Subprogram for pushing objects mOway searches P the objects and pushes them Subprogram for pushing objects out of a black EM defender circle It puts together the enclosed and push subprograms linefollow left Subprogram for following a line on the left side linefollow right Subprogram for following a line on the right side The following table sho
52. specifically designed for teaching and research Their purpose is to bring the world of autonomous robots closer to the teaching centers mOway s main purpose is to be a useful tool for those who are being introduced for the first time to the world of the minirobots as well as for those who are already experienced and wish to perform complex collaborative robotic applications mOway aims to stimulate enthusiasm for this new and exciting branch of engineering in a prompt and enjoyable way through the practical exercises included in this manual This manual has been implemented to assist learning how to use mOway It provides some basic notions on using mOway and its functions in a quick and clear manner This manual is divided in two parts The first part includes a description of the elements which form part of the robot and their functioning The second part of the manual includes a series of practical exercises that can be executed with mOway www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 6 of 84 2 What is mOway mOway is an autonomous programmable small robot designed mainly to perform practical minirobotics applications It provides a perfect hardware platform for those wishing to take their first steps within the world of mobile robots as well as for those who have already worked with minirobots and want to develop more complex applications The mOway robot is equipped with a series
53. t 2 Connect the RFUSB to PC E 3 Connect mOway robot to PC 4 Open mOway Scratch application a mUOWayoctdtcr www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 71 of 84 5 Select the language in which the Scratch programs will be developed in this case English i mOway Scratch E m 6 Press the Program button on the lateral panel this 1s not necessary if the robot has been previously programmed in this way 0 RF channel 7 Once the robot has been programmed disconnect it from the PC and switch the robot on 8 Open one of the Scratch projects for mOway You can open them form Start gt All programs gt mOway Pack v3 gt mOway Scratch projects For example open the moway RC sb project di mOway Pack n mOway Pack v2 de mOwayPade o mOway Datasheets miy Hir a a A A T a A amp 3 mOwayWorld 2 Uninstall J mOway Smart City 4 www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 72 of 84 9 Press OK Remote sensor connections enabled OF 10 Once the Scratch project is open press the Start button on the lateral panel of MowayWorld The panel status is the following 11 On the Scratch window you will see the sensor values When the arrow keys of the keyboard are pressed the robot will move www moway
54. t Stop This command stops mOway s motors e Sound Play This function makes mOway to emit tones from 244 Hz to 16 KHz It is possible to define the time that the speaker will be activated www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 40 of 84 Sound Module In the Sound Module you can tell mOway to play a tone at a specific frequency Need help Commands for mOway Frequency ConstantFrequency 244 14 herzios 244 14 to 62499 84 Flowchart Control Commands run continiously until next sound module in flowchart for Constant Time o seconds 0 1 to 25 5 O finish time distance limit before continuing with the next action in flowchart w Save Image 44 Sound Play configuration window e Sound Stop Stops the speaker sound e Lights This module makes it possible to operate on mOway s LED diodes You can turn them on turn them off or make them blink Light Module In the Light Module you can contro mOway s four LED lights Switch them on off or let them blink Need help Commands for mOway Front Turn On Top green Let Blink Brake Turn Off Top red No Change x Cancel Image 45 Lights configuration window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 41 of 84 5 3 2
55. the camera module mOway Camera Module it is possible to display on the computer what mOway is watching Camera board sends images wirelessly to the video receptor mOway Camera Board Image 18 Camera module Camera Module is connected to expansion connector of mOway robot It is controlled by robot programming It has a connector on the back so that other circuitry can be attached RF module or user circuitry Camera control is performed by Microchip MCP23S08 device which is an input output port controlled by SPI The basic functions are the following e Turn on When camera is on the LED of the module is on The camera sends images through RF to video receptor e Turn off When camera is off the LED of the module is off The camera RF transmission ends e Channel change When the camera channel changes the LED blinks As interface the device has four pins available for the SPI bus two more pins for controlling the module and another two for the supply Other wireless transmitters can affect the 1mages quality If so change the channel of transmission both camera and video receptor NOTE Both camera transmission and mOway RF module transmission are in the same frequency band So that when camera 1s active mOway RF module reception distance decreases ll Available in some packs Available in some packs www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 21 of 84
56. the state of the motors the state of the LEDs and the mOway speaker o The rotation of the wheels is indicated by red arrows It also reflects the distance travelled by the robot o The sound emitted by the robot 1s indicated by the speaker icon When it is green it simulates that mOway beeps When it is red it simulates that the sound has stopped www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 64 of 84 Simulation gt i oH Hc CE Movement Lights and Sound BN mOway movements Travelled Distance e Line and obstacles sensors simulates the change of the value of the line and obstacles sensors The value of the simulator sensors 1s defined by the analog value of the real sensors of the robot Therefore the value of the simulated sensor are the following Simulation gt o g E Line and Obstacle Sensors e je Obstacle not 0 to 127 detected Obstacle 128 to 255 detected www moway robot com Line Sensors eft Sensor Right Sensor White 0 20 Grey 21 229 Black 230 255 Obstacle Sensors Central Sensor Central Sensor 3ide Sensor Side Sensor 2 Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 65 of 84 e Environment it simulates the variation of the light and temperature sensors and the microphone was O o O Brightness 0 100 mes o l Rene enm e Accelerometer it simulates the v
57. til it reaches a black line This program can be found in the Scratch projects folder in mOway Pack named moway enclosed sb When one of the two line sensors detects a black line mOway goes back a bit turn around and continue Thus mOway will be enclosed within a black contour on a white surface At the same time the detection will be also reflected in Scratch Each time mOway detects a line the object will rotate and it will alert that a line 1s detected when clicked go to x D yi n point in direction Elha broadcast ga forever if Line Left sensor value gt or Line Right sensor value gt broadcast back Tha D Bette broadcast rotate left turn C degrees Line detected zz Secs broadcast go www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 81 of 84 8 5 3 MowayRC The following program acts as a mOway radio control using Scratch This program can be found in the Scratch projects folder in mOway Pack named moway RC sb With the arrow keys we control the mOway movement and with some additional keys we activate the frontal LED and the buzzer when up arrow key pressed when left arrow key pressed broadcast go broadcast rotate left when down arrow key pressed when right arrow key pressed broadcast back broadcast rotate right when key pressed broadcast stop when f key pressed when b key pressed broadcast frontled on broadcast buzzerio
58. tion An identification for the robot and a communication channel must be selected For establishing communication between two mO ways they must be configured with the same channel and an unique address for each one If the configurations is correct the output is true Otherwise the output is false lt 9 Communicate Start In this module you can configure communication parameters Communication Chanel Image 50 Communicate Start configuration window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 49 of 84 e Communicate Stop This module stops the RF communication It has not any configuration window e Communicate Send This module makes it possible to transmit a frame to a specific address The address of the receptor and the data which can consists of constants or variables must be indicated in the frame If the sent data has been received by the receptor the output is true Otherwise the output is false Before using this conditional the RF communication must be configured using the Communicate Start module AII the robots taking part in the RF communication must have the same channel and different addresses C Communicate Send message In this module you can tell moway to send a message to another Moway Need help Moway receptor Direction h 0 255 ConstanVaue w 5 0255 VariabData E 259 Constant Valu
59. tions that mOway can carry out moving reading sensors transmission of radiofrequency messages etc These modules are grouped depending on their function Each of the modules included in MowayWorld are described below 5 3 1 Moway Actions This group of modules makes it possible to control mOway s actuators motors speaker and LEDs Functions of these modules can be performed for a user defined period of time or distance if the finish time distance limit before continuing with the next action in flowchart option is selected If this option is not selected the function will be executed indefinitely until another module changes the current function e Movement Straight mOway robot has two motors one in each wheel These give it a great flexibility in its movements Movement straight command makes mOway to go forward or backward describing a straight line trajectory Speed value can be modified Movement Module Straight In this Movement Module you can give mOway the command to move straight Need help Commands for mOway Wheel Speed Constant Speed x Direction e go forward D go backward Flowchart Control commands run 3 continiously until next movement module in flowchart for Constant Time 0 1 seconds 0 1 to 25 5 for Constant Distance v 0 2 centimeters 0 1 to 25 5 O finish time distance limit before continuing with the next action in flowchart w Save Image 40
60. ts Line 1 Line 2 Line 3 Line 4 Line 5 Line 6 Input Input Input Direction Output Output Output InitValue on 1 onco e on co M oro s onc A on co Image 48 Module IO Configuration configuration window e Module IO Set Output This module sets On resets Off or toggles expansion connector pins that are configured as outputs WARNING Set Output values only can be assigned for pins configured as outputs leaving other lines with No change value If a value is assigned to an input this may damage the robot irreversibly g IO Module Set Output In this module you can set on off or toggle expansion output ports a 1 TION 2 m 3 Value ee 4 5 Ey 6 Image 49 Module IO Set Output configuration window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 48 of 84 e Module IO Check Input This module checks the digital value of one of the 6 pins of the expansion connector It compares if the value of the selected pin 1s equal or different lt gt to on 1 or off 0 e Camera Play This module activates the mOway camera One of the four channels has to be selected This channel must be the same of the Moway Camera Board video receptor e Camera Stop This module turns the camera off e Communicate Start This module configures the robot in order to establish a radiofrequency RF communica
61. uage to simplify communications through some functions which are responsible for I2C communications The format for these frames is explained in the motors and drive system library section The table below describes connections between the main PCB and the servo motor unit 3 3 Sensor and indicators group This group consists of different luminous sensors and indicators connected to the mOway microprocessor through which the robot interacts with the external world Two line tracking sensors Four obstacle detection sensors A light sensor An expansion connector Four LED diodes Temperature sensor Speaker Microphone www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 10 of 84 e Accelerometer e Battery level PIC 18f86j50 SPEAKER Image 4 Sensors and indicators group 3 3 1 Line sensors The line tracking sensors are two reflection optocouplers mounted on the top front part of the robot They use infrared light reflection to detect the colour of the terrain at the point where the robot is These two sensors are connected to two microcontroller analog ports so strong terrain contrasts like white lines on black backgrounds can be detected They are also capable of distinguishing different tones The Vishay CNY70 sensor has a compact construction where the emitting light source and the detector are arranged in the same direction to be able to detect by using the r
62. us programming knowledge is not essential to use flowchart programming 5 1 MowayWorld workspace The following lines describe the different parts of MowayWorld workspace 5 1 1 Toolbar Toolbar makes it possible to manage the project edit the flowchart create variables program mOway robot change MowayWorld language and many other functions mOway World Edit View Project Functions Variables Simulation Moway RC Language Help Ewe 5 f oagal Eo mQway Image 25 Toolbar 5 1 2 Flowchart Editor The Flowchart Editor window is where modules are placed and connected to develop the program When a new project is created this window is empty except for the starting point In flow diagrams there is always a starting point from which the program begins www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 29 of 84 Image 26 Flowchart Editor window 5 1 3 Tools On the left side of the workspace we can find the Tools section Here there are all the modules to control mOway such as movement actions checking sensors communication and so on Modules are grouped by their type of function Actions Sensors Data Flowchart Control and Expansion connector Image 27 Toolbox section A module is inserted by just dragging and dropping it in the flowchart editor This module function can be configured by making double click on it or in the Properties window see next chapter Some modul
63. ws the variables and the values can be taken for the correct execution of the commands ENEL G Description Range of values rotation axis Rotation axis Wheel over a wheel Any value over the center time Movement time in tenths of a 0 255 0 25 5 seconds second www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 77 of 84 The following table shows the mOway variables we can read in Scratch using the sensor value block Line Lett sensor value For example the previous block indicates the remaining battery level of mOway Variable Description Range of values Y Axis g Acceleration in g in the axis Y 2 0 to 2 0 g Z AXIS g Acceleration in g in the axis Z 2 0 to 2 0 g Motor End Activated sensor when the last 0 1 command sent to the motor has finished X AXIS g Acceleration in g in the axis X 2 0 to 2 0 g www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 78 of 84 8 5 Exercises For a better understanding of the mOway integration within the MowayWorld installer we include five sample exercises By default they are located in this folder Program Files gt mOwayPack v3 mOwayRobot mOway Scratch projects You can find them also in Start gt All programs gt mOway Pack v3 gt mOway Scratch projects 8 5 1 Geometric shapes The following Scratch program reproduces geometric shapes The examples can
64. ww moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 42 of 84 e Line This module checks the digital value of line sensors This module is very useful for making mOway follow a line black or white on the floor detect boundaries etc Each sensor can perform one of the following conditions o black line detection o white line detection o detection inactive In addition it makes it possible to check the AND or OR boolean operation If AND option is checked all the conditions must be true to get a true output On the other hand if OR is checked just one of all the condition has to be true to get a true output Sensors Line Detection Configure mOways two line detection sensors and connect them with and or operator to set the condition for a true and false output Need help Commands for mOway Left Line Sensor Right Line Sensor Black Line l White Line 9 AND OR Output TRUE Ifa black line is detected on the right side FALSE Otherwise Cv Image 47 Sensors Check Line configuration window e Noise This module has a true output if mOway detects a loud sound It has not any configuration window e Tap This module has a true output 1f mOway detects a tap or a high acceleration It has not any configuration window www moway robot com Title mOway Beginners Manual Rev v3 1 0 February 2013 Page 43 of 84
Download Pdf Manuals
Related Search
Related Contents
Le rapport au format pdf table Taïga - Vauconsant 025.0584-0 - Esmerilhadeira T mode d`emploi pour remplir la common application プレミアムゴールドモートル 取扱説明書(CO-SR型 洗面台横付型)(PDFファイル) CurricUNET User Manual iPad User Guide - Verizon Wireless モトローラ 特定小電力トランシーバー Copyright © All rights reserved.
Failed to retrieve file