diff options
author | Cristian Maglie <c.maglie@bug.st> | 2013-08-23 15:59:24 +0200 |
---|---|---|
committer | Cristian Maglie <c.maglie@bug.st> | 2013-08-23 15:59:24 +0200 |
commit | 540743129b2badb813b703208d121ff14553c147 (patch) | |
tree | 6fadb4ebce68e1f0cb298a282be135c23fd156ed /libraries/Robot_Control/helper.cpp | |
parent | 073b3ac9d4ae93ac0bb3a91afc65ae9d8f1d5d59 (diff) | |
parent | 67c84855c2f3ce99b091a756bb2ca1a016260659 (diff) |
Merge branch 'ide-1.5.x' into dev-ide-1.5.x-discovery
Conflicts:
app/src/processing/app/Preferences.java
app/src/processing/app/debug/Uploader.java
Diffstat (limited to 'libraries/Robot_Control/helper.cpp')
-rw-r--r-- | libraries/Robot_Control/helper.cpp | 45 |
1 files changed, 0 insertions, 45 deletions
diff --git a/libraries/Robot_Control/helper.cpp b/libraries/Robot_Control/helper.cpp deleted file mode 100644 index a7a956a..0000000 --- a/libraries/Robot_Control/helper.cpp +++ /dev/null @@ -1,45 +0,0 @@ -#include "ArduinoRobot.h" - -void RobotControl::drawBase(){ - Arduino_LCD::drawCircle(64,80,50,foreGround); - Arduino_LCD::drawLine(64,30,64,20,foreGround); -} -void RobotControl::drawDire(int16_t dire){ - static uint8_t x_old; - static uint8_t y_old; - static uint8_t x_t_old; - static uint8_t y_t_old; - - uint8_t x=60*sin(dire/360.0*6.28)+64; - uint8_t x_t=40*sin(dire/360.0*6.28)+64; - uint8_t y=60*cos(dire/360.0*6.28)+80; - uint8_t y_t=40*cos(dire/360.0*6.28)+80; - - Arduino_LCD::drawLine(x_t_old,y_t_old,x_old,y_old,backGround); - Arduino_LCD::drawLine(x_t,y_t,x,y,RED); - - x_old=x; - y_old=y; - x_t_old=x_t; - y_t_old=y_t; -} - -void RobotControl::drawCompass(uint16_t value){ - drawBase(); - drawDire(value); - debugPrint(value,57,76); -} - -//display logos -void RobotControl::displayLogos(){ - _drawBMP("lg0.bmp",0,0); - delay(2000); - _drawBMP("lg1.bmp",0,0); - delay(2000); - clearScreen(); -} - -//wait for a button to be pressed -void RobotControl::waitContinue(uint8_t key){ - while(!(Robot.keyboardRead()==key)); -} |