Skip to content

Commit

Permalink
Trim trailing spaces
Browse files Browse the repository at this point in the history
  • Loading branch information
Kari Hautio committed Jan 12, 2012
1 parent 2a1ac56 commit cddcd22
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 10 deletions.
2 changes: 1 addition & 1 deletion Libraries/AQ_OSD/MAX7456.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
The user must connect a MAX7456 OSD chip to the appropriate header pins on
the Arduino. These pins are marked 'OSD' on the AeroQuad Shield v2.
If the chip is not connected properly, this code should not hang (according
If the chip is not connected properly, this code should not hang (according
to my best knowledge).
If using the SparkFun MAX7456 breakout board, the reset pin should be wired
Expand Down
2 changes: 1 addition & 1 deletion Libraries/AQ_OSD/MAX7456_AI.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
The user must connect a MAX7456 OSD chip to the appropriate header pins on
the Arduino. These pins are marked 'OSD' on the AeroQuad Shield v2.
If the chip is not connected properly, this code should not hang (according
If the chip is not connected properly, this code should not hang (according
to my best knowledge).
If using the SparkFun MAX7456 breakout board, the reset pin should be wired
Expand Down
8 changes: 4 additions & 4 deletions Libraries/AQ_OSD/MAX7456_BattMonitor.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,22 +63,22 @@ void displayVoltage(byte areMotorsArmed) {
else {
currentValue = batteryData[osdBatNo].current*10.0;
}

if (abs(currentValue)>=100) { // > 10A only display whole amps
snprintf(buf,12,"%4dA%5d\24 ", currentValue/10, (int)batteryData[osdBatNo].usedCapacity);
}
else {
snprintf(buf,12,"%c%1d.%1dA%5d\24 ", currentValue<0?'-':' ',abs(currentValue/10),abs(currentValue%10),(int)batteryData[osdBatNo].usedCapacity);
}
}

writeChars( buf, 11, 0, VOLTAGE_ROW+osdBatNo, VOLTAGE_COL+6 );
}

osdBatCounter++;
if (osdBatCounter >= numberOfBatteries * 8) {
osdBatCounter = 0;
}

#if defined (BattMonitorAutoDescent)
if (batteryAlarm && areMotorsArmed) {
if (!descentWarningShown) {
Expand Down
2 changes: 1 addition & 1 deletion Libraries/AQ_OSD/MAX7456_Heading.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
int lastHeading = 361; // bogus to force update

void displayHeading(int currentHeading) {

if (currentHeading != lastHeading) {
char buf[6];
snprintf(buf,6,"\6%3d\7",currentHeading); // \6 is compass \7 is degree symbol
Expand Down
4 changes: 1 addition & 3 deletions Libraries/AQ_OSD/MAX7456_RSSI.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,4 @@ void displayRSSI() {
}
}

#endif // #define _AQ_OSD_MAX7456_H_


#endif // #define _AQ_OSD_MAX7456_RSSI_H_

0 comments on commit cddcd22

Please sign in to comment.