Mercurial > public > ostc4
annotate Discovery/Src/tMenuEditCustom.c @ 951:e9c37071933b Evo_2_23
Added vibration warning:
The internal buzzer of the GPIO_V2 may now be used as additional warning notificator. It can be activated using the check button in the customer view menu. The vibration will be active while the warning message is displayed in the dive window. In case the diver is in the menu then the warning will be active for a shorter duration.
author | Ideenmodellierer |
---|---|
date | Sun, 29 Dec 2024 18:29:56 +0100 |
parents | 2225c467f1e9 |
children |
rev | line source |
---|---|
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1 /////////////////////////////////////////////////////////////////////////////// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
2 /// -*- coding: UTF-8 -*- |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
3 /// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
4 /// \file Discovery/Src/tMenuEditXtra.c |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
5 /// \brief Menu Edit Xtra - Specials in Divemode like Reset Stopwatch |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
6 /// \author heinrichs weikamp gmbh |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
7 /// \date 02-Mar-2015 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
8 /// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
9 /// \details |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
10 /// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
11 /// $Id$ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
12 /////////////////////////////////////////////////////////////////////////////// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
13 /// \par Copyright (c) 2014-2018 Heinrichs Weikamp gmbh |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
14 /// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
15 /// This program is free software: you can redistribute it and/or modify |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
16 /// it under the terms of the GNU General Public License as published by |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
17 /// the Free Software Foundation, either version 3 of the License, or |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
18 /// (at your option) any later version. |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
19 /// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
20 /// This program is distributed in the hope that it will be useful, |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
21 /// but WITHOUT ANY WARRANTY; without even the implied warranty of |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
22 /// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
23 /// GNU General Public License for more details. |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
24 /// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
25 /// You should have received a copy of the GNU General Public License |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
26 /// along with this program. If not, see <http://www.gnu.org/licenses/>. |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
27 ////////////////////////////////////////////////////////////////////////////// |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
28 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
29 /* Includes ------------------------------------------------------------------*/ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
30 #include "tMenuEditCustom.h" |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
31 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
32 #include "gfx_fonts.h" |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
33 #include "simulation.h" |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
34 #include "timer.h" |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
35 #include "tMenuEdit.h" |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
36 #include "tHome.h" // for enum CUSTOMVIEWS and init_t7_compass() |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
37 #include "t3.h" |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
38 #include "t7.h" |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
39 #include "data_exchange_main.h" |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
40 #include "motion.h" |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
41 #include "tMenu.h" |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
42 #include "tMenuSystem.h" |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
43 #include <math.h> |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
44 |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
45 |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
46 #define CV_PER_PAGE (5u) /* number of cv selections shown at one page */ |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
47 #define MAX_BACKLIGHT_BOOST (2u) /* max number of backlight levels which may be increased during focus state */ |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
48 |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
49 #define MAX_FOCUS_LIMITER (2u) /* max number for reducing the spot used for focus detection */ |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
50 |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
51 static uint8_t customviewsSubpage = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
52 static uint8_t customviewsSubpageMax = 0; /* number of pages needed to display all selectable views */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
53 static const uint8_t* pcv_curchangelist; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
54 /* Private function prototypes -----------------------------------------------*/ |
520 | 55 void openEdit_Customview(void); |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
56 void openEdit_BigScreen(void); |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
57 void openEdit_MotionCtrl(void); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
58 void openEdit_ViewPort(void); |
951 | 59 void openEdit_WarningBuz(void); |
520 | 60 void refresh_Customviews(void); |
852 | 61 void setMenuContentStructure(); |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
62 char customview_TXT2BYTE_helper(uint8_t customViewId); |
820 | 63 char customviewBF_TXT2BYTE_helper(uint8_t customViewId); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
64 /* Announced function prototypes -----------------------------------------------*/ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
65 uint8_t OnAction_CViewTimeout (uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
66 uint8_t OnAction_CViewStandard (uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
67 uint8_t OnAction_CViewStandardBF(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
834
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
68 uint8_t OnAction_CViewAutofocusBF(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
69 uint8_t OnAction_CornerTimeout (uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
70 uint8_t OnAction_CornerStandard(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
71 uint8_t OnAction_CViewPortCalib(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
72 uint8_t OnAction_CViewPortLayout(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
73 uint8_t OnAction_CViewPortAmbient(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
74 uint8_t OnAction_CViewPortControl(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
75 uint8_t OnAction_CViewPortSpot(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
76 /* Exported functions --------------------------------------------------------*/ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
77 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
78 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
79 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
80 |
520 | 81 void refresh_Customviews(void) |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
82 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
83 char text[32]; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
84 uint8_t textpointer = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
85 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
86 // header |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
87 text[0] = '\001'; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
88 text[1] = TXT_2BYTE; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
89 text[2] = TXT2BYTE_Customviews; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
90 text[3] = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
91 write_topline(text); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
92 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
93 // custom view center return |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
94 textpointer = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
95 text[textpointer++] = TXT_2BYTE; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
96 text[textpointer++] = TXT2BYTE_CViewTimeout; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
97 textpointer += snprintf(&text[textpointer],11," %02u\016\016 %c\017",settingsGetPointer()->tX_customViewTimeout,TXT_Seconds); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
98 write_label_var( 30, 700, ME_Y_LINE1, &FontT48, text); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
99 |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
100 // custom view center primary |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
101 text[0] = TXT_2BYTE; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
102 text[1] = TXT2BYTE_CViewStandard; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
103 text[2] = ' '; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
104 text[3] = ' '; |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
105 |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
106 text[4] = TXT_2BYTE; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
107 text[5] = customview_TXT2BYTE_helper(settingsGetPointer()->tX_customViewPrimary); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
108 text[6] = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
109 write_label_var( 30, 700, ME_Y_LINE2, &FontT48, text); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
110 |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
111 // custom view big font |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
112 text[0] = TXT_2BYTE; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
113 text[1] = TXT2BYTE_ExtraDisplay; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
114 text[2] = ' '; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
115 text[3] = ' '; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
116 text[4] = TXT_2BYTE; |
820 | 117 text[5] = customviewBF_TXT2BYTE_helper(settingsGetPointer()->tX_customViewPrimaryBF); |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
118 text[6] = 0; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
119 write_label_var( 30, 700, ME_Y_LINE3, &FontT48, text); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
120 |
834
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
121 /* Bigfont autofocus selector */ |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
122 textpointer = 0; |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
123 text[textpointer++] = TXT_2BYTE; |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
124 text[textpointer++] = TXT2BYTE_ExtraDisplay; |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
125 textpointer += snprintf(&text[textpointer],20," %c%c",TXT_2BYTE, TXT2BYTE_Autofocus); |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
126 write_label_var( 30, 700, ME_Y_LINE4, &FontT48, text); |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
127 |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
128 tMenuEdit_refresh_field(StMCustom1_CViewAutoFocusBF); |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
129 |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
130 // field corner return |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
131 textpointer = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
132 text[textpointer++] = TXT_2BYTE; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
133 text[textpointer++] = TXT2BYTE_CornerTimeout; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
134 textpointer += snprintf(&text[textpointer],11," %02u\016\016 %c\017",settingsGetPointer()->tX_userselectedLeftLowerCornerTimeout,TXT_Seconds); |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
135 write_label_var( 30, 700, ME_Y_LINE5, &FontT48, text); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
136 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
137 // field corner primary |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
138 text[0] = TXT_2BYTE; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
139 text[1] = TXT2BYTE_CornerStandard; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
140 text[2] = ' '; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
141 text[3] = ' '; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
142 switch(settingsGetPointer()->tX_userselectedLeftLowerCornerPrimary) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
143 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
144 /* Temperature */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
145 case LLC_Temperature: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
146 text[4] = TXT_Temperature; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
147 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
148 /* Average Depth */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
149 case LLC_AverageDepth: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
150 text[4] = TXT_AvgDepth; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
151 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
152 /* ppO2 */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
153 case LLC_ppO2: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
154 text[4] = TXT_ppO2; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
155 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
156 /* Stop Uhr */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
157 case LLC_Stopwatch: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
158 text[4] = TXT_Stopwatch; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
159 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
160 /* Ceiling */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
161 case LLC_Ceiling: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
162 text[4] = TXT_Ceiling; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
163 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
164 /* Future TTS */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
165 case LLC_FutureTTS: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
166 text[4] = TXT_FutureTTS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
167 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
168 /* CNS */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
169 case LLC_CNS: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
170 text[4] = TXT_CNS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
171 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
172 case LLC_GF: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
173 text[4] = TXT_ActualGradient; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
174 break; |
656 | 175 case LLC_ScrubberTime: |
176 text[4] = TXT_ScrubTime; | |
177 break; | |
178 | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
179 #ifdef ENABLE_BOTTLE_SENSOR |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
180 case LCC_BottleBar: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
181 text[4] = TXT_AtemGasVorrat; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
182 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
183 #endif |
662 | 184 |
185 #ifdef ENABLE_PSCR_MODE | |
186 case LCC_SimPpo2: | |
187 text[4] = TXT_SimPpo2; | |
188 break; | |
189 #endif | |
751 | 190 #ifdef ENABLE_CO2_SUPPORT |
191 case LCC_CO2: | |
192 text[4] = TXT_CO2Sensor; | |
193 break; | |
194 #endif | |
737
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
195 case LLC_Compass: |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
196 text[4] = TXT_2BYTE; |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
197 text[5] = TXT2BYTE_Compass; |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
198 |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
199 break; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
200 /* none */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
201 case LLC_Empty: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
202 text[4] = '-'; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
203 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
204 default: |
630 | 205 text[4] = 'X'; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
206 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
207 } |
737
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
208 if (text[4] != TXT_2BYTE) { |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
209 text[5] = 0; |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
210 } else { |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
211 text[6] = 0; |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
212 } |
5071d554aaa5
NEW: Add mini compass with marker declination indication
heinrichsweikamp
parents:
706
diff
changeset
|
213 |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
214 write_label_var( 30, 700, ME_Y_LINE6, &FontT48, text); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
215 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
216 write_buttonTextline(TXT2BYTE_ButtonBack,TXT2BYTE_ButtonEnter,TXT2BYTE_ButtonNext); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
217 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
218 |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
219 void refresh_ViewPort(void) |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
220 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
221 char text[32]; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
222 uint8_t textIndex = 0; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
223 float distance = 0.0; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
224 SSettings* pSettings = settingsGetPointer(); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
225 GFX_DrawCfgScreen* pdrawScreen; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
226 point_t lowerleft = {0,0}; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
227 point_t upperright = {799,479}; |
575
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
228 float localLimit = 0.1; |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
229 uint8_t spotSize = (pSettings->viewPortMode >> 5) & 0x03; |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
230 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
231 text[0] = '\001'; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
232 text[1] = TXT_2BYTE; |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
233 text[2] = TXT2BYTE_MotionCtrl; |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
234 text[3] = 0; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
235 write_topline(text); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
236 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
237 text[0] = TXT_2BYTE; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
238 text[1] = TXT2BYTE_CalibView; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
239 text[2] = 0; |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
240 write_label_var( 30, 700, ME_Y_LINE2, &FontT48, text); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
241 |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
242 |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
243 textIndex = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
244 text[textIndex++] = TXT_2BYTE; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
245 text[textIndex++] = TXT2BYTE_FocusSpotSize; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
246 text[textIndex++] = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
247 write_label_var( 30, 340, ME_Y_LINE3, &FontT48, text); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
248 |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
249 textIndex = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
250 text[textIndex++] = TXT_2BYTE; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
251 switch(spotSize) |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
252 { |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
253 case 2: text[textIndex++] = TXT2BYTE_Minimum; break; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
254 case 1: text[textIndex++] = TXT2BYTE_Normal; break; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
255 default: |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
256 case 0: text[textIndex++] = TXT2BYTE_Maximum; break; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
257 } |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
258 text[textIndex++] = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
259 write_label_var( 500, 800, ME_Y_LINE3, &FontT48, text); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
260 |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
261 textIndex = 0; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
262 text[textIndex++] = TXT_2BYTE; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
263 text[textIndex++] = TXT2BYTE_IndicateFrame; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
264 text[textIndex++] = 0; |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
265 write_label_var( 30, 340, ME_Y_LINE4, &FontT48, text); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
266 textIndex = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
267 text[textIndex++] = '\006' - ((settingsGetPointer()->viewPortMode >> 4) & 1); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
268 text[textIndex++] = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
269 write_label_var( 500, 800, ME_Y_LINE4, &FontT48, text); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
270 textIndex = 0; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
271 text[textIndex++] = TXT_2BYTE; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
272 text[textIndex++] = TXT2BYTE_BoostBacklight; |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
273 text[textIndex++] = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
274 write_label_var( 30, 340, ME_Y_LINE5, &FontT48, text); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
275 textIndex = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
276 snprintf(&text[textIndex],32,"%d",(settingsGetPointer()->viewPortMode & 0x3)); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
277 write_label_var( 500, 800, ME_Y_LINE5, &FontT48, text); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
278 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
279 write_buttonTextline(TXT2BYTE_ButtonBack,TXT2BYTE_ButtonEnter,TXT2BYTE_ButtonNext); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
280 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
281 /* test if we are in focus */ |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
282 if((pSettings->viewPitch != 0.0) || (pSettings->viewRoll != 0.0) || (pSettings->viewYaw != 0.0)) |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
283 { |
625
028d8f3a9410
Switch Sector / Scroll detection to vector implementation:
Ideenmodellierer
parents:
604
diff
changeset
|
284 distance = checkViewport(stateUsed->lifeData.compass_roll, stateUsed->lifeData.compass_pitch, stateUsed->lifeData.compass_heading, MOTION_ENABLE_ALL); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
285 |
575
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
286 /* show "bar graph" indicating the distance to the center point */ |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
287 textIndex = 0; |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
288 text[textIndex++] = '\001'; |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
289 |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
290 if(fabs(distance) < localLimit) |
575
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
291 { |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
292 text[textIndex++] = '+'; |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
293 } |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
294 else |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
295 { |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
296 while (localLimit < 0.6) |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
297 { |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
298 localLimit += 0.1; |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
299 text[textIndex++] = '-'; |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
300 text[textIndex++] = '-'; |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
301 if(fabs(distance) < localLimit) |
575
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
302 { |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
303 break; |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
304 } |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
305 } |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
306 } |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
307 text[textIndex] = 0; |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
308 write_label_var( 30, 700, ME_Y_LINE1, &FontT48, text); |
86c4baa6ba29
Change style of viewport calibration menu:
Ideenmodellierer
parents:
572
diff
changeset
|
309 |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
310 /* MotionCtrl */ |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
311 textIndex = 0; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
312 |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
313 text[textIndex++] = TXT_2BYTE; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
314 text[textIndex++] = TXT2BYTE_MotionCtrl; |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
315 text[textIndex++] = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
316 write_label_var( 30, 340, ME_Y_LINE6, &FontT48, text); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
317 textIndex = 0; |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
318 text[textIndex++] = TXT_2BYTE; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
319 switch(settingsGetPointer()->MotionDetection) |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
320 { |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
321 case MOTION_DETECT_OFF: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
322 text[textIndex++] = TXT2BYTE_MoCtrlNone; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
323 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
324 case MOTION_DETECT_MOVE: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
325 text[textIndex++] = TXT2BYTE_MoCtrlPitch; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
326 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
327 case MOTION_DETECT_SECTOR: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
328 text[textIndex++] = TXT2BYTE_MoCtrlSector; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
329 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
330 case MOTION_DETECT_SCROLL: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
331 text[textIndex++] = TXT2BYTE_MoCtrlScroll; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
332 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
333 default: |
630 | 334 textIndex += snprintf(&text[4],4,"%u",settingsGetPointer()->MotionDetection); |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
335 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
336 } |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
337 text[textIndex] = 0; |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
338 write_label_var(500, 800, ME_Y_LINE6, &FontT48, text); |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
339 |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
340 |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
341 if(viewInFocus()) |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
342 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
343 set_Backlight_Boost(settingsGetPointer()->viewPortMode & 0x03); |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
344 if((pSettings->viewPortMode >> 4) & 0x01) |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
345 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
346 pdrawScreen = getMenuEditScreen(); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
347 GFX_draw_box(pdrawScreen,lowerleft,upperright,0,CLUT_NiceGreen); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
348 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
349 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
350 else |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
351 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
352 set_Backlight_Boost(0); |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
353 if((pSettings->viewPortMode >> 4) & 0x01) |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
354 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
355 pdrawScreen = getMenuEditScreen(); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
356 GFX_draw_box(pdrawScreen,lowerleft,upperright,0,CLUT_MenuTopBackground); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
357 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
358 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
359 resetFocusState(); /* no other instance shall be impacted by the local detection */ |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
360 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
361 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
362 |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
363 void openEdit_Custom(uint8_t line) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
364 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
365 set_globalState_Menu_Line(line); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
366 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
367 switch(line) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
368 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
369 case 1: |
706
10b7d271b9c4
Bugfix: only reset menu if a new sub menu is created:
Ideenmodellierer
parents:
700
diff
changeset
|
370 default: openEdit_Customview(); |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
371 break; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
372 case 2: openEdit_BigScreen(); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
373 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
374 case 3: openEdit_CustomviewDivemode(cv_changelist); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
375 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
376 case 4: openEdit_CustomviewDivemode(cv_changelist_BS); |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
377 break; |
951 | 378 #ifdef ENABLE_MOTION_CONTROL |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
379 case 5: openEdit_ViewPort(); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
380 break; |
951 | 381 #endif |
382 #ifdef ENABLE_GPIO_V2 | |
383 case 5: openEdit_WarningBuz(); | |
384 break; | |
385 #endif | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
386 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
387 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
388 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
389 /* Private functions ---------------------------------------------------------*/ |
520 | 390 void openEdit_Customview(void) |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
391 { |
706
10b7d271b9c4
Bugfix: only reset menu if a new sub menu is created:
Ideenmodellierer
parents:
700
diff
changeset
|
392 resetMenuEdit(CLUT_MenuPageCustomView); |
520 | 393 refresh_Customviews(); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
394 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
395 write_field_button(StMCustom1_CViewTimeout, 400, 700, ME_Y_LINE1, &FontT48, ""); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
396 write_field_button(StMCustom1_CViewStandard, 400, 700, ME_Y_LINE2, &FontT48, ""); |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
397 write_field_button(StMCustom1_CViewStandardBF, 400, 700, ME_Y_LINE3, &FontT48, ""); |
834
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
398 write_field_on_off(StMCustom1_CViewAutoFocusBF, 650, 700, ME_Y_LINE4, &FontT48, "", settingsGetPointer()->cvAutofocus); |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
399 write_field_button(StMCustom1_CornerTimeout, 400, 700, ME_Y_LINE5, &FontT48, ""); |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
400 write_field_button(StMCustom1_CornerStandard, 400, 700, ME_Y_LINE6, &FontT48, ""); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
401 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
402 setEvent(StMCustom1_CViewTimeout, (uint32_t)OnAction_CViewTimeout); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
403 setEvent(StMCustom1_CViewStandard, (uint32_t)OnAction_CViewStandard); |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
404 setEvent(StMCustom1_CViewStandardBF, (uint32_t)OnAction_CViewStandardBF); |
834
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
405 setEvent(StMCustom1_CViewAutoFocusBF, (uint32_t)OnAction_CViewAutofocusBF); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
406 setEvent(StMCustom1_CornerTimeout, (uint32_t)OnAction_CornerTimeout); |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
407 setEvent(StMCustom1_CornerStandard, (uint32_t)OnAction_CornerStandard); |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
408 } |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
409 |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
410 void openEdit_BigScreen(void) |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
411 { |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
412 uint8_t newValue = 0; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
413 SSettings *pSettings = settingsGetPointer(); |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
414 |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
415 newValue = pSettings->extraDisplay + 1; |
739 | 416 |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
417 if(newValue >= EXTRADISPLAY_END) |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
418 { |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
419 newValue = EXTRADISPLAY_none; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
420 } |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
421 pSettings->extraDisplay = newValue; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
422 |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
423 exitMenuEdit_to_Menu_with_Menu_Update_do_not_write_settings_for_this_only(); |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
424 } |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
425 |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
426 void openEdit_MotionCtrl(void) |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
427 { |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
428 uint8_t newValue = 0; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
429 SSettings *pSettings = settingsGetPointer(); |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
430 |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
431 switch(pSettings->MotionDetection) |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
432 { |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
433 case MOTION_DETECT_OFF: |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
434 newValue = MOTION_DETECT_MOVE; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
435 break; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
436 case MOTION_DETECT_MOVE: |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
437 newValue = MOTION_DETECT_SECTOR; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
438 break; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
439 case MOTION_DETECT_SECTOR: |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
440 newValue = MOTION_DETECT_SCROLL; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
441 break; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
442 case MOTION_DETECT_SCROLL: |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
443 newValue = MOTION_DETECT_OFF; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
444 break; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
445 default: |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
446 newValue = MOTION_DETECT_OFF; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
447 break; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
448 } |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
449 pSettings->MotionDetection = newValue; |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
450 InitMotionDetection(); |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
451 |
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
452 exitMenuEdit_to_Menu_with_Menu_Update_do_not_write_settings_for_this_only(); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
453 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
454 |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
455 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
456 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
457 void openEdit_ViewPort(void) |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
458 { |
951 | 459 #ifdef ENABLE_MOTION_CONTROL |
706
10b7d271b9c4
Bugfix: only reset menu if a new sub menu is created:
Ideenmodellierer
parents:
700
diff
changeset
|
460 resetMenuEdit(CLUT_MenuPageCustomView); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
461 refresh_ViewPort(); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
462 |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
463 write_field_button(StMCustom5_CViewPortCalib, 400, 700, ME_Y_LINE2, &FontT48, ""); |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
464 write_field_button(StMCustom5_CViewPortSpotSize,400, 700, ME_Y_LINE3, &FontT48, ""); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
465 write_field_button(StMCustom5_CViewPortLayout, 400, 700, ME_Y_LINE4, &FontT48, ""); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
466 write_field_button(StMCustom5_CViewPortAmbient, 400, 700, ME_Y_LINE5, &FontT48, ""); |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
467 write_field_button(StMCustom5_CViewPortControl, 400, 700, ME_Y_LINE6, &FontT48, ""); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
468 |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
469 setEvent(StMCustom5_CViewPortCalib, (uint32_t)OnAction_CViewPortCalib); |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
470 setEvent(StMCustom5_CViewPortSpotSize, (uint32_t)OnAction_CViewPortSpot); |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
471 setEvent(StMCustom5_CViewPortLayout, (uint32_t)OnAction_CViewPortLayout); |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
472 setEvent(StMCustom5_CViewPortAmbient, (uint32_t)OnAction_CViewPortAmbient); |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
473 setEvent(StMCustom5_CViewPortControl, (uint32_t)OnAction_CViewPortControl); |
951 | 474 #endif |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
475 } |
951 | 476 void openEdit_WarningBuz(void) |
477 { | |
478 SSettings *pSettings = settingsGetPointer(); | |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
479 |
951 | 480 if(pSettings->warningBuzzer == 0) |
481 { | |
482 pSettings->warningBuzzer = 1; | |
483 } | |
484 else | |
485 { | |
486 pSettings->warningBuzzer = 0; | |
487 } | |
488 exitMenuEdit_to_Menu_with_Menu_Update_do_not_write_settings_for_this_only(); | |
489 } | |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
490 |
520 | 491 char customview_TXT2BYTE_helper(uint8_t customViewId) |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
492 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
493 char text = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
494 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
495 switch(customViewId) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
496 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
497 case CVIEW_sensors: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
498 text = TXT2BYTE_O2monitor; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
499 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
500 case CVIEW_sensors_mV: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
501 text = TXT2BYTE_O2voltage; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
502 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
503 case CVIEW_Compass: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
504 text = TXT2BYTE_Compass; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
505 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
506 case CVIEW_Decolist: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
507 text = TXT2BYTE_Decolist; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
508 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
509 case CVIEW_Tissues: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
510 text = TXT2BYTE_Tissues; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
511 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
512 case CVIEW_Profile: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
513 text = TXT2BYTE_Profile; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
514 break; |
531 | 515 case CVIEW_Gaslist: |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
516 text = TXT2BYTE_Gaslist; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
517 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
518 case CVIEW_EADTime: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
519 text = TXT2BYTE_Info; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
520 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
521 case CVIEW_SummaryOfLeftCorner: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
522 text = TXT2BYTE_Summary; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
523 break; |
805
dd7ce655db26
Adds a simple countdown timer, available as a custom view in surface and dive mode.
heinrichsweikamp
parents:
751
diff
changeset
|
524 case CVIEW_Timer: |
dd7ce655db26
Adds a simple countdown timer, available as a custom view in surface and dive mode.
heinrichsweikamp
parents:
751
diff
changeset
|
525 text = TXT2BYTE_Timer; |
dd7ce655db26
Adds a simple countdown timer, available as a custom view in surface and dive mode.
heinrichsweikamp
parents:
751
diff
changeset
|
526 break; |
899
2225c467f1e9
Added data path and visualization for position data:
Ideenmodellierer
parents:
852
diff
changeset
|
527 case CVIEW_Position: |
2225c467f1e9
Added data path and visualization for position data:
Ideenmodellierer
parents:
852
diff
changeset
|
528 text = TXT2BYTE_Position; |
2225c467f1e9
Added data path and visualization for position data:
Ideenmodellierer
parents:
852
diff
changeset
|
529 break; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
530 case CVIEW_noneOrDebug: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
531 text = TXT2BYTE_DispNoneDbg; |
820 | 532 break; |
533 default: | |
534 break; | |
535 } | |
536 return text; | |
537 } | |
538 char customviewBF_TXT2BYTE_helper(uint8_t customViewId) | |
539 { | |
540 char text = 0; | |
541 | |
542 switch(customViewId) | |
543 { | |
544 case CVIEW_T3_noneOrDebug: | |
545 text = TXT2BYTE_DispNoneDbg; | |
546 break; | |
547 case CVIEW_T3_sensors: | |
548 text = TXT2BYTE_O2monitor; | |
549 break; | |
550 case CVIEW_T3_Compass: | |
551 text = TXT2BYTE_Compass; | |
552 break; | |
553 case CVIEW_T3_Decostop: | |
554 text = TXT2BYTE_Decolist; | |
555 break; | |
556 #ifdef ENABLE_T3_PROFILE_VIEW | |
557 case CVIEW_T3_Profile: | |
558 text = TXT2BYTE_Profile; | |
559 break; | |
560 #endif | |
836
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
561 case CVIEW_T3_Temperature: |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
562 text = TXT2BYTE_AmbientTemperature; |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
563 break; |
820 | 564 case CVIEW_T3_GasList: |
565 text = TXT2BYTE_Gaslist; | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
566 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
567 case CVIEW_T3_MaxDepth: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
568 text = TXT2BYTE_MaxDepth; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
569 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
570 case CVIEW_T3_StopWatch: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
571 text = TXT2BYTE_Stopwatch; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
572 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
573 case CVIEW_T3_TTS: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
574 text = TXT2BYTE_TTS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
575 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
576 case CVIEW_T3_ppO2andGas: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
577 text = TXT2BYTE_ppoNair; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
578 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
579 case CVIEW_T3_Navigation: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
580 text = TXT2BYTE_Navigation; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
581 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
582 case CVIEW_T3_DepthData: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
583 text = TXT2BYTE_DepthData; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
584 break; |
542
6960df7ddb09
Added new t3 view showing first deco stop and tts in parallel:
Ideenmodellierer
parents:
541
diff
changeset
|
585 case CVIEW_T3_DecoTTS: |
6960df7ddb09
Added new t3 view showing first deco stop and tts in parallel:
Ideenmodellierer
parents:
541
diff
changeset
|
586 text = TXT2BYTE_DecoTTS; |
6960df7ddb09
Added new t3 view showing first deco stop and tts in parallel:
Ideenmodellierer
parents:
541
diff
changeset
|
587 break; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
588 default: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
589 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
590 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
591 return text; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
592 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
593 |
520 | 594 uint8_t OnAction_CViewTimeout(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
595 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
596 uint8_t value; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
597 value = settingsGetPointer()->tX_customViewTimeout; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
598 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
599 if(value < 5) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
600 value = 5; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
601 else if(value < 10) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
602 value = 10; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
603 else if(value < 15) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
604 value = 15; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
605 else if(value < 20) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
606 value = 20; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
607 else if(value < 30) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
608 value = 30; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
609 else if(value < 45) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
610 value = 45; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
611 else if(value < 60) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
612 value = 60; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
613 else |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
614 value = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
615 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
616 settingsGetPointer()->tX_customViewTimeout = value; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
617 return UPDATE_DIVESETTINGS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
618 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
619 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
620 |
520 | 621 uint8_t OnAction_CViewStandard(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
622 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
623 uint8_t newValue; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
624 switch(settingsGetPointer()->tX_customViewPrimary) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
625 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
626 case CVIEW_sensors: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
627 newValue = CVIEW_sensors_mV; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
628 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
629 case CVIEW_sensors_mV: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
630 newValue = CVIEW_Compass; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
631 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
632 case CVIEW_Compass: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
633 newValue = CVIEW_Decolist; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
634 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
635 case CVIEW_Decolist: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
636 newValue = CVIEW_Tissues; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
637 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
638 case CVIEW_Tissues: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
639 newValue = CVIEW_Profile; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
640 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
641 case CVIEW_Profile: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
642 newValue = CVIEW_Gaslist; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
643 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
644 case CVIEW_Gaslist: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
645 newValue = CVIEW_EADTime; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
646 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
647 case CVIEW_EADTime: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
648 newValue = CVIEW_SummaryOfLeftCorner; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
649 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
650 case CVIEW_SummaryOfLeftCorner: |
805
dd7ce655db26
Adds a simple countdown timer, available as a custom view in surface and dive mode.
heinrichsweikamp
parents:
751
diff
changeset
|
651 newValue = CVIEW_Timer; |
dd7ce655db26
Adds a simple countdown timer, available as a custom view in surface and dive mode.
heinrichsweikamp
parents:
751
diff
changeset
|
652 break; |
dd7ce655db26
Adds a simple countdown timer, available as a custom view in surface and dive mode.
heinrichsweikamp
parents:
751
diff
changeset
|
653 case CVIEW_Timer: |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
654 newValue = CVIEW_noneOrDebug; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
655 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
656 case CVIEW_noneOrDebug: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
657 default: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
658 newValue = CVIEW_sensors; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
659 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
660 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
661 settingsGetPointer()->tX_customViewPrimary = newValue; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
662 return UPDATE_DIVESETTINGS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
663 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
664 |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
665 uint8_t OnAction_CViewStandardBF(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
666 { |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
667 uint8_t index = 0; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
668 uint8_t newValue; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
669 |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
670 /* list contains all views which may be selected => get index of current setting */ |
820 | 671 while((settingsGetPointer()->tX_customViewPrimaryBF != cv_changelist_BS[index]) && (cv_changelist_BS[index] != CVIEW_T3_END)) |
541
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
672 { |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
673 index++; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
674 } |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
675 if((cv_changelist_BS[index] == CVIEW_T3_END) || (cv_changelist_BS[index+1] == CVIEW_T3_END)) /* invalid or last setting */ |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
676 { |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
677 newValue = cv_changelist_BS[0]; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
678 } |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
679 else |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
680 { |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
681 newValue = cv_changelist_BS[index + 1]; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
682 } |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
683 |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
684 settingsGetPointer()->tX_customViewPrimaryBF = newValue; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
685 return UPDATE_DIVESETTINGS; |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
686 } |
6fbf7cd391cb
Added default view selection and auto return to view to t3 visualization:
Ideenmodellierer
parents:
531
diff
changeset
|
687 |
834
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
688 uint8_t OnAction_CViewAutofocusBF(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
689 { |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
690 SSettings *pSettings = settingsGetPointer(); |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
691 if(pSettings->cvAutofocus) |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
692 { |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
693 pSettings->cvAutofocus = 0; |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
694 } |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
695 else |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
696 { |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
697 pSettings->cvAutofocus = 1; |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
698 } |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
699 tMenuEdit_set_on_off(editId, pSettings->cvAutofocus); |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
700 return UPDATE_DIVESETTINGS; |
2a8af51ab04d
Added event based display changes for big font view:
Ideenmodellierer
parents:
820
diff
changeset
|
701 } |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
702 |
520 | 703 uint8_t OnAction_CornerTimeout(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
704 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
705 uint8_t value; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
706 value = settingsGetPointer()->tX_userselectedLeftLowerCornerTimeout; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
707 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
708 if(value < 5) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
709 value = 5; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
710 else if(value < 10) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
711 value = 10; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
712 else if(value < 15) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
713 value = 15; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
714 else if(value < 20) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
715 value = 20; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
716 else if(value < 30) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
717 value = 30; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
718 else if(value < 45) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
719 value = 45; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
720 else if(value < 60) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
721 value = 60; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
722 else |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
723 value = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
724 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
725 settingsGetPointer()->tX_userselectedLeftLowerCornerTimeout = value; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
726 return UPDATE_DIVESETTINGS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
727 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
728 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
729 |
520 | 730 uint8_t OnAction_CornerStandard(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
731 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
732 uint8_t value; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
733 value = settingsGetPointer()->tX_userselectedLeftLowerCornerPrimary; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
734 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
735 value += 1; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
736 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
737 if(value >= LLC_END) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
738 value = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
739 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
740 settingsGetPointer()->tX_userselectedLeftLowerCornerPrimary = value; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
741 return UPDATE_DIVESETTINGS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
742 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
743 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
744 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
745 uint8_t OnAction_Customview_Toggle(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
746 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
747 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
748 uint8_t line = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
749 SSettings *pSettings = settingsGetPointer(); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
750 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
751 switch(editId) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
752 { |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
753 case StMCustom3_CViewSelection1: line = 1; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
754 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
755 case StMCustom3_CViewSelection2: line = 2; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
756 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
757 case StMCustom3_CViewSelection3: line = 3; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
758 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
759 case StMCustom3_CViewSelection4: line = 4; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
760 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
761 case StMCustom3_CViewSelection5: line = 5; |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
762 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
763 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
764 default: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
765 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
766 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
767 if(pcv_curchangelist == cv_changelist) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
768 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
769 pSettings->cv_configuration ^= 1 << (pcv_curchangelist[customviewsSubpage * 5 + line-1]); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
770 if(t7_GetEnabled_customviews() == 0) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
771 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
772 pSettings->cv_configuration ^= (1 << CVIEW_noneOrDebug); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
773 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
774 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
775 else |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
776 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
777 pSettings->cv_config_BigScreen ^= 1 << (pcv_curchangelist[customviewsSubpage * 5 + line-1]); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
778 if(t3_GetEnabled_customviews() == 0) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
779 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
780 pSettings->cv_config_BigScreen ^= (1 << CVIEW_noneOrDebug); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
781 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
782 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
783 return UPDATE_DIVESETTINGS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
784 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
785 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
786 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
787 uint8_t OnAction_Customview_NextPage(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
788 { |
852 | 789 resetMenuContentStructure(); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
790 customviewsSubpage++; |
852 | 791 |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
792 if(customviewsSubpage == customviewsSubpageMax) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
793 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
794 customviewsSubpage = 0; |
852 | 795 setMenuContentStructure(); |
796 tMenuEdit_select(StMCustom3_CViewSelection6); | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
797 } |
852 | 798 else |
799 { | |
800 setMenuContentStructure(); | |
801 } | |
802 | |
750
6bd21ebe1a93
Avoid blinking in customer view selection page:
Ideenmodellierer
parents:
739
diff
changeset
|
803 CustomviewDivemode_refresh(); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
804 return UPDATE_DIVESETTINGS; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
805 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
806 |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
807 uint8_t OnAction_CViewPortCalib(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
808 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
809 float heading; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
810 if(settingsGetPointer()->compassInertia) |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
811 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
812 heading = (uint16_t)compass_getCompensated(); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
813 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
814 else |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
815 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
816 heading = (uint16_t)stateUsed->lifeData.compass_heading; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
817 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
818 calibrateViewport(stateUsed->lifeData.compass_roll,stateUsed->lifeData.compass_pitch,heading); |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
819 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
820 return UPDATE_DIVESETTINGS; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
821 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
822 uint8_t OnAction_CViewPortLayout(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
823 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
824 SSettings* pSettings = settingsGetPointer(); |
700 | 825 if((pSettings->viewPortMode & 0x10) != 0) |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
826 { |
640 | 827 pSettings->viewPortMode &= 0xEF; /* 1110 1111 */ |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
828 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
829 else |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
830 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
831 pSettings->viewPortMode |= 0x10; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
832 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
833 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
834 return UPDATE_DIVESETTINGS; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
835 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
836 uint8_t OnAction_CViewPortAmbient(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
837 { |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
838 SSettings* pSettings = settingsGetPointer(); |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
839 if(((pSettings->viewPortMode +1) & 0x03) <= MAX_BACKLIGHT_BOOST) |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
840 { |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
841 pSettings->viewPortMode++; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
842 } |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
843 else |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
844 { |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
845 pSettings->viewPortMode &= 0xFC; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
846 } |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
847 |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
848 return UPDATE_DIVESETTINGS; |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
849 } |
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
850 |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
851 uint8_t OnAction_CViewPortControl(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
852 { |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
853 uint8_t newValue = 0; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
854 SSettings *pSettings = settingsGetPointer(); |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
855 |
604
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
856 switch(pSettings->MotionDetection) |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
857 { |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
858 case MOTION_DETECT_OFF: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
859 newValue = MOTION_DETECT_MOVE; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
860 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
861 case MOTION_DETECT_MOVE: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
862 newValue = MOTION_DETECT_SECTOR; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
863 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
864 case MOTION_DETECT_SECTOR: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
865 newValue = MOTION_DETECT_SCROLL; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
866 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
867 case MOTION_DETECT_SCROLL: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
868 newValue = MOTION_DETECT_OFF; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
869 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
870 default: |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
871 newValue = MOTION_DETECT_OFF; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
872 break; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
873 } |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
874 pSettings->MotionDetection = newValue; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
875 return UPDATE_DIVESETTINGS; |
fb5bb04ad914
Merged menu items of viewport and motion control:
Ideenmodellierer
parents:
600
diff
changeset
|
876 } |
552
531e7818b737
Added menu structure to acces viewport calibration:
Ideenmodellierer
parents:
542
diff
changeset
|
877 |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
878 uint8_t OnAction_CViewPortSpot(uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
879 { |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
880 uint8_t newValue = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
881 SSettings *pSettings = settingsGetPointer(); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
882 |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
883 newValue = ((pSettings->viewPortMode >> 5) + 1) & 0x03; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
884 if(newValue > MAX_FOCUS_LIMITER) |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
885 { |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
886 newValue = 0; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
887 } |
640 | 888 pSettings->viewPortMode &= 0x9F; /* 1001 1111 */ |
626
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
889 pSettings->viewPortMode |= (newValue << 5); |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
890 return UPDATE_DIVESETTINGS; |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
891 } |
3e1a0e267f38
Added option to select sensitivity of focus detection:
Ideenmodellierer
parents:
625
diff
changeset
|
892 |
852 | 893 void setMenuContentStructure() |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
894 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
895 char text[MAX_PAGE_TEXTSIZE]; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
896 uint8_t textPointer = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
897 uint32_t id; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
898 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
899 uint8_t i; |
836
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
900 uint8_t endID = CVIEW_END; |
852 | 901 SSettings *pSettings = settingsGetPointer(); |
836
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
902 |
852 | 903 if(pcv_curchangelist == cv_changelist_BS) |
836
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
904 { |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
905 endID = CVIEW_T3_END; |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
906 } |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
907 |
852 | 908 for(i=0; i<5;i++) /* fill maximum 5 items and leave last one for sub page selection */ |
909 { | |
910 textPointer = 0; | |
911 id = pcv_curchangelist[customviewsSubpage * 5 + i]; | |
912 if(id == endID) /* last list item? */ | |
913 { | |
914 break; | |
915 } | |
916 else | |
917 { | |
918 if(pcv_curchangelist == cv_changelist) | |
919 { | |
920 text[textPointer++] = '\006' - CHECK_BIT_THOME(pSettings->cv_configuration,id); | |
921 } | |
922 else | |
923 { | |
924 text[textPointer++] = '\006' - CHECK_BIT_THOME(pSettings->cv_config_BigScreen,id); | |
925 } | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
926 text[textPointer++] = ' '; |
520 | 927 textPointer += snprintf(&text[textPointer], 60, "%c%c\n\r", TXT_2BYTE, customview_TXT2BYTE_helper(id)); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
928 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
929 switch(i) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
930 { |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
931 case 0: write_field_button(StMCustom3_CViewSelection1, 30, 800, ME_Y_LINE1, &FontT48, ""); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
932 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
933 case 1: write_field_button(StMCustom3_CViewSelection2, 30, 800, ME_Y_LINE2, &FontT48, ""); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
934 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
935 case 2: write_field_button(StMCustom3_CViewSelection3, 30, 800, ME_Y_LINE3, &FontT48, ""); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
936 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
937 case 3: write_field_button(StMCustom3_CViewSelection4, 30, 800, ME_Y_LINE4, &FontT48, ""); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
938 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
939 case 4: write_field_button(StMCustom3_CViewSelection5, 30, 800, ME_Y_LINE5, &FontT48, ""); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
940 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
941 default: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
942 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
943 } |
852 | 944 } |
945 } | |
946 for(;i<5;i++) /* clear empty lines in case menu shows less than 5 entries */ | |
947 { | |
948 switch(i) | |
949 { | |
950 case 0: write_label_var( 30, 800, ME_Y_LINE1, &FontT48, ""); | |
951 break; | |
952 case 1: write_label_var( 30, 800, ME_Y_LINE2, &FontT48, ""); | |
953 break; | |
954 case 2: write_label_var( 30, 800, ME_Y_LINE3, &FontT48, ""); | |
955 break; | |
956 case 3: write_label_var( 30, 800, ME_Y_LINE4, &FontT48, ""); | |
957 break; | |
958 case 4: write_label_var( 30, 800, ME_Y_LINE5, &FontT48, ""); | |
959 break; | |
960 default: | |
961 break; | |
962 }; | |
963 } | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
964 |
852 | 965 if(customviewsSubpageMax != 1) |
966 { | |
967 textPointer = 0; | |
968 text[textPointer++] = TXT_2BYTE; | |
969 text[textPointer++] = TXT2BYTE_ButtonNext; | |
970 text[textPointer] = 0; | |
971 write_field_button(StMCustom3_CViewSelection6, 30, 800, ME_Y_LINE6, &FontT48, text); | |
972 } | |
973 | |
974 /* because of the ID handling inside of the functions, all buttons needs to be assigned before the events may be set => have the same loop twice */ | |
975 for(i=0; i<5;i++) /* fill maximum 5 items and leave last one for sub page selection */ | |
976 { | |
977 id = pcv_curchangelist[customviewsSubpage * 5 + i]; | |
978 if(id == endID) /* last list item? */ | |
979 { | |
980 break; | |
981 } | |
982 else | |
983 { | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
984 switch(i) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
985 { |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
986 case 0: setEvent(StMCustom3_CViewSelection1, (uint32_t)OnAction_Customview_Toggle); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
987 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
988 case 1: setEvent(StMCustom3_CViewSelection2, (uint32_t)OnAction_Customview_Toggle); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
989 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
990 case 2: setEvent(StMCustom3_CViewSelection3, (uint32_t)OnAction_Customview_Toggle); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
991 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
992 case 3: setEvent(StMCustom3_CViewSelection4, (uint32_t)OnAction_Customview_Toggle); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
993 break; |
521
e221cf762f45
Move Bigfont and motion Ctrl selection menu out of custom view submenu:
Ideenmodellierer
parents:
520
diff
changeset
|
994 case 4: setEvent(StMCustom3_CViewSelection5, (uint32_t)OnAction_Customview_Toggle); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
995 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
996 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
997 default: |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
998 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
999 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1000 |
852 | 1001 } |
1002 } | |
1003 if(customviewsSubpageMax != 1) | |
1004 { | |
1005 setEvent(StMCustom3_CViewSelection6,(uint32_t)OnAction_Customview_NextPage); | |
1006 } | |
1007 } | |
1008 void openEdit_CustomviewDivemode(const uint8_t* pcv_changelist) | |
1009 { | |
1010 resetMenuEdit(CLUT_MenuPageCustomView); | |
1011 customviewsSubpageMax = (tHome_getNumberOfAvailableCVs(pcv_changelist) / CV_PER_PAGE) + 1; | |
750
6bd21ebe1a93
Avoid blinking in customer view selection page:
Ideenmodellierer
parents:
739
diff
changeset
|
1012 |
852 | 1013 if(pcv_curchangelist != pcv_changelist) /* new selection base? => reset page index */ |
1014 { | |
1015 customviewsSubpage = 0; | |
1016 } | |
1017 pcv_curchangelist = pcv_changelist; | |
1018 | |
1019 setMenuContentStructure(); | |
1020 | |
1021 write_buttonTextline(TXT2BYTE_ButtonBack,TXT2BYTE_ButtonEnter,TXT2BYTE_ButtonNext); | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1022 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1023 |
520 | 1024 void openEdit_CustomviewDivemodeMenu(uint8_t line) |
1025 { | |
1026 static uint8_t customviewsSubpage = 0; | |
1027 SSettings *pSettings = settingsGetPointer(); | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1028 |
815
ce8f71217f45
Bugfix CustomView selection during dive mode:
Ideenmodellierer
parents:
805
diff
changeset
|
1029 customviewsSubpageMax = (tHome_getNumberOfAvailableCVs(cv_changelist) / CV_PER_PAGE) + 1; |
520 | 1030 |
1031 if((line == 6) || (cv_changelist[customviewsSubpage * 5 + line-1] == CVIEW_END)) /* select next set of views */ | |
1032 { | |
1033 customviewsSubpage++; | |
815
ce8f71217f45
Bugfix CustomView selection during dive mode:
Ideenmodellierer
parents:
805
diff
changeset
|
1034 if(customviewsSubpage == customviewsSubpageMax) |
520 | 1035 { |
1036 customviewsSubpage = 0; | |
1037 } | |
1038 set_CustomsviewsSubpage(customviewsSubpage); | |
1039 /* rebuild the selection page with the next set of customer views */ | |
815
ce8f71217f45
Bugfix CustomView selection during dive mode:
Ideenmodellierer
parents:
805
diff
changeset
|
1040 updateSpecificMenu(StMSYS); |
520 | 1041 openMenu(0); |
1042 } | |
1043 else | |
1044 { | |
1045 pSettings->cv_configuration ^= 1 << (cv_changelist[customviewsSubpage * 5 + line-1]); | |
1046 if(t7_GetEnabled_customviews() == 0) | |
1047 { | |
1048 pSettings->cv_configuration ^= (1 << CVIEW_noneOrDebug); | |
1049 } | |
1050 InitMotionDetection(); /* consider new view setup for view selection by motion */ | |
1051 exitMenuEdit_to_Menu_with_Menu_Update(); | |
1052 } | |
1053 } | |
1054 | |
1055 uint8_t OnAction_ExtraDisplay (uint32_t editId, uint8_t blockNumber, uint8_t digitNumber, uint8_t digitContent, uint8_t action) | |
1056 { | |
1057 uint8_t newValue; | |
1058 | |
1059 newValue = settingsGetPointer()->extraDisplay + 1; | |
739 | 1060 |
520 | 1061 if(newValue >= EXTRADISPLAY_END) |
1062 { | |
1063 newValue = EXTRADISPLAY_none; | |
1064 } | |
1065 settingsGetPointer()->extraDisplay = newValue; | |
1066 return UNSPECIFIC_RETURN; | |
1067 } | |
1068 | |
1069 void CustomviewDivemode_refresh() | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1070 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1071 SSettings *pSettings = settingsGetPointer(); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1072 char text[MAX_PAGE_TEXTSIZE]; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1073 uint8_t textPointer = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1074 uint32_t id; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1075 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1076 uint8_t i; |
836
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
1077 uint8_t endID = CVIEW_END; |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
1078 |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
1079 if(pcv_curchangelist == cv_changelist_BS) |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
1080 { |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
1081 endID = CVIEW_T3_END; |
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
1082 } |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1083 |
531 | 1084 text[textPointer++] = '\001'; |
1085 text[textPointer++] = TXT_2BYTE; | |
1086 text[textPointer++] = TXT2BYTE_SelectCustomviews; | |
1087 text[textPointer++] = ' '; | |
1088 text[textPointer++] = '1' + customviewsSubpage; | |
1089 text[textPointer++] = 0; | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1090 write_topline(text); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1091 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1092 |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1093 for(i=0; i<5;i++) /* fill maximum 5 items and leave last one for sub page selection */ |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1094 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1095 textPointer = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1096 id = pcv_curchangelist[customviewsSubpage * 5 + i]; |
836
8d6c35655d4d
Bugfix BF temperatur display and cv switching:
ideenmodellierer
parents:
835
diff
changeset
|
1097 if(id == endID) /* last list item? */ |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1098 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1099 break; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1100 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1101 else |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1102 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1103 if(pcv_curchangelist == cv_changelist) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1104 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1105 text[textPointer++] = '\006' - CHECK_BIT_THOME(pSettings->cv_configuration,id); |
820 | 1106 text[textPointer++] = ' '; |
1107 textPointer += snprintf(&text[textPointer], 60, "%c%c\n\r", TXT_2BYTE, customview_TXT2BYTE_helper(id)); | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1108 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1109 else |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1110 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1111 text[textPointer++] = '\006' - CHECK_BIT_THOME(pSettings->cv_config_BigScreen,id); |
820 | 1112 text[textPointer++] = ' '; |
1113 textPointer += snprintf(&text[textPointer], 60, "%c%c\n\r", TXT_2BYTE, customviewBF_TXT2BYTE_helper(id)); | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1114 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1115 |
820 | 1116 switch(i) |
1117 { | |
1118 case 0: write_label_var( 30, 800, ME_Y_LINE1, &FontT48, text); | |
1119 break; | |
1120 case 1: write_label_var( 30, 800, ME_Y_LINE2, &FontT48, text); | |
1121 break; | |
1122 case 2: write_label_var( 30, 800, ME_Y_LINE3, &FontT48, text); | |
1123 break; | |
1124 case 3: write_label_var( 30, 800, ME_Y_LINE4, &FontT48, text); | |
1125 break; | |
1126 case 4: write_label_var( 30, 800, ME_Y_LINE5, &FontT48, text); | |
1127 break; | |
1128 default: | |
1129 break; | |
1130 } | |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1131 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1132 } |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1133 if(customviewsSubpageMax != 1) |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1134 { |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1135 textPointer = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1136 text[textPointer++] = TXT_2BYTE; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1137 text[textPointer++] = TXT2BYTE_ButtonNext; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1138 text[textPointer] = 0; |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1139 write_label_var( 30, 800, ME_Y_LINE6, &FontT48, text); |
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1140 } |
515
218ac999e96b
Added missing display of button labels in refresh function:
Ideenmodellierer
parents:
506
diff
changeset
|
1141 write_buttonTextline(TXT2BYTE_ButtonBack,TXT2BYTE_ButtonEnter,TXT2BYTE_ButtonNext); |
506
998529b3e142
Added new top level menu for customization of views
Ideenmodellierer
parents:
diff
changeset
|
1142 } |