Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: SPI_TFTx2 SPI_TFTx2_ILI9341 TFT_fonts TOUCH_TFTx2 mbed
Fork of CANary_9341 by
Diff: displayModes.cpp
- Branch:
- Metric
- Revision:
- 111:d1559bb25c43
- Parent:
- 108:29b5a760adc2
- Child:
- 113:f388b4505463
--- a/displayModes.cpp Sun Jun 30 19:52:38 2013 +0000
+++ b/displayModes.cpp Sun Jun 30 23:04:56 2013 +0000
@@ -77,14 +77,14 @@
if(force){
tt.cls();
}
- if(force||lmiles!=miles_trip[0]){ //only update if changed
+ if(force||(int)lmiles!=(int)miles_trip[0]){ //only update if changed
tt.foreground(Navy);
tt.set_font((unsigned char*) Arial28x28);
tt.locate(6,210);
- printf("kWh : %s : Eff\n",distanceUnit());
+ printf("kWh : %s : Eff\n",distanceUnit());
for(int i=0; i<3; i++){
tt.locate(6,20+i*60);
- printf("%3.2f : %3.1f : %2.1f \n",kWh_trip[i],convertDistance(miles_trip[i]),convertDistance(miles_trip[i])/kWh_trip[i]);
+ printf("%3.2f : %3.1f : %2.1f\n",kWh_trip[i],convertDistance(miles_trip[i]),convertDistance(miles_trip[i])/kWh_trip[i]);
}
tt.set_font((unsigned char*) Arial12x12);
tt.background(DarkCyan);
