View the step-by-step solution to:

CS 578 - Software Architectures Spring 2010 Homework Assignment #3 Due:

hey my hw is related to software architecutre,its my third hw.its based on second hw,i have done with second,its basically checking architecture on dradel,coding,csadel and related things,info is given in pdf file,but i have to give auxillary files also hw2.please check it and tell me
CS 578 – Software Architectures Spring 2010 Homework Assignment #3 Due: Tuesday, March 30th, 2010 In this assignment, we provide you with the domain model for the robotic scenario in assignment #2 as well as a simulation and graphical interface which simulates and presents the robots moving and following each other. You are expected to provide the C2SADEL specification for the robotic scenario and use a software architecture modeling and analysis tool, called DRADEL, to check the syntactic correctness as well as structural and behavioral soundness of your provided C2SADEL specification you developed. You are expected to provide a C2SADEL specification which enables 1. parsing (i.e., syntactic checking), 2. checking structural constraints, 3. type checking (i.e. behavioral checking), and 4. code generation in DRADEL. Your C2SADEL specification must be able to “pass” all four of these steps. For example, if you are not able to pass the structural constraint checking or type checking steps, you will not get credit for your implementation. The generated code skeletons are compilable on top of Prism-Lite, a simple architectural middleware platform written in Java, but they do not provide any application logic (also known as business logic), which in your C2SADEL specifications is reflected in the pre- and post- conditions. You are expected to implement the application-specific logic for the robotic scenario, by “filling in the blanks” of the automatically generated Prism-Lite code. The application must run with five robots, and the convoy should not break if the leader robot is out of battery. Domain Model Figure 1 depicts a domain model for the robotic scenario in assignment #2. The domain model in figure 2 provides the domain model for a single robot which is applicable for all the robots including the leader robot. In this assignment all the robots, including the leader robot may fail due to battery depletion. However, the robots convoy should not break in any case. When the leader robot is low in battery the front most robot should become the leader and when any follower robot is about to die, the robot behind it should switch to follow the robot in front of it. The convoy should start with five robots and should continue working until all the robots batteries are depleted.
Background image of page 1
2 AssignALeader BatteryIsGood Λ LeaderIsKnown Λ LeaderBatteryIsGood 7 E n d C a m e ra F o llo w in g LeaderIsKnown Λ IsCamerFollowing 8 10 9 E n d IR F o llo w in g ReleaseLeader LeaderIsKnown Λ IsIRFollowing LeaderIsKnown Ø 3 4 StartCameraFollowing BatteryIsGood Λ CameraIsWorking Λ LeaderIsKnown Λ LeaderBatteryIsGood BatteryIsGood Λ CameraIsWorking Λ LeaderIsKnown Λ LeaderBatteryIsGood Λ IsCamerFollowing 1 BatteryIsGood Λ LeaderBatteryIsGood 5 6 StartIRFollowing BatteryIsGood Λ ¬CameraIsWorking Λ LeaderIsKnown Λ LeaderBatteryIsGood BatteryIsGood Λ ¬CameraIsWorking Λ LeaderIsKnown Λ LeaderBatteryIsGood Λ IsIRFollowing 10 9 StartLeading IsLeader Λ IsLeading 9 SetAsLeader ¬IsLeader Λ ¬IsLeading ¬IsLeader Figure 1 Simulation Environment We provided two java classes to simulate and represent the environment and robots: Robot and Environment . The Robot class simulates a robot that has a color and an IR code and that can follow another robot using its camera or IR sensor. The camera of a robot might be broken at the beginning or it might break later. The battery of the robot depletes as time passes. The battery depletes at the highest rate when the robot is camera following another robot and is at the lowest rate when it is not moving. When the robot is leading the convoy or performing the IR following the battery depletion is at a medium rate. Note the robot functions become unavailable when the battery level is at 0 percent. On the other hand, the Environment class contains the Robot and associated classes and shows the graphical interface. When a robot’s battery is dead it will be deleted from the environment. Figure 2 shows a snap shot of the graphical interface of the Environment class. The boxes on the top row show the robots which have some battery left. The Bottom row shows the current convoy of the robots. This picture shows the condition in which the red robot is the leader, the blue robot is color following the red robot and the orange robot is IR following the blue robot, and two of the robots are already dead.
Background image of page 2
Show entire document

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.


Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question