dhiltonp

inlined functions

Dec 31st, 2012
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Diff 1.58 KB | None | 0 0
  1. From 5150cb558181170d97e5d118ea0ee6d9b2282996 Mon Sep 17 00:00:00 2001
  2. From: David P Hilton <[email protected]>
  3. Date: Mon, 31 Dec 2012 11:01:50 -0700
  4. Subject: [PATCH] inlined some functions
  5.  
  6. ---
  7. programs/hexbright_jrt/hexbright_jrt.ino |   16 ++++++++--------
  8.  1 files changed, 8 insertions(+), 8 deletions(-)
  9.  mode change 100644 => 100755 programs/hexbright_jrt/hexbright_jrt.ino
  10.  
  11. diff --git a/programs/hexbright_jrt/hexbright_jrt.ino b/programs/hexbright_jrt/hexbright_jrt.ino
  12. old mode 100644
  13. new mode 100755
  14. index c830f47..bcd7304
  15. --- a/programs/hexbright_jrt/hexbright_jrt.ino
  16. +++ b/programs/hexbright_jrt/hexbright_jrt.ino
  17. @@ -218,7 +218,7 @@ void loop()
  18.      }
  19.  }
  20.  
  21. -void oneSecondLoop()
  22. +inline void oneSecondLoop()
  23.  {
  24.      const unsigned long time = millis();
  25.  
  26. @@ -249,7 +249,7 @@ void checkAccel()
  27.      resetAccelTimeout();
  28.  }
  29.  
  30. -void powerOff()
  31. +inline void powerOff()
  32.  {
  33.      // Don't unnecessarily update the EEPROM
  34.      byte eepromLastOnMode = EEPROM.read(EEPROM_LAST_ON_MODE);
  35. @@ -261,27 +261,27 @@ void powerOff()
  36.      hb.shutdown();
  37.  }
  38.  
  39. -void setLightOff()
  40. +inline void setLightOff()
  41.  {
  42.      setLight(MODE_OFF);
  43.  }
  44.  
  45. -void setLightLow()
  46. +inline void setLightLow()
  47.  {
  48.      setLight(MODE_LOW);
  49.  }
  50.  
  51. -void setLightMed()
  52. +inline void setLightMed()
  53.  {
  54.      setLight(MODE_MED);
  55.  }
  56.  
  57. -void setLightHigh()
  58. +inline void setLightHigh()
  59.  {
  60.      setLight(MODE_HIGH);
  61.  }
  62.  
  63. -void setLightBlinking()
  64. +inline void setLightBlinking()
  65.  {
  66.      setLight(MODE_BLINKING);
  67.  }
  68. @@ -337,4 +337,4 @@ void resetAccelTimeout()
  69.  }
  70.  
  71.  
  72. -
  73. +
  74. --
  75. 1.7.9
Advertisement
Add Comment
Please, Sign In to add comment