Software Design

Published on December 2016 | Categories: Documents | Downloads: 49 | Comments: 0 | Views: 393
of 4
Download PDF   Embed   Report

Comments

Content

Software Design: The researchers used two environments namely, Microsoft Robotics Developer Studio 2008 R3 and NXT-G Software. These are used to manipulate the logic flow and the movements of the robot. Both environments are supported by the NXT Brick which serves as the brain of the robot. It is a requirement to have a communication first between the Brick and a said environment for it to read what the researchers had programmed. In this study, the researchers used Bluetooth as the channel of communication.

Microsoft Robotics Developer Studio Microsoft Robotics Developer Studio (Microsoft RDS, MRDS) is a Windows-based environment for robot control and simulation. It is aimed at academic, hobbyist, and commercial developers and handles a wide variety of robot hardware. They’re four major components in MRDS namely, CCR (Concurrency and Coordination Runtime), DSS (Decentralized Software Services), VPL (Visual Programming Language), VSE (Visual Simulation Environment). In this study, the researchers chose to use VPL or the Visual Programming Language. VPL is a graphical development environment that uses a service and activity catalog. It can interact graphically; a service or an activity is represented by a block that has inputs and outputs that just need to be dragged from the catalog to the diagram. Linking can be done with the mouse, it allows you to define if signals are simultaneous or not, permits you to perform operations on transmitted values. It can be linked only through mouse, linking one activity to another based on what logic you want to happen. The improved version of MRDS allows the users to write a software using LEGO Mindstorms NXT which the hardware the developers used. The developers used only few of the components under LEGO Mindstorms NXT, components that are needed for the program flow such as LEGO NXT brick, LEGO Sound Sensor and LEGO NXT Motor. LEGO NXT brick must be present in the program for the communication between the hardware and software to happen. LEGO Sound Sensor is actually the frontline component in the program because of the developer’s main function which is to detect music. Then Finally, LEGO NXT Motor is used to determine what motor will be in motion in a certain flow of the program. Other components in the program are called Activities. It is the default component in MRDS. Activity blocks such as Activity, Variable, Calculate, Data, Join, Merge, If, Switch, List Function and Comment. These blocks are used as different methods similar to hard coding in other Programming environments. Since the developers are non-professionals in the robotics field, they preferred using the Visual Programming Language which is easier to program with.

Since the Lego Sound Sensor can only detect the loudness of the music, the developers made a program where the Intensity it will detect will be converted into a calculation of Tempo. They had researched a way on how to calculate beats per minute or the BPM. Based on the researched data, BPM is computed through the time signature. They used the two common signatures which are 4/4 for the fast music and 2/2 for the slow to moderate music. They had also developed an If condition where, If the detected Intensity is greater than 50, then the number is multiplied to 4 prior to the time signature that is mentioned which is 4/4. Now, if the detected Intensity is less than 50, the number will be multiplied by 2 prior to the 2/2 time signature. After it had computed the BPM, the results will be shown in a dialog box and at the same time the robot will move based on the result which is another If condition. If the computed BPM is greater than 50 then the power of the movement of the robot is 0.7 of value which is fast but If the computed BPM is less than 50 then the power of the movement is just 0.3 of value. The computed BPM is linked to the Lego Motors of the Legs and Arms.

NXT-G Software The Lego Mindstorms NXT 2.0 might look like a toy but it a full blown robotics environment that is suitable for ages 10 and up. Meaning, it’s for both suitable for hobbyist and professional developer. Thus, NXT-G, the Lego Mindstorm NXT 2.0’s native integrated development environment is a very simple and intuitive, icon-based drag-and-drop programming language which was designed for an easy introduction for new users. NXT-G works by choosing program blocks that works with motors and makes the sensor react to stimuli or input. And through this, people can make programs to instruct the robot to do tasks that maybe simple or complex. The developers find the NXT-G very convenient but sometimes it tends to become sluggish and slow, even on powerful machines. Nonetheless, they efficiently managed to create a smooth logic for the program of their robot through the usage of the blocks. The first blocks that were used were the sound block. These were used to make the robot say some nifty phrases like “Music Please”. But in between these words, other blocks were used to make “spaces” or “pauses”, and these blocks are known as the wait block. And wait block can configure the length of the “pauses” or “breaks” and are measured in seconds. The actual objective of the robot was manipulated in a logic that started with the Sound Sensor block. Using data wires, it can send out the current sound value and a logic signal (true/false) based on whether the current sound value falls above or below a trigger point. Since the developer is aiming for the tempo, calculations shall be needed first, hence the sound value is what they need, not the logic signal. Upon “hearing” the sound, its value will now undergo into a computation through the Math block. The Math block can do the four basic mathematical operations plus the square root operation. The same formula that was discussed in the Microsoft Robotics Developer Studio shall be applied on this also. The difference is that, the developers used a constant block that has a constant variable 50 which shall serve as the comparison value. Both the sound value and the comparison value will now then go through another block, known as the Compare block. The compare block will check whether the sound value is greater than the comparison value. Meaning, if the computation’s output is above 50, and then the sound is fast and vice versa. After the comparison, the robot will now determine if the music is fast or not. It will now go into a switch block which is known as the Boolean of the NXT-G. If the value is true, another set of blocks were used, including the number to text bock to convert the number value into text, it is similar to the convert to string code in various programing language. The converted text will pass through the display block, which will be the one who’s responsible for displaying the text in the screen. Series and combinations of motor and wait block were used on the choreography of the robot. Same sense shall be applied on the false value but of course, the choreography is slower because the computed sound value of the music is below 50.

Sponsor Documents

Or use your account on DocShare.tips

Hide

Forgot your password?

Or register your new account on DocShare.tips

Hide

Lost your password? Please enter your email address. You will receive a link to create a new password.

Back to log-in

Close