Optimaze with new mbed os for study

Dependencies:   TS_DISCO_F746NG BSP_DISCO_F746NG Graphics

Revision:
1:5e49b46de1b0
Parent:
0:d8b9955d2b36
Child:
2:8db224cc1fcb
diff -r d8b9955d2b36 -r 5e49b46de1b0 RadarDemo/Radar.h
--- a/RadarDemo/Radar.h	Fri Nov 04 01:02:37 2016 +0000
+++ b/RadarDemo/Radar.h	Fri Nov 04 17:10:50 2016 +0000
@@ -1,6 +1,19 @@
-//
-// Radar.h - example of graphic commands usage to create 2D graphics.
-//
+/*
+    Radar.h - Simple radar simulator, example of graphic commands usage to create 2D graphics.
+
+    Copyright(c) 2016 karpent at gmail.com, MIT License
+
+    Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files(the "Software"),
+    to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
+    and / or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions :
+
+    The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
+    OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
+    THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+*/
 
 #pragma once
 
@@ -24,7 +37,6 @@
 public:
 
     Radar(Display* display);
-    //Radar();
     ~Radar();
 
     /// <summary>
@@ -34,12 +46,13 @@
 
 
     /// <summary>
-    /// Demo: Updates the targets in sector.
+    /// Updates the targets in sector for the current time. 
+    /// Returns true if targets found.
     /// </summary>
     /// <param name="startAngle">The start angle.</param>
     /// <param name="endAngle">The end angle.</param>
     /// <param name="currentTime">Current Time in miliseconds.</param>
-    void UpdateTargetsLocation(float startAngle, float endAngle, uint32_t currentTime);
+    bool UpdateTargetsLocation(float startAngle, float endAngle, uint32_t currentTime);
 
 
     /// <summary>
@@ -104,9 +117,8 @@
 
 private:
 
-
     /// <summary>
-    /// Display window in local coordinate system
+    /// Display window in local coordinates system
     /// </summary>
     Window window;