123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186 |
- <?xml version="1.0" encoding="utf-8"?>
- <fragment xmlns="http://www.holeschak.de/BmwDeepObd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.holeschak.de/BmwDeepObd BmwDeepObd.xsd">
- <page name="PDC" fontsize="small" display-mode="grid" gauges-portrait="2" gauges-landscape="4" logfile="PDCACT.log">
- <strings>
- <string name="PDC">PDC</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HL_WERT"> back left [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HML_WERT"> back left middle [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HMR_WERT"> back right middle [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HR_WERT"> back right [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VL_WERT"> front left [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VML_WERT"> front left middle [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VMR_WERT"> front right middle [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VR_WERT"> front right [cm]</string>
- </strings>
- <strings lang="de">
- <string name="PDC">PDC</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HL_WERT"> Hinten Links [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HML_WERT"> Hinten Links Mitte [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HMR_WERT"> Hinten Rechts Mitte [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HR_WERT"> Hinten Rechts [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VL_WERT"> Vorn Links [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VML_WERT"> Vorn Links Mitte [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VMR_WERT"> Vorn Rechts Mitte [cm]</string>
- <string name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VR_WERT"> Vorn Rechts [cm]</string>
- </strings>
- <jobs sgbd="pdcact">
- <job name="STATUS_MESSWERTE_LESEN">
- <display name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VL_WERT" result="STAT_WEG_VL_WERT" grid-type="simple-gauge-round" min-value="0" max-value="255" log_tag="STAT_WEG_VL_WERT" />
- <display name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VML_WERT" result="STAT_WEG_VML_WERT" grid-type="simple-gauge-round" min-value="0" max-value="255" log_tag="STAT_WEG_VML_WERT" />
- <display name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VMR_WERT" result="STAT_WEG_VMR_WERT" grid-type="simple-gauge-round" min-value="0" max-value="255" log_tag="STAT_WEG_VMR_WERT" />
- <display name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_VR_WERT" result="STAT_WEG_VR_WERT" grid-type="simple-gauge-round" min-value="0" max-value="255" log_tag="STAT_WEG_VR_WERT" />
- <display name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HL_WERT" result="STAT_WEG_HL_WERT" grid-type="simple-gauge-round" min-value="0" max-value="255" log_tag="STAT_WEG_HL_WERT" />
- <display name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HML_WERT" result="STAT_WEG_HML_WERT" grid-type="simple-gauge-round" min-value="0" max-value="255" log_tag="STAT_WEG_HML_WERT" />
- <display name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HMR_WERT" result="STAT_WEG_HMR_WERT" grid-type="simple-gauge-round" min-value="0" max-value="255" log_tag="STAT_WEG_HMR_WERT" />
- <display name="!JOB#STATUS_MESSWERTE_LESEN#STAT_WEG_HR_WERT" result="STAT_WEG_HR_WERT" grid-type="simple-gauge-round" min-value="0" max-value="255" log_tag="STAT_WEG_HR_WERT" />
- </job>
- </jobs>
- <code show_warnings="true">
- <![CDATA[
- class PageClass
- {
- public string FormatResult(JobReader.PageInfo pageInfo, MultiMap<string, EdiabasNet.ResultData> resultDict, string resultName, ref Android.Graphics.Color? textColor)
- {
- string result = string.Empty;
- Int64 value;
- bool found;
- switch (resultName)
- {
- case "STATUS_MESSWERTE_LESEN#STAT_WEG_VL_WERT":
- value = ActivityMain.GetResultInt64(resultDict, resultName, 0, out found);
-
- // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]}
- result = string.Format(ActivityMain.Culture, "{0,3:0}", value);
-
- // Liste der möglichen Farbnamen: https://docs.microsoft.com/en-us/dotnet/api/android.graphics.color?view=xamarin-android-sdk-9
- if (found && value <= 20) textColor = Android.Graphics.Color.Red;
- else if (found && value <= 40) textColor = Android.Graphics.Color.Orange;
- else if (found && value <= 80) textColor = Android.Graphics.Color.Yellow;
- else if (found && value <= 100) textColor = Android.Graphics.Color.Green;
- else if (found && value > 200) textColor = Android.Graphics.Color.White;
- else textColor = Android.Graphics.Color.Gray;
-
- break;
-
- case "STATUS_MESSWERTE_LESEN#STAT_WEG_VML_WERT":
- value = ActivityMain.GetResultInt64(resultDict, resultName, 0, out found);
-
- // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]}
- result = string.Format(ActivityMain.Culture, "{0,3:0}", value);
-
- // Liste der möglichen Farbnamen: https://docs.microsoft.com/en-us/dotnet/api/android.graphics.color?view=xamarin-android-sdk-9
- if (found && value <= 20) textColor = Android.Graphics.Color.Red;
- else if (found && value <= 40) textColor = Android.Graphics.Color.Orange;
- else if (found && value <= 80) textColor = Android.Graphics.Color.Yellow;
- else if (found && value <= 100) textColor = Android.Graphics.Color.Green;
- else if (found && value > 200) textColor = Android.Graphics.Color.White;
- else textColor = Android.Graphics.Color.Gray;
-
- break;
-
- case "STATUS_MESSWERTE_LESEN#STAT_WEG_VMR_WERT":
- value = ActivityMain.GetResultInt64(resultDict, resultName, 0, out found);
-
- // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]}
- result = string.Format(ActivityMain.Culture, "{0,3:0}", value);
-
- // Liste der möglichen Farbnamen: https://docs.microsoft.com/en-us/dotnet/api/android.graphics.color?view=xamarin-android-sdk-9
- if (found && value <= 20) textColor = Android.Graphics.Color.Red;
- else if (found && value <= 40) textColor = Android.Graphics.Color.Orange;
- else if (found && value <= 80) textColor = Android.Graphics.Color.Yellow;
- else if (found && value <= 100) textColor = Android.Graphics.Color.Green;
- else if (found && value > 200) textColor = Android.Graphics.Color.White;
- else textColor = Android.Graphics.Color.Gray;
-
- break;
-
- case "STATUS_MESSWERTE_LESEN#STAT_WEG_VR_WERT":
- value = ActivityMain.GetResultInt64(resultDict, resultName, 0, out found);
-
- // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]}
- result = string.Format(ActivityMain.Culture, "{0,3:0}", value);
-
- // Liste der möglichen Farbnamen: https://docs.microsoft.com/en-us/dotnet/api/android.graphics.color?view=xamarin-android-sdk-9
- if (found && value <= 20) textColor = Android.Graphics.Color.Red;
- else if (found && value <= 40) textColor = Android.Graphics.Color.Orange;
- else if (found && value <= 80) textColor = Android.Graphics.Color.Yellow;
- else if (found && value <= 100) textColor = Android.Graphics.Color.Green;
- else if (found && value > 200) textColor = Android.Graphics.Color.White;
- else textColor = Android.Graphics.Color.Gray;
-
- break;
-
- case "STATUS_MESSWERTE_LESEN#STAT_WEG_HL_WERT":
- value = ActivityMain.GetResultInt64(resultDict, resultName, 0, out found);
-
- // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]}
- result = string.Format(ActivityMain.Culture, "{0,3:0}", value);
-
- // Liste der möglichen Farbnamen: https://docs.microsoft.com/en-us/dotnet/api/android.graphics.color?view=xamarin-android-sdk-9
- if (found && value <= 20) textColor = Android.Graphics.Color.Red;
- else if (found && value <= 40) textColor = Android.Graphics.Color.Orange;
- else if (found && value <= 80) textColor = Android.Graphics.Color.Yellow;
- else if (found && value <= 100) textColor = Android.Graphics.Color.Green;
- else if (found && value > 200) textColor = Android.Graphics.Color.White;
- else textColor = Android.Graphics.Color.Gray;
-
- break;
-
- case "STATUS_MESSWERTE_LESEN#STAT_WEG_HML_WERT":
- value = ActivityMain.GetResultInt64(resultDict, resultName, 0, out found);
-
- // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]}
- result = string.Format(ActivityMain.Culture, "{0,3:0}", value);
-
- // Liste der möglichen Farbnamen: https://docs.microsoft.com/en-us/dotnet/api/android.graphics.color?view=xamarin-android-sdk-9
- if (found && value <= 20) textColor = Android.Graphics.Color.Red;
- else if (found && value <= 40) textColor = Android.Graphics.Color.Orange;
- else if (found && value <= 80) textColor = Android.Graphics.Color.Yellow;
- else if (found && value <= 100) textColor = Android.Graphics.Color.Green;
- else if (found && value > 200) textColor = Android.Graphics.Color.White;
- else textColor = Android.Graphics.Color.Gray;
-
- break;
-
- case "STATUS_MESSWERTE_LESEN#STAT_WEG_HMR_WERT":
- value = ActivityMain.GetResultInt64(resultDict, resultName, 0, out found);
-
- // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]}
- result = string.Format(ActivityMain.Culture, "{0,3:0}", value);
-
- // Liste der möglichen Farbnamen: https://docs.microsoft.com/en-us/dotnet/api/android.graphics.color?view=xamarin-android-sdk-9
- if (found && value <= 20) textColor = Android.Graphics.Color.Red;
- else if (found && value <= 40) textColor = Android.Graphics.Color.Orange;
- else if (found && value <= 80) textColor = Android.Graphics.Color.Yellow;
- else if (found && value <= 100) textColor = Android.Graphics.Color.Green;
- else if (found && value > 200) textColor = Android.Graphics.Color.White;
- else textColor = Android.Graphics.Color.Gray;
-
- break;
-
- case "STATUS_MESSWERTE_LESEN#STAT_WEG_HR_WERT":
- value = ActivityMain.GetResultInt64(resultDict, resultName, 0, out found);
-
- // result format: {0,[DIGITS TOTAL INCL COMMA],[0|0.0|0.00|0.000...]}
- result = string.Format(ActivityMain.Culture, "{0,3:0}", value);
-
- // Liste der möglichen Farbnamen: https://docs.microsoft.com/en-us/dotnet/api/android.graphics.color?view=xamarin-android-sdk-9
- if (found && value <= 20) textColor = Android.Graphics.Color.Red;
- else if (found && value <= 40) textColor = Android.Graphics.Color.Orange;
- else if (found && value <= 80) textColor = Android.Graphics.Color.Yellow;
- else if (found && value <= 100) textColor = Android.Graphics.Color.Green;
- else if (found && value > 200) textColor = Android.Graphics.Color.White;
- else textColor = Android.Graphics.Color.Gray;
-
- break;
-
- }
- return result;
- }
- }
- ]]>
- </code>
- </page>
- </fragment>
|