diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..fdc4b61 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +/MyLibsGeneral/.vscode/ +/Doc/ \ No newline at end of file diff --git a/Doc/html/____general__flash_8c_source.html b/Doc/html/____general__flash_8c_source.html index 35f7ff8..f97c936 100644 --- a/Doc/html/____general__flash_8c_source.html +++ b/Doc/html/____general__flash_8c_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Src/__general_flash.c Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Src/__general_flash.c Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({ - + + -
+
__general_flash.c
-
1#include "general_flash.h"
+
1#include "__general_flash.h"
2FLASH_EraseInitTypeDef EraseInitStruct;
3extern HAL_StatusTypeDef res_hal;
4unsigned CRC_Update;
@@ -302,11 +294,12 @@ $(function(){initNavTree('____general__flash_8c_source.html',''); initResizable(
192
+
diff --git a/Doc/html/____general__flash_8h_source.html b/Doc/html/____general__flash_8h_source.html index 4b017c4..463e16a 100644 --- a/Doc/html/____general__flash_8h_source.html +++ b/Doc/html/____general__flash_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/__general_flash.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/__general_flash.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({ - + + -
+
7
8//////////////////////////////////////////////////////////////////////
9/////////////////////////---USER SETTINGS---/////////////////////////
-
10
+
10
11
12/////////////////////////---USER SETTINGS---/////////////////////////
-
13#include "mylibs_defs.h"
+
13#include "mylibs_defs.h"
14
15
16
17/////////////////////////////////////////////////////////////////////
18////////////////////////////---DEFINES---////////////////////////////
-
19
+
19
20////////////////////////////---DEFINES---////////////////////////////
-
21
+
21
22
23/////////////////////////////////////////////////////////////////////
24///////////////////////---STRUCTURES & ENUMS---//////////////////////
-
25
+
25
26///////////////////////---STRUCTURES & ENUMS---//////////////////////
-
27
+
27
28
29/////////////////////////////////////////////////////////////////////
30///////////////////////////---FUNCTIONS---///////////////////////////
-
31
+
31
32HAL_StatusTypeDef FLASH_Enable_DualBankMode(void);
33HAL_StatusTypeDef FLASH_WriteProtection(uint32_t BankN, uint32_t WriteProtection);
34/* functions for reading bytes/halswords/words */
@@ -150,16 +142,17 @@ $(function(){initNavTree('____general__flash_8h_source.html',''); initResizable(
40HAL_StatusTypeDef FLASH_Write_HalfWord(uint32_t Address, uint16_t Data);
41HAL_StatusTypeDef FLASH_Write_Word(uint32_t Address, uint32_t Data);
42///////////////////////////---FUNCTIONS---///////////////////////////
-
43
+
43
44#endif // __FLASH_GENERAL_H_
Заголочный файл для дефайнов библиотеки MyLibsGeneral.
+ diff --git a/Doc/html/annotated.html b/Doc/html/annotated.html index 9b3b980..1481365 100644 --- a/Doc/html/annotated.html +++ b/Doc/html/annotated.html @@ -3,7 +3,7 @@ - + MyLibs: Class List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
 CGPIO_SwitchTypeDefСтруктура кнопки  CHF_StackFrame_tКонтекст стек-фрейма процессора при HardFault  CRTT_FlashHeader_tСтруктура RTT, которая будет положена в Flash - CSPI_SettingsTypeDef + CSPI_SettingsTypeDefСтруктура настроек SPI  CTIM_EncoderTypeDefСтруктура инициализации енкодера  CTIM_SettingsTypeDefСтруктура инициализации таймера - CUART_SettingsTypeDef + CUART_SettingsTypeDefСтруктура настроек UART  Cuint16_BitTypeDef  Cuint32_BitTypeDef  Cuint64_BitTypeDef @@ -122,10 +119,11 @@ $(function(){initNavTree('annotated.html',''); initResizable(); });
+ diff --git a/Doc/html/annotated_dup.js b/Doc/html/annotated_dup.js index 74f25da..7e0e8ac 100644 --- a/Doc/html/annotated_dup.js +++ b/Doc/html/annotated_dup.js @@ -5,10 +5,10 @@ var annotated_dup = [ "GPIO_SwitchTypeDef", "struct_g_p_i_o___switch_type_def.html", "struct_g_p_i_o___switch_type_def" ], [ "HF_StackFrame_t", "struct_h_f___stack_frame__t.html", "struct_h_f___stack_frame__t" ], [ "RTT_FlashHeader_t", "struct_r_t_t___flash_header__t.html", "struct_r_t_t___flash_header__t" ], - [ "SPI_SettingsTypeDef", "struct_s_p_i___settings_type_def.html", null ], + [ "SPI_SettingsTypeDef", "struct_s_p_i___settings_type_def.html", "struct_s_p_i___settings_type_def" ], [ "TIM_EncoderTypeDef", "struct_t_i_m___encoder_type_def.html", "struct_t_i_m___encoder_type_def" ], [ "TIM_SettingsTypeDef", "struct_t_i_m___settings_type_def.html", "struct_t_i_m___settings_type_def" ], - [ "UART_SettingsTypeDef", "struct_u_a_r_t___settings_type_def.html", null ], + [ "UART_SettingsTypeDef", "struct_u_a_r_t___settings_type_def.html", "struct_u_a_r_t___settings_type_def" ], [ "uint16_BitTypeDef", "unionuint16___bit_type_def.html", null ], [ "uint32_BitTypeDef", "unionuint32___bit_type_def.html", null ], [ "uint64_BitTypeDef", "unionuint64___bit_type_def.html", null ], diff --git a/Doc/html/bit__access_8h.html b/Doc/html/bit__access_8h.html index f0e236e..eacf932 100644 --- a/Doc/html/bit__access_8h.html +++ b/Doc/html/bit__access_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
-
bit_access.h File Reference
@@ -110,74 +104,72 @@ $(function(){initNavTree('bit__access_8h.html',''); initResizable(); });

Заголочный файл для дефайнов битового доступа. More...

#include "mylibs_defs.h"
-
- + Include dependency graph for bit_access.h:
+
Include dependency graph for bit_access.h:
-
- + This graph shows which files directly or indirectly include this file:
+
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

- - - - - - - - - + + + +

+

Classes

union  uint8_BitTypeDef
 
union  uint16_BitTypeDef
 
union  uint32_BitTypeDef
 
union  uint64_BitTypeDef
 
union  uint8_BitTypeDef
union  uint16_BitTypeDef
union  uint32_BitTypeDef
union  uint64_BitTypeDef
- - + - - + - - + - - + -

+

Macros

#define uint8_bit(_uint8_, _bit_)   (*(uint8_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
#define uint8_bit(_uint8_, _bit_)
 Получить n-й бит из uint8_t.
 
#define uint16_bit(_uint8_, _bit_)   (*(uint16_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
#define uint16_bit(_uint8_, _bit_)
 Получить n-й бит из uint16_t.
 
#define uint32_bit(_uint8_, _bit_)   (*(uint32_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
#define uint32_bit(_uint8_, _bit_)
 Получить n-й бит из uint32_t.
 
#define uint64_bit(_uint8_, _bit_)   (*(uint64_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
#define uint64_bit(_uint8_, _bit_)
 Получить n-й бит из uint64_t.
 
-

Detailed Description

+

Detailed Description

Заголочный файл для дефайнов битового доступа.

Definition in file bit_access.h.

+ +
diff --git a/Doc/html/bit__access_8h__dep__incl.map b/Doc/html/bit__access_8h__dep__incl.map index 5c825d5..11c4cbf 100644 --- a/Doc/html/bit__access_8h__dep__incl.map +++ b/Doc/html/bit__access_8h__dep__incl.map @@ -1,5 +1,5 @@ - - - - + + + + diff --git a/Doc/html/bit__access_8h__dep__incl.md5 b/Doc/html/bit__access_8h__dep__incl.md5 index 20054ed..2f7fcbf 100644 --- a/Doc/html/bit__access_8h__dep__incl.md5 +++ b/Doc/html/bit__access_8h__dep__incl.md5 @@ -1 +1 @@ -7a9fce78f461300acd0d2ab58815dc95 \ No newline at end of file +9d0f52ae67584f7f09caa88b8c7ab4e9 \ No newline at end of file diff --git a/Doc/html/bit__access_8h__dep__incl.png b/Doc/html/bit__access_8h__dep__incl.png index 3ef9c17..79f6619 100644 Binary files a/Doc/html/bit__access_8h__dep__incl.png and b/Doc/html/bit__access_8h__dep__incl.png differ diff --git a/Doc/html/bit__access_8h__incl.map b/Doc/html/bit__access_8h__incl.map index b03b1f1..9afbbb7 100644 --- a/Doc/html/bit__access_8h__incl.map +++ b/Doc/html/bit__access_8h__incl.map @@ -1,9 +1,9 @@ - - - - - - - - + + + + + + + + diff --git a/Doc/html/bit__access_8h__incl.md5 b/Doc/html/bit__access_8h__incl.md5 index 78ce098..dd84ccf 100644 --- a/Doc/html/bit__access_8h__incl.md5 +++ b/Doc/html/bit__access_8h__incl.md5 @@ -1 +1 @@ -2dcaa807e109473ed5b8776ffa4971c6 \ No newline at end of file +4b8c2556090cdbb9271b9fbe97d7cf5b \ No newline at end of file diff --git a/Doc/html/bit__access_8h__incl.png b/Doc/html/bit__access_8h__incl.png index 62b90d7..6e25770 100644 Binary files a/Doc/html/bit__access_8h__incl.png and b/Doc/html/bit__access_8h__incl.png differ diff --git a/Doc/html/bit__access_8h_source.html b/Doc/html/bit__access_8h_source.html index 9098471..37a5171 100644 --- a/Doc/html/bit__access_8h_source.html +++ b/Doc/html/bit__access_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
- + + -
+
+ diff --git a/Doc/html/classes.html b/Doc/html/classes.html index 23924c7..29c6937 100644 --- a/Doc/html/classes.html +++ b/Doc/html/classes.html @@ -3,7 +3,7 @@ - + MyLibs: Class Index @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
+
diff --git a/Doc/html/clipboard.js b/Doc/html/clipboard.js index 42c1fb0..9da9f3c 100644 --- a/Doc/html/clipboard.js +++ b/Doc/html/clipboard.js @@ -28,8 +28,8 @@ SOFTWARE. */ let clipboard_title = "Copy to clipboard" -let clipboard_icon = `` -let clipboard_successIcon = `` +let clipboard_icon = `` +let clipboard_successIcon = `` let clipboard_successDuration = 1000 $(function() { diff --git a/Doc/html/darkmode_toggle.js b/Doc/html/darkmode_toggle.js index b9c7364..9c1ca07 100644 --- a/Doc/html/darkmode_toggle.js +++ b/Doc/html/darkmode_toggle.js @@ -74,10 +74,15 @@ class DarkModeToggle extends HTMLElement { mainMenuVisible = menuStyle.display!=='none' } const searchBoxPos1 = document.getElementById("searchBoxPos1"); + const buttonLi = document.getElementById('toggle-dark-mode'); + if (buttonLi) { + buttonLi.parentNode.removeChild(buttonLi); + } if (searchBox) { // (1) search box visible searchBox.parentNode.appendChild(toggleButton) } else if (navRow1) { // (2) no search box, static menu bar const li = document.createElement('li'); + li.id = 'toggle-dark-mode'; li.style = 'float: right;' li.appendChild(toggleButton); toggleButton.style = 'width: 24px; height: 25px; padding-top: 11px; float: right;'; @@ -85,6 +90,7 @@ class DarkModeToggle extends HTMLElement { row.appendChild(li) } else if (mainMenu && mainMenuVisible) { // (3) no search box + dynamic menu bar expanded const li = document.createElement('li'); + li.id = 'toggle-dark-mode'; li.style = 'float: right;' li.appendChild(toggleButton); toggleButton.style = 'width: 14px; height: 36px; padding-top: 10px; float: right;'; diff --git a/Doc/html/dir_000002_000000.html b/Doc/html/dir_000002_000000.html index b7ab20a..fe40133 100644 --- a/Doc/html/dir_000002_000000.html +++ b/Doc/html/dir_000002_000000.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Src -> Inc Relation +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Src -> Inc Relation - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
-

Src → Inc Relation

File in MyLibsGeneral/SrcIncludes file in MyLibsGeneral/Inc
__general_spi.cgeneral_gpio.h
__general_uart.cgeneral_gpio.h
general_gpio.cgeneral_gpio.h
general_tim.cgeneral_tim.h
+

Src → Inc Relation

File in MyLibsGeneral/SrcIncludes file in MyLibsGeneral/Inc
general_gpio.cgeneral_gpio.h
general_spi.cgeneral_gpio.h
general_spi.cgeneral_spi.h
general_tim.cgeneral_tim.h
general_uart.cgeneral_gpio.h
general_uart.cgeneral_uart.h
+ +
diff --git a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4.html b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4.html index 4586fc7..958ae41 100644 --- a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4.html +++ b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Src Directory Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Src Directory Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
Src Directory Reference
-
- + Directory dependency graph for Src:
+
Directory dependency graph for Src:
- - - - - - - - + + - - + + + - + +

+

Files

 __general_flash.c
 
 __general_spi.c
 
 __general_uart.c
 
 general_gpio.c
 
__general_flash.c
 
general_gpio.c
 Модуль для инициализации портов и работы с ними.
 
 general_tim.c
 
general_spi.c
 Модуль для инициализации SPI.
 
general_tim.c
 Модуль для инициализации таймеров и работы с ними.
 
 
general_uart.c
 Модуль для инициализации UART.
+ + diff --git a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4.js b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4.js index 6df5d45..6f89d24 100644 --- a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4.js +++ b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4.js @@ -1,8 +1,8 @@ var dir_9c80311a018e1f8cfb6659b73d634be4 = [ [ "__general_flash.c", "____general__flash_8c_source.html", null ], - [ "__general_spi.c", "____general__spi_8c_source.html", null ], - [ "__general_uart.c", "____general__uart_8c_source.html", null ], [ "general_gpio.c", "general__gpio_8c.html", "general__gpio_8c" ], - [ "general_tim.c", "general__tim_8c.html", "general__tim_8c" ] + [ "general_spi.c", "general__spi_8c.html", "general__spi_8c" ], + [ "general_tim.c", "general__tim_8c.html", "general__tim_8c" ], + [ "general_uart.c", "general__uart_8c.html", "general__uart_8c" ] ]; \ No newline at end of file diff --git a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.map b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.map index 783d929..52c2821 100644 --- a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.map +++ b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.map @@ -1,7 +1,7 @@ - + - + diff --git a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.md5 b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.md5 index 1cbce3c..933f5ab 100644 --- a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.md5 +++ b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.md5 @@ -1 +1 @@ -84dda0250b351e30a8ed843193ca7a92 \ No newline at end of file +ffa428a4e7938b24bbf734d10d788ade \ No newline at end of file diff --git a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.png b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.png index 662c95b..41d2896 100644 Binary files a/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.png and b/Doc/html/dir_9c80311a018e1f8cfb6659b73d634be4_dep.png differ diff --git a/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515.html b/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515.html index ceb2fd5..48001a0 100644 --- a/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515.html +++ b/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral Directory Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral Directory Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
MyLibsGeneral Directory Reference
-
- + Directory dependency graph for MyLibsGeneral:
+
Directory dependency graph for MyLibsGeneral:
- - - - - + +

+

Directories

 Inc
 
 Src
 
 
Inc
 
Src
- - - +

+

Files

 mainpage.h
 
 
mainpage.h
+ + diff --git a/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.map b/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.map index 9406b23..65a89e3 100644 --- a/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.map +++ b/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.map @@ -1,7 +1,7 @@ - + - + diff --git a/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.md5 b/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.md5 index 9534313..13dbe4c 100644 --- a/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.md5 +++ b/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.md5 @@ -1 +1 @@ -9178b7f2911a2208010657da2be83ea6 \ No newline at end of file +8443f86a129039a222fea0f68a874d48 \ No newline at end of file diff --git a/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.png b/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.png index 755f4fd..8bc91fc 100644 Binary files a/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.png and b/Doc/html/dir_9e11e9a41112194af3eee6cc728f9515_dep.png differ diff --git a/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1.html b/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1.html index 8a9cc60..8a5dfde 100644 --- a/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1.html +++ b/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc Directory Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc Directory Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
Inc Directory Reference
-
- + Directory dependency graph for Inc:
+
Directory dependency graph for Inc:
- - - - - - - - + + - - + - - + - - + + + - - + + + - - + - - + - - + - - + -

+

Files

 __general_flash.h
 
 __general_spi.h
 
 __general_uart.h
 
 bit_access.h
 
__general_flash.h
 
bit_access.h
 Заголочный файл для дефайнов битового доступа.
 
 evolve_optimizer.h
 
evolve_optimizer.h
 Заголовочный файл для адаптивного подбора параметров
 
 general_gpio.h
 
general_gpio.h
 Заголовочный файл для модуля инициализации портов и работы с ними.
 
 general_tim.h
 
general_spi.h
 Заголовочный файл для модуля инициализации SPI.
 
general_tim.h
 Заголовочный файл для модуля инициализации таймеров и работы с ними.
 
 mylibs_config.h
 
general_uart.h
 Заголовочный файл для модуля инициализации UART.
 
mylibs_config.h
 Конфигурации для библиотек MyLibs.
 
 mylibs_defs.h
 
mylibs_defs.h
 Заголочный файл для дефайнов библиотеки MyLibsGeneral.
 
 mylibs_include.h
 
mylibs_include.h
 Заголочный файл для всех библиотек
 
 trace.h
 
trace.h
 Заголочный файл для работы с трассировкой.
 
 trackers.h
 
trackers.h
 Заголочный файл для работы с трекерами Trackers defines.
 
+ + diff --git a/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1.js b/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1.js index 68cf10b..3cc106f 100644 --- a/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1.js +++ b/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1.js @@ -1,12 +1,12 @@ var dir_eb423fea8a9c4b9b32b922020ec391e1 = [ [ "__general_flash.h", "____general__flash_8h_source.html", null ], - [ "__general_spi.h", "____general__spi_8h_source.html", null ], - [ "__general_uart.h", "____general__uart_8h_source.html", null ], [ "bit_access.h", "bit__access_8h.html", "bit__access_8h" ], [ "evolve_optimizer.h", "evolve__optimizer_8h.html", "evolve__optimizer_8h" ], [ "general_gpio.h", "general__gpio_8h.html", "general__gpio_8h" ], + [ "general_spi.h", "general__spi_8h.html", "general__spi_8h" ], [ "general_tim.h", "general__tim_8h.html", "general__tim_8h" ], + [ "general_uart.h", "general__uart_8h.html", "general__uart_8h" ], [ "mylibs_config.h", "mylibs__config_8h.html", "mylibs__config_8h" ], [ "mylibs_defs.h", "mylibs__defs_8h.html", "mylibs__defs_8h" ], [ "mylibs_include.h", "mylibs__include_8h.html", null ], diff --git a/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1_dep.map b/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1_dep.map index e44b344..8f7cb36 100644 --- a/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1_dep.map +++ b/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1_dep.map @@ -1,4 +1,4 @@ - + diff --git a/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1_dep.md5 b/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1_dep.md5 index bb4da48..f594f8b 100644 --- a/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1_dep.md5 +++ b/Doc/html/dir_eb423fea8a9c4b9b32b922020ec391e1_dep.md5 @@ -1 +1 @@ -88eae9c3335ed0a89cb7c7066ad193a7 \ No newline at end of file +51bda8bf2e3b4eafeabf6cf3520068b7 \ No newline at end of file diff --git a/Doc/html/doxygen.css b/Doc/html/doxygen.css index 7dbff89..59138c1 100644 --- a/Doc/html/doxygen.css +++ b/Doc/html/doxygen.css @@ -1,11 +1,12 @@ -/* The standard CSS for doxygen 1.10.0*/ +/* The standard CSS for doxygen 1.14.0*/ html { /* page base colors */ --page-background-color: white; --page-foreground-color: black; --page-link-color: #3D578C; ---page-visited-link-color: #4665A2; +--page-visited-link-color: #3D578C; +--page-external-link-color: #334975; /* index */ --index-odd-item-bg-color: #F8F9FC; @@ -16,46 +17,50 @@ html { /* header */ --header-background-color: #F9FAFC; --header-separator-color: #C4CFE5; ---header-gradient-image: url('nav_h.png'); ---group-header-separator-color: #879ECB; +--group-header-separator-color: #D9E0EE; --group-header-color: #354C7B; --inherit-header-color: gray; --footer-foreground-color: #2A3D61; ---footer-logo-width: 104px; +--footer-logo-width: 75px; --citation-label-color: #334975; --glow-color: cyan; --title-background-color: white; ---title-separator-color: #5373B4; +--title-separator-color: #C4CFE5; --directory-separator-color: #9CAFD4; --separator-color: #4A6AAA; --blockquote-background-color: #F7F8FB; --blockquote-border-color: #9CAFD4; ---scrollbar-thumb-color: #9CAFD4; +--scrollbar-thumb-color: #C4CFE5; --scrollbar-background-color: #F9FAFC; --icon-background-color: #728DC1; --icon-foreground-color: white; +/* --icon-doc-image: url('doc.svg'); --icon-folder-open-image: url('folderopen.svg'); ---icon-folder-closed-image: url('folderclosed.svg'); +--icon-folder-closed-image: url('folderclosed.svg');*/ +--icon-folder-open-fill-color: #C4CFE5; +--icon-folder-fill-color: #D8DFEE; +--icon-folder-border-color: #4665A2; +--icon-doc-fill-color: #D8DFEE; +--icon-doc-border-color: #4665A2; /* brief member declaration list */ --memdecl-background-color: #F9FAFC; --memdecl-separator-color: #DEE4F0; --memdecl-foreground-color: #555; --memdecl-template-color: #4665A2; +--memdecl-border-color: #D5DDEC; /* detailed member list */ --memdef-border-color: #A8B8D9; --memdef-title-background-color: #E2E8F2; ---memdef-title-gradient-image: url('nav_f.png'); ---memdef-proto-background-color: #DFE5F1; +--memdef-proto-background-color: #EEF1F7; --memdef-proto-text-color: #253555; ---memdef-proto-text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); --memdef-doc-background-color: white; --memdef-param-name-color: #602020; --memdef-template-color: #4665A2; @@ -74,29 +79,34 @@ html { /** navigation bar/tree/menu */ --nav-background-color: #F9FAFC; --nav-foreground-color: #364D7C; ---nav-gradient-image: url('tab_b.png'); ---nav-gradient-hover-image: url('tab_h.png'); ---nav-gradient-active-image: url('tab_a.png'); ---nav-gradient-active-image-parent: url("../tab_a.png"); ---nav-separator-image: url('tab_s.png'); ---nav-breadcrumb-image: url('bc_s.png'); ---nav-breadcrumb-border-color: #C2CDE4; ---nav-splitbar-image: url('splitbar.png'); +--nav-border-color: #C4CFE5; +--nav-breadcrumb-separator-color: #C4CFE5; +--nav-breadcrumb-active-bg: #EEF1F7; +--nav-breadcrumb-color: #354C7B; +--nav-breadcrumb-border-color: #E1E7F2; +--nav-splitbar-bg-color: #DCE2EF; +--nav-splitbar-handle-color: #9CAFD4; --nav-font-size-level1: 13px; --nav-font-size-level2: 10px; --nav-font-size-level3: 9px; --nav-text-normal-color: #283A5D; --nav-text-hover-color: white; --nav-text-active-color: white; ---nav-text-normal-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); ---nav-text-hover-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); ---nav-text-active-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); --nav-menu-button-color: #364D7C; --nav-menu-background-color: white; --nav-menu-foreground-color: #555555; +--nav-menu-active-bg: #DCE2EF; +--nav-menu-active-color: #9CAFD4; --nav-menu-toggle-color: rgba(255, 255, 255, 0.5); ---nav-arrow-color: #9CAFD4; ---nav-arrow-selected-color: #9CAFD4; +--nav-arrow-color: #B6C4DF; +--nav-arrow-selected-color: #90A5CE; + +/* sync icon */ +--sync-icon-border-color: #C4CFE5; +--sync-icon-background-color: #F9FAFC; +--sync-icon-selected-background-color: #EEF1F7; +--sync-icon-color: #C4CFE5; +--sync-icon-selected-color: #6884BD; /* table of contents */ --toc-background-color: #F4F6FA; @@ -107,18 +117,20 @@ html { /** search field */ --search-background-color: white; --search-foreground-color: #909090; ---search-magnification-image: url('mag.svg'); ---search-magnification-select-image: url('mag_sel.svg'); --search-active-color: black; ---search-filter-background-color: #F9FAFC; +--search-filter-background-color: rgba(255,255,255,.7); +--search-filter-backdrop-filter: blur(4px); --search-filter-foreground-color: black; ---search-filter-border-color: #90A5CE; +--search-filter-border-color: rgba(150,150,150,.4); --search-filter-highlight-text-color: white; --search-filter-highlight-bg-color: #3D578C; --search-results-foreground-color: #425E97; ---search-results-background-color: #EEF1F7; ---search-results-border-color: black; ---search-box-shadow: inset 0.5px 0.5px 3px 0px #555; +--search-results-background-color: rgba(255,255,255,.8); +--search-results-backdrop-filter: blur(4px); +--search-results-border-color: rgba(150,150,150,.4); +--search-box-border-color: #B6C4DF; +--search-close-icon-bg-color: #A0A0A0; +--search-close-icon-fg-color: white; /** code fragments */ --code-keyword-color: #008000; @@ -147,23 +159,21 @@ html { --fragment-lineno-link-hover-bg-color: #C8C8C8; --fragment-copy-ok-color: #2EC82E; --tooltip-foreground-color: black; ---tooltip-background-color: white; ---tooltip-border-color: gray; +--tooltip-background-color: rgba(255,255,255,0.8); +--tooltip-arrow-background-color: white; +--tooltip-border-color: rgba(150,150,150,0.7); +--tooltip-backdrop-filter: blur(3px); --tooltip-doc-color: grey; --tooltip-declaration-color: #006318; --tooltip-link-color: #4665A2; ---tooltip-shadow: 1px 1px 7px gray; +--tooltip-shadow: 0 4px 8px 0 rgba(0,0,0,.25); --fold-line-color: #808080; ---fold-minus-image: url('minus.svg'); ---fold-plus-image: url('plus.svg'); ---fold-minus-image-relpath: url('../../minus.svg'); ---fold-plus-image-relpath: url('../../plus.svg'); /** font-family */ ---font-family-normal: Roboto,sans-serif; +--font-family-normal: system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol"; --font-family-monospace: 'JetBrains Mono',Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace,fixed; --font-family-nav: 'Lucida Grande',Geneva,Helvetica,Arial,sans-serif; ---font-family-title: Tahoma,Arial,sans-serif; +--font-family-title: system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol"; --font-family-toc: Verdana,'DejaVu Sans',Geneva,sans-serif; --font-family-search: Arial,Verdana,sans-serif; --font-family-icon: Arial,Helvetica; @@ -198,7 +208,8 @@ html.dark-mode { --page-background-color: black; --page-foreground-color: #C9D1D9; --page-link-color: #90A5CE; ---page-visited-link-color: #A3B4D7; +--page-visited-link-color: #90A5CE; +--page-external-link-color: #A3B4D7; /* index */ --index-odd-item-bg-color: #0B101A; @@ -209,8 +220,7 @@ html.dark-mode { /* header */ --header-background-color: #070B11; --header-separator-color: #141C2E; ---header-gradient-image: url('nav_hd.png'); ---group-header-separator-color: #283A5D; +--group-header-separator-color: #1D2A43; --group-header-color: #90A5CE; --inherit-header-color: #A0A0A0; @@ -220,35 +230,36 @@ html.dark-mode { --glow-color: cyan; --title-background-color: #090D16; ---title-separator-color: #354C79; +--title-separator-color: #212F4B; --directory-separator-color: #283A5D; --separator-color: #283A5D; --blockquote-background-color: #101826; --blockquote-border-color: #283A5D; ---scrollbar-thumb-color: #283A5D; +--scrollbar-thumb-color: #2C3F65; --scrollbar-background-color: #070B11; --icon-background-color: #334975; --icon-foreground-color: #C4CFE5; ---icon-doc-image: url('docd.svg'); ---icon-folder-open-image: url('folderopend.svg'); ---icon-folder-closed-image: url('folderclosedd.svg'); +--icon-folder-open-fill-color: #4665A2; +--icon-folder-fill-color: #5373B4; +--icon-folder-border-color: #C4CFE5; +--icon-doc-fill-color: #6884BD; +--icon-doc-border-color: #C4CFE5; /* brief member declaration list */ --memdecl-background-color: #0B101A; --memdecl-separator-color: #2C3F65; --memdecl-foreground-color: #BBB; --memdecl-template-color: #7C95C6; +--memdecl-border-color: #233250; /* detailed member list */ --memdef-border-color: #233250; --memdef-title-background-color: #1B2840; ---memdef-title-gradient-image: url('nav_fd.png'); --memdef-proto-background-color: #19243A; --memdef-proto-text-color: #9DB0D4; ---memdef-proto-text-shadow: 0px 1px 1px rgba(0, 0, 0, 0.9); --memdef-doc-background-color: black; --memdef-param-name-color: #D28757; --memdef-template-color: #7C95C6; @@ -267,29 +278,34 @@ html.dark-mode { /** navigation bar/tree/menu */ --nav-background-color: #101826; --nav-foreground-color: #364D7C; ---nav-gradient-image: url('tab_bd.png'); ---nav-gradient-hover-image: url('tab_hd.png'); ---nav-gradient-active-image: url('tab_ad.png'); ---nav-gradient-active-image-parent: url("../tab_ad.png"); ---nav-separator-image: url('tab_sd.png'); ---nav-breadcrumb-image: url('bc_sd.png'); +--nav-border-color: #212F4B; +--nav-breadcrumb-separator-color: #212F4B; +--nav-breadcrumb-active-bg: #1D2A43; +--nav-breadcrumb-color: #90A5CE; --nav-breadcrumb-border-color: #2A3D61; ---nav-splitbar-image: url('splitbard.png'); +--nav-splitbar-bg-color: #283A5D; +--nav-splitbar-handle-color: #4665A2; --nav-font-size-level1: 13px; --nav-font-size-level2: 10px; --nav-font-size-level3: 9px; --nav-text-normal-color: #B6C4DF; --nav-text-hover-color: #DCE2EF; --nav-text-active-color: #DCE2EF; ---nav-text-normal-shadow: 0px 1px 1px black; ---nav-text-hover-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); ---nav-text-active-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); --nav-menu-button-color: #B6C4DF; --nav-menu-background-color: #05070C; --nav-menu-foreground-color: #BBBBBB; +--nav-menu-active-bg: #1D2A43; +--nav-menu-active-color: #C9D3E7; --nav-menu-toggle-color: rgba(255, 255, 255, 0.2); ---nav-arrow-color: #334975; ---nav-arrow-selected-color: #90A5CE; +--nav-arrow-color: #4665A2; +--nav-arrow-selected-color: #6884BD; + +/* sync icon */ +--sync-icon-border-color: #212F4B; +--sync-icon-background-color: #101826; +--sync-icon-selected-background-color: #1D2A43; +--sync-icon-color: #4665A2; +--sync-icon-selected-color: #5373B4; /* table of contents */ --toc-background-color: #151E30; @@ -300,18 +316,20 @@ html.dark-mode { /** search field */ --search-background-color: black; --search-foreground-color: #C5C5C5; ---search-magnification-image: url('mag_d.svg'); ---search-magnification-select-image: url('mag_seld.svg'); ---search-active-color: #C5C5C5; +--search-active-color: #F5F5F5; --search-filter-background-color: #101826; --search-filter-foreground-color: #90A5CE; +--search-filter-backdrop-filter: none; --search-filter-border-color: #7C95C6; --search-filter-highlight-text-color: #BCC9E2; --search-filter-highlight-bg-color: #283A5D; ---search-results-background-color: #101826; +--search-results-background-color: black; --search-results-foreground-color: #90A5CE; ---search-results-border-color: #7C95C6; ---search-box-shadow: inset 0.5px 0.5px 3px 0px #2F436C; +--search-results-backdrop-filter: none; +--search-results-border-color: #334975; +--search-box-border-color: #334975; +--search-close-icon-bg-color: #909090; +--search-close-icon-fg-color: black; /** code fragments */ --code-keyword-color: #CC99CD; @@ -341,22 +359,20 @@ html.dark-mode { --fragment-copy-ok-color: #0EA80E; --tooltip-foreground-color: #C9D1D9; --tooltip-background-color: #202020; +--tooltip-arrow-background-color: #202020; +--tooltip-backdrop-filter: none; --tooltip-border-color: #C9D1D9; --tooltip-doc-color: #D9E1E9; --tooltip-declaration-color: #20C348; --tooltip-link-color: #79C0FF; --tooltip-shadow: none; --fold-line-color: #808080; ---fold-minus-image: url('minusd.svg'); ---fold-plus-image: url('plusd.svg'); ---fold-minus-image-relpath: url('../../minusd.svg'); ---fold-plus-image-relpath: url('../../plusd.svg'); /** font-family */ ---font-family-normal: Roboto,sans-serif; +--font-family-normal: system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol"; --font-family-monospace: 'JetBrains Mono',Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace,fixed; --font-family-nav: 'Lucida Grande',Geneva,Helvetica,Arial,sans-serif; ---font-family-title: Tahoma,Arial,sans-serif; +--font-family-title: system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,Noto Sans,sans-serif,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol"; --font-family-toc: Verdana,'DejaVu Sans',Geneva,sans-serif; --font-family-search: Arial,Verdana,sans-serif; --font-family-icon: Arial,Helvetica; @@ -387,8 +403,8 @@ html.dark-mode { } body { - background-color: var(--page-background-color); - color: var(--page-foreground-color); + background-color: var(--page-background-color); + color: var(--page-foreground-color); } body, table, div, p, dl { @@ -398,13 +414,22 @@ body, table, div, p, dl { line-height: 22px; } +body.resizing { + user-select: none; + -webkit-user-select: none; +} + +#doc-content { + scrollbar-width: thin; +} + /* @group Heading Levels */ .title { font-family: var(--font-family-normal); line-height: 28px; - font-size: 150%; - font-weight: bold; + font-size: 160%; + font-weight: 400; margin: 10px 2px; } @@ -413,7 +438,10 @@ h1.groupheader { } h2.groupheader { - border-bottom: 1px solid var(--group-header-separator-color); + box-shadow: 12px 0 var(--page-background-color), + -12px 0 var(--page-background-color), + 12px 1px var(--group-header-separator-color), + -12px 1px var(--group-header-separator-color); color: var(--group-header-color); font-size: 150%; font-weight: normal; @@ -423,6 +451,13 @@ h2.groupheader { width: 100%; } +td h2.groupheader { + box-shadow: 13px 0 var(--page-background-color), + -13px 0 var(--page-background-color), + 13px 1px var(--group-header-separator-color), + -13px 1px var(--group-header-separator-color); +} + h3.groupheader { font-size: 100%; } @@ -449,8 +484,8 @@ p.startli, p.startdd { } th p.starttd, th p.intertd, th p.endtd { - font-size: 100%; - font-weight: 700; + font-size: 100%; + font-weight: 700; } p.starttd { @@ -495,9 +530,11 @@ h3.version { } div.navtab { - padding-right: 15px; + margin-right: 6px; + padding-right: 6px; text-align: right; line-height: 110%; + background-color: var(--nav-background-color); } div.navtab table { @@ -510,19 +547,10 @@ td.navtab { } td.navtabHL { - background-image: var(--nav-gradient-active-image); - background-repeat:repeat-x; padding-right: 6px; padding-left: 6px; -} - -td.navtabHL a, td.navtabHL a:visited { - color: var(--nav-text-hover-color); - text-shadow: var(--nav-text-hover-shadow); -} - -a.navtab { - font-weight: bold; + border-radius: 0 6px 6px 0; + background-color: var(--nav-menu-active-bg); } div.qindex{ @@ -597,16 +625,11 @@ a { color: var(--page-visited-link-color); } -a:hover { +span.label a:hover { text-decoration: none; background: linear-gradient(to bottom, transparent 0,transparent calc(100% - 1px), currentColor 100%); } -a:hover > span.arrow { - text-decoration: none; - background : var(--nav-background-color); -} - a.el { font-weight: bold; } @@ -614,12 +637,12 @@ a.el { a.elRef { } -a.code, a.code:visited, a.line, a.line:visited { - color: var(--code-link-color); +a.el, a.el:visited, a.code, a.code:visited, a.line, a.line:visited { + color: var(--page-link-color); } a.codeRef, a.codeRef:visited, a.lineRef, a.lineRef:visited { - color: var(--code-external-link-color); + color: var(--page-external-link-color); } a.code.hl_class { /* style for links to class names in code snippets */ } @@ -655,103 +678,125 @@ dl.el { margin-left: -1cm; } +ul.check { + list-style:none; + text-indent: -16px; + padding-left: 38px; +} +li.unchecked:before { + content: "\2610\A0"; +} +li.checked:before { + content: "\2611\A0"; +} + +ol { + text-indent: 0px; +} + ul { - overflow: visible; + text-indent: 0px; + overflow: visible; } ul.multicol { - -moz-column-gap: 1em; - -webkit-column-gap: 1em; - column-gap: 1em; - -moz-column-count: 3; - -webkit-column-count: 3; - column-count: 3; - list-style-type: none; + -moz-column-gap: 1em; + -webkit-column-gap: 1em; + column-gap: 1em; + -moz-column-count: 3; + -webkit-column-count: 3; + column-count: 3; + list-style-type: none; } #side-nav ul { - overflow: visible; /* reset ul rule for scroll bar in GENERATE_TREEVIEW window */ + overflow: visible; /* reset ul rule for scroll bar in GENERATE_TREEVIEW window */ } #main-nav ul { - overflow: visible; /* reset ul rule for the navigation bar drop down lists */ + overflow: visible; /* reset ul rule for the navigation bar drop down lists */ } .fragment { - text-align: left; - direction: ltr; - overflow-x: auto; - overflow-y: hidden; - position: relative; - min-height: 12px; - margin: 10px 0px; - padding: 10px 10px; - border: 1px solid var(--fragment-border-color); - border-radius: 4px; - background-color: var(--fragment-background-color); - color: var(--fragment-foreground-color); + text-align: left; + direction: ltr; + overflow-x: auto; + overflow-y: hidden; + position: relative; + min-height: 12px; + margin: 10px 0px; + padding: 10px 10px; + border: 1px solid var(--fragment-border-color); + border-radius: 4px; + background-color: var(--fragment-background-color); + color: var(--fragment-foreground-color); } pre.fragment { - word-wrap: break-word; - font-size: 10pt; - line-height: 125%; - font-family: var(--font-family-monospace); + word-wrap: break-word; + font-size: 10pt; + line-height: 125%; + font-family: var(--font-family-monospace); +} + +span.tt { + white-space: pre; + font-family: var(--font-family-monospace); } .clipboard { - width: 24px; - height: 24px; - right: 5px; - top: 5px; - opacity: 0; - position: absolute; - display: inline; - overflow: auto; - fill: var(--fragment-foreground-color); - justify-content: center; - align-items: center; - cursor: pointer; + width: 24px; + height: 24px; + right: 5px; + top: 5px; + opacity: 0; + position: absolute; + display: inline; + overflow: hidden; + justify-content: center; + align-items: center; + cursor: pointer; } .clipboard.success { - border: 1px solid var(--fragment-foreground-color); - border-radius: 4px; + border: 1px solid var(--fragment-foreground-color); + border-radius: 4px; } .fragment:hover .clipboard, .clipboard.success { - opacity: .28; + opacity: .4; } .clipboard:hover, .clipboard.success { - opacity: 1 !important; + opacity: 1 !important; } .clipboard:active:not([class~=success]) svg { - transform: scale(.91); + transform: scale(.91); } .clipboard.success svg { - fill: var(--fragment-copy-ok-color); + fill: var(--fragment-copy-ok-color); } .clipboard.success { - border-color: var(--fragment-copy-ok-color); + border-color: var(--fragment-copy-ok-color); } div.line { font-family: var(--font-family-monospace); - font-size: 13px; + font-size: 13px; min-height: 13px; line-height: 1.2; - text-wrap: unrestricted; + text-wrap: wrap; + word-break: break-all; white-space: -moz-pre-wrap; /* Moz */ white-space: -pre-wrap; /* Opera 4-6 */ white-space: -o-pre-wrap; /* Opera 7 */ white-space: pre-wrap; /* CSS3 */ word-wrap: break-word; /* IE 5.5+ */ - text-indent: -53px; - padding-left: 53px; + text-indent: -62px; + padding-left: 62px; padding-bottom: 0px; margin: 0px; -webkit-transition-property: background-color, box-shadow; @@ -767,8 +812,8 @@ div.line { } div.line:after { - content:"\000A"; - white-space: pre; + content:"\000A"; + white-space: pre; } div.line.glow { @@ -777,26 +822,67 @@ div.line.glow { } span.fold { - margin-left: 5px; - margin-right: 1px; - margin-top: 0px; - margin-bottom: 0px; - padding: 0px; display: inline-block; width: 12px; height: 12px; - background-repeat:no-repeat; - background-position:center; + margin-left: 4px; + margin-right: 1px; +} + +span.foldnone { + display: inline-block; + position: relative; + cursor: pointer; + user-select: none; +} + +span.fold.plus, span.fold.minus { + width: 10px; + height: 10px; + background-color: var(--fragment-background-color); + position: relative; + border: 1px solid var(--fold-line-color); + margin-right: 1px; +} + +span.fold.plus::before, span.fold.minus::before { + content: ''; + position: absolute; + background-color: var(--fold-line-color); +} + +span.fold.plus::before { + width: 2px; + height: 6px; + top: 2px; + left: 4px; +} + +span.fold.plus::after { + content: ''; + position: absolute; + width: 6px; + height: 2px; + top: 4px; + left: 2px; + background-color: var(--fold-line-color); +} + +span.fold.minus::before { + width: 6px; + height: 2px; + top: 4px; + left: 2px; } span.lineno { padding-right: 4px; - margin-right: 9px; + margin-right: 9px; text-align: right; border-right: 2px solid var(--fragment-lineno-border-color); color: var(--fragment-lineno-foreground-color); background-color: var(--fragment-lineno-background-color); - white-space: pre; + white-space: pre; } span.lineno a, span.lineno a:visited { color: var(--fragment-lineno-link-fg-color); @@ -818,18 +904,27 @@ span.lineno a:hover { } div.classindex ul { - list-style: none; - padding-left: 0; + list-style: none; + padding-left: 0; } div.classindex span.ai { - display: inline-block; + display: inline-block; } div.groupHeader { - margin-left: 16px; - margin-top: 12px; - font-weight: bold; + box-shadow: 13px 0 var(--page-background-color), + -13px 0 var(--page-background-color), + 13px 1px var(--group-header-separator-color), + -13px 1px var(--group-header-separator-color); + color: var(--group-header-color); + font-size: 110%; + font-weight: 500; + margin-left: 0px; + margin-top: 0em; + margin-bottom: 6px; + padding-top: 8px; + padding-bottom: 4px; } div.groupText { @@ -839,13 +934,13 @@ div.groupText { body { color: var(--page-foreground-color); - margin: 0; + margin: 0; } div.contents { margin-top: 10px; margin-left: 12px; - margin-right: 8px; + margin-right: 12px; } p.formulaDsp { @@ -865,9 +960,9 @@ img.formulaInl, img.inline { div.center { text-align: center; - margin-top: 0px; - margin-bottom: 0px; - padding: 0px; + margin-top: 0px; + margin-bottom: 0px; + padding: 0px; } div.center img { @@ -942,10 +1037,10 @@ span.vhdllogic { } blockquote { - background-color: var(--blockquote-background-color); - border-left: 2px solid var(--blockquote-border-color); - margin: 0 24px 0 4px; - padding: 0 12px 0 16px; + background-color: var(--blockquote-background-color); + border-left: 2px solid var(--blockquote-border-color); + margin: 0 24px 0 4px; + padding: 0 12px 0 16px; } /* @end */ @@ -967,9 +1062,14 @@ th.dirtab { } hr { - height: 0px; border: none; - border-top: 1px solid var(--separator-color); + margin-top: 16px; + margin-bottom: 16px; + height: 1px; + box-shadow: 13px 0 var(--page-background-color), + -13px 0 var(--page-background-color), + 13px 1px var(--group-header-separator-color), + -13px 1px var(--group-header-separator-color); } hr.footer { @@ -984,14 +1084,6 @@ table.memberdecls { } .memberdecls td, .fieldtable tr { - -webkit-transition-property: background-color, box-shadow; - -webkit-transition-duration: 0.5s; - -moz-transition-property: background-color, box-shadow; - -moz-transition-duration: 0.5s; - -ms-transition-property: background-color, box-shadow; - -ms-transition-duration: 0.5s; - -o-transition-property: background-color, box-shadow; - -o-transition-duration: 0.5s; transition-property: background-color, box-shadow; transition-duration: 0.5s; } @@ -1001,13 +1093,23 @@ table.memberdecls { box-shadow: 0 0 15px var(--glow-color); } +.memberdecls tr[class^='memitem'] { + font-family: var(--font-family-monospace); +} + .mdescLeft, .mdescRight, -.memItemLeft, .memItemRight, -.memTemplItemLeft, .memTemplItemRight, .memTemplParams { +.memItemLeft, .memItemRight { + padding-top: 2px; + padding-bottom: 2px; +} + +.memTemplParams { + padding-left: 10px; + padding-top: 5px; +} + +.memItemLeft, .memItemRight, .memTemplParams { background-color: var(--memdecl-background-color); - border: none; - margin: 4px; - padding: 1px 0 0 8px; } .mdescLeft, .mdescRight { @@ -1015,27 +1117,104 @@ table.memberdecls { color: var(--memdecl-foreground-color); } -.memSeparator { - border-bottom: 1px solid var(--memdecl-separator-color); - line-height: 1px; - margin: 0px; - padding: 0px; +tr[class^='memdesc'] { + box-shadow: inset 0px 1px 3px 0px rgba(0,0,0,.075); } -.memItemLeft, .memTemplItemLeft { - white-space: nowrap; +.mdescLeft { + border-left: 1px solid var(--memdecl-border-color); + border-bottom: 1px solid var(--memdecl-border-color); } -.memItemRight, .memTemplItemRight { - width: 100%; +.mdescRight { + border-right: 1px solid var(--memdecl-border-color); + border-bottom: 1px solid var(--memdecl-border-color); } .memTemplParams { color: var(--memdecl-template-color); - white-space: nowrap; + white-space: nowrap; font-size: 80%; + border-left: 1px solid var(--memdecl-border-color); + border-right: 1px solid var(--memdecl-border-color); } +td.ititle { + border: 1px solid var(--memdecl-border-color); + border-top-left-radius: 4px; + border-top-right-radius: 4px; + padding-left: 10px; +} + +tr:not(:first-child) > td.ititle { + border-top: 0; + border-radius: 0; +} + +.memItemLeft { + white-space: nowrap; + border-left: 1px solid var(--memdecl-border-color); + border-bottom: 1px solid var(--memdecl-border-color); + padding-left: 10px; + transition: none; +} + +.memItemRight { + width: 100%; + border-right: 1px solid var(--memdecl-border-color); + border-bottom: 1px solid var(--memdecl-border-color); + padding-right: 10px; + transition: none; +} + +tr.heading + tr[class^='memitem'] td.memItemLeft, +tr.groupHeader + tr[class^='memitem'] td.memItemLeft, +tr.inherit_header + tr[class^='memitem'] td.memItemLeft { + border-top: 1px solid var(--memdecl-border-color); + border-top-left-radius: 4px; +} + +tr.heading + tr[class^='memitem'] td.memItemRight, +tr.groupHeader + tr[class^='memitem'] td.memItemRight, +tr.inherit_header + tr[class^='memitem'] td.memItemRight { + border-top: 1px solid var(--memdecl-border-color); + border-top-right-radius: 4px; +} + +tr.heading + tr[class^='memitem'] td.memTemplParams, +tr.heading + tr td.ititle, +tr.groupHeader + tr[class^='memitem'] td.memTemplParams, +tr.groupHeader + tr td.ititle, +tr.inherit_header + tr[class^='memitem'] td.memTemplParams { + border-top: 1px solid var(--memdecl-border-color); + border-top-left-radius: 4px; + border-top-right-radius: 4px; +} + +table.memberdecls tr:last-child td.memItemLeft, +table.memberdecls tr:last-child td.mdescLeft, +table.memberdecls tr[class^='memitem']:has(+ tr.groupHeader) td.memItemLeft, +table.memberdecls tr[class^='memitem']:has(+ tr.inherit_header) td.memItemLeft, +table.memberdecls tr[class^='memdesc']:has(+ tr.groupHeader) td.mdescLeft, +table.memberdecls tr[class^='memdesc']:has(+ tr.inherit_header) td.mdescLeft { + border-bottom-left-radius: 4px; +} + +table.memberdecls tr:last-child td.memItemRight, +table.memberdecls tr:last-child td.mdescRight, +table.memberdecls tr[class^='memitem']:has(+ tr.groupHeader) td.memItemRight, +table.memberdecls tr[class^='memitem']:has(+ tr.inherit_header) td.memItemRight, +table.memberdecls tr[class^='memdesc']:has(+ tr.groupHeader) td.mdescRight, +table.memberdecls tr[class^='memdesc']:has(+ tr.inherit_header) td.mdescRight { + border-bottom-right-radius: 4px; +} + +tr.template .memItemLeft, tr.template .memItemRight { + border-top: none; + padding-top: 0; +} + + /* @end */ /* @group Member Details */ @@ -1050,24 +1229,43 @@ table.memberdecls { border-top-right-radius: 4px; border-top-left-radius: 4px; margin-bottom: -1px; - background-image: var(--memdef-title-gradient-image); - background-repeat: repeat-x; - background-color: var(--memdef-title-background-color); + background-color: var(--memdef-proto-background-color); line-height: 1.25; - font-weight: 300; + font-family: var(--font-family-monospace); + font-weight: 500; + font-size: 16px; float:left; + box-shadow: 0 10px 0 -1px var(--memdef-proto-background-color), + 0 2px 8px 0 rgba(0,0,0,.075); + position: relative; +} + +.memtitle:after { + content: ''; + display: block; + background: var(--memdef-proto-background-color); + height: 10px; + bottom: -10px; + left: 0px; + right: -14px; + position: absolute; + border-top-right-radius: 6px; } .permalink { - font-size: 65%; - display: inline-block; - vertical-align: middle; + font-family: var(--font-family-monospace); + font-weight: 500; + line-height: 1.25; + font-size: 16px; + display: inline-block; + vertical-align: middle; } .memtemplate { font-size: 80%; color: var(--memdef-template-color); + font-family: var(--font-family-monospace); font-weight: normal; margin-left: 9px; } @@ -1080,22 +1278,21 @@ table.memberdecls { padding: 0; margin-bottom: 10px; margin-right: 5px; - -webkit-transition: box-shadow 0.5s linear; - -moz-transition: box-shadow 0.5s linear; - -ms-transition: box-shadow 0.5s linear; - -o-transition: box-shadow 0.5s linear; - transition: box-shadow 0.5s linear; - display: table !important; - width: 100%; + display: table !important; + width: 100%; + box-shadow: 0 2px 8px 0 rgba(0,0,0,.075); + border-radius: 4px; } .memitem.glow { - box-shadow: 0 0 15px var(--glow-color); + box-shadow: 0 0 15px var(--glow-color); } .memname { - font-weight: 400; - margin-left: 6px; + font-family: var(--font-family-monospace); + font-size: 13px; + font-weight: 400; + margin-left: 6px; } .memname td { @@ -1103,53 +1300,39 @@ table.memberdecls { } .memproto, dl.reflist dt { - border-top: 1px solid var(--memdef-border-color); - border-left: 1px solid var(--memdef-border-color); - border-right: 1px solid var(--memdef-border-color); - padding: 6px 0px 6px 0px; - color: var(--memdef-proto-text-color); - font-weight: bold; - text-shadow: var(--memdef-proto-text-shadow); - background-color: var(--memdef-proto-background-color); - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - border-top-right-radius: 4px; + border-top: 1px solid var(--memdef-border-color); + border-left: 1px solid var(--memdef-border-color); + border-right: 1px solid var(--memdef-border-color); + padding: 6px 0px 6px 0px; + color: var(--memdef-proto-text-color); + font-weight: bold; + background-color: var(--memdef-proto-background-color); + border-top-right-radius: 4px; + border-bottom: 1px solid var(--memdef-border-color); } .overload { - font-family: var(--font-family-monospace); + font-family: var(--font-family-monospace); font-size: 65%; } .memdoc, dl.reflist dd { - border-bottom: 1px solid var(--memdef-border-color); - border-left: 1px solid var(--memdef-border-color); - border-right: 1px solid var(--memdef-border-color); - padding: 6px 10px 2px 10px; - border-top-width: 0; - background-image:url('nav_g.png'); - background-repeat:repeat-x; - background-color: var(--memdef-doc-background-color); - /* opera specific markup */ - border-bottom-left-radius: 4px; - border-bottom-right-radius: 4px; - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - /* firefox specific markup */ - -moz-border-radius-bottomleft: 4px; - -moz-border-radius-bottomright: 4px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - /* webkit specific markup */ - -webkit-border-bottom-left-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + border-bottom: 1px solid var(--memdef-border-color); + border-left: 1px solid var(--memdef-border-color); + border-right: 1px solid var(--memdef-border-color); + padding: 6px 10px 2px 10px; + border-top-width: 0; + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; } dl.reflist dt { - padding: 5px; + padding: 5px; } dl.reflist dd { - margin: 0px 0px 10px 0px; - padding: 5px; + margin: 0px 0px 10px 0px; + padding: 5px; } .paramkey { @@ -1164,9 +1347,9 @@ dl.reflist dd { .paramname { white-space: nowrap; - padding: 0px; - padding-bottom: 1px; - margin-left: 2px; + padding: 0px; + padding-bottom: 1px; + margin-left: 2px; } .paramname em { @@ -1180,23 +1363,23 @@ dl.reflist dd { } .params, .retval, .exception, .tparams { - margin-left: 0px; - padding-left: 0px; + margin-left: 0px; + padding-left: 0px; } .params .paramname, .retval .paramname, .tparams .paramname, .exception .paramname { - font-weight: bold; - vertical-align: top; + font-weight: bold; + vertical-align: top; } .params .paramtype, .tparams .paramtype { - font-style: italic; - vertical-align: top; + font-style: italic; + vertical-align: top; } .params .paramdir, .tparams .paramdir { - font-family: var(--font-family-monospace); - vertical-align: top; + font-family: var(--font-family-monospace); + vertical-align: top; } table.mlabels { @@ -1215,15 +1398,15 @@ td.mlabels-right { } span.mlabels { - margin-left: 8px; + margin-left: 8px; } span.mlabel { - background-color: var(--label-background-color); - border-top:1px solid var(--label-left-top-border-color); - border-left:1px solid var(--label-left-top-border-color); - border-right:1px solid var(--label-right-bottom-border-color); - border-bottom:1px solid var(--label-right-bottom-border-color); + background-color: var(--label-background-color); + border-top:1px solid var(--label-left-top-border-color); + border-left:1px solid var(--label-left-top-border-color); + border-right:1px solid var(--label-right-bottom-border-color); + border-bottom:1px solid var(--label-right-bottom-border-color); text-shadow: none; color: var(--label-foreground-color); margin-right: 4px; @@ -1241,39 +1424,37 @@ span.mlabel { /* these are for tree view inside a (index) page */ div.directory { - margin: 10px 0px; - border-top: 1px solid var(--directory-separator-color); - border-bottom: 1px solid var(--directory-separator-color); - width: 100%; + margin: 10px 0px; + width: 100%; } .directory table { - border-collapse:collapse; + border-collapse:collapse; } .directory td { - margin: 0px; - padding: 0px; + margin: 0px; + padding: 0px; vertical-align: top; } .directory td.entry { - white-space: nowrap; - padding-right: 6px; + white-space: nowrap; + padding-right: 6px; padding-top: 3px; } .directory td.entry a { - outline:none; + outline:none; } .directory td.entry a img { - border: none; + border: none; } .directory td.desc { - width: 100%; - padding-left: 6px; + width: 100%; + padding-left: 6px; padding-right: 6px; padding-top: 3px; border-left: 1px solid rgba(0,0,0,0.05); @@ -1294,90 +1475,178 @@ div.directory { } .directory .levels { - white-space: nowrap; - width: 100%; - text-align: right; - font-size: 9pt; + white-space: nowrap; + width: 100%; + text-align: right; + font-size: 9pt; } .directory .levels span { - cursor: pointer; - padding-left: 2px; - padding-right: 2px; + cursor: pointer; + padding-left: 2px; + padding-right: 2px; color: var(--page-link-color); } .arrow { - color: var(--nav-arrow-color); - -webkit-user-select: none; - -khtml-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; - cursor: pointer; - font-size: 80%; - display: inline-block; - width: 16px; - height: 22px; + color: var(--nav-background-color); + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + cursor: pointer; + font-size: 80%; + display: inline-block; + width: 16px; + height: 14px; + transition: opacity 0.3s ease; +} + +span.arrowhead { + position: relative; + padding: 0; + margin: 0 0 0 2px; + display: inline-block; + width: 5px; + height: 5px; + border-right: 2px solid var(--nav-arrow-color); + border-bottom: 2px solid var(--nav-arrow-color); + transform: rotate(-45deg); + transition: transform 0.3s ease; +} + +span.arrowhead.opened { + transform: rotate(45deg); +} + +.selected span.arrowhead { + border-right: 2px solid var(--nav-arrow-selected-color); + border-bottom: 2px solid var(--nav-arrow-selected-color); } .icon { - font-family: var(--font-family-icon); - line-height: normal; - font-weight: bold; - font-size: 12px; - height: 14px; - width: 16px; - display: inline-block; - background-color: var(--icon-background-color); - color: var(--icon-foreground-color); - text-align: center; - border-radius: 4px; - margin-left: 2px; - margin-right: 2px; + font-family: var(--font-family-icon); + line-height: normal; + font-weight: bold; + font-size: 12px; + height: 14px; + width: 16px; + display: inline-block; + background-color: var(--icon-background-color); + color: var(--icon-foreground-color); + text-align: center; + border-radius: 4px; + margin-left: 2px; + margin-right: 2px; } .icona { - width: 24px; - height: 22px; - display: inline-block; + width: 24px; + height: 22px; + display: inline-block; } -.iconfopen { - width: 24px; - height: 18px; - margin-bottom: 4px; - background-image:var(--icon-folder-open-image); - background-repeat: repeat-y; - vertical-align:top; - display: inline-block; -} - -.iconfclosed { - width: 24px; - height: 18px; - margin-bottom: 4px; - background-image:var(--icon-folder-closed-image); - background-repeat: repeat-y; - vertical-align:top; - display: inline-block; +.iconfolder { + width: 24px; + height: 18px; + margin-top: 6px; + vertical-align:top; + display: inline-block; + position: relative; } .icondoc { - width: 24px; - height: 18px; - margin-bottom: 4px; - background-image:var(--icon-doc-image); - background-position: 0px -4px; - background-repeat: repeat-y; - vertical-align:top; - display: inline-block; + width: 24px; + height: 18px; + margin-top: 3px; + vertical-align:top; + display: inline-block; + position: relative; } +.folder-icon { + width: 16px; + height: 11px; + background-color: var(--icon-folder-fill-color); + border: 1px solid var(--icon-folder-border-color); + border-radius: 0 2px 2px 2px; + position: relative; + box-sizing: content-box; +} + +.folder-icon::after { + content: ''; + position: absolute; + top: 2px; + left: -1px; + width: 16px; + height: 7px; + background-color: var(--icon-folder-open-fill-color); + border: 1px solid var(--icon-folder-border-color); + border-radius: 7px 7px 2px 2px; + transform-origin: top left; + opacity: 0; + transition: all 0.3s linear; +} + +.folder-icon::before { + content: ''; + position: absolute; + top: -3px; + left: -1px; + width: 6px; + height: 2px; + background-color: var(--icon-folder-fill-color); + border-top: 1px solid var(--icon-folder-border-color); + border-left: 1px solid var(--icon-folder-border-color); + border-right: 1px solid var(--icon-folder-border-color); + border-radius: 2px 2px 0 0; +} + +.folder-icon.open::after { + top: 3px; + opacity: 1; +} + +.doc-icon { + left: 6px; + width: 12px; + height: 16px; + background-color: var(--icon-doc-border-color); + clip-path: polygon(0 0, 66% 0, 100% 25%, 100% 100%, 0 100%); + position: relative; + display: inline-block; +} +.doc-icon::before { + content: ""; + left: 1px; + top: 1px; + width: 10px; + height: 14px; + background-color: var(--icon-doc-fill-color); + clip-path: polygon(0 0, 66% 0, 100% 25%, 100% 100%, 0 100%); + position: absolute; + box-sizing: border-box; +} +.doc-icon::after { + content: ""; + left: 7px; + top: 0px; + width: 3px; + height: 3px; + background-color: transparent; + position: absolute; + border: 1px solid var(--icon-doc-border-color); +} + + + + /* @end */ div.dynheader { - margin-top: 8px; + margin-top: 8px; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; @@ -1386,6 +1655,13 @@ div.dynheader { user-select: none; } +span.dynarrow { + position: relative; + display: inline-block; + width: 12px; + bottom: 1px; +} + address { font-style: normal; color: var(--footer-foreground-color); @@ -1397,8 +1673,8 @@ table.doxtable caption { table.doxtable { border-collapse:collapse; - margin-top: 4px; - margin-bottom: 4px; + margin-top: 4px; + margin-bottom: 4px; } table.doxtable td, table.doxtable th { @@ -1415,127 +1691,145 @@ table.doxtable th { } table.fieldtable { - margin-bottom: 10px; - border: 1px solid var(--memdef-border-color); - border-spacing: 0px; - border-radius: 4px; - box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); + margin-bottom: 10px; + border: 1px solid var(--memdef-border-color); + border-spacing: 0px; + border-radius: 4px; + box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); } .fieldtable td, .fieldtable th { - padding: 3px 7px 2px; + padding: 3px 7px 2px; } -.fieldtable td.fieldtype, .fieldtable td.fieldname { - white-space: nowrap; - border-right: 1px solid var(--memdef-border-color); - border-bottom: 1px solid var(--memdef-border-color); - vertical-align: top; +.fieldtable td.fieldtype, .fieldtable td.fieldname, .fieldtable td.fieldinit { + white-space: nowrap; + border-right: 1px solid var(--memdef-border-color); + border-bottom: 1px solid var(--memdef-border-color); + vertical-align: top; } .fieldtable td.fieldname { - padding-top: 3px; + padding-top: 3px; } +.fieldtable td.fieldinit { + padding-top: 3px; + text-align: right; +} + + .fieldtable td.fielddoc { - border-bottom: 1px solid var(--memdef-border-color); + border-bottom: 1px solid var(--memdef-border-color); } .fieldtable td.fielddoc p:first-child { - margin-top: 0px; + margin-top: 0px; } .fieldtable td.fielddoc p:last-child { - margin-bottom: 2px; + margin-bottom: 2px; } .fieldtable tr:last-child td { - border-bottom: none; + border-bottom: none; } .fieldtable th { - background-image: var(--memdef-title-gradient-image); - background-repeat:repeat-x; - background-color: var(--memdef-title-background-color); - font-size: 90%; - color: var(--memdef-proto-text-color); - padding-bottom: 4px; - padding-top: 5px; - text-align:left; - font-weight: 400; - border-top-left-radius: 4px; - border-top-right-radius: 4px; - border-bottom: 1px solid var(--memdef-border-color); + background-color: var(--memdef-title-background-color); + font-size: 90%; + color: var(--memdef-proto-text-color); + padding-bottom: 4px; + padding-top: 5px; + text-align:left; + font-weight: 400; + border-top-left-radius: 4px; + border-top-right-radius: 4px; + border-bottom: 1px solid var(--memdef-border-color); } +/* ----------- navigation breadcrumb styling ----------- */ -.tabsearch { - top: 0px; - left: 10px; - height: 36px; - background-image: var(--nav-gradient-image); - z-index: 101; +#nav-path ul { + height: 30px; + line-height: 30px; + color: var(--nav-text-normal-color); overflow: hidden; - font-size: 13px; + margin: 0px; + padding-left: 4px; + background-image: none; + background: var(--page-background-color); + border-bottom: 1px solid var(--nav-breadcrumb-separator-color); + font-size: var(--nav-font-size-level1); + font-family: var(--font-family-nav); + position: relative; + z-index: 100; } -.navpath ul -{ - font-size: 11px; - background-image: var(--nav-gradient-image); - background-repeat:repeat-x; - background-position: 0 -5px; - height:30px; - line-height:30px; - color:var(--nav-text-normal-color); - border:solid 1px var(--nav-breadcrumb-border-color); - overflow:hidden; - margin:0px; - padding:0px; +#main-nav { + border-bottom: 1px solid var(--nav-border-color); } -.navpath li -{ +.navpath li { list-style-type:none; float:left; - padding-left:10px; - padding-right:15px; - background-image:var(--nav-breadcrumb-image); - background-repeat:no-repeat; - background-position:right; color: var(--nav-foreground-color); } -.navpath li.navelem a -{ - height:32px; - display:block; - outline: none; - color: var(--nav-text-normal-color); - font-family: var(--font-family-nav); - text-shadow: var(--nav-text-normal-shadow); - text-decoration: none; +.navpath li.footer { + list-style-type:none; + float:right; + padding-left:10px; + padding-right:15px; + background-image:none; + background-repeat:no-repeat; + background-position:right; + font-size: 8pt; + color: var(--footer-foreground-color); } -.navpath li.navelem a:hover -{ - color: var(--nav-text-hover-color); - text-shadow: var(--nav-text-hover-shadow); +#nav-path li.navelem { + background-image: none; + display: flex; + align-items: center; + padding-left: 15px; } -.navpath li.footer -{ - list-style-type:none; - float:right; - padding-left:10px; - padding-right:15px; - background-image:none; - background-repeat:no-repeat; - background-position:right; - color: var(--footer-foreground-color); - font-size: 8pt; +.navpath li.navelem a { + text-shadow: none; + display: inline-block; + color: var(--nav-breadcrumb-color); + position: relative; + top: 0px; + height: 30px; + margin-right: -20px; } +#nav-path li.navelem:after { + content: ''; + display: inline-block; + position: relative; + top: 0; + right: -15px; + width: 30px; + height: 30px; + transform: scaleX(0.5) scale(0.707) rotate(45deg); + z-index: 10; + background: var(--page-background-color); + box-shadow: 2px -2px 0 2px var(--nav-breadcrumb-separator-color); + border-radius: 0 5px 0 50px; +} + +#nav-path li.navelem:first-child { + margin-left: -6px; +} + +#nav-path li.navelem:hover, +#nav-path li.navelem:hover:after { + background-color: var(--nav-breadcrumb-active-bg); +} + +/* ---------------------- */ div.summary { @@ -1553,14 +1847,14 @@ div.summary a table.classindex { - margin: 10px; - white-space: nowrap; - margin-left: 3%; - margin-right: 3%; - width: 94%; - border: 0; - border-spacing: 0; - padding: 0; + margin: 10px; + white-space: nowrap; + margin-left: 3%; + margin-right: 3%; + width: 94%; + border: 0; + border-spacing: 0; + padding: 0; } div.ingroups @@ -1577,10 +1871,8 @@ div.ingroups a div.header { - background-image: var(--header-gradient-image); - background-repeat:repeat-x; - background-color: var(--header-background-color); margin: 0px; + background-color: var(--header-background-color); border-bottom: 1px solid var(--header-separator-color); } @@ -1589,166 +1881,105 @@ div.headertitle padding: 5px 5px 5px 10px; } -.PageDocRTL-title div.headertitle { - text-align: right; - direction: rtl; -} - dl { - padding: 0 0 0 0; + padding: 0 0 0 0; } -/* - -dl.section { - margin-left: 0px; - padding-left: 0px; -} - -dl.note { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #D0C000; -} - -dl.warning, dl.attention { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #FF0000; -} - -dl.pre, dl.post, dl.invariant { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #00D000; -} - -dl.deprecated { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #505050; -} - -dl.todo { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #00C0E0; -} - -dl.test { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #3030E0; -} - -dl.bug { - margin-left: -7px; - padding-left: 3px; - border-left: 4px solid; - border-color: #C08050; -} - -*/ - dl.bug dt a, dl.deprecated dt a, dl.todo dt a, dl.test a { - font-weight: bold !important; + font-weight: bold !important; } -dl.warning, dl.attention, dl.note, dl.deprecated, dl.bug, +dl.warning, dl.attention, dl.important, dl.note, dl.deprecated, dl.bug, dl.invariant, dl.pre, dl.post, dl.todo, dl.test, dl.remark { - padding: 10px; - margin: 10px 0px; - overflow: hidden; - margin-left: 0; - border-radius: 4px; + padding: 10px; + margin: 10px 0px; + overflow: hidden; + margin-left: 0; + border-radius: 4px; } dl.section dd { - margin-bottom: 2px; + margin-bottom: 2px; } -dl.warning, dl.attention { - background: var(--warning-color-bg); - border-left: 8px solid var(--warning-color-hl); - color: var(--warning-color-text); +dl.warning, dl.attention, dl.important { + background: var(--warning-color-bg); + border-left: 8px solid var(--warning-color-hl); + color: var(--warning-color-text); } -dl.warning dt, dl.attention dt { - color: var(--warning-color-hl); +dl.warning dt, dl.attention dt, dl.important dt { + color: var(--warning-color-hl); } dl.note, dl.remark { - background: var(--note-color-bg); - border-left: 8px solid var(--note-color-hl); - color: var(--note-color-text); + background: var(--note-color-bg); + border-left: 8px solid var(--note-color-hl); + color: var(--note-color-text); } dl.note dt, dl.remark dt { - color: var(--note-color-hl); + color: var(--note-color-hl); } dl.todo { - background: var(--todo-color-bg); - border-left: 8px solid var(--todo-color-hl); - color: var(--todo-color-text); + background: var(--todo-color-bg); + border-left: 8px solid var(--todo-color-hl); + color: var(--todo-color-text); } dl.todo dt { - color: var(--todo-color-hl); + color: var(--todo-color-hl); } dl.test { - background: var(--test-color-bg); - border-left: 8px solid var(--test-color-hl); - color: var(--test-color-text); + background: var(--test-color-bg); + border-left: 8px solid var(--test-color-hl); + color: var(--test-color-text); } dl.test dt { - color: var(--test-color-hl); + color: var(--test-color-hl); } dl.bug dt a { - color: var(--bug-color-hl) !important; + color: var(--bug-color-hl) !important; } dl.bug { - background: var(--bug-color-bg); - border-left: 8px solid var(--bug-color-hl); - color: var(--bug-color-text); + background: var(--bug-color-bg); + border-left: 8px solid var(--bug-color-hl); + color: var(--bug-color-text); } dl.bug dt a { - color: var(--bug-color-hl) !important; + color: var(--bug-color-hl) !important; } dl.deprecated { - background: var(--deprecated-color-bg); - border-left: 8px solid var(--deprecated-color-hl); - color: var(--deprecated-color-text); + background: var(--deprecated-color-bg); + border-left: 8px solid var(--deprecated-color-hl); + color: var(--deprecated-color-text); } dl.deprecated dt a { - color: var(--deprecated-color-hl) !important; + color: var(--deprecated-color-hl) !important; } -dl.section dd, dl.bug dd, dl.deprecated dd, dl.todo dd, dl.test dd { - margin-inline-start: 0px; +dl.note dd, dl.warning dd, dl.pre dd, dl.post dd, +dl.remark dd, dl.attention dd, dl.important dd, dl.invariant dd, +dl.bug dd, dl.deprecated dd, dl.todo dd, dl.test dd { + margin-inline-start: 0px; } dl.invariant, dl.pre, dl.post { - background: var(--invariant-color-bg); - border-left: 8px solid var(--invariant-color-hl); - color: var(--invariant-color-text); + background: var(--invariant-color-bg); + border-left: 8px solid var(--invariant-color-hl); + color: var(--invariant-color-text); } dl.invariant dt, dl.pre dt, dl.post dt { - color: var(--invariant-color-hl); + color: var(--invariant-color-hl); } @@ -1771,22 +2002,27 @@ dl.invariant dt, dl.pre dt, dl.post dt { #projectalign { - vertical-align: middle; - padding-left: 0.5em; + vertical-align: middle; + padding-left: 0.5em; } #projectname { font-size: 200%; font-family: var(--font-family-title); - margin: 0px; - padding: 2px 0px; + margin: 0; + padding: 0; +} + +#side-nav #projectname +{ + font-size: 130%; } #projectbrief { font-size: 90%; - font-family: var(--font-family-title); + font-family: var(--font-family-title); margin: 0px; padding: 0px; } @@ -1794,43 +2030,42 @@ dl.invariant dt, dl.pre dt, dl.post dt { #projectnumber { font-size: 50%; - font-family: 50% var(--font-family-title); + font-family: var(--font-family-title); margin: 0px; padding: 0px; } #titlearea { - padding: 0px; + padding: 0 0 0 5px; margin: 0px; - width: 100%; border-bottom: 1px solid var(--title-separator-color); background-color: var(--title-background-color); } .image { - text-align: center; + text-align: center; } .dotgraph { - text-align: center; + text-align: center; } .mscgraph { - text-align: center; + text-align: center; } .plantumlgraph { - text-align: center; + text-align: center; } .diagraph { - text-align: center; + text-align: center; } .caption @@ -1839,70 +2074,67 @@ dl.invariant dt, dl.pre dt, dl.post dt { } dl.citelist { - margin-bottom:50px; + margin-bottom:50px; } dl.citelist dt { - color:var(--citation-label-color); - float:left; - font-weight:bold; - margin-right:10px; - padding:5px; - text-align:right; - width:52px; + color:var(--citation-label-color); + float:left; + font-weight:bold; + margin-right:10px; + padding:5px; + text-align:right; + width:52px; } dl.citelist dd { - margin:2px 0 2px 72px; - padding:5px 0; + margin:2px 0 2px 72px; + padding:5px 0; } div.toc { - padding: 14px 25px; - background-color: var(--toc-background-color); - border: 1px solid var(--toc-border-color); - border-radius: 7px 7px 7px 7px; - float: right; - height: auto; - margin: 0 8px 10px 10px; - width: 200px; + padding: 14px 25px; + background-color: var(--toc-background-color); + border: 1px solid var(--toc-border-color); + border-radius: 7px 7px 7px 7px; + float: right; + height: auto; + margin: 0 8px 10px 10px; + width: 200px; } div.toc li { - background: var(--toc-down-arrow-image) no-repeat scroll 0 5px transparent; - font: 10px/1.2 var(--font-family-toc); - margin-top: 5px; - padding-left: 10px; - padding-top: 2px; + background: var(--toc-down-arrow-image) no-repeat scroll 0 5px transparent; + font: 10px/1.2 var(--font-family-toc); + margin-top: 5px; + padding-left: 10px; + padding-top: 2px; } div.toc h3 { - font: bold 12px/1.2 var(--font-family-toc); + font: bold 12px/1.2 var(--font-family-toc); color: var(--toc-header-color); - border-bottom: 0 none; - margin: 0; + border-bottom: 0 none; + margin: 0; } div.toc ul { - list-style: none outside none; - border: medium none; - padding: 0px; + list-style: none outside none; + border: medium none; + padding: 0px; +} + +div.toc li[class^='level'] { + margin-left: 15px; } div.toc li.level1 { - margin-left: 0px; + margin-left: 0px; } -div.toc li.level2 { - margin-left: 15px; -} - -div.toc li.level3 { - margin-left: 15px; -} - -div.toc li.level4 { - margin-left: 15px; +div.toc li.empty { + background-image: none; + margin-top: 0px; } span.emoji { @@ -1912,13 +2144,12 @@ span.emoji { } span.obfuscator { - display: none; + display: none; } .inherit_header { - font-weight: bold; - color: var(--inherit-header-color); - cursor: pointer; + font-weight: 400; + cursor: pointer; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; @@ -1928,49 +2159,49 @@ span.obfuscator { } .inherit_header td { - padding: 6px 0px 2px 5px; + padding: 6px 0 2px 0; } .inherit { - display: none; + display: none; } tr.heading h2 { - margin-top: 12px; - margin-bottom: 4px; + margin-top: 12px; + margin-bottom: 12px; } /* tooltip related style info */ .ttc { - position: absolute; - display: none; + position: absolute; + display: none; } #powerTip { cursor: default; - /*white-space: nowrap;*/ - color: var(--tooltip-foreground-color); + color: var(--tooltip-foreground-color); background-color: var(--tooltip-background-color); + backdrop-filter: var(--tooltip-backdrop-filter); + -webkit-backdrop-filter: var(--tooltip-backdrop-filter); border: 1px solid var(--tooltip-border-color); - border-radius: 4px 4px 4px 4px; + border-radius: 4px; box-shadow: var(--tooltip-shadow); display: none; font-size: smaller; max-width: 80%; - opacity: 0.9; padding: 1ex 1em 1em; position: absolute; z-index: 2147483647; } #powerTip div.ttdoc { - color: var(--tooltip-doc-color); + color: var(--tooltip-doc-color); font-style: italic; } #powerTip div.ttname a { - font-weight: bold; + font-weight: bold; } #powerTip a { @@ -1978,18 +2209,18 @@ tr.heading h2 { } #powerTip div.ttname { - font-weight: bold; + font-weight: bold; } #powerTip div.ttdeci { - color: var(--tooltip-declaration-color); + color: var(--tooltip-declaration-color); } #powerTip div { - margin: 0px; - padding: 0px; - font-size: 12px; - font-family: var(--font-family-tooltip); + margin: 0px; + padding: 0px; + font-size: 12px; + font-family: var(--font-family-tooltip); line-height: 16px; } @@ -2035,7 +2266,7 @@ tr.heading h2 { } #powerTip.n:after, #powerTip.ne:after, #powerTip.nw:after { - border-top-color: var(--tooltip-background-color); + border-top-color: var(--tooltip-arrow-background-color); border-width: 10px; margin: 0px -10px; } @@ -2063,7 +2294,7 @@ tr.heading h2 { } #powerTip.s:after, #powerTip.se:after, #powerTip.sw:after { - border-bottom-color: var(--tooltip-background-color); + border-bottom-color: var(--tooltip-arrow-background-color); border-width: 10px; margin: 0px -10px; } @@ -2120,29 +2351,29 @@ tr.heading h2 { @media print { - #top { display: none; } - #side-nav { display: none; } - #nav-path { display: none; } - body { overflow:visible; } - h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } - .summary { display: none; } - .memitem { page-break-inside: avoid; } - #doc-content - { - margin-left:0 !important; - height:auto !important; - width:auto !important; - overflow:inherit; - display:inline; - } + #top { display: none; } + #side-nav { display: none; } + #nav-path { display: none; } + body { overflow:visible; } + h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } + .summary { display: none; } + .memitem { page-break-inside: avoid; } + #doc-content + { + margin-left:0 !important; + height:auto !important; + width:auto !important; + overflow:inherit; + display:inline; + } } /* @group Markdown */ table.markdownTable { border-collapse:collapse; - margin-top: 4px; - margin-bottom: 4px; + margin-top: 4px; + margin-bottom: 4px; } table.markdownTable td, table.markdownTable th { @@ -2173,9 +2404,13 @@ th.markdownTableHeadCenter, td.markdownTableBodyCenter { text-align: center } -tt, code, kbd, samp +tt, code, kbd { - display: inline-block; + display: inline-block; +} +tt, code, kbd +{ + vertical-align: top; } /* @end */ @@ -2184,26 +2419,27 @@ u { } details>summary { - list-style-type: none; + list-style-type: none; } details > summary::-webkit-details-marker { - display: none; + display: none; } details>summary::before { - content: "\25ba"; - padding-right:4px; - font-size: 80%; + content: "\25ba"; + padding-right:4px; + font-size: 80%; } details[open]>summary::before { - content: "\25bc"; - padding-right:4px; - font-size: 80%; + content: "\25bc"; + padding-right:4px; + font-size: 80%; } -body { +:root { + scrollbar-width: thin; scrollbar-color: var(--scrollbar-thumb-color) var(--scrollbar-background-color); } diff --git a/Doc/html/doxygen_crawl.html b/Doc/html/doxygen_crawl.html index 19a05df..ddd0271 100644 --- a/Doc/html/doxygen_crawl.html +++ b/Doc/html/doxygen_crawl.html @@ -4,169 +4,357 @@ Validator / crawler helper - + - - - - - - - - - - - - - - - - - + + + + + + + + + - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - + - - - + + + + + + + + + + + + + + + + + + + + + + + - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/Doc/html/dynsections.js b/Doc/html/dynsections.js index 24dfe9c..d89724e 100644 --- a/Doc/html/dynsections.js +++ b/Doc/html/dynsections.js @@ -23,8 +23,11 @@ @licend The above is the entire license notice for the JavaScript code in this file */ -let dynsection = { +function toggleVisibility(linkObj) { + return dynsection.toggleVisibility(linkObj); +} +let dynsection = { // helper function updateStripes : function() { $('table.directory tr'). @@ -40,15 +43,13 @@ let dynsection = { const trigger = $('#'+base+'-trigger'); const src=$(trigger).attr('src'); if (content.is(':visible')===true) { - content.hide(); + content.slideUp('fast'); summary.show(); - $(linkObj).addClass('closed').removeClass('opened'); - $(trigger).attr('src',src.substring(0,src.length-8)+'closed.png'); + $(linkObj).find('.arrowhead').addClass('closed').removeClass('opened'); } else { - content.show(); + content.slideDown('fast'); summary.hide(); - $(linkObj).removeClass('closed').addClass('opened'); - $(trigger).attr('src',src.substring(0,src.length-10)+'open.png'); + $(linkObj).find('.arrowhead').removeClass('closed').addClass('opened'); } return false; }, @@ -59,12 +60,12 @@ let dynsection = { const i = $('#img'+this.id.substring(3)); const a = $('#arr'+this.id.substring(3)); if (l'); + $('span[class=lineno]:first').append(''); // add vertical lines to other rows $('span[class=lineno]').not(':eq(0)').append(''); // add toggle controls to lines with fold divs @@ -169,9 +167,8 @@ let codefold = { const start = $(this).attr('data-start'); const end = $(this).attr('data-end'); // replace normal fold span with controls for the first line of a foldable fragment - $(this).find('span[class=fold]:first').replaceWith(''); + $(this).find('span[class=fold]:first').replaceWith(''); // append div for folded (closed) representation $(this).after(''); // extract the first line from the "open" section to represent closed content @@ -183,7 +180,7 @@ let codefold = { $(line).html($(line).html().replace(new RegExp('\\s*'+start+'\\s*$','g'),'')); } // replace minus with plus symbol - $(line).find('span[class=fold]').css('background-image',codefold.plusImg[relPath]); + $(line).find('span[class=fold]').addClass('plus').removeClass('minus'); // append ellipsis $(line).append(' '+start+''+end); // insert constructed line into closed div diff --git a/Doc/html/evolve__optimizer_8h.html b/Doc/html/evolve__optimizer_8h.html index 031520b..8b7d966 100644 --- a/Doc/html/evolve__optimizer_8h.html +++ b/Doc/html/evolve__optimizer_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/evolve_optimizer.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/evolve_optimizer.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
-
evolve_optimizer.h File Reference
@@ -113,88 +106,83 @@ $(function(){initNavTree('evolve__optimizer_8h.html',''); initResizable(); });
#include "mylibs_defs.h"
#include <stdint.h>
#include <stdlib.h>
-
- + Include dependency graph for evolve_optimizer.h:
+
Include dependency graph for evolve_optimizer.h:
-
- + This graph shows which files directly or indirectly include this file:
+
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

- - + -

+

Classes

struct  EvolveOptimizer_t
struct  EvolveOptimizer_t
 Структура эволюционного оптимизатора More...
 
- - + - - + - - - - - - -

+

Macros

#define PARAM_SCALE(x, min_val, max_val)   (((float)(x) - (float)(min_val)) / ((float)(max_val) - (float)(min_val)))
#define PARAM_SCALE(x, min_val, max_val)
 Линейное масштабирование x из диапазона [min_val, max_val] в диапазон [0, 1)
 
#define PARAM_UNSCALE(val, min_val, max_val)   (((float)(val)) * ((float)(max_val) - (float)(min_val)) + (float)(min_val))
#define PARAM_UNSCALE(val, min_val, max_val)
 Обратное линейное масштабирование значения из [0, 1) в диапазон [min_val, max_val].
 
#define local_time()   HAL_GetTick()
 Локальное время
 
#define EVOLVE_MUTATION_MIN_PCT   10
 Минимальная мутация (в процентах от Loss)
 
#define EVOLVE_MUTATION_MAX_PCT   100
 Максимальная мутация (в процентах от Loss)
 
#define ELOVLE_N_ELITE_CANDIDATE   2
 Количество кандидатов, которые проходят в поколение без изменений (по умолчанию 2)
 
- - -

+

Functions

__STATIC_INLINE int EvolveOptimizer_Init (EvolveOptimizer_t *opt, uint16_t n_params, uint16_t n_cand, uint16_t n_best, float mutation_amp, float *start_params)
 Инициализация эволюционного оптимизатора.
 
__STATIC_INLINE int EvolveOptimizer_Step (EvolveOptimizer_t *opt, float *params, float loss)
 Один шаг эволюционного оптимизатора.
 
-

Detailed Description

+

Detailed Description

Заголовочный файл для адаптивного подбора параметров

Definition in file evolve_optimizer.h.

+ +
diff --git a/Doc/html/evolve__optimizer_8h.js b/Doc/html/evolve__optimizer_8h.js index 4382494..31f5538 100644 --- a/Doc/html/evolve__optimizer_8h.js +++ b/Doc/html/evolve__optimizer_8h.js @@ -2,7 +2,6 @@ var evolve__optimizer_8h = [ [ "PARAM_SCALE", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga83abbcabaff9111c03ae2475ee72ea3e", null ], [ "PARAM_UNSCALE", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#gaa1d5510fe5f0bd989473f3ebe324bde3", null ], - [ "local_time", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga9c853b02c22f26023c34d1d404b6d653", null ], [ "EVOLVE_MUTATION_MIN_PCT", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga2f2b1be34ad4eb1bf3267237200cd6c6", null ], [ "EVOLVE_MUTATION_MAX_PCT", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga861c1c6a503c21441abcec0d57b848bc", null ], [ "ELOVLE_N_ELITE_CANDIDATE", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga38607e23d9234524bc7de5869b15b8eb", null ], diff --git a/Doc/html/evolve__optimizer_8h__dep__incl.map b/Doc/html/evolve__optimizer_8h__dep__incl.map index 415f98a..2741c58 100644 --- a/Doc/html/evolve__optimizer_8h__dep__incl.map +++ b/Doc/html/evolve__optimizer_8h__dep__incl.map @@ -1,5 +1,5 @@ - - - - + + + + diff --git a/Doc/html/evolve__optimizer_8h__dep__incl.md5 b/Doc/html/evolve__optimizer_8h__dep__incl.md5 index 69e9dea..4ae7408 100644 --- a/Doc/html/evolve__optimizer_8h__dep__incl.md5 +++ b/Doc/html/evolve__optimizer_8h__dep__incl.md5 @@ -1 +1 @@ -f553378750fe54c08a141590bf28abc6 \ No newline at end of file +41a81c5527cb10d478e05e49562aedc3 \ No newline at end of file diff --git a/Doc/html/evolve__optimizer_8h__dep__incl.png b/Doc/html/evolve__optimizer_8h__dep__incl.png index 18e4a8e..02dd104 100644 Binary files a/Doc/html/evolve__optimizer_8h__dep__incl.png and b/Doc/html/evolve__optimizer_8h__dep__incl.png differ diff --git a/Doc/html/evolve__optimizer_8h__incl.map b/Doc/html/evolve__optimizer_8h__incl.map index 037f879..97465e0 100644 --- a/Doc/html/evolve__optimizer_8h__incl.map +++ b/Doc/html/evolve__optimizer_8h__incl.map @@ -1,13 +1,13 @@ - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/Doc/html/evolve__optimizer_8h__incl.md5 b/Doc/html/evolve__optimizer_8h__incl.md5 index ab56a56..29bbece 100644 --- a/Doc/html/evolve__optimizer_8h__incl.md5 +++ b/Doc/html/evolve__optimizer_8h__incl.md5 @@ -1 +1 @@ -fd2e7c14c3afd7acdbec8e90d05455b4 \ No newline at end of file +4993f7378dc2ed7a2e950385e8313f89 \ No newline at end of file diff --git a/Doc/html/evolve__optimizer_8h__incl.png b/Doc/html/evolve__optimizer_8h__incl.png index b22e7b3..09857dc 100644 Binary files a/Doc/html/evolve__optimizer_8h__incl.png and b/Doc/html/evolve__optimizer_8h__incl.png differ diff --git a/Doc/html/evolve__optimizer_8h_source.html b/Doc/html/evolve__optimizer_8h_source.html index ac55157..1b2d3ba 100644 --- a/Doc/html/evolve__optimizer_8h_source.html +++ b/Doc/html/evolve__optimizer_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/evolve_optimizer.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/evolve_optimizer.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
- + + -
+
81
82#ifndef local_time
-
83#define local_time() HAL_GetTick() ///< Локальное время
+
83#define local_time() HAL_GetTick() ///< Локальное время
84#endif
85
86
@@ -216,261 +208,275 @@ $(function(){initNavTree('evolve__optimizer_8h_source.html',''); initResizable()
102typedef struct {
103 float stability; ///< Коэффициент насколько стабильная популяция (0..1)(@ref n_cand)
-
104 uint16_t n_params; ///< Количество параметров
-
105 uint16_t n_cand; ///< Количество кандидатов в популяции
-
106 uint16_t n_best; ///< Количество лучших, усредняемых
-
107 float mutation_amp; ///< Амплитуда мутации (0..1)
-
108 uint16_t cand_index; ///< Индекс кандидата для обработки
-
109 float loss[EVOLVE_MAX_CANDIDATES]; ///< Loss для каждого кандидата
-
110 float candidates[EVOLVE_MAX_CANDIDATES][EVOLVE_MAX_PARAMS]; ///< Параметры кандидатов
-
111 uint16_t sorted_idx[EVOLVE_MAX_CANDIDATES]; ///< Индексы отсортированных кандидатов
- +
104
+
105 uint16_t n_params; ///< Количество параметров
+
106 uint16_t n_cand; ///< Количество кандидатов в популяции
+
107 uint16_t n_best; ///< Количество лучших, усредняемых
+
108 float mutation_amp; ///< Амплитуда мутации (0..1)
+
109
+
110 uint16_t cand_index; ///< Индекс кандидата для обработки
+
111 uint16_t gen_index; ///< Индекс популяции
+
112
+
113 //INTERNAL
+
114 float gen_mut; ///< Амплитуда мутации у текущей популяции
+
115
+
116 float loss[EVOLVE_MAX_CANDIDATES]; ///< Loss для каждого кандидата
+
117 float candidates[EVOLVE_MAX_CANDIDATES][EVOLVE_MAX_PARAMS]; ///< Параметры кандидатов
+
118 uint16_t sorted_idx[EVOLVE_MAX_CANDIDATES]; ///< Индексы отсортированных кандидатов
+
-
113
-
114
-
115
-
116/**
-
117 * @cond EVOLVE_INTERNAL
-
118 */
-
119
-
120// Вспомогательный указатель для сортировки
-
121static EvolveOptimizer_t *g_sort_opt; // глобальный указатель на текущий оптимизатор
-
122
-
123// функция условия сортировки
-
124static int cmp_idx(const void *a, const void *b) {
-
125 if (g_sort_opt->loss[*(const uint16_t*)a] < g_sort_opt->loss[*(const uint16_t*)b])
-
126 return -1;
-
127 if (g_sort_opt->loss[*(const uint16_t*)a] > g_sort_opt->loss[*(const uint16_t*)b])
-
128 return 1;
-
129 return 0;
-
130}
-
131/** @endcond */
-
132
-
133
-
134
-
135
-
136
-
137/**
-
138 * @brief Инициализация эволюционного оптимизатора.
-
139 * @param opt Указатель на структуру оптимизатора
-
140 * @param n_params Количество параметров в одном кандидате
-
141 * @param n_cand Количество кандидатов
-
142 * @param n_best Количество лучших, усредняемых
-
143 * @param mutation_amp Амплитуда мутации (в диапазоне 0.0–1.0)
-
144 * @param start_params Начальные параметры (в диапазоне 0.0–1.0)
-
145 * @return 0 — если окей,
-
146 * -1 — если ошибка
-
147 */
-
- -
149 uint16_t n_params,
-
150 uint16_t n_cand,
-
151 uint16_t n_best,
-
152 float mutation_amp,
-
153 float* start_params)
-
154{
-
155 if((opt == NULL) || (start_params == NULL))
-
156 return -1;
-
157
-
158 if(n_params > EVOLVE_MAX_PARAMS)
-
159 return -1;
-
160 opt->n_params = n_params;
-
161
-
162 if(n_cand > EVOLVE_MAX_CANDIDATES)
-
163 return -1;
-
164 opt->n_cand = n_cand;
-
165
-
166 if(n_best > EVOLVE_MAX_CANDIDATES/2)
-
167 return -1;
-
168 opt->n_best = n_best;
-
169
-
170
-
171 if((mutation_amp > 1) || (mutation_amp < 0))
-
172 return -1;
-
173 if(mutation_amp <= 0.001f)
-
174 mutation_amp = 0.001f;
-
175 opt->mutation_amp = mutation_amp;
-
176
-
177 uint32_t seed = local_time();
-
178#ifdef ADC1
-
179 seed += (ADC1->DR & 0xFF);
-
180#endif
-
181 srand(seed);
-
182
-
183 for (uint16_t i = 0; i < n_cand; i++) {
-
184 for (uint16_t j = 0; j < n_params; j++) {
-
185 // Добавляем случайную мутацию вокруг стартового параметра
-
186 float base = start_params[j];
-
187 float inv_randmax = 1.0f / (float)RAND_MAX;
-
188 float noise = ((float)rand() * inv_randmax * 2.0f - 1.0f) * mutation_amp;
-
189 opt->candidates[i][j] = base + noise;
-
190 if (opt->candidates[i][j] < 0.0f) opt->candidates[i][j] = 0.0f;
-
191 if (opt->candidates[i][j] > 1.0f) opt->candidates[i][j] = 1.0f;
-
192 }
-
193 opt->loss[i] = 0.0f;
-
194 }
-
195
-
196 return 0;
-
197}
+
120
+
121
+
122
+
123/**
+
124 * @cond EVOLVE_INTERNAL
+
125 */
+
126
+
127// Вспомогательный указатель для сортировки
+
128static EvolveOptimizer_t *g_sort_opt; // глобальный указатель на текущий оптимизатор
+
129
+
130// функция условия сортировки
+
131static int cmp_idx(const void *a, const void *b) {
+
132 if (g_sort_opt->loss[*(const uint16_t*)a] < g_sort_opt->loss[*(const uint16_t*)b])
+
133 return -1;
+
134 if (g_sort_opt->loss[*(const uint16_t*)a] > g_sort_opt->loss[*(const uint16_t*)b])
+
135 return 1;
+
136 return 0;
+
137}
+
138/** @endcond */
+
139
+
140
+
141
+
142
+
143
+
144/**
+
145 * @brief Инициализация эволюционного оптимизатора.
+
146 * @param opt Указатель на структуру оптимизатора
+
147 * @param n_params Количество параметров в одном кандидате
+
148 * @param n_cand Количество кандидатов
+
149 * @param n_best Количество лучших, усредняемых
+
150 * @param mutation_amp Амплитуда мутации (в диапазоне 0.0–1.0)
+
151 * @param start_params Начальные параметры (в диапазоне 0.0–1.0)
+
152 * @return 0 — если окей,
+
153 * -1 — если ошибка
+
154 */
+
+ +
156 uint16_t n_params,
+
157 uint16_t n_cand,
+
158 uint16_t n_best,
+
159 float mutation_amp,
+
160 float* start_params)
+
161{
+
162 if((opt == NULL) || (start_params == NULL))
+
163 return -1;
+
164
+
165 if(n_params > EVOLVE_MAX_PARAMS)
+
166 return -1;
+
167 opt->n_params = n_params;
+
168
+
169 if(n_cand > EVOLVE_MAX_CANDIDATES)
+
170 return -1;
+
171 opt->n_cand = n_cand;
+
172
+
173 if(n_best > EVOLVE_MAX_CANDIDATES/2)
+
174 return -1;
+
175 opt->n_best = n_best;
+
176
+
177
+
178 if((mutation_amp > 1) || (mutation_amp < 0))
+
179 return -1;
+
180 if(mutation_amp <= 0.001f)
+
181 mutation_amp = 0.001f;
+
182 opt->mutation_amp = mutation_amp;
+
183
+
184 uint32_t seed = local_time();
+
185#ifdef ADC1
+
186 seed += (ADC1->DR & 0xFF);
+
187#endif
+
188 srand(seed);
+
189
+
190 for (uint16_t i = 0; i < n_cand; i++) {
+
191 for (uint16_t j = 0; j < n_params; j++) {
+
192 // Добавляем случайную мутацию вокруг стартового параметра
+
193 float base = start_params[j];
+
194 float inv_randmax = 1.0f / (float)RAND_MAX;
+
195 float noise = ((float)rand() * inv_randmax * 2.0f - 1.0f) * mutation_amp;
+
196 opt->candidates[i][j] = base + noise;
+
197 if (opt->candidates[i][j] < 0.0f) opt->candidates[i][j] = 0.0f;
+
198 if (opt->candidates[i][j] > 1.0f) opt->candidates[i][j] = 1.0f;
+
199 }
+
200 opt->loss[i] = 0.0f;
+
201 }
+
202
+
203 opt->cand_index = 0;
+
204 opt->gen_index = 0;
+
205 return 0;
+
206}
-
198
-
199
-
200/**
-
201 * @brief Один шаг эволюционного оптимизатора.
-
202 * @param opt Указатель на структуру оптимизатора
-
203 * @param params Массив параметров, которые будут обновлены (на выходе — новые параметры)
-
204 * @param loss Loss текущего кандидата
-
205 * @return 0 — если окей,
-
206 * -1 — если ошибка
-
207 * @details
-
208 * Сохраняет loss текущего кандидата и формирует параметры следующего кандидата.
-
209 * Если накоплено n_cand кандидатов, генерируется новое поколение.
-
210 * Новое поколение формируется случайным выбором из n_best лучших с добавлением мутации.
-
211 *
-
212 * На выходе params содержит параметры следующего кандидата для измерений.
-
213 * @note Функция использует глобальную внутреннюю переменную для сортировки.
-
214 * Надо убедится что только один экземпляр функции запущен в момент времени
-
215 */
-
- -
217 float* params,
-
218 float loss)
-
219{
-
220 if((opt == NULL) || (params == NULL))
-
221 return -1;
-
222
-
223 uint16_t n_params = opt->n_params;
-
224 if(n_params > EVOLVE_MAX_PARAMS)
-
225 return -1;
-
226
-
227 uint16_t n_cand = opt->n_cand;
-
228 if(n_cand > EVOLVE_MAX_CANDIDATES)
-
229 return -1;
-
230
-
231 uint16_t n_best = opt->n_best;
-
232 if(n_best > EVOLVE_MAX_CANDIDATES/2)
-
233 return -1;
-
234
-
235 float mut = opt->mutation_amp;
-
236 if((mut > 1) ||(mut < 0))
-
237 return -1;
-
238
-
239 // 1. Сохраняем loss текущего кандидата
-
240 opt->loss[opt->cand_index] = loss;
-
241 opt->cand_index++;
-
242
-
243 if (opt->cand_index >= n_cand) {
-
244 // 2. Сортируем текущее поколение по loss
-
245 for(uint16_t i = 0; i < opt->n_cand; i++)
-
246 opt->sorted_idx[i] = i;
-
247
-
248 g_sort_opt = opt;
-
249 qsort(opt->sorted_idx, opt->n_cand, sizeof(uint16_t), cmp_idx);
-
250 g_sort_opt = NULL;
+
207
+
208
+
209/**
+
210 * @brief Один шаг эволюционного оптимизатора.
+
211 * @param opt Указатель на структуру оптимизатора
+
212 * @param params Массив параметров, которые будут обновлены (на выходе — новые параметры)
+
213 * @param loss Loss текущего кандидата
+
214 * @return 0 — если окей,
+
215 * -1 — если ошибка
+
216 * @details
+
217 * Сохраняет loss текущего кандидата и формирует параметры следующего кандидата.
+
218 * Если накоплено n_cand кандидатов, генерируется новое поколение.
+
219 * Новое поколение формируется случайным выбором из n_best лучших с добавлением мутации.
+
220 *
+
221 * На выходе params содержит параметры следующего кандидата для измерений.
+
222 * @note Функция использует глобальную внутреннюю переменную для сортировки.
+
223 * Надо убедится что только один экземпляр функции запущен в момент времени
+
224 */
+
+ +
226 float* params,
+
227 float loss)
+
228{
+
229 if((opt == NULL) || (params == NULL))
+
230 return -1;
+
231
+
232 uint16_t n_params = opt->n_params;
+
233 if(n_params > EVOLVE_MAX_PARAMS)
+
234 return -1;
+
235
+
236 uint16_t n_cand = opt->n_cand;
+
237 if(n_cand > EVOLVE_MAX_CANDIDATES)
+
238 return -1;
+
239
+
240 uint16_t n_best = opt->n_best;
+
241 if(n_best > EVOLVE_MAX_CANDIDATES/2)
+
242 return -1;
+
243
+
244 float mut = opt->mutation_amp;
+
245 if((mut > 1) ||(mut < 0))
+
246 return -1;
+
247
+
248 // 1. Сохраняем loss текущего кандидата
+
249 opt->loss[opt->cand_index] = loss;
+
250 opt->cand_index++;
251
-
252 // --- Адаптивная мутация в зависимости от Loss ---
-
253 float best_loss = opt->loss[opt->sorted_idx[0]];
-
254 float worst_loss = opt->loss[opt->sorted_idx[opt->n_cand - 1]];
-
255 float diff = worst_loss - best_loss;
-
256
-
257 float sum_loss = 0.0f;
-
258 for (uint16_t i = 0; i < n_cand; i++)
-
259 sum_loss += opt->loss[i];
-
260 float avg_loss = sum_loss / (float)n_cand;
-
261
-
262
-
263 float loss_ratio = (diff > 0.0f) ? ((avg_loss - best_loss) / diff) : 0.5f;
-
264 if (loss_ratio < 0.0f) loss_ratio = 0.0f;
-
265 if (loss_ratio > 1.0f) loss_ratio = 1.0f;
-
266
-
267 // Записываем стабильность популяции в структуру
-
268 if(diff < 0.0f) diff = 0.0f;
-
269 if(diff > 1.0f) diff = 1.0f;
-
270 opt->stability = (1.0f - worst_loss) * (1.0f - (worst_loss - best_loss));
-
271 if(opt->stability < 0.0f) opt->stability = 0.0f;
-
272 if(opt->stability > 1.0f) opt->stability = 1.0f;
-
273
-
274 float mut_pct = EVOLVE_MUTATION_MIN_PCT +
- -
276 float adaptive_mut = mut * (mut_pct / 100.0f);
-
277 if (adaptive_mut < 0.0001f) adaptive_mut = 0.0001f;
-
278
-
279 // 3. Генерируем новое поколение
-
280 uint16_t n_elite = ELOVLE_N_ELITE_CANDIDATE;
-
281 for (uint16_t c = 0; c < n_cand; c++) {
-
282 if (c < n_elite) {
-
283 for (uint16_t i = 0; i < n_params; i++)
-
284 opt->candidates[c][i] = opt->candidates[opt->sorted_idx[c]][i];
-
285 opt->loss[c] = 0.0f;
-
286 } else {
-
287 for (uint16_t i = 0; i < n_params; i++) {
-
288 float inv_randmax = 1.0f / (float)RAND_MAX;
-
289 float noise = ((float)rand() * inv_randmax * 2.0f - 1.0f) * adaptive_mut;
-
290 uint16_t parent = opt->sorted_idx[rand() % opt->n_best];
-
291 opt->candidates[c][i] = opt->candidates[parent][i] + noise;
-
292 if (opt->candidates[c][i] < 0.0f) opt->candidates[c][i] = 0.0f;
-
293 if (opt->candidates[c][i] > 1.0f) opt->candidates[c][i] = 1.0f;
-
294 }
+
252 if (opt->cand_index >= n_cand) {
+
253 // 2. Сортируем текущее поколение по loss
+
254 for(uint16_t i = 0; i < opt->n_cand; i++)
+
255 opt->sorted_idx[i] = i;
+
256
+
257 g_sort_opt = opt;
+
258 qsort(opt->sorted_idx, opt->n_cand, sizeof(uint16_t), cmp_idx);
+
259 g_sort_opt = NULL;
+
260
+
261 // --- Адаптивная мутация в зависимости от Loss ---
+
262 float best_loss = opt->loss[opt->sorted_idx[0]];
+
263 float worst_loss = opt->loss[opt->sorted_idx[opt->n_cand - 1]];
+
264 float diff = worst_loss - best_loss;
+
265
+
266 float sum_loss = 0.0f;
+
267 for (uint16_t i = 0; i < n_cand; i++)
+
268 sum_loss += opt->loss[i];
+
269 float avg_loss = sum_loss / (float)n_cand;
+
270
+
271
+
272 float loss_ratio = (diff > 0.0f) ? ((avg_loss - best_loss) / diff) : 0.5f;
+
273 if (loss_ratio < 0.0f) loss_ratio = 0.0f;
+
274 if (loss_ratio > 1.0f) loss_ratio = 1.0f;
+
275
+
276 // Записываем стабильность популяции в структуру
+
277 if(diff < 0.0f) diff = 0.0f;
+
278 if(diff > 1.0f) diff = 1.0f;
+
279 opt->stability = (1.0f - worst_loss) * (1.0f - (worst_loss - best_loss));
+
280 if(opt->stability < 0.0f) opt->stability = 0.0f;
+
281 if(opt->stability > 1.0f) opt->stability = 1.0f;
+
282
+
283 float mut_pct = EVOLVE_MUTATION_MIN_PCT +
+ +
285 float adaptive_mut = mut * (mut_pct / 100.0f);
+
286 if (adaptive_mut < 0.0001f) adaptive_mut = 0.0001f;
+
287 opt->gen_mut = adaptive_mut;
+
288
+
289 // 3. Генерируем новое поколение
+
290 uint16_t n_elite = ELOVLE_N_ELITE_CANDIDATE;
+
291 for (uint16_t c = 0; c < n_cand; c++) {
+
292 if (c < n_elite) {
+
293 for (uint16_t i = 0; i < n_params; i++)
+
294 opt->candidates[c][i] = opt->candidates[opt->sorted_idx[c]][i];
295 opt->loss[c] = 0.0f;
-
296 }
-
297 }
-
298 opt->cand_index = 0;
-
299 }
-
300
-
301 // 4. Возвращаем параметры следующего кандидата
-
302 for (uint16_t i = 0; i < opt->n_params; i++)
-
303 params[i] = opt->candidates[opt->cand_index][i];
-
304
-
305 return 0;
-
306}
+
296 } else {
+
297 for (uint16_t i = 0; i < n_params; i++) {
+
298 float inv_randmax = 1.0f / (float)RAND_MAX;
+
299 float noise = ((float)rand() * inv_randmax * 2.0f - 1.0f) * adaptive_mut;
+
300 uint16_t parent = opt->sorted_idx[rand() % opt->n_best];
+
301 opt->candidates[c][i] = opt->candidates[parent][i] + noise;
+
302 if (opt->candidates[c][i] < 0.0f) opt->candidates[c][i] = 0.0f;
+
303 if (opt->candidates[c][i] > 1.0f) opt->candidates[c][i] = 1.0f;
+
304 }
+
305 opt->loss[c] = 0.0f;
+
306 }
+
307 }
+
308 opt->cand_index = 0;
+
309 opt->gen_index++;
+
310 }
+
311
+
312 // 4. Возвращаем параметры следующего кандидата
+
313 for (uint16_t i = 0; i < opt->n_params; i++)
+
314 params[i] = opt->candidates[opt->cand_index][i];
+
315
+
316 return 0;
+
317}
-
307#else // ENABLE_EVOLVE_OPTIMIZATION
-
308//заглушки
-
309typedef struct {
-
310 uint16_t n_params;
-
311 uint16_t n_cand;
-
312 uint16_t n_best;
-
313 float mutation_amp;
-
314 float loss[0];
-
315 float candidates[0][0];
- -
317#define EvolveOptimizer_Init(opt, n_params, n_cand, n_best, mutation_amp, start_params)
-
318#define EvolveOptimizer_Step(opt, params, LossFunc)
-
319#define PARAM_SCALE(x, min_val, max_val) (x)
-
320#define PARAM_UNSCALE(val, min_val, max_val) (val)
-
321#endif // ENABLE_EVOLVE_OPTIMIZATION
-
322
-
323#endif // __EVOLVE_OPTIMIZER_H_
-
324
-
325/** EVOLVE_OPTIMIZER
-
326 * @}
-
327 */
+
318#else // ENABLE_EVOLVE_OPTIMIZATION
+
319//заглушки
+
320typedef struct {
+
321 uint16_t n_params;
+
322 uint16_t n_cand;
+
323 uint16_t n_best;
+
324 float mutation_amp;
+
325 float loss[0];
+
326 float candidates[0][0];
+ +
328#define EvolveOptimizer_Init(opt, n_params, n_cand, n_best, mutation_amp, start_params)
+
329#define EvolveOptimizer_Step(opt, params, LossFunc)
+
330#define PARAM_SCALE(x, min_val, max_val) (x)
+
331#define PARAM_UNSCALE(val, min_val, max_val) (val)
+
332#endif // ENABLE_EVOLVE_OPTIMIZATION
+
333
+
334#endif // __EVOLVE_OPTIMIZER_H_
+
335
+
336/** EVOLVE_OPTIMIZER
+
337 * @}
+
338 */
#define EVOLVE_MAX_CANDIDATES
Максимальное количество кандидатов для обучения
#define EVOLVE_MAX_PARAMS
Максимальное количество параметров
#define EVOLVE_MUTATION_MIN_PCT
Минимальная мутация (в процентах от Loss)
#define ELOVLE_N_ELITE_CANDIDATE
Количество кандидатов, которые проходят в поколение без изменений (по умолчанию 2)
-
__STATIC_INLINE int EvolveOptimizer_Init(EvolveOptimizer_t *opt, uint16_t n_params, uint16_t n_cand, uint16_t n_best, float mutation_amp, float *start_params)
Инициализация эволюционного оптимизатора.
+
__STATIC_INLINE int EvolveOptimizer_Init(EvolveOptimizer_t *opt, uint16_t n_params, uint16_t n_cand, uint16_t n_best, float mutation_amp, float *start_params)
Инициализация эволюционного оптимизатора.
#define EVOLVE_MUTATION_MAX_PCT
Максимальная мутация (в процентах от Loss)
-
#define local_time()
Локальное время
-
__STATIC_INLINE int EvolveOptimizer_Step(EvolveOptimizer_t *opt, float *params, float loss)
Один шаг эволюционного оптимизатора.
+
__STATIC_INLINE int EvolveOptimizer_Step(EvolveOptimizer_t *opt, float *params, float loss)
Один шаг эволюционного оптимизатора.
+
#define local_time()
Локальное время
Заголочный файл для дефайнов библиотеки MyLibsGeneral.
Структура эволюционного оптимизатора
-
uint16_t cand_index
Индекс кандидата для обработки
-
uint16_t n_params
Количество параметров
-
uint16_t sorted_idx[100]
Индексы отсортированных кандидатов
+
uint16_t cand_index
Индекс кандидата для обработки
+
uint16_t n_params
Количество параметров
+
float gen_mut
Амплитуда мутации у текущей популяции
+
uint16_t sorted_idx[100]
Индексы отсортированных кандидатов
float stability
Коэффициент насколько стабильная популяция (0..1)(n_cand)
-
float loss[100]
Loss для каждого кандидата
-
uint16_t n_best
Количество лучших, усредняемых
-
uint16_t n_cand
Количество кандидатов в популяции
-
float candidates[100][20]
Параметры кандидатов
-
float mutation_amp
Амплитуда мутации (0..1)
+
float loss[100]
Loss для каждого кандидата
+
uint16_t n_best
Количество лучших, усредняемых
+
uint16_t n_cand
Количество кандидатов в популяции
+
uint16_t gen_index
Индекс популяции
+
float candidates[100][20]
Параметры кандидатов
+
float mutation_amp
Амплитуда мутации (0..1)
+
diff --git a/Doc/html/files.html b/Doc/html/files.html index a27bf8e..cda73dd 100644 --- a/Doc/html/files.html +++ b/Doc/html/files.html @@ -3,7 +3,7 @@ - + MyLibs: File List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
- + + @@ -73,10 +71,9 @@ $(function() { +
Here is a list of all documented files with brief descriptions:
[detail level 123]
- - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + +
  MyLibsGeneral
  Inc
 __general_flash.h
 __general_spi.h
 __general_uart.h
 bit_access.hЗаголочный файл для дефайнов битового доступа
 evolve_optimizer.hЗаголовочный файл для адаптивного подбора параметров
 general_gpio.hЗаголовочный файл для модуля инициализации портов и работы с ними
 general_tim.hЗаголовочный файл для модуля инициализации таймеров и работы с ними
 mylibs_config.hКонфигурации для библиотек MyLibs
 mylibs_defs.hЗаголочный файл для дефайнов библиотеки MyLibsGeneral
 mylibs_include.hЗаголочный файл для всех библиотек
 trace.hЗаголочный файл для работы с трассировкой
 trackers.hЗаголочный файл для работы с трекерами Trackers defines
  Src
 __general_flash.c
 __general_spi.c
 __general_uart.c
 general_gpio.cМодуль для инициализации портов и работы с ними
 general_tim.cМодуль для инициализации таймеров и работы с ними
 mainpage.h
 
MyLibsGeneral
 
Inc
 
__general_flash.h
 
bit_access.h
Заголочный файл для дефайнов битового доступа
 
evolve_optimizer.h
Заголовочный файл для адаптивного подбора параметров
 
general_gpio.h
Заголовочный файл для модуля инициализации портов и работы с ними
 
general_spi.h
Заголовочный файл для модуля инициализации SPI
 
general_tim.h
Заголовочный файл для модуля инициализации таймеров и работы с ними
 
general_uart.h
Заголовочный файл для модуля инициализации UART
 
mylibs_config.h
Конфигурации для библиотек MyLibs
 
mylibs_defs.h
Заголочный файл для дефайнов библиотеки MyLibsGeneral
 
mylibs_include.h
Заголочный файл для всех библиотек
 
trace.h
Заголочный файл для работы с трассировкой
 
trackers.h
Заголочный файл для работы с трекерами Trackers defines
 
Src
 
__general_flash.c
 
general_gpio.c
Модуль для инициализации портов и работы с ними
 
general_spi.c
Модуль для инициализации SPI
 
general_tim.c
Модуль для инициализации таймеров и работы с ними
 
general_uart.c
Модуль для инициализации UART
 
mainpage.h
+
diff --git a/Doc/html/functions.html b/Doc/html/functions.html index 4841303..998b50d 100644 --- a/Doc/html/functions.html +++ b/Doc/html/functions.html @@ -3,7 +3,7 @@ - + MyLibs: Class Members @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
Here is a list of all documented class members with links to the class documentation for each member:
-

- c -

+
diff --git a/Doc/html/functions_vars.html b/Doc/html/functions_vars.html index d9cec07..5b72a00 100644 --- a/Doc/html/functions_vars.html +++ b/Doc/html/functions_vars.html @@ -3,7 +3,7 @@ - + MyLibs: Class Members - Variables @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
Here is a list of all documented variables with links to the class documentation for each member:
-

- c -

+
diff --git a/Doc/html/general__gpio_8c.html b/Doc/html/general__gpio_8c.html index 82278a7..895b805 100644 --- a/Doc/html/general__gpio_8c.html +++ b/Doc/html/general__gpio_8c.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Src/general_gpio.c File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Src/general_gpio.c File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
-
general_gpio.c File Reference
@@ -109,61 +104,50 @@ $(function(){initNavTree('general__gpio_8c.html',''); initResizable(); });

Модуль для инициализации портов и работы с ними. More...

#include "general_gpio.h"
-
- + Include dependency graph for general_gpio.c:
+
Include dependency graph for general_gpio.c:

Go to the source code of this file.

- - - - - - - - - - -

+

Functions

HAL_StatusTypeDef GPIO_Clock_Enable (GPIO_TypeDef *GPIOx)
 Включить тактирование порта GPIO.
 
HAL_StatusTypeDef GPIO_LED_Init (GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_ActiveLevel)
 Инициализировать светодиод (структуру светодиода)
 
HAL_StatusTypeDef GPIO_LED_On (GPIO_LEDTypeDef *led)
 Включить светодиод
 
HAL_StatusTypeDef GPIO_LED_Off (GPIO_LEDTypeDef *led)
 Выключить светодиод
 
HAL_StatusTypeDef GPIO_LED_Set (GPIO_LEDTypeDef *led, uint8_t led_state)
 Выставить светодиод по переменной
 
HAL_StatusTypeDef GPIO_LED_Blink_Start (GPIO_LEDTypeDef *led, uint32_t period)
 Активировать моргание светодиодом
 
HAL_StatusTypeDef GPIO_LED_Fading_Start (GPIO_LEDTypeDef *led, uint32_t period)
 Активировать моргание светодиодом
 
void GPIO_LED_Dynamic_Handle (GPIO_LEDTypeDef *led)
 Управление динамическими режимами свечения светодиода
 
HAL_StatusTypeDef GPIO_Switch_Init (GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_ActiveLevel)
 Инициализировать кнопку (структуру кнопки)
 
int GPIO_Read_Switch (GPIO_SwitchTypeDef *sw)
 Считать состоянии кнопки
 
-

Detailed Description

+

Detailed Description

Модуль для инициализации портов и работы с ними.

Реализация функций для работы с GPIO:

  • Включение тактирования портов
  • @@ -175,11 +159,19 @@ Functions

    Definition in file general_gpio.c.

+ +
diff --git a/Doc/html/general__gpio_8c__incl.map b/Doc/html/general__gpio_8c__incl.map index 99ab50e..1d47388 100644 --- a/Doc/html/general__gpio_8c__incl.map +++ b/Doc/html/general__gpio_8c__incl.map @@ -1,11 +1,11 @@ - - - - - - - - - - + + + + + + + + + + diff --git a/Doc/html/general__gpio_8c__incl.md5 b/Doc/html/general__gpio_8c__incl.md5 index 78771e7..958ccc2 100644 --- a/Doc/html/general__gpio_8c__incl.md5 +++ b/Doc/html/general__gpio_8c__incl.md5 @@ -1 +1 @@ -ef5806c364614a686ed2e7465f1e02dc \ No newline at end of file +6e517891df2cdbcb0824fafba9ac3005 \ No newline at end of file diff --git a/Doc/html/general__gpio_8c__incl.png b/Doc/html/general__gpio_8c__incl.png index e3e6c87..f8a4a65 100644 Binary files a/Doc/html/general__gpio_8c__incl.png and b/Doc/html/general__gpio_8c__incl.png differ diff --git a/Doc/html/general__gpio_8c_source.html b/Doc/html/general__gpio_8c_source.html index 627536e..f0c45b5 100644 --- a/Doc/html/general__gpio_8c_source.html +++ b/Doc/html/general__gpio_8c_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Src/general_gpio.c Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Src/general_gpio.c Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
- + + -
+
189 /* Режим моргания светодиода */
190 if(led->state == LED_IS_BLINKING)
191 {
-
192 uint32_t tickcurrent = HAL_GetTick();
+
192 uint32_t tickcurrent = local_time();
193 /* Ожидание истечения периода моргания */
194 if((tickcurrent - led->tickprev) > led->LED_Period)
195 {
@@ -329,7 +321,7 @@ $(function(){initNavTree('general__gpio_8c_source.html',''); initResizable(); })
204 {
205 static unsigned direction = 0;
206 static int duty = 0;
-
207 uint32_t tickcurrent = HAL_GetTick();
+
207 uint32_t tickcurrent = local_time();
208 /* Ожидание момента изменения яркости */
209 /* Период ШИМ 20 мс, поэтому менять яроксть надо 40 раз за период (туда обратно) */
210 if((tickcurrent - led->tickprev) > led->LED_Period/(LED_PWM_TICKS*2))
@@ -417,9 +409,9 @@ $(function(){initNavTree('general__gpio_8c_source.html',''); initResizable(); })
288 if(sw->Sw_FilterDelay) // если включена защита от дребезга
289 {
290 if(sw->tickprev == 0)
-
291 sw->tickprev = HAL_GetTick();
+
291 sw->tickprev = local_time();
292
-
293 if((HAL_GetTick() - sw->tickprev) >= sw->Sw_FilterDelay)
+
293 if((local_time() - sw->tickprev) >= sw->Sw_FilterDelay)
294 {
295 if(HAL_GPIO_ReadPin(sw->Sw_Port, sw->Sw_Pin) == sw->Sw_ActiveLvl)
296 {
@@ -457,7 +449,8 @@ $(function(){initNavTree('general__gpio_8c_source.html',''); initResizable(); })
Заголовочный файл для модуля инициализации портов и работы с ними.
#define check_null_ptr_1(p1)
Проверить один указатель на NULL.
Definition mylibs_defs.h:38
#define check_null_ptr_3(p1, p2, p3)
Проверить три указателя на NULL.
Definition mylibs_defs.h:44
-
#define LED_PWM_TICKS
Количество тиков в периоде ШИМ
+
#define LED_PWM_TICKS
Количество тиков в периоде ШИМ
+
#define local_time()
Локальное время
HAL_StatusTypeDef GPIO_Clock_Enable(GPIO_TypeDef *GPIOx)
Включить тактирование порта GPIO.
HAL_StatusTypeDef GPIO_LED_On(GPIO_LEDTypeDef *led)
Включить светодиод
HAL_StatusTypeDef GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period)
Активировать моргание светодиодом
@@ -466,31 +459,32 @@ $(function(){initNavTree('general__gpio_8c_source.html',''); initResizable(); })
void GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led)
Управление динамическими режимами свечения светодиода
HAL_StatusTypeDef GPIO_LED_Set(GPIO_LEDTypeDef *led, uint8_t led_state)
Выставить светодиод по переменной
HAL_StatusTypeDef GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period)
Активировать моргание светодиодом
-
@ LED_IS_BLINKING
Моргание светодиодом
-
@ LED_IS_OFF
Светодиод выключен
-
@ LED_IS_FADING
Плавное моргание светодиодом
-
@ LED_IS_ON
Светодиод включен
+
@ LED_IS_BLINKING
Моргание светодиодом
+
@ LED_IS_OFF
Светодиод выключен
+
@ LED_IS_FADING
Плавное моргание светодиодом
+
@ LED_IS_ON
Светодиод включен
int GPIO_Read_Switch(GPIO_SwitchTypeDef *sw)
Считать состоянии кнопки
HAL_StatusTypeDef GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_ActiveLevel)
Инициализировать кнопку (структуру кнопки)
-
Структура светодиода
-
uint32_t LED_Pin
GPIO пин ножки светодиода
-
uint32_t LED_Period
Период моргания светодиода
-
GPIO_TypeDef * LED_Port
GPIO порт ножки светодиода
-
uint8_t LED_ActiveLvl
Активный уровень ножки (при котором светодиод горит)
-
GPIO_LEDStateTypeDef state
Текущий режим работы светодиода
-
Структура кнопки
-
uint32_t Sw_PrevState
Предыдущее состояние кнопки
-
uint32_t Sw_FilterDelay
Фильтр от дребезга (в мс)
-
uint8_t Sw_ActiveLvl
Активный уровень ножки (при котором кнопка нажата)
-
uint32_t Sw_Pin
GPIO пин ножки кнопки
-
GPIO_TypeDef * Sw_Port
GPIO порт ножки кнопки
+
Структура светодиода
+
uint32_t LED_Pin
GPIO пин ножки светодиода
+
uint32_t LED_Period
Период моргания светодиода
+
GPIO_TypeDef * LED_Port
GPIO порт ножки светодиода
+
uint8_t LED_ActiveLvl
Активный уровень ножки (при котором светодиод горит)
+
GPIO_LEDStateTypeDef state
Текущий режим работы светодиода
+
Структура кнопки
+
uint32_t Sw_PrevState
Предыдущее состояние кнопки
+
uint32_t Sw_FilterDelay
Фильтр от дребезга (в мс)
+
uint8_t Sw_ActiveLvl
Активный уровень ножки (при котором кнопка нажата)
+
uint32_t Sw_Pin
GPIO пин ножки кнопки
+
GPIO_TypeDef * Sw_Port
GPIO порт ножки кнопки
+ diff --git a/Doc/html/general__gpio_8h.html b/Doc/html/general__gpio_8h.html index b5bf390..014c240 100644 --- a/Doc/html/general__gpio_8h.html +++ b/Doc/html/general__gpio_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_gpio.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_gpio.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
-
general_gpio.h File Reference
@@ -112,79 +104,67 @@ $(function(){initNavTree('general__gpio_8h.html',''); initResizable(); });

Заголовочный файл для модуля инициализации портов и работы с ними. More...

#include "mylibs_defs.h"
-
- + Include dependency graph for general_gpio.h:
+
Include dependency graph for general_gpio.h:
-
- + This graph shows which files directly or indirectly include this file:
+
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

- - + - - + -

+

Classes

struct  GPIO_LEDTypeDef
struct  GPIO_LEDTypeDef
 Структура светодиода More...
 
struct  GPIO_SwitchTypeDef
struct  GPIO_SwitchTypeDef
 Структура кнопки More...
 
- - - - - - - - -

+

Macros

#define LED_PWM_TICKS   15
 Количество тиков в периоде ШИМ
 
#define LED_ON   1
 Состояние пина для включения светодиода
 
#define LED_OFF   0
 Состояние пина для выключения светодиода
 
#define SW_ON   1
 Состояние пина при нажатой кнопке
 
#define SW_OFF   0
 Состояние пина при отжатой кнопке
 
#define GPIO_TIM_Alternate_Mapping(INSTANCE)
 Маппинг альтернативной функции TIM между GPIO.
 
- , LED_IS_FADING = 3 } -

+

Enumerations

enum  GPIO_LEDStateTypeDef { LED_IS_OFF = 0 , LED_IS_ON = 1 @@ -192,52 +172,49 @@ Enumerations
 Режимы работы светодиода More...
 
- - - - - - - - - - -

+

Functions

HAL_StatusTypeDef GPIO_Clock_Enable (GPIO_TypeDef *GPIOx)
 Включить тактирование порта GPIO.
 
HAL_StatusTypeDef GPIO_Switch_Init (GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State)
 Инициализировать кнопку (структуру кнопки)
 
int GPIO_Read_Switch (GPIO_SwitchTypeDef *swstart)
 Считать состоянии кнопки
 
HAL_StatusTypeDef GPIO_LED_Init (GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State)
 Инициализировать светодиод (структуру светодиода)
 
HAL_StatusTypeDef GPIO_LED_On (GPIO_LEDTypeDef *led)
 Включить светодиод
 
HAL_StatusTypeDef GPIO_LED_Off (GPIO_LEDTypeDef *led)
 Выключить светодиод
 
HAL_StatusTypeDef GPIO_LED_Set (GPIO_LEDTypeDef *led, uint8_t led_state)
 Выставить светодиод по переменной
 
HAL_StatusTypeDef GPIO_LED_Blink_Start (GPIO_LEDTypeDef *led, uint32_t period)
 Активировать моргание светодиодом
 
HAL_StatusTypeDef GPIO_LED_Fading_Start (GPIO_LEDTypeDef *led, uint32_t period)
 Активировать моргание светодиодом
 
void GPIO_LED_Dynamic_Handle (GPIO_LEDTypeDef *led)
 Управление динамическими режимами свечения светодиода
 
-

Detailed Description

+

Detailed Description

Заголовочный файл для модуля инициализации портов и работы с ними.

Definition in file general_gpio.h.

+ +
diff --git a/Doc/html/general__gpio_8h.js b/Doc/html/general__gpio_8h.js index 20925fe..e739a8f 100644 --- a/Doc/html/general__gpio_8h.js +++ b/Doc/html/general__gpio_8h.js @@ -5,7 +5,6 @@ var general__gpio_8h = [ "LED_OFF", "group___g_p_i_o___i_n_i_t.html#ga80700bb63bd56ebabbb4728aa433fd29", null ], [ "SW_ON", "group___g_p_i_o___i_n_i_t.html#ga19d9e3aced311179a2914e0c9b13d0f9", null ], [ "SW_OFF", "group___g_p_i_o___i_n_i_t.html#gacd8900c9ec0efde1da3253b718574067", null ], - [ "GPIO_TIM_Alternate_Mapping", "group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga580b842096340b066c28b24d6b315be6", null ], [ "GPIO_LEDStateTypeDef", "group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaac2b90d8b8c9579b6aa5d3bbda9b1ff1", [ [ "LED_IS_OFF", "group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a74276cd2464314e422e8a144483f74ae", null ], [ "LED_IS_ON", "group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1af6abfb9c5b95abbdb239590f2cd245ea", null ], diff --git a/Doc/html/general__gpio_8h__dep__incl.map b/Doc/html/general__gpio_8h__dep__incl.map index 1ee50f3..4a3628e 100644 --- a/Doc/html/general__gpio_8h__dep__incl.map +++ b/Doc/html/general__gpio_8h__dep__incl.map @@ -1,16 +1,16 @@ - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + diff --git a/Doc/html/general__gpio_8h__dep__incl.md5 b/Doc/html/general__gpio_8h__dep__incl.md5 index b686327..4499c32 100644 --- a/Doc/html/general__gpio_8h__dep__incl.md5 +++ b/Doc/html/general__gpio_8h__dep__incl.md5 @@ -1 +1 @@ -f42bf5193afb062a9c95d3c96bb4e0cd \ No newline at end of file +f0505ab3694aaaff670ed9b2b0d44914 \ No newline at end of file diff --git a/Doc/html/general__gpio_8h__dep__incl.png b/Doc/html/general__gpio_8h__dep__incl.png index 8d29aae..8c65085 100644 Binary files a/Doc/html/general__gpio_8h__dep__incl.png and b/Doc/html/general__gpio_8h__dep__incl.png differ diff --git a/Doc/html/general__gpio_8h__incl.map b/Doc/html/general__gpio_8h__incl.map index f3ddf1d..2a678e8 100644 --- a/Doc/html/general__gpio_8h__incl.map +++ b/Doc/html/general__gpio_8h__incl.map @@ -1,9 +1,9 @@ - - - - - - - - + + + + + + + + diff --git a/Doc/html/general__gpio_8h__incl.md5 b/Doc/html/general__gpio_8h__incl.md5 index 7a01ba7..e999f78 100644 --- a/Doc/html/general__gpio_8h__incl.md5 +++ b/Doc/html/general__gpio_8h__incl.md5 @@ -1 +1 @@ -21dce52570063c58c664fb8c26d4473d \ No newline at end of file +64dafee7a8d3ae5fb443763ec7bc3400 \ No newline at end of file diff --git a/Doc/html/general__gpio_8h__incl.png b/Doc/html/general__gpio_8h__incl.png index 0a47dfa..04247fc 100644 Binary files a/Doc/html/general__gpio_8h__incl.png and b/Doc/html/general__gpio_8h__incl.png differ diff --git a/Doc/html/general__gpio_8h_source.html b/Doc/html/general__gpio_8h_source.html index 3ebec28..7f0a29f 100644 --- a/Doc/html/general__gpio_8h_source.html +++ b/Doc/html/general__gpio_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_gpio.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_gpio.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
- + + -
+
27 * @{
28 */
29
-
30#ifndef LED_PWM_TICKS
-
31#define LED_PWM_TICKS 15 ///< Количество тиков в периоде ШИМ
+
30#ifndef local_time
+
31#define local_time() HAL_GetTick() ///< Локальное время
32#endif
-
33
-
34#ifndef LED_ON
-
35#define LED_ON 1 ///< Состояние пина для включения светодиода
+
33
+
34#ifndef LED_PWM_TICKS
+
35#define LED_PWM_TICKS 15 ///< Количество тиков в периоде ШИМ
36#endif
-
37#ifndef LED_OFF
-
38#define LED_OFF 0 ///< Состояние пина для выключения светодиода
-
39#endif
-
40
-
41#ifndef SW_ON
-
42#define SW_ON 1 ///< Состояние пина при нажатой кнопке
+
37
+
38#ifndef LED_ON
+
39#define LED_ON 1 ///< Состояние пина для включения светодиода
+
40#endif
+
41#ifndef LED_OFF
+
42#define LED_OFF 0 ///< Состояние пина для выключения светодиода
43#endif
-
44#ifndef SW_OFF
-
45#define SW_OFF 0 ///< Состояние пина при отжатой кнопке
-
46#endif
-
47
-
48/** GPIO_INIT
-
49 * @}
-
50 */
-
51
-
52
-
53// /**
-
54// * @brief Маппинг альтернативной функции SPI между GPIO
-
55// * @ingroup MYLIBS_GPIO_GENERAL
-
56// */
-
57// #define SPI_Alternate_Mapping(INSTANCE) \
-
58// ((((INSTANCE) == TIM1) || ((INSTANCE) == TIM2))? GPIO_AF1_TIM1: \
-
59// (((INSTANCE) == TIM3) || ((INSTANCE) == TIM4) || ((INSTANCE) == TIM5))? GPIO_AF2_TIM3: \
-
60// (((INSTANCE) == TIM8) || ((INSTANCE) == TIM9) || ((INSTANCE) == TIM10) || ((INSTANCE) == TIM11))? GPIO_AF3_TIM8: \
-
61// (((INSTANCE) == TIM12) || ((INSTANCE) == TIM13) || ((INSTANCE) == TIM14))? GPIO_AF9_TIM12: \
-
62// (0))
-
63
-
64
-
65/**
-
66 * @brief Маппинг альтернативной функции TIM между GPIO
-
67 * @ingroup MYLIBS_GPIO_GENERAL
-
68 */
-
-
69#define GPIO_TIM_Alternate_Mapping(INSTANCE) \
-
70((((INSTANCE) == TIM1) || ((INSTANCE) == TIM2))? GPIO_AF1_TIM1: \
-
71(((INSTANCE) == TIM3) || ((INSTANCE) == TIM4) || ((INSTANCE) == TIM5))? GPIO_AF2_TIM3: \
-
72(((INSTANCE) == TIM8) || ((INSTANCE) == TIM9) || ((INSTANCE) == TIM10) || ((INSTANCE) == TIM11))? GPIO_AF3_TIM8: \
-
73(((INSTANCE) == TIM12) || ((INSTANCE) == TIM13) || ((INSTANCE) == TIM14))? GPIO_AF9_TIM12: \
-
74(0))
+
44
+
45#ifndef SW_ON
+
46#define SW_ON 1 ///< Состояние пина при нажатой кнопке
+
47#endif
+
48#ifndef SW_OFF
+
49#define SW_OFF 0 ///< Состояние пина при отжатой кнопке
+
50#endif
+
51
+
52/** GPIO_INIT
+
53 * @}
+
54 */
+
55
+
56
+
57/**
+
58 * @brief Режимы работы светодиода
+
59 * @ingroup MYLIBS_GPIO_LEDS
+
60 */
+
+
61typedef enum
+
62{
+
63 LED_IS_OFF = 0, ///< Светодиод выключен
+
64 LED_IS_ON = 1, ///< Светодиод включен
+
65 LED_IS_BLINKING = 2, ///< Моргание светодиодом
+
66 LED_IS_FADING = 3, ///< Плавное моргание светодиодом
+
-
75
-
76
-
77/**
-
78 * @brief Режимы работы светодиода
-
79 * @ingroup MYLIBS_GPIO_LEDS
-
80 */
-
-
81typedef enum
-
82{
-
83 LED_IS_OFF = 0, ///< Светодиод выключен
-
84 LED_IS_ON = 1, ///< Светодиод включен
-
85 LED_IS_BLINKING = 2, ///< Моргание светодиодом
-
86 LED_IS_FADING = 3, ///< Плавное моргание светодиодом
- +
68
+
69/**
+
70 * @brief Структура светодиода
+
71 * @ingroup MYLIBS_GPIO_LEDS
+
72 */
+
+
73typedef struct
+
74{
+
75 GPIO_LEDStateTypeDef state; ///< Текущий режим работы светодиода
+
76
+
77 GPIO_TypeDef *LED_Port; ///< GPIO порт ножки светодиода
+
78 uint32_t LED_Pin; ///< GPIO пин ножки светодиода
+
79
+
80 uint8_t LED_ActiveLvl; ///< Активный уровень ножки (при котором светодиод горит)
+
81 uint32_t LED_Period; ///< Период моргания светодиода
+
82
+
83 uint32_t tickprev;
+
-
88
-
89/**
-
90 * @brief Структура светодиода
-
91 * @ingroup MYLIBS_GPIO_LEDS
-
92 */
-
-
93typedef struct
-
94{
-
95 GPIO_LEDStateTypeDef state; ///< Текущий режим работы светодиода
-
96
-
97 GPIO_TypeDef *LED_Port; ///< GPIO порт ножки светодиода
-
98 uint32_t LED_Pin; ///< GPIO пин ножки светодиода
-
99
-
100 uint8_t LED_ActiveLvl; ///< Активный уровень ножки (при котором светодиод горит)
-
101 uint32_t LED_Period; ///< Период моргания светодиода
-
102
-
103 uint32_t tickprev;
- +
85
+
86/**
+
87 * @brief Структура кнопки
+
88 * @ingroup MYLIBS_GPIO_SWITCH
+
89 */
+
+
90typedef struct
+
91{
+
92 GPIO_TypeDef *Sw_Port; ///< GPIO порт ножки кнопки
+
93 uint32_t Sw_Pin; ///< GPIO пин ножки кнопки
+
94
+
95 uint8_t Sw_ActiveLvl; ///< Активный уровень ножки (при котором кнопка нажата)
+
96 uint32_t Sw_PrevState; ///< Предыдущее состояние кнопки
+
97 uint32_t Sw_FilterDelay; ///< Фильтр от дребезга (в мс)
+
98
+
99 uint32_t tickprev;
+
-
105
-
106/**
-
107 * @brief Структура кнопки
-
108 * @ingroup MYLIBS_GPIO_SWITCH
-
109 */
-
-
110typedef struct
-
111{
-
112 GPIO_TypeDef *Sw_Port; ///< GPIO порт ножки кнопки
-
113 uint32_t Sw_Pin; ///< GPIO пин ножки кнопки
-
114
-
115 uint8_t Sw_ActiveLvl; ///< Активный уровень ножки (при котором кнопка нажата)
-
116 uint32_t Sw_PrevState; ///< Предыдущее состояние кнопки
-
117 uint32_t Sw_FilterDelay; ///< Фильтр от дребезга (в мс)
-
118
-
119 uint32_t tickprev;
- -
-
121
+
101
+
102
+
103/////////////////////////////////////////////////////////////////////
+
104///////////////////////////---FUNCTIONS---///////////////////////////
+
105/**
+
106 * @addtogroup MYLIBS_GPIO_GENERAL General tools
+
107 * @ingroup MY_LIBS_GPIO
+
108 * @brief Общие функции/макросы для работы с GPIO
+
109 * @par Пример использования:
+
110 @code
+
111 // Включаем тактирование порта GPIOA
+
112 GPIO_Clock_Enable(GPIOA);
+
113 @endcode
+
114 * @{
+
115 */
+
116
+
117HAL_StatusTypeDef GPIO_Clock_Enable(GPIO_TypeDef *GPIOx);
+
118
+
119/** MYLIBS_GPIO_GENERAL
+
120 * @}
+
121 */
122
-
123/////////////////////////////////////////////////////////////////////
-
124///////////////////////////---FUNCTIONS---///////////////////////////
-
125/**
-
126 * @addtogroup MYLIBS_GPIO_GENERAL General tools
-
127 * @ingroup MY_LIBS_GPIO
-
128 * @brief Общие функции/макросы для работы с GPIO
-
129 * @{
-
130 */
-
131
-
132HAL_StatusTypeDef GPIO_Clock_Enable(GPIO_TypeDef *GPIOx);
-
133
-
134/** MYLIBS_GPIO_GENERAL
-
135 * @}
-
136 */
-
137
-
138/**
-
139* @addtogroup MYLIBS_GPIO_SWITCH Switch tools
-
140* @ingroup MY_LIBS_GPIO
-
141* @brief Функции для работы с GPIO, как с кнопкой
-
142* @{
-
143*/
-
144
-
145/* Инициализировать кнопку (структуру кнопки) */
-
146HAL_StatusTypeDef GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State);
-
147/* Считать состоянии кнопки запуска */
- -
149
-
150/** MYLIBS_GPIO_SWITCH
-
151 * @}
-
152 */
-
153
+
123/**
+
124 * @addtogroup MYLIBS_GPIO_SWITCH Switch tools
+
125 * @ingroup MY_LIBS_GPIO
+
126 * @brief Функции для работы с GPIO, как с кнопкой
+
127 * @par Пример использования:
+
128 @code
+
129 MX_GPIO_Init(); // инициализация пина аппаратная
+
130
+
131 // Инициализация кнопки на порте GPIOB, пин 0, активный уровень 1
+
132 GPIO_SwitchTypeDef sw1;
+
133 GPIO_Switch_Init(&sw1, GPIOB, GPIO_PIN_0, 1); // или дефайн SW_ON/SW_OFF
+
134
+
135 // Считываем состояние кнопки
+
136 if(GPIO_Read_Switch(&sw1))
+
137 {
+
138 // Кнопка нажата
+
139 LED_ON();
+
140 }
+
141 else
+
142 {
+
143 // Кнопка отжата
+
144 LED_OFF();
+
145 }
+
146 @endcode
+
147 * @{
+
148 */
+
149
+
150/* Инициализировать кнопку (структуру кнопки) */
+
151HAL_StatusTypeDef GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State);
+
152/* Считать состоянии кнопки запуска */
+
154
-
155/**
-
156 * @addtogroup MYLIBS_GPIO_LEDS LED tools
-
157 * @ingroup MY_LIBS_GPIO
-
158 * @brief Функции для работы с GPIO, для управления светодиодом
-
159 * @{
-
160 */
-
161
-
162/* Инициализировать светодиод (структуру светодиода) */
-
163HAL_StatusTypeDef GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State);
-
164/* Включить светодиод */
-
165HAL_StatusTypeDef GPIO_LED_On (GPIO_LEDTypeDef *led);
-
166/* Выключить светодиод */
-
167HAL_StatusTypeDef GPIO_LED_Off (GPIO_LEDTypeDef *led);
-
168/* Выставить светодиод по переменной */
-
169HAL_StatusTypeDef GPIO_LED_Set (GPIO_LEDTypeDef *led, uint8_t led_state);
-
170/* Активировать моргание светодиодом */
-
171HAL_StatusTypeDef GPIO_LED_Blink_Start (GPIO_LEDTypeDef *led, uint32_t period);
-
172/* Активировать моргание светодиодом */
-
173HAL_StatusTypeDef GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period);
-
174/* Управление динамическими режимами свечения светодиода */
- -
176
-
177/** MYLIBS_GPIO_LEDS
-
178 * @}
-
179 */
-
180///////////////////////////---FUNCTIONS---///////////////////////////
-
181
-
182
-
183#endif // __GPIO_GENERAL_H_
+
155/** MYLIBS_GPIO_SWITCH
+
156 * @}
+
157 */
+
158
+
159
+
160/**
+
161 * @addtogroup MYLIBS_GPIO_LEDS LED tools
+
162 * @ingroup MY_LIBS_GPIO
+
163 * @brief Функции для работы с GPIO, для управления светодиодом
+
164 * @par Пример использования:
+
165 @code
+
166 MX_GPIO_Init(); // инициализация пина аппаратная
+
167
+
168 // Инициализация светодиода на порте GPIOA, пин 5, активный уровень 0
+
169 GPIO_LEDTypeDef led;
+
170 GPIO_LED_Init(&led, GPIOA, GPIO_PIN_5, 0); // или дефайн LED_ON/LED_OFF
+
171
+
172 // Включение светодиода
+
173 GPIO_LED_On(&led);
+
174
+
175 // Запуск моргания
+
176 GPIO_LED_Blink_Start(&led, 500); // Период 500 мс
+
177
+
178 // В основном цикле
+
179 while (1) {
+
180 GPIO_LED_Dynamic_Handle(&led);
+
181 }
+
182 @endcode
+
183 * @{
+
184 */
+
185
+
186/* Инициализировать светодиод (структуру светодиода) */
+
187HAL_StatusTypeDef GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State);
+
188/* Включить светодиод */
+
189HAL_StatusTypeDef GPIO_LED_On (GPIO_LEDTypeDef *led);
+
190/* Выключить светодиод */
+
191HAL_StatusTypeDef GPIO_LED_Off (GPIO_LEDTypeDef *led);
+
192/* Выставить светодиод по переменной */
+
193HAL_StatusTypeDef GPIO_LED_Set (GPIO_LEDTypeDef *led, uint8_t led_state);
+
194/* Активировать моргание светодиодом */
+
195HAL_StatusTypeDef GPIO_LED_Blink_Start (GPIO_LEDTypeDef *led, uint32_t period);
+
196/* Активировать моргание светодиодом */
+
197HAL_StatusTypeDef GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period);
+
198/* Управление динамическими режимами свечения светодиода */
+ +
200
+
201/** MYLIBS_GPIO_LEDS
+
202 * @}
+
203 */
+
204///////////////////////////---FUNCTIONS---///////////////////////////
+
205
+
206
+
207/**
+
208 * @cond GPIO_INTERNAL
+
209 */
+
210
+
211// /**
+
212// * @brief Маппинг альтернативной функции SPI между GPIO
+
213// * @ingroup MYLIBS_GPIO_GENERAL
+
214// */
+
215// #define SPI_Alternate_Mapping(INSTANCE) \
+
216// ((((INSTANCE) == TIM1) || ((INSTANCE) == TIM2))? GPIO_AF1_TIM1: \
+
217// (((INSTANCE) == TIM3) || ((INSTANCE) == TIM4) || ((INSTANCE) == TIM5))? GPIO_AF2_TIM3: \
+
218// (((INSTANCE) == TIM8) || ((INSTANCE) == TIM9) || ((INSTANCE) == TIM10) || ((INSTANCE) == TIM11))? GPIO_AF3_TIM8: \
+
219// (((INSTANCE) == TIM12) || ((INSTANCE) == TIM13) || ((INSTANCE) == TIM14))? GPIO_AF9_TIM12: \
+
220// (0))
+
221
+
222
+
223/**
+
224 * @brief Маппинг альтернативной функции TIM между GPIO
+
225 * @ingroup MYLIBS_GPIO_GENERAL
+
226 */
+
227#define GPIO_TIM_Alternate_Mapping(INSTANCE) \
+
228((((INSTANCE) == TIM1) || ((INSTANCE) == TIM2))? GPIO_AF1_TIM1: \
+
229(((INSTANCE) == TIM3) || ((INSTANCE) == TIM4) || ((INSTANCE) == TIM5))? GPIO_AF2_TIM3: \
+
230(((INSTANCE) == TIM8) || ((INSTANCE) == TIM9) || ((INSTANCE) == TIM10) || ((INSTANCE) == TIM11))? GPIO_AF3_TIM8: \
+
231(((INSTANCE) == TIM12) || ((INSTANCE) == TIM13) || ((INSTANCE) == TIM14))? GPIO_AF9_TIM12: \
+
232(0))
+
233
+
234
+
235/** @endcond */
+
236
+
237#endif // __GPIO_GENERAL_H_
HAL_StatusTypeDef GPIO_Clock_Enable(GPIO_TypeDef *GPIOx)
Включить тактирование порта GPIO.
HAL_StatusTypeDef GPIO_LED_On(GPIO_LEDTypeDef *led)
Включить светодиод
HAL_StatusTypeDef GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period)
Активировать моргание светодиодом
-
GPIO_LEDStateTypeDef
Режимы работы светодиода
+
GPIO_LEDStateTypeDef
Режимы работы светодиода
HAL_StatusTypeDef GPIO_LED_Off(GPIO_LEDTypeDef *led)
Выключить светодиод
HAL_StatusTypeDef GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State)
Инициализировать светодиод (структуру светодиода)
void GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led)
Управление динамическими режимами свечения светодиода
HAL_StatusTypeDef GPIO_LED_Set(GPIO_LEDTypeDef *led, uint8_t led_state)
Выставить светодиод по переменной
HAL_StatusTypeDef GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period)
Активировать моргание светодиодом
-
@ LED_IS_BLINKING
Моргание светодиодом
-
@ LED_IS_OFF
Светодиод выключен
-
@ LED_IS_FADING
Плавное моргание светодиодом
-
@ LED_IS_ON
Светодиод включен
+
@ LED_IS_BLINKING
Моргание светодиодом
+
@ LED_IS_OFF
Светодиод выключен
+
@ LED_IS_FADING
Плавное моргание светодиодом
+
@ LED_IS_ON
Светодиод включен
int GPIO_Read_Switch(GPIO_SwitchTypeDef *swstart)
Считать состоянии кнопки
HAL_StatusTypeDef GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State)
Инициализировать кнопку (структуру кнопки)
Заголочный файл для дефайнов библиотеки MyLibsGeneral.
-
Структура светодиода
-
uint32_t LED_Pin
GPIO пин ножки светодиода
-
uint32_t LED_Period
Период моргания светодиода
-
GPIO_TypeDef * LED_Port
GPIO порт ножки светодиода
-
uint8_t LED_ActiveLvl
Активный уровень ножки (при котором светодиод горит)
-
GPIO_LEDStateTypeDef state
Текущий режим работы светодиода
-
Структура кнопки
-
uint32_t Sw_PrevState
Предыдущее состояние кнопки
-
uint32_t Sw_FilterDelay
Фильтр от дребезга (в мс)
-
uint8_t Sw_ActiveLvl
Активный уровень ножки (при котором кнопка нажата)
-
uint32_t Sw_Pin
GPIO пин ножки кнопки
-
GPIO_TypeDef * Sw_Port
GPIO порт ножки кнопки
+
Структура светодиода
+
uint32_t LED_Pin
GPIO пин ножки светодиода
+
uint32_t LED_Period
Период моргания светодиода
+
GPIO_TypeDef * LED_Port
GPIO порт ножки светодиода
+
uint8_t LED_ActiveLvl
Активный уровень ножки (при котором светодиод горит)
+
GPIO_LEDStateTypeDef state
Текущий режим работы светодиода
+
Структура кнопки
+
uint32_t Sw_PrevState
Предыдущее состояние кнопки
+
uint32_t Sw_FilterDelay
Фильтр от дребезга (в мс)
+
uint8_t Sw_ActiveLvl
Активный уровень ножки (при котором кнопка нажата)
+
uint32_t Sw_Pin
GPIO пин ножки кнопки
+
GPIO_TypeDef * Sw_Port
GPIO порт ножки кнопки
+
diff --git a/Doc/html/general__tim_8c.html b/Doc/html/general__tim_8c.html index bd4d793..bc889a7 100644 --- a/Doc/html/general__tim_8c.html +++ b/Doc/html/general__tim_8c.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Src/general_tim.c File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Src/general_tim.c File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
- + + @@ -73,10 +71,9 @@ $(function() { +
-
general_tim.c File Reference
@@ -109,67 +104,55 @@ $(function(){initNavTree('general__tim_8c.html',''); initResizable(); });

Модуль для инициализации таймеров и работы с ними. More...

#include "general_tim.h"
-
- + Include dependency graph for general_tim.c:
+
Include dependency graph for general_tim.c:

Go to the source code of this file.

- - - - - - - - - - - -

+

Functions

HAL_StatusTypeDef TIM_Base_Init (TIM_SettingsTypeDef *stim)
 Инициализация таймера.
 
HAL_StatusTypeDef TIM_Encoder_Init (TIM_EncoderTypeDef *henc, TIM_HandleTypeDef *htim)
 Инициализация режима энкодер у таймера.
 
HAL_StatusTypeDef TIM_Output_PWM_Init (TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN)
 Инициализация выхода ШИМ таймера.
 
HAL_StatusTypeDef TIM_OC_Comparator_Init (TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL)
 Инициализация OC компаратора таймера.
 
HAL_StatusTypeDef TIM_Encoder_Read (TIM_EncoderTypeDef *henc)
 Считать энкодер.
 
int TIM_Encoder_ReadSwitch (TIM_EncoderTypeDef *henc)
 Считать кнопку энкодера.
 
HAL_StatusTypeDef TIM_Delay (TIM_HandleTypeDef *htim, uint16_t delay)
 Задержка в тиках таймера (блокирующая).
 
HAL_StatusTypeDef TIM_Delay_Start (TIM_HandleTypeDef *htim)
 Начать отсчет неблокирующей задержки.
 
HAL_StatusTypeDef TIM_Delay_NonBlocking (TIM_HandleTypeDef *htim, uint16_t delay)
 Задержка в тиках таймера (неблокирующая).
 
void TIM_Base_MspInit (TIM_HandleTypeDef *htim, TIM_ITModeTypeDef it_mode)
 Инициализация CLK и NVIC таймеров.
 
void TIM_Base_MspDeInit (TIM_HandleTypeDef *htim)
 Деинициализация CLK и NVIC таймеров.
 
-

Detailed Description

+

Detailed Description

Модуль для инициализации таймеров и работы с ними.

Реализация функций для работы с TIM:

  • Инициализация таймера и его каналов
  • @@ -180,11 +163,19 @@ Functions

    Definition in file general_tim.c.

+ +
diff --git a/Doc/html/general__tim_8c__incl.map b/Doc/html/general__tim_8c__incl.map index c9dcd77..1096c09 100644 --- a/Doc/html/general__tim_8c__incl.map +++ b/Doc/html/general__tim_8c__incl.map @@ -1,14 +1,14 @@ - - - - - - - - - - - - - + + + + + + + + + + + + + diff --git a/Doc/html/general__tim_8c__incl.md5 b/Doc/html/general__tim_8c__incl.md5 index 7a3d6eb..b3c8500 100644 --- a/Doc/html/general__tim_8c__incl.md5 +++ b/Doc/html/general__tim_8c__incl.md5 @@ -1 +1 @@ -eb15c46347f395057c20d321276b7d03 \ No newline at end of file +b9386d564e6b4fd6c35f93b0536b2339 \ No newline at end of file diff --git a/Doc/html/general__tim_8c__incl.png b/Doc/html/general__tim_8c__incl.png index d4ca6a6..616abfe 100644 Binary files a/Doc/html/general__tim_8c__incl.png and b/Doc/html/general__tim_8c__incl.png differ diff --git a/Doc/html/general__tim_8c_source.html b/Doc/html/general__tim_8c_source.html index bc98ff1..9efe1e5 100644 --- a/Doc/html/general__tim_8c_source.html +++ b/Doc/html/general__tim_8c_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Src/general_tim.c Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Src/general_tim.c Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
- + + -
+
195 GPIO_InitStruct.Mode = GPIO_MODE_AF_PP;
196 GPIO_InitStruct.Pull = GPIO_PULLUP;
197 GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
-
198 GPIO_InitStruct.Alternate = GPIO_TIM_Alternate_Mapping(henc->htim->Instance);
+
198 GPIO_InitStruct.Alternate = GPIO_TIM_Alternate_Mapping(henc->htim->Instance);
199 if(GPIO_InitStruct.Alternate)
200 HAL_GPIO_Init(henc->GPIOx, &GPIO_InitStruct);
201
@@ -370,7 +362,7 @@ $(function(){initNavTree('general__tim_8c_source.html',''); initResizable(); });
255 else
256 GPIO_InitStruct.Pull = GPIO_PULLUP;
257 GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
-
258 GPIO_InitStruct.Alternate = GPIO_TIM_Alternate_Mapping(htim->Instance);
+
258 GPIO_InitStruct.Alternate = GPIO_TIM_Alternate_Mapping(htim->Instance);
259 if(GPIO_InitStruct.Alternate)
260 HAL_GPIO_Init(GPIOx, &GPIO_InitStruct);
261
@@ -531,7 +523,7 @@ $(function(){initNavTree('general__tim_8c_source.html',''); initResizable(); });
403 * @brief Инициализация CLK и NVIC таймеров.
404 * @param htim Указатель на хендл таймера.
405 * @note Чтобы не генерировать функцию с иницилизацией неиспользуемых таймеров,
-
406 дефайнами в general_tim.h определяются используемые таймеры.
+
406 дефайнами @ref TIM_INIT в @ref general_tim.h определяются используемые таймеры.
407 */
408void TIM_Base_MspInit(TIM_HandleTypeDef* htim, TIM_ITModeTypeDef it_mode)
@@ -742,7 +734,7 @@ $(function(){initNavTree('general__tim_8c_source.html',''); initResizable(); });
612 * @brief Деинициализация CLK и NVIC таймеров.
613 * @param htim Указатель на хендл таймера.
614 * @note Чтобы не генерировать функцию с деиницилизацией неиспользуемых таймеров,
-
615 дефайнами в general_tim.h определяются используемые таймеры.
+
615 дефайнами @ref TIM_INIT в @ref general_tim.h определяются используемые таймеры.
616 */
617void TIM_Base_MspDeInit(TIM_HandleTypeDef* htim)
@@ -857,7 +849,6 @@ $(function(){initNavTree('general__tim_8c_source.html',''); initResizable(); });
#define check_null_ptr_1(p1)
Проверить один указатель на NULL.
Definition mylibs_defs.h:38
#define check_null_ptr_3(p1, p2, p3)
Проверить три указателя на NULL.
Definition mylibs_defs.h:44
#define MyLibs_Error_Handler(params)
Error_Handler который будет вызыватся в библиотеке
Definition mylibs_defs.h:31
-
#define GPIO_TIM_Alternate_Mapping(INSTANCE)
Маппинг альтернативной функции TIM между GPIO.
HAL_StatusTypeDef GPIO_Clock_Enable(GPIO_TypeDef *GPIOx)
Включить тактирование порта GPIO.
int GPIO_Read_Switch(GPIO_SwitchTypeDef *swstart)
Считать состоянии кнопки
HAL_StatusTypeDef GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State)
Инициализировать кнопку (структуру кнопки)
@@ -870,37 +861,38 @@ $(function(){initNavTree('general__tim_8c_source.html',''); initResizable(); });
HAL_StatusTypeDef TIM_Base_Init(TIM_SettingsTypeDef *stim)
Инициализация таймера.
Definition general_tim.c:34
void TIM_Base_MspDeInit(TIM_HandleTypeDef *htim)
Деинициализация CLK и NVIC таймеров.
void TIM_Base_MspInit(TIM_HandleTypeDef *htim, TIM_ITModeTypeDef it_mode)
Инициализация CLK и NVIC таймеров.
-
TIM_ITModeTypeDef
Режим прерываний таймера
Definition general_tim.h:77
+
TIM_ITModeTypeDef
Режим прерываний таймера
Definition general_tim.h:78
HAL_StatusTypeDef TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN)
Инициализация выхода ШИМ таймера.
HAL_StatusTypeDef TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL)
Инициализация OC компаратора таймера.
-
Структура инициализации енкодера
-
TIM_Encoder_InitTypeDef sConfig
Указатель на структуру настройки энкодера
-
uint16_t Encoder_Shdw
Последние считанные тики
-
uint32_t GPIO_PIN_TI1
Пин, куда подключается канал TI1.
-
uint32_t GPIO_PIN_TI2
Пин, куда подключается канал TI2.
-
uint32_t GPIO_PIN_SW
Пин, куда кнопка энкодера (если есть)
-
int16_t Encoder_Diff
Считанная разница
-
GPIO_SwitchTypeDef Sw
Структура кнопки
-
GPIO_TypeDef * GPIOx
Порт, куда подключается энкодер
-
TIM_HandleTypeDef * htim
Указатель на HAL handle таймера
-
Структура инициализации таймера
-
uint8_t sTickBasePrescaler
Дополнительный делитель, для удобного деления sTickBaseUS.
-
TIM_MasterConfigTypeDef sMasterConfig
Настройки мастер режима таймера
-
TIM_ClockConfigTypeDef sClockSourceConfig
Настройки тактирования таймера
-
TIM_MHzTickBaseTypeDef sTickBaseUS
Длительность одного тика
-
float sTimAHBFreqMHz
Частота шины тактирования таймера
-
TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig
Настройки дедтаймов таймера
-
TIM_SlaveConfigTypeDef sSlaveConfig
Настройки слейв режима таймера
-
TIM_ITModeTypeDef sTimMode
Настройки прерывания таймера
-
TIM_HandleTypeDef htim
HAL handle таймера
-
float sTimFreqHz
Желаемая частота таймера
+
Структура инициализации енкодера
+
TIM_Encoder_InitTypeDef sConfig
Указатель на структуру настройки энкодера
+
uint16_t Encoder_Shdw
Последние считанные тики
+
uint32_t GPIO_PIN_TI1
Пин, куда подключается канал TI1.
+
uint32_t GPIO_PIN_TI2
Пин, куда подключается канал TI2.
+
uint32_t GPIO_PIN_SW
Пин, куда кнопка энкодера (если есть)
+
int16_t Encoder_Diff
Считанная разница
+
GPIO_SwitchTypeDef Sw
Структура кнопки
+
GPIO_TypeDef * GPIOx
Порт, куда подключается энкодер
+
TIM_HandleTypeDef * htim
Указатель на HAL handle таймера
+
Структура инициализации таймера
+
uint8_t sTickBasePrescaler
Дополнительный делитель, для удобного деления sTickBaseUS.
+
TIM_MasterConfigTypeDef sMasterConfig
Настройки мастер режима таймера
+
TIM_ClockConfigTypeDef sClockSourceConfig
Настройки тактирования таймера
+
TIM_MHzTickBaseTypeDef sTickBaseUS
Длительность одного тика
+
float sTimAHBFreqMHz
Частота шины тактирования таймера
+
TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig
Настройки дедтаймов таймера
+
TIM_SlaveConfigTypeDef sSlaveConfig
Настройки слейв режима таймера
+
TIM_ITModeTypeDef sTimMode
Настройки прерывания таймера
+
TIM_HandleTypeDef htim
HAL handle таймера
+
float sTimFreqHz
Желаемая частота таймера
+
diff --git a/Doc/html/general__tim_8h.html b/Doc/html/general__tim_8h.html index 02f3cb8..eb1d4bc 100644 --- a/Doc/html/general__tim_8h.html +++ b/Doc/html/general__tim_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_tim.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_tim.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
-
general_tim.h File Reference
@@ -113,109 +105,87 @@ $(function(){initNavTree('general__tim_8h.html',''); initResizable(); }); More...

#include "mylibs_defs.h"
#include "general_gpio.h"
-
- + Include dependency graph for general_tim.h:
+
Include dependency graph for general_tim.h:
-
- + This graph shows which files directly or indirectly include this file:
+
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

- - + - - + -

+

Classes

struct  TIM_SettingsTypeDef
struct  TIM_SettingsTypeDef
 Структура инициализации таймера More...
 
struct  TIM_EncoderTypeDef
struct  TIM_EncoderTypeDef
 Структура инициализации енкодера More...
 
- - - - - - - - - - - - - - - - - -

+

Macros

#define HAL_TIM_MODULE_ENABLED
 
#define USE_TIM1
 Включить TIM1 в TIM_Base_MspInit.
 
#define USE_TIM2
 Включить TIM2 в TIM_Base_MspInit.
 
#define USE_TIM3
 Включить TIM3 в TIM_Base_MspInit.
 
#define USE_TIM4
 Включить TIM4 в TIM_Base_MspInit.
 
#define USE_TIM5
 Включить TIM5 в TIM_Base_MspInit.
 
#define USE_TIM6
 Включить TIM6 в TIM_Base_MspInit.
 
#define USE_TIM7
 Включить TIM7 в TIM_Base_MspInit.
 
#define USE_TIM8
 Включить TIM8 в TIM_Base_MspInit.
 
#define USE_TIM9
 Включить TIM9 в TIM_Base_MspInit.
 
#define USE_TIM10
 Включить TIM10 в TIM_Base_MspInit.
 
#define USE_TIM11
 Включить TIM11 в TIM_Base_MspInit.
 
#define USE_TIM12
 Включить TIM12 в TIM_Base_MspInit.
 
#define USE_TIM13
 Включить TIM13 в TIM_Base_MspInit.
 
#define USE_TIM14
 Включить TIM14 в TIM_Base_MspInit.
 
#define TIM_IT_CONF_Pos   0
 
#define TIM_IT_CONF   (1<<(TIM_IT_CONF_Pos))
 
- -
} -

+

Enumerations

enum  TIM_ITModeTypeDef { TIM_DEFAULT = 0 , TIM_IT_MODE = (1<<( 0 )) }
 Режим прерываний таймера More...
 
enum  TIM_MHzTickBaseTypeDef {
  TIM_Base_Disable = 0 , TIM_TickBase_1US = 1 @@ -228,49 +198,37 @@ Enumerations
 Длительность тика таймера (частота тактирования таймера) More...
 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + +

+

Functions

HAL_StatusTypeDef TIM_Output_PWM_Init (TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN)
 Инициализация выхода ШИМ таймера.
 
HAL_StatusTypeDef TIM_OC_Comparator_Init (TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL)
 Инициализация OC компаратора таймера.
 
HAL_StatusTypeDef TIM_Encoder_Init (TIM_EncoderTypeDef *henc1, TIM_HandleTypeDef *htim)
 Инициализация режима энкодер у таймера.
 
HAL_StatusTypeDef TIM_Encoder_Read (TIM_EncoderTypeDef *henc)
 Считать энкодер.
 
int TIM_Encoder_ReadSwitch (TIM_EncoderTypeDef *henc)
 Считать кнопку энкодера.
 
HAL_StatusTypeDef TIM_Delay_Start (TIM_HandleTypeDef *htim)
 Начать отсчет неблокирующей задержки.
 
HAL_StatusTypeDef TIM_Delay (TIM_HandleTypeDef *htim, uint16_t delay)
 Задержка в тиках таймера (блокирующая).
 
HAL_StatusTypeDef TIM_Delay_NonBlocking (TIM_HandleTypeDef *htim, uint16_t delay)
 Задержка в тиках таймера (неблокирующая).
 
HAL_StatusTypeDef TIM_Base_Init (TIM_SettingsTypeDef *stim)
 Инициализация таймера.
 
void TIM_Base_MspInit (TIM_HandleTypeDef *htim, TIM_ITModeTypeDef it_mode)
 Инициализация CLK и NVIC таймеров.
 
void TIM_Base_MspDeInit (TIM_HandleTypeDef *htim)
 Деинициализация CLK и NVIC таймеров.
 
HAL_StatusTypeDef TIM_Delay_Start (TIM_HandleTypeDef *htim)
 Начать отсчет неблокирующей задержки.
HAL_StatusTypeDef TIM_Delay (TIM_HandleTypeDef *htim, uint16_t delay)
 Задержка в тиках таймера (блокирующая).
HAL_StatusTypeDef TIM_Delay_NonBlocking (TIM_HandleTypeDef *htim, uint16_t delay)
 Задержка в тиках таймера (неблокирующая).
HAL_StatusTypeDef TIM_Output_PWM_Init (TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN)
 Инициализация выхода ШИМ таймера.
HAL_StatusTypeDef TIM_OC_Comparator_Init (TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL)
 Инициализация OC компаратора таймера.
HAL_StatusTypeDef TIM_Encoder_Init (TIM_EncoderTypeDef *henc1, TIM_HandleTypeDef *htim)
 Инициализация режима энкодер у таймера.
HAL_StatusTypeDef TIM_Encoder_Read (TIM_EncoderTypeDef *henc)
 Считать энкодер.
int TIM_Encoder_ReadSwitch (TIM_EncoderTypeDef *henc)
 Считать кнопку энкодера.
-

Detailed Description

+

Detailed Description

Заголовочный файл для модуля инициализации таймеров и работы с ними.

Definition in file general_tim.h.

-

Macro Definition Documentation

+

Macro Definition Documentation

◆ TIM_IT_CONF_Pos

@@ -283,7 +241,7 @@ Functions
-

Definition at line 56 of file general_tim.h.

+

Definition at line 57 of file general_tim.h.

@@ -299,17 +257,25 @@ Functions
-

Definition at line 63 of file general_tim.h.

+

Definition at line 64 of file general_tim.h.

+ + diff --git a/Doc/html/general__tim_8h.js b/Doc/html/general__tim_8h.js index babcffb..d72435a 100644 --- a/Doc/html/general__tim_8h.js +++ b/Doc/html/general__tim_8h.js @@ -27,15 +27,15 @@ var general__tim_8h = [ "TIM_TickBase_10MS", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a7421a08abd119e71aa99eea5ab5d6daa", null ], [ "TIM_TickBase_100MS", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a18527a2d781eb4365aecd9a3184fc1da", null ] ] ], + [ "TIM_Base_Init", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga7044214f24a9868ba7e1650b55e639ec", null ], + [ "TIM_Base_MspInit", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaad47337be7ba2f6c0777c40d7278c931", null ], + [ "TIM_Base_MspDeInit", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga879e3f1c919c02990736730275367115", null ], + [ "TIM_Delay_Start", "group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga4c0dfde4e15f677600605348b4e97834", null ], + [ "TIM_Delay", "group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga88c552a133cb6e3015453cccab74c07e", null ], + [ "TIM_Delay_NonBlocking", "group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga108637af414bff3373059273b815ce9b", null ], [ "TIM_Output_PWM_Init", "group___m_y_l_i_b_s___t_i_m___o_c.html#gadb2f465d89f609e035867e980c3a29c6", null ], [ "TIM_OC_Comparator_Init", "group___m_y_l_i_b_s___t_i_m___o_c.html#gae2608ca8023e9a0713af0b4fbfbc1889", null ], [ "TIM_Encoder_Init", "group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc", null ], [ "TIM_Encoder_Read", "group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#gac3bc6525f88c275e47eb864e6d567501", null ], - [ "TIM_Encoder_ReadSwitch", "group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga117b795017e9e3a357ddefe323412761", null ], - [ "TIM_Delay_Start", "group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga4c0dfde4e15f677600605348b4e97834", null ], - [ "TIM_Delay", "group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga88c552a133cb6e3015453cccab74c07e", null ], - [ "TIM_Delay_NonBlocking", "group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga108637af414bff3373059273b815ce9b", null ], - [ "TIM_Base_Init", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga7044214f24a9868ba7e1650b55e639ec", null ], - [ "TIM_Base_MspInit", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaad47337be7ba2f6c0777c40d7278c931", null ], - [ "TIM_Base_MspDeInit", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga879e3f1c919c02990736730275367115", null ] + [ "TIM_Encoder_ReadSwitch", "group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga117b795017e9e3a357ddefe323412761", null ] ]; \ No newline at end of file diff --git a/Doc/html/general__tim_8h__dep__incl.map b/Doc/html/general__tim_8h__dep__incl.map index 3dcd765..e76bc39 100644 --- a/Doc/html/general__tim_8h__dep__incl.map +++ b/Doc/html/general__tim_8h__dep__incl.map @@ -1,7 +1,7 @@ - - - - - - + + + + + + diff --git a/Doc/html/general__tim_8h__dep__incl.md5 b/Doc/html/general__tim_8h__dep__incl.md5 index 2434b2c..abe2711 100644 --- a/Doc/html/general__tim_8h__dep__incl.md5 +++ b/Doc/html/general__tim_8h__dep__incl.md5 @@ -1 +1 @@ -74541afe89b6c16b8591605dc764fc98 \ No newline at end of file +44714191f83fa51a72cbc1377ffdbdff \ No newline at end of file diff --git a/Doc/html/general__tim_8h__dep__incl.png b/Doc/html/general__tim_8h__dep__incl.png index 6bb7cd8..c7c1671 100644 Binary files a/Doc/html/general__tim_8h__dep__incl.png and b/Doc/html/general__tim_8h__dep__incl.png differ diff --git a/Doc/html/general__tim_8h__incl.map b/Doc/html/general__tim_8h__incl.map index 21eca5a..ee3bd57 100644 --- a/Doc/html/general__tim_8h__incl.map +++ b/Doc/html/general__tim_8h__incl.map @@ -1,12 +1,12 @@ - - - - - - - - - - - + + + + + + + + + + + diff --git a/Doc/html/general__tim_8h__incl.md5 b/Doc/html/general__tim_8h__incl.md5 index d78e9c9..c5ffabb 100644 --- a/Doc/html/general__tim_8h__incl.md5 +++ b/Doc/html/general__tim_8h__incl.md5 @@ -1 +1 @@ -8ec1d8e42b4cabc9ae1262ea0306324b \ No newline at end of file +8d2ac3de78aaeedbad6de045ad16b161 \ No newline at end of file diff --git a/Doc/html/general__tim_8h__incl.png b/Doc/html/general__tim_8h__incl.png index 481c01c..ac28d97 100644 Binary files a/Doc/html/general__tim_8h__incl.png and b/Doc/html/general__tim_8h__incl.png differ diff --git a/Doc/html/general__tim_8h_source.html b/Doc/html/general__tim_8h_source.html index 5f30512..d716fed 100644 --- a/Doc/html/general__tim_8h_source.html +++ b/Doc/html/general__tim_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_tim.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_tim.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({ - + + -
+
12 - @ref MYLIBS_TIM_DELAY — функции задержки через таймеры (blocking и non-blocking).
13 - @ref MYLIBS_TIM_OC — настройка каналов Output Compare и PWM.
14 - @ref MYLIBS_TIM_ENCODER — работа с энкодерами, чтение положения и кнопки.
-
15* @note Требуется подключение модуля TIM в библиотеке HAL
-
16@code
-
17#define HAL_TIM_MODULE_ENABLED
-
18@endcode
-
19*************************************************************************/
-
20#ifndef __TIM_GENERAL_H_
-
21#define __TIM_GENERAL_H_
-
22
-
23/////////////////////////////////////////////////////////////////////
-
24/////////////////////////---USER SETTINGS---/////////////////////////
-
25/**
-
26 * @addtogroup TIM_INIT Init defines
-
27 * @ingroup MYLIBS_TIM_GENERAL
-
28 * @brief Настройка таймеров
-
29 * @{
-
30 */
-
31#define HAL_TIM_MODULE_ENABLED
-
32
-
33#define USE_TIM1 ///< Включить TIM1 в @ref TIM_Base_MspInit
-
34#define USE_TIM2 ///< Включить TIM2 в @ref TIM_Base_MspInit
-
35#define USE_TIM3 ///< Включить TIM3 в @ref TIM_Base_MspInit
-
36#define USE_TIM4 ///< Включить TIM4 в @ref TIM_Base_MspInit
-
37#define USE_TIM5 ///< Включить TIM5 в @ref TIM_Base_MspInit
-
38#define USE_TIM6 ///< Включить TIM6 в @ref TIM_Base_MspInit
-
39#define USE_TIM7 ///< Включить TIM7 в @ref TIM_Base_MspInit
-
40#define USE_TIM8 ///< Включить TIM8 в @ref TIM_Base_MspInit
-
41#define USE_TIM9 ///< Включить TIM9 в @ref TIM_Base_MspInit
-
42#define USE_TIM10 ///< Включить TIM10 в @ref TIM_Base_MspInit
-
43#define USE_TIM11 ///< Включить TIM11 в @ref TIM_Base_MspInit
-
44#define USE_TIM12 ///< Включить TIM12 в @ref TIM_Base_MspInit
-
45#define USE_TIM13 ///< Включить TIM13 в @ref TIM_Base_MspInit
-
46#define USE_TIM14 ///< Включить TIM14 в @ref TIM_Base_MspInit
-
47/** TIM_INIT
-
48 * @}
-
49 */
-
50/////////////////////////---USER SETTINGS---/////////////////////////
-
51#include "mylibs_defs.h"
-
52#include "general_gpio.h"
-
53
-
54/////////////////////////////////////////////////////////////////////
-
55////////////////////////////---DEFINES---////////////////////////////
-
56#define TIM_IT_CONF_Pos 0
-
57//#define TIM_PWM_CONF_Pos 1
-
58//#define TIM_CLCK_SRC_CONF_Pos 2
-
59//#define TIM_SLAVE_CONF_Pos 3
-
60//#define TIM_MASTER_CONF_Pos 4
-
61//#define TIM_BDTR_CONF_Pos 5
-
62
-
63#define TIM_IT_CONF (1<<(TIM_IT_CONF_Pos))
-
64//#define TIM_PWM_CONF (1<<(TIM_PWM_Pos))
-
65
-
66////////////////////////////---DEFINES---////////////////////////////]
-
67
+
15
+
16* @note Требуется подключение модуля TIM в библиотеке HAL и GPIO (@ref MY_LIBS_GPIO) из MyLibs
+
17@code
+
18#define HAL_TIM_MODULE_ENABLED
+
19@endcode
+
20*************************************************************************/
+
21#ifndef __TIM_GENERAL_H_
+
22#define __TIM_GENERAL_H_
+
23
+
24/////////////////////////////////////////////////////////////////////
+
25/////////////////////////---USER SETTINGS---/////////////////////////
+
26/**
+
27 * @addtogroup TIM_INIT Init defines
+
28 * @ingroup MYLIBS_TIM_GENERAL
+
29 * @brief Настройка таймеров
+
30 * @{
+
31 */
+
32#define HAL_TIM_MODULE_ENABLED
+
33
+
34#define USE_TIM1 ///< Включить TIM1 в @ref TIM_Base_MspInit
+
35#define USE_TIM2 ///< Включить TIM2 в @ref TIM_Base_MspInit
+
36#define USE_TIM3 ///< Включить TIM3 в @ref TIM_Base_MspInit
+
37#define USE_TIM4 ///< Включить TIM4 в @ref TIM_Base_MspInit
+
38#define USE_TIM5 ///< Включить TIM5 в @ref TIM_Base_MspInit
+
39#define USE_TIM6 ///< Включить TIM6 в @ref TIM_Base_MspInit
+
40#define USE_TIM7 ///< Включить TIM7 в @ref TIM_Base_MspInit
+
41#define USE_TIM8 ///< Включить TIM8 в @ref TIM_Base_MspInit
+
42#define USE_TIM9 ///< Включить TIM9 в @ref TIM_Base_MspInit
+
43#define USE_TIM10 ///< Включить TIM10 в @ref TIM_Base_MspInit
+
44#define USE_TIM11 ///< Включить TIM11 в @ref TIM_Base_MspInit
+
45#define USE_TIM12 ///< Включить TIM12 в @ref TIM_Base_MspInit
+
46#define USE_TIM13 ///< Включить TIM13 в @ref TIM_Base_MspInit
+
47#define USE_TIM14 ///< Включить TIM14 в @ref TIM_Base_MspInit
+
48/** TIM_INIT
+
49 * @}
+
50 */
+
51/////////////////////////---USER SETTINGS---/////////////////////////
+
52#include "mylibs_defs.h"
+
53#include "general_gpio.h"
+
54
+
55/////////////////////////////////////////////////////////////////////
+
56////////////////////////////---DEFINES---////////////////////////////
+
57#define TIM_IT_CONF_Pos 0
+
58//#define TIM_PWM_CONF_Pos 1
+
59//#define TIM_CLCK_SRC_CONF_Pos 2
+
60//#define TIM_SLAVE_CONF_Pos 3
+
61//#define TIM_MASTER_CONF_Pos 4
+
62//#define TIM_BDTR_CONF_Pos 5
+
63
+
64#define TIM_IT_CONF (1<<(TIM_IT_CONF_Pos))
+
65//#define TIM_PWM_CONF (1<<(TIM_PWM_Pos))
+
66
+
67////////////////////////////---DEFINES---////////////////////////////]
68
-
69
-
70/////////////////////////////////////////////////////////////////////
-
71///////////////////////---STRUCTURES & ENUMS---//////////////////////
-
72/**
-
73 * @brief Режим прерываний таймера
-
74 * @ingroup MYLIBS_TIM_GENERAL
-
75 */
-
-
76typedef enum
-
77{
-
78 TIM_DEFAULT = 0, ///< Прерываний отключены
-
79 TIM_IT_MODE = TIM_IT_CONF, ///< Прерываний включены
-
80// TIM_PWM_MODE = TIM_PWM_ENABLE,
-
81// TIM_PWM_IT_MODE = TIM_PWM_ENABLE | TIM_IT_CONF,
- +
69
+
70
+
71/////////////////////////////////////////////////////////////////////
+
72///////////////////////---STRUCTURES & ENUMS---//////////////////////
+
73/**
+
74 * @brief Режим прерываний таймера
+
75 * @ingroup MYLIBS_TIM_GENERAL
+
76 */
+
+
77typedef enum
+
78{
+
79 TIM_DEFAULT = 0, ///< Прерываний отключены
+
80 TIM_IT_MODE = TIM_IT_CONF, ///< Прерываний включены
+
81// TIM_PWM_MODE = TIM_PWM_ENABLE,
+
82// TIM_PWM_IT_MODE = TIM_PWM_ENABLE | TIM_IT_CONF,
+
-
83
-
84/**
-
85 * @brief Длительность тика таймера (частота тактирования таймера)
-
86 * @ingroup MYLIBS_TIM_GENERAL
-
87 * @details enum дает базовые длительности, но можно выставить другие
-
88 * (напр 500 - 0.5 мс)
-
89 */
-
-
90typedef enum
-
91{
-
92 TIM_Base_Disable = 0, ///< Таймер отключен
-
93 TIM_TickBase_1US = 1, ///< Таймер тактируется с частотой 1 МГц
-
94 TIM_TickBase_10US = 10, ///< Таймер тактируется с частотой 100 кГц
-
95 TIM_TickBase_100US = 100, ///< Таймер тактируется с частотой 10 кГц
-
96 TIM_TickBase_1MS = 1000, ///< Таймер тактируется с частотой 1 кГц
-
97 TIM_TickBase_10MS = 10000, ///< Таймер тактируется с частотой 100 Гц
-
98 TIM_TickBase_100MS = 100000, ///< Таймер тактируется с частотой 10 Гц
- +
84
+
85/**
+
86 * @brief Длительность тика таймера (частота тактирования таймера)
+
87 * @ingroup MYLIBS_TIM_GENERAL
+
88 * @details enum дает базовые длительности, но можно выставить другие
+
89 * (напр 500 - 0.5 мс)
+
90 */
+
+
91typedef enum
+
92{
+
93 TIM_Base_Disable = 0, ///< Таймер отключен
+
94 TIM_TickBase_1US = 1, ///< Таймер тактируется с частотой 1 МГц
+
95 TIM_TickBase_10US = 10, ///< Таймер тактируется с частотой 100 кГц
+
96 TIM_TickBase_100US = 100, ///< Таймер тактируется с частотой 10 кГц
+
97 TIM_TickBase_1MS = 1000, ///< Таймер тактируется с частотой 1 кГц
+
98 TIM_TickBase_10MS = 10000, ///< Таймер тактируется с частотой 100 Гц
+
99 TIM_TickBase_100MS = 100000, ///< Таймер тактируется с частотой 10 Гц
+
-
100
-
101/**
-
102 * @brief Структура инициализации таймера
-
103 * @ingroup MYLIBS_TIM_GENERAL
-
104 * @details
-
105 * Содержит все базовые структуры, которые нужны для инициализации таймера.
-
106 * Если структуры настроек не заданы, то они заполнятся сами дефолтными параметрами
-
107 *
-
108 * Также высокоуровневые настройки частоты работы таймера.
-
109 * Если какая-либо высокоуровневая настройка не задана, то
-
110 * по возможности берется низкоуровневая настройка из структур
-
111 */
-
-
112typedef struct // struct with settings for custom function
-
113{
-
114 TIM_HandleTypeDef htim; ///< HAL handle таймера
-
115 TIM_ClockConfigTypeDef sClockSourceConfig; ///< Настройки тактирования таймера
-
116 TIM_SlaveConfigTypeDef sSlaveConfig; ///< Настройки слейв режима таймера
-
117 TIM_MasterConfigTypeDef sMasterConfig; ///< Настройки мастер режима таймера
-
118 TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig; ///< Настройки дедтаймов таймера
-
119
-
120 TIM_ITModeTypeDef sTimMode; ///< Настройки прерывания таймера
-
121 TIM_MHzTickBaseTypeDef sTickBaseUS; ///< Длительность одного тика
-
122 uint8_t sTickBasePrescaler; ///< Дополнительный делитель, для удобного деления @ref sTickBaseUS
-
123 float sTimAHBFreqMHz; ///< Частота шины тактирования таймера
-
124 float sTimFreqHz; ///< Желаемая частота таймера
-
125
- +
101
+
102/**
+
103 * @brief Структура инициализации таймера
+
104 * @ingroup MYLIBS_TIM_GENERAL
+
105 * @details
+
106 * Содержит все базовые структуры, которые нужны для инициализации таймера.
+
107 * Если структуры настроек не заданы, то они заполнятся сами дефолтными параметрами
+
108 *
+
109 * Также высокоуровневые настройки частоты работы таймера.
+
110 * Если какая-либо высокоуровневая настройка не задана, то
+
111 * по возможности берется низкоуровневая настройка из структур
+
112 */
+
+
113typedef struct // struct with settings for custom function
+
114{
+
115 TIM_HandleTypeDef htim; ///< HAL handle таймера
+
116 TIM_ClockConfigTypeDef sClockSourceConfig; ///< Настройки тактирования таймера
+
117 TIM_SlaveConfigTypeDef sSlaveConfig; ///< Настройки слейв режима таймера
+
118 TIM_MasterConfigTypeDef sMasterConfig; ///< Настройки мастер режима таймера
+
119 TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig; ///< Настройки дедтаймов таймера
+
120
+
121 TIM_ITModeTypeDef sTimMode; ///< Настройки прерывания таймера
+
122 TIM_MHzTickBaseTypeDef sTickBaseUS; ///< Длительность одного тика
+
123 uint8_t sTickBasePrescaler; ///< Дополнительный делитель, для удобного деления @ref sTickBaseUS
+
124 float sTimAHBFreqMHz; ///< Частота шины тактирования таймера
+
125 float sTimFreqHz; ///< Желаемая частота таймера
+
126
+
-
127
-
128
-
129/**
-
130 * @brief Структура инициализации енкодера
-
131 * @ingroup MYLIBS_TIM_ENCODER
-
132 * @details
-
133 * Содержит все базовые структуры, которые нужны для инициализации таймера.
-
134 * Если структуры настроек не заданы, то они заполнятся сами дефолтными параметрами
-
135 *
-
136 * Также высокоуровневые настройки частоты работы таймера.
-
137 * Если какая-либо высокоуровневая настройка не задана, то
-
138 * по возможности берется низкоуровневая настройка из структур
-
139 */
-
-
140typedef struct // struct with variables for encoder
-
141{
-
142 int16_t Encoder_Diff; ///< Считанная разница
-
143 uint16_t Encoder_Shdw; ///< Последние считанные тики
-
144
-
145 TIM_HandleTypeDef *htim; ///< Указатель на HAL handle таймера
-
146 TIM_Encoder_InitTypeDef sConfig; ///< Указатель на структуру настройки энкодера
-
147
-
148 GPIO_TypeDef *GPIOx; ///< Порт, куда подключается энкодер
-
149 uint32_t GPIO_PIN_TI1; ///< Пин, куда подключается канал TI1
-
150 uint32_t GPIO_PIN_TI2; ///< Пин, куда подключается канал TI2
-
151 uint32_t GPIO_PIN_SW; ///< Пин, куда кнопка энкодера (если есть)
-
152
-
153 GPIO_SwitchTypeDef Sw; ///< Структура кнопки
-
154
- +
128
+
129
+
130/**
+
131 * @brief Структура инициализации енкодера
+
132 * @ingroup MYLIBS_TIM_ENCODER
+
133 * @details
+
134 * Содержит все базовые структуры, которые нужны для инициализации таймера.
+
135 * Если структуры настроек не заданы, то они заполнятся сами дефолтными параметрами
+
136 *
+
137 * Также высокоуровневые настройки частоты работы таймера.
+
138 * Если какая-либо высокоуровневая настройка не задана, то
+
139 * по возможности берется низкоуровневая настройка из структур
+
140 */
+
+
141typedef struct // struct with variables for encoder
+
142{
+
143 int16_t Encoder_Diff; ///< Считанная разница
+
144 uint16_t Encoder_Shdw; ///< Последние считанные тики
+
145
+
146 TIM_HandleTypeDef *htim; ///< Указатель на HAL handle таймера
+
147 TIM_Encoder_InitTypeDef sConfig; ///< Указатель на структуру настройки энкодера
+
148
+
149 GPIO_TypeDef *GPIOx; ///< Порт, куда подключается энкодер
+
150 uint32_t GPIO_PIN_TI1; ///< Пин, куда подключается канал TI1
+
151 uint32_t GPIO_PIN_TI2; ///< Пин, куда подключается канал TI2
+
152 uint32_t GPIO_PIN_SW; ///< Пин, куда кнопка энкодера (если есть)
+
153
+
154 GPIO_SwitchTypeDef Sw; ///< Структура кнопки
+
155
+
-
156///////////////////////---STRUCTURES & ENUMS---//////////////////////
-
157
-
158/////////////////////////////////////////////////////////////////////
-
159///////////////////////////---FUNCTIONS---///////////////////////////
-
160/**
-
161 * @addtogroup MYLIBS_TIM_OC PWM/OC Channels tools
-
162 * @ingroup MY_LIBS_TIM
-
163 * @brief Функции для инициализации базовых функций каналов таймера
-
164 * @{
-
165 */
-
166/* Initialize PWM Channel and GPIO for output */
-
167HAL_StatusTypeDef TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN);
-
168/* Initialize OC Comparator */
-
169HAL_StatusTypeDef TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL);
-
170/** MYLIBS_TIM_ENCODER
-
171 * @}
-
172 */
-
173
-
174/**
-
175 * @addtogroup MYLIBS_TIM_ENCODER Encoder tools
-
176 * @ingroup MY_LIBS_TIM
-
177 * @brief Функции для считывания энкодера
-
178 * @{
-
179 */
-
180/* Initialize TIM Encoder functional */
-
181HAL_StatusTypeDef TIM_Encoder_Init(TIM_EncoderTypeDef *henc1, TIM_HandleTypeDef *htim);
-
182/* Считать энкодер */
-
183HAL_StatusTypeDef TIM_Encoder_Read(TIM_EncoderTypeDef *henc);
-
184/* Считать кнопку энкодера */
- -
186/** MYLIBS_TIM_ENCODER
-
187 * @}
-
188 */
-
189
-
190/**
-
191 * @addtogroup MYLIBS_TIM_DELAY Delay tools
-
192 * @ingroup MY_LIBS_TIM
-
193 * @brief Функции для формирования задержек с помощью таймеров
-
194 * @{
+
157///////////////////////---STRUCTURES & ENUMS---//////////////////////
+
158
+
159/////////////////////////////////////////////////////////////////////
+
160///////////////////////////---FUNCTIONS---///////////////////////////
+
161/**
+
162 * @addtogroup MYLIBS_TIM_GENERAL General tools
+
163 * @ingroup MY_LIBS_TIM
+
164 * @brief Функции для базовой инициализации таймеров
+
165 * @par Пример использования:
+
166 @code
+
167 TIM_SettingsTypeDef tim2Settings;
+
168
+
169 void TIM2_Init(void)
+
170 {
+
171 // Настройка таймера TIM2 на 1 кГц с прерываниями с шагом таймера 10 мкс
+
172 tim2Settings.htim.Instance = TIM2;
+
173 tim2Settings.sTimMode = TIM_IT_MODE;
+
174 tim2Settings.sTickBaseUS = TIM_TickBase_10US;
+
175 tim2Settings.sTickBasePrescaler = 1;
+
176 tim2Settings.sTimFreqHz = 1000; // 1 кГц
+
177 tim2Settings.sTimAHBFreqMHz = 72000000; // Hz
+
178
+
179 if(TIM_Base_Init(&tim2Settings) != HAL_OK)
+
180 {
+
181 Error_Handler();
+
182 }
+
183 }
+
184 @endcode
+
185 * @{
+
186 */
+
187/* Initialize TIM with TIM_SettingsTypeDef structure */
+
188HAL_StatusTypeDef TIM_Base_Init(TIM_SettingsTypeDef* stim);
+
189/* Initialize TIMs clock and interrupt */
+
190void TIM_Base_MspInit(TIM_HandleTypeDef* htim, TIM_ITModeTypeDef it_mode);
+
191/* DeInitialize TIMs clock and interrupt */
+
192void TIM_Base_MspDeInit(TIM_HandleTypeDef* htim);
+
193/** MYLIBS_TIM_GENERAL
+
194 * @}
195 */
-
196/* Start delay via TIM */
-
197HAL_StatusTypeDef TIM_Delay_Start(TIM_HandleTypeDef *htim);
-
198/* Delay via TIM */
-
199HAL_StatusTypeDef TIM_Delay(TIM_HandleTypeDef *htim, uint16_t delay);
-
200/* Wait Delay via TIM without blocking app */
-
201HAL_StatusTypeDef TIM_Delay_NonBlocking(TIM_HandleTypeDef *htim, uint16_t delay);
-
202/** MYLIBS_TIM_DELAY
-
203 * @}
-
204 */
-
205
-
206/**
-
207 * @addtogroup MYLIBS_TIM_GENERAL General tools
-
208 * @ingroup MY_LIBS_TIM
-
209 * @brief Функции для базовой инициализации таймеров
-
210 * @{
-
211 */
-
212/* Initialize TIM with TIM_SettingsTypeDef structure */
-
213HAL_StatusTypeDef TIM_Base_Init(TIM_SettingsTypeDef* stim);
-
214/* Initialize TIMs clock and interrupt */
-
215void TIM_Base_MspInit(TIM_HandleTypeDef* htim, TIM_ITModeTypeDef it_mode);
-
216/* DeInitialize TIMs clock and interrupt */
-
217void TIM_Base_MspDeInit(TIM_HandleTypeDef* htim);
-
218/** MYLIBS_TIM_GENERAL
-
219 * @}
-
220 */
-
221///////////////////////////---FUNCTIONS---///////////////////////////
-
222
-
223
-
224#endif // __TIM_GENERAL_H_
+
196
+
197/**
+
198 * @addtogroup MYLIBS_TIM_DELAY Delay tools
+
199 * @ingroup MY_LIBS_TIM
+
200 * @brief Функции для формирования задержек с помощью таймеров
+
201 * @par Пример использования:
+
202 @code
+
203 TIM_HandleTypeDef htim2;
+
204
+
205 // блокирующая задержка 500 тиков таймера
+
206 LED_ON();
+
207 TIM_Delay(&htim2, 500);
+
208 LED_OFF();
+
209
+
210
+
211 while(1)
+
212 {
+
213 // не блокирующая задержка 200 тиков таймера
+
214 if(TIM_Delay_NonBlocking(&htim2, 200) == HAL_OK)
+
215 {
+
216 TIM_Delay_Start(&htim2);
+
217 LED_TOOGLE();
+
218 }
+
219 }
+
220 @endcode
+
221 * @{
+
222 */
+
223/* Start delay via TIM */
+
224HAL_StatusTypeDef TIM_Delay_Start(TIM_HandleTypeDef *htim);
+
225/* Delay via TIM */
+
226HAL_StatusTypeDef TIM_Delay(TIM_HandleTypeDef *htim, uint16_t delay);
+
227/* Wait Delay via TIM without blocking app */
+
228HAL_StatusTypeDef TIM_Delay_NonBlocking(TIM_HandleTypeDef *htim, uint16_t delay);
+
229/** MYLIBS_TIM_DELAY
+
230 * @}
+
231 */
+
232
+
233/**
+
234 * @addtogroup MYLIBS_TIM_OC PWM/OC Channels tools
+
235 * @ingroup MY_LIBS_TIM
+
236 * @brief Функции для инициализации базовых функций каналов таймера
+
237 * @par Пример использования:
+
238 @code
+
239 void PWM_Channel_Init_Example(void)
+
240 {
+
241 TIM_HandleTypeDef htim3;
+
242 TIM_OC_InitTypeDef sConfigOC;
+
243 GPIO_TypeDef *GPIOx = GPIOB;
+
244 uint32_t PWM_PIN = GPIO_PIN_0;
+
245
+
246 // Настройка таймера и канала PWM
+
247 TIM_Output_PWM_Init(&htim3, &sConfigOC, TIM_CHANNEL_1, GPIOx, PWM_PIN);
+
248
+
249 // Настройка компаратора OC
+
250 TIM_OC_Comparator_Init(&htim3, TIM_CHANNEL_1);
+
251 }
+
252 @endcode
+
253 * @{
+
254 */
+
255/* Initialize PWM Channel and GPIO for output */
+
256HAL_StatusTypeDef TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN);
+
257/* Initialize OC Comparator */
+
258HAL_StatusTypeDef TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL);
+
259/** MYLIBS_TIM_ENCODER
+
260 * @}
+
261 */
+
262
+
263/**
+
264 * @addtogroup MYLIBS_TIM_ENCODER Encoder tools
+
265 * @ingroup MY_LIBS_TIM
+
266 * @brief Функции для считывания энкодера
+
267 * @par Пример использования:
+
268 @code
+
269 TIM_EncoderTypeDef henc1;
+
270 TIM_HandleTypeDef htim4;
+
271
+
272 // инициализация
+
273 henc1.htim = &htim4;
+
274 henc1.GPIOx = GPIOA;
+
275 henc1.GPIO_PIN_TI1 = GPIO_PIN_0;
+
276 henc1.GPIO_PIN_TI2 = GPIO_PIN_1;
+
277 TIM_Encoder_Init(&henc1, &htim4);
+
278
+
279 // считывание энкодера и кнопки
+
280 int16_t delta = TIM_Encoder_Read(&henc1);
+
281 setpoint_tmp += delta;
+
282 if(TIM_Encoder_ReadSwitch(&henc1))
+
283 {
+
284 setpoint = setpoint_tmp; // подтвердить новое значение
+
285 }
+
286 @endcode
+
287 * @{
+
288 */
+
289/* Initialize TIM Encoder functional */
+
290HAL_StatusTypeDef TIM_Encoder_Init(TIM_EncoderTypeDef *henc1, TIM_HandleTypeDef *htim);
+
291/* Считать энкодер */
+
292HAL_StatusTypeDef TIM_Encoder_Read(TIM_EncoderTypeDef *henc);
+
293/* Считать кнопку энкодера */
+ +
295/** MYLIBS_TIM_ENCODER
+
296 * @}
+
297 */
+
298///////////////////////////---FUNCTIONS---///////////////////////////
+
299
+
300
+
301#endif // __TIM_GENERAL_H_
Заголовочный файл для модуля инициализации портов и работы с ними.
HAL_StatusTypeDef TIM_Delay_NonBlocking(TIM_HandleTypeDef *htim, uint16_t delay)
Задержка в тиках таймера (неблокирующая).
HAL_StatusTypeDef TIM_Delay_Start(TIM_HandleTypeDef *htim)
Начать отсчет неблокирующей задержки.
@@ -349,50 +418,51 @@ $(function(){initNavTree('general__tim_8h_source.html',''); initResizable(); });
HAL_StatusTypeDef TIM_Encoder_Read(TIM_EncoderTypeDef *henc)
Считать энкодер.
HAL_StatusTypeDef TIM_Base_Init(TIM_SettingsTypeDef *stim)
Инициализация таймера.
Definition general_tim.c:34
void TIM_Base_MspDeInit(TIM_HandleTypeDef *htim)
Деинициализация CLK и NVIC таймеров.
-
TIM_MHzTickBaseTypeDef
Длительность тика таймера (частота тактирования таймера)
Definition general_tim.h:91
+
TIM_MHzTickBaseTypeDef
Длительность тика таймера (частота тактирования таймера)
Definition general_tim.h:92
void TIM_Base_MspInit(TIM_HandleTypeDef *htim, TIM_ITModeTypeDef it_mode)
Инициализация CLK и NVIC таймеров.
-
TIM_ITModeTypeDef
Режим прерываний таймера
Definition general_tim.h:77
-
@ TIM_TickBase_10US
Таймер тактируется с частотой 100 кГц
Definition general_tim.h:94
-
@ TIM_TickBase_100US
Таймер тактируется с частотой 10 кГц
Definition general_tim.h:95
-
@ TIM_TickBase_100MS
Таймер тактируется с частотой 10 Гц
Definition general_tim.h:98
-
@ TIM_TickBase_1US
Таймер тактируется с частотой 1 МГц
Definition general_tim.h:93
-
@ TIM_TickBase_1MS
Таймер тактируется с частотой 1 кГц
Definition general_tim.h:96
-
@ TIM_TickBase_10MS
Таймер тактируется с частотой 100 Гц
Definition general_tim.h:97
-
@ TIM_Base_Disable
Таймер отключен
Definition general_tim.h:92
-
@ TIM_IT_MODE
Прерываний включены
Definition general_tim.h:79
-
@ TIM_DEFAULT
Прерываний отключены
Definition general_tim.h:78
+
TIM_ITModeTypeDef
Режим прерываний таймера
Definition general_tim.h:78
+
@ TIM_TickBase_10US
Таймер тактируется с частотой 100 кГц
Definition general_tim.h:95
+
@ TIM_TickBase_100US
Таймер тактируется с частотой 10 кГц
Definition general_tim.h:96
+
@ TIM_TickBase_100MS
Таймер тактируется с частотой 10 Гц
Definition general_tim.h:99
+
@ TIM_TickBase_1US
Таймер тактируется с частотой 1 МГц
Definition general_tim.h:94
+
@ TIM_TickBase_1MS
Таймер тактируется с частотой 1 кГц
Definition general_tim.h:97
+
@ TIM_TickBase_10MS
Таймер тактируется с частотой 100 Гц
Definition general_tim.h:98
+
@ TIM_Base_Disable
Таймер отключен
Definition general_tim.h:93
+
@ TIM_IT_MODE
Прерываний включены
Definition general_tim.h:80
+
@ TIM_DEFAULT
Прерываний отключены
Definition general_tim.h:79
HAL_StatusTypeDef TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN)
Инициализация выхода ШИМ таймера.
HAL_StatusTypeDef TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL)
Инициализация OC компаратора таймера.
Заголочный файл для дефайнов библиотеки MyLibsGeneral.
-
Структура кнопки
-
Структура инициализации енкодера
-
TIM_Encoder_InitTypeDef sConfig
Указатель на структуру настройки энкодера
-
uint16_t Encoder_Shdw
Последние считанные тики
-
uint32_t GPIO_PIN_TI1
Пин, куда подключается канал TI1.
-
uint32_t GPIO_PIN_TI2
Пин, куда подключается канал TI2.
-
uint32_t GPIO_PIN_SW
Пин, куда кнопка энкодера (если есть)
-
int16_t Encoder_Diff
Считанная разница
-
GPIO_SwitchTypeDef Sw
Структура кнопки
-
GPIO_TypeDef * GPIOx
Порт, куда подключается энкодер
-
TIM_HandleTypeDef * htim
Указатель на HAL handle таймера
-
Структура инициализации таймера
-
uint8_t sTickBasePrescaler
Дополнительный делитель, для удобного деления sTickBaseUS.
-
TIM_MasterConfigTypeDef sMasterConfig
Настройки мастер режима таймера
-
TIM_ClockConfigTypeDef sClockSourceConfig
Настройки тактирования таймера
-
TIM_MHzTickBaseTypeDef sTickBaseUS
Длительность одного тика
-
float sTimAHBFreqMHz
Частота шины тактирования таймера
-
TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig
Настройки дедтаймов таймера
-
TIM_SlaveConfigTypeDef sSlaveConfig
Настройки слейв режима таймера
-
TIM_ITModeTypeDef sTimMode
Настройки прерывания таймера
-
TIM_HandleTypeDef htim
HAL handle таймера
-
float sTimFreqHz
Желаемая частота таймера
+
Структура кнопки
+
Структура инициализации енкодера
+
TIM_Encoder_InitTypeDef sConfig
Указатель на структуру настройки энкодера
+
uint16_t Encoder_Shdw
Последние считанные тики
+
uint32_t GPIO_PIN_TI1
Пин, куда подключается канал TI1.
+
uint32_t GPIO_PIN_TI2
Пин, куда подключается канал TI2.
+
uint32_t GPIO_PIN_SW
Пин, куда кнопка энкодера (если есть)
+
int16_t Encoder_Diff
Считанная разница
+
GPIO_SwitchTypeDef Sw
Структура кнопки
+
GPIO_TypeDef * GPIOx
Порт, куда подключается энкодер
+
TIM_HandleTypeDef * htim
Указатель на HAL handle таймера
+
Структура инициализации таймера
+
uint8_t sTickBasePrescaler
Дополнительный делитель, для удобного деления sTickBaseUS.
+
TIM_MasterConfigTypeDef sMasterConfig
Настройки мастер режима таймера
+
TIM_ClockConfigTypeDef sClockSourceConfig
Настройки тактирования таймера
+
TIM_MHzTickBaseTypeDef sTickBaseUS
Длительность одного тика
+
float sTimAHBFreqMHz
Частота шины тактирования таймера
+
TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig
Настройки дедтаймов таймера
+
TIM_SlaveConfigTypeDef sSlaveConfig
Настройки слейв режима таймера
+
TIM_ITModeTypeDef sTimMode
Настройки прерывания таймера
+
TIM_HandleTypeDef htim
HAL handle таймера
+
float sTimFreqHz
Желаемая частота таймера
+
diff --git a/Doc/html/globals.html b/Doc/html/globals.html index 66ad2d8..772cd86 100644 --- a/Doc/html/globals.html +++ b/Doc/html/globals.html @@ -3,7 +3,7 @@ - + MyLibs: File Members @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
- + +
@@ -73,10 +71,9 @@ $(function() { +
Here is a list of all documented file members with links to the documentation:
-

- a -

+
diff --git a/Doc/html/globals_defs.html b/Doc/html/globals_defs.html index 29ec4f2..0d6f81e 100644 --- a/Doc/html/globals_defs.html +++ b/Doc/html/globals_defs.html @@ -3,7 +3,7 @@ - + MyLibs: File Members @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
Here is a list of all documented macros with links to the documentation:
-

- a -

+
diff --git a/Doc/html/globals_enum.html b/Doc/html/globals_enum.html index 5e793c5..6f657c5 100644 --- a/Doc/html/globals_enum.html +++ b/Doc/html/globals_enum.html @@ -3,7 +3,7 @@ - + MyLibs: File Members @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
+
diff --git a/Doc/html/globals_eval.html b/Doc/html/globals_eval.html index 6328d76..0a9db7f 100644 --- a/Doc/html/globals_eval.html +++ b/Doc/html/globals_eval.html @@ -3,7 +3,7 @@ - + MyLibs: File Members @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
+
diff --git a/Doc/html/globals_func.html b/Doc/html/globals_func.html index fca3e0d..4f8749e 100644 --- a/Doc/html/globals_func.html +++ b/Doc/html/globals_func.html @@ -3,7 +3,7 @@ - + MyLibs: File Members @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
Here is a list of all documented functions with links to the documentation:
-

- e -

+
diff --git a/Doc/html/graph_legend.html b/Doc/html/graph_legend.html index dc6f4f9..141b423 100644 --- a/Doc/html/graph_legend.html +++ b/Doc/html/graph_legend.html @@ -3,7 +3,7 @@ - + MyLibs: Graph Legend @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
  • A dark red arrow is used for private inheritance.
  • -A purple dashed arrow is used if a class is contained or used by another class. The arrow is labelled with the variable(s) through which the pointed class or struct is accessible.
  • +A purple dashed arrow is used if a class is contained or used by another class. The arrow is labeled with the variable(s) through which the pointed class or struct is accessible.
  • -A yellow dashed arrow denotes a relation between a template instance and the template class it was instantiated from. The arrow is labelled with the template parameters of the instance.
  • +A yellow dashed arrow denotes a relation between a template instance and the template class it was instantiated from. The arrow is labeled with the template parameters of the instance.
    +
    diff --git a/Doc/html/group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html b/Doc/html/group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html index 08e7802..91e6dff 100644 --- a/Doc/html/group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html +++ b/Doc/html/group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html @@ -3,7 +3,7 @@ - + MyLibs: Bit access defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Bit access defines
    +
    Bit access defines

    Макросы и typedef'ы для работы с битами в unsigned типах. More...

    -
    - + Collaboration diagram for Bit access defines:
    +
    Collaboration diagram for Bit access defines:
    - - - - - - - - - + + + +

    +

    Classes

    union  uint8_BitTypeDef
     
    union  uint16_BitTypeDef
     
    union  uint32_BitTypeDef
     
    union  uint64_BitTypeDef
     
    union  uint8_BitTypeDef
    union  uint16_BitTypeDef
    union  uint32_BitTypeDef
    union  uint64_BitTypeDef
    - - + - - + - - + - - + -

    +

    Macros

    #define uint8_bit(_uint8_, _bit_)   (*(uint8_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
    #define uint8_bit(_uint8_, _bit_)
     Получить n-й бит из uint8_t.
     
    #define uint16_bit(_uint8_, _bit_)   (*(uint16_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
    #define uint16_bit(_uint8_, _bit_)
     Получить n-й бит из uint16_t.
     
    #define uint32_bit(_uint8_, _bit_)   (*(uint32_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
    #define uint32_bit(_uint8_, _bit_)
     Получить n-й бит из uint32_t.
     
    #define uint64_bit(_uint8_, _bit_)   (*(uint64_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
    #define uint64_bit(_uint8_, _bit_)
     Получить n-й бит из uint64_t.
     
    -

    Detailed Description

    +

    Detailed Description

    Макросы и typedef'ы для работы с битами в unsigned типах.

    В этом файле определены макросы для получения значения конкретного бита^

  • Макросы возвращают 0 или 1.
  • -
  • Доступ реализован через приведение к union с битовыми полями, поэтому это безопасный способ работы с отдельными битами без ручного сдвига и маскирования.
  • +
  • Доступ реализован через приведение к union с битовыми полями, поэтому это безопасный способ работы с отдельными битами без ручного сдвига и маскирования.
  • -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ uint8_bit

    @@ -177,16 +162,18 @@ Macros #define uint8_bit ( - _uint8_, + _uint8_, - _bit_ )   (*(uint8_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_ + _bit_ )
    - +Value:
    (*(uint8_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
    + +

    Получить n-й бит из uint8_t.

    Parameters
    @@ -211,16 +198,18 @@ Macros - + - +
    #define uint16_bit ( _uint8_, _uint8_,
    _bit_ )   (*(uint16_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_ _bit_ )
    - +Value:
    (*(uint16_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
    + +

    Получить n-й бит из uint16_t.

    Parameters
    @@ -245,16 +234,18 @@ Macros - + - +
    #define uint32_bit ( _uint8_, _uint8_,
    _bit_ )   (*(uint32_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_ _bit_ )
    - +Value:
    (*(uint32_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
    + +

    Получить n-й бит из uint32_t.

    Parameters
    @@ -279,16 +270,18 @@ Macros - + - +
    #define uint64_bit ( _uint8_, _uint8_,
    _bit_ )   (*(uint64_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_ _bit_ )
    - +Value:
    (*(uint64_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_
    + +

    Получить n-й бит из uint64_t.

    Parameters
    @@ -306,10 +299,18 @@ Macros + + diff --git a/Doc/html/group___d_e_l_a_y_s___d_e_f_i_n_e_s.html b/Doc/html/group___d_e_l_a_y_s___d_e_f_i_n_e_s.html index 0aa93d9..28dfdd1 100644 --- a/Doc/html/group___d_e_l_a_y_s___d_e_f_i_n_e_s.html +++ b/Doc/html/group___d_e_l_a_y_s___d_e_f_i_n_e_s.html @@ -3,7 +3,7 @@ - +MyLibs: Delays defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + +
    @@ -73,10 +71,9 @@ $(function() {
    +
    - -
    Delays defines
    +
    Delays defines

    Макросы и определения для работы с задержками в миллисекундах. More...

    -
    - + Collaboration diagram for Delays defines:
    +
    Collaboration diagram for Delays defines:
    - - - - - + + + - - + - - + -

    +

    Macros

    #define msDelay(_ms_)   HAL_Delay(_ms_)
     Задержка на указанное количество миллисекунд.
     
    #define msDelayStart(_pvar_)   *(_pvar_) = HAL_GetTick()
    #define msDelay(_ms_)
     Блокирующая задержка на указанное количество миллисекунд.
    #define msDelayStart(_pvar_)
     Начать отсчет задержки.
     
    #define msDelayWhileActive(_ms_, _pvar_)   (HAL_GetTick() - *(_pvar_) < _ms_)
    #define msDelayWhileActive(_ms_, _pvar_)
     Проверяет, активна ли задержка.
     
    #define msDelayWaitDone(_ms_, _pvar_)   (HAL_GetTick() - *(_pvar_) >= _ms_)
    #define msDelayWaitDone(_ms_, _pvar_)
     Проверяет, завершилась ли задержка.
     
    -

    Detailed Description

    +

    Detailed Description

    Макросы и определения для работы с задержками в миллисекундах.

    Этот блок содержит макросы для реализации задержек с использованием HAL или FreeRTOS:

    • msDelay — простая задержка заданной длительности;
    • @@ -143,7 +133,7 @@ Macros
    • msDelayWhileActive — проверка, активна ли задержка;
    • msDelayWaitDone — проверка, завершена ли задержка. Эти макросы удобны для реализации неблокирующих задержек.
    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ msDelay

    @@ -153,22 +143,23 @@ Macros #define msDelay ( - _ms_) -    HAL_Delay(_ms_) + _ms_) +
    - -

    Задержка на указанное количество миллисекунд.

    +Value:
    osDelay(_ms_)
    +
    +

    Блокирующая задержка на указанное количество миллисекунд.

    Parameters
    _ms_Время задержки в миллисекундах.
    -
    Note
    Использует HAL_Delay или osDelay в зависимости от FREERTOS_DELAY.
    +
    Note
    Использует задержку через local_time или osDelay в зависимости от FREERTOS_DELAY.
    -

    Definition at line 82 of file mylibs_defs.h.

    +

    Definition at line 80 of file mylibs_defs.h.

    @@ -181,12 +172,14 @@ Macros #define msDelayStart ( - _pvar_) -    *(_pvar_) = HAL_GetTick() + _pvar_) +
    - +Value:
    *(_pvar_) = local_time()
    +
    #define local_time()
    Локальное время
    +

    Начать отсчет задержки.

    Parameters
    @@ -194,10 +187,10 @@ Macros
    -

    После вызова этого макроса переменная pvar содержит текущее количество миллисекунд с момента запуска системы (HAL_GetTick).

    +

    После вызова этого макроса переменная pvar содержит текущее количество миллисекунд с момента запуска системы (local_time).

    Используется для реализации неблокирующих задержек.

    -

    Definition at line 94 of file mylibs_defs.h.

    +

    Definition at line 98 of file mylibs_defs.h.

    @@ -210,16 +203,17 @@ Macros #define msDelayWhileActive ( - _ms_, + _ms_, - _pvar_ )   (HAL_GetTick() - *(_pvar_) < _ms_) + _pvar_ )
    - +Value:
    (local_time() - *(_pvar_) < _ms_)
    +

    Проверяет, активна ли задержка.

    Parameters
    @@ -238,9 +232,9 @@ Macros

    Возвращает true, пока время задержки не истекло. Используется в проверках, когда нужно действовать, пока задержка выполняется. Пример:

    while(msDelayWhileActive(1000, &tick)) {
    // выполняем другие задачи, задержка не блокирует поток
    }
    -
    #define msDelayWhileActive(_ms_, _pvar_)
    Проверяет, активна ли задержка.
    +
    #define msDelayWhileActive(_ms_, _pvar_)
    Проверяет, активна ли задержка.
    -

    Definition at line 111 of file mylibs_defs.h.

    +

    Definition at line 115 of file mylibs_defs.h.

    @@ -253,16 +247,17 @@ Macros - + - +
    #define msDelayWaitDone ( _ms_, _ms_,
    _pvar_ )   (HAL_GetTick() - *(_pvar_) >= _ms_) _pvar_ )
    - +Value:
    (local_time() - *(_pvar_) >= _ms_)
    +

    Проверяет, завершилась ли задержка.

    Parameters
    @@ -281,18 +276,26 @@ Macros

    Возвращает true, когда задержка уже завершена. Используется в проверках, когда нужно выполнить действие только после окончания задержки. Пример:

    if(msDelayWaitDone(1000, &tick)) {
    // выполняем действие после завершения задержки
    }
    -
    #define msDelayWaitDone(_ms_, _pvar_)
    Проверяет, завершилась ли задержка.
    +
    #define msDelayWaitDone(_ms_, _pvar_)
    Проверяет, завершилась ли задержка.
    -

    Definition at line 128 of file mylibs_defs.h.

    +

    Definition at line 132 of file mylibs_defs.h.

    + + diff --git a/Doc/html/group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html b/Doc/html/group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html index a3931c8..02199b4 100644 --- a/Doc/html/group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html +++ b/Doc/html/group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html @@ -3,7 +3,7 @@ - +MyLibs: Error Handler defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Error Handler defines
    +
    Error Handler defines

    Дефайны для обработки ошибок More...

    -
    - + Collaboration diagram for Error Handler defines:
    +
    Collaboration diagram for Error Handler defines:
    - - + - - + - - + - - + - - + - - + -

    +

    Macros

    #define MyLibs_Error_Handler(params)   Error_Handler(params)
    #define MyLibs_Error_Handler(params)
     Error_Handler который будет вызыватся в библиотеке
     
    #define check_null_ptr_1(p1)   (p1 == NULL)
    #define check_null_ptr_1(p1)
     Проверить один указатель на NULL.
     
    #define check_null_ptr_2(p1, p2)   ((p1 == NULL) || (p1 != NULL && p2 == NULL))
    #define check_null_ptr_2(p1, p2)
     Проверить два указателя на NULL.
     
    #define check_null_ptr_3(p1, p2, p3)   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && p3 == NULL))))
    #define check_null_ptr_3(p1, p2, p3)
     Проверить три указателя на NULL.
     
    #define check_null_ptr_4(p1, p2, p3, p4)   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && p4 == NULL))))))
    #define check_null_ptr_4(p1, p2, p3, p4)
     Проверить четыре указателя на NULL.
     
    #define check_null_ptr_5(p1, p2, p3, p4, p5)   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && ((p4 == NULL) || (p4 != NULL && p5 == NULL))))))))
    #define check_null_ptr_5(p1, p2, p3, p4, p5)
     Проверить пять указателей на NULL.
     
    - -

    +

    Functions

    void Error_Handler (void)
     
    -

    Detailed Description

    +

    Detailed Description

    Дефайны для обработки ошибок

    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ MyLibs_Error_Handler

    @@ -160,12 +146,13 @@ void Error_Handler (vo #define MyLibs_Error_Handler ( - params) -    Error_Handler(params) + params) +
    - +Value:
    Error_Handler(params)
    +

    Error_Handler который будет вызыватся в библиотеке

    Definition at line 31 of file mylibs_defs.h.

    @@ -181,12 +168,13 @@ void Error_Handler (vo #define check_null_ptr_1 ( - p1) -    (p1 == NULL) + p1) +
    - +Value:
    (p1 == NULL)
    +

    Проверить один указатель на NULL.

    Definition at line 38 of file mylibs_defs.h.

    @@ -202,16 +190,17 @@ void Error_Handler (vo #define check_null_ptr_2 ( - p1, + p1, - p2 )   ((p1 == NULL) || (p1 != NULL && p2 == NULL)) + p2 )
    - +Value:
    ((p1 == NULL) || (p1 != NULL && p2 == NULL))
    +

    Проверить два указателя на NULL.

    Definition at line 41 of file mylibs_defs.h.

    @@ -227,21 +216,22 @@ void Error_Handler (vo #define check_null_ptr_3 ( - p1, + p1, - p2, + p2, - p3 )   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && p3 == NULL)))) + p3 )
    - +Value:
    ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && p3 == NULL))))
    +

    Проверить три указателя на NULL.

    Definition at line 44 of file mylibs_defs.h.

    @@ -257,26 +247,27 @@ void Error_Handler (vo #define check_null_ptr_4 ( - p1, + p1, - p2, + p2, - p3, + p3, - p4 )   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && p4 == NULL)))))) + p4 )
    - +Value:
    ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && p4 == NULL))))))
    +

    Проверить четыре указателя на NULL.

    Definition at line 47 of file mylibs_defs.h.

    @@ -292,31 +283,32 @@ void Error_Handler (vo #define check_null_ptr_5 ( - p1, + p1, - p2, + p2, - p3, + p3, - p4, + p4, - p5 )   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && ((p4 == NULL) || (p4 != NULL && p5 == NULL)))))))) + p5 )
    - +Value:
    ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && ((p4 == NULL) || (p4 != NULL && p5 == NULL))))))))
    +

    Проверить пять указателей на NULL.

    Definition at line 50 of file mylibs_defs.h.

    @@ -325,10 +317,18 @@ void Error_Handler (vo
    + +
    diff --git a/Doc/html/group___e_v_o_l_v_e___c_o_n_f_i_g.html b/Doc/html/group___e_v_o_l_v_e___c_o_n_f_i_g.html index 14d4da5..3581a16 100644 --- a/Doc/html/group___e_v_o_l_v_e___c_o_n_f_i_g.html +++ b/Doc/html/group___e_v_o_l_v_e___c_o_n_f_i_g.html @@ -3,7 +3,7 @@ - + MyLibs: Evolve configs @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Evolve configs
    +
    Evolve configs

    Конфигурация однослойного персептрона и алгоритма обучения More...

    -
    - + Collaboration diagram for Evolve configs:
    +
    Collaboration diagram for Evolve configs:
    - - - -

    +

    Macros

    #define ENABLE_EVOLVE_OPTIMIZATION
     Включить оптимизацию параметров
     
    #define EVOLVE_MAX_PARAMS   20
     Максимальное количество параметров
     
    #define EVOLVE_MAX_CANDIDATES   100
     Максимальное количество кандидатов для обучения
     
    -

    Detailed Description

    +

    Detailed Description

    Конфигурация однослойного персептрона и алгоритма обучения

    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ ENABLE_EVOLVE_OPTIMIZATION

    @@ -191,10 +182,18 @@ Macros
    + +
    diff --git a/Doc/html/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html b/Doc/html/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html index 89e1aeb..21f0c0c 100644 --- a/Doc/html/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html +++ b/Doc/html/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html @@ -3,7 +3,7 @@ - + MyLibs: Evolve optimizer @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Evolve optimizer
    +
    Evolve optimizer

    Библиотека для эволюционного подбора параметров More...

    -
    - + Collaboration diagram for Evolve optimizer:
    +
    Collaboration diagram for Evolve optimizer:
    - - + -

    +

    Classes

    struct  EvolveOptimizer_t
    struct  EvolveOptimizer_t
     Структура эволюционного оптимизатора More...
     
    - - + - - + - - - - - - -

    +

    Macros

    #define PARAM_SCALE(x, min_val, max_val)   (((float)(x) - (float)(min_val)) / ((float)(max_val) - (float)(min_val)))
    #define PARAM_SCALE(x, min_val, max_val)
     Линейное масштабирование x из диапазона [min_val, max_val] в диапазон [0, 1)
     
    #define PARAM_UNSCALE(val, min_val, max_val)   (((float)(val)) * ((float)(max_val) - (float)(min_val)) + (float)(min_val))
    #define PARAM_UNSCALE(val, min_val, max_val)
     Обратное линейное масштабирование значения из [0, 1) в диапазон [min_val, max_val].
     
    #define local_time()   HAL_GetTick()
     Локальное время
     
    #define EVOLVE_MUTATION_MIN_PCT   10
     Минимальная мутация (в процентах от Loss)
     
    #define EVOLVE_MUTATION_MAX_PCT   100
     Максимальная мутация (в процентах от Loss)
     
    #define ELOVLE_N_ELITE_CANDIDATE   2
     Количество кандидатов, которые проходят в поколение без изменений (по умолчанию 2)
     
    - - -

    +

    Functions

    __STATIC_INLINE int EvolveOptimizer_Init (EvolveOptimizer_t *opt, uint16_t n_params, uint16_t n_cand, uint16_t n_best, float mutation_amp, float *start_params)
     Инициализация эволюционного оптимизатора.
     
    __STATIC_INLINE int EvolveOptimizer_Step (EvolveOptimizer_t *opt, float *params, float loss)
     Один шаг эволюционного оптимизатора.
     
    -

    Detailed Description

    +

    Detailed Description

    Библиотека для эволюционного подбора параметров

    Поддерживает:

    • Любое количество параметров
    • @@ -205,14 +186,13 @@ Functions
      param_u8 = PARAM_UNSCALE(params[2], 10.0f, 100.0f);
      param_i16 = PARAM_UNSCALE(params[3], 500.0f, 5000.0f);
      Заголовочный файл для адаптивного подбора параметров
      -
      __STATIC_INLINE int EvolveOptimizer_Init(EvolveOptimizer_t *opt, uint16_t n_params, uint16_t n_cand, uint16_t n_best, float mutation_amp, float *start_params)
      Инициализация эволюционного оптимизатора.
      +
      __STATIC_INLINE int EvolveOptimizer_Init(EvolveOptimizer_t *opt, uint16_t n_params, uint16_t n_cand, uint16_t n_best, float mutation_amp, float *start_params)
      Инициализация эволюционного оптимизатора.
      #define PARAM_SCALE(x, min_val, max_val)
      Линейное масштабирование x из диапазона [min_val, max_val] в диапазон [0, 1)
      #define PARAM_UNSCALE(val, min_val, max_val)
      Обратное линейное масштабирование значения из [0, 1) в диапазон [min_val, max_val].
      -
      __STATIC_INLINE int EvolveOptimizer_Step(EvolveOptimizer_t *opt, float *params, float loss)
      Один шаг эволюционного оптимизатора.
      +
      __STATIC_INLINE int EvolveOptimizer_Step(EvolveOptimizer_t *opt, float *params, float loss)
      Один шаг эволюционного оптимизатора.
      Структура эволюционного оптимизатора
      -

    - -

    Macro Definition Documentation

    +
    +

    Macro Definition Documentation

    ◆ PARAM_SCALE

    @@ -222,21 +202,22 @@ Functions #define PARAM_SCALE ( - x, + x, - min_val, + min_val, - max_val )   (((float)(x) - (float)(min_val)) / ((float)(max_val) - (float)(min_val))) + max_val )
    - +Value:
    (((float)(x) - (float)(min_val)) / ((float)(max_val) - (float)(min_val)))
    +

    Линейное масштабирование x из диапазона [min_val, max_val] в диапазон [0, 1)

    Definition at line 73 of file evolve_optimizer.h.

    @@ -252,46 +233,26 @@ Functions #define PARAM_UNSCALE ( - val, + val, - min_val, + min_val, - max_val )   (((float)(val)) * ((float)(max_val) - (float)(min_val)) + (float)(min_val)) + max_val )
    - +Value:
    (((float)(val)) * ((float)(max_val) - (float)(min_val)) + (float)(min_val))
    +

    Обратное линейное масштабирование значения из [0, 1) в диапазон [min_val, max_val].

    Definition at line 79 of file evolve_optimizer.h.

    -
    -
    - -

    ◆ local_time

    - -
    -
    - - - - - - - -
    #define local_time()   HAL_GetTick()
    -
    - -

    Локальное время

    - -

    Definition at line 83 of file evolve_optimizer.h.

    -
    @@ -348,7 +309,7 @@ Functions -

    Function Documentation

    +

    Function Documentation

    ◆ EvolveOptimizer_Init()

    @@ -358,27 +319,27 @@ Functions __STATIC_INLINE int EvolveOptimizer_Init ( - EvolveOptimizer_t * opt, + EvolveOptimizer_t * opt, - uint16_t n_params, + uint16_t n_params, - uint16_t n_cand, + uint16_t n_cand, - uint16_t n_best, + uint16_t n_best, - float mutation_amp, + float mutation_amp, @@ -402,7 +363,7 @@ Functions
    Returns
    0 — если окей, -1 — если ошибка
    -

    Definition at line 148 of file evolve_optimizer.h.

    +

    Definition at line 155 of file evolve_optimizer.h.

    @@ -415,12 +376,12 @@ Functions __STATIC_INLINE int EvolveOptimizer_Step ( - EvolveOptimizer_t * opt, + EvolveOptimizer_t * opt, - float * params, + float * params, @@ -443,16 +404,24 @@ Functions

    Сохраняет loss текущего кандидата и формирует параметры следующего кандидата. Если накоплено n_cand кандидатов, генерируется новое поколение. Новое поколение формируется случайным выбором из n_best лучших с добавлением мутации.

    На выходе params содержит параметры следующего кандидата для измерений.

    Note
    Функция использует глобальную внутреннюю переменную для сортировки. Надо убедится что только один экземпляр функции запущен в момент времени
    -

    Definition at line 216 of file evolve_optimizer.h.

    +

    Definition at line 225 of file evolve_optimizer.h.

    + + diff --git a/Doc/html/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.js b/Doc/html/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.js index d3344de..df1c356 100644 --- a/Doc/html/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.js +++ b/Doc/html/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.js @@ -7,13 +7,14 @@ var group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r = [ "n_best", "struct_evolve_optimizer__t.html#a950cd70cb6bff33b78ad35ee58c729a6", null ], [ "mutation_amp", "struct_evolve_optimizer__t.html#af779c7aeba0053e36cee7aade160f1c8", null ], [ "cand_index", "struct_evolve_optimizer__t.html#a0ae0e63ba351335d4445d927991c64ae", null ], + [ "gen_index", "struct_evolve_optimizer__t.html#ad0f464d7048a9ed0753b61f76f563108", null ], + [ "gen_mut", "struct_evolve_optimizer__t.html#a3be8c0c34db8429210ff470497a56727", null ], [ "loss", "struct_evolve_optimizer__t.html#a93f628397c2f8d4027f2906752b650df", null ], [ "candidates", "struct_evolve_optimizer__t.html#aec67667fd1f1533e693e41c79bc28da4", null ], [ "sorted_idx", "struct_evolve_optimizer__t.html#a74b81df1c298c99162310f3f7d91735a", null ] ] ], [ "PARAM_SCALE", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga83abbcabaff9111c03ae2475ee72ea3e", null ], [ "PARAM_UNSCALE", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#gaa1d5510fe5f0bd989473f3ebe324bde3", null ], - [ "local_time", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga9c853b02c22f26023c34d1d404b6d653", null ], [ "EVOLVE_MUTATION_MIN_PCT", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga2f2b1be34ad4eb1bf3267237200cd6c6", null ], [ "EVOLVE_MUTATION_MAX_PCT", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga861c1c6a503c21441abcec0d57b848bc", null ], [ "ELOVLE_N_ELITE_CANDIDATE", "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga38607e23d9234524bc7de5869b15b8eb", null ], diff --git a/Doc/html/group___g_p_i_o___i_n_i_t.html b/Doc/html/group___g_p_i_o___i_n_i_t.html index e643f63..51ad3d1 100644 --- a/Doc/html/group___g_p_i_o___i_n_i_t.html +++ b/Doc/html/group___g_p_i_o___i_n_i_t.html @@ -3,7 +3,7 @@ - + MyLibs: Init defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - - +

    Настройка состояний кнопок и количества тиков в периоде ШИМ More...

    -
    - + Collaboration diagram for Init defines:
    +
    Collaboration diagram for Init defines:
    - - - - - -

    +

    Macros

    #define LED_PWM_TICKS   15
     Количество тиков в периоде ШИМ
     
    #define LED_ON   1
     Состояние пина для включения светодиода
     
    #define LED_OFF   0
     Состояние пина для выключения светодиода
     
    #define SW_ON   1
     Состояние пина при нажатой кнопке
     
    #define SW_OFF   0
     Состояние пина при отжатой кнопке
     
    -

    Detailed Description

    +

    Detailed Description

    Настройка состояний кнопок и количества тиков в периоде ШИМ

    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ LED_PWM_TICKS

    @@ -155,7 +144,7 @@ Macros

    Количество тиков в периоде ШИМ

    -

    Definition at line 31 of file general_gpio.h.

    +

    Definition at line 35 of file general_gpio.h.

    @@ -173,7 +162,7 @@ Macros

    Состояние пина для включения светодиода

    -

    Definition at line 35 of file general_gpio.h.

    +

    Definition at line 39 of file general_gpio.h.

    @@ -191,7 +180,7 @@ Macros

    Состояние пина для выключения светодиода

    -

    Definition at line 38 of file general_gpio.h.

    +

    Definition at line 42 of file general_gpio.h.

    @@ -209,7 +198,7 @@ Macros

    Состояние пина при нажатой кнопке

    -

    Definition at line 42 of file general_gpio.h.

    +

    Definition at line 46 of file general_gpio.h.

    @@ -227,16 +216,24 @@ Macros

    Состояние пина при отжатой кнопке

    -

    Definition at line 45 of file general_gpio.h.

    +

    Definition at line 49 of file general_gpio.h.

    + + diff --git a/Doc/html/group___l_i_b_s___c_o_n_f_i_g.html b/Doc/html/group___l_i_b_s___c_o_n_f_i_g.html index f0e726d..10024d9 100644 --- a/Doc/html/group___l_i_b_s___c_o_n_f_i_g.html +++ b/Doc/html/group___l_i_b_s___c_o_n_f_i_g.html @@ -3,7 +3,7 @@ - + MyLibs: Libraries configs @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Libraries configs
    +
    Libraries configs

    Подключение различных модулей библиотеки More...

    -
    - + Collaboration diagram for Libraries configs:
    +
    Collaboration diagram for Libraries configs:
    - + + - - - - - + +

    +

    Macros

    #define local_time()
     Локальное время
    #define INCLUDE_EVOLVE_OPTIMIZER
     Подключить библиотеку для оптимизации параметров
     
    #define INCLUDE_BIT_ACCESS_LIB
     Подключить библиотеку с typedef с битовыми полями
     
    #define INCLUDE_TRACKERS_LIB
     Подключить библиотеку с трекерами
     
    #define INCLUDE_TRACE_LIB
     Подключить библиотеку с трейсами
     
    #define INCLUDE_GENERAL_PERIPH_LIBS
     Подключить библиотеку с периферией
     
    #define FREERTOS_DELAY
     Использовать FreeRTOS задержку, вместо HAL.
    -

    Detailed Description

    +

    Detailed Description

    Подключение различных модулей библиотеки

    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    + +

    ◆ local_time

    + +
    +
    + + + + + + + +
    #define local_time()
    +
    +Value:
    uwTick
    +
    +

    Локальное время

    + +

    Definition at line 80 of file mylibs_config.h.

    + +
    +

    ◆ INCLUDE_EVOLVE_OPTIMIZER

    @@ -155,7 +170,7 @@ Macros

    Подключить библиотеку для оптимизации параметров

    -

    Definition at line 80 of file mylibs_config.h.

    +

    Definition at line 82 of file mylibs_config.h.

    @@ -173,7 +188,7 @@ Macros

    Подключить библиотеку с typedef с битовыми полями

    -

    Definition at line 81 of file mylibs_config.h.

    +

    Definition at line 83 of file mylibs_config.h.

    @@ -191,7 +206,7 @@ Macros

    Подключить библиотеку с трекерами

    -

    Definition at line 82 of file mylibs_config.h.

    +

    Definition at line 84 of file mylibs_config.h.

    @@ -209,7 +224,7 @@ Macros

    Подключить библиотеку с трейсами

    -

    Definition at line 83 of file mylibs_config.h.

    +

    Definition at line 85 of file mylibs_config.h.

    @@ -227,16 +242,42 @@ Macros

    Подключить библиотеку с периферией

    -

    Definition at line 84 of file mylibs_config.h.

    +

    Definition at line 86 of file mylibs_config.h.

    + + + + +

    ◆ FREERTOS_DELAY

    + +
    +
    + + + + +
    #define FREERTOS_DELAY
    +
    + +

    Использовать FreeRTOS задержку, вместо HAL.

    + +

    Definition at line 87 of file mylibs_config.h.

    + + diff --git a/Doc/html/group___l_i_b_s___c_o_n_f_i_g.js b/Doc/html/group___l_i_b_s___c_o_n_f_i_g.js index 7938549..e82ae27 100644 --- a/Doc/html/group___l_i_b_s___c_o_n_f_i_g.js +++ b/Doc/html/group___l_i_b_s___c_o_n_f_i_g.js @@ -1,8 +1,10 @@ var group___l_i_b_s___c_o_n_f_i_g = [ + [ "local_time", "group___l_i_b_s___c_o_n_f_i_g.html#ga9c853b02c22f26023c34d1d404b6d653", null ], [ "INCLUDE_EVOLVE_OPTIMIZER", "group___l_i_b_s___c_o_n_f_i_g.html#ga66560656d080d6551627a19dfb847c66", null ], [ "INCLUDE_BIT_ACCESS_LIB", "group___l_i_b_s___c_o_n_f_i_g.html#gaf4ddb2a71ec0d05c2480e197cd17c0be", null ], [ "INCLUDE_TRACKERS_LIB", "group___l_i_b_s___c_o_n_f_i_g.html#ga4403055986b70bb02b8d37073a122e32", null ], [ "INCLUDE_TRACE_LIB", "group___l_i_b_s___c_o_n_f_i_g.html#ga0a3ca94b616997069dd53e2c6c2687d7", null ], - [ "INCLUDE_GENERAL_PERIPH_LIBS", "group___l_i_b_s___c_o_n_f_i_g.html#ga181a46326e46b60afb160190832c7281", null ] + [ "INCLUDE_GENERAL_PERIPH_LIBS", "group___l_i_b_s___c_o_n_f_i_g.html#ga181a46326e46b60afb160190832c7281", null ], + [ "FREERTOS_DELAY", "group___l_i_b_s___c_o_n_f_i_g.html#ga57c369737d5c0cfdb7baeecba0a4b151", null ] ]; \ No newline at end of file diff --git a/Doc/html/group___m_y___l_i_b_s___g_p_i_o.html b/Doc/html/group___m_y___l_i_b_s___g_p_i_o.html index 7b2cede..b588aa0 100644 --- a/Doc/html/group___m_y___l_i_b_s___g_p_i_o.html +++ b/Doc/html/group___m_y___l_i_b_s___g_p_i_o.html @@ -3,7 +3,7 @@ - + MyLibs: GPIO Tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    GPIO Tools
    +
    GPIO Tools

    Функции и макросы для удобной работы с GPIO. More...

    -
    - + Collaboration diagram for GPIO Tools:
    +
    Collaboration diagram for GPIO Tools:
    - - + - - + - - + -

    +

    Topics

     General tools
     General tools
     Общие функции/макросы для работы с GPIO.
     
     Switch tools
     Switch tools
     Функции для работы с GPIO, как с кнопкой
     
     LED tools
     LED tools
     Функции для работы с GPIO, для управления светодиодом
     
    -

    Detailed Description

    +

    Detailed Description

    Функции и макросы для удобной работы с GPIO.

    Модуль предоставляет универсальные инструменты для работы с GPIO):

    • General tools — инициализация и общие функции работы с портами.
    • @@ -144,10 +135,18 @@ Topics
    + +
    diff --git a/Doc/html/group___m_y___l_i_b_s___t_i_m.html b/Doc/html/group___m_y___l_i_b_s___t_i_m.html index 4afff85..1c120f6 100644 --- a/Doc/html/group___m_y___l_i_b_s___t_i_m.html +++ b/Doc/html/group___m_y___l_i_b_s___t_i_m.html @@ -3,7 +3,7 @@ - + MyLibs: TIM Tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    TIM Tools
    +
    TIM Tools

    Функции и макросы для удобной работы с TIM. More...

    -
    - + Collaboration diagram for TIM Tools:
    +
    Collaboration diagram for TIM Tools:
    - - - - - - - - - - - + - + + + + + +

    +

    Topics

     PWM/OC Channels tools
     Функции для инициализации базовых функций каналов таймера
     
     Encoder tools
     Функции для считывания энкодера
     
     Delay tools
     Функции для формирования задержек с помощью таймеров
     
     General tools
     General tools
     Функции для базовой инициализации таймеров
     
     Delay tools
     Функции для формирования задержек с помощью таймеров
     PWM/OC Channels tools
     Функции для инициализации базовых функций каналов таймера
     Encoder tools
     Функции для считывания энкодера
    -

    Detailed Description

    +

    Detailed Description

    Функции и макросы для удобной работы с TIM.

    Модуль предоставляет универсальные инструменты для работы с TIM:

    • General tools — базовая инициализация таймеров и прерываний.
    • Delay tools — функции задержки через таймеры (blocking и non-blocking).
    • PWM/OC Channels tools — настройка каналов Output Compare и PWM.
    • -
    • Encoder tools — работа с энкодерами, чтение положения и кнопки.
      Note
      Требуется подключение модуля TIM в библиотеке HAL
      #define HAL_TIM_MODULE_ENABLED
      +
    • Encoder tools — работа с энкодерами, чтение положения и кнопки.

      +
      Note
      Требуется подключение модуля TIM в библиотеке HAL и GPIO (GPIO Tools) из MyLibs
      #define HAL_TIM_MODULE_ENABLED
    + +
    diff --git a/Doc/html/group___m_y___l_i_b_s___t_i_m.js b/Doc/html/group___m_y___l_i_b_s___t_i_m.js index 49958de..61cd824 100644 --- a/Doc/html/group___m_y___l_i_b_s___t_i_m.js +++ b/Doc/html/group___m_y___l_i_b_s___t_i_m.js @@ -1,7 +1,7 @@ var group___m_y___l_i_b_s___t_i_m = [ - [ "PWM/OC Channels tools", "group___m_y_l_i_b_s___t_i_m___o_c.html", "group___m_y_l_i_b_s___t_i_m___o_c" ], - [ "Encoder tools", "group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html", "group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r" ], + [ "General tools", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l" ], [ "Delay tools", "group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html", "group___m_y_l_i_b_s___t_i_m___d_e_l_a_y" ], - [ "General tools", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html", "group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l" ] + [ "PWM/OC Channels tools", "group___m_y_l_i_b_s___t_i_m___o_c.html", "group___m_y_l_i_b_s___t_i_m___o_c" ], + [ "Encoder tools", "group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html", "group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r" ] ]; \ No newline at end of file diff --git a/Doc/html/group___m_y___l_i_b_s___t_i_m.map b/Doc/html/group___m_y___l_i_b_s___t_i_m.map index b0bb8ef..0f14167 100644 --- a/Doc/html/group___m_y___l_i_b_s___t_i_m.map +++ b/Doc/html/group___m_y___l_i_b_s___t_i_m.map @@ -1,8 +1,8 @@ - - - - + + + + diff --git a/Doc/html/group___m_y___l_i_b_s___t_i_m.md5 b/Doc/html/group___m_y___l_i_b_s___t_i_m.md5 index 588e808..ab26041 100644 --- a/Doc/html/group___m_y___l_i_b_s___t_i_m.md5 +++ b/Doc/html/group___m_y___l_i_b_s___t_i_m.md5 @@ -1 +1 @@ -bddd90356fb04fa1e92560356c210866 \ No newline at end of file +936137dd7521a28e69e9d997087dab56 \ No newline at end of file diff --git a/Doc/html/group___m_y_l_i_b_s___a_l_l.html b/Doc/html/group___m_y_l_i_b_s___a_l_l.html index db4abd7..2edb3f9 100644 --- a/Doc/html/group___m_y_l_i_b_s___a_l_l.html +++ b/Doc/html/group___m_y_l_i_b_s___a_l_l.html @@ -3,7 +3,7 @@ - + MyLibs: My Libs @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    My Libs
    +
    My Libs

    Все используемые MyLibs библиотеки More...

    -
    - + Collaboration diagram for My Libs:
    +
    Collaboration diagram for My Libs:
    - - + - - + - - + -

    +

    Topics

     Configs
     Configs
     Конфигурации для библиотек MyLibs.
     
     General Tools
     General Tools
     Общие макросы и typedef'ы, используемые по всему проекту
     
     Peripheral
     Peripheral
     Модули для управления периферией
     
    -

    Detailed Description

    +

    Detailed Description

    Все используемые MyLibs библиотеки

    Для подключения библиотеки необходимо:

    • Сконфигурировать mylibs_config.h:
        @@ -147,10 +138,18 @@ Topics
    + +
    diff --git a/Doc/html/group___m_y_l_i_b_s___c_o_n_f_i_g.html b/Doc/html/group___m_y_l_i_b_s___c_o_n_f_i_g.html index 837c430..04d29e3 100644 --- a/Doc/html/group___m_y_l_i_b_s___c_o_n_f_i_g.html +++ b/Doc/html/group___m_y_l_i_b_s___c_o_n_f_i_g.html @@ -3,7 +3,7 @@ - + MyLibs: Configs @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Configs
    +
    Configs

    Конфигурации для библиотек MyLibs. More...

    -
    - + Collaboration diagram for Configs:
    +
    Collaboration diagram for Configs:
    - - + - - + - - + -

    +

    Topics

     Trace configs
     Trace configs
     Конфигурация трекеров и трассировки
     
     Evolve configs
     Evolve configs
     Конфигурация однослойного персептрона и алгоритма обучения
     
     Libraries configs
     Libraries configs
     Подключение различных модулей библиотеки
     
    -

    Detailed Description

    +

    Detailed Description

    Конфигурации для библиотек MyLibs.

    + +
    diff --git a/Doc/html/group___m_y_l_i_b_s___d_e_f_i_n_e_s.html b/Doc/html/group___m_y_l_i_b_s___d_e_f_i_n_e_s.html index cfa10db..093beb8 100644 --- a/Doc/html/group___m_y_l_i_b_s___d_e_f_i_n_e_s.html +++ b/Doc/html/group___m_y_l_i_b_s___d_e_f_i_n_e_s.html @@ -3,7 +3,7 @@ - + MyLibs: General Tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    General Tools
    +
    General Tools

    Общие макросы и typedef'ы, используемые по всему проекту More...

    -
    - + Collaboration diagram for General Tools:
    +
    Collaboration diagram for General Tools:
    - - + - - + - - + - - + - - + - - + - - + -

    +

    Topics

     Bit access defines
     Bit access defines
     Макросы и typedef'ы для работы с битами в unsigned типах.
     
     Evolve optimizer
     Evolve optimizer
     Библиотека для эволюционного подбора параметров
     
     Error Handler defines
     Error Handler defines
     Дефайны для обработки ошибок
     
     Delays defines
     Delays defines
     Макросы и определения для работы с задержками в миллисекундах.
     
     Utils defines
     Utils defines
     Общие вспомогательные макросы
     
     Trace defines
     Trace defines
     Дефайны для работы с трассировкой
     
     Trackers defines
     Trackers defines
     Дефайны для работы с трекерами
     
    -

    Detailed Description

    +

    Detailed Description

    Общие макросы и typedef'ы, используемые по всему проекту

    + +
    diff --git a/Doc/html/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html b/Doc/html/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html index 14b0ac7..c97b5d3 100644 --- a/Doc/html/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html +++ b/Doc/html/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html @@ -3,7 +3,7 @@ - + MyLibs: General tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    General tools
    +
    General tools

    Общие функции/макросы для работы с GPIO. More...

    -
    - + Collaboration diagram for General tools:
    +
    Collaboration diagram for General tools:
    - - + -

    +

    Topics

     Init defines
     Init defines
     Настройка состояний кнопок и количества тиков в периоде ШИМ
     
    - - - - -

    -Macros

    #define GPIO_TIM_Alternate_Mapping(INSTANCE)
     Маппинг альтернативной функции TIM между GPIO.
     
    - -

    +

    Functions

    HAL_StatusTypeDef GPIO_Clock_Enable (GPIO_TypeDef *GPIOx)
     Включить тактирование порта GPIO.
     
    -

    Detailed Description

    +

    Detailed Description

    Общие функции/макросы для работы с GPIO.

    -

    Macro Definition Documentation

    - -

    ◆ GPIO_TIM_Alternate_Mapping

    - -
    -
    - - - - - - - -
    #define GPIO_TIM_Alternate_Mapping( INSTANCE)
    -
    -Value:
    ((((INSTANCE) == TIM1) || ((INSTANCE) == TIM2))? GPIO_AF1_TIM1: \
    -
    (((INSTANCE) == TIM3) || ((INSTANCE) == TIM4) || ((INSTANCE) == TIM5))? GPIO_AF2_TIM3: \
    -
    (((INSTANCE) == TIM8) || ((INSTANCE) == TIM9) || ((INSTANCE) == TIM10) || ((INSTANCE) == TIM11))? GPIO_AF3_TIM8: \
    -
    (((INSTANCE) == TIM12) || ((INSTANCE) == TIM13) || ((INSTANCE) == TIM14))? GPIO_AF9_TIM12: \
    -
    (0))
    -
    -

    Маппинг альтернативной функции TIM между GPIO.

    - -

    Definition at line 69 of file general_gpio.h.

    - -
    -
    -

    Function Documentation

    +
    Пример использования:
    // Включаем тактирование порта GPIOA
    + +
    HAL_StatusTypeDef GPIO_Clock_Enable(GPIO_TypeDef *GPIOx)
    Включить тактирование порта GPIO.
    +
    +

    Function Documentation

    ◆ GPIO_Clock_Enable()

    @@ -194,10 +155,18 @@ Functions
    + +
    diff --git a/Doc/html/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.js b/Doc/html/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.js index 64baa3b..18fd2e8 100644 --- a/Doc/html/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.js +++ b/Doc/html/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.js @@ -1,6 +1,5 @@ var group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l = [ [ "Init defines", "group___g_p_i_o___i_n_i_t.html", "group___g_p_i_o___i_n_i_t" ], - [ "GPIO_TIM_Alternate_Mapping", "group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga580b842096340b066c28b24d6b315be6", null ], [ "GPIO_Clock_Enable", "group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga962f010f783b81fcdd27eb6b53db28e6", null ] ]; \ No newline at end of file diff --git a/Doc/html/group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html b/Doc/html/group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html index d4c6383..9577120 100644 --- a/Doc/html/group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html +++ b/Doc/html/group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html @@ -3,7 +3,7 @@ - + MyLibs: LED tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +

    Функции для работы с GPIO, для управления светодиодом More...

    -
    - + Collaboration diagram for LED tools:
    +
    Collaboration diagram for LED tools:
    - - + -

    +

    Classes

    struct  GPIO_LEDTypeDef
    struct  GPIO_LEDTypeDef
     Структура светодиода More...
     
    - , LED_IS_FADING = 3 } -

    +

    Enumerations

    enum  GPIO_LEDStateTypeDef { LED_IS_OFF = 0 , LED_IS_ON = 1 @@ -136,35 +127,49 @@ Enumerations
     Режимы работы светодиода More...
     
    - - - - - - - -

    +

    Functions

    HAL_StatusTypeDef GPIO_LED_Init (GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State)
     Инициализировать светодиод (структуру светодиода)
     
    HAL_StatusTypeDef GPIO_LED_On (GPIO_LEDTypeDef *led)
     Включить светодиод
     
    HAL_StatusTypeDef GPIO_LED_Off (GPIO_LEDTypeDef *led)
     Выключить светодиод
     
    HAL_StatusTypeDef GPIO_LED_Set (GPIO_LEDTypeDef *led, uint8_t led_state)
     Выставить светодиод по переменной
     
    HAL_StatusTypeDef GPIO_LED_Blink_Start (GPIO_LEDTypeDef *led, uint32_t period)
     Активировать моргание светодиодом
     
    HAL_StatusTypeDef GPIO_LED_Fading_Start (GPIO_LEDTypeDef *led, uint32_t period)
     Активировать моргание светодиодом
     
    void GPIO_LED_Dynamic_Handle (GPIO_LEDTypeDef *led)
     Управление динамическими режимами свечения светодиода
     
    -

    Detailed Description

    +

    Detailed Description

    Функции для работы с GPIO, для управления светодиодом

    -

    Enumeration Type Documentation

    +
    Пример использования:
    MX_GPIO_Init(); // инициализация пина аппаратная
    +
    +
    // Инициализация светодиода на порте GPIOA, пин 5, активный уровень 0
    + +
    GPIO_LED_Init(&led, GPIOA, GPIO_PIN_5, 0); // или дефайн LED_ON/LED_OFF
    +
    +
    // Включение светодиода
    + +
    +
    // Запуск моргания
    +
    GPIO_LED_Blink_Start(&led, 500); // Период 500 мс
    +
    +
    // В основном цикле
    +
    while (1) {
    + +
    }
    +
    HAL_StatusTypeDef GPIO_LED_On(GPIO_LEDTypeDef *led)
    Включить светодиод
    +
    HAL_StatusTypeDef GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State)
    Инициализировать светодиод (структуру светодиода)
    +
    void GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led)
    Управление динамическими режимами свечения светодиода
    +
    HAL_StatusTypeDef GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period)
    Активировать моргание светодиодом
    +
    Структура светодиода
    +
    +

    Enumeration Type Documentation

    ◆ GPIO_LEDStateTypeDef

    @@ -189,11 +194,11 @@ Functions -

    Definition at line 81 of file general_gpio.h.

    +

    Definition at line 61 of file general_gpio.h.

    -

    Function Documentation

    +

    Function Documentation

    ◆ GPIO_LED_Init()

    @@ -203,17 +208,17 @@ Functions HAL_StatusTypeDef GPIO_LED_Init ( - GPIO_LEDTypeDef * led, + GPIO_LEDTypeDef * led, - GPIO_TypeDef * GPIOx, + GPIO_TypeDef * GPIOx, - uint32_t GPIO_PIN_X, + uint32_t GPIO_PIN_X, @@ -303,7 +308,7 @@ Functions HAL_StatusTypeDef GPIO_LED_Set ( - GPIO_LEDTypeDef * led, + GPIO_LEDTypeDef * led, @@ -336,7 +341,7 @@ Functions HAL_StatusTypeDef GPIO_LED_Blink_Start ( - GPIO_LEDTypeDef * led, + GPIO_LEDTypeDef * led, @@ -370,7 +375,7 @@ Functions HAL_StatusTypeDef GPIO_LED_Fading_Start ( - GPIO_LEDTypeDef * led, + GPIO_LEDTypeDef * led, @@ -425,10 +430,18 @@ Functions
    + + diff --git a/Doc/html/group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html b/Doc/html/group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html index 9c2d8b8..82cb8d5 100644 --- a/Doc/html/group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html +++ b/Doc/html/group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html @@ -3,7 +3,7 @@ - + MyLibs: Switch tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Switch tools
    +
    Switch tools

    Функции для работы с GPIO, как с кнопкой More...

    -
    - + Collaboration diagram for Switch tools:
    +
    Collaboration diagram for Switch tools:
    - - + -

    +

    Classes

    struct  GPIO_SwitchTypeDef
    struct  GPIO_SwitchTypeDef
     Структура кнопки More...
     
    - - -

    +

    Functions

    HAL_StatusTypeDef GPIO_Switch_Init (GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State)
     Инициализировать кнопку (структуру кнопки)
     
    int GPIO_Read_Switch (GPIO_SwitchTypeDef *swstart)
     Считать состоянии кнопки
     
    -

    Detailed Description

    +

    Detailed Description

    Функции для работы с GPIO, как с кнопкой

    -

    Function Documentation

    +
    Пример использования:
    MX_GPIO_Init(); // инициализация пина аппаратная
    +
    +
    // Инициализация кнопки на порте GPIOB, пин 0, активный уровень 1
    + +
    GPIO_Switch_Init(&sw1, GPIOB, GPIO_PIN_0, 1); // или дефайн SW_ON/SW_OFF
    +
    +
    // Считываем состояние кнопки
    + +
    {
    +
    // Кнопка нажата
    +
    LED_ON();
    +
    }
    +
    else
    +
    {
    +
    // Кнопка отжата
    + +
    }
    +
    #define LED_OFF
    Состояние пина для выключения светодиода
    +
    #define LED_ON
    Состояние пина для включения светодиода
    +
    int GPIO_Read_Switch(GPIO_SwitchTypeDef *swstart)
    Считать состоянии кнопки
    +
    HAL_StatusTypeDef GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State)
    Инициализировать кнопку (структуру кнопки)
    +
    Структура кнопки
    +
    +

    Function Documentation

    ◆ GPIO_Switch_Init()

    @@ -148,17 +161,17 @@ Functions HAL_StatusTypeDef GPIO_Switch_Init ( - GPIO_SwitchTypeDef * sw, + GPIO_SwitchTypeDef * sw, - GPIO_TypeDef * GPIOx, + GPIO_TypeDef * GPIOx, - uint32_t GPIO_PIN_X, + uint32_t GPIO_PIN_X, @@ -215,10 +228,18 @@ Functions
    + +
    diff --git a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.html b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.html index a0a8774..1131a7c 100644 --- a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.html +++ b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.html @@ -3,7 +3,7 @@ - + MyLibs: Peripheral @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Peripheral
    +
    Peripheral

    Модули для управления периферией More...

    -
    - + Collaboration diagram for Peripheral:
    +
    Collaboration diagram for Peripheral:
    - - + - - + + + - + +

    +

    Topics

     GPIO Tools
     GPIO Tools
     Функции и макросы для удобной работы с GPIO.
     
     TIM Tools
     SPI Tools
     Функции и макросы для удобной работы с SPI.
     TIM Tools
     Функции и макросы для удобной работы с TIM.
     
     UART Tools
     Функции и макросы для удобной работы с UART.
    -

    Detailed Description

    +

    Detailed Description

    Модули для управления периферией

    + +
    diff --git a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.js b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.js index 3fc66f5..d54fe32 100644 --- a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.js +++ b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.js @@ -1,5 +1,7 @@ var group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l = [ [ "GPIO Tools", "group___m_y___l_i_b_s___g_p_i_o.html", "group___m_y___l_i_b_s___g_p_i_o" ], - [ "TIM Tools", "group___m_y___l_i_b_s___t_i_m.html", "group___m_y___l_i_b_s___t_i_m" ] + [ "SPI Tools", "group___m_y___l_i_b_s___s_p_i.html", "group___m_y___l_i_b_s___s_p_i" ], + [ "TIM Tools", "group___m_y___l_i_b_s___t_i_m.html", "group___m_y___l_i_b_s___t_i_m" ], + [ "UART Tools", "group___m_y___l_i_b_s___u_a_r_t.html", "group___m_y___l_i_b_s___u_a_r_t" ] ]; \ No newline at end of file diff --git a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.map b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.map index fc698cf..0321692 100644 --- a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.map +++ b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.map @@ -1,6 +1,8 @@ - - - - + + + + + + diff --git a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.md5 b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.md5 index ee8c449..2e10e09 100644 --- a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.md5 +++ b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.md5 @@ -1 +1 @@ -9a24bce9b60d282ebbaf04d75a3cfad4 \ No newline at end of file +1044283365b108883d0b7a448ff91792 \ No newline at end of file diff --git a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.png b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.png index 756240e..f29ac65 100644 Binary files a/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.png and b/Doc/html/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.png differ diff --git a/Doc/html/group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html b/Doc/html/group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html index e0afecf..7c74916 100644 --- a/Doc/html/group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html +++ b/Doc/html/group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html @@ -3,7 +3,7 @@ - + MyLibs: Delay tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Delay tools
    +
    Delay tools

    Функции для формирования задержек с помощью таймеров More...

    -
    - + Collaboration diagram for Delay tools:
    +
    Collaboration diagram for Delay tools:
    - - - -

    +

    Functions

    HAL_StatusTypeDef TIM_Delay_Start (TIM_HandleTypeDef *htim)
     Начать отсчет неблокирующей задержки.
     
    HAL_StatusTypeDef TIM_Delay (TIM_HandleTypeDef *htim, uint16_t delay)
     Задержка в тиках таймера (блокирующая).
     
    HAL_StatusTypeDef TIM_Delay_NonBlocking (TIM_HandleTypeDef *htim, uint16_t delay)
     Задержка в тиках таймера (неблокирующая).
     
    -

    Detailed Description

    +

    Detailed Description

    Функции для формирования задержек с помощью таймеров

    -

    Function Documentation

    +
    Пример использования:
    TIM_HandleTypeDef htim2;
    +
    +
    // блокирующая задержка 500 тиков таймера
    + +
    TIM_Delay(&htim2, 500);
    + +
    +
    +
    while(1)
    +
    {
    +
    // не блокирующая задержка 200 тиков таймера
    +
    if(TIM_Delay_NonBlocking(&htim2, 200) == HAL_OK)
    +
    {
    +
    TIM_Delay_Start(&htim2);
    +
    LED_TOOGLE();
    +
    }
    +
    }
    +
    #define LED_OFF
    Состояние пина для выключения светодиода
    +
    #define LED_ON
    Состояние пина для включения светодиода
    +
    HAL_StatusTypeDef TIM_Delay_NonBlocking(TIM_HandleTypeDef *htim, uint16_t delay)
    Задержка в тиках таймера (неблокирующая).
    +
    HAL_StatusTypeDef TIM_Delay_Start(TIM_HandleTypeDef *htim)
    Начать отсчет неблокирующей задержки.
    +
    HAL_StatusTypeDef TIM_Delay(TIM_HandleTypeDef *htim, uint16_t delay)
    Задержка в тиках таймера (блокирующая).
    +
    +

    Function Documentation

    ◆ TIM_Delay_Start()

    @@ -173,7 +187,7 @@ Functions HAL_StatusTypeDef TIM_Delay ( - TIM_HandleTypeDef * htim, + TIM_HandleTypeDef * htim, @@ -207,7 +221,7 @@ Functions HAL_StatusTypeDef TIM_Delay_NonBlocking ( - TIM_HandleTypeDef * htim, + TIM_HandleTypeDef * htim, @@ -234,10 +248,18 @@ Functions
    + +
    diff --git a/Doc/html/group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html b/Doc/html/group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html index e1af34d..ac2ffb9 100644 --- a/Doc/html/group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html +++ b/Doc/html/group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html @@ -3,7 +3,7 @@ - + MyLibs: Encoder tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Encoder tools
    +
    Encoder tools

    Функции для считывания энкодера More...

    -
    - + Collaboration diagram for Encoder tools:
    +
    Collaboration diagram for Encoder tools:
    - - + -

    +

    Classes

    struct  TIM_EncoderTypeDef
    struct  TIM_EncoderTypeDef
     Структура инициализации енкодера More...
     
    - - - -

    +

    Functions

    HAL_StatusTypeDef TIM_Encoder_Init (TIM_EncoderTypeDef *henc1, TIM_HandleTypeDef *htim)
     Инициализация режима энкодер у таймера.
     
    HAL_StatusTypeDef TIM_Encoder_Read (TIM_EncoderTypeDef *henc)
     Считать энкодер.
     
    int TIM_Encoder_ReadSwitch (TIM_EncoderTypeDef *henc)
     Считать кнопку энкодера.
     
    -

    Detailed Description

    +

    Detailed Description

    Функции для считывания энкодера

    -

    Function Documentation

    +
    Пример использования:
    +
    TIM_HandleTypeDef htim4;
    +
    +
    // инициализация
    +
    henc1.htim = &htim4;
    +
    henc1.GPIOx = GPIOA;
    +
    henc1.GPIO_PIN_TI1 = GPIO_PIN_0;
    +
    henc1.GPIO_PIN_TI2 = GPIO_PIN_1;
    +
    TIM_Encoder_Init(&henc1, &htim4);
    +
    +
    // считывание энкодера и кнопки
    +
    int16_t delta = TIM_Encoder_Read(&henc1);
    +
    setpoint_tmp += delta;
    + +
    {
    +
    setpoint = setpoint_tmp; // подтвердить новое значение
    +
    }
    +
    int TIM_Encoder_ReadSwitch(TIM_EncoderTypeDef *henc)
    Считать кнопку энкодера.
    +
    HAL_StatusTypeDef TIM_Encoder_Init(TIM_EncoderTypeDef *henc1, TIM_HandleTypeDef *htim)
    Инициализация режима энкодер у таймера.
    +
    HAL_StatusTypeDef TIM_Encoder_Read(TIM_EncoderTypeDef *henc)
    Считать энкодер.
    +
    Структура инициализации енкодера
    +
    uint32_t GPIO_PIN_TI1
    Пин, куда подключается канал TI1.
    +
    uint32_t GPIO_PIN_TI2
    Пин, куда подключается канал TI2.
    +
    GPIO_TypeDef * GPIOx
    Порт, куда подключается энкодер
    +
    TIM_HandleTypeDef * htim
    Указатель на HAL handle таймера
    +
    +

    Function Documentation

    ◆ TIM_Encoder_Init()

    @@ -151,7 +166,7 @@ Functions HAL_StatusTypeDef TIM_Encoder_Init ( - TIM_EncoderTypeDef * henc, + TIM_EncoderTypeDef * henc, @@ -235,10 +250,18 @@ Functions
    + +
    diff --git a/Doc/html/group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html b/Doc/html/group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html index ab492db..7e224ac 100644 --- a/Doc/html/group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html +++ b/Doc/html/group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html @@ -3,7 +3,7 @@ - + MyLibs: General tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    General tools
    +
    General tools

    Функции для базовой инициализации таймеров More...

    -
    - + Collaboration diagram for General tools:
    +
    Collaboration diagram for General tools:
    - - + -

    +

    Topics

     Init defines
     Init defines
     Настройка таймеров
     
    - - + -

    +

    Classes

    struct  TIM_SettingsTypeDef
    struct  TIM_SettingsTypeDef
     Структура инициализации таймера More...
     
    - -
    } -

    +

    Enumerations

    enum  TIM_ITModeTypeDef { TIM_DEFAULT = 0 , TIM_IT_MODE = (1<<( 0 )) }
     Режим прерываний таймера More...
     
    enum  TIM_MHzTickBaseTypeDef {
      TIM_Base_Disable = 0 , TIM_TickBase_1US = 1 @@ -155,23 +143,47 @@ Enumerations
     Длительность тика таймера (частота тактирования таймера) More...
     
    - - - -

    +

    Functions

    HAL_StatusTypeDef TIM_Base_Init (TIM_SettingsTypeDef *stim)
     Инициализация таймера.
     
    void TIM_Base_MspInit (TIM_HandleTypeDef *htim, TIM_ITModeTypeDef it_mode)
     Инициализация CLK и NVIC таймеров.
     
    void TIM_Base_MspDeInit (TIM_HandleTypeDef *htim)
     Деинициализация CLK и NVIC таймеров.
     
    -

    Detailed Description

    +

    Detailed Description

    Функции для базовой инициализации таймеров

    -

    Enumeration Type Documentation

    +
    Пример использования:
    TIM_SettingsTypeDef tim2Settings;
    +
    +
    void TIM2_Init(void)
    +
    {
    +
    // Настройка таймера TIM2 на 1 кГц с прерываниями с шагом таймера 10 мкс
    +
    tim2Settings.htim.Instance = TIM2;
    +
    tim2Settings.sTimMode = TIM_IT_MODE;
    + +
    tim2Settings.sTickBasePrescaler = 1;
    +
    tim2Settings.sTimFreqHz = 1000; // 1 кГц
    +
    tim2Settings.sTimAHBFreqMHz = 72000000; // Hz
    +
    +
    if(TIM_Base_Init(&tim2Settings) != HAL_OK)
    +
    {
    +
    Error_Handler();
    +
    }
    +
    }
    +
    HAL_StatusTypeDef TIM_Base_Init(TIM_SettingsTypeDef *stim)
    Инициализация таймера.
    Definition general_tim.c:34
    +
    @ TIM_TickBase_10US
    Таймер тактируется с частотой 100 кГц
    Definition general_tim.h:95
    +
    @ TIM_IT_MODE
    Прерываний включены
    Definition general_tim.h:80
    +
    Структура инициализации таймера
    +
    uint8_t sTickBasePrescaler
    Дополнительный делитель, для удобного деления sTickBaseUS.
    +
    TIM_MHzTickBaseTypeDef sTickBaseUS
    Длительность одного тика
    +
    float sTimAHBFreqMHz
    Частота шины тактирования таймера
    +
    TIM_ITModeTypeDef sTimMode
    Настройки прерывания таймера
    +
    TIM_HandleTypeDef htim
    HAL handle таймера
    +
    float sTimFreqHz
    Желаемая частота таймера
    +
    +

    Enumeration Type Documentation

    ◆ TIM_ITModeTypeDef

    @@ -192,7 +204,7 @@ Functions -

    Definition at line 76 of file general_tim.h.

    +

    Definition at line 77 of file general_tim.h.

    @@ -227,11 +239,11 @@ Functions -

    Definition at line 90 of file general_tim.h.

    +

    Definition at line 91 of file general_tim.h.

    -

    Function Documentation

    +

    Function Documentation

    ◆ TIM_Base_Init()

    @@ -278,7 +290,7 @@ Functions void TIM_Base_MspInit ( - TIM_HandleTypeDef * htim, + TIM_HandleTypeDef * htim, @@ -295,7 +307,7 @@ Functions -
    Note
    Чтобы не генерировать функцию с иницилизацией неиспользуемых таймеров, дефайнами в general_tim.h определяются используемые таймеры.
    +
    Note
    Чтобы не генерировать функцию с иницилизацией неиспользуемых таймеров, дефайнами Init defines в general_tim.h определяются используемые таймеры.

    Definition at line 408 of file general_tim.c.

    @@ -323,7 +335,7 @@ Functions -
    Note
    Чтобы не генерировать функцию с деиницилизацией неиспользуемых таймеров, дефайнами в general_tim.h определяются используемые таймеры.
    +
    Note
    Чтобы не генерировать функцию с деиницилизацией неиспользуемых таймеров, дефайнами Init defines в general_tim.h определяются используемые таймеры.

    Definition at line 617 of file general_tim.c.

    @@ -331,10 +343,18 @@ Functions + + diff --git a/Doc/html/group___m_y_l_i_b_s___t_i_m___o_c.html b/Doc/html/group___m_y_l_i_b_s___t_i_m___o_c.html index 29c0731..2f229a6 100644 --- a/Doc/html/group___m_y_l_i_b_s___t_i_m___o_c.html +++ b/Doc/html/group___m_y_l_i_b_s___t_i_m___o_c.html @@ -3,7 +3,7 @@ - + MyLibs: PWM/OC Channels tools @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    PWM/OC Channels tools
    +
    PWM/OC Channels tools

    Функции для инициализации базовых функций каналов таймера More...

    -
    - + Collaboration diagram for PWM/OC Channels tools:
    +
    Collaboration diagram for PWM/OC Channels tools:
    - - -

    +

    Functions

    HAL_StatusTypeDef TIM_Output_PWM_Init (TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN)
     Инициализация выхода ШИМ таймера.
     
    HAL_StatusTypeDef TIM_OC_Comparator_Init (TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL)
     Инициализация OC компаратора таймера.
     
    -

    Detailed Description

    +

    Detailed Description

    Функции для инициализации базовых функций каналов таймера

    -

    Function Documentation

    +
    Пример использования:
    void PWM_Channel_Init_Example(void)
    +
    {
    +
    TIM_HandleTypeDef htim3;
    +
    TIM_OC_InitTypeDef sConfigOC;
    +
    GPIO_TypeDef *GPIOx = GPIOB;
    +
    uint32_t PWM_PIN = GPIO_PIN_0;
    +
    +
    // Настройка таймера и канала PWM
    +
    TIM_Output_PWM_Init(&htim3, &sConfigOC, TIM_CHANNEL_1, GPIOx, PWM_PIN);
    +
    +
    // Настройка компаратора OC
    +
    TIM_OC_Comparator_Init(&htim3, TIM_CHANNEL_1);
    +
    }
    +
    HAL_StatusTypeDef TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN)
    Инициализация выхода ШИМ таймера.
    +
    HAL_StatusTypeDef TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL)
    Инициализация OC компаратора таймера.
    +
    +

    Function Documentation

    ◆ TIM_Output_PWM_Init()

    @@ -141,22 +149,22 @@ Functions HAL_StatusTypeDef TIM_Output_PWM_Init ( - TIM_HandleTypeDef * htim, + TIM_HandleTypeDef * htim, - TIM_OC_InitTypeDef * sConfigOC, + TIM_OC_InitTypeDef * sConfigOC, - uint32_t TIM_CHANNEL, + uint32_t TIM_CHANNEL, - GPIO_TypeDef * GPIOx, + GPIO_TypeDef * GPIOx, @@ -193,7 +201,7 @@ Functions HAL_StatusTypeDef TIM_OC_Comparator_Init ( - TIM_HandleTypeDef * htim, + TIM_HandleTypeDef * htim, @@ -220,10 +228,18 @@ Functions
    + +
    diff --git a/Doc/html/group___t_i_m___i_n_i_t.html b/Doc/html/group___t_i_m___i_n_i_t.html index 9130ced..5209e6b 100644 --- a/Doc/html/group___t_i_m___i_n_i_t.html +++ b/Doc/html/group___t_i_m___i_n_i_t.html @@ -3,7 +3,7 @@ - + MyLibs: Init defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - - +

    Настройка таймеров More...

    -
    - + Collaboration diagram for Init defines:
    +
    Collaboration diagram for Init defines:
    - - - - - - - - - - - - - - - -

    +

    Macros

    #define HAL_TIM_MODULE_ENABLED
     
    #define USE_TIM1
     Включить TIM1 в TIM_Base_MspInit.
     
    #define USE_TIM2
     Включить TIM2 в TIM_Base_MspInit.
     
    #define USE_TIM3
     Включить TIM3 в TIM_Base_MspInit.
     
    #define USE_TIM4
     Включить TIM4 в TIM_Base_MspInit.
     
    #define USE_TIM5
     Включить TIM5 в TIM_Base_MspInit.
     
    #define USE_TIM6
     Включить TIM6 в TIM_Base_MspInit.
     
    #define USE_TIM7
     Включить TIM7 в TIM_Base_MspInit.
     
    #define USE_TIM8
     Включить TIM8 в TIM_Base_MspInit.
     
    #define USE_TIM9
     Включить TIM9 в TIM_Base_MspInit.
     
    #define USE_TIM10
     Включить TIM10 в TIM_Base_MspInit.
     
    #define USE_TIM11
     Включить TIM11 в TIM_Base_MspInit.
     
    #define USE_TIM12
     Включить TIM12 в TIM_Base_MspInit.
     
    #define USE_TIM13
     Включить TIM13 в TIM_Base_MspInit.
     
    #define USE_TIM14
     Включить TIM14 в TIM_Base_MspInit.
     
    -

    Detailed Description

    +

    Detailed Description

    Настройка таймеров

    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ HAL_TIM_MODULE_ENABLED

    @@ -182,7 +161,7 @@ Macros
    -

    Definition at line 31 of file general_tim.h.

    +

    Definition at line 32 of file general_tim.h.

    @@ -200,7 +179,7 @@ Macros

    Включить TIM1 в TIM_Base_MspInit.

    -

    Definition at line 33 of file general_tim.h.

    +

    Definition at line 34 of file general_tim.h.

    @@ -218,7 +197,7 @@ Macros

    Включить TIM2 в TIM_Base_MspInit.

    -

    Definition at line 34 of file general_tim.h.

    +

    Definition at line 35 of file general_tim.h.

    @@ -236,7 +215,7 @@ Macros

    Включить TIM3 в TIM_Base_MspInit.

    -

    Definition at line 35 of file general_tim.h.

    +

    Definition at line 36 of file general_tim.h.

    @@ -254,7 +233,7 @@ Macros

    Включить TIM4 в TIM_Base_MspInit.

    -

    Definition at line 36 of file general_tim.h.

    +

    Definition at line 37 of file general_tim.h.

    @@ -272,7 +251,7 @@ Macros

    Включить TIM5 в TIM_Base_MspInit.

    -

    Definition at line 37 of file general_tim.h.

    +

    Definition at line 38 of file general_tim.h.

    @@ -290,7 +269,7 @@ Macros

    Включить TIM6 в TIM_Base_MspInit.

    -

    Definition at line 38 of file general_tim.h.

    +

    Definition at line 39 of file general_tim.h.

    @@ -308,7 +287,7 @@ Macros

    Включить TIM7 в TIM_Base_MspInit.

    -

    Definition at line 39 of file general_tim.h.

    +

    Definition at line 40 of file general_tim.h.

    @@ -326,7 +305,7 @@ Macros

    Включить TIM8 в TIM_Base_MspInit.

    -

    Definition at line 40 of file general_tim.h.

    +

    Definition at line 41 of file general_tim.h.

    @@ -344,7 +323,7 @@ Macros

    Включить TIM9 в TIM_Base_MspInit.

    -

    Definition at line 41 of file general_tim.h.

    +

    Definition at line 42 of file general_tim.h.

    @@ -362,7 +341,7 @@ Macros

    Включить TIM10 в TIM_Base_MspInit.

    -

    Definition at line 42 of file general_tim.h.

    +

    Definition at line 43 of file general_tim.h.

    @@ -380,7 +359,7 @@ Macros

    Включить TIM11 в TIM_Base_MspInit.

    -

    Definition at line 43 of file general_tim.h.

    +

    Definition at line 44 of file general_tim.h.

    @@ -398,7 +377,7 @@ Macros

    Включить TIM12 в TIM_Base_MspInit.

    -

    Definition at line 44 of file general_tim.h.

    +

    Definition at line 45 of file general_tim.h.

    @@ -416,7 +395,7 @@ Macros

    Включить TIM13 в TIM_Base_MspInit.

    -

    Definition at line 45 of file general_tim.h.

    +

    Definition at line 46 of file general_tim.h.

    @@ -434,16 +413,24 @@ Macros

    Включить TIM14 в TIM_Base_MspInit.

    -

    Definition at line 46 of file general_tim.h.

    +

    Definition at line 47 of file general_tim.h.

    + + diff --git a/Doc/html/group___t_r_a_c_e.html b/Doc/html/group___t_r_a_c_e.html index 2365c24..6941ffc 100644 --- a/Doc/html/group___t_r_a_c_e.html +++ b/Doc/html/group___t_r_a_c_e.html @@ -3,7 +3,7 @@ - + MyLibs: Trace defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Trace defines
    +
    Trace defines

    Дефайны для работы с трассировкой More...

    -
    - + Collaboration diagram for Trace defines:
    +
    Collaboration diagram for Trace defines:
    - - + - - + - - + - - + -

    +

    Topics

     Serial trace defines
     Serial trace defines
     Дефайны для работы с serial трассировкой (SWO, RTT)
     
     GPIO trace defines
     GPIO trace defines
     Дефайны для работы с GPIO трассировкой
     
     Flash RTT Buffer
     Flash RTT Buffer
     Макросы и функции для сохранения/чтения RTT буфера в Flash.
     
     Hardfault trace defines
     Hardfault trace defines
     Модуль трассировки HardFault с возможностью сохранения RTT буфера во Flash.
     
    -

    Detailed Description

    +

    Detailed Description

    Дефайны для работы с трассировкой

    + +
    diff --git a/Doc/html/group___t_r_a_c_e___c_o_n_f_i_g.html b/Doc/html/group___t_r_a_c_e___c_o_n_f_i_g.html index 99c9556..cd9e6da 100644 --- a/Doc/html/group___t_r_a_c_e___c_o_n_f_i_g.html +++ b/Doc/html/group___t_r_a_c_e___c_o_n_f_i_g.html @@ -3,7 +3,7 @@ - + MyLibs: Trace configs @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Trace configs
    +
    Trace configs

    Конфигурация трекеров и трассировки More...

    -
    - + Collaboration diagram for Trace configs:
    +
    Collaboration diagram for Trace configs:
    - - - - - - - - - - - - - - - - -

    +

    Macros

    #define TRACKERS_ENABLE
     Включить трекеры
     
    #define SERIAL_TRACE_ENABLE
     Включить serial трассировку
     
    #define RTT_TRACE_ENABLE
     Включить serial трассировку через RTT.
     
    #define SWO_TRACE_ENABLE
     Включить serial трассировку через SWO.
     
    #define LOG_LEVEL   1
     Уровень log serial трассировки log_printf.
     
    #define RTT_FLASH_BUFFER_SIZE   1024
     Размер буфера RTT в Flash.
     
    #define RTT_FLASH_SECTOR   FLASH_SECTOR_11
     Сектор FLASH куда положится RTT буфер
     
    #define RTT_FLASH_SECTOR_START   0x080E0000
     Начало сектора RTT_FLASH_SECTOR.
     
    #define RTT_FLASH_SECTOR_END   0x080FFFFF
     Конец сектора RTT_FLASH_SECTOR.
     
    #define HARDFAULT_SERIAL_TRACE
     Включить обработку и serial трассировку Hardfault.
     
    #define HF_RTT_TAG_BASE   0xDEAD0000
     базовый тег для HardFault
     
    #define HF_RTT_TAIL_SIZE   RTT_FLASH_BUFFER_SIZE
     Размер буфера RTT, который сохранится при Hardfault.
     
    #define HF_STACK_DUMP_WORDS   32
     Сколько слов стека будет проанализировано во время Hardfault.
     
    #define HF_FLASH_ADDR   ((uint32_t)0x080FF000)
     Адрес FLASH куда положится RTT буфер
     
    #define HF_RAM_END   0x20030000
     Конец RAM памяти (чтобы во время анализа стека не выйти за пределы)
     
    #define GPIO_TRACE_ENABLE
     Включить GPIO трассировку
     
    -

    Detailed Description

    +

    Detailed Description

    Конфигурация трекеров и трассировки

    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ TRACKERS_ENABLE

    @@ -469,10 +447,18 @@ Macros
    + +
    diff --git a/Doc/html/group___t_r_a_c_e___g_p_i_o.html b/Doc/html/group___t_r_a_c_e___g_p_i_o.html index b0b1874..647e041 100644 --- a/Doc/html/group___t_r_a_c_e___g_p_i_o.html +++ b/Doc/html/group___t_r_a_c_e___g_p_i_o.html @@ -3,7 +3,7 @@ - + MyLibs: GPIO trace defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    GPIO trace defines
    +
    GPIO trace defines

    Дефайны для работы с GPIO трассировкой More...

    -
    - + Collaboration diagram for GPIO trace defines:
    +
    Collaboration diagram for GPIO trace defines:
    - - + - - + -

    +

    Macros

    #define TRACE_GPIO_RESET(_gpio_, _pin_)   (_gpio_)->BSRR = ((_pin_)<<16)
    #define TRACE_GPIO_RESET(_gpio_, _pin_)
     Сбросить указанную ножку GPIO.
     
    #define TRACE_GPIO_SET(_gpio_, _pin_)   (_gpio_)->BSRR = (((_pin_)))
    #define TRACE_GPIO_SET(_gpio_, _pin_)
     Установить указанную ножку GPIO.
     
    -

    Detailed Description

    +

    Detailed Description

    Дефайны для работы с GPIO трассировкой

    Определяется дефайны для работы с GPIO трассировкой:

    • TRACE_GPIO_RESET() - для сброса ножки GPIO (через BSRR)
    • TRACE_GPIO_SET() - для выставления ножки GPIO (через BSRR)
    • -
    • Если трассировка GPIO_TRACE_ENABLE отключена, то все дефайны определяются как 'ничего' и на производительность кода не влияют
      -
    • +
    • Если трассировка GPIO_TRACE_ENABLE отключена, то все дефайны определяются как 'ничего' и на производительность кода не влияют
    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ TRACE_GPIO_RESET

    @@ -147,16 +138,17 @@ Macros #define TRACE_GPIO_RESET ( - _gpio_, + _gpio_, - _pin_ )   (_gpio_)->BSRR = ((_pin_)<<16) + _pin_ )
    - +Value:
    (_gpio_)->BSRR = ((_pin_)<<16)
    +

    Сбросить указанную ножку GPIO.

    Parameters
    @@ -170,7 +162,7 @@ Macros
  • GPIO_TRACE_ENABLE определён - устанавливает бит сброса через BSRR ((pin)<<16)
  • -

    Definition at line 142 of file trace.h.

    +

    Definition at line 155 of file trace.h.

    @@ -183,16 +175,17 @@ Macros - + - +
    #define TRACE_GPIO_SET ( _gpio_, _gpio_,
    _pin_ )   (_gpio_)->BSRR = (((_pin_))) _pin_ )
    - +Value:
    (_gpio_)->BSRR = (((_pin_)))
    +

    Установить указанную ножку GPIO.

    Parameters
    @@ -206,16 +199,24 @@ Macros
  • GPIO_TRACE_ENABLE определён - устанавливает бит установки через BSRR (pin)
  • -

    Definition at line 141 of file trace.h.

    +

    Definition at line 154 of file trace.h.

    + + diff --git a/Doc/html/group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html b/Doc/html/group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html index a75a57e..4f37553 100644 --- a/Doc/html/group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html +++ b/Doc/html/group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html @@ -3,7 +3,7 @@ - +MyLibs: Hardfault trace defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + +
    @@ -73,10 +71,9 @@ $(function() {
    +
    - -
    Hardfault trace defines
    +
    Hardfault trace defines

    Модуль трассировки HardFault с возможностью сохранения RTT буфера во Flash. More...

    -
    - + Collaboration diagram for Hardfault trace defines:
    +
    Collaboration diagram for Hardfault trace defines:
    - - + -

    +

    Classes

    struct  HF_StackFrame_t
    struct  HF_StackFrame_t
     Контекст стек-фрейма процессора при HardFault. More...
     
    - - -

    +

    Functions

    __STATIC_FORCEINLINE int HF_CheckRecovered (int erase)
     Проверка и вывод последнего HardFault-трейса из Flash.
     
    __STATIC_FORCEINLINE void HF_HandleFault (void)
     Обработчик HardFault.
     
    -

    Detailed Description

    +

    Detailed Description

    Модуль трассировки HardFault с возможностью сохранения RTT буфера во Flash.

    Этот модуль позволяет сохранять контекст процессора и последние символы RTT буфера при возникновении HardFault.

    Механизм работы:

      @@ -176,10 +166,10 @@ Functions
      RTT_EraseFlash(); // erase rtt flash after message readed
      }
      }
      -
      __STATIC_FORCEINLINE int HF_CheckRecovered(int erase)
      Проверка и вывод последнего HardFault-трейса из Flash.
      Definition trace.h:486
      -
      __STATIC_FORCEINLINE void HF_HandleFault(void)
      Обработчик HardFault.
      Definition trace.h:527
      -
      __STATIC_FORCEINLINE int RTT_EraseFlash(void)
      Стирание сектора Flash с RTT-буфером
      Definition trace.h:375
      -

    Function Documentation

    +
    __STATIC_FORCEINLINE int HF_CheckRecovered(int erase)
    Проверка и вывод последнего HardFault-трейса из Flash.
    Definition trace.h:499
    +
    __STATIC_FORCEINLINE void HF_HandleFault(void)
    Обработчик HardFault.
    Definition trace.h:540
    +
    __STATIC_FORCEINLINE int RTT_EraseFlash(void)
    Стирание сектора Flash с RTT-буфером
    Definition trace.h:388
    +

    Function Documentation

    ◆ HF_CheckRecovered()

    @@ -204,7 +194,7 @@ Functions
    Note
    Вызов рекомендуется при инициализации приложения для анализа предыдущего сбоя.
    -

    Definition at line 486 of file trace.h.

    +

    Definition at line 499 of file trace.h.

    @@ -217,7 +207,7 @@ Functions __STATIC_FORCEINLINE void HF_HandleFault ( - void ) + void ) @@ -234,16 +224,24 @@ Functions
    Note
    Функция защищена, так как вызывается в контексте сбоя — минимизирует использование вызовов HAL.
    -

    Definition at line 527 of file trace.h.

    +

    Definition at line 540 of file trace.h.

    + + diff --git a/Doc/html/group___t_r_a_c_e___r_t_t___f_l_a_s_h.html b/Doc/html/group___t_r_a_c_e___r_t_t___f_l_a_s_h.html index b401ff0..20cd2c9 100644 --- a/Doc/html/group___t_r_a_c_e___r_t_t___f_l_a_s_h.html +++ b/Doc/html/group___t_r_a_c_e___r_t_t___f_l_a_s_h.html @@ -3,7 +3,7 @@ - + MyLibs: Flash RTT Buffer @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Flash RTT Buffer
    +
    Flash RTT Buffer

    Макросы и функции для сохранения/чтения RTT буфера в Flash. More...

    -
    - + Collaboration diagram for Flash RTT Buffer:
    +
    Collaboration diagram for Flash RTT Buffer:
    - - + -

    +

    Classes

    struct  RTT_FlashHeader_t
    struct  RTT_FlashHeader_t
     Структура RTT, которая будет положена в Flash. More...
     
    - - - - -

    +

    Functions

    __STATIC_FORCEINLINE void RTT_FlashPrepare (void)
     Подготовка Flash к записи
     
    __STATIC_FORCEINLINE int RTT_SaveToFlash (uint32_t tag, uint32_t tail_size)
     Сохраняет последние символы RTT-буфера в Flash по тегу
     
    __STATIC_FORCEINLINE int RTT_ReadFromFlash (uint32_t tag, char *Buffer, uint32_t tail_size, uint32_t *read_size)
     Читает последние символы RTT-буфера из Flash по тегу
     
    __STATIC_FORCEINLINE int RTT_EraseFlash (void)
     Стирание сектора Flash с RTT-буфером
     
    -

    Detailed Description

    +

    Detailed Description

    Макросы и функции для сохранения/чтения RTT буфера в Flash.

    Модуль позволяет сохранять данные RTT буфера во Flash и читать их обратно по тегам.
    Теги работают следующим образом:
    @@ -163,7 +151,7 @@ Functions

  • RTT_FLASH_SECTOR_START - Начало сектора RTT_FLASH_SECTOR
  • RTT_FLASH_SECTOR_END - Конец сектора RTT_FLASH_SECTOR
  • -

    Function Documentation

    +

    Function Documentation

    ◆ RTT_FlashPrepare()

    @@ -173,7 +161,7 @@ Functions __STATIC_FORCEINLINE void RTT_FlashPrepare ( - void ) + void ) @@ -182,7 +170,7 @@ Functions

    Подготовка Flash к записи

    Сбрасывает ошибки Flash и ожидает готовности перед записью

    -

    Definition at line 190 of file trace.h.

    +

    Definition at line 203 of file trace.h.

    @@ -195,7 +183,7 @@ Functions __STATIC_FORCEINLINE int RTT_SaveToFlash ( - uint32_t tag, + uint32_t tag, @@ -220,7 +208,7 @@ Functions
  • Если конкретный (младший байт != 0) — запись выполняется только с этим тегом, иначе ошибка.
  • -

    Definition at line 214 of file trace.h.

    +

    Definition at line 227 of file trace.h.

    @@ -233,17 +221,17 @@ Functions __STATIC_FORCEINLINE int RTT_ReadFromFlash ( - uint32_t tag, + uint32_t tag, - char * Buffer, + char * Buffer, - uint32_t tail_size, + uint32_t tail_size, @@ -269,7 +257,7 @@ Functions
  • Если конкретный (младший байт != 0) — прочитывается именно эта запись.
  • -

    Definition at line 311 of file trace.h.

    +

    Definition at line 324 of file trace.h.

    @@ -282,7 +270,7 @@ Functions __STATIC_FORCEINLINE int RTT_EraseFlash ( - void ) + void ) @@ -290,16 +278,24 @@ Functions

    Стирание сектора Flash с RTT-буфером

    -

    Definition at line 375 of file trace.h.

    +

    Definition at line 388 of file trace.h.

    + + diff --git a/Doc/html/group___t_r_a_c_e___s_e_r_i_a_l.html b/Doc/html/group___t_r_a_c_e___s_e_r_i_a_l.html index a2019a0..ca0045f 100644 --- a/Doc/html/group___t_r_a_c_e___s_e_r_i_a_l.html +++ b/Doc/html/group___t_r_a_c_e___s_e_r_i_a_l.html @@ -3,7 +3,7 @@ - + MyLibs: Serial trace defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Serial trace defines
    +
    Serial trace defines

    Дефайны для работы с serial трассировкой (SWO, RTT) More...

    -
    - + Collaboration diagram for Serial trace defines:
    +
    Collaboration diagram for Serial trace defines:
    - - + - - - +

    +

    Macros

    #define my_printf(...)   SEGGER_RTT_printf(0, __VA_ARGS__)
    #define my_printf(...)
     Универсальный макрос для вывода трассировки
     
    #define log_printf(TAG, fmt, ...)
     Макрос логирования с поддержкой уровней LOG_LEVEL.
     
     Макрос логирования с поддержкой уровней LOG_LEVEL.
    -

    Detailed Description

    +

    Detailed Description

    Дефайны для работы с serial трассировкой (SWO, RTT)

    В зависимости от настроек определяется дефайн my_printf() и log_printf() для работы с трассировкой:

    • SERIAL_TRACE_ENABLE - Если трассировка отключена, то все дефайны определяются как 'ничего' и на производительность кода не влияют
    • -
    • RTT_TRACE_ENABLE - для RTT это будет вызов функции SEGGER_RTT_printf(), с подключением библиотеки SEGGER_RTT.h Предварительно надо подключить библиотеку SEGGER RTT и вызвать функцию SEGGER_RTT_Init()
    • +
    • RTT_TRACE_ENABLE - для RTT это будет вызов функции SEGGER_RTT_printf()

      +

      Предварительно надо подключить библиотеку SEGGER RTT (SEGGER_RTT.h) и вызвать функцию SEGGER_RTT_Init()

      +
    • SWO_TRACE_ENABLE для SWO это будет просто printf()

      -

      Но библиотеку STDOUT надо подключить самостоятельно:

      -
          Manage Run-Time Environment -> Compiler -> I/O -> STDOUT 

      Для SWO также надо включить трассировку:
      +

      Предварительно надо подключить библиотеку STDOUT и retarget под ITM:

      +
          Manage Run-Time Environment -> Compiler -> I/O -> STDOUT -> ITM
      +

      Для SWO также надо включить трассировку:

      -
          Options For Target -> Debug -> Debugger Settings

      В вкладке Debug:

        +
            Options For Target -> Debug -> Debugger Settings
        +

        В вкладке Debug:

        • Port = SW В вкладке Trace:
        • Указать Core Clock
        • Выставить Trace Port = SWO
        • -
        • ITM - выбрать нужный порт (для Keil нулевой порт)
          -
        • +
        • ITM - выбрать нужный порт (для Keil нулевой порт)
      -

      Macro Definition Documentation

      +

      Macro Definition Documentation

      ◆ my_printf

      @@ -157,20 +152,21 @@ Macros #define my_printf ( - ...) -    SEGGER_RTT_printf(0, __VA_ARGS__) + ...) +
    - +Value:
    SEGGER_RTT_printf(0, __VA_ARGS__)
    +

    Универсальный макрос для вывода трассировки

    Варианты реализации:

      -
    • RTT_TRACE_ENABLE SEGGER_RTT_printf(0, ...)
    • -
    • SWO_TRACE_ENABLE - printf(...)
    • +
    • RTT_TRACE_ENABLE SEGGER_RTT_printf(0, ...)
    • +
    • SWO_TRACE_ENABLE - printf(...)
    • NO_TRACE - пустой макрос
    -

    Definition at line 71 of file trace.h.

    +

    Definition at line 80 of file trace.h.

    @@ -183,25 +179,26 @@ Macros #define log_printf ( - TAG, + TAG, - fmt, + fmt, - ... ) + ... )
    Value:
    my_printf("\n[%lu] [%s] " fmt, \
    -
    (unsigned long)uwTick, TAG, ##__VA_ARGS__)
    -
    #define my_printf(...)
    Универсальный макрос для вывода трассировки
    Definition trace.h:71
    +
    (unsigned long)local_time(), TAG, ##__VA_ARGS__)
    +
    #define local_time()
    Локальное время
    +
    #define my_printf(...)
    Универсальный макрос для вывода трассировки
    Definition trace.h:80
    -

    Макрос логирования с поддержкой уровней LOG_LEVEL.

    +

    Макрос логирования с поддержкой уровней LOG_LEVEL.

    Parameters
    @@ -210,21 +207,33 @@ Macros

    Варианты реализации:

      -
    • LOG_LEVEL == 0 - логирование отключено (макрос пустой)
    • -
    • LOG_LEVEL == 1 - выводится время и TAG
    • -
    • LOG_LEVEL >= 2 - выводится время, TAG, имя файла и номер строки
    • +
    • LOG_LEVEL == 0 - логирование отключено (макрос пустой)
    • +
    • LOG_LEVEL == 1 - выводится время local_time и TAG
      [123] [ADC] Measure Done
      +
      [456] [ADC] Measure Err
      +
    • +
    • LOG_LEVEL >= 2 - выводится время, TAG, имя файла и номер строки
      [123] [ADC] (../Core/Src/adc.c:75) Measure Done
      +
      [456] [ADC] (../Core/Src/adc.c:80) Measure Err
      +
    -

    Definition at line 96 of file trace.h.

    +

    Definition at line 109 of file trace.h.

    + + diff --git a/Doc/html/group___t_r_a_c_k_e_r_s.html b/Doc/html/group___t_r_a_c_k_e_r_s.html index 09abab2..66db708 100644 --- a/Doc/html/group___t_r_a_c_k_e_r_s.html +++ b/Doc/html/group___t_r_a_c_k_e_r_s.html @@ -3,7 +3,7 @@ - +MyLibs: Trackers defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    TAGТэг лога
    - + +
    @@ -73,10 +71,9 @@ $(function() { +
    - -
    Trackers defines
    +
    Trackers defines

    Дефайны для работы с трекерами More...

    -
    - + Collaboration diagram for Trackers defines:
    +
    Collaboration diagram for Trackers defines:
    - - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + -

    +

    Macros

    #define TrackerTypeDef(num_user_vars)
     Структура для счетчиков отладки
     
    #define num_of_usercnts(_user_)   (sizeof(_user_) / sizeof(uint32_t))
    #define num_of_usercnts(_user_)
     Получить количетство пользовательских переменных
     
    #define assert_usertracker(_cntstruct_, _uservarnumb_)   ((_uservarnumb_) < num_of_usercnts((_cntstruct_).user))
    #define assert_usertracker(_cntstruct_, _uservarnumb_)
     Проверка существует ли указанная пользовательская переменная
     
    #define if_assert_usertracker(_cntstruct_, _uservarnumb_)   if(assert_usertracker(_cntstruct_, _uservarnumb_))
    #define if_assert_usertracker(_cntstruct_, _uservarnumb_)
     Условие для проверки существует ли указанная пользовательская переменная
     
    #define tern_assert_usertracker(_cntstruct_, _uservarnumb_)   (assert_usertracker(_cntstruct_, _uservarnumb_)) ? _uservarnumb_ : 0
    #define tern_assert_usertracker(_cntstruct_, _uservarnumb_)
     Тернарный оператор для проверки существует ли указанная пользовательская переменная
     
    #define TrackerGet_Ok(_cntstruct_)   (_cntstruct_).cnt_ok
    #define TrackerGet_Ok(_cntstruct_)
     Считать счетчик успешных событий
     
    #define TrackerGet_Err(_cntstruct_)   (_cntstruct_).cnt_err
    #define TrackerGet_Err(_cntstruct_)
     Считать счетчик ошибок
     
    #define TrackerGet_Warn(_cntstruct_)   (_cntstruct_).cnt_warn
    #define TrackerGet_Warn(_cntstruct_)
     Считать счетчик предупреждений
     
    #define TrackerGet_User(_cntstruct_, _uservarnumb_)   (_cntstruct_).user[tern_assert_usertracker(_cntstruct_, _uservarnumb_)]
    #define TrackerGet_User(_cntstruct_, _uservarnumb_)
     Считать пользовательскую переменную
     
    #define TrackerCnt_Ok(_cntstruct_)   (_cntstruct_).cnt_ok++
    #define TrackerCnt_Ok(_cntstruct_)
     Инкрементирование счетчика успешных событий
     
    #define TrackerCnt_Err(_cntstruct_)   (_cntstruct_).cnt_err++
    #define TrackerCnt_Err(_cntstruct_)
     Инкрементирование счетчика ошибок
     
    #define TrackerCnt_Warn(_cntstruct_)   (_cntstruct_).cnt_warn++
    #define TrackerCnt_Warn(_cntstruct_)
     Инкрементирование счетчика предупреждений
     
    #define TrackerCnt_User(_cntstruct_, _uservarnumb_)   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_]++;
    #define TrackerCnt_User(_cntstruct_, _uservarnumb_)
     Инкрементирование пользовательской переменной
     
    #define TrackerWrite_User(_cntstruct_, _uservarnumb_, _val_)   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = (_val_)
    #define TrackerWrite_User(_cntstruct_, _uservarnumb_, _val_)
     Запись числа в пользовательскую переменную
     
    #define TrackerClear_All(_cntstruct_)   memset(&(_cntstruct_), 0, sizeof(_cntstruct_))
    #define TrackerClear_All(_cntstruct_)
     Очистка всей структуры
     
    #define TrackerClear_Ok(_cntstruct_)   (_cntstruct_).cnt_ok = 0
    #define TrackerClear_Ok(_cntstruct_)
     Очистка счетчика успешных событий
     
    #define TrackerClear_Err(_cntstruct_)   (_cntstruct_).cnt_err = 0
    #define TrackerClear_Err(_cntstruct_)
     Очистка счетчика ошибок
     
    #define TrackerClear_Warn(_cntstruct_)   (_cntstruct_).cnt_warn = 0
    #define TrackerClear_Warn(_cntstruct_)
     Очистка счетчика предупреждений
     
    #define TrackerClear_User(_cntstruct_, _uservarnumb_)   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = 0;
    #define TrackerClear_User(_cntstruct_, _uservarnumb_)
     Очистка пользовательской переменной
     
    #define TrackerClear_UserAll(_cntstruct_)   memset(&(_cntstruct_).user, 0, sizeof((_cntstruct_).user))
    #define TrackerClear_UserAll(_cntstruct_)
     Очистка всех пользовательских переменных
     
    -

    Detailed Description

    +

    Detailed Description

    Дефайны для работы с трекерами


    Есть дефайн для объявления структуры трекера: TrackerTypeDef(num_user_vars). Структура состоит из следующих элементов:

    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ TrackerTypeDef

    @@ -238,7 +211,7 @@ Macros #define TrackerTypeDef ( - num_user_vars) + num_user_vars) @@ -274,12 +247,13 @@ Macros #define num_of_usercnts ( - _user_) -    (sizeof(_user_) / sizeof(uint32_t)) + _user_) +
    - +Value:
    (sizeof(_user_) / sizeof(uint32_t))
    +

    Получить количетство пользовательских переменных

    Definition at line 80 of file trackers.h.

    @@ -295,16 +269,18 @@ Macros #define assert_usertracker ( - _cntstruct_, + _cntstruct_, - _uservarnumb_ )   ((_uservarnumb_) < num_of_usercnts((_cntstruct_).user)) + _uservarnumb_ )
    - +Value:
    ((_uservarnumb_) < num_of_usercnts((_cntstruct_).user))
    +
    #define num_of_usercnts(_user_)
    Получить количетство пользовательских переменных
    Definition trackers.h:80
    +

    Проверка существует ли указанная пользовательская переменная

    Definition at line 82 of file trackers.h.

    @@ -320,16 +296,18 @@ Macros #define if_assert_usertracker ( - _cntstruct_, + _cntstruct_, - _uservarnumb_ )   if(assert_usertracker(_cntstruct_, _uservarnumb_)) + _uservarnumb_ )
    - +Value:
    if(assert_usertracker(_cntstruct_, _uservarnumb_))
    +
    #define assert_usertracker(_cntstruct_, _uservarnumb_)
    Проверка существует ли указанная пользовательская переменная
    Definition trackers.h:82
    +

    Условие для проверки существует ли указанная пользовательская переменная

    Definition at line 84 of file trackers.h.

    @@ -345,16 +323,17 @@ Macros #define tern_assert_usertracker ( - _cntstruct_, + _cntstruct_, - _uservarnumb_ )   (assert_usertracker(_cntstruct_, _uservarnumb_)) ? _uservarnumb_ : 0 + _uservarnumb_ )
    - +Value:
    (assert_usertracker(_cntstruct_, _uservarnumb_)) ? _uservarnumb_ : 0
    +

    Тернарный оператор для проверки существует ли указанная пользовательская переменная

    Definition at line 86 of file trackers.h.

    @@ -370,12 +349,13 @@ Macros #define TrackerGet_Ok ( - _cntstruct_) -    (_cntstruct_).cnt_ok + _cntstruct_) +
    - +Value:
    (_cntstruct_).cnt_ok
    +

    Считать счетчик успешных событий

    Definition at line 90 of file trackers.h.

    @@ -391,12 +371,13 @@ Macros #define TrackerGet_Err ( - _cntstruct_) -    (_cntstruct_).cnt_err + _cntstruct_) +
    - +Value:
    (_cntstruct_).cnt_err
    +

    Считать счетчик ошибок

    Definition at line 92 of file trackers.h.

    @@ -412,12 +393,13 @@ Macros #define TrackerGet_Warn ( - _cntstruct_) -    (_cntstruct_).cnt_warn + _cntstruct_) +
    - +Value:
    (_cntstruct_).cnt_warn
    +

    Считать счетчик предупреждений

    Definition at line 94 of file trackers.h.

    @@ -433,16 +415,18 @@ Macros #define TrackerGet_User ( - _cntstruct_, + _cntstruct_, - _uservarnumb_ )   (_cntstruct_).user[tern_assert_usertracker(_cntstruct_, _uservarnumb_)] + _uservarnumb_ )
    - +Value:
    (_cntstruct_).user[tern_assert_usertracker(_cntstruct_, _uservarnumb_)]
    +
    #define tern_assert_usertracker(_cntstruct_, _uservarnumb_)
    Тернарный оператор для проверки существует ли указанная пользовательская переменная
    Definition trackers.h:86
    +

    Считать пользовательскую переменную

    Note
    Здесь нет проверки - существует ли пользовательская переменная! Есть возможность выйти за границы структуры!!! Чтобы этого избежать можно использовать дефайн #ref assert_usertracker()
      if(assert_usertracker(struct, 0)) {
           TrackerGet_User(struct, 0)
    @@ -462,12 +446,13 @@ Macros
             
               #define TrackerCnt_Ok
               (
    -                    _cntstruct_)
    -             (_cntstruct_).cnt_ok++
    +                    _cntstruct_)
    +          
             
           
     
    - +Value:
    (_cntstruct_).cnt_ok++
    +

    Инкрементирование счетчика успешных событий

    Definition at line 111 of file trackers.h.

    @@ -483,12 +468,13 @@ Macros #define TrackerCnt_Err ( - _cntstruct_) -    (_cntstruct_).cnt_err++ + _cntstruct_) +
    - +Value:
    (_cntstruct_).cnt_err++
    +

    Инкрементирование счетчика ошибок

    Definition at line 113 of file trackers.h.

    @@ -504,12 +490,13 @@ Macros #define TrackerCnt_Warn ( - _cntstruct_) -    (_cntstruct_).cnt_warn++ + _cntstruct_) +
    - +Value:
    (_cntstruct_).cnt_warn++
    +

    Инкрементирование счетчика предупреждений

    Definition at line 115 of file trackers.h.

    @@ -525,16 +512,18 @@ Macros #define TrackerCnt_User ( - _cntstruct_, + _cntstruct_, - _uservarnumb_ )   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_]++; + _uservarnumb_ )
    - +Value:
    if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_]++;
    +
    #define if_assert_usertracker(_cntstruct_, _uservarnumb_)
    Условие для проверки существует ли указанная пользовательская переменная
    Definition trackers.h:84
    +

    Инкрементирование пользовательской переменной

    Definition at line 117 of file trackers.h.

    @@ -550,21 +539,22 @@ Macros #define TrackerWrite_User ( - _cntstruct_, + _cntstruct_, - _uservarnumb_, + _uservarnumb_, - _val_ )   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = (_val_) + _val_ )
    - +Value:
    if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = (_val_)
    +

    Запись числа в пользовательскую переменную

    Definition at line 119 of file trackers.h.

    @@ -580,12 +570,13 @@ Macros #define TrackerClear_All ( - _cntstruct_) -    memset(&(_cntstruct_), 0, sizeof(_cntstruct_)) + _cntstruct_) +
    - +Value:
    memset(&(_cntstruct_), 0, sizeof(_cntstruct_))
    +

    Очистка всей структуры

    Definition at line 122 of file trackers.h.

    @@ -601,12 +592,13 @@ Macros #define TrackerClear_Ok ( - _cntstruct_) -    (_cntstruct_).cnt_ok = 0 + _cntstruct_) +
    - +Value:
    (_cntstruct_).cnt_ok = 0
    +

    Очистка счетчика успешных событий

    Definition at line 124 of file trackers.h.

    @@ -622,12 +614,13 @@ Macros #define TrackerClear_Err ( - _cntstruct_) -    (_cntstruct_).cnt_err = 0 + _cntstruct_) +
    - +Value:
    (_cntstruct_).cnt_err = 0
    +

    Очистка счетчика ошибок

    Definition at line 126 of file trackers.h.

    @@ -643,12 +636,13 @@ Macros #define TrackerClear_Warn ( - _cntstruct_) -    (_cntstruct_).cnt_warn = 0 + _cntstruct_) +
    - +Value:
    (_cntstruct_).cnt_warn = 0
    +

    Очистка счетчика предупреждений

    Definition at line 128 of file trackers.h.

    @@ -664,16 +658,17 @@ Macros #define TrackerClear_User ( - _cntstruct_, + _cntstruct_, - _uservarnumb_ )   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = 0; + _uservarnumb_ )
    - +Value:
    if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = 0;
    +

    Очистка пользовательской переменной

    Definition at line 130 of file trackers.h.

    @@ -689,12 +684,13 @@ Macros #define TrackerClear_UserAll ( - _cntstruct_) -    memset(&(_cntstruct_).user, 0, sizeof((_cntstruct_).user)) + _cntstruct_) +
    - +Value:
    memset(&(_cntstruct_).user, 0, sizeof((_cntstruct_).user))
    +

    Очистка всех пользовательских переменных

    Definition at line 132 of file trackers.h.

    @@ -703,10 +699,18 @@ Macros
    + +
    diff --git a/Doc/html/group___u_t_i_l_s___d_e_f_i_n_e_s.html b/Doc/html/group___u_t_i_l_s___d_e_f_i_n_e_s.html index 847999e..72b22b5 100644 --- a/Doc/html/group___u_t_i_l_s___d_e_f_i_n_e_s.html +++ b/Doc/html/group___u_t_i_l_s___d_e_f_i_n_e_s.html @@ -3,7 +3,7 @@ - + MyLibs: Utils defines @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    Utils defines
    +
    Utils defines

    Общие вспомогательные макросы More...

    -
    - + Collaboration diagram for Utils defines:
    +
    Collaboration diagram for Utils defines:
    - - + - - + - - + - - + -

    +

    Macros

    #define ClearStruct(_struct_)   memset(&(_struct_), 0, sizeof(_struct_))
    #define ClearStruct(_struct_)
     Обнуление структуры.
     
    #define Divide_Up(_val_, _div_)   ((_val_ - 1) / _div_) + 1 /* через мат выражение */
    #define Divide_Up(_val_, _div_)
     Деление с округлением вверх
     
    #define ByteSwap16(v)   (((v&0xFF00) >> (8)) | ((v&0x00FF) << (8)))
    #define ByteSwap16(v)
     Swap between Little Endian and Big Endian.
     
    #define ABS(x)   ( ((x) > 0)? (x) : -(x))
    #define ABS(x)
     Абсолютное значение числа
     
    -

    Detailed Description

    +

    Detailed Description

    Общие вспомогательные макросы

    -

    Macro Definition Documentation

    +

    Macro Definition Documentation

    ◆ ClearStruct

    @@ -147,12 +137,13 @@ Macros #define ClearStruct ( - _struct_) -    memset(&(_struct_), 0, sizeof(_struct_)) + _struct_) +
    - +Value:
    memset(&(_struct_), 0, sizeof(_struct_))
    +

    Обнуление структуры.

    Parameters
    @@ -162,7 +153,7 @@ Macros

    Макрос использует memset для обнуления всей памяти структуры. Используется для быстрой и безопасной инициализации переменных структур до нуля.

    -

    Definition at line 151 of file mylibs_defs.h.

    +

    Definition at line 155 of file mylibs_defs.h.

    @@ -175,16 +166,17 @@ Macros - + - +
    #define Divide_Up ( _val_, _val_,
    _div_ )   ((_val_ - 1) / _div_) + 1 /* через мат выражение */ _div_ )
    - +Value:
    ((_val_ - 1) / _div_) + 1 /* через мат выражение */
    +

    Деление с округлением вверх

    Parameters
    @@ -196,7 +188,7 @@ Macros
    Returns
    Результат деления, округленный вверх.

    Если результат деления без остатка: он возвращается как есть Если с остатком - округляется вверх

    -

    Definition at line 162 of file mylibs_defs.h.

    +

    Definition at line 166 of file mylibs_defs.h.

    @@ -209,12 +201,13 @@ Macros - - + +
    #define ByteSwap16 ( v)   (((v&0xFF00) >> (8)) | ((v&0x00FF) << (8))) v)
    - +Value:
    (((v&0xFF00) >> (8)) | ((v&0x00FF) << (8)))
    +

    Swap between Little Endian and Big Endian.

    Parameters
    @@ -225,7 +218,7 @@ Macros
    Returns
    Результат с поменяными местами старшим и младшим байтом.

    Переключения между двумя типами хранения слова: HI-LO байты и LO-HI байты.

    -

    Definition at line 170 of file mylibs_defs.h.

    +

    Definition at line 174 of file mylibs_defs.h.

    @@ -238,12 +231,13 @@ Macros - - + +
    #define ABS ( x)   ( ((x) > 0)? (x) : -(x)) x)
    - +Value:
    ( ((x) > 0)? (x) : -(x))
    +

    Абсолютное значение числа

    Parameters
    @@ -254,16 +248,24 @@ Macros
    Returns
    Абсолютное значение числа x.

    Берет число по модулю. Хз как работает библиотечный abs в stdlib.h, мб это быстрее, но вряд ли конечно.

    -

    Definition at line 178 of file mylibs_defs.h.

    +

    Definition at line 182 of file mylibs_defs.h.

    + + diff --git a/Doc/html/index.html b/Doc/html/index.html index 3916f2b..bea1476 100644 --- a/Doc/html/index.html +++ b/Doc/html/index.html @@ -3,7 +3,7 @@ - +MyLibs: MyLibs @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + +
    @@ -73,10 +71,9 @@ $(function() {
    +
    MyLibs
    -

    +

    Обзор

    -

    MyLibs - это набор библиотек для удобной работы с периферией микроконтроллеров STM32.

    -

    +

    MyLibs - это набор библиотек для удобной работы с STM32.

    +

    Основные возможности

    -

    +

    Общие утилиты (General Tools)

    • Макросы для задержек и утилит (Delays defines и Utils defines)
    • @@ -116,7 +113,7 @@ $(function(){initNavTree('index.html',''); initResizable(); });
    • Эволюционный алгоритм для оптимизации параметров (Evolve optimizer)
    • Битовый доступ к регистрам через union (Bit access defines)
    -

    +

    Трассировка Trace defines

    • Serial трассировка через SWO и RTT (Serial trace defines)
    • @@ -124,14 +121,14 @@ $(function(){initNavTree('index.html',''); initResizable(); });
    • Сохранение логов в Flash память (Flash RTT Buffer)
    • Обработка HardFault с сохранением контекста (Hardfault trace defines)
    -

    +

    Модуль GPIO GPIO Tools

    • Инициализация портов и тактирования (General tools)
    • Управление светодиодами (включение/выключение, моргание, плавное затухание) (LED tools)
    • Работа с кнопками (чтение состояния, фильтрация дребезга) (Switch tools)
    -

    +

    Модуль таймеров TIM Tools

    • Базовая инициализация таймеров (General tools)
    • @@ -139,21 +136,36 @@ $(function(){initNavTree('index.html',''); initResizable(); });
    • Работа с энкодерами (чтение положения, обработка кнопок) (Encoder tools)
    • Настройка ШИМ и Output Compare (PWM/OC Channels tools)
    -

    +

    +Модуль UART UART Tools

    +
      +
    • Базовая инициализация UART и его пинов одной функцией (UART_Base_Init)
    • +
    +

    +Модуль SPI SPI Tools

    +
      +
    • Базовая инициализация SPI и пинов одной функцией (SPI_Base_Init)
    • +
    +

    Структура проекта

    ├── inc/ # Заголовочные файлы
    │ ├── mylibs_include.h # Главный include файл
    │ ├── mylibs_config.h # Конфигурация библиотек
    │ ├── mylibs_defs.h # Общие определения и макросы
    │ ├── bit_access.h # Битовый доступ к регистрам
    +
    │ ├── evolve_optimizer.h # Оптимизатор (генетический алгоритм)
    │ ├── trackers.h # Трекеры для отладки
    │ ├── trace.h # Трассировка и логирование
    │ ├── general_gpio.h # Работа с GPIO
    +
    ├── general_spi.h # Работа с SPI
    │ └── general_tim.h # Работа с таймерами
    +
    ├── general_uart.h # Работа с UART
    └── src/ # Исходные файлы
    ├── general_gpio.c # Реализация GPIO
    +
    ├── general_spi.c # Реализация SPI
    └── general_tim.c # Реализация TIM
    -

    +
    ├── general_uart.c # Реализация UART
    +

    Использование

    Инструкция по подключению:

      @@ -161,65 +173,17 @@ $(function(){initNavTree('index.html',''); initResizable(); });
    1. Подключите главный заголовочный файл:
      #include "mylibs_include.h"
      Заголочный файл для всех библиотек
    2. -
    3. Используйте нужные модули в своем коде
    4. +
    5. Используйте нужные модули в своем коде. Примеры использования приведены в соответствующей теме
    -

    -Пример работы с GPIO

    -
    // Инициализация светодиода
    -
    MX_GPIO_Init();
    - -
    GPIO_LED_Init(&led, GPIOA, GPIO_PIN_5, 1);
    -
    -
    // Включение светодиода
    - -
    -
    // Запуск моргания
    -
    GPIO_LED_Blink_Start(&led, 500); // Период 500 мс
    -
    -
    // В основном цикле
    -
    while (1) {
    - -
    }
    -
    HAL_StatusTypeDef GPIO_LED_On(GPIO_LEDTypeDef *led)
    Включить светодиод
    -
    HAL_StatusTypeDef GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State)
    Инициализировать светодиод (структуру светодиода)
    -
    void GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led)
    Управление динамическими режимами свечения светодиода
    -
    HAL_StatusTypeDef GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period)
    Активировать моргание светодиодом
    -
    Структура светодиода
    -

    -Пример работы с таймером

    -
    // Настройка таймера
    -
    TIM_SettingsTypeDef tim_settings = {0};
    -
    tim_settings.htim.Instance = TIM2;
    -
    tim_settings.sTimAHBFreqMHz = SystemCoreClock;
    - -
    tim_settings.sTimFreqHz = 1000; // 1 кГц
    -
    tim_settings.sTimMode = TIM_IT_CONF;
    -
    -
    TIM_Base_Init(&tim_settings);
    -
    HAL_TIM_Base_Start(&tim_settings.htim);
    -
    HAL_StatusTypeDef TIM_Base_Init(TIM_SettingsTypeDef *stim)
    Инициализация таймера.
    Definition general_tim.c:34
    -
    @ TIM_TickBase_1MS
    Таймер тактируется с частотой 1 кГц
    Definition general_tim.h:96
    -
    Структура инициализации таймера
    -
    TIM_MHzTickBaseTypeDef sTickBaseUS
    Длительность одного тика
    -
    float sTimAHBFreqMHz
    Частота шины тактирования таймера
    -
    TIM_ITModeTypeDef sTimMode
    Настройки прерывания таймера
    -
    TIM_HandleTypeDef htim
    HAL handle таймера
    -
    float sTimFreqHz
    Желаемая частота таймера
    -

    -Зависимости

    -
      -
    • HAL библиотека STM32
    • -
    • SEGGER RTT (опционально, для RTT трассировки)
    • -
    • FreeRTOS (опционально, для FreeRTOS задержек)
    • -
    - +
    + diff --git a/Doc/html/jquery.js b/Doc/html/jquery.js index 1dffb65..875ada7 100644 --- a/Doc/html/jquery.js +++ b/Doc/html/jquery.js @@ -1,17 +1,143 @@ /*! jQuery v3.6.0 | (c) OpenJS Foundation and other contributors | jquery.org/license */ -!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType&&"function"!=typeof e.item},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.6.0",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e&&e.namespaceURI,n=e&&(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},j=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||D,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,D=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="",y.option=!!ce.lastChild;var ge={thead:[1,"","
    "],col:[2,"","
    "],tr:[2,"","
    "],td:[3,"","
    "],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n",""]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d\s*$/g;function je(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function De(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function qe(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Le(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var _t,zt=[],Ut=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=zt.pop()||S.expando+"_"+wt.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Ut.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ut.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Ut,"$1"+r):!1!==e.jsonp&&(e.url+=(Tt.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,zt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((_t=E.implementation.createHTMLDocument("").body).innerHTML="
    ",2===_t.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=Fe(y.pixelPosition,function(e,t){if(t)return t=We(e,n),Pe.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp( +"^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"�":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType +}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c +)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){ +return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e&&e.namespaceURI,n=e&&(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll( +":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id") +)&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push( +"\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test( +a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},j=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null, +null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne +).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||D,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,D=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for( +var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="",y.option=!!ce.lastChild;var ge={thead:[1,"","
    "],col:[2,"","
    "],tr:[2,"","
    "],td:[3,"","
    "],_default:[0,"",""]};function ve(e,t){var n; +return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n",""]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d\s*$/g;function je(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function De(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function qe(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Le(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0, +r=s[i].length;n").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var _t,zt=[],Ut=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=zt.pop()||S.expando+"_"+wt.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Ut.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ut.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Ut,"$1"+r):!1!==e.jsonp&&(e.url+=(Tt.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r] +,C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,zt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((_t=E.implementation.createHTMLDocument("").body).innerHTML="
    ",2===_t.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each( +function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r, +"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=Fe(y.pixelPosition,function(e,t){if(t)return t=We(e,n),Pe.test(t)?S(e).position()[n]+"px":t})} +),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each( +"blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0",options:{classes:{},disabled:!1,create:null},_createWidget:function(t,e){e=y(e||this.defaultElement||this)[0],this.element=y(e),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=y(),this.hoverable=y(),this.focusable=y(),this.classesElementLookup={},e!==this&&(y.data(e,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===e&&this.destroy()}}),this.document=y(e.style?e.ownerDocument:e.document||e),this.window=y(this.document[0].defaultView||this.document[0].parentWindow)),this.options=y.widget.extend({},this.options,this._getCreateOptions(),t),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:y.noop,_create:y.noop,_init:y.noop,destroy:function(){var i=this;this._destroy(),y.each(this.classesElementLookup,function(t,e){i._removeClass(e,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:y.noop,widget:function(){return this.element},option:function(t,e){var i,s,n,o=t;if(0===arguments.length)return y.widget.extend({},this.options);if("string"==typeof t)if(o={},t=(i=t.split(".")).shift(),i.length){for(s=o[t]=y.widget.extend({},this.options[t]),n=0;n
    "),i=e.children()[0];return y("body").append(e),t=i.offsetWidth,e.css("overflow","scroll"),t===(i=i.offsetWidth)&&(i=e[0].clientWidth),e.remove(),s=t-i},getScrollInfo:function(t){var e=t.isWindow||t.isDocument?"":t.element.css("overflow-x"),i=t.isWindow||t.isDocument?"":t.element.css("overflow-y"),e="scroll"===e||"auto"===e&&t.widthx(D(s),D(n))?o.important="horizontal":o.important="vertical",p.using.call(this,t,o)}),h.offset(y.extend(l,{using:t}))})},y.ui.position={fit:{left:function(t,e){var i=e.within,s=i.isWindow?i.scrollLeft:i.offset.left,n=i.width,o=t.left-e.collisionPosition.marginLeft,h=s-o,a=o+e.collisionWidth-n-s;e.collisionWidth>n?0n?0=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),y.ui.plugin={add:function(t,e,i){var s,n=y.ui[t].prototype;for(s in i)n.plugins[s]=n.plugins[s]||[],n.plugins[s].push([e,i[s]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;n").css({overflow:"hidden",position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,t={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(t),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(t),this._proportionallyResize()),this._setupHandles(),e.autoHide&&y(this.element).on("mouseenter",function(){e.disabled||(i._removeClass("ui-resizable-autohide"),i._handles.show())}).on("mouseleave",function(){e.disabled||i.resizing||(i._addClass("ui-resizable-autohide"),i._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy(),this._addedHandles.remove();function t(t){y(t).removeData("resizable").removeData("ui-resizable").off(".resizable")}var e;return this.elementIsWrapper&&(t(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),t(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;case"aspectRatio":this._aspectRatio=!!e}},_setupHandles:function(){var t,e,i,s,n,o=this.options,h=this;if(this.handles=o.handles||(y(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=y(),this._addedHandles=y(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),i=this.handles.split(","),this.handles={},e=0;e"),this._addClass(n,"ui-resizable-handle "+s),n.css({zIndex:o.zIndex}),this.handles[t]=".ui-resizable-"+t,this.element.children(this.handles[t]).length||(this.element.append(n),this._addedHandles=this._addedHandles.add(n));this._renderAxis=function(t){var e,i,s;for(e in t=t||this.element,this.handles)this.handles[e].constructor===String?this.handles[e]=this.element.children(this.handles[e]).first().show():(this.handles[e].jquery||this.handles[e].nodeType)&&(this.handles[e]=y(this.handles[e]),this._on(this.handles[e],{mousedown:h._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(i=y(this.handles[e],this.element),s=/sw|ne|nw|se|n|s/.test(e)?i.outerHeight():i.outerWidth(),i=["padding",/ne|nw|n/.test(e)?"Top":/se|sw|s/.test(e)?"Bottom":/^e$/.test(e)?"Right":"Left"].join(""),t.css(i,s),this._proportionallyResize()),this._handles=this._handles.add(this.handles[e])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){h.resizing||(this.className&&(n=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),h.axis=n&&n[1]?n[1]:"se")}),o.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._addedHandles.remove()},_mouseCapture:function(t){var e,i,s=!1;for(e in this.handles)(i=y(this.handles[e])[0])!==t.target&&!y.contains(i,t.target)||(s=!0);return!this.options.disabled&&s},_mouseStart:function(t){var e,i,s=this.options,n=this.element;return this.resizing=!0,this._renderProxy(),e=this._num(this.helper.css("left")),i=this._num(this.helper.css("top")),s.containment&&(e+=y(s.containment).scrollLeft()||0,i+=y(s.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:e,top:i},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:n.width(),height:n.height()},this.originalSize=this._helper?{width:n.outerWidth(),height:n.outerHeight()}:{width:n.width(),height:n.height()},this.sizeDiff={width:n.outerWidth()-n.width(),height:n.outerHeight()-n.height()},this.originalPosition={left:e,top:i},this.originalMousePosition={left:t.pageX,top:t.pageY},this.aspectRatio="number"==typeof s.aspectRatio?s.aspectRatio:this.originalSize.width/this.originalSize.height||1,s=y(".ui-resizable-"+this.axis).css("cursor"),y("body").css("cursor","auto"===s?this.axis+"-resize":s),this._addClass("ui-resizable-resizing"),this._propagate("start",t),!0},_mouseDrag:function(t){var e=this.originalMousePosition,i=this.axis,s=t.pageX-e.left||0,e=t.pageY-e.top||0,i=this._change[i];return this._updatePrevProperties(),i&&(e=i.apply(this,[t,s,e]),this._updateVirtualBoundaries(t.shiftKey),(this._aspectRatio||t.shiftKey)&&(e=this._updateRatio(e,t)),e=this._respectSize(e,t),this._updateCache(e),this._propagate("resize",t),e=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),y.isEmptyObject(e)||(this._updatePrevProperties(),this._trigger("resize",t,this.ui()),this._applyChanges())),!1},_mouseStop:function(t){this.resizing=!1;var e,i,s,n=this.options,o=this;return this._helper&&(s=(e=(i=this._proportionallyResizeElements).length&&/textarea/i.test(i[0].nodeName))&&this._hasScroll(i[0],"left")?0:o.sizeDiff.height,i=e?0:o.sizeDiff.width,e={width:o.helper.width()-i,height:o.helper.height()-s},i=parseFloat(o.element.css("left"))+(o.position.left-o.originalPosition.left)||null,s=parseFloat(o.element.css("top"))+(o.position.top-o.originalPosition.top)||null,n.animate||this.element.css(y.extend(e,{top:s,left:i})),o.helper.height(o.size.height),o.helper.width(o.size.width),this._helper&&!n.animate&&this._proportionallyResize()),y("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",t),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s=this.options,n={minWidth:this._isNumber(s.minWidth)?s.minWidth:0,maxWidth:this._isNumber(s.maxWidth)?s.maxWidth:1/0,minHeight:this._isNumber(s.minHeight)?s.minHeight:0,maxHeight:this._isNumber(s.maxHeight)?s.maxHeight:1/0};(this._aspectRatio||t)&&(e=n.minHeight*this.aspectRatio,i=n.minWidth/this.aspectRatio,s=n.maxHeight*this.aspectRatio,t=n.maxWidth/this.aspectRatio,e>n.minWidth&&(n.minWidth=e),i>n.minHeight&&(n.minHeight=i),st.width,h=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,a=this.originalPosition.left+this.originalSize.width,r=this.originalPosition.top+this.originalSize.height,l=/sw|nw|w/.test(i),i=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),h&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=a-e.minWidth),s&&l&&(t.left=a-e.maxWidth),h&&i&&(t.top=r-e.minHeight),n&&i&&(t.top=r-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];e<4;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;e").css({overflow:"hidden"}),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++e.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize;return{left:this.originalPosition.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize;return{top:this.originalPosition.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(t,e,i){return y.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[t,e,i]))},sw:function(t,e,i){return y.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[t,e,i]))},ne:function(t,e,i){return y.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[t,e,i]))},nw:function(t,e,i){return y.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[t,e,i]))}},_propagate:function(t,e){y.ui.plugin.call(this,t,[e,this.ui()]),"resize"!==t&&this._trigger(t,e,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),y.ui.plugin.add("resizable","animate",{stop:function(e){var i=y(this).resizable("instance"),t=i.options,s=i._proportionallyResizeElements,n=s.length&&/textarea/i.test(s[0].nodeName),o=n&&i._hasScroll(s[0],"left")?0:i.sizeDiff.height,h=n?0:i.sizeDiff.width,n={width:i.size.width-h,height:i.size.height-o},h=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,o=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(y.extend(n,o&&h?{top:o,left:h}:{}),{duration:t.animateDuration,easing:t.animateEasing,step:function(){var t={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};s&&s.length&&y(s[0]).css({width:t.width,height:t.height}),i._updateCache(t),i._propagate("resize",e)}})}}),y.ui.plugin.add("resizable","containment",{start:function(){var i,s,n=y(this).resizable("instance"),t=n.options,e=n.element,o=t.containment,h=o instanceof y?o.get(0):/parent/.test(o)?e.parent().get(0):o;h&&(n.containerElement=y(h),/document/.test(o)||o===document?(n.containerOffset={left:0,top:0},n.containerPosition={left:0,top:0},n.parentData={element:y(document),left:0,top:0,width:y(document).width(),height:y(document).height()||document.body.parentNode.scrollHeight}):(i=y(h),s=[],y(["Top","Right","Left","Bottom"]).each(function(t,e){s[t]=n._num(i.css("padding"+e))}),n.containerOffset=i.offset(),n.containerPosition=i.position(),n.containerSize={height:i.innerHeight()-s[3],width:i.innerWidth()-s[1]},t=n.containerOffset,e=n.containerSize.height,o=n.containerSize.width,o=n._hasScroll(h,"left")?h.scrollWidth:o,e=n._hasScroll(h)?h.scrollHeight:e,n.parentData={element:h,left:t.left,top:t.top,width:o,height:e}))},resize:function(t){var e=y(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.position,o=e._aspectRatio||t.shiftKey,h={top:0,left:0},a=e.containerElement,t=!0;a[0]!==document&&/static/.test(a.css("position"))&&(h=s),n.left<(e._helper?s.left:0)&&(e.size.width=e.size.width+(e._helper?e.position.left-s.left:e.position.left-h.left),o&&(e.size.height=e.size.width/e.aspectRatio,t=!1),e.position.left=i.helper?s.left:0),n.top<(e._helper?s.top:0)&&(e.size.height=e.size.height+(e._helper?e.position.top-s.top:e.position.top),o&&(e.size.width=e.size.height*e.aspectRatio,t=!1),e.position.top=e._helper?s.top:0),i=e.containerElement.get(0)===e.element.parent().get(0),n=/relative|absolute/.test(e.containerElement.css("position")),i&&n?(e.offset.left=e.parentData.left+e.position.left,e.offset.top=e.parentData.top+e.position.top):(e.offset.left=e.element.offset().left,e.offset.top=e.element.offset().top),n=Math.abs(e.sizeDiff.width+(e._helper?e.offset.left-h.left:e.offset.left-s.left)),s=Math.abs(e.sizeDiff.height+(e._helper?e.offset.top-h.top:e.offset.top-s.top)),n+e.size.width>=e.parentData.width&&(e.size.width=e.parentData.width-n,o&&(e.size.height=e.size.width/e.aspectRatio,t=!1)),s+e.size.height>=e.parentData.height&&(e.size.height=e.parentData.height-s,o&&(e.size.width=e.size.height*e.aspectRatio,t=!1)),t||(e.position.left=e.prevPosition.left,e.position.top=e.prevPosition.top,e.size.width=e.prevSize.width,e.size.height=e.prevSize.height)},stop:function(){var t=y(this).resizable("instance"),e=t.options,i=t.containerOffset,s=t.containerPosition,n=t.containerElement,o=y(t.helper),h=o.offset(),a=o.outerWidth()-t.sizeDiff.width,o=o.outerHeight()-t.sizeDiff.height;t._helper&&!e.animate&&/relative/.test(n.css("position"))&&y(this).css({left:h.left-s.left-i.left,width:a,height:o}),t._helper&&!e.animate&&/static/.test(n.css("position"))&&y(this).css({left:h.left-s.left-i.left,width:a,height:o})}}),y.ui.plugin.add("resizable","alsoResize",{start:function(){var t=y(this).resizable("instance").options;y(t.alsoResize).each(function(){var t=y(this);t.data("ui-resizable-alsoresize",{width:parseFloat(t.width()),height:parseFloat(t.height()),left:parseFloat(t.css("left")),top:parseFloat(t.css("top"))})})},resize:function(t,i){var e=y(this).resizable("instance"),s=e.options,n=e.originalSize,o=e.originalPosition,h={height:e.size.height-n.height||0,width:e.size.width-n.width||0,top:e.position.top-o.top||0,left:e.position.left-o.left||0};y(s.alsoResize).each(function(){var t=y(this),s=y(this).data("ui-resizable-alsoresize"),n={},e=t.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];y.each(e,function(t,e){var i=(s[e]||0)+(h[e]||0);i&&0<=i&&(n[e]=i||null)}),t.css(n)})},stop:function(){y(this).removeData("ui-resizable-alsoresize")}}),y.ui.plugin.add("resizable","ghost",{start:function(){var t=y(this).resizable("instance"),e=t.size;t.ghost=t.originalElement.clone(),t.ghost.css({opacity:.25,display:"block",position:"relative",height:e.height,width:e.width,margin:0,left:0,top:0}),t._addClass(t.ghost,"ui-resizable-ghost"),!1!==y.uiBackCompat&&"string"==typeof t.options.ghost&&t.ghost.addClass(this.options.ghost),t.ghost.appendTo(t.helper)},resize:function(){var t=y(this).resizable("instance");t.ghost&&t.ghost.css({position:"relative",height:t.size.height,width:t.size.width})},stop:function(){var t=y(this).resizable("instance");t.ghost&&t.helper&&t.helper.get(0).removeChild(t.ghost.get(0))}}),y.ui.plugin.add("resizable","grid",{resize:function(){var t,e=y(this).resizable("instance"),i=e.options,s=e.size,n=e.originalSize,o=e.originalPosition,h=e.axis,a="number"==typeof i.grid?[i.grid,i.grid]:i.grid,r=a[0]||1,l=a[1]||1,u=Math.round((s.width-n.width)/r)*r,p=Math.round((s.height-n.height)/l)*l,d=n.width+u,c=n.height+p,f=i.maxWidth&&i.maxWidthd,s=i.minHeight&&i.minHeight>c;i.grid=a,m&&(d+=r),s&&(c+=l),f&&(d-=r),g&&(c-=l),/^(se|s|e)$/.test(h)?(e.size.width=d,e.size.height=c):/^(ne)$/.test(h)?(e.size.width=d,e.size.height=c,e.position.top=o.top-p):/^(sw)$/.test(h)?(e.size.width=d,e.size.height=c,e.position.left=o.left-u):((c-l<=0||d-r<=0)&&(t=e._getPaddingPlusBorderDimensions(this)),0",options:{classes:{},disabled:!1,create:null},_createWidget:function(t,e){e=y(e||this.defaultElement||this)[0],this.element=y(e),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=y(),this.hoverable=y(),this.focusable=y(),this.classesElementLookup={},e!==this&&(y.data(e,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t +){t.target===e&&this.destroy()}}),this.document=y(e.style?e.ownerDocument:e.document||e),this.window=y(this.document[0].defaultView||this.document[0].parentWindow)),this.options=y.widget.extend({},this.options,this._getCreateOptions(),t),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:y.noop,_create:y.noop,_init:y.noop,destroy:function(){var i=this;this._destroy(),y.each(this.classesElementLookup,function(t,e){i._removeClass(e,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:y.noop,widget:function(){return this.element},option:function(t,e){var i,s,n,o=t;if(0===arguments.length)return y.widget.extend({},this.options);if("string"==typeof t)if(o={},t=(i=t.split(".")).shift(),i.length){for(s=o[t +]=y.widget.extend({},this.options[t]),n=0;n
    "),i=e.children()[0];return y("body").append(e),t=i.offsetWidth,e.css("overflow","scroll"),t===(i=i.offsetWidth)&&(i=e[0].clientWidth),e.remove(),s=t-i}, +getScrollInfo:function(t){var e=t.isWindow||t.isDocument?"":t.element.css("overflow-x"),i=t.isWindow||t.isDocument?"":t.element.css("overflow-y"),e="scroll"===e||"auto"===e&&t.widthx(D(s),D(n))?o.important="horizontal":o.important="vertical",p.using.call(this,t,o)}),h.offset(y.extend(l,{using:t}))})},y.ui.position={fit:{left:function(t,e){var i=e.within, +s=i.isWindow?i.scrollLeft:i.offset.left,n=i.width,o=t.left-e.collisionPosition.marginLeft,h=s-o,a=o+e.collisionWidth-n-s;e.collisionWidth>n?0n?0=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),y.ui.plugin={add:function(t,e,i){var s,n=y.ui[t].prototype;for(s in i)n.plugins[s]=n.plugins[s]||[],n.plugins[s].push([e,i[s]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;n").css({overflow:"hidden",position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})), +this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,t={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(t),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(t),this._proportionallyResize()),this._setupHandles(),e.autoHide&&y(this.element).on("mouseenter",function(){e.disabled||(i._removeClass("ui-resizable-autohide"),i._handles.show())}).on("mouseleave",function(){e.disabled||i.resizing||(i._addClass("ui-resizable-autohide"),i._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy(),this._addedHandles.remove();function t(t){y(t +).removeData("resizable").removeData("ui-resizable").off(".resizable")}var e;return this.elementIsWrapper&&(t(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),t(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;case"aspectRatio":this._aspectRatio=!!e}},_setupHandles:function(){var t,e,i,s,n,o=this.options,h=this;if(this.handles=o.handles||(y(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=y(),this._addedHandles=y(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),i=this.handles.split( +","),this.handles={},e=0;e"),this._addClass(n,"ui-resizable-handle "+s),n.css({zIndex:o.zIndex}),this.handles[t]=".ui-resizable-"+t,this.element.children(this.handles[t]).length||(this.element.append(n),this._addedHandles=this._addedHandles.add(n));this._renderAxis=function(t){var e,i,s;for(e in t=t||this.element,this.handles)this.handles[e].constructor===String?this.handles[e]=this.element.children(this.handles[e]).first().show():(this.handles[e].jquery||this.handles[e].nodeType)&&(this.handles[e]=y(this.handles[e]),this._on(this.handles[e],{mousedown:h._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(i=y(this.handles[e],this.element),s=/sw|ne|nw|se|n|s/.test(e)?i.outerHeight():i.outerWidth(),i=["padding",/ne|nw|n/.test(e)?"Top":/se|sw|s/.test(e)?"Bottom":/^e$/.test(e)?"Right":"Left"].join(""),t.css(i,s),this._proportionallyResize()),this._handles=this._handles.add( +this.handles[e])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){h.resizing||(this.className&&(n=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),h.axis=n&&n[1]?n[1]:"se")}),o.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._addedHandles.remove()},_mouseCapture:function(t){var e,i,s=!1;for(e in this.handles)(i=y(this.handles[e])[0])!==t.target&&!y.contains(i,t.target)||(s=!0);return!this.options.disabled&&s},_mouseStart:function(t){var e,i,s=this.options,n=this.element;return this.resizing=!0,this._renderProxy(),e=this._num(this.helper.css("left")),i=this._num(this.helper.css("top")),s.containment&&(e+=y(s.containment).scrollLeft()||0,i+=y(s.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:e,top:i},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{ +width:n.width(),height:n.height()},this.originalSize=this._helper?{width:n.outerWidth(),height:n.outerHeight()}:{width:n.width(),height:n.height()},this.sizeDiff={width:n.outerWidth()-n.width(),height:n.outerHeight()-n.height()},this.originalPosition={left:e,top:i},this.originalMousePosition={left:t.pageX,top:t.pageY},this.aspectRatio="number"==typeof s.aspectRatio?s.aspectRatio:this.originalSize.width/this.originalSize.height||1,s=y(".ui-resizable-"+this.axis).css("cursor"),y("body").css("cursor","auto"===s?this.axis+"-resize":s),this._addClass("ui-resizable-resizing"),this._propagate("start",t),!0},_mouseDrag:function(t){var e=this.originalMousePosition,i=this.axis,s=t.pageX-e.left||0,e=t.pageY-e.top||0,i=this._change[i];return this._updatePrevProperties(),i&&(e=i.apply(this,[t,s,e]),this._updateVirtualBoundaries(t.shiftKey),(this._aspectRatio||t.shiftKey)&&(e=this._updateRatio(e,t)),e=this._respectSize(e,t),this._updateCache(e),this._propagate("resize",t),e=this._applyChanges(), +!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),y.isEmptyObject(e)||(this._updatePrevProperties(),this._trigger("resize",t,this.ui()),this._applyChanges())),!1},_mouseStop:function(t){this.resizing=!1;var e,i,s,n=this.options,o=this;return this._helper&&(s=(e=(i=this._proportionallyResizeElements).length&&/textarea/i.test(i[0].nodeName))&&this._hasScroll(i[0],"left")?0:o.sizeDiff.height,i=e?0:o.sizeDiff.width,e={width:o.helper.width()-i,height:o.helper.height()-s},i=parseFloat(o.element.css("left"))+(o.position.left-o.originalPosition.left)||null,s=parseFloat(o.element.css("top"))+(o.position.top-o.originalPosition.top)||null,n.animate||this.element.css(y.extend(e,{top:s,left:i})),o.helper.height(o.size.height),o.helper.width(o.size.width),this._helper&&!n.animate&&this._proportionallyResize()),y("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",t),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){ +this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s=this.options,n={minWidth:this._isNumber(s.minWidth)?s.minWidth:0,maxWidth:this._isNumber(s.maxWidth)?s.maxWidth:1/0,minHeight:this._isNumber(s.minHeight)?s.minHeight:0,maxHeight:this._isNumber(s.maxHeight)?s.maxHeight:1/0};(this._aspectRatio||t)&&(e=n.minHeight*this.aspectRatio,i=n.minWidth/this.aspectRatio,s=n.maxHeight*this.aspectRatio,t=n.maxWidth/this.aspectRatio,e>n.minWidth&&(n.minWidth=e),i>n.minHeight&&(n.minHeight=i),st.width,h=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,a=this.originalPosition.left+this.originalSize.width,r=this.originalPosition.top+this.originalSize.height +,l=/sw|nw|w/.test(i),i=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),h&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=a-e.minWidth),s&&l&&(t.left=a-e.maxWidth),h&&i&&(t.top=r-e.minHeight),n&&i&&(t.top=r-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];e<4;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;e").css({overflow:"hidden"}),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++e.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize;return{left:this.originalPosition.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize;return{top:this.originalPosition.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(t,e,i){return y.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[t,e,i]))},sw:function(t,e, +i){return y.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[t,e,i]))},ne:function(t,e,i){return y.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[t,e,i]))},nw:function(t,e,i){return y.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[t,e,i]))}},_propagate:function(t,e){y.ui.plugin.call(this,t,[e,this.ui()]),"resize"!==t&&this._trigger(t,e,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),y.ui.plugin.add("resizable","animate",{stop:function(e){var i=y(this).resizable("instance"),t=i.options,s=i._proportionallyResizeElements,n=s.length&&/textarea/i.test(s[0].nodeName),o=n&&i._hasScroll(s[0],"left")?0:i.sizeDiff.height,h=n?0:i.sizeDiff.width,n={width:i.size.width-h,height:i.size.height-o},h=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left +)||null,o=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(y.extend(n,o&&h?{top:o,left:h}:{}),{duration:t.animateDuration,easing:t.animateEasing,step:function(){var t={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};s&&s.length&&y(s[0]).css({width:t.width,height:t.height}),i._updateCache(t),i._propagate("resize",e)}})}}),y.ui.plugin.add("resizable","containment",{start:function(){var i,s,n=y(this).resizable("instance"),t=n.options,e=n.element,o=t.containment,h=o instanceof y?o.get(0):/parent/.test(o)?e.parent().get(0):o;h&&(n.containerElement=y(h),/document/.test(o)||o===document?(n.containerOffset={left:0,top:0},n.containerPosition={left:0,top:0},n.parentData={element:y(document),left:0,top:0,width:y(document).width(),height:y(document).height()||document.body.parentNode.scrollHeight}):(i=y(h),s=[],y(["Top","Right","Left","Bottom"]).each(function(t,e +){s[t]=n._num(i.css("padding"+e))}),n.containerOffset=i.offset(),n.containerPosition=i.position(),n.containerSize={height:i.innerHeight()-s[3],width:i.innerWidth()-s[1]},t=n.containerOffset,e=n.containerSize.height,o=n.containerSize.width,o=n._hasScroll(h,"left")?h.scrollWidth:o,e=n._hasScroll(h)?h.scrollHeight:e,n.parentData={element:h,left:t.left,top:t.top,width:o,height:e}))},resize:function(t){var e=y(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.position,o=e._aspectRatio||t.shiftKey,h={top:0,left:0},a=e.containerElement,t=!0;a[0]!==document&&/static/.test(a.css("position"))&&(h=s),n.left<(e._helper?s.left:0)&&(e.size.width=e.size.width+(e._helper?e.position.left-s.left:e.position.left-h.left),o&&(e.size.height=e.size.width/e.aspectRatio,t=!1),e.position.left=i.helper?s.left:0),n.top<(e._helper?s.top:0)&&(e.size.height=e.size.height+(e._helper?e.position.top-s.top:e.position.top),o&&(e.size.width=e.size.height*e.aspectRatio,t=!1),e.position.top=e._helper?s.top:0), +i=e.containerElement.get(0)===e.element.parent().get(0),n=/relative|absolute/.test(e.containerElement.css("position")),i&&n?(e.offset.left=e.parentData.left+e.position.left,e.offset.top=e.parentData.top+e.position.top):(e.offset.left=e.element.offset().left,e.offset.top=e.element.offset().top),n=Math.abs(e.sizeDiff.width+(e._helper?e.offset.left-h.left:e.offset.left-s.left)),s=Math.abs(e.sizeDiff.height+(e._helper?e.offset.top-h.top:e.offset.top-s.top)),n+e.size.width>=e.parentData.width&&(e.size.width=e.parentData.width-n,o&&(e.size.height=e.size.width/e.aspectRatio,t=!1)),s+e.size.height>=e.parentData.height&&(e.size.height=e.parentData.height-s,o&&(e.size.width=e.size.height*e.aspectRatio,t=!1)),t||(e.position.left=e.prevPosition.left,e.position.top=e.prevPosition.top,e.size.width=e.prevSize.width,e.size.height=e.prevSize.height)},stop:function(){var t=y(this).resizable("instance"),e=t.options,i=t.containerOffset,s=t.containerPosition,n=t.containerElement,o=y(t.helper),h=o.offset(),a=o.outerWidth( +)-t.sizeDiff.width,o=o.outerHeight()-t.sizeDiff.height;t._helper&&!e.animate&&/relative/.test(n.css("position"))&&y(this).css({left:h.left-s.left-i.left,width:a,height:o}),t._helper&&!e.animate&&/static/.test(n.css("position"))&&y(this).css({left:h.left-s.left-i.left,width:a,height:o})}}),y.ui.plugin.add("resizable","alsoResize",{start:function(){var t=y(this).resizable("instance").options;y(t.alsoResize).each(function(){var t=y(this);t.data("ui-resizable-alsoresize",{width:parseFloat(t.width()),height:parseFloat(t.height()),left:parseFloat(t.css("left")),top:parseFloat(t.css("top"))})})},resize:function(t,i){var e=y(this).resizable("instance"),s=e.options,n=e.originalSize,o=e.originalPosition,h={height:e.size.height-n.height||0,width:e.size.width-n.width||0,top:e.position.top-o.top||0,left:e.position.left-o.left||0};y(s.alsoResize).each(function(){var t=y(this),s=y(this).data("ui-resizable-alsoresize"),n={},e=t.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];y.each(e, +function(t,e){var i=(s[e]||0)+(h[e]||0);i&&0<=i&&(n[e]=i||null)}),t.css(n)})},stop:function(){y(this).removeData("ui-resizable-alsoresize")}}),y.ui.plugin.add("resizable","ghost",{start:function(){var t=y(this).resizable("instance"),e=t.size;t.ghost=t.originalElement.clone(),t.ghost.css({opacity:.25,display:"block",position:"relative",height:e.height,width:e.width,margin:0,left:0,top:0}),t._addClass(t.ghost,"ui-resizable-ghost"),!1!==y.uiBackCompat&&"string"==typeof t.options.ghost&&t.ghost.addClass(this.options.ghost),t.ghost.appendTo(t.helper)},resize:function(){var t=y(this).resizable("instance");t.ghost&&t.ghost.css({position:"relative",height:t.size.height,width:t.size.width})},stop:function(){var t=y(this).resizable("instance");t.ghost&&t.helper&&t.helper.get(0).removeChild(t.ghost.get(0))}}),y.ui.plugin.add("resizable","grid",{resize:function(){var t,e=y(this).resizable("instance"),i=e.options,s=e.size,n=e.originalSize,o=e.originalPosition,h=e.axis,a="number"==typeof i.grid?[i.grid,i.grid]:i.grid,r=a[0 +]||1,l=a[1]||1,u=Math.round((s.width-n.width)/r)*r,p=Math.round((s.height-n.height)/l)*l,d=n.width+u,c=n.height+p,f=i.maxWidth&&i.maxWidthd,s=i.minHeight&&i.minHeight>c;i.grid=a,m&&(d+=r),s&&(c+=l),f&&(d-=r),g&&(c-=l),/^(se|s|e)$/.test(h)?(e.size.width=d,e.size.height=c):/^(ne)$/.test(h)?(e.size.width=d,e.size.height=c,e.position.top=o.top-p):/^(sw)$/.test(h)?(e.size.width=d,e.size.height=c,e.position.left=o.left-u):((c-l<=0||d-r<=0)&&(t=e._getPaddingPlusBorderDimensions(this)),0=f[g]?0:Math.min(f[g],n));!a&&1=f[g]?0:Math.min(f[g],n));!a&&1-1){targetElements.on(evt+EVENT_NAMESPACE,function elementToggle(event){$.powerTip.toggle(this,event)})}else{targetElements.on(evt+EVENT_NAMESPACE,function elementOpen(event){$.powerTip.show(this,event)})}});$.each(options.closeEvents,function(idx,evt){if($.inArray(evt,options.openEvents)<0){targetElements.on(evt+EVENT_NAMESPACE,function elementClose(event){$.powerTip.hide(this,!isMouseEvent(event))})}});targetElements.on("keydown"+EVENT_NAMESPACE,function elementKeyDown(event){if(event.keyCode===27){$.powerTip.hide(this,true)}})}return targetElements};$.fn.powerTip.defaults={fadeInTime:200,fadeOutTime:100,followMouse:false,popupId:"powerTip",popupClass:null,intentSensitivity:7,intentPollInterval:100,closeDelay:100,placement:"n",smartPlacement:false,offset:10,mouseOnToPopup:false,manual:false,openEvents:["mouseenter","focus"],closeEvents:["mouseleave","blur"]};$.fn.powerTip.smartPlacementLists={n:["n","ne","nw","s"],e:["e","ne","se","w","nw","sw","n","s","e"],s:["s","se","sw","n"],w:["w","nw","sw","e","ne","se","n","s","w"],nw:["nw","w","sw","n","s","se","nw"],ne:["ne","e","se","n","s","sw","ne"],sw:["sw","w","nw","s","n","ne","sw"],se:["se","e","ne","s","n","nw","se"],"nw-alt":["nw-alt","n","ne-alt","sw-alt","s","se-alt","w","e"],"ne-alt":["ne-alt","n","nw-alt","se-alt","s","sw-alt","e","w"],"sw-alt":["sw-alt","s","se-alt","nw-alt","n","ne-alt","w","e"],"se-alt":["se-alt","s","sw-alt","ne-alt","n","nw-alt","e","w"]};$.powerTip={show:function apiShowTip(element,event){if(isMouseEvent(event)){trackMouse(event);session.previousX=event.pageX;session.previousY=event.pageY;$(element).data(DATA_DISPLAYCONTROLLER).show()}else{$(element).first().data(DATA_DISPLAYCONTROLLER).show(true,true)}return element},reposition:function apiResetPosition(element){$(element).first().data(DATA_DISPLAYCONTROLLER).resetPosition();return element},hide:function apiCloseTip(element,immediate){var displayController;immediate=element?immediate:true;if(element){displayController=$(element).first().data(DATA_DISPLAYCONTROLLER)}else if(session.activeHover){displayController=session.activeHover.data(DATA_DISPLAYCONTROLLER)}if(displayController){displayController.hide(immediate)}return element},toggle:function apiToggle(element,event){if(session.activeHover&&session.activeHover.is(element)){$.powerTip.hide(element,!isMouseEvent(event))}else{$.powerTip.show(element,event)}return element}};$.powerTip.showTip=$.powerTip.show;$.powerTip.closeTip=$.powerTip.hide;function CSSCoordinates(){var me=this;me.top="auto";me.left="auto";me.right="auto";me.bottom="auto";me.set=function(property,value){if($.isNumeric(value)){me[property]=Math.round(value)}}}function DisplayController(element,options,tipController){var hoverTimer=null,myCloseDelay=null;function openTooltip(immediate,forceOpen){cancelTimer();if(!element.data(DATA_HASACTIVEHOVER)){if(!immediate){session.tipOpenImminent=true;hoverTimer=setTimeout(function intentDelay(){hoverTimer=null;checkForIntent()},options.intentPollInterval)}else{if(forceOpen){element.data(DATA_FORCEDOPEN,true)}closeAnyDelayed();tipController.showTip(element)}}else{cancelClose()}}function closeTooltip(disableDelay){if(myCloseDelay){myCloseDelay=session.closeDelayTimeout=clearTimeout(myCloseDelay);session.delayInProgress=false}cancelTimer();session.tipOpenImminent=false;if(element.data(DATA_HASACTIVEHOVER)){element.data(DATA_FORCEDOPEN,false);if(!disableDelay){session.delayInProgress=true;session.closeDelayTimeout=setTimeout(function closeDelay(){session.closeDelayTimeout=null;tipController.hideTip(element);session.delayInProgress=false;myCloseDelay=null},options.closeDelay);myCloseDelay=session.closeDelayTimeout}else{tipController.hideTip(element)}}}function checkForIntent(){var xDifference=Math.abs(session.previousX-session.currentX),yDifference=Math.abs(session.previousY-session.currentY),totalDifference=xDifference+yDifference;if(totalDifference",{id:options.popupId});if($body.length===0){$body=$("body")}$body.append(tipElement);session.tooltips=session.tooltips?session.tooltips.add(tipElement):tipElement}if(options.followMouse){if(!tipElement.data(DATA_HASMOUSEMOVE)){$document.on("mousemove"+EVENT_NAMESPACE,positionTipOnCursor);$window.on("scroll"+EVENT_NAMESPACE,positionTipOnCursor);tipElement.data(DATA_HASMOUSEMOVE,true)}}function beginShowTip(element){element.data(DATA_HASACTIVEHOVER,true);tipElement.queue(function queueTipInit(next){showTip(element);next()})}function showTip(element){var tipContent;if(!element.data(DATA_HASACTIVEHOVER)){return}if(session.isTipOpen){if(!session.isClosing){hideTip(session.activeHover)}tipElement.delay(100).queue(function queueTipAgain(next){showTip(element);next()});return}element.trigger("powerTipPreRender");tipContent=getTooltipContent(element);if(tipContent){tipElement.empty().append(tipContent)}else{return}element.trigger("powerTipRender");session.activeHover=element;session.isTipOpen=true;tipElement.data(DATA_MOUSEONTOTIP,options.mouseOnToPopup);tipElement.addClass(options.popupClass);if(!options.followMouse||element.data(DATA_FORCEDOPEN)){positionTipOnElement(element);session.isFixedTipOpen=true}else{positionTipOnCursor()}if(!element.data(DATA_FORCEDOPEN)&&!options.followMouse){$document.on("click"+EVENT_NAMESPACE,function documentClick(event){var target=event.target;if(target!==element[0]){if(options.mouseOnToPopup){if(target!==tipElement[0]&&!$.contains(tipElement[0],target)){$.powerTip.hide()}}else{$.powerTip.hide()}}})}if(options.mouseOnToPopup&&!options.manual){tipElement.on("mouseenter"+EVENT_NAMESPACE,function tipMouseEnter(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).cancel()}});tipElement.on("mouseleave"+EVENT_NAMESPACE,function tipMouseLeave(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).hide()}})}tipElement.fadeIn(options.fadeInTime,function fadeInCallback(){if(!session.desyncTimeout){session.desyncTimeout=setInterval(closeDesyncedTip,500)}element.trigger("powerTipOpen")})}function hideTip(element){session.isClosing=true;session.isTipOpen=false;session.desyncTimeout=clearInterval(session.desyncTimeout);element.data(DATA_HASACTIVEHOVER,false);element.data(DATA_FORCEDOPEN,false);$document.off("click"+EVENT_NAMESPACE);tipElement.off(EVENT_NAMESPACE);tipElement.fadeOut(options.fadeOutTime,function fadeOutCallback(){var coords=new CSSCoordinates;session.activeHover=null;session.isClosing=false;session.isFixedTipOpen=false;tipElement.removeClass();coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);tipElement.css(coords);element.trigger("powerTipClose")})}function positionTipOnCursor(){var tipWidth,tipHeight,coords,collisions,collisionCount;if(!session.isFixedTipOpen&&(session.isTipOpen||session.tipOpenImminent&&tipElement.data(DATA_HASMOUSEMOVE))){tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=new CSSCoordinates;coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);collisions=getViewportCollisions(coords,tipWidth,tipHeight);if(collisions!==Collision.none){collisionCount=countFlags(collisions);if(collisionCount===1){if(collisions===Collision.right){coords.set("left",session.scrollLeft+session.windowWidth-tipWidth)}else if(collisions===Collision.bottom){coords.set("top",session.scrollTop+session.windowHeight-tipHeight)}}else{coords.set("left",session.currentX-tipWidth-options.offset);coords.set("top",session.currentY-tipHeight-options.offset)}}tipElement.css(coords)}}function positionTipOnElement(element){var priorityList,finalPlacement;if(options.smartPlacement||options.followMouse&&element.data(DATA_FORCEDOPEN)){priorityList=$.fn.powerTip.smartPlacementLists[options.placement];$.each(priorityList,function(idx,pos){var collisions=getViewportCollisions(placeTooltip(element,pos),tipElement.outerWidth(),tipElement.outerHeight());finalPlacement=pos;return collisions!==Collision.none})}else{placeTooltip(element,options.placement);finalPlacement=options.placement}tipElement.removeClass("w nw sw e ne se n s w se-alt sw-alt ne-alt nw-alt");tipElement.addClass(finalPlacement)}function placeTooltip(element,placement){var iterationCount=0,tipWidth,tipHeight,coords=new CSSCoordinates;coords.set("top",0);coords.set("left",0);tipElement.css(coords);do{tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=placementCalculator.compute(element,placement,tipWidth,tipHeight,options.offset);tipElement.css(coords)}while(++iterationCount<=5&&(tipWidth!==tipElement.outerWidth()||tipHeight!==tipElement.outerHeight()));return coords}function closeDesyncedTip(){var isDesynced=false,hasDesyncableCloseEvent=$.grep(["mouseleave","mouseout","blur","focusout"],function(eventType){return $.inArray(eventType,options.closeEvents)!==-1}).length>0;if(session.isTipOpen&&!session.isClosing&&!session.delayInProgress&&hasDesyncableCloseEvent){if(session.activeHover.data(DATA_HASACTIVEHOVER)===false||session.activeHover.is(":disabled")){isDesynced=true}else if(!isMouseOver(session.activeHover)&&!session.activeHover.is(":focus")&&!session.activeHover.data(DATA_FORCEDOPEN)){if(tipElement.data(DATA_MOUSEONTOTIP)){if(!isMouseOver(tipElement)){isDesynced=true}}else{isDesynced=true}}if(isDesynced){hideTip(session.activeHover)}}}this.showTip=beginShowTip;this.hideTip=hideTip;this.resetPosition=positionTipOnElement}function isSvgElement(element){return Boolean(window.SVGElement&&element[0]instanceof SVGElement)}function isMouseEvent(event){return Boolean(event&&$.inArray(event.type,MOUSE_EVENTS)>-1&&typeof event.pageX==="number")}function initTracking(){if(!session.mouseTrackingActive){session.mouseTrackingActive=true;getViewportDimensions();$(getViewportDimensions);$document.on("mousemove"+EVENT_NAMESPACE,trackMouse);$window.on("resize"+EVENT_NAMESPACE,trackResize);$window.on("scroll"+EVENT_NAMESPACE,trackScroll)}}function getViewportDimensions(){session.scrollLeft=$window.scrollLeft();session.scrollTop=$window.scrollTop();session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackResize(){session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackScroll(){var x=$window.scrollLeft(),y=$window.scrollTop();if(x!==session.scrollLeft){session.currentX+=x-session.scrollLeft;session.scrollLeft=x}if(y!==session.scrollTop){session.currentY+=y-session.scrollTop;session.scrollTop=y}}function trackMouse(event){session.currentX=event.pageX;session.currentY=event.pageY}function isMouseOver(element){var elementPosition=element.offset(),elementBox=element[0].getBoundingClientRect(),elementWidth=elementBox.right-elementBox.left,elementHeight=elementBox.bottom-elementBox.top;return session.currentX>=elementPosition.left&&session.currentX<=elementPosition.left+elementWidth&&session.currentY>=elementPosition.top&&session.currentY<=elementPosition.top+elementHeight}function getTooltipContent(element){var tipText=element.data(DATA_POWERTIP),tipObject=element.data(DATA_POWERTIPJQ),tipTarget=element.data(DATA_POWERTIPTARGET),targetElement,content;if(tipText){if($.isFunction(tipText)){tipText=tipText.call(element[0])}content=tipText}else if(tipObject){if($.isFunction(tipObject)){tipObject=tipObject.call(element[0])}if(tipObject.length>0){content=tipObject.clone(true,true)}}else if(tipTarget){targetElement=$("#"+tipTarget);if(targetElement.length>0){content=targetElement.html()}}return content}function getViewportCollisions(coords,elementWidth,elementHeight){var viewportTop=session.scrollTop,viewportLeft=session.scrollLeft,viewportBottom=viewportTop+session.windowHeight,viewportRight=viewportLeft+session.windowWidth,collisions=Collision.none;if(coords.topviewportBottom||Math.abs(coords.bottom-session.windowHeight)>viewportBottom){collisions|=Collision.bottom}if(coords.leftviewportRight){collisions|=Collision.left}if(coords.left+elementWidth>viewportRight||coords.right-1){ +targetElements.on(evt+EVENT_NAMESPACE,function elementToggle(event){$.powerTip.toggle(this,event)})}else{targetElements.on(evt+EVENT_NAMESPACE,function elementOpen(event){$.powerTip.show(this,event)})}});$.each(options.closeEvents,function(idx,evt){if($.inArray(evt,options.openEvents)<0){targetElements.on(evt+EVENT_NAMESPACE,function elementClose(event){$.powerTip.hide(this,!isMouseEvent(event))})}});targetElements.on("keydown"+EVENT_NAMESPACE,function elementKeyDown(event){if(event.keyCode===27){$.powerTip.hide(this,true)}})}return targetElements};$.fn.powerTip.defaults={fadeInTime:200,fadeOutTime:100,followMouse:false,popupId:"powerTip",popupClass:null,intentSensitivity:7,intentPollInterval:100,closeDelay:100,placement:"n",smartPlacement:false,offset:10,mouseOnToPopup:false,manual:false,openEvents:["mouseenter","focus"],closeEvents:["mouseleave","blur"]};$.fn.powerTip.smartPlacementLists={n:["n","ne","nw","s"],e:["e","ne","se","w","nw","sw","n","s","e"],s:["s","se","sw","n"],w:["w","nw","sw","e","ne","se", +"n","s","w"],nw:["nw","w","sw","n","s","se","nw"],ne:["ne","e","se","n","s","sw","ne"],sw:["sw","w","nw","s","n","ne","sw"],se:["se","e","ne","s","n","nw","se"],"nw-alt":["nw-alt","n","ne-alt","sw-alt","s","se-alt","w","e"],"ne-alt":["ne-alt","n","nw-alt","se-alt","s","sw-alt","e","w"],"sw-alt":["sw-alt","s","se-alt","nw-alt","n","ne-alt","w","e"],"se-alt":["se-alt","s","sw-alt","ne-alt","n","nw-alt","e","w"]};$.powerTip={show:function apiShowTip(element,event){if(isMouseEvent(event)){trackMouse(event);session.previousX=event.pageX;session.previousY=event.pageY;$(element).data(DATA_DISPLAYCONTROLLER).show()}else{$(element).first().data(DATA_DISPLAYCONTROLLER).show(true,true)}return element},reposition:function apiResetPosition(element){$(element).first().data(DATA_DISPLAYCONTROLLER).resetPosition();return element},hide:function apiCloseTip(element,immediate){var displayController;immediate=element?immediate:true;if(element){displayController=$(element).first().data(DATA_DISPLAYCONTROLLER)}else if( +session.activeHover){displayController=session.activeHover.data(DATA_DISPLAYCONTROLLER)}if(displayController){displayController.hide(immediate)}return element},toggle:function apiToggle(element,event){if(session.activeHover&&session.activeHover.is(element)){$.powerTip.hide(element,!isMouseEvent(event))}else{$.powerTip.show(element,event)}return element}};$.powerTip.showTip=$.powerTip.show;$.powerTip.closeTip=$.powerTip.hide;function CSSCoordinates(){var me=this;me.top="auto";me.left="auto";me.right="auto";me.bottom="auto";me.set=function(property,value){if($.isNumeric(value)){me[property]=Math.round(value)}}}function DisplayController(element,options,tipController){var hoverTimer=null,myCloseDelay=null;function openTooltip(immediate,forceOpen){cancelTimer();if(!element.data(DATA_HASACTIVEHOVER)){if(!immediate){session.tipOpenImminent=true;hoverTimer=setTimeout(function intentDelay(){hoverTimer=null;checkForIntent()},options.intentPollInterval)}else{if(forceOpen){element.data(DATA_FORCEDOPEN,true)} +closeAnyDelayed();tipController.showTip(element)}}else{cancelClose()}}function closeTooltip(disableDelay){if(myCloseDelay){myCloseDelay=session.closeDelayTimeout=clearTimeout(myCloseDelay);session.delayInProgress=false}cancelTimer();session.tipOpenImminent=false;if(element.data(DATA_HASACTIVEHOVER)){element.data(DATA_FORCEDOPEN,false);if(!disableDelay){session.delayInProgress=true;session.closeDelayTimeout=setTimeout(function closeDelay(){session.closeDelayTimeout=null;tipController.hideTip(element);session.delayInProgress=false;myCloseDelay=null},options.closeDelay);myCloseDelay=session.closeDelayTimeout}else{tipController.hideTip(element)}}}function checkForIntent(){var xDifference=Math.abs(session.previousX-session.currentX),yDifference=Math.abs(session.previousY-session.currentY),totalDifference=xDifference+yDifference;if(totalDifference",{id:options.popupId});if($body.length===0){$body=$("body")}$body.append(tipElement);session.tooltips=session.tooltips?session.tooltips.add(tipElement):tipElement}if(options.followMouse){if(!tipElement.data(DATA_HASMOUSEMOVE)){$document.on("mousemove"+EVENT_NAMESPACE,positionTipOnCursor);$window.on("scroll"+EVENT_NAMESPACE,positionTipOnCursor);tipElement.data(DATA_HASMOUSEMOVE,true)}}function beginShowTip(element){element.data(DATA_HASACTIVEHOVER,true);tipElement.queue(function queueTipInit(next){showTip(element);next()})}function showTip(element){var tipContent;if(!element.data(DATA_HASACTIVEHOVER)){return}if( +session.isTipOpen){if(!session.isClosing){hideTip(session.activeHover)}tipElement.delay(100).queue(function queueTipAgain(next){showTip(element);next()});return}element.trigger("powerTipPreRender");tipContent=getTooltipContent(element);if(tipContent){tipElement.empty().append(tipContent)}else{return}element.trigger("powerTipRender");session.activeHover=element;session.isTipOpen=true;tipElement.data(DATA_MOUSEONTOTIP,options.mouseOnToPopup);tipElement.addClass(options.popupClass);if(!options.followMouse||element.data(DATA_FORCEDOPEN)){positionTipOnElement(element);session.isFixedTipOpen=true}else{positionTipOnCursor()}if(!element.data(DATA_FORCEDOPEN)&&!options.followMouse){$document.on("click"+EVENT_NAMESPACE,function documentClick(event){var target=event.target;if(target!==element[0]){if(options.mouseOnToPopup){if(target!==tipElement[0]&&!$.contains(tipElement[0],target)){$.powerTip.hide()}}else{$.powerTip.hide()}}})}if(options.mouseOnToPopup&&!options.manual){tipElement.on("mouseenter"+EVENT_NAMESPACE, +function tipMouseEnter(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).cancel()}});tipElement.on("mouseleave"+EVENT_NAMESPACE,function tipMouseLeave(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).hide()}})}tipElement.fadeIn(options.fadeInTime,function fadeInCallback(){if(!session.desyncTimeout){session.desyncTimeout=setInterval(closeDesyncedTip,500)}element.trigger("powerTipOpen")})}function hideTip(element){session.isClosing=true;session.isTipOpen=false;session.desyncTimeout=clearInterval(session.desyncTimeout);element.data(DATA_HASACTIVEHOVER,false);element.data(DATA_FORCEDOPEN,false);$document.off("click"+EVENT_NAMESPACE);tipElement.off(EVENT_NAMESPACE);tipElement.fadeOut(options.fadeOutTime,function fadeOutCallback(){var coords=new CSSCoordinates;session.activeHover=null;session.isClosing=false;session.isFixedTipOpen=false;tipElement.removeClass();coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset); +tipElement.css(coords);element.trigger("powerTipClose")})}function positionTipOnCursor(){var tipWidth,tipHeight,coords,collisions,collisionCount;if(!session.isFixedTipOpen&&(session.isTipOpen||session.tipOpenImminent&&tipElement.data(DATA_HASMOUSEMOVE))){tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=new CSSCoordinates;coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);collisions=getViewportCollisions(coords,tipWidth,tipHeight);if(collisions!==Collision.none){collisionCount=countFlags(collisions);if(collisionCount===1){if(collisions===Collision.right){coords.set("left",session.scrollLeft+session.windowWidth-tipWidth)}else if(collisions===Collision.bottom){coords.set("top",session.scrollTop+session.windowHeight-tipHeight)}}else{coords.set("left",session.currentX-tipWidth-options.offset);coords.set("top",session.currentY-tipHeight-options.offset)}}tipElement.css(coords)}}function positionTipOnElement(element){var priorityList, +finalPlacement;if(options.smartPlacement||options.followMouse&&element.data(DATA_FORCEDOPEN)){priorityList=$.fn.powerTip.smartPlacementLists[options.placement];$.each(priorityList,function(idx,pos){var collisions=getViewportCollisions(placeTooltip(element,pos),tipElement.outerWidth(),tipElement.outerHeight());finalPlacement=pos;return collisions!==Collision.none})}else{placeTooltip(element,options.placement);finalPlacement=options.placement}tipElement.removeClass("w nw sw e ne se n s w se-alt sw-alt ne-alt nw-alt");tipElement.addClass(finalPlacement)}function placeTooltip(element,placement){var iterationCount=0,tipWidth,tipHeight,coords=new CSSCoordinates;coords.set("top",0);coords.set("left",0);tipElement.css(coords);do{tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=placementCalculator.compute(element,placement,tipWidth,tipHeight,options.offset);tipElement.css(coords)}while(++iterationCount<=5&&(tipWidth!==tipElement.outerWidth()||tipHeight!==tipElement.outerHeight())); +return coords}function closeDesyncedTip(){var isDesynced=false,hasDesyncableCloseEvent=$.grep(["mouseleave","mouseout","blur","focusout"],function(eventType){return $.inArray(eventType,options.closeEvents)!==-1}).length>0;if(session.isTipOpen&&!session.isClosing&&!session.delayInProgress&&hasDesyncableCloseEvent){if(session.activeHover.data(DATA_HASACTIVEHOVER)===false||session.activeHover.is(":disabled")){isDesynced=true}else if(!isMouseOver(session.activeHover)&&!session.activeHover.is(":focus")&&!session.activeHover.data(DATA_FORCEDOPEN)){if(tipElement.data(DATA_MOUSEONTOTIP)){if(!isMouseOver(tipElement)){isDesynced=true}}else{isDesynced=true}}if(isDesynced){hideTip(session.activeHover)}}}this.showTip=beginShowTip;this.hideTip=hideTip;this.resetPosition=positionTipOnElement}function isSvgElement(element){return Boolean(window.SVGElement&&element[0]instanceof SVGElement)}function isMouseEvent(event){return Boolean(event&&$.inArray(event.type,MOUSE_EVENTS)>-1&&typeof event.pageX==="number")} +function initTracking(){if(!session.mouseTrackingActive){session.mouseTrackingActive=true;getViewportDimensions();$(getViewportDimensions);$document.on("mousemove"+EVENT_NAMESPACE,trackMouse);$window.on("resize"+EVENT_NAMESPACE,trackResize);$window.on("scroll"+EVENT_NAMESPACE,trackScroll)}}function getViewportDimensions(){session.scrollLeft=$window.scrollLeft();session.scrollTop=$window.scrollTop();session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackResize(){session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackScroll(){var x=$window.scrollLeft(),y=$window.scrollTop();if(x!==session.scrollLeft){session.currentX+=x-session.scrollLeft;session.scrollLeft=x}if(y!==session.scrollTop){session.currentY+=y-session.scrollTop;session.scrollTop=y}}function trackMouse(event){session.currentX=event.pageX;session.currentY=event.pageY}function isMouseOver(element){var elementPosition=element.offset(),elementBox=element[0].getBoundingClientRect(), +elementWidth=elementBox.right-elementBox.left,elementHeight=elementBox.bottom-elementBox.top;return session.currentX>=elementPosition.left&&session.currentX<=elementPosition.left+elementWidth&&session.currentY>=elementPosition.top&&session.currentY<=elementPosition.top+elementHeight}function getTooltipContent(element){var tipText=element.data(DATA_POWERTIP),tipObject=element.data(DATA_POWERTIPJQ),tipTarget=element.data(DATA_POWERTIPTARGET),targetElement,content;if(tipText){if($.isFunction(tipText)){tipText=tipText.call(element[0])}content=tipText}else if(tipObject){if($.isFunction(tipObject)){tipObject=tipObject.call(element[0])}if(tipObject.length>0){content=tipObject.clone(true,true)}}else if(tipTarget){targetElement=$("#"+tipTarget);if(targetElement.length>0){content=targetElement.html()}}return content}function getViewportCollisions(coords,elementWidth,elementHeight){var viewportTop=session.scrollTop,viewportLeft=session.scrollLeft,viewportBottom=viewportTop+session.windowHeight, +viewportRight=viewportLeft+session.windowWidth,collisions=Collision.none;if(coords.topviewportBottom||Math.abs(coords.bottom-session.windowHeight)>viewportBottom){collisions|=Collision.bottom}if(coords.leftviewportRight){collisions|=Collision.left}if(coords.left+elementWidth>viewportRight||coords.right1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);/*! SmartMenus jQuery Plugin - v1.1.0 - September 17, 2017 + */!function(a){function f(a,b){if(!(a.originalEvent.touches.length>1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b, +"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery); +/*! SmartMenus jQuery Plugin - v1.1.0 - September 17, 2017 * http://www.smartmenus.org/ - * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function($){function initMouseDetection(t){var e=".smartmenus_mouse";if(mouseDetectionEnabled||t)mouseDetectionEnabled&&t&&($(document).off(e),mouseDetectionEnabled=!1);else{var i=!0,s=null,o={mousemove:function(t){var e={x:t.pageX,y:t.pageY,timeStamp:(new Date).getTime()};if(s){var o=Math.abs(s.x-e.x),a=Math.abs(s.y-e.y);if((o>0||a>0)&&2>=o&&2>=a&&300>=e.timeStamp-s.timeStamp&&(mouse=!0,i)){var n=$(t.target).closest("a");n.is("a")&&$.each(menuTrees,function(){return $.contains(this.$root[0],n[0])?(this.itemEnter({currentTarget:n[0]}),!1):void 0}),i=!1}}s=e}};o[touchEvents?"touchstart":"pointerover pointermove pointerout MSPointerOver MSPointerMove MSPointerOut"]=function(t){isTouchEvent(t.originalEvent)&&(mouse=!1)},$(document).on(getEventsNS(o,e)),mouseDetectionEnabled=!0}}function isTouchEvent(t){return!/^(4|mouse)$/.test(t.pointerType)}function getEventsNS(t,e){e||(e="");var i={};for(var s in t)i[s.split(" ").join(e+" ")+e]=t[s];return i}var menuTrees=[],mouse=!1,touchEvents="ontouchstart"in window,mouseDetectionEnabled=!1,requestAnimationFrame=window.requestAnimationFrame||function(t){return setTimeout(t,1e3/60)},cancelAnimationFrame=window.cancelAnimationFrame||function(t){clearTimeout(t)},canAnimate=!!$.fn.animate;return $.SmartMenus=function(t,e){this.$root=$(t),this.opts=e,this.rootId="",this.accessIdPrefix="",this.$subArrow=null,this.activatedItems=[],this.visibleSubMenus=[],this.showTimeout=0,this.hideTimeout=0,this.scrollTimeout=0,this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.idInc=0,this.$firstLink=null,this.$firstSub=null,this.disabled=!1,this.$disableOverlay=null,this.$touchScrollingSub=null,this.cssTransforms3d="perspective"in t.style||"webkitPerspective"in t.style,this.wasCollapsible=!1,this.init()},$.extend($.SmartMenus,{hideAll:function(){$.each(menuTrees,function(){this.menuHideAll()})},destroy:function(){for(;menuTrees.length;)menuTrees[0].destroy();initMouseDetection(!0)},prototype:{init:function(t){var e=this;if(!t){menuTrees.push(this),this.rootId=((new Date).getTime()+Math.random()+"").replace(/\D/g,""),this.accessIdPrefix="sm-"+this.rootId+"-",this.$root.hasClass("sm-rtl")&&(this.opts.rightToLeftSubMenus=!0);var i=".smartmenus";this.$root.data("smartmenus",this).attr("data-smartmenus-id",this.rootId).dataSM("level",1).on(getEventsNS({"mouseover focusin":$.proxy(this.rootOver,this),"mouseout focusout":$.proxy(this.rootOut,this),keydown:$.proxy(this.rootKeyDown,this)},i)).on(getEventsNS({mouseenter:$.proxy(this.itemEnter,this),mouseleave:$.proxy(this.itemLeave,this),mousedown:$.proxy(this.itemDown,this),focus:$.proxy(this.itemFocus,this),blur:$.proxy(this.itemBlur,this),click:$.proxy(this.itemClick,this)},i),"a"),i+=this.rootId,this.opts.hideOnClick&&$(document).on(getEventsNS({touchstart:$.proxy(this.docTouchStart,this),touchmove:$.proxy(this.docTouchMove,this),touchend:$.proxy(this.docTouchEnd,this),click:$.proxy(this.docClick,this)},i)),$(window).on(getEventsNS({"resize orientationchange":$.proxy(this.winResize,this)},i)),this.opts.subIndicators&&(this.$subArrow=$("").addClass("sub-arrow"),this.opts.subIndicatorsText&&this.$subArrow.html(this.opts.subIndicatorsText)),initMouseDetection()}if(this.$firstSub=this.$root.find("ul").each(function(){e.menuInit($(this))}).eq(0),this.$firstLink=this.$root.find("a").eq(0),this.opts.markCurrentItem){var s=/(index|default)\.[^#\?\/]*/i,o=/#.*/,a=window.location.href.replace(s,""),n=a.replace(o,"");this.$root.find("a").each(function(){var t=this.href.replace(s,""),i=$(this);(t==a||t==n)&&(i.addClass("current"),e.opts.markCurrentTree&&i.parentsUntil("[data-smartmenus-id]","ul").each(function(){$(this).dataSM("parent-a").addClass("current")}))})}this.wasCollapsible=this.isCollapsible()},destroy:function(t){if(!t){var e=".smartmenus";this.$root.removeData("smartmenus").removeAttr("data-smartmenus-id").removeDataSM("level").off(e),e+=this.rootId,$(document).off(e),$(window).off(e),this.opts.subIndicators&&(this.$subArrow=null)}this.menuHideAll();var i=this;this.$root.find("ul").each(function(){var t=$(this);t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.dataSM("shown-before")&&((i.opts.subMenusMinWidth||i.opts.subMenusMaxWidth)&&t.css({width:"",minWidth:"",maxWidth:""}).removeClass("sm-nowrap"),t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.css({zIndex:"",top:"",left:"",marginLeft:"",marginTop:"",display:""})),0==(t.attr("id")||"").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeDataSM("in-mega").removeDataSM("shown-before").removeDataSM("scroll-arrows").removeDataSM("parent-a").removeDataSM("level").removeDataSM("beforefirstshowfired").removeAttr("role").removeAttr("aria-hidden").removeAttr("aria-labelledby").removeAttr("aria-expanded"),this.$root.find("a.has-submenu").each(function(){var t=$(this);0==t.attr("id").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeClass("has-submenu").removeDataSM("sub").removeAttr("aria-haspopup").removeAttr("aria-controls").removeAttr("aria-expanded").closest("li").removeDataSM("sub"),this.opts.subIndicators&&this.$root.find("span.sub-arrow").remove(),this.opts.markCurrentItem&&this.$root.find("a.current").removeClass("current"),t||(this.$root=null,this.$firstLink=null,this.$firstSub=null,this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),menuTrees.splice($.inArray(this,menuTrees),1))},disable:function(t){if(!this.disabled){if(this.menuHideAll(),!t&&!this.opts.isPopup&&this.$root.is(":visible")){var e=this.$root.offset();this.$disableOverlay=$('
    ').css({position:"absolute",top:e.top,left:e.left,width:this.$root.outerWidth(),height:this.$root.outerHeight(),zIndex:this.getStartZIndex(!0),opacity:0}).appendTo(document.body)}this.disabled=!0}},docClick:function(t){return this.$touchScrollingSub?(this.$touchScrollingSub=null,void 0):((this.visibleSubMenus.length&&!$.contains(this.$root[0],t.target)||$(t.target).closest("a").length)&&this.menuHideAll(),void 0)},docTouchEnd:function(){if(this.lastTouch){if(!(!this.visibleSubMenus.length||void 0!==this.lastTouch.x2&&this.lastTouch.x1!=this.lastTouch.x2||void 0!==this.lastTouch.y2&&this.lastTouch.y1!=this.lastTouch.y2||this.lastTouch.target&&$.contains(this.$root[0],this.lastTouch.target))){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var t=this;this.hideTimeout=setTimeout(function(){t.menuHideAll()},350)}this.lastTouch=null}},docTouchMove:function(t){if(this.lastTouch){var e=t.originalEvent.touches[0];this.lastTouch.x2=e.pageX,this.lastTouch.y2=e.pageY}},docTouchStart:function(t){var e=t.originalEvent.touches[0];this.lastTouch={x1:e.pageX,y1:e.pageY,target:e.target}},enable:function(){this.disabled&&(this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),this.disabled=!1)},getClosestMenu:function(t){for(var e=$(t).closest("ul");e.dataSM("in-mega");)e=e.parent().closest("ul");return e[0]||null},getHeight:function(t){return this.getOffset(t,!0)},getOffset:function(t,e){var i;"none"==t.css("display")&&(i={position:t[0].style.position,visibility:t[0].style.visibility},t.css({position:"absolute",visibility:"hidden"}).show());var s=t[0].getBoundingClientRect&&t[0].getBoundingClientRect(),o=s&&(e?s.height||s.bottom-s.top:s.width||s.right-s.left);return o||0===o||(o=e?t[0].offsetHeight:t[0].offsetWidth),i&&t.hide().css(i),o},getStartZIndex:function(t){var e=parseInt(this[t?"$root":"$firstSub"].css("z-index"));return!t&&isNaN(e)&&(e=parseInt(this.$root.css("z-index"))),isNaN(e)?1:e},getTouchPoint:function(t){return t.touches&&t.touches[0]||t.changedTouches&&t.changedTouches[0]||t},getViewport:function(t){var e=t?"Height":"Width",i=document.documentElement["client"+e],s=window["inner"+e];return s&&(i=Math.min(i,s)),i},getViewportHeight:function(){return this.getViewport(!0)},getViewportWidth:function(){return this.getViewport()},getWidth:function(t){return this.getOffset(t)},handleEvents:function(){return!this.disabled&&this.isCSSOn()},handleItemEvents:function(t){return this.handleEvents()&&!this.isLinkInMegaMenu(t)},isCollapsible:function(){return"static"==this.$firstSub.css("position")},isCSSOn:function(){return"inline"!=this.$firstLink.css("display")},isFixed:function(){var t="fixed"==this.$root.css("position");return t||this.$root.parentsUntil("body").each(function(){return"fixed"==$(this).css("position")?(t=!0,!1):void 0}),t},isLinkInMegaMenu:function(t){return $(this.getClosestMenu(t[0])).hasClass("mega-menu")},isTouchMode:function(){return!mouse||this.opts.noMouseOver||this.isCollapsible()},itemActivate:function(t,e){var i=t.closest("ul"),s=i.dataSM("level");if(s>1&&(!this.activatedItems[s-2]||this.activatedItems[s-2][0]!=i.dataSM("parent-a")[0])){var o=this;$(i.parentsUntil("[data-smartmenus-id]","ul").get().reverse()).add(i).each(function(){o.itemActivate($(this).dataSM("parent-a"))})}if((!this.isCollapsible()||e)&&this.menuHideSubMenus(this.activatedItems[s-1]&&this.activatedItems[s-1][0]==t[0]?s:s-1),this.activatedItems[s-1]=t,this.$root.triggerHandler("activate.smapi",t[0])!==!1){var a=t.dataSM("sub");a&&(this.isTouchMode()||!this.opts.showOnClick||this.clickActivated)&&this.menuShow(a)}},itemBlur:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&this.$root.triggerHandler("blur.smapi",e[0])},itemClick:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(this.$touchScrollingSub&&this.$touchScrollingSub[0]==e.closest("ul")[0])return this.$touchScrollingSub=null,t.stopPropagation(),!1;if(this.$root.triggerHandler("click.smapi",e[0])===!1)return!1;var i=$(t.target).is(".sub-arrow"),s=e.dataSM("sub"),o=s?2==s.dataSM("level"):!1,a=this.isCollapsible(),n=/toggle$/.test(this.opts.collapsibleBehavior),r=/link$/.test(this.opts.collapsibleBehavior),h=/^accordion/.test(this.opts.collapsibleBehavior);if(s&&!s.is(":visible")){if((!r||!a||i)&&(this.opts.showOnClick&&o&&(this.clickActivated=!0),this.itemActivate(e,h),s.is(":visible")))return this.focusActivated=!0,!1}else if(a&&(n||i))return this.itemActivate(e,h),this.menuHide(s),n&&(this.focusActivated=!1),!1;return this.opts.showOnClick&&o||e.hasClass("disabled")||this.$root.triggerHandler("select.smapi",e[0])===!1?!1:void 0}},itemDown:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&e.dataSM("mousedown",!0)},itemEnter:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(!this.isTouchMode()){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);var i=this;this.showTimeout=setTimeout(function(){i.itemActivate(e)},this.opts.showOnClick&&1==e.closest("ul").dataSM("level")?1:this.opts.showTimeout)}this.$root.triggerHandler("mouseenter.smapi",e[0])}},itemFocus:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(!this.focusActivated||this.isTouchMode()&&e.dataSM("mousedown")||this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0]==e[0]||this.itemActivate(e,!0),this.$root.triggerHandler("focus.smapi",e[0]))},itemLeave:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(this.isTouchMode()||(e[0].blur(),this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0)),e.removeDataSM("mousedown"),this.$root.triggerHandler("mouseleave.smapi",e[0]))},menuHide:function(t){if(this.$root.triggerHandler("beforehide.smapi",t[0])!==!1&&(canAnimate&&t.stop(!0,!0),"none"!=t.css("display"))){var e=function(){t.css("z-index","")};this.isCollapsible()?canAnimate&&this.opts.collapsibleHideFunction?this.opts.collapsibleHideFunction.call(this,t,e):t.hide(this.opts.collapsibleHideDuration,e):canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,t,e):t.hide(this.opts.hideDuration,e),t.dataSM("scroll")&&(this.menuScrollStop(t),t.css({"touch-action":"","-ms-touch-action":"","-webkit-transform":"",transform:""}).off(".smartmenus_scroll").removeDataSM("scroll").dataSM("scroll-arrows").hide()),t.dataSM("parent-a").removeClass("highlighted").attr("aria-expanded","false"),t.attr({"aria-expanded":"false","aria-hidden":"true"});var i=t.dataSM("level");this.activatedItems.splice(i-1,1),this.visibleSubMenus.splice($.inArray(t,this.visibleSubMenus),1),this.$root.triggerHandler("hide.smapi",t[0])}},menuHideAll:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);for(var t=this.opts.isPopup?1:0,e=this.visibleSubMenus.length-1;e>=t;e--)this.menuHide(this.visibleSubMenus[e]);this.opts.isPopup&&(canAnimate&&this.$root.stop(!0,!0),this.$root.is(":visible")&&(canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,this.$root):this.$root.hide(this.opts.hideDuration))),this.activatedItems=[],this.visibleSubMenus=[],this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.$root.triggerHandler("hideAll.smapi")},menuHideSubMenus:function(t){for(var e=this.activatedItems.length-1;e>=t;e--){var i=this.activatedItems[e].dataSM("sub");i&&this.menuHide(i)}},menuInit:function(t){if(!t.dataSM("in-mega")){t.hasClass("mega-menu")&&t.find("ul").dataSM("in-mega",!0);for(var e=2,i=t[0];(i=i.parentNode.parentNode)!=this.$root[0];)e++;var s=t.prevAll("a").eq(-1);s.length||(s=t.prevAll().find("a").eq(-1)),s.addClass("has-submenu").dataSM("sub",t),t.dataSM("parent-a",s).dataSM("level",e).parent().dataSM("sub",t);var o=s.attr("id")||this.accessIdPrefix+ ++this.idInc,a=t.attr("id")||this.accessIdPrefix+ ++this.idInc;s.attr({id:o,"aria-haspopup":"true","aria-controls":a,"aria-expanded":"false"}),t.attr({id:a,role:"group","aria-hidden":"true","aria-labelledby":o,"aria-expanded":"false"}),this.opts.subIndicators&&s[this.opts.subIndicatorsPos](this.$subArrow.clone())}},menuPosition:function(t){var e,i,s=t.dataSM("parent-a"),o=s.closest("li"),a=o.parent(),n=t.dataSM("level"),r=this.getWidth(t),h=this.getHeight(t),u=s.offset(),l=u.left,c=u.top,d=this.getWidth(s),m=this.getHeight(s),p=$(window),f=p.scrollLeft(),v=p.scrollTop(),b=this.getViewportWidth(),S=this.getViewportHeight(),g=a.parent().is("[data-sm-horizontal-sub]")||2==n&&!a.hasClass("sm-vertical"),M=this.opts.rightToLeftSubMenus&&!o.is("[data-sm-reverse]")||!this.opts.rightToLeftSubMenus&&o.is("[data-sm-reverse]"),w=2==n?this.opts.mainMenuSubOffsetX:this.opts.subMenusSubOffsetX,T=2==n?this.opts.mainMenuSubOffsetY:this.opts.subMenusSubOffsetY;if(g?(e=M?d-r-w:w,i=this.opts.bottomToTopSubMenus?-h-T:m+T):(e=M?w-r:d-w,i=this.opts.bottomToTopSubMenus?m-T-h:T),this.opts.keepInViewport){var y=l+e,I=c+i;if(M&&f>y?e=g?f-y+e:d-w:!M&&y+r>f+b&&(e=g?f+b-r-y+e:w-r),g||(S>h&&I+h>v+S?i+=v+S-h-I:(h>=S||v>I)&&(i+=v-I)),g&&(I+h>v+S+.49||v>I)||!g&&h>S+.49){var x=this;t.dataSM("scroll-arrows")||t.dataSM("scroll-arrows",$([$('')[0],$('')[0]]).on({mouseenter:function(){t.dataSM("scroll").up=$(this).hasClass("scroll-up"),x.menuScroll(t)},mouseleave:function(e){x.menuScrollStop(t),x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(t){t.preventDefault()}}).insertAfter(t));var A=".smartmenus_scroll";if(t.dataSM("scroll",{y:this.cssTransforms3d?0:i-m,step:1,itemH:m,subH:h,arrowDownH:this.getHeight(t.dataSM("scroll-arrows").eq(1))}).on(getEventsNS({mouseover:function(e){x.menuScrollOver(t,e)},mouseout:function(e){x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(e){x.menuScrollMousewheel(t,e)}},A)).dataSM("scroll-arrows").css({top:"auto",left:"0",marginLeft:e+(parseInt(t.css("border-left-width"))||0),width:r-(parseInt(t.css("border-left-width"))||0)-(parseInt(t.css("border-right-width"))||0),zIndex:t.css("z-index")}).eq(g&&this.opts.bottomToTopSubMenus?0:1).show(),this.isFixed()){var C={};C[touchEvents?"touchstart touchmove touchend":"pointerdown pointermove pointerup MSPointerDown MSPointerMove MSPointerUp"]=function(e){x.menuScrollTouch(t,e)},t.css({"touch-action":"none","-ms-touch-action":"none"}).on(getEventsNS(C,A))}}}t.css({top:"auto",left:"0",marginLeft:e,marginTop:i-m})},menuScroll:function(t,e,i){var s,o=t.dataSM("scroll"),a=t.dataSM("scroll-arrows"),n=o.up?o.upEnd:o.downEnd;if(!e&&o.momentum){if(o.momentum*=.92,s=o.momentum,.5>s)return this.menuScrollStop(t),void 0}else s=i||(e||!this.opts.scrollAccelerate?this.opts.scrollStep:Math.floor(o.step));var r=t.dataSM("level");if(this.activatedItems[r-1]&&this.activatedItems[r-1].dataSM("sub")&&this.activatedItems[r-1].dataSM("sub").is(":visible")&&this.menuHideSubMenus(r-1),o.y=o.up&&o.y>=n||!o.up&&n>=o.y?o.y:Math.abs(n-o.y)>s?o.y+(o.up?s:-s):n,t.css(this.cssTransforms3d?{"-webkit-transform":"translate3d(0, "+o.y+"px, 0)",transform:"translate3d(0, "+o.y+"px, 0)"}:{marginTop:o.y}),mouse&&(o.up&&o.y>o.downEnd||!o.up&&o.y0;t.dataSM("scroll-arrows").eq(i?0:1).is(":visible")&&(t.dataSM("scroll").up=i,this.menuScroll(t,!0))}e.preventDefault()},menuScrollOut:function(t,e){mouse&&(/^scroll-(up|down)/.test((e.relatedTarget||"").className)||(t[0]==e.relatedTarget||$.contains(t[0],e.relatedTarget))&&this.getClosestMenu(e.relatedTarget)==t[0]||t.dataSM("scroll-arrows").css("visibility","hidden"))},menuScrollOver:function(t,e){if(mouse&&!/^scroll-(up|down)/.test(e.target.className)&&this.getClosestMenu(e.target)==t[0]){this.menuScrollRefreshData(t);var i=t.dataSM("scroll"),s=$(window).scrollTop()-t.dataSM("parent-a").offset().top-i.itemH;t.dataSM("scroll-arrows").eq(0).css("margin-top",s).end().eq(1).css("margin-top",s+this.getViewportHeight()-i.arrowDownH).end().css("visibility","visible")}},menuScrollRefreshData:function(t){var e=t.dataSM("scroll"),i=$(window).scrollTop()-t.dataSM("parent-a").offset().top-e.itemH;this.cssTransforms3d&&(i=-(parseFloat(t.css("margin-top"))-i)),$.extend(e,{upEnd:i,downEnd:i+this.getViewportHeight()-e.subH})},menuScrollStop:function(t){return this.scrollTimeout?(cancelAnimationFrame(this.scrollTimeout),this.scrollTimeout=0,t.dataSM("scroll").step=1,!0):void 0},menuScrollTouch:function(t,e){if(e=e.originalEvent,isTouchEvent(e)){var i=this.getTouchPoint(e);if(this.getClosestMenu(i.target)==t[0]){var s=t.dataSM("scroll");if(/(start|down)$/i.test(e.type))this.menuScrollStop(t)?(e.preventDefault(),this.$touchScrollingSub=t):this.$touchScrollingSub=null,this.menuScrollRefreshData(t),$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp});else if(/move$/i.test(e.type)){var o=void 0!==s.touchY?s.touchY:s.touchStartY;if(void 0!==o&&o!=i.pageY){this.$touchScrollingSub=t;var a=i.pageY>o;void 0!==s.up&&s.up!=a&&$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp}),$.extend(s,{up:a,touchY:i.pageY}),this.menuScroll(t,!0,Math.abs(i.pageY-o))}e.preventDefault()}else void 0!==s.touchY&&((s.momentum=15*Math.pow(Math.abs(i.pageY-s.touchStartY)/(e.timeStamp-s.touchStartTime),2))&&(this.menuScrollStop(t),this.menuScroll(t),e.preventDefault()),delete s.touchY)}}},menuShow:function(t){if((t.dataSM("beforefirstshowfired")||(t.dataSM("beforefirstshowfired",!0),this.$root.triggerHandler("beforefirstshow.smapi",t[0])!==!1))&&this.$root.triggerHandler("beforeshow.smapi",t[0])!==!1&&(t.dataSM("shown-before",!0),canAnimate&&t.stop(!0,!0),!t.is(":visible"))){var e=t.dataSM("parent-a"),i=this.isCollapsible();if((this.opts.keepHighlighted||i)&&e.addClass("highlighted"),i)t.removeClass("sm-nowrap").css({zIndex:"",width:"auto",minWidth:"",maxWidth:"",top:"",left:"",marginLeft:"",marginTop:""});else{if(t.css("z-index",this.zIndexInc=(this.zIndexInc||this.getStartZIndex())+1),(this.opts.subMenusMinWidth||this.opts.subMenusMaxWidth)&&(t.css({width:"auto",minWidth:"",maxWidth:""}).addClass("sm-nowrap"),this.opts.subMenusMinWidth&&t.css("min-width",this.opts.subMenusMinWidth),this.opts.subMenusMaxWidth)){var s=this.getWidth(t);t.css("max-width",this.opts.subMenusMaxWidth),s>this.getWidth(t)&&t.removeClass("sm-nowrap").css("width",this.opts.subMenusMaxWidth)}this.menuPosition(t)}var o=function(){t.css("overflow","")};i?canAnimate&&this.opts.collapsibleShowFunction?this.opts.collapsibleShowFunction.call(this,t,o):t.show(this.opts.collapsibleShowDuration,o):canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,t,o):t.show(this.opts.showDuration,o),e.attr("aria-expanded","true"),t.attr({"aria-expanded":"true","aria-hidden":"false"}),this.visibleSubMenus.push(t),this.$root.triggerHandler("show.smapi",t[0])}},popupHide:function(t){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},t?1:this.opts.hideTimeout)},popupShow:function(t,e){if(!this.opts.isPopup)return alert('SmartMenus jQuery Error:\n\nIf you want to show this menu via the "popupShow" method, set the isPopup:true option.'),void 0;if(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),this.$root.dataSM("shown-before",!0),canAnimate&&this.$root.stop(!0,!0),!this.$root.is(":visible")){this.$root.css({left:t,top:e});var i=this,s=function(){i.$root.css("overflow","")};canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,this.$root,s):this.$root.show(this.opts.showDuration,s),this.visibleSubMenus[0]=this.$root}},refresh:function(){this.destroy(!0),this.init(!0)},rootKeyDown:function(t){if(this.handleEvents())switch(t.keyCode){case 27:var e=this.activatedItems[0];if(e){this.menuHideAll(),e[0].focus();var i=e.dataSM("sub");i&&this.menuHide(i)}break;case 32:var s=$(t.target);if(s.is("a")&&this.handleItemEvents(s)){var i=s.dataSM("sub");i&&!i.is(":visible")&&(this.itemClick({currentTarget:t.target}),t.preventDefault())}}},rootOut:function(t){if(this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),!this.opts.showOnClick||!this.opts.hideOnClick)){var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},this.opts.hideTimeout)}},rootOver:function(t){this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0)},winResize:function(t){if(this.handleEvents()){if(!("onorientationchange"in window)||"orientationchange"==t.type){var e=this.isCollapsible();this.wasCollapsible&&e||(this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0].blur(),this.menuHideAll()),this.wasCollapsible=e}}else if(this.$disableOverlay){var i=this.$root.offset();this.$disableOverlay.css({top:i.top,left:i.left,width:this.$root.outerWidth(),height:this.$root.outerHeight()})}}}}),$.fn.dataSM=function(t,e){return e?this.data(t+"_smartmenus",e):this.data(t+"_smartmenus")},$.fn.removeDataSM=function(t){return this.removeData(t+"_smartmenus")},$.fn.smartmenus=function(options){if("string"==typeof options){var args=arguments,method=options;return Array.prototype.shift.call(args),this.each(function(){var t=$(this).data("smartmenus");t&&t[method]&&t[method].apply(t,args)})}return this.each(function(){var dataOpts=$(this).data("sm-options")||null;if(dataOpts)try{dataOpts=eval("("+dataOpts+")")}catch(e){dataOpts=null,alert('ERROR\n\nSmartMenus jQuery init:\nInvalid "data-sm-options" attribute value syntax.')}new $.SmartMenus(this,$.extend({},$.fn.smartmenus.defaults,options,dataOpts))})},$.fn.smartmenus.defaults={isPopup:!1,mainMenuSubOffsetX:0,mainMenuSubOffsetY:0,subMenusSubOffsetX:0,subMenusSubOffsetY:0,subMenusMinWidth:"10em",subMenusMaxWidth:"20em",subIndicators:!0,subIndicatorsPos:"append",subIndicatorsText:"",scrollStep:30,scrollAccelerate:!0,showTimeout:250,hideTimeout:500,showDuration:0,showFunction:null,hideDuration:0,hideFunction:function(t,e){t.fadeOut(200,e)},collapsibleShowDuration:0,collapsibleShowFunction:function(t,e){t.slideDown(200,e)},collapsibleHideDuration:0,collapsibleHideFunction:function(t,e){t.slideUp(200,e)},showOnClick:!1,hideOnClick:!0,noMouseOver:!1,keepInViewport:!0,keepHighlighted:!0,markCurrentItem:!1,markCurrentTree:!0,rightToLeftSubMenus:!1,bottomToTopSubMenus:!1,collapsibleBehavior:"default"},$}); \ No newline at end of file + * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function($){function initMouseDetection(t){var e=".smartmenus_mouse";if(mouseDetectionEnabled||t)mouseDetectionEnabled&&t&&($(document).off(e),mouseDetectionEnabled=!1);else{var i=!0,s=null,o={mousemove:function(t){var e={x:t.pageX,y:t.pageY,timeStamp:(new Date).getTime()};if(s){var o=Math.abs(s.x-e.x),a=Math.abs(s.y-e.y);if((o>0||a>0)&&2>=o&&2>=a&&300>=e.timeStamp-s.timeStamp&&(mouse=!0,i)){var n=$(t.target).closest("a");n.is("a")&&$.each(menuTrees,function(){return $.contains(this.$root[0],n[0])?(this.itemEnter({currentTarget:n[0]}),!1):void 0}),i=!1}}s=e}};o[touchEvents?"touchstart":"pointerover pointermove pointerout MSPointerOver MSPointerMove MSPointerOut"]=function(t){isTouchEvent(t.originalEvent)&&(mouse=!1)},$(document).on(getEventsNS(o,e)), +mouseDetectionEnabled=!0}}function isTouchEvent(t){return!/^(4|mouse)$/.test(t.pointerType)}function getEventsNS(t,e){e||(e="");var i={};for(var s in t)i[s.split(" ").join(e+" ")+e]=t[s];return i}var menuTrees=[],mouse=!1,touchEvents="ontouchstart"in window,mouseDetectionEnabled=!1,requestAnimationFrame=window.requestAnimationFrame||function(t){return setTimeout(t,1e3/60)},cancelAnimationFrame=window.cancelAnimationFrame||function(t){clearTimeout(t)},canAnimate=!!$.fn.animate;return $.SmartMenus=function(t,e){this.$root=$(t),this.opts=e,this.rootId="",this.accessIdPrefix="",this.$subArrow=null,this.activatedItems=[],this.visibleSubMenus=[],this.showTimeout=0,this.hideTimeout=0,this.scrollTimeout=0,this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.idInc=0,this.$firstLink=null,this.$firstSub=null,this.disabled=!1,this.$disableOverlay=null,this.$touchScrollingSub=null,this.cssTransforms3d="perspective"in t.style||"webkitPerspective"in t.style,this.wasCollapsible=!1,this.init()},$.extend( +$.SmartMenus,{hideAll:function(){$.each(menuTrees,function(){this.menuHideAll()})},destroy:function(){for(;menuTrees.length;)menuTrees[0].destroy();initMouseDetection(!0)},prototype:{init:function(t){var e=this;if(!t){menuTrees.push(this),this.rootId=((new Date).getTime()+Math.random()+"").replace(/\D/g,""),this.accessIdPrefix="sm-"+this.rootId+"-",this.$root.hasClass("sm-rtl")&&(this.opts.rightToLeftSubMenus=!0);var i=".smartmenus";this.$root.data("smartmenus",this).attr("data-smartmenus-id",this.rootId).dataSM("level",1).on(getEventsNS({"mouseover focusin":$.proxy(this.rootOver,this),"mouseout focusout":$.proxy(this.rootOut,this),keydown:$.proxy(this.rootKeyDown,this)},i)).on(getEventsNS({mouseenter:$.proxy(this.itemEnter,this),mouseleave:$.proxy(this.itemLeave,this),mousedown:$.proxy(this.itemDown,this),focus:$.proxy(this.itemFocus,this),blur:$.proxy(this.itemBlur,this),click:$.proxy(this.itemClick,this)},i),"a"),i+=this.rootId,this.opts.hideOnClick&&$(document).on(getEventsNS({touchstart:$.proxy( +this.docTouchStart,this),touchmove:$.proxy(this.docTouchMove,this),touchend:$.proxy(this.docTouchEnd,this),click:$.proxy(this.docClick,this)},i)),$(window).on(getEventsNS({"resize orientationchange":$.proxy(this.winResize,this)},i)),this.opts.subIndicators&&(this.$subArrow=$("").addClass("sub-arrow"),this.opts.subIndicatorsText&&this.$subArrow.html(this.opts.subIndicatorsText)),initMouseDetection()}if(this.$firstSub=this.$root.find("ul").each(function(){e.menuInit($(this))}).eq(0),this.$firstLink=this.$root.find("a").eq(0),this.opts.markCurrentItem){var s=/(index|default)\.[^#\?\/]*/i,o=/#.*/,a=window.location.href.replace(s,""),n=a.replace(o,"");this.$root.find("a").each(function(){var t=this.href.replace(s,""),i=$(this);(t==a||t==n)&&(i.addClass("current"),e.opts.markCurrentTree&&i.parentsUntil("[data-smartmenus-id]","ul").each(function(){$(this).dataSM("parent-a").addClass("current")}))})}this.wasCollapsible=this.isCollapsible()},destroy:function(t){if(!t){var e=".smartmenus";this.$root.removeData( +"smartmenus").removeAttr("data-smartmenus-id").removeDataSM("level").off(e),e+=this.rootId,$(document).off(e),$(window).off(e),this.opts.subIndicators&&(this.$subArrow=null)}this.menuHideAll();var i=this;this.$root.find("ul").each(function(){var t=$(this);t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.dataSM("shown-before")&&((i.opts.subMenusMinWidth||i.opts.subMenusMaxWidth)&&t.css({width:"",minWidth:"",maxWidth:""}).removeClass("sm-nowrap"),t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.css({zIndex:"",top:"",left:"",marginLeft:"",marginTop:"",display:""})),0==(t.attr("id")||"").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeDataSM("in-mega").removeDataSM("shown-before").removeDataSM("scroll-arrows").removeDataSM("parent-a").removeDataSM("level").removeDataSM("beforefirstshowfired").removeAttr("role").removeAttr("aria-hidden").removeAttr("aria-labelledby").removeAttr("aria-expanded"),this.$root.find("a.has-submenu").each(function(){var t=$(this);0==t.attr("id" +).indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeClass("has-submenu").removeDataSM("sub").removeAttr("aria-haspopup").removeAttr("aria-controls").removeAttr("aria-expanded").closest("li").removeDataSM("sub"),this.opts.subIndicators&&this.$root.find("span.sub-arrow").remove(),this.opts.markCurrentItem&&this.$root.find("a.current").removeClass("current"),t||(this.$root=null,this.$firstLink=null,this.$firstSub=null,this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),menuTrees.splice($.inArray(this,menuTrees),1))},disable:function(t){if(!this.disabled){if(this.menuHideAll(),!t&&!this.opts.isPopup&&this.$root.is(":visible")){var e=this.$root.offset();this.$disableOverlay=$('
    ').css({position:"absolute",top:e.top,left:e.left,width:this.$root.outerWidth(),height:this.$root.outerHeight(),zIndex:this.getStartZIndex(!0),opacity:0}).appendTo(document.body)}this.disabled=!0}},docClick:function(t){return this.$touchScrollingSub?( +this.$touchScrollingSub=null,void 0):((this.visibleSubMenus.length&&!$.contains(this.$root[0],t.target)||$(t.target).closest("a").length)&&this.menuHideAll(),void 0)},docTouchEnd:function(){if(this.lastTouch){if(!(!this.visibleSubMenus.length||void 0!==this.lastTouch.x2&&this.lastTouch.x1!=this.lastTouch.x2||void 0!==this.lastTouch.y2&&this.lastTouch.y1!=this.lastTouch.y2||this.lastTouch.target&&$.contains(this.$root[0],this.lastTouch.target))){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var t=this;this.hideTimeout=setTimeout(function(){t.menuHideAll()},350)}this.lastTouch=null}},docTouchMove:function(t){if(this.lastTouch){var e=t.originalEvent.touches[0];this.lastTouch.x2=e.pageX,this.lastTouch.y2=e.pageY}},docTouchStart:function(t){var e=t.originalEvent.touches[0];this.lastTouch={x1:e.pageX,y1:e.pageY,target:e.target}},enable:function(){this.disabled&&(this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),this.disabled=!1)},getClosestMenu:function(t){for( +var e=$(t).closest("ul");e.dataSM("in-mega");)e=e.parent().closest("ul");return e[0]||null},getHeight:function(t){return this.getOffset(t,!0)},getOffset:function(t,e){var i;"none"==t.css("display")&&(i={position:t[0].style.position,visibility:t[0].style.visibility},t.css({position:"absolute",visibility:"hidden"}).show());var s=t[0].getBoundingClientRect&&t[0].getBoundingClientRect(),o=s&&(e?s.height||s.bottom-s.top:s.width||s.right-s.left);return o||0===o||(o=e?t[0].offsetHeight:t[0].offsetWidth),i&&t.hide().css(i),o},getStartZIndex:function(t){var e=parseInt(this[t?"$root":"$firstSub"].css("z-index"));return!t&&isNaN(e)&&(e=parseInt(this.$root.css("z-index"))),isNaN(e)?1:e},getTouchPoint:function(t){return t.touches&&t.touches[0]||t.changedTouches&&t.changedTouches[0]||t},getViewport:function(t){var e=t?"Height":"Width",i=document.documentElement["client"+e],s=window["inner"+e];return s&&(i=Math.min(i,s)),i},getViewportHeight:function(){return this.getViewport(!0)},getViewportWidth:function(){ +return this.getViewport()},getWidth:function(t){return this.getOffset(t)},handleEvents:function(){return!this.disabled&&this.isCSSOn()},handleItemEvents:function(t){return this.handleEvents()&&!this.isLinkInMegaMenu(t)},isCollapsible:function(){return"static"==this.$firstSub.css("position")},isCSSOn:function(){return"inline"!=this.$firstLink.css("display")},isFixed:function(){var t="fixed"==this.$root.css("position");return t||this.$root.parentsUntil("body").each(function(){return"fixed"==$(this).css("position")?(t=!0,!1):void 0}),t},isLinkInMegaMenu:function(t){return $(this.getClosestMenu(t[0])).hasClass("mega-menu")},isTouchMode:function(){return!mouse||this.opts.noMouseOver||this.isCollapsible()},itemActivate:function(t,e){var i=t.closest("ul"),s=i.dataSM("level");if(s>1&&(!this.activatedItems[s-2]||this.activatedItems[s-2][0]!=i.dataSM("parent-a")[0])){var o=this;$(i.parentsUntil("[data-smartmenus-id]","ul").get().reverse()).add(i).each(function(){o.itemActivate($(this).dataSM("parent-a"))})}if(( +!this.isCollapsible()||e)&&this.menuHideSubMenus(this.activatedItems[s-1]&&this.activatedItems[s-1][0]==t[0]?s:s-1),this.activatedItems[s-1]=t,this.$root.triggerHandler("activate.smapi",t[0])!==!1){var a=t.dataSM("sub");a&&(this.isTouchMode()||!this.opts.showOnClick||this.clickActivated)&&this.menuShow(a)}},itemBlur:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&this.$root.triggerHandler("blur.smapi",e[0])},itemClick:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(this.$touchScrollingSub&&this.$touchScrollingSub[0]==e.closest("ul")[0])return this.$touchScrollingSub=null,t.stopPropagation(),!1;if(this.$root.triggerHandler("click.smapi",e[0])===!1)return!1;var i=$(t.target).is(".sub-arrow"),s=e.dataSM("sub"),o=s?2==s.dataSM("level"):!1,a=this.isCollapsible(),n=/toggle$/.test(this.opts.collapsibleBehavior),r=/link$/.test(this.opts.collapsibleBehavior),h=/^accordion/.test(this.opts.collapsibleBehavior);if(s&&!s.is(":visible")){if((!r||!a||i)&&(this.opts.showOnClick&&o&&( +this.clickActivated=!0),this.itemActivate(e,h),s.is(":visible")))return this.focusActivated=!0,!1}else if(a&&(n||i))return this.itemActivate(e,h),this.menuHide(s),n&&(this.focusActivated=!1),!1;return this.opts.showOnClick&&o||e.hasClass("disabled")||this.$root.triggerHandler("select.smapi",e[0])===!1?!1:void 0}},itemDown:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&e.dataSM("mousedown",!0)},itemEnter:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(!this.isTouchMode()){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);var i=this;this.showTimeout=setTimeout(function(){i.itemActivate(e)},this.opts.showOnClick&&1==e.closest("ul").dataSM("level")?1:this.opts.showTimeout)}this.$root.triggerHandler("mouseenter.smapi",e[0])}},itemFocus:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(!this.focusActivated||this.isTouchMode()&&e.dataSM("mousedown")||this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0]==e[0 +]||this.itemActivate(e,!0),this.$root.triggerHandler("focus.smapi",e[0]))},itemLeave:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(this.isTouchMode()||(e[0].blur(),this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0)),e.removeDataSM("mousedown"),this.$root.triggerHandler("mouseleave.smapi",e[0]))},menuHide:function(t){if(this.$root.triggerHandler("beforehide.smapi",t[0])!==!1&&(canAnimate&&t.stop(!0,!0),"none"!=t.css("display"))){var e=function(){t.css("z-index","")};this.isCollapsible()?canAnimate&&this.opts.collapsibleHideFunction?this.opts.collapsibleHideFunction.call(this,t,e):t.hide(this.opts.collapsibleHideDuration,e):canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,t,e):t.hide(this.opts.hideDuration,e),t.dataSM("scroll")&&(this.menuScrollStop(t),t.css({"touch-action":"","-ms-touch-action":"","-webkit-transform":"",transform:""}).off(".smartmenus_scroll").removeDataSM("scroll").dataSM("scroll-arrows").hide()),t.dataSM("parent-a").removeClass( +"highlighted").attr("aria-expanded","false"),t.attr({"aria-expanded":"false","aria-hidden":"true"});var i=t.dataSM("level");this.activatedItems.splice(i-1,1),this.visibleSubMenus.splice($.inArray(t,this.visibleSubMenus),1),this.$root.triggerHandler("hide.smapi",t[0])}},menuHideAll:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);for(var t=this.opts.isPopup?1:0,e=this.visibleSubMenus.length-1;e>=t;e--)this.menuHide(this.visibleSubMenus[e]);this.opts.isPopup&&(canAnimate&&this.$root.stop(!0,!0),this.$root.is(":visible")&&(canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,this.$root):this.$root.hide(this.opts.hideDuration))),this.activatedItems=[],this.visibleSubMenus=[],this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.$root.triggerHandler("hideAll.smapi")},menuHideSubMenus:function(t){for(var e=this.activatedItems.length-1;e>=t;e--){var i=this.activatedItems[e].dataSM("sub");i&&this.menuHide(i)}},menuInit:function(t){if(!t.dataSM("in-mega")){ +t.hasClass("mega-menu")&&t.find("ul").dataSM("in-mega",!0);for(var e=2,i=t[0];(i=i.parentNode.parentNode)!=this.$root[0];)e++;var s=t.prevAll("a").eq(-1);s.length||(s=t.prevAll().find("a").eq(-1)),s.addClass("has-submenu").dataSM("sub",t),t.dataSM("parent-a",s).dataSM("level",e).parent().dataSM("sub",t);var o=s.attr("id")||this.accessIdPrefix+ ++this.idInc,a=t.attr("id")||this.accessIdPrefix+ ++this.idInc;s.attr({id:o,"aria-haspopup":"true","aria-controls":a,"aria-expanded":"false"}),t.attr({id:a,role:"group","aria-hidden":"true","aria-labelledby":o,"aria-expanded":"false"}),this.opts.subIndicators&&s[this.opts.subIndicatorsPos](this.$subArrow.clone())}},menuPosition:function(t){var e,i,s=t.dataSM("parent-a"),o=s.closest("li"),a=o.parent(),n=t.dataSM("level"),r=this.getWidth(t),h=this.getHeight(t),u=s.offset(),l=u.left,c=u.top,d=this.getWidth(s),m=this.getHeight(s),p=$(window),f=p.scrollLeft(),v=p.scrollTop(),b=this.getViewportWidth(),S=this.getViewportHeight(),g=a.parent().is("[data-sm-horizontal-sub]" +)||2==n&&!a.hasClass("sm-vertical"),M=this.opts.rightToLeftSubMenus&&!o.is("[data-sm-reverse]")||!this.opts.rightToLeftSubMenus&&o.is("[data-sm-reverse]"),w=2==n?this.opts.mainMenuSubOffsetX:this.opts.subMenusSubOffsetX,T=2==n?this.opts.mainMenuSubOffsetY:this.opts.subMenusSubOffsetY;if(g?(e=M?d-r-w:w,i=this.opts.bottomToTopSubMenus?-h-T:m+T):(e=M?w-r:d-w,i=this.opts.bottomToTopSubMenus?m-T-h:T),this.opts.keepInViewport){var y=l+e,I=c+i;if(M&&f>y?e=g?f-y+e:d-w:!M&&y+r>f+b&&(e=g?f+b-r-y+e:w-r),g||(S>h&&I+h>v+S?i+=v+S-h-I:(h>=S||v>I)&&(i+=v-I)),g&&(I+h>v+S+.49||v>I)||!g&&h>S+.49){var x=this;t.dataSM("scroll-arrows")||t.dataSM("scroll-arrows",$([$('')[0],$('')[0]]).on({mouseenter:function(){t.dataSM("scroll").up=$(this).hasClass("scroll-up"),x.menuScroll(t)},mouseleave:function(e){x.menuScrollStop(t),x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(t){ +t.preventDefault()}}).insertAfter(t));var A=".smartmenus_scroll";if(t.dataSM("scroll",{y:this.cssTransforms3d?0:i-m,step:1,itemH:m,subH:h,arrowDownH:this.getHeight(t.dataSM("scroll-arrows").eq(1))}).on(getEventsNS({mouseover:function(e){x.menuScrollOver(t,e)},mouseout:function(e){x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(e){x.menuScrollMousewheel(t,e)}},A)).dataSM("scroll-arrows").css({top:"auto",left:"0",marginLeft:e+(parseInt(t.css("border-left-width"))||0),width:r-(parseInt(t.css("border-left-width"))||0)-(parseInt(t.css("border-right-width"))||0),zIndex:t.css("z-index")}).eq(g&&this.opts.bottomToTopSubMenus?0:1).show(),this.isFixed()){var C={};C[touchEvents?"touchstart touchmove touchend":"pointerdown pointermove pointerup MSPointerDown MSPointerMove MSPointerUp"]=function(e){x.menuScrollTouch(t,e)},t.css({"touch-action":"none","-ms-touch-action":"none"}).on(getEventsNS(C,A))}}}t.css({top:"auto",left:"0",marginLeft:e,marginTop:i-m})},menuScroll:function(t,e,i){var s,o=t.dataSM("scroll"), +a=t.dataSM("scroll-arrows"),n=o.up?o.upEnd:o.downEnd;if(!e&&o.momentum){if(o.momentum*=.92,s=o.momentum,.5>s)return this.menuScrollStop(t),void 0}else s=i||(e||!this.opts.scrollAccelerate?this.opts.scrollStep:Math.floor(o.step));var r=t.dataSM("level");if(this.activatedItems[r-1]&&this.activatedItems[r-1].dataSM("sub")&&this.activatedItems[r-1].dataSM("sub").is(":visible")&&this.menuHideSubMenus(r-1),o.y=o.up&&o.y>=n||!o.up&&n>=o.y?o.y:Math.abs(n-o.y)>s?o.y+(o.up?s:-s):n,t.css(this.cssTransforms3d?{"-webkit-transform":"translate3d(0, "+o.y+"px, 0)",transform:"translate3d(0, "+o.y+"px, 0)"}:{marginTop:o.y}),mouse&&(o.up&&o.y>o.downEnd||!o.up&&o.y0;t.dataSM("scroll-arrows").eq(i?0:1).is(":visible")&&(t.dataSM("scroll").up=i,this.menuScroll(t,!0))}e.preventDefault()},menuScrollOut:function(t,e){mouse&&(/^scroll-(up|down)/.test((e.relatedTarget||"").className)||(t[0]==e.relatedTarget||$.contains(t[0],e.relatedTarget))&&this.getClosestMenu(e.relatedTarget)==t[0]||t.dataSM("scroll-arrows").css("visibility","hidden"))},menuScrollOver:function(t,e){if(mouse&&!/^scroll-(up|down)/.test(e.target.className)&&this.getClosestMenu(e.target)==t[0]){this.menuScrollRefreshData(t);var i=t.dataSM("scroll"),s=$(window).scrollTop()-t.dataSM("parent-a").offset().top-i.itemH;t.dataSM("scroll-arrows").eq(0).css("margin-top",s).end().eq(1).css("margin-top",s+this.getViewportHeight()-i.arrowDownH).end().css("visibility","visible")}},menuScrollRefreshData:function(t){var e=t.dataSM("scroll"),i=$(window).scrollTop()-t.dataSM("parent-a").offset().top-e.itemH;this.cssTransforms3d&&(i=-(parseFloat(t.css("margin-top"))-i)),$.extend(e,{upEnd:i, +downEnd:i+this.getViewportHeight()-e.subH})},menuScrollStop:function(t){return this.scrollTimeout?(cancelAnimationFrame(this.scrollTimeout),this.scrollTimeout=0,t.dataSM("scroll").step=1,!0):void 0},menuScrollTouch:function(t,e){if(e=e.originalEvent,isTouchEvent(e)){var i=this.getTouchPoint(e);if(this.getClosestMenu(i.target)==t[0]){var s=t.dataSM("scroll");if(/(start|down)$/i.test(e.type))this.menuScrollStop(t)?(e.preventDefault(),this.$touchScrollingSub=t):this.$touchScrollingSub=null,this.menuScrollRefreshData(t),$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp});else if(/move$/i.test(e.type)){var o=void 0!==s.touchY?s.touchY:s.touchStartY;if(void 0!==o&&o!=i.pageY){this.$touchScrollingSub=t;var a=i.pageY>o;void 0!==s.up&&s.up!=a&&$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp}),$.extend(s,{up:a,touchY:i.pageY}),this.menuScroll(t,!0,Math.abs(i.pageY-o))}e.preventDefault()}else void 0!==s.touchY&&((s.momentum=15*Math.pow(Math.abs(i.pageY-s.touchStartY)/(e.timeStamp-s.touchStartTime),2) +)&&(this.menuScrollStop(t),this.menuScroll(t),e.preventDefault()),delete s.touchY)}}},menuShow:function(t){if((t.dataSM("beforefirstshowfired")||(t.dataSM("beforefirstshowfired",!0),this.$root.triggerHandler("beforefirstshow.smapi",t[0])!==!1))&&this.$root.triggerHandler("beforeshow.smapi",t[0])!==!1&&(t.dataSM("shown-before",!0),canAnimate&&t.stop(!0,!0),!t.is(":visible"))){var e=t.dataSM("parent-a"),i=this.isCollapsible();if((this.opts.keepHighlighted||i)&&e.addClass("highlighted"),i)t.removeClass("sm-nowrap").css({zIndex:"",width:"auto",minWidth:"",maxWidth:"",top:"",left:"",marginLeft:"",marginTop:""});else{if(t.css("z-index",this.zIndexInc=(this.zIndexInc||this.getStartZIndex())+1),(this.opts.subMenusMinWidth||this.opts.subMenusMaxWidth)&&(t.css({width:"auto",minWidth:"",maxWidth:""}).addClass("sm-nowrap"),this.opts.subMenusMinWidth&&t.css("min-width",this.opts.subMenusMinWidth),this.opts.subMenusMaxWidth)){var s=this.getWidth(t);t.css("max-width",this.opts.subMenusMaxWidth),s>this.getWidth(t +)&&t.removeClass("sm-nowrap").css("width",this.opts.subMenusMaxWidth)}this.menuPosition(t)}var o=function(){t.css("overflow","")};i?canAnimate&&this.opts.collapsibleShowFunction?this.opts.collapsibleShowFunction.call(this,t,o):t.show(this.opts.collapsibleShowDuration,o):canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,t,o):t.show(this.opts.showDuration,o),e.attr("aria-expanded","true"),t.attr({"aria-expanded":"true","aria-hidden":"false"}),this.visibleSubMenus.push(t),this.$root.triggerHandler("show.smapi",t[0])}},popupHide:function(t){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},t?1:this.opts.hideTimeout)},popupShow:function(t,e){if(!this.opts.isPopup)return alert('SmartMenus jQuery Error:\n\nIf you want to show this menu via the "popupShow" method, set the isPopup:true option.'),void 0;if(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),this.$root.dataSM("shown-before",!0), +canAnimate&&this.$root.stop(!0,!0),!this.$root.is(":visible")){this.$root.css({left:t,top:e});var i=this,s=function(){i.$root.css("overflow","")};canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,this.$root,s):this.$root.show(this.opts.showDuration,s),this.visibleSubMenus[0]=this.$root}},refresh:function(){this.destroy(!0),this.init(!0)},rootKeyDown:function(t){if(this.handleEvents())switch(t.keyCode){case 27:var e=this.activatedItems[0];if(e){this.menuHideAll(),e[0].focus();var i=e.dataSM("sub");i&&this.menuHide(i)}break;case 32:var s=$(t.target);if(s.is("a")&&this.handleItemEvents(s)){var i=s.dataSM("sub");i&&!i.is(":visible")&&(this.itemClick({currentTarget:t.target}),t.preventDefault())}}},rootOut:function(t){if(this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),!this.opts.showOnClick||!this.opts.hideOnClick)){var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},this.opts.hideTimeout)}}, +rootOver:function(t){this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0)},winResize:function(t){if(this.handleEvents()){if(!("onorientationchange"in window)||"orientationchange"==t.type){var e=this.isCollapsible();this.wasCollapsible&&e||(this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0].blur(),this.menuHideAll()),this.wasCollapsible=e}}else if(this.$disableOverlay){var i=this.$root.offset();this.$disableOverlay.css({top:i.top,left:i.left,width:this.$root.outerWidth(),height:this.$root.outerHeight()})}}}}),$.fn.dataSM=function(t,e){return e?this.data(t+"_smartmenus",e):this.data(t+"_smartmenus")},$.fn.removeDataSM=function(t){return this.removeData(t+"_smartmenus")},$.fn.smartmenus=function(options){if("string"==typeof options){var args=arguments,method=options;return Array.prototype.shift.call(args),this.each(function(){var t=$(this).data("smartmenus");t&&t[method]&&t[method].apply(t,args)})} +return this.each(function(){var dataOpts=$(this).data("sm-options")||null;if(dataOpts)try{dataOpts=eval("("+dataOpts+")")}catch(e){dataOpts=null,alert('ERROR\n\nSmartMenus jQuery init:\nInvalid "data-sm-options" attribute value syntax.')}new $.SmartMenus(this,$.extend({},$.fn.smartmenus.defaults,options,dataOpts))})},$.fn.smartmenus.defaults={isPopup:!1,mainMenuSubOffsetX:0,mainMenuSubOffsetY:0,subMenusSubOffsetX:0,subMenusSubOffsetY:0,subMenusMinWidth:"10em",subMenusMaxWidth:"20em",subIndicators:!0,subIndicatorsPos:"append",subIndicatorsText:"",scrollStep:30,scrollAccelerate:!0,showTimeout:250,hideTimeout:500,showDuration:0,showFunction:null,hideDuration:0,hideFunction:function(t,e){t.fadeOut(200,e)},collapsibleShowDuration:0,collapsibleShowFunction:function(t,e){t.slideDown(200,e)},collapsibleHideDuration:0,collapsibleHideFunction:function(t,e){t.slideUp(200,e)},showOnClick:!1,hideOnClick:!0,noMouseOver:!1,keepInViewport:!0,keepHighlighted:!0,markCurrentItem:!1,markCurrentTree:!0,rightToLeftSubMenus:!1, +bottomToTopSubMenus:!1,collapsibleBehavior:"default"},$}); diff --git a/Doc/html/mainpage_8h_source.html b/Doc/html/mainpage_8h_source.html index 010d228..67363ab 100644 --- a/Doc/html/mainpage_8h_source.html +++ b/Doc/html/mainpage_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/mainpage.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/mainpage.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
    - + + -
    +
    3@mainpage
    4
    5@section overview Обзор
    -
    6MyLibs - это набор библиотек для удобной работы с периферией микроконтроллеров STM32.
    +
    6MyLibs - это набор библиотек для удобной работы с STM32.
    7
    8@subsection features Основные возможности
    9
    @@ -140,85 +132,56 @@ $(function(){initNavTree('mainpage_8h_source.html',''); initResizable(); });
    30- Работа с энкодерами (чтение положения, обработка кнопок) (@ref MYLIBS_TIM_ENCODER)
    31- Настройка ШИМ и Output Compare (@ref MYLIBS_TIM_OC)
    32
    -
    33
    -
    34@subsection structure Структура проекта
    +
    33@subsubsection uart_module Модуль UART @ref MY_LIBS_UART
    +
    34- Базовая инициализация UART и его пинов одной функцией (@ref UART_Base_Init)
    35
    -
    36@code
    -
    37├── inc/ # Заголовочные файлы
    -
    38│ ├── mylibs_include.h # Главный include файл
    -
    39│ ├── mylibs_config.h # Конфигурация библиотек
    -
    40│ ├── mylibs_defs.h # Общие определения и макросы
    -
    41│ ├── bit_access.h # Битовый доступ к регистрам
    -
    42│ ├── trackers.h # Трекеры для отладки
    -
    43│ ├── trace.h # Трассировка и логирование
    -
    44│ ├── general_gpio.h # Работа с GPIO
    -
    45│ └── general_tim.h # Работа с таймерами
    -
    46└── src/ # Исходные файлы
    -
    47 ├── general_gpio.c # Реализация GPIO
    -
    48 └── general_tim.c # Реализация TIM
    -
    49@endcode
    -
    50
    -
    51@subsection usage_basic Использование
    -
    52
    -
    53Инструкция по подключению:
    -
    54
    -
    551. Настройте конфигурацию @ref MYLIBS_CONFIG в @ref mylibs_config.h
    -
    56
    -
    572. Подключите главный заголовочный файл:
    -
    58@code
    -
    59#include "mylibs_include.h"
    -
    60@endcode
    -
    61
    -
    623. Используйте нужные модули в своем коде
    -
    63
    -
    64@subsubsection gpio_example Пример работы с GPIO
    -
    65
    -
    66@code
    -
    67// Инициализация светодиода
    -
    68MX_GPIO_Init();
    -
    69GPIO_LEDTypeDef led;
    -
    70GPIO_LED_Init(&led, GPIOA, GPIO_PIN_5, 1);
    +
    36@subsubsection spi_module Модуль SPI @ref MY_LIBS_SPI
    +
    37- Базовая инициализация SPI и пинов одной функцией (@ref SPI_Base_Init)
    +
    38
    +
    39@subsection structure Структура проекта
    +
    40
    +
    41@code
    +
    42├── inc/ # Заголовочные файлы
    +
    43│ ├── mylibs_include.h # Главный include файл
    +
    44│ ├── mylibs_config.h # Конфигурация библиотек
    +
    45│ ├── mylibs_defs.h # Общие определения и макросы
    +
    46│ ├── bit_access.h # Битовый доступ к регистрам
    +
    47│ ├── evolve_optimizer.h # Оптимизатор (генетический алгоритм)
    +
    48│ ├── trackers.h # Трекеры для отладки
    +
    49│ ├── trace.h # Трассировка и логирование
    +
    50│ ├── general_gpio.h # Работа с GPIO
    +
    51 ├── general_spi.h # Работа с SPI
    +
    52│ └── general_tim.h # Работа с таймерами
    +
    53 ├── general_uart.h # Работа с UART
    +
    54└── src/ # Исходные файлы
    +
    55 ├── general_gpio.c # Реализация GPIO
    +
    56 ├── general_spi.c # Реализация SPI
    +
    57 └── general_tim.c # Реализация TIM
    +
    58 ├── general_uart.c # Реализация UART
    +
    59@endcode
    +
    60
    +
    61@subsection usage_basic Использование
    +
    62
    +
    63Инструкция по подключению:
    +
    64
    +
    651. Настройте конфигурацию @ref MYLIBS_CONFIG в @ref mylibs_config.h
    +
    66
    +
    672. Подключите главный заголовочный файл:
    +
    68@code
    +
    69#include "mylibs_include.h"
    +
    70@endcode
    71
    -
    72// Включение светодиода
    -
    73GPIO_LED_On(&led);
    -
    74
    -
    75// Запуск моргания
    -
    76GPIO_LED_Blink_Start(&led, 500); // Период 500 мс
    -
    77
    -
    78// В основном цикле
    -
    79while (1) {
    -
    80GPIO_LED_Dynamic_Handle(&led);
    -
    81}
    -
    82@endcode
    -
    83
    -
    84@subsubsection tim_example Пример работы с таймером
    -
    85
    -
    86@code
    -
    87// Настройка таймера
    -
    88TIM_SettingsTypeDef tim_settings = {0};
    -
    89tim_settings.htim.Instance = TIM2;
    -
    90tim_settings.sTimAHBFreqMHz = SystemCoreClock;
    -
    91tim_settings.sTickBaseUS = TIM_TickBase_1MS;
    -
    92tim_settings.sTimFreqHz = 1000; // 1 кГц
    -
    93tim_settings.sTimMode = TIM_IT_CONF;
    -
    94
    -
    95TIM_Base_Init(&tim_settings);
    -
    96HAL_TIM_Base_Start(&tim_settings.htim);
    -
    97@endcode
    -
    98
    -
    99@subsection dependencies Зависимости
    -
    100
    -
    101- HAL библиотека STM32
    -
    102- SEGGER RTT (опционально, для RTT трассировки)
    -
    103- FreeRTOS (опционально, для FreeRTOS задержек)
    -
    104 */
    +
    723. Используйте нужные модули в своем коде. Примеры использования приведены в соответствующей теме
    +
    73
    +
    74 */
    + diff --git a/Doc/html/menu.js b/Doc/html/menu.js index 717761d..15f9c52 100644 --- a/Doc/html/menu.js +++ b/Doc/html/menu.js @@ -22,7 +22,7 @@ @licend The above is the entire license notice for the JavaScript code in this file */ -function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { +function initMenu(relPath,searchEnabled,serverSide,searchPage,search,treeview) { function makeTree(data,relPath) { let result=''; if ('children' in data) { @@ -49,7 +49,7 @@ function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { searchBoxHtml='
    '+ '
    '+ '
     '+ + '" method="get">'+ ''+ @@ -60,8 +60,8 @@ function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { } else { searchBoxHtml='
    '+ ''+ - ' '+ + ''+ ''+ ''+ - ''+ + '
    '+ '
    '+ '
    '; } @@ -84,14 +83,12 @@ function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { '
    '); $('#main-nav').append(makeTree(menudata,relPath)); $('#main-nav').children(':first').addClass('sm sm-dox').attr('id','main-menu'); - if (searchBoxHtml) { - $('#main-menu').append('
  • '); - } + $('#main-menu').append('
  • '); const $mainMenuState = $('#main-menu-state'); let prevWidth = 0; if ($mainMenuState.length) { const initResizableIfExists = function() { - if (typeof initResizable==='function') initResizable(); + if (typeof initResizable==='function') initResizable(treeview); } // animate mobile menu $mainMenuState.change(function() { diff --git a/Doc/html/menudata.js b/Doc/html/menudata.js index a1b4cb1..7938a54 100644 --- a/Doc/html/menudata.js +++ b/Doc/html/menudata.js @@ -64,6 +64,7 @@ var menudata={children:[ {text:"c",url:"globals.html#index_c"}, {text:"d",url:"globals.html#index_d"}, {text:"e",url:"globals.html#index_e"}, +{text:"f",url:"globals.html#index_f"}, {text:"g",url:"globals.html#index_g"}, {text:"h",url:"globals.html#index_h"}, {text:"i",url:"globals.html#index_i"}, @@ -80,7 +81,9 @@ var menudata={children:[ {text:"g",url:"globals_func.html#index_g"}, {text:"h",url:"globals_func.html#index_h"}, {text:"r",url:"globals_func.html#index_r"}, -{text:"t",url:"globals_func.html#index_t"}]}, +{text:"s",url:"globals_func.html#index_s"}, +{text:"t",url:"globals_func.html#index_t"}, +{text:"u",url:"globals_func.html#index_u"}]}, {text:"Enumerations",url:"globals_enum.html"}, {text:"Enumerator",url:"globals_eval.html"}, {text:"Macros",url:"globals_defs.html",children:[ @@ -89,6 +92,7 @@ var menudata={children:[ {text:"c",url:"globals_defs.html#index_c"}, {text:"d",url:"globals_defs.html#index_d"}, {text:"e",url:"globals_defs.html#index_e"}, +{text:"f",url:"globals_defs.html#index_f"}, {text:"g",url:"globals_defs.html#index_g"}, {text:"h",url:"globals_defs.html#index_h"}, {text:"i",url:"globals_defs.html#index_i"}, diff --git a/Doc/html/mylibs__config_8h.html b/Doc/html/mylibs__config_8h.html index c5c8870..c0e7444 100644 --- a/Doc/html/mylibs__config_8h.html +++ b/Doc/html/mylibs__config_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_config.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_config.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    mylibs_config.h File Reference
    @@ -109,154 +104,145 @@ $(function(){initNavTree('mylibs__config_8h.html',''); initResizable(); });

    Конфигурации для библиотек MyLibs. More...

    #include "stm32f4xx_hal.h"
    -
    - + Include dependency graph for mylibs_config.h:
    +
    Include dependency graph for mylibs_config.h:
    -
    - + This graph shows which files directly or indirectly include this file:
    +
    This graph shows which files directly or indirectly include this file:

    Go to the source code of this file.

    - - - - - - - - - - - - - - - - - - - - + + - - - - - + +

    +

    Macros

    #define TRACKERS_ENABLE
     Включить трекеры
     
    #define SERIAL_TRACE_ENABLE
     Включить serial трассировку
     
    #define RTT_TRACE_ENABLE
     Включить serial трассировку через RTT.
     
    #define SWO_TRACE_ENABLE
     Включить serial трассировку через SWO.
     
    #define LOG_LEVEL   1
     Уровень log serial трассировки log_printf.
     
    #define RTT_FLASH_BUFFER_SIZE   1024
     Размер буфера RTT в Flash.
     
    #define RTT_FLASH_SECTOR   FLASH_SECTOR_11
     Сектор FLASH куда положится RTT буфер
     
    #define RTT_FLASH_SECTOR_START   0x080E0000
     Начало сектора RTT_FLASH_SECTOR.
     
    #define RTT_FLASH_SECTOR_END   0x080FFFFF
     Конец сектора RTT_FLASH_SECTOR.
     
    #define HARDFAULT_SERIAL_TRACE
     Включить обработку и serial трассировку Hardfault.
     
    #define HF_RTT_TAG_BASE   0xDEAD0000
     базовый тег для HardFault
     
    #define HF_RTT_TAIL_SIZE   RTT_FLASH_BUFFER_SIZE
     Размер буфера RTT, который сохранится при Hardfault.
     
    #define HF_STACK_DUMP_WORDS   32
     Сколько слов стека будет проанализировано во время Hardfault.
     
    #define HF_FLASH_ADDR   ((uint32_t)0x080FF000)
     Адрес FLASH куда положится RTT буфер
     
    #define HF_RAM_END   0x20030000
     Конец RAM памяти (чтобы во время анализа стека не выйти за пределы)
     
    #define GPIO_TRACE_ENABLE
     Включить GPIO трассировку
     
    #define ENABLE_EVOLVE_OPTIMIZATION
     Включить оптимизацию параметров
     
    #define EVOLVE_MAX_PARAMS   20
     Максимальное количество параметров
     
    #define EVOLVE_MAX_CANDIDATES   100
     Максимальное количество кандидатов для обучения
     
    #define local_time()
     Локальное время
    #define INCLUDE_EVOLVE_OPTIMIZER
     Подключить библиотеку для оптимизации параметров
     
    #define INCLUDE_BIT_ACCESS_LIB
     Подключить библиотеку с typedef с битовыми полями
     
    #define INCLUDE_TRACKERS_LIB
     Подключить библиотеку с трекерами
     
    #define INCLUDE_TRACE_LIB
     Подключить библиотеку с трейсами
     
    #define INCLUDE_GENERAL_PERIPH_LIBS
     Подключить библиотеку с периферией
     
    #define FREERTOS_DELAY
     Использовать FreeRTOS задержку, вместо HAL.
    -

    Detailed Description

    +

    Detailed Description

    Конфигурации для библиотек MyLibs.

    Definition in file mylibs_config.h.

    + +
    diff --git a/Doc/html/mylibs__config_8h.js b/Doc/html/mylibs__config_8h.js index 18173b2..522ab62 100644 --- a/Doc/html/mylibs__config_8h.js +++ b/Doc/html/mylibs__config_8h.js @@ -19,9 +19,11 @@ var mylibs__config_8h = [ "ENABLE_EVOLVE_OPTIMIZATION", "group___e_v_o_l_v_e___c_o_n_f_i_g.html#ga2cac097081444a7a9b040f4b11550e47", null ], [ "EVOLVE_MAX_PARAMS", "group___e_v_o_l_v_e___c_o_n_f_i_g.html#ga80d6162495fc3776d8902610657d4fee", null ], [ "EVOLVE_MAX_CANDIDATES", "group___e_v_o_l_v_e___c_o_n_f_i_g.html#ga7c1396e5c95c766afccdb45cbfcf5971", null ], + [ "local_time", "group___l_i_b_s___c_o_n_f_i_g.html#ga9c853b02c22f26023c34d1d404b6d653", null ], [ "INCLUDE_EVOLVE_OPTIMIZER", "group___l_i_b_s___c_o_n_f_i_g.html#ga66560656d080d6551627a19dfb847c66", null ], [ "INCLUDE_BIT_ACCESS_LIB", "group___l_i_b_s___c_o_n_f_i_g.html#gaf4ddb2a71ec0d05c2480e197cd17c0be", null ], [ "INCLUDE_TRACKERS_LIB", "group___l_i_b_s___c_o_n_f_i_g.html#ga4403055986b70bb02b8d37073a122e32", null ], [ "INCLUDE_TRACE_LIB", "group___l_i_b_s___c_o_n_f_i_g.html#ga0a3ca94b616997069dd53e2c6c2687d7", null ], - [ "INCLUDE_GENERAL_PERIPH_LIBS", "group___l_i_b_s___c_o_n_f_i_g.html#ga181a46326e46b60afb160190832c7281", null ] + [ "INCLUDE_GENERAL_PERIPH_LIBS", "group___l_i_b_s___c_o_n_f_i_g.html#ga181a46326e46b60afb160190832c7281", null ], + [ "FREERTOS_DELAY", "group___l_i_b_s___c_o_n_f_i_g.html#ga57c369737d5c0cfdb7baeecba0a4b151", null ] ]; \ No newline at end of file diff --git a/Doc/html/mylibs__config_8h__dep__incl.map b/Doc/html/mylibs__config_8h__dep__incl.map index 4efa19d..614dd43 100644 --- a/Doc/html/mylibs__config_8h__dep__incl.map +++ b/Doc/html/mylibs__config_8h__dep__incl.map @@ -1,40 +1,45 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Doc/html/mylibs__config_8h__dep__incl.md5 b/Doc/html/mylibs__config_8h__dep__incl.md5 index a472a39..6fc3081 100644 --- a/Doc/html/mylibs__config_8h__dep__incl.md5 +++ b/Doc/html/mylibs__config_8h__dep__incl.md5 @@ -1 +1 @@ -ee8ba613c66132201fb932c77e0ad018 \ No newline at end of file +8d5bfdadc4587edbd964391d4cdcd645 \ No newline at end of file diff --git a/Doc/html/mylibs__config_8h__dep__incl.png b/Doc/html/mylibs__config_8h__dep__incl.png index 2b6edb9..4ec6cdd 100644 Binary files a/Doc/html/mylibs__config_8h__dep__incl.png and b/Doc/html/mylibs__config_8h__dep__incl.png differ diff --git a/Doc/html/mylibs__config_8h__incl.map b/Doc/html/mylibs__config_8h__incl.map index f06cfbf..a83cb29 100644 --- a/Doc/html/mylibs__config_8h__incl.map +++ b/Doc/html/mylibs__config_8h__incl.map @@ -1,5 +1,5 @@ - - - - + + + + diff --git a/Doc/html/mylibs__config_8h__incl.md5 b/Doc/html/mylibs__config_8h__incl.md5 index d0ac3e6..f136b91 100644 --- a/Doc/html/mylibs__config_8h__incl.md5 +++ b/Doc/html/mylibs__config_8h__incl.md5 @@ -1 +1 @@ -7361bc4b175718270d049d00a1cbdbe2 \ No newline at end of file +fb457d2826e0abaa227e1adc840edd68 \ No newline at end of file diff --git a/Doc/html/mylibs__config_8h__incl.png b/Doc/html/mylibs__config_8h__incl.png index 021f13e..9c49be9 100644 Binary files a/Doc/html/mylibs__config_8h__incl.png and b/Doc/html/mylibs__config_8h__incl.png differ diff --git a/Doc/html/mylibs__config_8h_source.html b/Doc/html/mylibs__config_8h_source.html index e7e3ac5..325193d 100644 --- a/Doc/html/mylibs__config_8h_source.html +++ b/Doc/html/mylibs__config_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_config.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_config.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
    - + + -
    +
    77 * @{
    78 */
    79
    -
    80#define INCLUDE_EVOLVE_OPTIMIZER ///< Подключить библиотеку для оптимизации параметров
    -
    81#define INCLUDE_BIT_ACCESS_LIB ///< Подключить библиотеку с typedef с битовыми полями
    -
    82#define INCLUDE_TRACKERS_LIB ///< Подключить библиотеку с трекерами
    -
    83#define INCLUDE_TRACE_LIB ///< Подключить библиотеку с трейсами
    -
    84#define INCLUDE_GENERAL_PERIPH_LIBS ///< Подключить библиотеку с периферией
    -
    85//#define FREERTOS_DELAY ///< Использовать FreeRTOS задержку, вместо HAL
    -
    86
    -
    87/** LIBS_CONFIG
    -
    88 * @}
    -
    89 */
    -
    90
    -
    91/** MYLIBS_CONFIG
    -
    92 * @}
    -
    93 */
    -
    94#endif //__MYLIBS_CONFIG_H_
    +
    80#define local_time() uwTick ///< Локальное время
    +
    81
    +
    82#define INCLUDE_EVOLVE_OPTIMIZER ///< Подключить библиотеку для оптимизации параметров
    +
    83#define INCLUDE_BIT_ACCESS_LIB ///< Подключить библиотеку с typedef с битовыми полями
    +
    84#define INCLUDE_TRACKERS_LIB ///< Подключить библиотеку с трекерами
    +
    85#define INCLUDE_TRACE_LIB ///< Подключить библиотеку с трейсами
    +
    86#define INCLUDE_GENERAL_PERIPH_LIBS ///< Подключить библиотеку с периферией
    +
    87#define FREERTOS_DELAY ///< Использовать FreeRTOS задержку, вместо HAL
    +
    88
    +
    89/** LIBS_CONFIG
    +
    90 * @}
    +
    91 */
    +
    92
    +
    93/** MYLIBS_CONFIG
    +
    94 * @}
    +
    95 */
    +
    96#endif //__MYLIBS_CONFIG_H_
    + diff --git a/Doc/html/mylibs__defs_8h.html b/Doc/html/mylibs__defs_8h.html index 11b6fe0..44f1469 100644 --- a/Doc/html/mylibs__defs_8h.html +++ b/Doc/html/mylibs__defs_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_defs.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_defs.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    mylibs_defs.h File Reference
    @@ -110,130 +104,126 @@ $(function(){initNavTree('mylibs__defs_8h.html',''); initResizable(); });

    Заголочный файл для дефайнов библиотеки MyLibsGeneral. More...

    #include "mylibs_config.h"
    -
    - + Include dependency graph for mylibs_defs.h:
    +
    Include dependency graph for mylibs_defs.h:
    -
    - + This graph shows which files directly or indirectly include this file:
    +
    This graph shows which files directly or indirectly include this file:

    Go to the source code of this file.

    - - + - - + - - + - - + - - + - - + - - - - - + + + - - + - - + - - + - - + - - + - - + -

    +

    Macros

    #define MyLibs_Error_Handler(params)   Error_Handler(params)
    #define MyLibs_Error_Handler(params)
     Error_Handler который будет вызыватся в библиотеке
     
    #define check_null_ptr_1(p1)   (p1 == NULL)
    #define check_null_ptr_1(p1)
     Проверить один указатель на NULL.
     
    #define check_null_ptr_2(p1, p2)   ((p1 == NULL) || (p1 != NULL && p2 == NULL))
    #define check_null_ptr_2(p1, p2)
     Проверить два указателя на NULL.
     
    #define check_null_ptr_3(p1, p2, p3)   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && p3 == NULL))))
    #define check_null_ptr_3(p1, p2, p3)
     Проверить три указателя на NULL.
     
    #define check_null_ptr_4(p1, p2, p3, p4)   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && p4 == NULL))))))
    #define check_null_ptr_4(p1, p2, p3, p4)
     Проверить четыре указателя на NULL.
     
    #define check_null_ptr_5(p1, p2, p3, p4, p5)   ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && ((p4 == NULL) || (p4 != NULL && p5 == NULL))))))))
    #define check_null_ptr_5(p1, p2, p3, p4, p5)
     Проверить пять указателей на NULL.
     
    #define msDelay(_ms_)   HAL_Delay(_ms_)
     Задержка на указанное количество миллисекунд.
     
    #define msDelayStart(_pvar_)   *(_pvar_) = HAL_GetTick()
    #define msDelay(_ms_)
     Блокирующая задержка на указанное количество миллисекунд.
    #define msDelayStart(_pvar_)
     Начать отсчет задержки.
     
    #define msDelayWhileActive(_ms_, _pvar_)   (HAL_GetTick() - *(_pvar_) < _ms_)
    #define msDelayWhileActive(_ms_, _pvar_)
     Проверяет, активна ли задержка.
     
    #define msDelayWaitDone(_ms_, _pvar_)   (HAL_GetTick() - *(_pvar_) >= _ms_)
    #define msDelayWaitDone(_ms_, _pvar_)
     Проверяет, завершилась ли задержка.
     
    #define ClearStruct(_struct_)   memset(&(_struct_), 0, sizeof(_struct_))
    #define ClearStruct(_struct_)
     Обнуление структуры.
     
    #define Divide_Up(_val_, _div_)   ((_val_ - 1) / _div_) + 1 /* через мат выражение */
    #define Divide_Up(_val_, _div_)
     Деление с округлением вверх
     
    #define ByteSwap16(v)   (((v&0xFF00) >> (8)) | ((v&0x00FF) << (8)))
    #define ByteSwap16(v)
     Swap between Little Endian and Big Endian.
     
    #define ABS(x)   ( ((x) > 0)? (x) : -(x))
    #define ABS(x)
     Абсолютное значение числа
     
    - -

    +

    Functions

    void Error_Handler (void)
     
    -

    Detailed Description

    +

    Detailed Description

    Заголочный файл для дефайнов библиотеки MyLibsGeneral.

    Definition in file mylibs_defs.h.

    + +
    diff --git a/Doc/html/mylibs__defs_8h__dep__incl.map b/Doc/html/mylibs__defs_8h__dep__incl.map index 8fa37fc..ce26d5a 100644 --- a/Doc/html/mylibs__defs_8h__dep__incl.map +++ b/Doc/html/mylibs__defs_8h__dep__incl.map @@ -1,38 +1,43 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Doc/html/mylibs__defs_8h__dep__incl.md5 b/Doc/html/mylibs__defs_8h__dep__incl.md5 index 3966021..f9d40e4 100644 --- a/Doc/html/mylibs__defs_8h__dep__incl.md5 +++ b/Doc/html/mylibs__defs_8h__dep__incl.md5 @@ -1 +1 @@ -0d52bcfe55773d72fc2fd1ffe571809c \ No newline at end of file +ffd75cfd03af0339ae80d27ad27b99ee \ No newline at end of file diff --git a/Doc/html/mylibs__defs_8h__dep__incl.png b/Doc/html/mylibs__defs_8h__dep__incl.png index 37c8c1a..c8452b8 100644 Binary files a/Doc/html/mylibs__defs_8h__dep__incl.png and b/Doc/html/mylibs__defs_8h__dep__incl.png differ diff --git a/Doc/html/mylibs__defs_8h__incl.map b/Doc/html/mylibs__defs_8h__incl.map index 187d88e..3999afd 100644 --- a/Doc/html/mylibs__defs_8h__incl.map +++ b/Doc/html/mylibs__defs_8h__incl.map @@ -1,7 +1,7 @@ - - - - - - + + + + + + diff --git a/Doc/html/mylibs__defs_8h__incl.md5 b/Doc/html/mylibs__defs_8h__incl.md5 index 9e01e49..9f55d02 100644 --- a/Doc/html/mylibs__defs_8h__incl.md5 +++ b/Doc/html/mylibs__defs_8h__incl.md5 @@ -1 +1 @@ -8a0ac3856fdf2caf22b43c3ac8597efe \ No newline at end of file +b9276a0f630657b77b3f0cee41c5de21 \ No newline at end of file diff --git a/Doc/html/mylibs__defs_8h__incl.png b/Doc/html/mylibs__defs_8h__incl.png index 274d9bd..4b2f864 100644 Binary files a/Doc/html/mylibs__defs_8h__incl.png and b/Doc/html/mylibs__defs_8h__incl.png differ diff --git a/Doc/html/mylibs__defs_8h_source.html b/Doc/html/mylibs__defs_8h_source.html index 0733a3c..fc3c67c 100644 --- a/Doc/html/mylibs__defs_8h_source.html +++ b/Doc/html/mylibs__defs_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_defs.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_defs.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
    - + + -
    +
    72
    73/**
    74 * @def msDelay(_ms_)
    -
    75 * @brief Задержка на указанное количество миллисекунд.
    +
    75 * @brief Блокирующая задержка на указанное количество миллисекунд.
    76 * @param _ms_ Время задержки в миллисекундах.
    -
    77 * @note Использует HAL_Delay или osDelay в зависимости от @ref FREERTOS_DELAY.
    +
    77 * @note Использует задержку через @ref local_time или osDelay в зависимости от @ref FREERTOS_DELAY.
    78 */
    79#ifdef FREERTOS_DELAY
    -
    80 #define msDelay(_ms_) osDelay(_ms_)
    +
    80 #define msDelay(_ms_) osDelay(_ms_)
    81#else
    -
    82 #define msDelay(_ms_) HAL_Delay(_ms_)
    -
    83#endif
    -
    84
    -
    85
    -
    86/**
    -
    87 * @brief Начать отсчет задержки.
    -
    88 * @param _pvar_ Указатель на переменную типа uint32_t для хранения времени старта.
    -
    89 * @details После вызова этого макроса переменная _pvar_ содержит текущее количество миллисекунд
    -
    90 * с момента запуска системы (HAL_GetTick).
    -
    91 *
    -
    92 * Используется для реализации неблокирующих задержек.
    -
    93 */
    -
    94#define msDelayStart(_pvar_) *(_pvar_) = HAL_GetTick()
    -
    95
    -
    96/**
    -
    97 * @brief Проверяет, активна ли задержка.
    -
    98 * @param _ms_ Длительность задержки в миллисекундах.
    -
    99 * @param _pvar_ Указатель на переменную, в которой сохранено время начала (@ref msDelayStart).
    -
    100 * @retval 1 Задержка еще активна.
    -
    101 * @retval 0 Задержка завершена.
    -
    102 * @details
    -
    103 * Возвращает true, пока время задержки не истекло. Используется в проверках,
    -
    104 * когда нужно **действовать, пока задержка выполняется**. Пример:
    -
    105 * @code
    -
    106 * while(msDelayWhileActive(1000, &tick)) {
    -
    107 * // выполняем другие задачи, задержка не блокирует поток
    -
    108 * }
    -
    109 * @endcode
    -
    110 */
    -
    111#define msDelayWhileActive(_ms_, _pvar_) (HAL_GetTick() - *(_pvar_) < _ms_)
    -
    112
    -
    113/**
    -
    114 * @brief Проверяет, завершилась ли задержка.
    -
    115 * @param _ms_ Длительность задержки в миллисекундах.
    -
    116 * @param _pvar_ Указатель на переменную, в которой сохранено время начала (msDelayStart).
    -
    117 * @retval 1 Задержка завершена.
    -
    118 * @retval 0 Задержка еще активна.
    -
    119 * @details
    -
    120 * Возвращает true, когда задержка уже завершена. Используется в проверках,
    -
    121 * когда нужно **выполнить действие только после окончания задержки**. Пример:
    -
    122 * @code
    -
    123 * if(msDelayWaitDone(1000, &tick)) {
    -
    124 * // выполняем действие после завершения задержки
    -
    125 * }
    -
    126 * @endcode
    -
    127 */
    -
    128#define msDelayWaitDone(_ms_, _pvar_) (HAL_GetTick() - *(_pvar_) >= _ms_)
    -
    129
    -
    130/** DELAYS_DEFINES
    -
    131 * @}
    -
    132 */
    -
    133
    -
    134
    -
    135/***************************************************************************
    -
    136*******************************UTIL_DEFINES********************************/
    -
    137static int dummy;
    -
    138/**
    -
    139 * @addtogroup UTILS_DEFINES Utils defines
    -
    140 * @ingroup MYLIBS_DEFINES
    -
    141 * @brief Общие вспомогательные макросы
    -
    142 * @{
    -
    143 */
    -
    144
    -
    145/**
    -
    146 * @brief Обнуление структуры.
    -
    147 * @param _struct_ Структура, которую нужно обнулить.
    -
    148 * @details Макрос использует memset для обнуления всей памяти структуры.
    -
    149 * Используется для быстрой и безопасной инициализации переменных структур до нуля.
    -
    150 */
    -
    151#define ClearStruct(_struct_) memset(&(_struct_), 0, sizeof(_struct_))
    -
    152
    -
    153/**
    -
    154 * @brief Деление с округлением вверх
    -
    155 * @param _val_ Делимое.
    -
    156 * @param _div_ Делитель.
    -
    157 * @return Результат деления, округленный вверх.
    -
    158 * @details Если результат деления без остатка: он возвращается как есть
    -
    159 Если с остатком - округляется вверх
    -
    160 */
    -
    161//#define Divide_Up(_val_, _div_) (((_val_)%(_div_))? (_val_)/(_div_)+1 : (_val_)/_div_) /* через тернарный оператор */
    -
    162#define Divide_Up(_val_, _div_) ((_val_ - 1) / _div_) + 1 /* через мат выражение */
    -
    163
    -
    164/**
    -
    165 * @brief Swap between Little Endian and Big Endian
    -
    166 * @param v Исходное 16-битное значение.
    -
    167 * @return Результат с поменяными местами старшим и младшим байтом.
    -
    168 * @details Переключения между двумя типами хранения слова: HI-LO байты и LO-HI байты.
    -
    169 */
    -
    170#define ByteSwap16(v) (((v&0xFF00) >> (8)) | ((v&0x00FF) << (8)))
    -
    171
    -
    172/**
    -
    173 * @brief Абсолютное значение числа
    -
    174 * @param x Число.
    -
    175 * @return Абсолютное значение числа x.
    -
    176 * @details Берет число по модулю. Хз как работает библиотечный abs в stdlib.h, мб это быстрее, но вряд ли конечно.
    -
    177 */
    -
    178#define ABS(x) ( ((x) > 0)? (x) : -(x))
    -
    179
    -
    180/** UTILS_DEFINES
    -
    181 * @}
    -
    182 */
    -
    183
    -
    184#endif //__MYLIBS_DEFINES_H_
    +
    82 #define msDelay(_ms_) \
    +
    83 do { \
    +
    84 uint32_t _start_ = local_time(); \
    +
    85 while (local_time() - _start_ < (_ms_)) {} \
    +
    86 } while(0)
    +
    87#endif
    +
    88
    +
    89
    +
    90/**
    +
    91 * @brief Начать отсчет задержки.
    +
    92 * @param _pvar_ Указатель на переменную типа uint32_t для хранения времени старта.
    +
    93 * @details После вызова этого макроса переменная _pvar_ содержит текущее количество миллисекунд
    +
    94 * с момента запуска системы (@ref local_time).
    +
    95 *
    +
    96 * Используется для реализации неблокирующих задержек.
    +
    97 */
    +
    98#define msDelayStart(_pvar_) *(_pvar_) = local_time()
    +
    99
    +
    100/**
    +
    101 * @brief Проверяет, активна ли задержка.
    +
    102 * @param _ms_ Длительность задержки в миллисекундах.
    +
    103 * @param _pvar_ Указатель на переменную, в которой сохранено время начала (@ref msDelayStart).
    +
    104 * @retval 1 Задержка еще активна.
    +
    105 * @retval 0 Задержка завершена.
    +
    106 * @details
    +
    107 * Возвращает true, пока время задержки не истекло. Используется в проверках,
    +
    108 * когда нужно **действовать, пока задержка выполняется**. Пример:
    +
    109 * @code
    +
    110 * while(msDelayWhileActive(1000, &tick)) {
    +
    111 * // выполняем другие задачи, задержка не блокирует поток
    +
    112 * }
    +
    113 * @endcode
    +
    114 */
    +
    115#define msDelayWhileActive(_ms_, _pvar_) (local_time() - *(_pvar_) < _ms_)
    +
    116
    +
    117/**
    +
    118 * @brief Проверяет, завершилась ли задержка.
    +
    119 * @param _ms_ Длительность задержки в миллисекундах.
    +
    120 * @param _pvar_ Указатель на переменную, в которой сохранено время начала (msDelayStart).
    +
    121 * @retval 1 Задержка завершена.
    +
    122 * @retval 0 Задержка еще активна.
    +
    123 * @details
    +
    124 * Возвращает true, когда задержка уже завершена. Используется в проверках,
    +
    125 * когда нужно **выполнить действие только после окончания задержки**. Пример:
    +
    126 * @code
    +
    127 * if(msDelayWaitDone(1000, &tick)) {
    +
    128 * // выполняем действие после завершения задержки
    +
    129 * }
    +
    130 * @endcode
    +
    131 */
    +
    132#define msDelayWaitDone(_ms_, _pvar_) (local_time() - *(_pvar_) >= _ms_)
    +
    133
    +
    134/** DELAYS_DEFINES
    +
    135 * @}
    +
    136 */
    +
    137
    +
    138
    +
    139/***************************************************************************
    +
    140*******************************UTIL_DEFINES********************************/
    +
    141static int dummy;
    +
    142/**
    +
    143 * @addtogroup UTILS_DEFINES Utils defines
    +
    144 * @ingroup MYLIBS_DEFINES
    +
    145 * @brief Общие вспомогательные макросы
    +
    146 * @{
    +
    147 */
    +
    148
    +
    149/**
    +
    150 * @brief Обнуление структуры.
    +
    151 * @param _struct_ Структура, которую нужно обнулить.
    +
    152 * @details Макрос использует memset для обнуления всей памяти структуры.
    +
    153 * Используется для быстрой и безопасной инициализации переменных структур до нуля.
    +
    154 */
    +
    155#define ClearStruct(_struct_) memset(&(_struct_), 0, sizeof(_struct_))
    +
    156
    +
    157/**
    +
    158 * @brief Деление с округлением вверх
    +
    159 * @param _val_ Делимое.
    +
    160 * @param _div_ Делитель.
    +
    161 * @return Результат деления, округленный вверх.
    +
    162 * @details Если результат деления без остатка: он возвращается как есть
    +
    163 Если с остатком - округляется вверх
    +
    164 */
    +
    165//#define Divide_Up(_val_, _div_) (((_val_)%(_div_))? (_val_)/(_div_)+1 : (_val_)/_div_) /* через тернарный оператор */
    +
    166#define Divide_Up(_val_, _div_) ((_val_ - 1) / _div_) + 1 /* через мат выражение */
    +
    167
    +
    168/**
    +
    169 * @brief Swap between Little Endian and Big Endian
    +
    170 * @param v Исходное 16-битное значение.
    +
    171 * @return Результат с поменяными местами старшим и младшим байтом.
    +
    172 * @details Переключения между двумя типами хранения слова: HI-LO байты и LO-HI байты.
    +
    173 */
    +
    174#define ByteSwap16(v) (((v&0xFF00) >> (8)) | ((v&0x00FF) << (8)))
    +
    175
    +
    176/**
    +
    177 * @brief Абсолютное значение числа
    +
    178 * @param x Число.
    +
    179 * @return Абсолютное значение числа x.
    +
    180 * @details Берет число по модулю. Хз как работает библиотечный abs в stdlib.h, мб это быстрее, но вряд ли конечно.
    +
    181 */
    +
    182#define ABS(x) ( ((x) > 0)? (x) : -(x))
    +
    183
    +
    184/** UTILS_DEFINES
    +
    185 * @}
    +
    186 */
    +
    187
    +
    188
    +
    189
    +
    190/**
    +
    191 * @cond LIBS_INTERNAL
    +
    192 */
    +
    193
    +
    194
    +
    195/**
    +
    196 * @brief Аналог HAL макроса для привязки DMA к UART.
    +
    197 * @note @ref __HAL_LINKDMA.
    +
    198 */
    +
    199#define __USER_LINKDMA(__HANDLE__, __PPP_DMA_FIELD__, __DMA_HANDLE__) \
    +
    200do{ \
    +
    201(__HANDLE__)->__PPP_DMA_FIELD__ = (__DMA_HANDLE__); \
    +
    202(__DMA_HANDLE__)->Parent = (__HANDLE__);} while(0U)
    +
    203
    +
    204
    +
    205/** @endcond */
    +
    206#endif //__MYLIBS_DEFINES_H_
    Конфигурации для библиотек MyLibs.
    + diff --git a/Doc/html/mylibs__include_8h.html b/Doc/html/mylibs__include_8h.html index be2ac76..1ca6082 100644 --- a/Doc/html/mylibs__include_8h.html +++ b/Doc/html/mylibs__include_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_include.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_include.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    #include "trackers.h"
    #include "trace.h"
    #include "evolve_optimizer.h"
    -#include "general_flash.h"
    +#include "__general_flash.h"
    #include "general_gpio.h"
    #include "general_tim.h"
    -
    - + Include dependency graph for mylibs_include.h:
    +
    Include dependency graph for mylibs_include.h:

    Go to the source code of this file.

    -

    Detailed Description

    +

    Detailed Description

    Заголочный файл для всех библиотек

    Здесь нужно собрать библиотеки и дефайны, которые должны быть видны во всем проекте, чтобы не подключать 100 инклюдов в каждом ".c" файле

    Definition in file mylibs_include.h.

    + + diff --git a/Doc/html/mylibs__include_8h__incl.map b/Doc/html/mylibs__include_8h__incl.map index cbac04c..a466c9e 100644 --- a/Doc/html/mylibs__include_8h__incl.map +++ b/Doc/html/mylibs__include_8h__incl.map @@ -1,40 +1,41 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Doc/html/mylibs__include_8h__incl.md5 b/Doc/html/mylibs__include_8h__incl.md5 index fbafb1d..b5a412b 100644 --- a/Doc/html/mylibs__include_8h__incl.md5 +++ b/Doc/html/mylibs__include_8h__incl.md5 @@ -1 +1 @@ -eac9d1a6617c9c7d940c97bf6eaa8368 \ No newline at end of file +8e2530f35d180e53745360e22f4da2e4 \ No newline at end of file diff --git a/Doc/html/mylibs__include_8h__incl.png b/Doc/html/mylibs__include_8h__incl.png index 032dfec..e935326 100644 Binary files a/Doc/html/mylibs__include_8h__incl.png and b/Doc/html/mylibs__include_8h__incl.png differ diff --git a/Doc/html/mylibs__include_8h_source.html b/Doc/html/mylibs__include_8h_source.html index 5b3eb8f..4a8e2ca 100644 --- a/Doc/html/mylibs__include_8h_source.html +++ b/Doc/html/mylibs__include_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_include.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/mylibs_include.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({ - + + -
    +
    98
    99#ifdef INCLUDE_GENERAL_PERIPH_LIBS
    100
    -
    101#include "general_flash.h"
    +
    101#include "__general_flash.h"
    102#include "general_gpio.h"
    103#ifdef HAL_SPI_MODULE_ENABLED
    -
    104#include "general_spi.h"
    +
    104#include "general_spi.h"
    105#endif
    106#ifdef HAL_UART_MODULE_ENABLED
    -
    107#include "general_uart.h"
    +
    107#include "general_uart.h"
    108#endif
    109#ifdef HAL_TIM_MODULE_ENABLED
    110#include "general_tim.h"
    @@ -226,28 +218,31 @@ $(function(){initNavTree('mylibs__include_8h_source.html',''); initResizable();
    116
    117
    118/////////////////////////---USER SETTINGS---/////////////////////////
    -
    119// user includes
    +
    119// user includes
    120
    121// user settings
    122/////////////////////////---USER SETTINGS---/////////////////////////
    -
    123
    +
    123
    124
    125#endif // __MYLIBS_INCLUDE_H_
    Заголочный файл для дефайнов битового доступа.
    Заголовочный файл для адаптивного подбора параметров
    Заголовочный файл для модуля инициализации портов и работы с ними.
    +
    Заголовочный файл для модуля инициализации SPI.
    Заголовочный файл для модуля инициализации таймеров и работы с ними.
    +
    Заголовочный файл для модуля инициализации UART.
    Заголочный файл для дефайнов библиотеки MyLibsGeneral.
    Структура эволюционного оптимизатора
    Заголочный файл для работы с трассировкой.
    Заголочный файл для работы с трекерами Trackers defines.
    + diff --git a/Doc/html/navtree.css b/Doc/html/navtree.css index 69211d4..0ea3a07 100644 --- a/Doc/html/navtree.css +++ b/Doc/html/navtree.css @@ -11,8 +11,8 @@ #nav-tree li { white-space:nowrap; - margin:0px; - padding:0px; + margin:0; + padding:0; } #nav-tree .plus { @@ -20,15 +20,10 @@ } #nav-tree .selected { - background-image: url('tab_a.png'); - background-repeat:repeat-x; - color: var(--nav-text-active-color); - text-shadow: var(--nav-text-active-shadow); -} - -#nav-tree .selected .arrow { - color: var(--nav-arrow-selected-color); - text-shadow: none; + position: relative; + background-color: var(--nav-menu-active-bg); + border-radius: 0 6px 6px 0; + /*margin-right: 5px;*/ } #nav-tree img { @@ -48,6 +43,7 @@ margin:0px; padding:0px; font: 12px var(--font-family-nav); + line-height: 22px; } #nav-tree .label a { @@ -56,7 +52,7 @@ #nav-tree .selected a { text-decoration:none; - color:var(--nav-text-active-color); + color:var(--page-link-color); } #nav-tree .children_ul { @@ -65,8 +61,9 @@ } #nav-tree .item { - margin:0px; - padding:0px; + margin: 0 6px 0 -5px; + padding: 0 0 0 5px; + height: 22px; } #nav-tree { @@ -89,7 +86,6 @@ display:block; position: absolute; left: 0px; - width: $width; overflow : hidden; } @@ -98,15 +94,31 @@ } .ui-resizable-e { - background-image:var(--nav-splitbar-image); - background-size:100%; - background-repeat:repeat-y; - background-attachment: scroll; - cursor:ew-resize; + transition: opacity 0.5s ease; + background-color: var(--nav-splitbar-bg-color); + opacity:0; + cursor:col-resize; height:100%; right:0; top:0; width:6px; + position: relative; +} + +.ui-resizable-e:after { + content: ''; + display: block; + top: 50%; + left: 1px; + width: 2px; + height: 15px; + border-left: 1px solid var(--nav-splitbar-handle-color); + border-right: 1px solid var(--nav-splitbar-handle-color); + position: absolute; +} + +.ui-resizable-e:hover { + opacity: 1; } .ui-resizable-handle { @@ -121,24 +133,97 @@ } #nav-tree { - background-repeat:repeat-x; background-color: var(--nav-background-color); -webkit-overflow-scrolling : touch; /* iOS 5+ */ + scrollbar-width: thin; + border-right: 1px solid var(--nav-border-color); + padding-left: 5px; } #nav-sync { position:absolute; - top:5px; - right:24px; - z-index:0; + top:0px; + right:0px; + z-index:1; } #nav-sync img { opacity:0.3; } -#nav-sync img:hover { - opacity:0.9; +div.nav-sync-icon { + position: relative; + width: 24px; + height: 17px; + left: -6px; + top: -1px; + opacity: 0.7; + display: inline-block; + background-color: var(--sync-icon-background-color); + border: 1px solid var(--sync-icon-border-color); + box-sizing: content-box; +} + +div.nav-sync-icon:hover { + background-color: var(--sync-icon-selected-background-color); + opacity: 1.0; +} + +div.nav-sync-icon.active:after { + content: ''; + background-color: var(--sync-icon-background-color); + border-top: 2px solid var(--sync-icon-color); + position: absolute; + width: 16px; + height: 0px; + top: 7px; + left: 4px; +} + +div.nav-sync-icon.active:hover:after { + border-top: 2px solid var(--sync-icon-selected-color); +} + +span.sync-icon-left { + position: absolute; + padding: 0; + margin: 0; + top: 3px; + left: 4px; + display: inline-block; + width: 8px; + height: 8px; + border-left: 2px solid var(--sync-icon-color); + border-top: 2px solid var(--sync-icon-color); + transform: rotate(-45deg); +} + +span.sync-icon-right { + position: absolute; + padding: 0; + margin: 0; + top: 3px; + left: 10px; + display: inline-block; + width: 8px; + height: 8px; + border-right: 2px solid var(--sync-icon-color); + border-bottom: 2px solid var(--sync-icon-color); + transform: rotate(-45deg); +} + +div.nav-sync-icon:hover span.sync-icon-left { + border-left: 2px solid var(--sync-icon-selected-color); + border-top: 2px solid var(--sync-icon-selected-color); +} + +div.nav-sync-icon:hover span.sync-icon-right { + border-right: 2px solid var(--sync-icon-selected-color); + border-bottom: 2px solid var(--sync-icon-selected-color); +} + +#nav-path ul { + border-top: 1px solid var(--nav-breadcrumb-separator-color); } @media print @@ -147,3 +232,96 @@ div.ui-resizable-handle { display: none; position: relative; } } +/*---------------------------*/ +#container { + display: grid; + grid-template-columns: auto auto; + overflow: hidden; +} + +#page-nav { + background: var(--nav-background-color); + display: block; + width: 250px; + box-sizing: content-box; + position: relative; + border-left: 1px solid var(--nav-border-color); +} + +#page-nav-tree { + display: inline-block; +} + +#page-nav-resize-handle { + transition: opacity 0.5s ease; + background-color: var(--nav-splitbar-bg-color); + opacity:0; + cursor:col-resize; + height:100%; + right:0; + top:0; + width:6px; + position: relative; + z-index: 1; + user-select: none; +} + +#page-nav-resize-handle:after { + content: ''; + display: block; + top: 50%; + left: 1px; + width: 2px; + height: 15px; + border-left: 1px solid var(--nav-splitbar-handle-color); + border-right: 1px solid var(--nav-splitbar-handle-color); + position: absolute; +} + +#page-nav-resize-handle.dragging, +#page-nav-resize-handle:hover { + opacity: 1; +} + +#page-nav-contents { + padding: 0; + margin: 0; + display: block; + top: 0; + left: 0; + height: 100%; + width: 100%; + position: absolute; + overflow: auto; + scrollbar-width: thin; + -webkit-overflow-scrolling : touch; /* iOS 5+ */ +} + +ul.page-outline, +ul.page-outline ul { + text-indent: 0; + list-style: none outside none; + padding: 0 0 0 4px; +} + +ul.page-outline { + margin: 0 4px 4px 6px; +} + +ul.page-outline div.item { + font: 12px var(--font-family-nav); + line-height: 22px; +} + +ul.page-outline li { + white-space: nowrap; +} + +ul.page-outline li.vis { + background-color: var(--nav-breadcrumb-active-bg); +} + +#container.resizing { + cursor: col-resize; + user-select: none; +} diff --git a/Doc/html/navtree.js b/Doc/html/navtree.js index 884b79b..4fcf6e3 100644 --- a/Doc/html/navtree.js +++ b/Doc/html/navtree.js @@ -23,16 +23,34 @@ @licend The above is the entire license notice for the JavaScript code in this file */ -function initNavTree(toroot,relpath) { +function initNavTree(toroot,relpath,allMembersFile) { let navTreeSubIndices = []; - const ARROW_DOWN = '▼'; - const ARROW_RIGHT = '►'; + const ARROW_DOWN = ''; + const ARROW_RIGHT = ''; const NAVPATH_COOKIE_NAME = ''+'navpath'; + const fullSidebar = typeof page_layout!=='undefined' && page_layout==1; + + function getScrollBarWidth () { + let outer = $('
    ').css({visibility: 'hidden', width: 100, overflow: 'scroll', scrollbarWidth: 'thin'}).appendTo('body'); + let widthWithScroll = $('
    ').css({width: '100%'}).appendTo(outer).outerWidth(); + outer.remove(); + return 100 - widthWithScroll; + } + const scrollbarWidth = getScrollBarWidth(); + + function adjustSyncIconPosition() { + if (!fullSidebar) { + const nt = document.getElementById("nav-tree"); + const hasVerticalScrollbar = nt.scrollHeight > nt.clientHeight; + $("#nav-sync").css({right:parseInt(hasVerticalScrollbar?scrollbarWidth:0)}); + } + } const getData = function(varName) { const i = varName.lastIndexOf('/'); const n = i>=0 ? varName.substring(i+1) : varName; - return eval(n.replace(/-/g,'_')); + const e = n.replace(/-/g,'_'); + return window[e]; } const stripPath = function(uri) { @@ -77,7 +95,7 @@ function initNavTree(toroot,relpath) { const script = document.createElement('script'); script.id = scriptName; script.type = 'text/javascript'; - script.onload = func; + script.onload = function() { func(); adjustSyncIconPosition(); } script.src = scriptName+'.js'; head.appendChild(script); } @@ -96,8 +114,8 @@ function initNavTree(toroot,relpath) { node.expandToggle.href = "javascript:void(0)"; node.expandToggle.onclick = function() { if (node.expanded) { - $(node.getChildrenUL()).slideUp("fast"); - node.plus_img.innerHTML=ARROW_RIGHT; + $(node.getChildrenUL()).slideUp("fast",adjustSyncIconPosition); + $(node.plus_img.childNodes[0]).removeClass('opened').addClass('closed'); node.expanded = false; } else { expandNode(o, node, false, true); @@ -122,9 +140,9 @@ function initNavTree(toroot,relpath) { if (ancParent.hasClass('memItemLeft') || ancParent.hasClass('memtitle') || ancParent.hasClass('fieldname') || ancParent.hasClass('fieldtype') || ancParent.is(':header')) { - pos = ancParent.position().top; + pos = ancParent.offset().top; } else if (anchor.position()) { - pos = anchor.position().top; + pos = anchor.offset().top; } if (pos) { const dcOffset = docContent.offset().top; @@ -136,12 +154,33 @@ function initNavTree(toroot,relpath) { docContent.animate({ scrollTop: pos + dcScrTop - dcOffset },Math.max(50,Math.min(500,dist)),function() { - window.location.href=aname; animationInProgress=false; + if (anchor.parent().attr('class')=='memItemLeft') { + let rows = $('.memberdecls tr[class$="'+hashValue()+'"]'); + glowEffect(rows.children(),300); // member without details + } else if (anchor.parent().attr('class')=='fieldname') { + glowEffect(anchor.parent().parent(),1000); // enum value + } else if (anchor.parent().attr('class')=='fieldtype') { + glowEffect(anchor.parent().parent(),1000); // struct field + } else if (anchor.parent().is(":header")) { + glowEffect(anchor.parent(),1000); // section header + } else { + glowEffect(anchor.next(),1000); // normal member + } }); } } + function htmlToNode(html) { + const template = document.createElement('template'); + template.innerHTML = html; + const nNodes = template.content.childNodes.length; + if (nNodes !== 1) { + throw new Error(`html parameter must represent a single node; got ${nNodes}. `); + } + return template.content.firstChild; + } + const newNode = function(o, po, text, link, childrenData, lastNode) { const node = { children : [], @@ -153,7 +192,6 @@ function initNavTree(toroot,relpath) { parentNode : po, itemDiv : document.createElement("div"), labelSpan : document.createElement("span"), - label : document.createTextNode(text), expanded : false, childrenUL : null, getChildrenUL : function() { @@ -176,7 +214,7 @@ function initNavTree(toroot,relpath) { const a = document.createElement("a"); node.labelSpan.appendChild(a); po.getChildrenUL().appendChild(node.li); - a.appendChild(node.label); + a.appendChild(htmlToNode(''+text+'')); if (link) { let url; if (link.substring(0,1)=='^') { @@ -241,8 +279,8 @@ function initNavTree(toroot,relpath) { if (!node.childrenVisited) { getNode(o, node); } - $(node.getChildrenUL()).slideDown("fast"); - node.plus_img.innerHTML = ARROW_DOWN; + $(node.getChildrenUL()).slideDown("fast",adjustSyncIconPosition); + $(node.plus_img.childNodes[0]).addClass('opened').removeClass('closed'); node.expanded = true; if (setFocus) { $(node.expandToggle).focus(); @@ -260,18 +298,6 @@ function initNavTree(toroot,relpath) { const highlightAnchor = function() { const aname = hashUrl(); const anchor = $(aname); - if (anchor.parent().attr('class')=='memItemLeft') { - let rows = $('.memberdecls tr[class$="'+hashValue()+'"]'); - glowEffect(rows.children(),300); // member without details - } else if (anchor.parent().attr('class')=='fieldname') { - glowEffect(anchor.parent().parent(),1000); // enum value - } else if (anchor.parent().attr('class')=='fieldtype') { - glowEffect(anchor.parent().parent(),1000); // struct field - } else if (anchor.parent().is(":header")) { - glowEffect(anchor.parent(),1000); // section header - } else { - glowEffect(anchor.next(),1000); // normal member - } gotoAnchor(anchor,aname); } @@ -293,7 +319,6 @@ function initNavTree(toroot,relpath) { if ($('#nav-tree-contents .item:first').hasClass('selected')) { topOffset+=25; } - $('#nav-sync').css('top',topOffset+'px'); showRoot(); } @@ -310,7 +335,7 @@ function initNavTree(toroot,relpath) { getNode(o, node); } $(node.getChildrenUL()).css({'display':'block'}); - node.plus_img.innerHTML = ARROW_DOWN; + $(node.plus_img.childNodes[0]).removeClass('closed').addClass('opened'); node.expanded = true; const n = node.children[o.breadcrumbs[index]]; if (index+10) { // try root page without hash as fallback + gotoUrl(o,root,'',relpath); + } else { + o.breadcrumbs = $.extend(true, [], nti); + if (!o.breadcrumbs && root!=NAVTREE[0][1]) { // fallback: show index + navTo(o,NAVTREE[0][1],"",relpath); + $('.item').removeClass('selected'); + $('.item').removeAttr('id'); + } + if (o.breadcrumbs) { + o.breadcrumbs.unshift(0); // add 0 for root node + showNode(o, o.node, 0, hash); + } } - if (o.breadcrumbs) { - o.breadcrumbs.unshift(0); // add 0 for root node - showNode(o, o.node, 0, hash); + } + + const gotoUrl = function(o,root,hash,relpath) { + const url=root+hash; + let i=-1; + while (NAVTREEINDEX[i+1]<=url) i++; + if (i==-1) { i=0; root=NAVTREE[0][1]; } // fallback: show index + if (navTreeSubIndices[i]) { + gotoNode(o,i,root,hash,relpath) + } else { + getScript(relpath+'navtreeindex'+i,function() { + navTreeSubIndices[i] = window['NAVTREEINDEX'+i]; + if (navTreeSubIndices[i]) { + gotoNode(o,i,root,hash,relpath); + } + }); } } @@ -385,28 +416,15 @@ function initNavTree(toroot,relpath) { glowEffect(anchor.parent(),1000); // line number hash=''; // strip line number anchors } - const url=root+hash; - let i=-1; - while (NAVTREEINDEX[i+1]<=url) i++; - if (i==-1) { i=0; root=NAVTREE[0][1]; } // fallback: show index - if (navTreeSubIndices[i]) { - gotoNode(o,i,root,hash,relpath) - } else { - getScript(relpath+'navtreeindex'+i,function() { - navTreeSubIndices[i] = eval('NAVTREEINDEX'+i); - if (navTreeSubIndices[i]) { - gotoNode(o,i,root,hash,relpath); - } - }); - } + gotoUrl(o,root,hash,relpath); } const showSyncOff = function(n,relpath) { - n.html(''); + n.html(''); } const showSyncOn = function(n,relpath) { - n.html(''); + n.html(''); } const o = { @@ -453,30 +471,429 @@ function initNavTree(toroot,relpath) { showRoot(); $(window).bind('hashchange', () => { - if (window.location.hash && window.location.hash.length>1) { - let a; - if ($(location).attr('hash')) { - const clslink=stripPath(pathName())+':'+hashValue(); - a=$('.item a[class$="'+clslink.replace(/1) { + let a; + if ($(location).attr('hash')) { + const clslink=stripPath(pathName())+':'+hashValue(); + a=$('.item a[class$="'+clslink.replace(/ try to keep right panel width + const shrinkLeft = Math.min(deficit, leftPanelWidth-minPanelWidth); + leftPanelWidth -= shrinkLeft; + const remainingDeficit = deficit - shrinkLeft; + const shrinkRight = Math.min(remainingDeficit, rightPanelWidth-minPanelWidth); + rightPanelWidth -= shrinkRight; + } else { // dragging right handle -> try to keep left panel width + const shrinkRight = Math.min(deficit, rightPanelWidth-minPanelWidth); + rightPanelWidth -= shrinkRight; + const remainingDeficit = deficit - shrinkRight; + const shrinkLeft = Math.min(remainingDeficit, leftPanelWidth-minPanelWidth); + leftPanelWidth -= shrinkLeft; + } + } else { + rightPanelWidth = pagenav.length ? Math.max(minPanelWidth,rightPanelWidth) : 0; + leftPanelWidth = Math.max(minPanelWidth,leftPanelWidth); + } + return { leftPanelWidth, rightPanelWidth } + } + + function updateWidths(sidenavWidth,pagenavWidth,dragLeft) + { + const widths = constrainPanelWidths(sidenavWidth,pagenavWidth,dragLeft); + const widthStr = parseInt(widths.leftPanelWidth)+"px"; + content.css({marginLeft:widthStr}); + if (fullSidebar) { + footer.css({marginLeft:widthStr}); + if (mainnav) { + mainnav.css({marginLeft:widthStr}); + } + } + sidenav.css({width:widthStr}); + if (pagenav.length) { + container.css({gridTemplateColumns:'auto '+parseInt(widths.rightPanelWidth)+'px'}); + pagenav.css({width:parseInt(widths.rightPanelWidth-1)+'px'}); + } + return widths; + } + + function resizeWidth(dragLeft) { + const sidenavWidth = $(sidenav).outerWidth()-barWidth; + const pagenavWidth = pagenav.length ? $(pagenav).outerWidth() : 0; + const widths = updateWidths(sidenavWidth,pagenavWidth,dragLeft); + Cookie.writeSetting(RESIZE_COOKIE_NAME,widths.leftPanelWidth-barWidth); + if (pagenav.length) { + Cookie.writeSetting(PAGENAV_COOKIE_NAME,widths.rightPanelWidth); + } + } + + function restoreWidth(sidenavWidth,pagenavWidth) { + updateWidths(sidenavWidth,pagenavWidth,false); + showHideNavBar(); + } + + function resizeHeight() { + const headerHeight = header.outerHeight(); + const windowHeight = $(window).height(); + let contentHeight; + const footerHeight = footer.outerHeight(); + let navtreeHeight,sideNavHeight; + if (!fullSidebar) { + contentHeight = windowHeight - headerHeight - footerHeight - 1; + navtreeHeight = contentHeight; + sideNavHeight = contentHeight; + } else if (fullSidebar) { + contentHeight = windowHeight - footerHeight - 1; + navtreeHeight = windowHeight - headerHeight - 1; + sideNavHeight = windowHeight - 1; + if (mainnav) { + contentHeight -= mainnav.outerHeight(); + } + } + navtree.css({height:navtreeHeight + "px"}); + sidenav.css({height:sideNavHeight + "px"}); + content.css({height:contentHeight + "px"}); + resizeWidth(false); + showHideNavBar(); + if (location.hash.slice(1)) { + (document.getElementById(location.hash.slice(1))||document.body).scrollIntoView(); + } + } + + header = $("#top"); + content = $("#doc-content"); + footer = $("#nav-path"); + sidenav = $("#side-nav"); + if (document.getElementById('main-nav')) { + mainnav = $("#main-nav"); + } + navtree = $("#nav-tree"); + pagenav = $("#page-nav"); + container = $("#container"); + $(".side-nav-resizable").resizable({resize: function(e, ui) { resizeWidth(true); } }); + $(sidenav).resizable({ minWidth: 0 }); + if (pagenav.length) { + pagehandle = $("#page-nav-resize-handle"); + pagehandle.on('mousedown touchstart',function(e) { + $('body').addClass('resizing'); + pagehandle.addClass('dragging'); + $(document).on('mousemove touchmove',function(e) { + const clientX = e.clientX || e.originalEvent.touches[0].clientX; + let pagenavWidth = container[0].offsetWidth-clientX+barWidth/2; + const sidenavWidth = sidenav.width(); + const widths = constrainPanelWidths(sidenavWidth,pagenavWidth,false); + container.css({gridTemplateColumns:'auto '+parseInt(widths.rightPanelWidth)+'px'}); + pagenav.css({width:parseInt(widths.rightPanelWidth-1)+'px'}); + content.css({marginLeft:parseInt(widths.leftPanelWidth)+'px'}); + Cookie.writeSetting(PAGENAV_COOKIE_NAME,pagenavWidth); + }); + $(document).on('mouseup touchend', function(e) { + $('body').removeClass('resizing'); + pagehandle.removeClass('dragging'); + $(document).off('mousemove mouseup touchmove touchend'); + }); + }); + } else { + container.css({gridTemplateColumns:'auto'}); + } + const width = parseInt(Cookie.readSetting(RESIZE_COOKIE_NAME,250)); + const pagenavWidth = parseInt(Cookie.readSetting(PAGENAV_COOKIE_NAME,250)); + if (width) { restoreWidth(width+barWidth,pagenavWidth); } else { resizeWidth(); } + const url = location.href; + const i=url.indexOf("#"); + if (i>=0) window.location.hash=url.substr(i); + const _preventDefault = function(evt) { evt.preventDefault(); }; + $("#splitbar").bind("dragstart", _preventDefault).bind("selectstart", _preventDefault); + $(window).ready(function() { + let lastWidth = -1; + let lastHeight = -1; + $(window).resize(function() { + const newWidth = $(this).width(), newHeight = $(this).height(); + if (newWidth!=lastWidth || newHeight!=lastHeight) { + resizeHeight(); + navtree_trampoline.updateContentTop(); + lastWidth = newWidth; + lastHeight = newHeight; + } + }); + resizeHeight(); + lastWidth = $(window).width(); + lastHeight = $(window).height(); + content.scroll(function() { + navtree_trampoline.updateContentTop(); + }); + }); + } + + + function initPageToc() { + const topMapping = []; + const toc_contents = $('#page-nav-contents'); + const content=$('
      ').addClass('page-outline'); + + var entityMap = { + '&': '&', + '<': '<', + '>': '>', + '"': '"', + "'": ''', + '/': '/', + '`': '`', + '=': '=' + }; + function escapeHtml (string) { + return String(string).replace(/[&<>"'`=\/]/g, function (s) { + return entityMap[s]; + }); + } + + // for ClassDef/GroupDef/ModuleDef/ConceptDef/DirDef + const groupSections = []; + let currentGroup = null; + $('h2.groupheader, h2.memtitle').each(function(){ + const $element = $(this); + if ($element.hasClass('groupheader')) { + currentGroup = { groupHeader: $element, memTitles: [] }; + groupSections.push(currentGroup); + } else if ($element.hasClass('memtitle') && currentGroup) { + currentGroup.memTitles.push($element); + } + }); + groupSections.forEach(function(item){ + const title = item.groupHeader.text().trim(); + let id = item.groupHeader.attr('id'); + const table = item.groupHeader.parents('table.memberdecls'); + let rows = $(); + if (table.length>0) { + rows = table.find("tr[class^='memitem:'] td.memItemRight, tr[class^='memitem:'] td.memItemLeft.anon, tr[class=groupHeader] td"); + } + function hasSubItems() { + return item.memTitles.length>0 || rows.toArray().some(function(el) { return $(el).is(':visible'); }); + } + const li = $('
    • ').attr('id','nav-'+id); + const div = $('
      ').addClass('item'); + const span = $('').addClass('arrow').css({ paddingLeft:'0' }); + if (hasSubItems()) { + span.append($('').addClass('arrowhead opened')); + } + const ahref = $('').attr('href','#'+id).append(title); + content.append(li.append(div.append(span).append(ahref))); + topMapping.push(id); + const ulStack = []; + ulStack.push(content); + if (hasSubItems()) { + let last_id = undefined; + let inMemberGroup = false; + // declaration sections have rows for items + rows.each(function(){ + let td = $(this); + let tr = $(td).parent(); + const is_anon_enum = td.contents().first().text().trim()=='{'; + if (tr.hasClass('template')) { + tr = tr.prev(); + } + id = $(tr).attr('id'); + const text = is_anon_enum ? 'anonymous enum' : $(this).find('a:first,b,div.groupHeader').text(); + let isMemberGroupHeader = $(tr).hasClass('groupHeader'); + if ($(tr).is(":visible") && last_id!=id && id!==undefined) { + if (isMemberGroupHeader && inMemberGroup) { + ulStack.pop(); + inMemberGroup=false; + } + const li2 = $('
    • ').attr('id','nav-'+id); + const div2 = $('
      ').addClass('item'); + const span2 = $('').addClass('arrow').css({ paddingLeft:parseInt(ulStack.length*16)+'px' }); + const ahref = $('').attr('href','#'+id).append(escapeHtml(text)); + li2.append(div2.append(span2).append(ahref)); + topMapping.push(id); + if (isMemberGroupHeader) { + span2.append($('').addClass('arrowhead opened')); + ulStack[ulStack.length-1].append(li2); + const ul2 = $('
        '); + ulStack.push(ul2); + li2.append(div2).append(ul2); + inMemberGroup=true; + } else { + ulStack[ulStack.length-1].append(li2); + } + last_id=id; + } + }); + // detailed documentation has h2.memtitle sections for items + item.memTitles.forEach(function(data) { + const text = $(data).contents().not($(data).children().first()).text(); + const name = text.replace(/\(\)(\s*\[\d+\/\d+\])?$/, '') // func() [2/8] -> func + id = $(data).find('span.permalink a').attr('href') + if (id!==undefined && name!==undefined) { + const li2 = $('
      • ').attr('id','nav-'+id.substring(1)); + const div2 = $('
      • '); + const div = $('
        ').addClass('item'); + const span = $('').addClass('arrow').css({ paddingLeft:'0' }); + const ahref = $('').attr('href',srcBaseUrl+dstBaseUrl+pageName).addClass('noscroll'); + content.append(li.append(div.append(span).append(ahref.append(LISTOFALLMEMBERS)))); + } + + if (groupSections.length==0) { + // for PageDef + const sectionTree = [], sectionStack = []; + $('h1.doxsection, h2.doxsection, h3.doxsection, h4.doxsection, h5.doxsection, h6.doxsection').each(function(){ + const level = parseInt(this.tagName[1]); + const anchor = $(this).find('a.anchor').attr('id'); + const node = { text: $(this).html(), id: anchor, children: [] }; + while (sectionStack.length && sectionStack[sectionStack.length - 1].level >= level) sectionStack.pop(); + (sectionStack.length ? sectionStack[sectionStack.length - 1].children : sectionTree).push(node); + sectionStack.push({ ...node, level }); + }); + if (sectionTree.length>0) { + function render(nodes, level=0) { + nodes.map(n => { + const li = $('
      • ').attr('id','nav-'+n.id); + const div = $('
        ').addClass('item'); + const span = $('').addClass('arrow').attr('style','padding-left:'+parseInt(level*16)+'px;'); + if (n.children.length > 0) { span.append($('').addClass('arrowhead opened')); } + const url = $('').attr('href','#'+n.id); + content.append(li.append(div.append(span).append(url.append(n.text)))); + topMapping.push(n.id); + render(n.children,level+1); + }); + } + render(sectionTree); + } + } + + toc_contents.append(content); + + $(".page-outline a[href]:not(.noscroll)").click(function(e) { + e.preventDefault(); + const aname = $(this).attr("href"); + gotoAnchor($(aname),aname); + }); + + let lastScrollSourceOffset = -1; + let lastScrollTargetOffset = -1; + let lastScrollTargetId = ''; + + navtree_trampoline.updateContentTop = function() { + const pagenavcontents = $("#page-nav-contents"); + if (pagenavcontents.length) { + const content = $("#doc-content"); + const height = content.height(); + const navy = pagenavcontents.offset().top; + const yc = content.offset().top; + let offsets = [] + for (let i=0;imargin || ye>margin) && (yslastScrollTargetOffset) || + (!scrollDown && targetOffset { + navtree_trampoline.updateContentTop(); + },200); + } + $(document).ready(function() { initPageToc(); initResizable(); }); + } /* @license-end */ diff --git a/Doc/html/navtreedata.js b/Doc/html/navtreedata.js index b8330df..a65bea9 100644 --- a/Doc/html/navtreedata.js +++ b/Doc/html/navtreedata.js @@ -27,17 +27,15 @@ var NAVTREE = [ "MyLibs", "index.html", [ [ "Обзор", "index.html#overview", [ [ "Основные возможности", "index.html#features", [ - [ "Общие утилиты (General Tools)", "index.html#utils_module", null ], - [ "Трассировка Trace defines", "index.html#trace_module", null ], - [ "Модуль GPIO GPIO Tools", "index.html#gpio_module", null ], - [ "Модуль таймеров TIM Tools", "index.html#tim_module", null ] + [ "Общие утилиты (General Tools)", "index.html#utils_module", null ], + [ "Трассировка Trace defines", "index.html#trace_module", null ], + [ "Модуль GPIO GPIO Tools", "index.html#gpio_module", null ], + [ "Модуль таймеров TIM Tools", "index.html#tim_module", null ], + [ "Модуль UART UART Tools", "index.html#uart_module", null ], + [ "Модуль SPI SPI Tools", "index.html#spi_module", null ] ] ], [ "Структура проекта", "index.html#structure", null ], - [ "Использование", "index.html#usage_basic", [ - [ "Пример работы с GPIO", "index.html#gpio_example", null ], - [ "Пример работы с таймером", "index.html#tim_example", null ] - ] ], - [ "Зависимости", "index.html#dependencies", null ] + [ "Использование", "index.html#usage_basic", null ] ] ], [ "Topics", "topics.html", "topics" ], [ "Classes", "annotated.html", [ @@ -64,8 +62,9 @@ var NAVTREE = var NAVTREEINDEX = [ "____general__flash_8c_source.html", -"struct_r_t_t___flash_header__t.html#ae7276198385c8d6f6508f433d042d52a" +"struct_evolve_optimizer__t.html#a74b81df1c298c99162310f3f7d91735a" ]; -var SYNCONMSG = 'click to disable panel synchronisation'; -var SYNCOFFMSG = 'click to enable panel synchronisation'; \ No newline at end of file +var SYNCONMSG = 'click to disable panel synchronization'; +var SYNCOFFMSG = 'click to enable panel synchronization'; +var LISTOFALLMEMBERS = 'List of all members'; \ No newline at end of file diff --git a/Doc/html/navtreeindex0.js b/Doc/html/navtreeindex0.js index bc95142..ccfbfcc 100644 --- a/Doc/html/navtreeindex0.js +++ b/Doc/html/navtreeindex0.js @@ -2,30 +2,37 @@ var NAVTREEINDEX0 = { "____general__flash_8c_source.html":[3,0,0,1,0], "____general__flash_8h_source.html":[3,0,0,0,0], -"____general__spi_8c_source.html":[3,0,0,1,1], -"____general__spi_8h_source.html":[3,0,0,0,1], -"____general__uart_8c_source.html":[3,0,0,1,2], -"____general__uart_8h_source.html":[3,0,0,0,2], "annotated.html":[2,0], -"bit__access_8h.html":[3,0,0,0,3], -"bit__access_8h_source.html":[3,0,0,0,3], +"bit__access_8h.html":[3,0,0,0,1], +"bit__access_8h_source.html":[3,0,0,0,1], "classes.html":[2,1], "dir_9c80311a018e1f8cfb6659b73d634be4.html":[3,0,0,1], "dir_9e11e9a41112194af3eee6cc728f9515.html":[3,0,0], "dir_eb423fea8a9c4b9b32b922020ec391e1.html":[3,0,0,0], -"evolve__optimizer_8h.html":[3,0,0,0,4], -"evolve__optimizer_8h_source.html":[3,0,0,0,4], +"evolve__optimizer_8h.html":[3,0,0,0,2], +"evolve__optimizer_8h_source.html":[3,0,0,0,2], "files.html":[3,0], "functions.html":[2,2,0], "functions_vars.html":[2,2,1], -"general__gpio_8c.html":[3,0,0,1,3], -"general__gpio_8c_source.html":[3,0,0,1,3], -"general__gpio_8h.html":[3,0,0,0,5], -"general__gpio_8h_source.html":[3,0,0,0,5], -"general__tim_8c.html":[3,0,0,1,4], -"general__tim_8c_source.html":[3,0,0,1,4], -"general__tim_8h.html":[3,0,0,0,6], -"general__tim_8h_source.html":[3,0,0,0,6], +"general__gpio_8c.html":[3,0,0,1,1], +"general__gpio_8c_source.html":[3,0,0,1,1], +"general__gpio_8h.html":[3,0,0,0,3], +"general__gpio_8h_source.html":[3,0,0,0,3], +"general__spi_8c.html":[3,0,0,1,2], +"general__spi_8c.html#ae80d21e5cab86571709a2619442733b5":[3,0,0,1,2,1], +"general__spi_8c_source.html":[3,0,0,1,2], +"general__spi_8h.html":[3,0,0,0,4], +"general__spi_8h_source.html":[3,0,0,0,4], +"general__tim_8c.html":[3,0,0,1,3], +"general__tim_8c_source.html":[3,0,0,1,3], +"general__tim_8h.html":[3,0,0,0,5], +"general__tim_8h_source.html":[3,0,0,0,5], +"general__uart_8c.html":[3,0,0,1,4], +"general__uart_8c.html#a3abae05bbde5f3b402bf18ca13dc6a0b":[3,0,0,1,4,1], +"general__uart_8c.html#ad82d0cbd19151675135fd75dad315d05":[3,0,0,1,4,2], +"general__uart_8c_source.html":[3,0,0,1,4], +"general__uart_8h.html":[3,0,0,0,6], +"general__uart_8h_source.html":[3,0,0,0,6], "globals.html":[3,1,0], "globals_defs.html":[3,1,4], "globals_enum.html":[3,1,2], @@ -53,14 +60,13 @@ var NAVTREEINDEX0 = "group___e_v_o_l_v_e___c_o_n_f_i_g.html#ga7c1396e5c95c766afccdb45cbfcf5971":[1,0,0,1,2], "group___e_v_o_l_v_e___c_o_n_f_i_g.html#ga80d6162495fc3776d8902610657d4fee":[1,0,0,1,1], "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html":[1,0,1,1], -"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga2f2b1be34ad4eb1bf3267237200cd6c6":[1,0,1,1,4], -"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga38607e23d9234524bc7de5869b15b8eb":[1,0,1,1,6], -"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga4e3ea118b5b9068619c57724a925ba21":[1,0,1,1,7], +"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga2f2b1be34ad4eb1bf3267237200cd6c6":[1,0,1,1,3], +"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga38607e23d9234524bc7de5869b15b8eb":[1,0,1,1,5], +"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga4e3ea118b5b9068619c57724a925ba21":[1,0,1,1,6], "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga83abbcabaff9111c03ae2475ee72ea3e":[1,0,1,1,1], -"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga861c1c6a503c21441abcec0d57b848bc":[1,0,1,1,5], -"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga9c853b02c22f26023c34d1d404b6d653":[1,0,1,1,3], +"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga861c1c6a503c21441abcec0d57b848bc":[1,0,1,1,4], "group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#gaa1d5510fe5f0bd989473f3ebe324bde3":[1,0,1,1,2], -"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#gaef44a1f3298514569cc2b396a92101ef":[1,0,1,1,8], +"group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#gaef44a1f3298514569cc2b396a92101ef":[1,0,1,1,7], "group___g_p_i_o___i_n_i_t.html":[1,0,2,0,0,0], "group___g_p_i_o___i_n_i_t.html#ga19d9e3aced311179a2914e0c9b13d0f9":[1,0,2,0,0,0,3], "group___g_p_i_o___i_n_i_t.html#ga1d42e219765ec526d99e306638ac0023":[1,0,2,0,0,0,0], @@ -68,19 +74,30 @@ var NAVTREEINDEX0 = "group___g_p_i_o___i_n_i_t.html#gacd8900c9ec0efde1da3253b718574067":[1,0,2,0,0,0,4], "group___g_p_i_o___i_n_i_t.html#gaf2e697ac60e05813d45ea2c9c9e79c25":[1,0,2,0,0,0,1], "group___l_i_b_s___c_o_n_f_i_g.html":[1,0,0,2], -"group___l_i_b_s___c_o_n_f_i_g.html#ga0a3ca94b616997069dd53e2c6c2687d7":[1,0,0,2,3], -"group___l_i_b_s___c_o_n_f_i_g.html#ga181a46326e46b60afb160190832c7281":[1,0,0,2,4], -"group___l_i_b_s___c_o_n_f_i_g.html#ga4403055986b70bb02b8d37073a122e32":[1,0,0,2,2], -"group___l_i_b_s___c_o_n_f_i_g.html#ga66560656d080d6551627a19dfb847c66":[1,0,0,2,0], -"group___l_i_b_s___c_o_n_f_i_g.html#gaf4ddb2a71ec0d05c2480e197cd17c0be":[1,0,0,2,1], +"group___l_i_b_s___c_o_n_f_i_g.html#ga0a3ca94b616997069dd53e2c6c2687d7":[1,0,0,2,4], +"group___l_i_b_s___c_o_n_f_i_g.html#ga181a46326e46b60afb160190832c7281":[1,0,0,2,5], +"group___l_i_b_s___c_o_n_f_i_g.html#ga4403055986b70bb02b8d37073a122e32":[1,0,0,2,3], +"group___l_i_b_s___c_o_n_f_i_g.html#ga57c369737d5c0cfdb7baeecba0a4b151":[1,0,0,2,6], +"group___l_i_b_s___c_o_n_f_i_g.html#ga66560656d080d6551627a19dfb847c66":[1,0,0,2,1], +"group___l_i_b_s___c_o_n_f_i_g.html#ga9c853b02c22f26023c34d1d404b6d653":[1,0,0,2,0], +"group___l_i_b_s___c_o_n_f_i_g.html#gaf4ddb2a71ec0d05c2480e197cd17c0be":[1,0,0,2,2], "group___m_y___l_i_b_s___g_p_i_o.html":[1,0,2,0], -"group___m_y___l_i_b_s___t_i_m.html":[1,0,2,1], +"group___m_y___l_i_b_s___s_p_i.html":[1,0,2,1], +"group___m_y___l_i_b_s___s_p_i.html#ga0e177e3c57a8fcdc73b5602e72ec66ba":[1,0,2,1,2], +"group___m_y___l_i_b_s___s_p_i.html#ga333dd251bc878931086d48aa932b1a5f":[1,0,2,1,3], +"group___m_y___l_i_b_s___s_p_i.html#gab9f13318daf02bc5b5f302ae392dccac":[1,0,2,1,4], +"group___m_y___l_i_b_s___s_p_i.html#gac279cc3eaa35541edfe330a1844a85e4":[1,0,2,1,5], +"group___m_y___l_i_b_s___t_i_m.html":[1,0,2,2], +"group___m_y___l_i_b_s___u_a_r_t.html":[1,0,2,3], +"group___m_y___l_i_b_s___u_a_r_t.html#ga2a22e46ecb9e04b2ce197a0e9c09044a":[1,0,2,3,3], +"group___m_y___l_i_b_s___u_a_r_t.html#ga93ed6ceef4e3b5e7885786125cce93bc":[1,0,2,3,5], +"group___m_y___l_i_b_s___u_a_r_t.html#gab9313fd2f9fc6873ca6bfbc5b96edbbb":[1,0,2,3,4], +"group___m_y___l_i_b_s___u_a_r_t.html#gab9f07396b778505c934143e89953e154":[1,0,2,3,2], "group___m_y_l_i_b_s___a_l_l.html":[1,0], "group___m_y_l_i_b_s___c_o_n_f_i_g.html":[1,0,0], "group___m_y_l_i_b_s___d_e_f_i_n_e_s.html":[1,0,1], "group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html":[1,0,2,0,0], -"group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga580b842096340b066c28b24d6b315be6":[1,0,2,0,0,1], -"group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga962f010f783b81fcdd27eb6b53db28e6":[1,0,2,0,0,2], +"group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga962f010f783b81fcdd27eb6b53db28e6":[1,0,2,0,0,1], "group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html":[1,0,2,0,2], "group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#ga4b9572949326b050694cd55d0a7e5f6c":[1,0,2,0,2,3], "group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaa00f20021781464af3dfe74aa3e59a0a":[1,0,2,0,2,7], @@ -98,47 +115,52 @@ var NAVTREEINDEX0 = "group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#ga960b24335b2026abcad126ab8c422d70":[1,0,2,0,1,2], "group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#gacafee0e68877f2b25df843356871d1f7":[1,0,2,0,1,1], "group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.html":[1,0,2], -"group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html":[1,0,2,1,2], -"group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga108637af414bff3373059273b815ce9b":[1,0,2,1,2,2], -"group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga4c0dfde4e15f677600605348b4e97834":[1,0,2,1,2,0], -"group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga88c552a133cb6e3015453cccab74c07e":[1,0,2,1,2,1], -"group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html":[1,0,2,1,1], -"group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga117b795017e9e3a357ddefe323412761":[1,0,2,1,1,3], -"group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc":[1,0,2,1,1,1], -"group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#gac3bc6525f88c275e47eb864e6d567501":[1,0,2,1,1,2], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html":[1,0,2,1,3], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga7044214f24a9868ba7e1650b55e639ec":[1,0,2,1,3,4], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga879e3f1c919c02990736730275367115":[1,0,2,1,3,6], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaa0a51c870325217ac099881f09dd0800":[1,0,2,1,3,3], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaad47337be7ba2f6c0777c40d7278c931":[1,0,2,1,3,5], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaeb611874216a4661fb83366b99b9e787":[1,0,2,1,3,2], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a060b01e890891fd17c8f95b55a94139f":[1,0,2,1,3,3,2], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a096ef0ab67788487f69d8877c6d89b30":[1,0,2,1,3,3,3], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a18527a2d781eb4365aecd9a3184fc1da":[1,0,2,1,3,3,6], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a63df3123d0ddc592b189ed1594456ea2":[1,0,2,1,3,3,1], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a6a66c5ed1d966c9e30f0219b664d2b25":[1,0,2,1,3,3,4], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a7421a08abd119e71aa99eea5ab5d6daa":[1,0,2,1,3,3,5], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800ae838122c0e83bc57ad31b546bf2f00e5":[1,0,2,1,3,3,0], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaeb611874216a4661fb83366b99b9e787a89ecf1ef6d45ead2efcb7dd30396114c":[1,0,2,1,3,2,1], -"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaeb611874216a4661fb83366b99b9e787ab0869828a4dfd62eaa44868ca27835f8":[1,0,2,1,3,2,0], -"group___m_y_l_i_b_s___t_i_m___o_c.html":[1,0,2,1,0], -"group___m_y_l_i_b_s___t_i_m___o_c.html#gadb2f465d89f609e035867e980c3a29c6":[1,0,2,1,0,0], -"group___m_y_l_i_b_s___t_i_m___o_c.html#gae2608ca8023e9a0713af0b4fbfbc1889":[1,0,2,1,0,1], -"group___t_i_m___i_n_i_t.html":[1,0,2,1,3,0], -"group___t_i_m___i_n_i_t.html#ga1493b39c9214501180b81b4c892f9be0":[1,0,2,1,3,0,3], -"group___t_i_m___i_n_i_t.html#ga176c97f06ebcf14e06e5c5bdbfac44c2":[1,0,2,1,3,0,10], -"group___t_i_m___i_n_i_t.html#ga252f4fba93fc265110e83760e0590af3":[1,0,2,1,3,0,4], -"group___t_i_m___i_n_i_t.html#ga28ba33d7c6bf22821dafa5bcee4854be":[1,0,2,1,3,0,7], -"group___t_i_m___i_n_i_t.html#ga4e2b0e6cdf9eed74581b575c3fd9516b":[1,0,2,1,3,0,11], -"group___t_i_m___i_n_i_t.html#ga54a98c21365e0bc45b81555d2b101f2b":[1,0,2,1,3,0,0], -"group___t_i_m___i_n_i_t.html#ga5b5685a43273b6e37242a4aba3ee0617":[1,0,2,1,3,0,2], -"group___t_i_m___i_n_i_t.html#ga72535a44955b43cbcd56e25039ab32eb":[1,0,2,1,3,0,1], -"group___t_i_m___i_n_i_t.html#ga7cdc54cc8cbbb6e9f60001f1e3e6ec67":[1,0,2,1,3,0,6], -"group___t_i_m___i_n_i_t.html#ga8fe31b98160627d19038222910be3f46":[1,0,2,1,3,0,5], -"group___t_i_m___i_n_i_t.html#ga98c0691052d1da2c4053dd3586ff7ce9":[1,0,2,1,3,0,9], -"group___t_i_m___i_n_i_t.html#ga9ae40be31d5271abe3e49f896d916d5c":[1,0,2,1,3,0,13], -"group___t_i_m___i_n_i_t.html#gaac627c0e98c9594cc41b1b46eb39e44a":[1,0,2,1,3,0,8], -"group___t_i_m___i_n_i_t.html#gaf48ef87650517652ddec039a189507ac":[1,0,2,1,3,0,12], +"group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html":[1,0,2,2,1], +"group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga108637af414bff3373059273b815ce9b":[1,0,2,2,1,2], +"group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga4c0dfde4e15f677600605348b4e97834":[1,0,2,2,1,0], +"group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga88c552a133cb6e3015453cccab74c07e":[1,0,2,2,1,1], +"group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html":[1,0,2,2,3], +"group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga117b795017e9e3a357ddefe323412761":[1,0,2,2,3,3], +"group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc":[1,0,2,2,3,1], +"group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#gac3bc6525f88c275e47eb864e6d567501":[1,0,2,2,3,2], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html":[1,0,2,2,0], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga7044214f24a9868ba7e1650b55e639ec":[1,0,2,2,0,4], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga879e3f1c919c02990736730275367115":[1,0,2,2,0,6], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaa0a51c870325217ac099881f09dd0800":[1,0,2,2,0,3], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaad47337be7ba2f6c0777c40d7278c931":[1,0,2,2,0,5], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaeb611874216a4661fb83366b99b9e787":[1,0,2,2,0,2], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a060b01e890891fd17c8f95b55a94139f":[1,0,2,2,0,3,2], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a096ef0ab67788487f69d8877c6d89b30":[1,0,2,2,0,3,3], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a18527a2d781eb4365aecd9a3184fc1da":[1,0,2,2,0,3,6], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a63df3123d0ddc592b189ed1594456ea2":[1,0,2,2,0,3,1], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a6a66c5ed1d966c9e30f0219b664d2b25":[1,0,2,2,0,3,4], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a7421a08abd119e71aa99eea5ab5d6daa":[1,0,2,2,0,3,5], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800ae838122c0e83bc57ad31b546bf2f00e5":[1,0,2,2,0,3,0], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaeb611874216a4661fb83366b99b9e787a89ecf1ef6d45ead2efcb7dd30396114c":[1,0,2,2,0,2,1], +"group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaeb611874216a4661fb83366b99b9e787ab0869828a4dfd62eaa44868ca27835f8":[1,0,2,2,0,2,0], +"group___m_y_l_i_b_s___t_i_m___o_c.html":[1,0,2,2,2], +"group___m_y_l_i_b_s___t_i_m___o_c.html#gadb2f465d89f609e035867e980c3a29c6":[1,0,2,2,2,0], +"group___m_y_l_i_b_s___t_i_m___o_c.html#gae2608ca8023e9a0713af0b4fbfbc1889":[1,0,2,2,2,1], +"group___s_p_i___i_n_i_t.html":[1,0,2,1,0], +"group___s_p_i___i_n_i_t.html#ga2fe0c8aeb2c61679f32836fef479eedf":[1,0,2,1,0,1], +"group___s_p_i___i_n_i_t.html#ga53687cddb8e39e76a79b8ffaa152fb2b":[1,0,2,1,0,2], +"group___s_p_i___i_n_i_t.html#ga5fdd6e5934a8005ef05b80f6d95883dc":[1,0,2,1,0,3], +"group___s_p_i___i_n_i_t.html#ga8ad4712bf4add56892d057778e826e0c":[1,0,2,1,0,0], +"group___t_i_m___i_n_i_t.html":[1,0,2,2,0,0], +"group___t_i_m___i_n_i_t.html#ga1493b39c9214501180b81b4c892f9be0":[1,0,2,2,0,0,3], +"group___t_i_m___i_n_i_t.html#ga176c97f06ebcf14e06e5c5bdbfac44c2":[1,0,2,2,0,0,10], +"group___t_i_m___i_n_i_t.html#ga252f4fba93fc265110e83760e0590af3":[1,0,2,2,0,0,4], +"group___t_i_m___i_n_i_t.html#ga28ba33d7c6bf22821dafa5bcee4854be":[1,0,2,2,0,0,7], +"group___t_i_m___i_n_i_t.html#ga4e2b0e6cdf9eed74581b575c3fd9516b":[1,0,2,2,0,0,11], +"group___t_i_m___i_n_i_t.html#ga54a98c21365e0bc45b81555d2b101f2b":[1,0,2,2,0,0,0], +"group___t_i_m___i_n_i_t.html#ga5b5685a43273b6e37242a4aba3ee0617":[1,0,2,2,0,0,2], +"group___t_i_m___i_n_i_t.html#ga72535a44955b43cbcd56e25039ab32eb":[1,0,2,2,0,0,1], +"group___t_i_m___i_n_i_t.html#ga7cdc54cc8cbbb6e9f60001f1e3e6ec67":[1,0,2,2,0,0,6], +"group___t_i_m___i_n_i_t.html#ga8fe31b98160627d19038222910be3f46":[1,0,2,2,0,0,5], +"group___t_i_m___i_n_i_t.html#ga98c0691052d1da2c4053dd3586ff7ce9":[1,0,2,2,0,0,9], +"group___t_i_m___i_n_i_t.html#ga9ae40be31d5271abe3e49f896d916d5c":[1,0,2,2,0,0,13], +"group___t_i_m___i_n_i_t.html#gaac627c0e98c9594cc41b1b46eb39e44a":[1,0,2,2,0,0,8], +"group___t_i_m___i_n_i_t.html#gaf48ef87650517652ddec039a189507ac":[1,0,2,2,0,0,12], "group___t_r_a_c_e.html":[1,0,1,5], "group___t_r_a_c_e___c_o_n_f_i_g.html":[1,0,0,0], "group___t_r_a_c_e___c_o_n_f_i_g.html#ga00ff2175bdc1fb11c8ec970ea3010dd8":[1,0,0,0,2], @@ -192,21 +214,28 @@ var NAVTREEINDEX0 = "group___t_r_a_c_k_e_r_s.html#gad91d8ca89074270fc040c0449e57cf07":[1,0,1,6,3], "group___t_r_a_c_k_e_r_s.html#gadd7fd2c6e3a4800f1d5ddab35fd4b43e":[1,0,1,6,2], "group___t_r_a_c_k_e_r_s.html#gae860b6947c6e317e14d40bd7b4b8eb74":[1,0,1,6,16], +"group___u_a_r_t___i_n_i_t.html":[1,0,2,3,0], +"group___u_a_r_t___i_n_i_t.html#ga167269406e73327b95c3bb7b9cfe6d89":[1,0,2,3,0,0], +"group___u_a_r_t___i_n_i_t.html#ga592c6bf4a6496d6806ba0838cdfa2340":[1,0,2,3,0,5], +"group___u_a_r_t___i_n_i_t.html#ga6dadd967b428aade24008ec060009976":[1,0,2,3,0,3], +"group___u_a_r_t___i_n_i_t.html#ga779530e93e7aa1f25eb13045ec42b8e7":[1,0,2,3,0,4], +"group___u_a_r_t___i_n_i_t.html#gaacb3968508217a0d8b3f64aa0c8aa07d":[1,0,2,3,0,2], +"group___u_a_r_t___i_n_i_t.html#gace54f148bb1d72f13bf397d096d38d1b":[1,0,2,3,0,1], +"group___u_a_r_t___i_n_i_t.html#gafaeb8bdd4aa7fb1987505530daa90868":[1,0,2,3,0,6], "group___u_t_i_l_s___d_e_f_i_n_e_s.html":[1,0,1,4], "group___u_t_i_l_s___d_e_f_i_n_e_s.html#ga0f22e895ac7781c3d1b68fee182c4291":[1,0,1,4,2], "group___u_t_i_l_s___d_e_f_i_n_e_s.html#ga996f7be338ccb40d1a2a5abc1ad61759":[1,0,1,4,3], "group___u_t_i_l_s___d_e_f_i_n_e_s.html#gabf45f2b60eedf80cf9d1dbe4302a741e":[1,0,1,4,1], "group___u_t_i_l_s___d_e_f_i_n_e_s.html#gaf5e598848326d48e86167e5099a029be":[1,0,1,4,0], "index.html":[], -"index.html#dependencies":[0,3], "index.html#features":[0,0], -"index.html#gpio_example":[0,2,0], "index.html#gpio_module":[0,0,2], "index.html#overview":[0], +"index.html#spi_module":[0,0,5], "index.html#structure":[0,1], -"index.html#tim_example":[0,2,1], "index.html#tim_module":[0,0,3], "index.html#trace_module":[0,0,1], +"index.html#uart_module":[0,0,4], "index.html#usage_basic":[0,2], "index.html#utils_module":[0,0,0], "mainpage_8h_source.html":[3,0,0,2], @@ -220,34 +249,5 @@ var NAVTREEINDEX0 = "struct_evolve_optimizer__t.html":[1,0,1,1,0], "struct_evolve_optimizer__t.html#a0ae0e63ba351335d4445d927991c64ae":[1,0,1,1,0,5], "struct_evolve_optimizer__t.html#a1c270fce82e0c97e6c88fd0971c1eed8":[1,0,1,1,0,1], -"struct_evolve_optimizer__t.html#a74b81df1c298c99162310f3f7d91735a":[1,0,1,1,0,8], -"struct_evolve_optimizer__t.html#a80eb0b8525b6bb838484f5922b9d8f7c":[1,0,1,1,0,0], -"struct_evolve_optimizer__t.html#a93f628397c2f8d4027f2906752b650df":[1,0,1,1,0,6], -"struct_evolve_optimizer__t.html#a950cd70cb6bff33b78ad35ee58c729a6":[1,0,1,1,0,3], -"struct_evolve_optimizer__t.html#ac35c7ca8cede4ab9c53a2845a91cd1b1":[1,0,1,1,0,2], -"struct_evolve_optimizer__t.html#aec67667fd1f1533e693e41c79bc28da4":[1,0,1,1,0,7], -"struct_evolve_optimizer__t.html#af779c7aeba0053e36cee7aade160f1c8":[1,0,1,1,0,4], -"struct_g_p_i_o___l_e_d_type_def.html":[1,0,2,0,2,0], -"struct_g_p_i_o___l_e_d_type_def.html#a684ff60e4c94daf2221524cdc6fcc978":[1,0,2,0,2,0,2], -"struct_g_p_i_o___l_e_d_type_def.html#a6cc026931a4681732f9a329ae03098ec":[1,0,2,0,2,0,4], -"struct_g_p_i_o___l_e_d_type_def.html#a831923d4d157267ecc2f1add1c49adcf":[1,0,2,0,2,0,1], -"struct_g_p_i_o___l_e_d_type_def.html#abe9aadc0b28d042267f7155e187a1816":[1,0,2,0,2,0,3], -"struct_g_p_i_o___l_e_d_type_def.html#ad28d93023a00e3c5669bd3deda122435":[1,0,2,0,2,0,0], -"struct_g_p_i_o___switch_type_def.html":[1,0,2,0,1,0], -"struct_g_p_i_o___switch_type_def.html#a245f1dc811279ce5d4598582db979a89":[1,0,2,0,1,0,3], -"struct_g_p_i_o___switch_type_def.html#a2600e599a961af2e280c721894df4c06":[1,0,2,0,1,0,4], -"struct_g_p_i_o___switch_type_def.html#a4fadf5ead3ebccad521a52c064eeb405":[1,0,2,0,1,0,2], -"struct_g_p_i_o___switch_type_def.html#a63d58d9cba49a5823175585ef2996032":[1,0,2,0,1,0,1], -"struct_g_p_i_o___switch_type_def.html#afb369df75a6065fd89ac4ba97d98ab1a":[1,0,2,0,1,0,0], -"struct_h_f___stack_frame__t.html":[1,0,1,5,3,0], -"struct_h_f___stack_frame__t.html#a16563896004751c90e41c81ae4570732":[1,0,1,5,3,0,6], -"struct_h_f___stack_frame__t.html#a286104d19185714940645a9df814ddea":[1,0,1,5,3,0,1], -"struct_h_f___stack_frame__t.html#a4146ed28926b5f234132b7112119a413":[1,0,1,5,3,0,0], -"struct_h_f___stack_frame__t.html#a453c7af42b6928a693af422e17c981d3":[1,0,1,5,3,0,3], -"struct_h_f___stack_frame__t.html#a5a52e5006dabcf68c0fa4cfb0e03335b":[1,0,1,5,3,0,2], -"struct_h_f___stack_frame__t.html#a6e51904297f7725e96d5b5fb291ef577":[1,0,1,5,3,0,5], -"struct_h_f___stack_frame__t.html#a819ee3bc518c460ece1b7c4079f8f80b":[1,0,1,5,3,0,4], -"struct_h_f___stack_frame__t.html#ae47cb051ee3c94471bfd4fe7e49c55f9":[1,0,1,5,3,0,7], -"struct_r_t_t___flash_header__t.html":[1,0,1,5,2,0], -"struct_r_t_t___flash_header__t.html#a844ee5470a323a749856cbb7a682dc57":[1,0,1,5,2,0,0] +"struct_evolve_optimizer__t.html#a3be8c0c34db8429210ff470497a56727":[1,0,1,1,0,7] }; diff --git a/Doc/html/navtreeindex1.js b/Doc/html/navtreeindex1.js index d127260..c6bdd85 100644 --- a/Doc/html/navtreeindex1.js +++ b/Doc/html/navtreeindex1.js @@ -1,30 +1,79 @@ var NAVTREEINDEX1 = { +"struct_evolve_optimizer__t.html#a74b81df1c298c99162310f3f7d91735a":[1,0,1,1,0,10], +"struct_evolve_optimizer__t.html#a80eb0b8525b6bb838484f5922b9d8f7c":[1,0,1,1,0,0], +"struct_evolve_optimizer__t.html#a93f628397c2f8d4027f2906752b650df":[1,0,1,1,0,8], +"struct_evolve_optimizer__t.html#a950cd70cb6bff33b78ad35ee58c729a6":[1,0,1,1,0,3], +"struct_evolve_optimizer__t.html#ac35c7ca8cede4ab9c53a2845a91cd1b1":[1,0,1,1,0,2], +"struct_evolve_optimizer__t.html#ad0f464d7048a9ed0753b61f76f563108":[1,0,1,1,0,6], +"struct_evolve_optimizer__t.html#aec67667fd1f1533e693e41c79bc28da4":[1,0,1,1,0,9], +"struct_evolve_optimizer__t.html#af779c7aeba0053e36cee7aade160f1c8":[1,0,1,1,0,4], +"struct_g_p_i_o___l_e_d_type_def.html":[1,0,2,0,2,0], +"struct_g_p_i_o___l_e_d_type_def.html#a684ff60e4c94daf2221524cdc6fcc978":[1,0,2,0,2,0,2], +"struct_g_p_i_o___l_e_d_type_def.html#a6cc026931a4681732f9a329ae03098ec":[1,0,2,0,2,0,4], +"struct_g_p_i_o___l_e_d_type_def.html#a831923d4d157267ecc2f1add1c49adcf":[1,0,2,0,2,0,1], +"struct_g_p_i_o___l_e_d_type_def.html#abe9aadc0b28d042267f7155e187a1816":[1,0,2,0,2,0,3], +"struct_g_p_i_o___l_e_d_type_def.html#ad28d93023a00e3c5669bd3deda122435":[1,0,2,0,2,0,0], +"struct_g_p_i_o___switch_type_def.html":[1,0,2,0,1,0], +"struct_g_p_i_o___switch_type_def.html#a245f1dc811279ce5d4598582db979a89":[1,0,2,0,1,0,3], +"struct_g_p_i_o___switch_type_def.html#a2600e599a961af2e280c721894df4c06":[1,0,2,0,1,0,4], +"struct_g_p_i_o___switch_type_def.html#a4fadf5ead3ebccad521a52c064eeb405":[1,0,2,0,1,0,2], +"struct_g_p_i_o___switch_type_def.html#a63d58d9cba49a5823175585ef2996032":[1,0,2,0,1,0,1], +"struct_g_p_i_o___switch_type_def.html#afb369df75a6065fd89ac4ba97d98ab1a":[1,0,2,0,1,0,0], +"struct_h_f___stack_frame__t.html":[1,0,1,5,3,0], +"struct_h_f___stack_frame__t.html#a16563896004751c90e41c81ae4570732":[1,0,1,5,3,0,6], +"struct_h_f___stack_frame__t.html#a286104d19185714940645a9df814ddea":[1,0,1,5,3,0,1], +"struct_h_f___stack_frame__t.html#a4146ed28926b5f234132b7112119a413":[1,0,1,5,3,0,0], +"struct_h_f___stack_frame__t.html#a453c7af42b6928a693af422e17c981d3":[1,0,1,5,3,0,3], +"struct_h_f___stack_frame__t.html#a5a52e5006dabcf68c0fa4cfb0e03335b":[1,0,1,5,3,0,2], +"struct_h_f___stack_frame__t.html#a6e51904297f7725e96d5b5fb291ef577":[1,0,1,5,3,0,5], +"struct_h_f___stack_frame__t.html#a819ee3bc518c460ece1b7c4079f8f80b":[1,0,1,5,3,0,4], +"struct_h_f___stack_frame__t.html#ae47cb051ee3c94471bfd4fe7e49c55f9":[1,0,1,5,3,0,7], +"struct_r_t_t___flash_header__t.html":[1,0,1,5,2,0], +"struct_r_t_t___flash_header__t.html#a844ee5470a323a749856cbb7a682dc57":[1,0,1,5,2,0,0], "struct_r_t_t___flash_header__t.html#ae7276198385c8d6f6508f433d042d52a":[1,0,1,5,2,0,2], "struct_r_t_t___flash_header__t.html#afd1a5c51af6f97d170c2ccbbe3e34699":[1,0,1,5,2,0,1], -"struct_s_p_i___settings_type_def.html":[2,0,5], -"struct_t_i_m___encoder_type_def.html":[1,0,2,1,1,0], -"struct_t_i_m___encoder_type_def.html#a021f0c585e9e62d68a4b09f630d8b6e5":[1,0,2,1,1,0,3], -"struct_t_i_m___encoder_type_def.html#a0dacce3dde7df3122583869d96a372a2":[1,0,2,1,1,0,1], -"struct_t_i_m___encoder_type_def.html#a4fc05ef011205a6702cb3d006bab677e":[1,0,2,1,1,0,5], -"struct_t_i_m___encoder_type_def.html#a67ad037b92162546763fc9c425b5e3c5":[1,0,2,1,1,0,6], -"struct_t_i_m___encoder_type_def.html#a6973108a83d2a3ea4fc3e0e8a501af80":[1,0,2,1,1,0,7], -"struct_t_i_m___encoder_type_def.html#a6f769f027b760a4b496e2b2b77bf54a3":[1,0,2,1,1,0,0], -"struct_t_i_m___encoder_type_def.html#a99295760ff8b27d1e6f1710f29383a45":[1,0,2,1,1,0,8], -"struct_t_i_m___encoder_type_def.html#ad29873fc8cdc71462e6d8744621120e9":[1,0,2,1,1,0,4], -"struct_t_i_m___encoder_type_def.html#adc80bd5a90444c31d84157f35c59b95c":[1,0,2,1,1,0,2], -"struct_t_i_m___settings_type_def.html":[1,0,2,1,3,1], -"struct_t_i_m___settings_type_def.html#a11151fe125960cb8e61328ffd06b7718":[1,0,2,1,3,1,7], -"struct_t_i_m___settings_type_def.html#a2d9d277dd395424b964445ec1bc65b21":[1,0,2,1,3,1,3], -"struct_t_i_m___settings_type_def.html#a3805f627567798c3cd1d79a0da42bea0":[1,0,2,1,3,1,1], -"struct_t_i_m___settings_type_def.html#a58da1b4c0f6d12d7d9fb2f170b9b9e6e":[1,0,2,1,3,1,6], -"struct_t_i_m___settings_type_def.html#a7073358fd3a722687eb85238ab570014":[1,0,2,1,3,1,8], -"struct_t_i_m___settings_type_def.html#a961f19f0e1672715c27bc94d7871dbb7":[1,0,2,1,3,1,4], -"struct_t_i_m___settings_type_def.html#a9694cf0910a69d48ff94f8aeac106969":[1,0,2,1,3,1,2], -"struct_t_i_m___settings_type_def.html#ab90e370c3edda88e76583293c250d2b0":[1,0,2,1,3,1,5], -"struct_t_i_m___settings_type_def.html#ada49efdbd35a8e442c3cff630d42f34c":[1,0,2,1,3,1,0], -"struct_t_i_m___settings_type_def.html#af6057ff3f60f5e01b41d4a347b79a5e4":[1,0,2,1,3,1,9], -"struct_u_a_r_t___settings_type_def.html":[2,0,8], +"struct_s_p_i___settings_type_def.html":[1,0,2,1,1], +"struct_s_p_i___settings_type_def.html#a0af3bdb273818ff97eb4ff3cff918820":[1,0,2,1,1,7], +"struct_s_p_i___settings_type_def.html#a0d55a2941854f61934487f3d209cfa95":[1,0,2,1,1,4], +"struct_s_p_i___settings_type_def.html#a3366c654d7ec6dd41c6a0b504dc8509a":[1,0,2,1,1,5], +"struct_s_p_i___settings_type_def.html#a3bcb1ed12da3544e02e6d36493669bdc":[1,0,2,1,1,2], +"struct_s_p_i___settings_type_def.html#a3cfd9469b0617a68bbd2a161ba06bb95":[1,0,2,1,1,10], +"struct_s_p_i___settings_type_def.html#a3f3748103a0b7861f6700042fd691ba1":[1,0,2,1,1,3], +"struct_s_p_i___settings_type_def.html#a6a15d48eccf92959de3a086031fdc979":[1,0,2,1,1,1], +"struct_s_p_i___settings_type_def.html#a961208869faf4a7369aaf4edde75f176":[1,0,2,1,1,8], +"struct_s_p_i___settings_type_def.html#aa0edaa145076d2383b3e0095d156d474":[1,0,2,1,1,11], +"struct_s_p_i___settings_type_def.html#ad203d8b8d67e4f477d002d15b03ba422":[1,0,2,1,1,0], +"struct_s_p_i___settings_type_def.html#aecd7a5c6e205335b8ed229d74cd35d14":[1,0,2,1,1,6], +"struct_s_p_i___settings_type_def.html#afbe75a1c36650a4a9b41fa706a4c7eab":[1,0,2,1,1,9], +"struct_t_i_m___encoder_type_def.html":[1,0,2,2,3,0], +"struct_t_i_m___encoder_type_def.html#a021f0c585e9e62d68a4b09f630d8b6e5":[1,0,2,2,3,0,3], +"struct_t_i_m___encoder_type_def.html#a0dacce3dde7df3122583869d96a372a2":[1,0,2,2,3,0,1], +"struct_t_i_m___encoder_type_def.html#a4fc05ef011205a6702cb3d006bab677e":[1,0,2,2,3,0,5], +"struct_t_i_m___encoder_type_def.html#a67ad037b92162546763fc9c425b5e3c5":[1,0,2,2,3,0,6], +"struct_t_i_m___encoder_type_def.html#a6973108a83d2a3ea4fc3e0e8a501af80":[1,0,2,2,3,0,7], +"struct_t_i_m___encoder_type_def.html#a6f769f027b760a4b496e2b2b77bf54a3":[1,0,2,2,3,0,0], +"struct_t_i_m___encoder_type_def.html#a99295760ff8b27d1e6f1710f29383a45":[1,0,2,2,3,0,8], +"struct_t_i_m___encoder_type_def.html#ad29873fc8cdc71462e6d8744621120e9":[1,0,2,2,3,0,4], +"struct_t_i_m___encoder_type_def.html#adc80bd5a90444c31d84157f35c59b95c":[1,0,2,2,3,0,2], +"struct_t_i_m___settings_type_def.html":[1,0,2,2,0,1], +"struct_t_i_m___settings_type_def.html#a11151fe125960cb8e61328ffd06b7718":[1,0,2,2,0,1,7], +"struct_t_i_m___settings_type_def.html#a2d9d277dd395424b964445ec1bc65b21":[1,0,2,2,0,1,3], +"struct_t_i_m___settings_type_def.html#a3805f627567798c3cd1d79a0da42bea0":[1,0,2,2,0,1,1], +"struct_t_i_m___settings_type_def.html#a58da1b4c0f6d12d7d9fb2f170b9b9e6e":[1,0,2,2,0,1,6], +"struct_t_i_m___settings_type_def.html#a7073358fd3a722687eb85238ab570014":[1,0,2,2,0,1,8], +"struct_t_i_m___settings_type_def.html#a961f19f0e1672715c27bc94d7871dbb7":[1,0,2,2,0,1,4], +"struct_t_i_m___settings_type_def.html#a9694cf0910a69d48ff94f8aeac106969":[1,0,2,2,0,1,2], +"struct_t_i_m___settings_type_def.html#ab90e370c3edda88e76583293c250d2b0":[1,0,2,2,0,1,5], +"struct_t_i_m___settings_type_def.html#ada49efdbd35a8e442c3cff630d42f34c":[1,0,2,2,0,1,0], +"struct_t_i_m___settings_type_def.html#af6057ff3f60f5e01b41d4a347b79a5e4":[1,0,2,2,0,1,9], +"struct_u_a_r_t___settings_type_def.html":[1,0,2,3,1], +"struct_u_a_r_t___settings_type_def.html#a15ce92b03f7f189bfbe1ab88a5f94d19":[1,0,2,3,1,5], +"struct_u_a_r_t___settings_type_def.html#a1ecc9ac6a1d2747ade56770cbab6a613":[1,0,2,3,1,4], +"struct_u_a_r_t___settings_type_def.html#a3fba2b52788fe453348b5d92ed52ba49":[1,0,2,3,1,2], +"struct_u_a_r_t___settings_type_def.html#a5f1babfcfb436cd77f5614253c0a5bef":[1,0,2,3,1,3], +"struct_u_a_r_t___settings_type_def.html#accf2c9448a3ea8eb3b8c25a569276fea":[1,0,2,3,1,0], +"struct_u_a_r_t___settings_type_def.html#af6f9910d065bae715cdb4a1024143a8f":[1,0,2,3,1,1], "topics.html":[1], "trace_8h.html":[3,0,0,0,10], "trace_8h_source.html":[3,0,0,0,10], diff --git a/Doc/html/search/all_10.js b/Doc/html/search/all_10.js index 6183e1d..91de365 100644 --- a/Doc/html/search/all_10.js +++ b/Doc/html/search/all_10.js @@ -27,36 +27,32 @@ var searchData= ['tim_5ftickbase_5f10us_24',['TIM_TickBase_10US',['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a060b01e890891fd17c8f95b55a94139f',1,'general_tim.h']]], ['tim_5ftickbase_5f1ms_25',['TIM_TickBase_1MS',['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a6a66c5ed1d966c9e30f0219b664d2b25',1,'general_tim.h']]], ['tim_5ftickbase_5f1us_26',['TIM_TickBase_1US',['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ggaa0a51c870325217ac099881f09dd0800a63df3123d0ddc592b189ed1594456ea2',1,'general_tim.h']]], - ['tools_27',['tools',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html',1,'Delay tools'],['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html',1,'Encoder tools']]], - ['tools_28',['General Tools',['../group___m_y_l_i_b_s___d_e_f_i_n_e_s.html',1,'']]], - ['tools_29',['tools',['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html',1,'General tools'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html',1,'General tools']]], - ['tools_30',['GPIO Tools',['../group___m_y___l_i_b_s___g_p_i_o.html',1,'']]], - ['tools_31',['tools',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html',1,'LED tools'],['../group___m_y_l_i_b_s___t_i_m___o_c.html',1,'PWM/OC Channels tools'],['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html',1,'Switch tools']]], - ['tools_32',['TIM Tools',['../group___m_y___l_i_b_s___t_i_m.html',1,'']]], - ['trace_33',['Трассировка @ref TRACE',['../index.html#trace_module',1,'']]], - ['trace_20configs_34',['Trace configs',['../group___t_r_a_c_e___c_o_n_f_i_g.html',1,'']]], - ['trace_20defines_35',['trace defines',['../group___t_r_a_c_e___g_p_i_o.html',1,'GPIO trace defines'],['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'Hardfault trace defines'],['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'Serial trace defines']]], - ['trace_20defines_36',['Trace defines',['../group___t_r_a_c_e.html',1,'']]], - ['trace_2eh_37',['trace.h',['../trace_8h.html',1,'']]], - ['trace_5fgpio_5freset_38',['TRACE_GPIO_RESET',['../group___t_r_a_c_e___g_p_i_o.html#ga69741d88c991112e99fe7a62e025108a',1,'trace.h']]], - ['trace_5fgpio_5fset_39',['TRACE_GPIO_SET',['../group___t_r_a_c_e___g_p_i_o.html#ga02a6a7b273766121db8ad4a1371373eb',1,'trace.h']]], - ['trackerclear_5fall_40',['TrackerClear_All',['../group___t_r_a_c_k_e_r_s.html#ga704f7b9f8c65c9bcec48ce7cb77a2d3b',1,'trackers.h']]], - ['trackerclear_5ferr_41',['TrackerClear_Err',['../group___t_r_a_c_k_e_r_s.html#gae860b6947c6e317e14d40bd7b4b8eb74',1,'trackers.h']]], - ['trackerclear_5fok_42',['TrackerClear_Ok',['../group___t_r_a_c_k_e_r_s.html#ga5dd8bac8c7ab5832019d55d7a68371b9',1,'trackers.h']]], - ['trackerclear_5fuser_43',['TrackerClear_User',['../group___t_r_a_c_k_e_r_s.html#ga063dab1067005e1600ea32531fdf3f8d',1,'trackers.h']]], - ['trackerclear_5fuserall_44',['TrackerClear_UserAll',['../group___t_r_a_c_k_e_r_s.html#gaaec7ec19977bb26fa1919dfe920b82d5',1,'trackers.h']]], - ['trackerclear_5fwarn_45',['TrackerClear_Warn',['../group___t_r_a_c_k_e_r_s.html#ga365a8c60bd13b75154feda649dd21ead',1,'trackers.h']]], - ['trackercnt_5ferr_46',['TrackerCnt_Err',['../group___t_r_a_c_k_e_r_s.html#ga49af29ab3927cad105c1d2b018a767e9',1,'trackers.h']]], - ['trackercnt_5fok_47',['TrackerCnt_Ok',['../group___t_r_a_c_k_e_r_s.html#ga23de0006aa08984cfeddb6aa5e512fa1',1,'trackers.h']]], - ['trackercnt_5fuser_48',['TrackerCnt_User',['../group___t_r_a_c_k_e_r_s.html#ga1b7549afc4a1760b54a9b93b0f6d105e',1,'trackers.h']]], - ['trackercnt_5fwarn_49',['TrackerCnt_Warn',['../group___t_r_a_c_k_e_r_s.html#ga8017fb05a56a1b667244f1f786fa9c57',1,'trackers.h']]], - ['trackerget_5ferr_50',['TrackerGet_Err',['../group___t_r_a_c_k_e_r_s.html#ga9dc91e6b798a081f95f2ccef2c288e5e',1,'trackers.h']]], - ['trackerget_5fok_51',['TrackerGet_Ok',['../group___t_r_a_c_k_e_r_s.html#gab880911066605602a966641682090169',1,'trackers.h']]], - ['trackerget_5fuser_52',['TrackerGet_User',['../group___t_r_a_c_k_e_r_s.html#ga4b08632669043dfdbd219dda03502bdb',1,'trackers.h']]], - ['trackerget_5fwarn_53',['TrackerGet_Warn',['../group___t_r_a_c_k_e_r_s.html#ga47ac59a406ee74d4cd9fe0fbaf63a758',1,'trackers.h']]], - ['trackers_20defines_54',['Trackers defines',['../group___t_r_a_c_k_e_r_s.html',1,'']]], - ['trackers_2eh_55',['trackers.h',['../trackers_8h.html',1,'']]], - ['trackers_5fenable_56',['TRACKERS_ENABLE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gac9eaedc31ab023ce7d6403999216e496',1,'mylibs_config.h']]], - ['trackertypedef_57',['TrackerTypeDef',['../group___t_r_a_c_k_e_r_s.html#ga50ccb119acf302969b7fdcb58f2130e4',1,'trackers.h']]], - ['trackerwrite_5fuser_58',['TrackerWrite_User',['../group___t_r_a_c_k_e_r_s.html#gad2f4062a9ac8c2ab062a364f640ebc51',1,'trackers.h']]] + ['tools_27',['Tools',['../group___m_y_l_i_b_s___d_e_f_i_n_e_s.html',1,'General Tools'],['../group___m_y___l_i_b_s___g_p_i_o.html',1,'GPIO Tools'],['../group___m_y___l_i_b_s___s_p_i.html',1,'SPI Tools'],['../group___m_y___l_i_b_s___t_i_m.html',1,'TIM Tools'],['../group___m_y___l_i_b_s___u_a_r_t.html',1,'UART Tools']]], + ['tools_28',['tools',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html',1,'Delay tools'],['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html',1,'Encoder tools'],['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html',1,'General tools'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html',1,'General tools'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html',1,'LED tools'],['../group___m_y_l_i_b_s___t_i_m___o_c.html',1,'PWM/OC Channels tools'],['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html',1,'Switch tools']]], + ['trace_29',['Трассировка <a class="el" href="group___t_r_a_c_e.html">Trace defines</a>',['../index.html#trace_module',1,'']]], + ['trace_20configs_30',['Trace configs',['../group___t_r_a_c_e___c_o_n_f_i_g.html',1,'']]], + ['trace_20defines_31',['Trace defines',['../group___t_r_a_c_e.html',1,'']]], + ['trace_20defines_32',['trace defines',['../group___t_r_a_c_e___g_p_i_o.html',1,'GPIO trace defines'],['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'Hardfault trace defines'],['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'Serial trace defines']]], + ['trace_2eh_33',['trace.h',['../trace_8h.html',1,'']]], + ['trace_5fgpio_5freset_34',['TRACE_GPIO_RESET',['../group___t_r_a_c_e___g_p_i_o.html#ga69741d88c991112e99fe7a62e025108a',1,'trace.h']]], + ['trace_5fgpio_5fset_35',['TRACE_GPIO_SET',['../group___t_r_a_c_e___g_p_i_o.html#ga02a6a7b273766121db8ad4a1371373eb',1,'trace.h']]], + ['trackerclear_5fall_36',['TrackerClear_All',['../group___t_r_a_c_k_e_r_s.html#ga704f7b9f8c65c9bcec48ce7cb77a2d3b',1,'trackers.h']]], + ['trackerclear_5ferr_37',['TrackerClear_Err',['../group___t_r_a_c_k_e_r_s.html#gae860b6947c6e317e14d40bd7b4b8eb74',1,'trackers.h']]], + ['trackerclear_5fok_38',['TrackerClear_Ok',['../group___t_r_a_c_k_e_r_s.html#ga5dd8bac8c7ab5832019d55d7a68371b9',1,'trackers.h']]], + ['trackerclear_5fuser_39',['TrackerClear_User',['../group___t_r_a_c_k_e_r_s.html#ga063dab1067005e1600ea32531fdf3f8d',1,'trackers.h']]], + ['trackerclear_5fuserall_40',['TrackerClear_UserAll',['../group___t_r_a_c_k_e_r_s.html#gaaec7ec19977bb26fa1919dfe920b82d5',1,'trackers.h']]], + ['trackerclear_5fwarn_41',['TrackerClear_Warn',['../group___t_r_a_c_k_e_r_s.html#ga365a8c60bd13b75154feda649dd21ead',1,'trackers.h']]], + ['trackercnt_5ferr_42',['TrackerCnt_Err',['../group___t_r_a_c_k_e_r_s.html#ga49af29ab3927cad105c1d2b018a767e9',1,'trackers.h']]], + ['trackercnt_5fok_43',['TrackerCnt_Ok',['../group___t_r_a_c_k_e_r_s.html#ga23de0006aa08984cfeddb6aa5e512fa1',1,'trackers.h']]], + ['trackercnt_5fuser_44',['TrackerCnt_User',['../group___t_r_a_c_k_e_r_s.html#ga1b7549afc4a1760b54a9b93b0f6d105e',1,'trackers.h']]], + ['trackercnt_5fwarn_45',['TrackerCnt_Warn',['../group___t_r_a_c_k_e_r_s.html#ga8017fb05a56a1b667244f1f786fa9c57',1,'trackers.h']]], + ['trackerget_5ferr_46',['TrackerGet_Err',['../group___t_r_a_c_k_e_r_s.html#ga9dc91e6b798a081f95f2ccef2c288e5e',1,'trackers.h']]], + ['trackerget_5fok_47',['TrackerGet_Ok',['../group___t_r_a_c_k_e_r_s.html#gab880911066605602a966641682090169',1,'trackers.h']]], + ['trackerget_5fuser_48',['TrackerGet_User',['../group___t_r_a_c_k_e_r_s.html#ga4b08632669043dfdbd219dda03502bdb',1,'trackers.h']]], + ['trackerget_5fwarn_49',['TrackerGet_Warn',['../group___t_r_a_c_k_e_r_s.html#ga47ac59a406ee74d4cd9fe0fbaf63a758',1,'trackers.h']]], + ['trackers_20defines_50',['Trackers defines',['../group___t_r_a_c_k_e_r_s.html',1,'']]], + ['trackers_2eh_51',['trackers.h',['../trackers_8h.html',1,'']]], + ['trackers_5fenable_52',['TRACKERS_ENABLE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gac9eaedc31ab023ce7d6403999216e496',1,'mylibs_config.h']]], + ['trackertypedef_53',['TrackerTypeDef',['../group___t_r_a_c_k_e_r_s.html#ga50ccb119acf302969b7fdcb58f2130e4',1,'trackers.h']]], + ['trackerwrite_5fuser_54',['TrackerWrite_User',['../group___t_r_a_c_k_e_r_s.html#gad2f4062a9ac8c2ab062a364f640ebc51',1,'trackers.h']]] ]; diff --git a/Doc/html/search/all_11.js b/Doc/html/search/all_11.js index 4b375bc..e6fd0be 100644 --- a/Doc/html/search/all_11.js +++ b/Doc/html/search/all_11.js @@ -1,27 +1,44 @@ var searchData= [ - ['uart_5fsettingstypedef_0',['UART_SettingsTypeDef',['../struct_u_a_r_t___settings_type_def.html',1,'']]], - ['uint16_5fbit_1',['uint16_bit',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html#ga6a122b536ad99ae611c8cf01437af086',1,'bit_access.h']]], - ['uint16_5fbittypedef_2',['uint16_BitTypeDef',['../unionuint16___bit_type_def.html',1,'']]], - ['uint32_5fbit_3',['uint32_bit',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html#gafaa2080168b1b6f7281e8bfabab022d1',1,'bit_access.h']]], - ['uint32_5fbittypedef_4',['uint32_BitTypeDef',['../unionuint32___bit_type_def.html',1,'']]], - ['uint64_5fbit_5',['uint64_bit',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html#ga47eb69ce9330a1c73fe8031240f02f0a',1,'bit_access.h']]], - ['uint64_5fbittypedef_6',['uint64_BitTypeDef',['../unionuint64___bit_type_def.html',1,'']]], - ['uint8_5fbit_7',['uint8_bit',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html#ga57dc3bb3472a66fc92312f89d42d2396',1,'bit_access.h']]], - ['uint8_5fbittypedef_8',['uint8_BitTypeDef',['../unionuint8___bit_type_def.html',1,'']]], - ['use_5ftim1_9',['USE_TIM1',['../group___t_i_m___i_n_i_t.html#ga54a98c21365e0bc45b81555d2b101f2b',1,'general_tim.h']]], - ['use_5ftim10_10',['USE_TIM10',['../group___t_i_m___i_n_i_t.html#ga98c0691052d1da2c4053dd3586ff7ce9',1,'general_tim.h']]], - ['use_5ftim11_11',['USE_TIM11',['../group___t_i_m___i_n_i_t.html#ga176c97f06ebcf14e06e5c5bdbfac44c2',1,'general_tim.h']]], - ['use_5ftim12_12',['USE_TIM12',['../group___t_i_m___i_n_i_t.html#ga4e2b0e6cdf9eed74581b575c3fd9516b',1,'general_tim.h']]], - ['use_5ftim13_13',['USE_TIM13',['../group___t_i_m___i_n_i_t.html#gaf48ef87650517652ddec039a189507ac',1,'general_tim.h']]], - ['use_5ftim14_14',['USE_TIM14',['../group___t_i_m___i_n_i_t.html#ga9ae40be31d5271abe3e49f896d916d5c',1,'general_tim.h']]], - ['use_5ftim2_15',['USE_TIM2',['../group___t_i_m___i_n_i_t.html#ga72535a44955b43cbcd56e25039ab32eb',1,'general_tim.h']]], - ['use_5ftim3_16',['USE_TIM3',['../group___t_i_m___i_n_i_t.html#ga5b5685a43273b6e37242a4aba3ee0617',1,'general_tim.h']]], - ['use_5ftim4_17',['USE_TIM4',['../group___t_i_m___i_n_i_t.html#ga1493b39c9214501180b81b4c892f9be0',1,'general_tim.h']]], - ['use_5ftim5_18',['USE_TIM5',['../group___t_i_m___i_n_i_t.html#ga252f4fba93fc265110e83760e0590af3',1,'general_tim.h']]], - ['use_5ftim6_19',['USE_TIM6',['../group___t_i_m___i_n_i_t.html#ga8fe31b98160627d19038222910be3f46',1,'general_tim.h']]], - ['use_5ftim7_20',['USE_TIM7',['../group___t_i_m___i_n_i_t.html#ga7cdc54cc8cbbb6e9f60001f1e3e6ec67',1,'general_tim.h']]], - ['use_5ftim8_21',['USE_TIM8',['../group___t_i_m___i_n_i_t.html#ga28ba33d7c6bf22821dafa5bcee4854be',1,'general_tim.h']]], - ['use_5ftim9_22',['USE_TIM9',['../group___t_i_m___i_n_i_t.html#gaac627c0e98c9594cc41b1b46eb39e44a',1,'general_tim.h']]], - ['utils_20defines_23',['Utils defines',['../group___u_t_i_l_s___d_e_f_i_n_e_s.html',1,'']]] + ['uart_20my_5flibs_5fuart_0',['Модуль UART <a class="el" href="group___m_y___l_i_b_s___u_a_r_t.html">UART Tools</a>',['../index.html#uart_module',1,'']]], + ['uart_20tools_1',['UART Tools',['../group___m_y___l_i_b_s___u_a_r_t.html',1,'']]], + ['uart_5fbase_5finit_2',['UART_Base_Init',['../group___m_y___l_i_b_s___u_a_r_t.html#gab9f07396b778505c934143e89953e154',1,'UART_Base_Init(UART_SettingsTypeDef *suart): general_uart.c'],['../group___m_y___l_i_b_s___u_a_r_t.html#gab9f07396b778505c934143e89953e154',1,'UART_Base_Init(UART_SettingsTypeDef *suart): general_uart.c']]], + ['uart_5fcheck_5finit_5fstruct_3',['UART_Check_Init_Struct',['../group___m_y___l_i_b_s___u_a_r_t.html#ga2a22e46ecb9e04b2ce197a0e9c09044a',1,'UART_Check_Init_Struct(UART_SettingsTypeDef *suart): general_uart.c'],['../group___m_y___l_i_b_s___u_a_r_t.html#ga2a22e46ecb9e04b2ce197a0e9c09044a',1,'UART_Check_Init_Struct(UART_SettingsTypeDef *suart): general_uart.c']]], + ['uart_5fdma_5finit_4',['UART_DMA_Init',['../general__uart_8c.html#ad82d0cbd19151675135fd75dad315d05',1,'general_uart.c']]], + ['uart_5fgpio_5finit_5',['UART_GPIO_Init',['../general__uart_8c.html#a3abae05bbde5f3b402bf18ca13dc6a0b',1,'general_uart.c']]], + ['uart_5fmspdeinit_6',['UART_MspDeInit',['../group___m_y___l_i_b_s___u_a_r_t.html#ga93ed6ceef4e3b5e7885786125cce93bc',1,'UART_MspDeInit(UART_HandleTypeDef *huart): general_uart.c'],['../group___m_y___l_i_b_s___u_a_r_t.html#ga93ed6ceef4e3b5e7885786125cce93bc',1,'UART_MspDeInit(UART_HandleTypeDef *huart): general_uart.c']]], + ['uart_5fmspinit_7',['UART_MspInit',['../group___m_y___l_i_b_s___u_a_r_t.html#gab9313fd2f9fc6873ca6bfbc5b96edbbb',1,'UART_MspInit(UART_HandleTypeDef *huart): general_uart.c'],['../group___m_y___l_i_b_s___u_a_r_t.html#gab9313fd2f9fc6873ca6bfbc5b96edbbb',1,'UART_MspInit(UART_HandleTypeDef *huart): general_uart.c']]], + ['uart_5fsettingstypedef_8',['UART_SettingsTypeDef',['../struct_u_a_r_t___settings_type_def.html',1,'']]], + ['uint16_5fbit_9',['uint16_bit',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html#ga6a122b536ad99ae611c8cf01437af086',1,'bit_access.h']]], + ['uint16_5fbittypedef_10',['uint16_BitTypeDef',['../unionuint16___bit_type_def.html',1,'']]], + ['uint32_5fbit_11',['uint32_bit',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html#gafaa2080168b1b6f7281e8bfabab022d1',1,'bit_access.h']]], + ['uint32_5fbittypedef_12',['uint32_BitTypeDef',['../unionuint32___bit_type_def.html',1,'']]], + ['uint64_5fbit_13',['uint64_bit',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html#ga47eb69ce9330a1c73fe8031240f02f0a',1,'bit_access.h']]], + ['uint64_5fbittypedef_14',['uint64_BitTypeDef',['../unionuint64___bit_type_def.html',1,'']]], + ['uint8_5fbit_15',['uint8_bit',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html#ga57dc3bb3472a66fc92312f89d42d2396',1,'bit_access.h']]], + ['uint8_5fbittypedef_16',['uint8_BitTypeDef',['../unionuint8___bit_type_def.html',1,'']]], + ['use_5fspi1_17',['USE_SPI1',['../group___s_p_i___i_n_i_t.html#ga2fe0c8aeb2c61679f32836fef479eedf',1,'general_spi.h']]], + ['use_5fspi2_18',['USE_SPI2',['../group___s_p_i___i_n_i_t.html#ga53687cddb8e39e76a79b8ffaa152fb2b',1,'general_spi.h']]], + ['use_5fspi3_19',['USE_SPI3',['../group___s_p_i___i_n_i_t.html#ga5fdd6e5934a8005ef05b80f6d95883dc',1,'general_spi.h']]], + ['use_5ftim1_20',['USE_TIM1',['../group___t_i_m___i_n_i_t.html#ga54a98c21365e0bc45b81555d2b101f2b',1,'general_tim.h']]], + ['use_5ftim10_21',['USE_TIM10',['../group___t_i_m___i_n_i_t.html#ga98c0691052d1da2c4053dd3586ff7ce9',1,'general_tim.h']]], + ['use_5ftim11_22',['USE_TIM11',['../group___t_i_m___i_n_i_t.html#ga176c97f06ebcf14e06e5c5bdbfac44c2',1,'general_tim.h']]], + ['use_5ftim12_23',['USE_TIM12',['../group___t_i_m___i_n_i_t.html#ga4e2b0e6cdf9eed74581b575c3fd9516b',1,'general_tim.h']]], + ['use_5ftim13_24',['USE_TIM13',['../group___t_i_m___i_n_i_t.html#gaf48ef87650517652ddec039a189507ac',1,'general_tim.h']]], + ['use_5ftim14_25',['USE_TIM14',['../group___t_i_m___i_n_i_t.html#ga9ae40be31d5271abe3e49f896d916d5c',1,'general_tim.h']]], + ['use_5ftim2_26',['USE_TIM2',['../group___t_i_m___i_n_i_t.html#ga72535a44955b43cbcd56e25039ab32eb',1,'general_tim.h']]], + ['use_5ftim3_27',['USE_TIM3',['../group___t_i_m___i_n_i_t.html#ga5b5685a43273b6e37242a4aba3ee0617',1,'general_tim.h']]], + ['use_5ftim4_28',['USE_TIM4',['../group___t_i_m___i_n_i_t.html#ga1493b39c9214501180b81b4c892f9be0',1,'general_tim.h']]], + ['use_5ftim5_29',['USE_TIM5',['../group___t_i_m___i_n_i_t.html#ga252f4fba93fc265110e83760e0590af3',1,'general_tim.h']]], + ['use_5ftim6_30',['USE_TIM6',['../group___t_i_m___i_n_i_t.html#ga8fe31b98160627d19038222910be3f46',1,'general_tim.h']]], + ['use_5ftim7_31',['USE_TIM7',['../group___t_i_m___i_n_i_t.html#ga7cdc54cc8cbbb6e9f60001f1e3e6ec67',1,'general_tim.h']]], + ['use_5ftim8_32',['USE_TIM8',['../group___t_i_m___i_n_i_t.html#ga28ba33d7c6bf22821dafa5bcee4854be',1,'general_tim.h']]], + ['use_5ftim9_33',['USE_TIM9',['../group___t_i_m___i_n_i_t.html#gaac627c0e98c9594cc41b1b46eb39e44a',1,'general_tim.h']]], + ['use_5fuart4_34',['USE_UART4',['../group___u_a_r_t___i_n_i_t.html#ga779530e93e7aa1f25eb13045ec42b8e7',1,'general_uart.h']]], + ['use_5fuart5_35',['USE_UART5',['../group___u_a_r_t___i_n_i_t.html#ga592c6bf4a6496d6806ba0838cdfa2340',1,'general_uart.h']]], + ['use_5fusart1_36',['USE_USART1',['../group___u_a_r_t___i_n_i_t.html#gace54f148bb1d72f13bf397d096d38d1b',1,'general_uart.h']]], + ['use_5fusart2_37',['USE_USART2',['../group___u_a_r_t___i_n_i_t.html#gaacb3968508217a0d8b3f64aa0c8aa07d',1,'general_uart.h']]], + ['use_5fusart3_38',['USE_USART3',['../group___u_a_r_t___i_n_i_t.html#ga6dadd967b428aade24008ec060009976',1,'general_uart.h']]], + ['use_5fusart6_39',['USE_USART6',['../group___u_a_r_t___i_n_i_t.html#gafaeb8bdd4aa7fb1987505530daa90868',1,'general_uart.h']]], + ['utils_20defines_40',['Utils defines',['../group___u_t_i_l_s___d_e_f_i_n_e_s.html',1,'']]] ]; diff --git a/Doc/html/search/all_13.js b/Doc/html/search/all_13.js index 088670f..4f064c9 100644 --- a/Doc/html/search/all_13.js +++ b/Doc/html/search/all_13.js @@ -1,4 +1,4 @@ var searchData= [ - ['зависимости_0',['Зависимости',['../index.html#dependencies',1,'']]] + ['использование_0',['Использование',['../index.html#usage_basic',1,'']]] ]; diff --git a/Doc/html/search/all_14.js b/Doc/html/search/all_14.js index 4f064c9..09baad2 100644 --- a/Doc/html/search/all_14.js +++ b/Doc/html/search/all_14.js @@ -1,4 +1,7 @@ var searchData= [ - ['использование_0',['Использование',['../index.html#usage_basic',1,'']]] + ['модуль_20таймеров_20my_5flibs_5ftim_0',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]], + ['модуль_20gpio_20my_5flibs_5fgpio_1',['Модуль GPIO <a class="el" href="group___m_y___l_i_b_s___g_p_i_o.html">GPIO Tools</a>',['../index.html#gpio_module',1,'']]], + ['модуль_20spi_20my_5flibs_5fspi_2',['Модуль SPI <a class="el" href="group___m_y___l_i_b_s___s_p_i.html">SPI Tools</a>',['../index.html#spi_module',1,'']]], + ['модуль_20uart_20my_5flibs_5fuart_3',['Модуль UART <a class="el" href="group___m_y___l_i_b_s___u_a_r_t.html">UART Tools</a>',['../index.html#uart_module',1,'']]] ]; diff --git a/Doc/html/search/all_15.js b/Doc/html/search/all_15.js index 728d84a..ca20af9 100644 --- a/Doc/html/search/all_15.js +++ b/Doc/html/search/all_15.js @@ -1,5 +1,6 @@ var searchData= [ - ['модуль_20таймеров_20ref_20my_5flibs_5ftim_0',['Модуль таймеров @ref MY_LIBS_TIM',['../index.html#tim_module',1,'']]], - ['модуль_20gpio_20ref_20my_5flibs_5fgpio_1',['Модуль GPIO @ref MY_LIBS_GPIO',['../index.html#gpio_module',1,'']]] + ['обзор_0',['Обзор',['../index.html#overview',1,'']]], + ['общие_20утилиты_20mylibs_5fdefines_1',['Общие утилиты (<a class="el" href="group___m_y_l_i_b_s___d_e_f_i_n_e_s.html">General Tools</a>)',['../index.html#utils_module',1,'']]], + ['основные_20возможности_2',['Основные возможности',['../index.html#features',1,'']]] ]; diff --git a/Doc/html/search/all_16.js b/Doc/html/search/all_16.js index 08f8b9f..82a23b2 100644 --- a/Doc/html/search/all_16.js +++ b/Doc/html/search/all_16.js @@ -1,6 +1,4 @@ var searchData= [ - ['обзор_0',['Обзор',['../index.html#overview',1,'']]], - ['общие_20утилиты_20ref_20mylibs_5fdefines_1',['Общие утилиты (@ref MYLIBS_DEFINES)',['../index.html#utils_module',1,'']]], - ['основные_20возможности_2',['Основные возможности',['../index.html#features',1,'']]] + ['проекта_0',['Структура проекта',['../index.html#structure',1,'']]] ]; diff --git a/Doc/html/search/all_17.js b/Doc/html/search/all_17.js index 77c91f2..dd4f424 100644 --- a/Doc/html/search/all_17.js +++ b/Doc/html/search/all_17.js @@ -1,6 +1,4 @@ var searchData= [ - ['пример_20работы_20с_20таймером_0',['Пример работы с таймером',['../index.html#tim_example',1,'']]], - ['пример_20работы_20с_20gpio_1',['Пример работы с GPIO',['../index.html#gpio_example',1,'']]], - ['проекта_2',['Структура проекта',['../index.html#structure',1,'']]] + ['структура_20проекта_0',['Структура проекта',['../index.html#structure',1,'']]] ]; diff --git a/Doc/html/search/all_18.js b/Doc/html/search/all_18.js index e75b48e..25680da 100644 --- a/Doc/html/search/all_18.js +++ b/Doc/html/search/all_18.js @@ -1,5 +1,5 @@ var searchData= [ - ['работы_20с_20таймером_0',['Пример работы с таймером',['../index.html#tim_example',1,'']]], - ['работы_20с_20gpio_1',['Пример работы с GPIO',['../index.html#gpio_example',1,'']]] + ['трассировка_20trace_0',['Трассировка <a class="el" href="group___t_r_a_c_e.html">Trace defines</a>',['../index.html#trace_module',1,'']]], + ['таймеров_20my_5flibs_5ftim_1',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]] ]; diff --git a/Doc/html/search/all_19.js b/Doc/html/search/all_19.js index 77b7b10..f69cabe 100644 --- a/Doc/html/search/all_19.js +++ b/Doc/html/search/all_19.js @@ -1,6 +1,4 @@ var searchData= [ - ['структура_20проекта_0',['Структура проекта',['../index.html#structure',1,'']]], - ['с_20таймером_1',['Пример работы с таймером',['../index.html#tim_example',1,'']]], - ['с_20gpio_2',['Пример работы с GPIO',['../index.html#gpio_example',1,'']]] + ['утилиты_20mylibs_5fdefines_0',['Общие утилиты (<a class="el" href="group___m_y_l_i_b_s___d_e_f_i_n_e_s.html">General Tools</a>)',['../index.html#utils_module',1,'']]] ]; diff --git a/Doc/html/search/all_2.js b/Doc/html/search/all_2.js index 8fed4dd..0a30887 100644 --- a/Doc/html/search/all_2.js +++ b/Doc/html/search/all_2.js @@ -9,6 +9,9 @@ var searchData= ['check_5fnull_5fptr_5f4_6',['check_null_ptr_4',['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html#ga590973be111afc3f9ba15e6939530254',1,'mylibs_defs.h']]], ['check_5fnull_5fptr_5f5_7',['check_null_ptr_5',['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html#gaab0aafd7a4a21ec4f338b19269f65490',1,'mylibs_defs.h']]], ['clearstruct_8',['ClearStruct',['../group___u_t_i_l_s___d_e_f_i_n_e_s.html#gaf5e598848326d48e86167e5099a029be',1,'mylibs_defs.h']]], - ['configs_9',['Configs',['../group___m_y_l_i_b_s___c_o_n_f_i_g.html',1,'']]], - ['configs_10',['configs',['../group___e_v_o_l_v_e___c_o_n_f_i_g.html',1,'Evolve configs'],['../group___l_i_b_s___c_o_n_f_i_g.html',1,'Libraries configs'],['../group___t_r_a_c_e___c_o_n_f_i_g.html',1,'Trace configs']]] + ['clk_5fgpio_5falternagefunc_9',['CLK_GPIO_AlternageFunc',['../struct_s_p_i___settings_type_def.html#a3f3748103a0b7861f6700042fd691ba1',1,'SPI_SettingsTypeDef']]], + ['clk_5fgpiox_10',['CLK_GPIOx',['../struct_s_p_i___settings_type_def.html#a6a15d48eccf92959de3a086031fdc979',1,'SPI_SettingsTypeDef']]], + ['clk_5fpin_11',['CLK_PIN',['../struct_s_p_i___settings_type_def.html#a3bcb1ed12da3544e02e6d36493669bdc',1,'SPI_SettingsTypeDef']]], + ['configs_12',['Configs',['../group___m_y_l_i_b_s___c_o_n_f_i_g.html',1,'']]], + ['configs_13',['configs',['../group___e_v_o_l_v_e___c_o_n_f_i_g.html',1,'Evolve configs'],['../group___l_i_b_s___c_o_n_f_i_g.html',1,'Libraries configs'],['../group___t_r_a_c_e___c_o_n_f_i_g.html',1,'Trace configs']]] ]; diff --git a/Doc/html/search/all_3.js b/Doc/html/search/all_3.js index 80775d3..98ee53c 100644 --- a/Doc/html/search/all_3.js +++ b/Doc/html/search/all_3.js @@ -1,8 +1,10 @@ var searchData= [ ['data_0',['data',['../struct_r_t_t___flash_header__t.html#ae7276198385c8d6f6508f433d042d52a',1,'RTT_FlashHeader_t']]], - ['defines_1',['defines',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html',1,'Bit access defines'],['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html',1,'Delays defines'],['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html',1,'Error Handler defines'],['../group___t_r_a_c_e___g_p_i_o.html',1,'GPIO trace defines'],['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'Hardfault trace defines'],['../group___g_p_i_o___i_n_i_t.html',1,'Init defines'],['../group___t_i_m___i_n_i_t.html',1,'Init defines'],['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'Serial trace defines'],['../group___t_r_a_c_e.html',1,'Trace defines'],['../group___t_r_a_c_k_e_r_s.html',1,'Trackers defines'],['../group___u_t_i_l_s___d_e_f_i_n_e_s.html',1,'Utils defines']]], + ['defines_1',['defines',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html',1,'Bit access defines'],['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html',1,'Delays defines'],['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html',1,'Error Handler defines'],['../group___t_r_a_c_e___g_p_i_o.html',1,'GPIO trace defines'],['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'Hardfault trace defines'],['../group___g_p_i_o___i_n_i_t.html',1,'Init defines'],['../group___s_p_i___i_n_i_t.html',1,'Init defines'],['../group___t_i_m___i_n_i_t.html',1,'Init defines'],['../group___u_a_r_t___i_n_i_t.html',1,'Init defines'],['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'Serial trace defines'],['../group___t_r_a_c_e.html',1,'Trace defines'],['../group___t_r_a_c_k_e_r_s.html',1,'Trackers defines'],['../group___u_t_i_l_s___d_e_f_i_n_e_s.html',1,'Utils defines']]], ['delay_20tools_2',['Delay tools',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html',1,'']]], ['delays_20defines_3',['Delays defines',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html',1,'']]], - ['divide_5fup_4',['Divide_Up',['../group___u_t_i_l_s___d_e_f_i_n_e_s.html#gabf45f2b60eedf80cf9d1dbe4302a741e',1,'mylibs_defs.h']]] + ['divide_5fup_4',['Divide_Up',['../group___u_t_i_l_s___d_e_f_i_n_e_s.html#gabf45f2b60eedf80cf9d1dbe4302a741e',1,'mylibs_defs.h']]], + ['dma_5fchannel_5fx_5',['DMA_CHANNEL_X',['../struct_s_p_i___settings_type_def.html#aa0edaa145076d2383b3e0095d156d474',1,'SPI_SettingsTypeDef::DMA_CHANNEL_X'],['../struct_u_a_r_t___settings_type_def.html#a15ce92b03f7f189bfbe1ab88a5f94d19',1,'UART_SettingsTypeDef::DMA_CHANNEL_X']]], + ['dmachannel_6',['DMAChannel',['../struct_s_p_i___settings_type_def.html#a3cfd9469b0617a68bbd2a161ba06bb95',1,'SPI_SettingsTypeDef::DMAChannel'],['../struct_u_a_r_t___settings_type_def.html#a1ecc9ac6a1d2747ade56770cbab6a613',1,'UART_SettingsTypeDef::DMAChannel']]] ]; diff --git a/Doc/html/search/all_5.js b/Doc/html/search/all_5.js index dd7045f..612342f 100644 --- a/Doc/html/search/all_5.js +++ b/Doc/html/search/all_5.js @@ -1,4 +1,5 @@ var searchData= [ - ['flash_20rtt_20buffer_0',['Flash RTT Buffer',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html',1,'']]] + ['flash_20rtt_20buffer_0',['Flash RTT Buffer',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html',1,'']]], + ['freertos_5fdelay_1',['FREERTOS_DELAY',['../group___l_i_b_s___c_o_n_f_i_g.html#ga57c369737d5c0cfdb7baeecba0a4b151',1,'mylibs_config.h']]] ]; diff --git a/Doc/html/search/all_6.js b/Doc/html/search/all_6.js index ea28794..8d7f470 100644 --- a/Doc/html/search/all_6.js +++ b/Doc/html/search/all_6.js @@ -1,32 +1,38 @@ var searchData= [ - ['general_20tools_0',['General Tools',['../group___m_y_l_i_b_s___d_e_f_i_n_e_s.html',1,'']]], - ['general_20tools_1',['General tools',['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html',1,'General tools'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html',1,'General tools']]], - ['general_5fgpio_2ec_2',['general_gpio.c',['../general__gpio_8c.html',1,'']]], - ['general_5fgpio_2eh_3',['general_gpio.h',['../general__gpio_8h.html',1,'']]], - ['general_5ftim_2ec_4',['general_tim.c',['../general__tim_8c.html',1,'']]], - ['general_5ftim_2eh_5',['general_tim.h',['../general__tim_8h.html',1,'']]], - ['gpio_6',['Пример работы с GPIO',['../index.html#gpio_example',1,'']]], - ['gpio_20ref_20my_5flibs_5fgpio_7',['Модуль GPIO @ref MY_LIBS_GPIO',['../index.html#gpio_module',1,'']]], - ['gpio_20tools_8',['GPIO Tools',['../group___m_y___l_i_b_s___g_p_i_o.html',1,'']]], - ['gpio_20trace_20defines_9',['GPIO trace defines',['../group___t_r_a_c_e___g_p_i_o.html',1,'']]], - ['gpio_5fclock_5fenable_10',['GPIO_Clock_Enable',['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga962f010f783b81fcdd27eb6b53db28e6',1,'GPIO_Clock_Enable(GPIO_TypeDef *GPIOx): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga962f010f783b81fcdd27eb6b53db28e6',1,'GPIO_Clock_Enable(GPIO_TypeDef *GPIOx): general_gpio.c']]], - ['gpio_5fled_5fblink_5fstart_11',['GPIO_LED_Blink_Start',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaf22f44ecaf6a1932b47edc5a845b03a9',1,'GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaf22f44ecaf6a1932b47edc5a845b03a9',1,'GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period): general_gpio.c']]], - ['gpio_5fled_5fdynamic_5fhandle_12',['GPIO_LED_Dynamic_Handle',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gad6e6189824406c4d472b6340c7f19bb2',1,'GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gad6e6189824406c4d472b6340c7f19bb2',1,'GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led): general_gpio.c']]], - ['gpio_5fled_5ffading_5fstart_13',['GPIO_LED_Fading_Start',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaa00f20021781464af3dfe74aa3e59a0a',1,'GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaa00f20021781464af3dfe74aa3e59a0a',1,'GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period): general_gpio.c']]], - ['gpio_5fled_5finit_14',['GPIO_LED_Init',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gac936453c7a0841c0b17bcfdae4958084',1,'GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gac936453c7a0841c0b17bcfdae4958084',1,'GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_ActiveLevel): general_gpio.c']]], - ['gpio_5fled_5foff_15',['GPIO_LED_Off',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaadda2d4f021390a4e392210a5ace5357',1,'GPIO_LED_Off(GPIO_LEDTypeDef *led): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaadda2d4f021390a4e392210a5ace5357',1,'GPIO_LED_Off(GPIO_LEDTypeDef *led): general_gpio.c']]], - ['gpio_5fled_5fon_16',['GPIO_LED_On',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#ga4b9572949326b050694cd55d0a7e5f6c',1,'GPIO_LED_On(GPIO_LEDTypeDef *led): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#ga4b9572949326b050694cd55d0a7e5f6c',1,'GPIO_LED_On(GPIO_LEDTypeDef *led): general_gpio.c']]], - ['gpio_5fled_5fset_17',['GPIO_LED_Set',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gae78b570447d55a462a679a89dbaa8ea2',1,'GPIO_LED_Set(GPIO_LEDTypeDef *led, uint8_t led_state): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gae78b570447d55a462a679a89dbaa8ea2',1,'GPIO_LED_Set(GPIO_LEDTypeDef *led, uint8_t led_state): general_gpio.c']]], - ['gpio_5fledstatetypedef_18',['GPIO_LEDStateTypeDef',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaac2b90d8b8c9579b6aa5d3bbda9b1ff1',1,'general_gpio.h']]], - ['gpio_5fledtypedef_19',['GPIO_LEDTypeDef',['../struct_g_p_i_o___l_e_d_type_def.html',1,'']]], - ['gpio_5fpin_5fsw_20',['GPIO_PIN_SW',['../struct_t_i_m___encoder_type_def.html#a6973108a83d2a3ea4fc3e0e8a501af80',1,'TIM_EncoderTypeDef']]], - ['gpio_5fpin_5fti1_21',['GPIO_PIN_TI1',['../struct_t_i_m___encoder_type_def.html#a4fc05ef011205a6702cb3d006bab677e',1,'TIM_EncoderTypeDef']]], - ['gpio_5fpin_5fti2_22',['GPIO_PIN_TI2',['../struct_t_i_m___encoder_type_def.html#a67ad037b92162546763fc9c425b5e3c5',1,'TIM_EncoderTypeDef']]], - ['gpio_5fread_5fswitch_23',['GPIO_Read_Switch',['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#ga960b24335b2026abcad126ab8c422d70',1,'GPIO_Read_Switch(GPIO_SwitchTypeDef *swstart): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#ga960b24335b2026abcad126ab8c422d70',1,'GPIO_Read_Switch(GPIO_SwitchTypeDef *sw): general_gpio.c']]], - ['gpio_5fswitch_5finit_24',['GPIO_Switch_Init',['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#gacafee0e68877f2b25df843356871d1f7',1,'GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#gacafee0e68877f2b25df843356871d1f7',1,'GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_ActiveLevel): general_gpio.c']]], - ['gpio_5fswitchtypedef_25',['GPIO_SwitchTypeDef',['../struct_g_p_i_o___switch_type_def.html',1,'']]], - ['gpio_5ftim_5falternate_5fmapping_26',['GPIO_TIM_Alternate_Mapping',['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga580b842096340b066c28b24d6b315be6',1,'general_gpio.h']]], - ['gpio_5ftrace_5fenable_27',['GPIO_TRACE_ENABLE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga4222e0e400ad81737cefcabeb03fd23b',1,'mylibs_config.h']]], - ['gpiox_28',['GPIOx',['../struct_t_i_m___encoder_type_def.html#ad29873fc8cdc71462e6d8744621120e9',1,'TIM_EncoderTypeDef']]] + ['gen_5findex_0',['gen_index',['../struct_evolve_optimizer__t.html#ad0f464d7048a9ed0753b61f76f563108',1,'EvolveOptimizer_t']]], + ['gen_5fmut_1',['gen_mut',['../struct_evolve_optimizer__t.html#a3be8c0c34db8429210ff470497a56727',1,'EvolveOptimizer_t']]], + ['general_20tools_2',['General Tools',['../group___m_y_l_i_b_s___d_e_f_i_n_e_s.html',1,'']]], + ['general_20tools_3',['General tools',['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html',1,'General tools'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html',1,'General tools']]], + ['general_5fgpio_2ec_4',['general_gpio.c',['../general__gpio_8c.html',1,'']]], + ['general_5fgpio_2eh_5',['general_gpio.h',['../general__gpio_8h.html',1,'']]], + ['general_5fspi_2ec_6',['general_spi.c',['../general__spi_8c.html',1,'']]], + ['general_5fspi_2eh_7',['general_spi.h',['../general__spi_8h.html',1,'']]], + ['general_5ftim_2ec_8',['general_tim.c',['../general__tim_8c.html',1,'']]], + ['general_5ftim_2eh_9',['general_tim.h',['../general__tim_8h.html',1,'']]], + ['general_5fuart_2ec_10',['general_uart.c',['../general__uart_8c.html',1,'']]], + ['general_5fuart_2eh_11',['general_uart.h',['../general__uart_8h.html',1,'']]], + ['gpio_20my_5flibs_5fgpio_12',['Модуль GPIO <a class="el" href="group___m_y___l_i_b_s___g_p_i_o.html">GPIO Tools</a>',['../index.html#gpio_module',1,'']]], + ['gpio_20tools_13',['GPIO Tools',['../group___m_y___l_i_b_s___g_p_i_o.html',1,'']]], + ['gpio_20trace_20defines_14',['GPIO trace defines',['../group___t_r_a_c_e___g_p_i_o.html',1,'']]], + ['gpio_5fclock_5fenable_15',['GPIO_Clock_Enable',['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga962f010f783b81fcdd27eb6b53db28e6',1,'GPIO_Clock_Enable(GPIO_TypeDef *GPIOx): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html#ga962f010f783b81fcdd27eb6b53db28e6',1,'GPIO_Clock_Enable(GPIO_TypeDef *GPIOx): general_gpio.c']]], + ['gpio_5fled_5fblink_5fstart_16',['GPIO_LED_Blink_Start',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaf22f44ecaf6a1932b47edc5a845b03a9',1,'GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaf22f44ecaf6a1932b47edc5a845b03a9',1,'GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period): general_gpio.c']]], + ['gpio_5fled_5fdynamic_5fhandle_17',['GPIO_LED_Dynamic_Handle',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gad6e6189824406c4d472b6340c7f19bb2',1,'GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gad6e6189824406c4d472b6340c7f19bb2',1,'GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led): general_gpio.c']]], + ['gpio_5fled_5ffading_5fstart_18',['GPIO_LED_Fading_Start',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaa00f20021781464af3dfe74aa3e59a0a',1,'GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaa00f20021781464af3dfe74aa3e59a0a',1,'GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period): general_gpio.c']]], + ['gpio_5fled_5finit_19',['GPIO_LED_Init',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gac936453c7a0841c0b17bcfdae4958084',1,'GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gac936453c7a0841c0b17bcfdae4958084',1,'GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_ActiveLevel): general_gpio.c']]], + ['gpio_5fled_5foff_20',['GPIO_LED_Off',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaadda2d4f021390a4e392210a5ace5357',1,'GPIO_LED_Off(GPIO_LEDTypeDef *led): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaadda2d4f021390a4e392210a5ace5357',1,'GPIO_LED_Off(GPIO_LEDTypeDef *led): general_gpio.c']]], + ['gpio_5fled_5fon_21',['GPIO_LED_On',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#ga4b9572949326b050694cd55d0a7e5f6c',1,'GPIO_LED_On(GPIO_LEDTypeDef *led): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#ga4b9572949326b050694cd55d0a7e5f6c',1,'GPIO_LED_On(GPIO_LEDTypeDef *led): general_gpio.c']]], + ['gpio_5fled_5fset_22',['GPIO_LED_Set',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gae78b570447d55a462a679a89dbaa8ea2',1,'GPIO_LED_Set(GPIO_LEDTypeDef *led, uint8_t led_state): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gae78b570447d55a462a679a89dbaa8ea2',1,'GPIO_LED_Set(GPIO_LEDTypeDef *led, uint8_t led_state): general_gpio.c']]], + ['gpio_5fledstatetypedef_23',['GPIO_LEDStateTypeDef',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html#gaac2b90d8b8c9579b6aa5d3bbda9b1ff1',1,'general_gpio.h']]], + ['gpio_5fledtypedef_24',['GPIO_LEDTypeDef',['../struct_g_p_i_o___l_e_d_type_def.html',1,'']]], + ['gpio_5fpin_5frx_25',['GPIO_PIN_RX',['../struct_u_a_r_t___settings_type_def.html#a3fba2b52788fe453348b5d92ed52ba49',1,'UART_SettingsTypeDef']]], + ['gpio_5fpin_5fsw_26',['GPIO_PIN_SW',['../struct_t_i_m___encoder_type_def.html#a6973108a83d2a3ea4fc3e0e8a501af80',1,'TIM_EncoderTypeDef']]], + ['gpio_5fpin_5fti1_27',['GPIO_PIN_TI1',['../struct_t_i_m___encoder_type_def.html#a4fc05ef011205a6702cb3d006bab677e',1,'TIM_EncoderTypeDef']]], + ['gpio_5fpin_5fti2_28',['GPIO_PIN_TI2',['../struct_t_i_m___encoder_type_def.html#a67ad037b92162546763fc9c425b5e3c5',1,'TIM_EncoderTypeDef']]], + ['gpio_5fpin_5ftx_29',['GPIO_PIN_TX',['../struct_u_a_r_t___settings_type_def.html#a5f1babfcfb436cd77f5614253c0a5bef',1,'UART_SettingsTypeDef']]], + ['gpio_5fread_5fswitch_30',['GPIO_Read_Switch',['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#ga960b24335b2026abcad126ab8c422d70',1,'GPIO_Read_Switch(GPIO_SwitchTypeDef *swstart): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#ga960b24335b2026abcad126ab8c422d70',1,'GPIO_Read_Switch(GPIO_SwitchTypeDef *sw): general_gpio.c']]], + ['gpio_5fswitch_5finit_31',['GPIO_Switch_Init',['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#gacafee0e68877f2b25df843356871d1f7',1,'GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State): general_gpio.c'],['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html#gacafee0e68877f2b25df843356871d1f7',1,'GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_ActiveLevel): general_gpio.c']]], + ['gpio_5fswitchtypedef_32',['GPIO_SwitchTypeDef',['../struct_g_p_i_o___switch_type_def.html',1,'']]], + ['gpio_5ftrace_5fenable_33',['GPIO_TRACE_ENABLE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga4222e0e400ad81737cefcabeb03fd23b',1,'mylibs_config.h']]], + ['gpiox_34',['GPIOx',['../struct_t_i_m___encoder_type_def.html#ad29873fc8cdc71462e6d8744621120e9',1,'TIM_EncoderTypeDef::GPIOx'],['../struct_u_a_r_t___settings_type_def.html#af6f9910d065bae715cdb4a1024143a8f',1,'UART_SettingsTypeDef::GPIOx']]] ]; diff --git a/Doc/html/search/all_7.js b/Doc/html/search/all_7.js index a3dfba5..abe2462 100644 --- a/Doc/html/search/all_7.js +++ b/Doc/html/search/all_7.js @@ -1,15 +1,19 @@ var searchData= [ - ['handler_20defines_0',['Error Handler defines',['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html',1,'']]], - ['hardfault_20trace_20defines_1',['Hardfault trace defines',['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'']]], - ['hardfault_5fserial_5ftrace_2',['HARDFAULT_SERIAL_TRACE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga47f454f804b4dbc26cae079e8d8641e6',1,'mylibs_config.h']]], - ['hf_5fcheckrecovered_3',['HF_CheckRecovered',['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html#ga03f8b6f3b537ee1c8e91065c60db504f',1,'trace.h']]], - ['hf_5fflash_5faddr_4',['HF_FLASH_ADDR',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga0c602733a4a359bf8c095d71cd4d0f63',1,'mylibs_config.h']]], - ['hf_5fhandlefault_5',['HF_HandleFault',['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html#gadd8e10e7ec3b0204f7f92062ecd452f7',1,'trace.h']]], - ['hf_5fram_5fend_6',['HF_RAM_END',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga92d0d14732edb7dfa21d483304bdb051',1,'mylibs_config.h']]], - ['hf_5frtt_5ftag_5fbase_7',['HF_RTT_TAG_BASE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gadc960255719c7eff4bdfaa850be9b313',1,'mylibs_config.h']]], - ['hf_5frtt_5ftail_5fsize_8',['HF_RTT_TAIL_SIZE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gafcc7ea03d4df8f1909e580b519a7f3ca',1,'mylibs_config.h']]], - ['hf_5fstack_5fdump_5fwords_9',['HF_STACK_DUMP_WORDS',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gaa31234688b333a505aaa57b8ecdedf5b',1,'mylibs_config.h']]], - ['hf_5fstackframe_5ft_10',['HF_StackFrame_t',['../struct_h_f___stack_frame__t.html',1,'']]], - ['htim_11',['htim',['../struct_t_i_m___settings_type_def.html#ada49efdbd35a8e442c3cff630d42f34c',1,'TIM_SettingsTypeDef::htim'],['../struct_t_i_m___encoder_type_def.html#adc80bd5a90444c31d84157f35c59b95c',1,'TIM_EncoderTypeDef::htim']]] + ['hal_5fspi_5fmodule_5fenabled_0',['HAL_SPI_MODULE_ENABLED',['../group___s_p_i___i_n_i_t.html#ga8ad4712bf4add56892d057778e826e0c',1,'general_spi.h']]], + ['hal_5fuart_5fmodule_5fenabled_1',['HAL_UART_MODULE_ENABLED',['../group___u_a_r_t___i_n_i_t.html#ga167269406e73327b95c3bb7b9cfe6d89',1,'general_uart.h']]], + ['handler_20defines_2',['Error Handler defines',['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html',1,'']]], + ['hardfault_20trace_20defines_3',['Hardfault trace defines',['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'']]], + ['hardfault_5fserial_5ftrace_4',['HARDFAULT_SERIAL_TRACE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga47f454f804b4dbc26cae079e8d8641e6',1,'mylibs_config.h']]], + ['hf_5fcheckrecovered_5',['HF_CheckRecovered',['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html#ga03f8b6f3b537ee1c8e91065c60db504f',1,'trace.h']]], + ['hf_5fflash_5faddr_6',['HF_FLASH_ADDR',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga0c602733a4a359bf8c095d71cd4d0f63',1,'mylibs_config.h']]], + ['hf_5fhandlefault_7',['HF_HandleFault',['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html#gadd8e10e7ec3b0204f7f92062ecd452f7',1,'trace.h']]], + ['hf_5fram_5fend_8',['HF_RAM_END',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga92d0d14732edb7dfa21d483304bdb051',1,'mylibs_config.h']]], + ['hf_5frtt_5ftag_5fbase_9',['HF_RTT_TAG_BASE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gadc960255719c7eff4bdfaa850be9b313',1,'mylibs_config.h']]], + ['hf_5frtt_5ftail_5fsize_10',['HF_RTT_TAIL_SIZE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gafcc7ea03d4df8f1909e580b519a7f3ca',1,'mylibs_config.h']]], + ['hf_5fstack_5fdump_5fwords_11',['HF_STACK_DUMP_WORDS',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gaa31234688b333a505aaa57b8ecdedf5b',1,'mylibs_config.h']]], + ['hf_5fstackframe_5ft_12',['HF_StackFrame_t',['../struct_h_f___stack_frame__t.html',1,'']]], + ['hspi_13',['hspi',['../struct_s_p_i___settings_type_def.html#ad203d8b8d67e4f477d002d15b03ba422',1,'SPI_SettingsTypeDef']]], + ['htim_14',['htim',['../struct_t_i_m___settings_type_def.html#ada49efdbd35a8e442c3cff630d42f34c',1,'TIM_SettingsTypeDef::htim'],['../struct_t_i_m___encoder_type_def.html#adc80bd5a90444c31d84157f35c59b95c',1,'TIM_EncoderTypeDef::htim']]], + ['huart_15',['huart',['../struct_u_a_r_t___settings_type_def.html#accf2c9448a3ea8eb3b8c25a569276fea',1,'UART_SettingsTypeDef']]] ]; diff --git a/Doc/html/search/all_8.js b/Doc/html/search/all_8.js index 037d453..01381de 100644 --- a/Doc/html/search/all_8.js +++ b/Doc/html/search/all_8.js @@ -6,5 +6,5 @@ var searchData= ['include_5fgeneral_5fperiph_5flibs_3',['INCLUDE_GENERAL_PERIPH_LIBS',['../group___l_i_b_s___c_o_n_f_i_g.html#ga181a46326e46b60afb160190832c7281',1,'mylibs_config.h']]], ['include_5ftrace_5flib_4',['INCLUDE_TRACE_LIB',['../group___l_i_b_s___c_o_n_f_i_g.html#ga0a3ca94b616997069dd53e2c6c2687d7',1,'mylibs_config.h']]], ['include_5ftrackers_5flib_5',['INCLUDE_TRACKERS_LIB',['../group___l_i_b_s___c_o_n_f_i_g.html#ga4403055986b70bb02b8d37073a122e32',1,'mylibs_config.h']]], - ['init_20defines_6',['Init defines',['../group___g_p_i_o___i_n_i_t.html',1,'Init defines'],['../group___t_i_m___i_n_i_t.html',1,'Init defines']]] + ['init_20defines_6',['Init defines',['../group___g_p_i_o___i_n_i_t.html',1,'Init defines'],['../group___s_p_i___i_n_i_t.html',1,'Init defines'],['../group___t_i_m___i_n_i_t.html',1,'Init defines'],['../group___u_a_r_t___i_n_i_t.html',1,'Init defines']]] ]; diff --git a/Doc/html/search/all_9.js b/Doc/html/search/all_9.js index 89afd0d..498b83d 100644 --- a/Doc/html/search/all_9.js +++ b/Doc/html/search/all_9.js @@ -14,7 +14,7 @@ var searchData= ['led_5fpwm_5fticks_11',['LED_PWM_TICKS',['../group___g_p_i_o___i_n_i_t.html#ga1d42e219765ec526d99e306638ac0023',1,'general_gpio.h']]], ['libraries_20configs_12',['Libraries configs',['../group___l_i_b_s___c_o_n_f_i_g.html',1,'']]], ['libs_13',['My Libs',['../group___m_y_l_i_b_s___a_l_l.html',1,'']]], - ['local_5ftime_14',['local_time',['../group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.html#ga9c853b02c22f26023c34d1d404b6d653',1,'evolve_optimizer.h']]], + ['local_5ftime_14',['local_time',['../group___l_i_b_s___c_o_n_f_i_g.html#ga9c853b02c22f26023c34d1d404b6d653',1,'mylibs_config.h']]], ['log_5flevel_15',['LOG_LEVEL',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga0b87e0d3bf5853bcbb0b66a7c48fdc05',1,'mylibs_config.h']]], ['log_5fprintf_16',['log_printf',['../group___t_r_a_c_e___s_e_r_i_a_l.html#ga730fb7b8d0bbb348dca73c15bd0e0b26',1,'trace.h']]], ['loss_17',['loss',['../struct_evolve_optimizer__t.html#a93f628397c2f8d4027f2906752b650df',1,'EvolveOptimizer_t']]], diff --git a/Doc/html/search/all_a.js b/Doc/html/search/all_a.js index fedafe7..45e0ffa 100644 --- a/Doc/html/search/all_a.js +++ b/Doc/html/search/all_a.js @@ -1,18 +1,26 @@ var searchData= [ - ['msdelay_0',['msDelay',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html#gabeb97579daeb622c6651ed03c4a27479',1,'mylibs_defs.h']]], - ['msdelaystart_1',['msDelayStart',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html#ga8a5051b1292d1019fe8dd3fc5521ab25',1,'mylibs_defs.h']]], - ['msdelaywaitdone_2',['msDelayWaitDone',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html#gaed082c07b9fc4d1894330d885b9b5518',1,'mylibs_defs.h']]], - ['msdelaywhileactive_3',['msDelayWhileActive',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html#ga0b97e172659a59ee4fa56f851643ae85',1,'mylibs_defs.h']]], - ['mutation_5famp_4',['mutation_amp',['../struct_evolve_optimizer__t.html#af779c7aeba0053e36cee7aade160f1c8',1,'EvolveOptimizer_t']]], - ['my_20libs_5',['My Libs',['../group___m_y_l_i_b_s___a_l_l.html',1,'']]], - ['my_5flibs_5fgpio_6',['Модуль GPIO @ref MY_LIBS_GPIO',['../index.html#gpio_module',1,'']]], - ['my_5flibs_5ftim_7',['Модуль таймеров @ref MY_LIBS_TIM',['../index.html#tim_module',1,'']]], - ['my_5fprintf_8',['my_printf',['../group___t_r_a_c_e___s_e_r_i_a_l.html#gae9b9b8a611e291a2f2aa5abf99f3ebaa',1,'trace.h']]], - ['mylibs_9',['MyLibs',['../index.html',1,'']]], - ['mylibs_5fconfig_2eh_10',['mylibs_config.h',['../mylibs__config_8h.html',1,'']]], - ['mylibs_5fdefines_11',['Общие утилиты (@ref MYLIBS_DEFINES)',['../index.html#utils_module',1,'']]], - ['mylibs_5fdefs_2eh_12',['mylibs_defs.h',['../mylibs__defs_8h.html',1,'']]], - ['mylibs_5ferror_5fhandler_13',['MyLibs_Error_Handler',['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html#gae110df81afd885a390bbeb152d7b709f',1,'mylibs_defs.h']]], - ['mylibs_5finclude_2eh_14',['mylibs_include.h',['../mylibs__include_8h.html',1,'']]] + ['miso_5fgpio_5falternagefunc_0',['MISO_GPIO_AlternageFunc',['../struct_s_p_i___settings_type_def.html#aecd7a5c6e205335b8ed229d74cd35d14',1,'SPI_SettingsTypeDef']]], + ['miso_5fgpiox_1',['MISO_GPIOx',['../struct_s_p_i___settings_type_def.html#a0d55a2941854f61934487f3d209cfa95',1,'SPI_SettingsTypeDef']]], + ['miso_5fpin_2',['MISO_PIN',['../struct_s_p_i___settings_type_def.html#a3366c654d7ec6dd41c6a0b504dc8509a',1,'SPI_SettingsTypeDef']]], + ['mosi_5fgpio_5falternagefunc_3',['MOSI_GPIO_AlternageFunc',['../struct_s_p_i___settings_type_def.html#afbe75a1c36650a4a9b41fa706a4c7eab',1,'SPI_SettingsTypeDef']]], + ['mosi_5fgpiox_4',['MOSI_GPIOx',['../struct_s_p_i___settings_type_def.html#a0af3bdb273818ff97eb4ff3cff918820',1,'SPI_SettingsTypeDef']]], + ['mosi_5fpin_5',['MOSI_PIN',['../struct_s_p_i___settings_type_def.html#a961208869faf4a7369aaf4edde75f176',1,'SPI_SettingsTypeDef']]], + ['msdelay_6',['msDelay',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html#gabeb97579daeb622c6651ed03c4a27479',1,'mylibs_defs.h']]], + ['msdelaystart_7',['msDelayStart',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html#ga8a5051b1292d1019fe8dd3fc5521ab25',1,'mylibs_defs.h']]], + ['msdelaywaitdone_8',['msDelayWaitDone',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html#gaed082c07b9fc4d1894330d885b9b5518',1,'mylibs_defs.h']]], + ['msdelaywhileactive_9',['msDelayWhileActive',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html#ga0b97e172659a59ee4fa56f851643ae85',1,'mylibs_defs.h']]], + ['mutation_5famp_10',['mutation_amp',['../struct_evolve_optimizer__t.html#af779c7aeba0053e36cee7aade160f1c8',1,'EvolveOptimizer_t']]], + ['my_20libs_11',['My Libs',['../group___m_y_l_i_b_s___a_l_l.html',1,'']]], + ['my_5flibs_5fgpio_12',['Модуль GPIO <a class="el" href="group___m_y___l_i_b_s___g_p_i_o.html">GPIO Tools</a>',['../index.html#gpio_module',1,'']]], + ['my_5flibs_5fspi_13',['Модуль SPI <a class="el" href="group___m_y___l_i_b_s___s_p_i.html">SPI Tools</a>',['../index.html#spi_module',1,'']]], + ['my_5flibs_5ftim_14',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]], + ['my_5flibs_5fuart_15',['Модуль UART <a class="el" href="group___m_y___l_i_b_s___u_a_r_t.html">UART Tools</a>',['../index.html#uart_module',1,'']]], + ['my_5fprintf_16',['my_printf',['../group___t_r_a_c_e___s_e_r_i_a_l.html#gae9b9b8a611e291a2f2aa5abf99f3ebaa',1,'trace.h']]], + ['mylibs_17',['MyLibs',['../index.html',1,'']]], + ['mylibs_5fconfig_2eh_18',['mylibs_config.h',['../mylibs__config_8h.html',1,'']]], + ['mylibs_5fdefines_19',['Общие утилиты (<a class="el" href="group___m_y_l_i_b_s___d_e_f_i_n_e_s.html">General Tools</a>)',['../index.html#utils_module',1,'']]], + ['mylibs_5fdefs_2eh_20',['mylibs_defs.h',['../mylibs__defs_8h.html',1,'']]], + ['mylibs_5ferror_5fhandler_21',['MyLibs_Error_Handler',['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html#gae110df81afd885a390bbeb152d7b709f',1,'mylibs_defs.h']]], + ['mylibs_5finclude_2eh_22',['mylibs_include.h',['../mylibs__include_8h.html',1,'']]] ]; diff --git a/Doc/html/search/all_e.js b/Doc/html/search/all_e.js index 40ec221..95ce717 100644 --- a/Doc/html/search/all_e.js +++ b/Doc/html/search/all_e.js @@ -5,19 +5,15 @@ var searchData= ['r12_2',['r12',['../struct_h_f___stack_frame__t.html#a819ee3bc518c460ece1b7c4079f8f80b',1,'HF_StackFrame_t']]], ['r2_3',['r2',['../struct_h_f___stack_frame__t.html#a5a52e5006dabcf68c0fa4cfb0e03335b',1,'HF_StackFrame_t']]], ['r3_4',['r3',['../struct_h_f___stack_frame__t.html#a453c7af42b6928a693af422e17c981d3',1,'HF_StackFrame_t']]], - ['ref_20my_5flibs_5fgpio_5',['Модуль GPIO @ref MY_LIBS_GPIO',['../index.html#gpio_module',1,'']]], - ['ref_20my_5flibs_5ftim_6',['Модуль таймеров @ref MY_LIBS_TIM',['../index.html#tim_module',1,'']]], - ['ref_20mylibs_5fdefines_7',['Общие утилиты (@ref MYLIBS_DEFINES)',['../index.html#utils_module',1,'']]], - ['ref_20trace_8',['Трассировка @ref TRACE',['../index.html#trace_module',1,'']]], - ['rtt_20buffer_9',['Flash RTT Buffer',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html',1,'']]], - ['rtt_5feraseflash_10',['RTT_EraseFlash',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html#ga8d8c6850e32b42871faefce3352012d1',1,'trace.h']]], - ['rtt_5fflash_5fbuffer_5fsize_11',['RTT_FLASH_BUFFER_SIZE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga501312b24e322de4dd6755ad442f0ba3',1,'mylibs_config.h']]], - ['rtt_5fflash_5fsector_12',['RTT_FLASH_SECTOR',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga3bc1b76864e1d32cbdd174d4caae7724',1,'mylibs_config.h']]], - ['rtt_5fflash_5fsector_5fend_13',['RTT_FLASH_SECTOR_END',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gafeca0be3688dea07ff443f894668003d',1,'mylibs_config.h']]], - ['rtt_5fflash_5fsector_5fstart_14',['RTT_FLASH_SECTOR_START',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga8e56f75d3ab8a89ddde1404ae23c3297',1,'mylibs_config.h']]], - ['rtt_5fflashheader_5ft_15',['RTT_FlashHeader_t',['../struct_r_t_t___flash_header__t.html',1,'']]], - ['rtt_5fflashprepare_16',['RTT_FlashPrepare',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html#ga21353cb4f5af666237739e62ce019cd6',1,'trace.h']]], - ['rtt_5freadfromflash_17',['RTT_ReadFromFlash',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html#ga734b2ebbf0c77699b739013878cfd146',1,'trace.h']]], - ['rtt_5fsavetoflash_18',['RTT_SaveToFlash',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html#ga79f222c8ab644de4d47f07528d1edd63',1,'trace.h']]], - ['rtt_5ftrace_5fenable_19',['RTT_TRACE_ENABLE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga00ff2175bdc1fb11c8ec970ea3010dd8',1,'mylibs_config.h']]] + ['rtt_20buffer_5',['Flash RTT Buffer',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html',1,'']]], + ['rtt_5feraseflash_6',['RTT_EraseFlash',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html#ga8d8c6850e32b42871faefce3352012d1',1,'trace.h']]], + ['rtt_5fflash_5fbuffer_5fsize_7',['RTT_FLASH_BUFFER_SIZE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga501312b24e322de4dd6755ad442f0ba3',1,'mylibs_config.h']]], + ['rtt_5fflash_5fsector_8',['RTT_FLASH_SECTOR',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga3bc1b76864e1d32cbdd174d4caae7724',1,'mylibs_config.h']]], + ['rtt_5fflash_5fsector_5fend_9',['RTT_FLASH_SECTOR_END',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gafeca0be3688dea07ff443f894668003d',1,'mylibs_config.h']]], + ['rtt_5fflash_5fsector_5fstart_10',['RTT_FLASH_SECTOR_START',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga8e56f75d3ab8a89ddde1404ae23c3297',1,'mylibs_config.h']]], + ['rtt_5fflashheader_5ft_11',['RTT_FlashHeader_t',['../struct_r_t_t___flash_header__t.html',1,'']]], + ['rtt_5fflashprepare_12',['RTT_FlashPrepare',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html#ga21353cb4f5af666237739e62ce019cd6',1,'trace.h']]], + ['rtt_5freadfromflash_13',['RTT_ReadFromFlash',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html#ga734b2ebbf0c77699b739013878cfd146',1,'trace.h']]], + ['rtt_5fsavetoflash_14',['RTT_SaveToFlash',['../group___t_r_a_c_e___r_t_t___f_l_a_s_h.html#ga79f222c8ab644de4d47f07528d1edd63',1,'trace.h']]], + ['rtt_5ftrace_5fenable_15',['RTT_TRACE_ENABLE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#ga00ff2175bdc1fb11c8ec970ea3010dd8',1,'mylibs_config.h']]] ]; diff --git a/Doc/html/search/all_f.js b/Doc/html/search/all_f.js index 6527aed..103d4c4 100644 --- a/Doc/html/search/all_f.js +++ b/Doc/html/search/all_f.js @@ -8,23 +8,30 @@ var searchData= ['size_5',['size',['../struct_r_t_t___flash_header__t.html#afd1a5c51af6f97d170c2ccbbe3e34699',1,'RTT_FlashHeader_t']]], ['smasterconfig_6',['sMasterConfig',['../struct_t_i_m___settings_type_def.html#a2d9d277dd395424b964445ec1bc65b21',1,'TIM_SettingsTypeDef']]], ['sorted_5fidx_7',['sorted_idx',['../struct_evolve_optimizer__t.html#a74b81df1c298c99162310f3f7d91735a',1,'EvolveOptimizer_t']]], - ['spi_5fsettingstypedef_8',['SPI_SettingsTypeDef',['../struct_s_p_i___settings_type_def.html',1,'']]], - ['sslaveconfig_9',['sSlaveConfig',['../struct_t_i_m___settings_type_def.html#a9694cf0910a69d48ff94f8aeac106969',1,'TIM_SettingsTypeDef']]], - ['stability_10',['stability',['../struct_evolve_optimizer__t.html#a80eb0b8525b6bb838484f5922b9d8f7c',1,'EvolveOptimizer_t']]], - ['state_11',['state',['../struct_g_p_i_o___l_e_d_type_def.html#ad28d93023a00e3c5669bd3deda122435',1,'GPIO_LEDTypeDef']]], - ['stickbaseprescaler_12',['sTickBasePrescaler',['../struct_t_i_m___settings_type_def.html#a11151fe125960cb8e61328ffd06b7718',1,'TIM_SettingsTypeDef']]], - ['stickbaseus_13',['sTickBaseUS',['../struct_t_i_m___settings_type_def.html#a58da1b4c0f6d12d7d9fb2f170b9b9e6e',1,'TIM_SettingsTypeDef']]], - ['stimahbfreqmhz_14',['sTimAHBFreqMHz',['../struct_t_i_m___settings_type_def.html#a7073358fd3a722687eb85238ab570014',1,'TIM_SettingsTypeDef']]], - ['stimfreqhz_15',['sTimFreqHz',['../struct_t_i_m___settings_type_def.html#af6057ff3f60f5e01b41d4a347b79a5e4',1,'TIM_SettingsTypeDef']]], - ['stimmode_16',['sTimMode',['../struct_t_i_m___settings_type_def.html#ab90e370c3edda88e76583293c250d2b0',1,'TIM_SettingsTypeDef']]], - ['sw_17',['Sw',['../struct_t_i_m___encoder_type_def.html#a99295760ff8b27d1e6f1710f29383a45',1,'TIM_EncoderTypeDef']]], - ['sw_5factivelvl_18',['Sw_ActiveLvl',['../struct_g_p_i_o___switch_type_def.html#a4fadf5ead3ebccad521a52c064eeb405',1,'GPIO_SwitchTypeDef']]], - ['sw_5ffilterdelay_19',['Sw_FilterDelay',['../struct_g_p_i_o___switch_type_def.html#a2600e599a961af2e280c721894df4c06',1,'GPIO_SwitchTypeDef']]], - ['sw_5foff_20',['SW_OFF',['../group___g_p_i_o___i_n_i_t.html#gacd8900c9ec0efde1da3253b718574067',1,'general_gpio.h']]], - ['sw_5fon_21',['SW_ON',['../group___g_p_i_o___i_n_i_t.html#ga19d9e3aced311179a2914e0c9b13d0f9',1,'general_gpio.h']]], - ['sw_5fpin_22',['Sw_Pin',['../struct_g_p_i_o___switch_type_def.html#a63d58d9cba49a5823175585ef2996032',1,'GPIO_SwitchTypeDef']]], - ['sw_5fport_23',['Sw_Port',['../struct_g_p_i_o___switch_type_def.html#afb369df75a6065fd89ac4ba97d98ab1a',1,'GPIO_SwitchTypeDef']]], - ['sw_5fprevstate_24',['Sw_PrevState',['../struct_g_p_i_o___switch_type_def.html#a245f1dc811279ce5d4598582db979a89',1,'GPIO_SwitchTypeDef']]], - ['switch_20tools_25',['Switch tools',['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html',1,'']]], - ['swo_5ftrace_5fenable_26',['SWO_TRACE_ENABLE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gab8db9704b5d11858aa879689b9d36336',1,'mylibs_config.h']]] + ['spi_20my_5flibs_5fspi_8',['Модуль SPI <a class="el" href="group___m_y___l_i_b_s___s_p_i.html">SPI Tools</a>',['../index.html#spi_module',1,'']]], + ['spi_20tools_9',['SPI Tools',['../group___m_y___l_i_b_s___s_p_i.html',1,'']]], + ['spi_5fbase_5finit_10',['SPI_Base_Init',['../group___m_y___l_i_b_s___s_p_i.html#ga0e177e3c57a8fcdc73b5602e72ec66ba',1,'SPI_Base_Init(SPI_SettingsTypeDef *sspi): general_spi.c'],['../group___m_y___l_i_b_s___s_p_i.html#ga0e177e3c57a8fcdc73b5602e72ec66ba',1,'SPI_Base_Init(SPI_SettingsTypeDef *sspi): general_spi.c']]], + ['spi_5fcheck_5finit_5fstruct_11',['SPI_Check_Init_Struct',['../group___m_y___l_i_b_s___s_p_i.html#ga333dd251bc878931086d48aa932b1a5f',1,'SPI_Check_Init_Struct(SPI_SettingsTypeDef *sspi): general_spi.c'],['../group___m_y___l_i_b_s___s_p_i.html#ga333dd251bc878931086d48aa932b1a5f',1,'SPI_Check_Init_Struct(SPI_SettingsTypeDef *sspi): general_spi.c']]], + ['spi_5fgpio_5finit_12',['SPI_GPIO_Init',['../general__spi_8c.html#ae80d21e5cab86571709a2619442733b5',1,'general_spi.c']]], + ['spi_5fmspdeinit_13',['SPI_MspDeInit',['../group___m_y___l_i_b_s___s_p_i.html#gac279cc3eaa35541edfe330a1844a85e4',1,'SPI_MspDeInit(SPI_HandleTypeDef *hspi): general_spi.c'],['../group___m_y___l_i_b_s___s_p_i.html#gac279cc3eaa35541edfe330a1844a85e4',1,'SPI_MspDeInit(SPI_HandleTypeDef *hspi): general_spi.c']]], + ['spi_5fmspinit_14',['SPI_MspInit',['../group___m_y___l_i_b_s___s_p_i.html#gab9f13318daf02bc5b5f302ae392dccac',1,'SPI_MspInit(SPI_HandleTypeDef *hspi): general_spi.c'],['../group___m_y___l_i_b_s___s_p_i.html#gab9f13318daf02bc5b5f302ae392dccac',1,'SPI_MspInit(SPI_HandleTypeDef *hspi): general_spi.c']]], + ['spi_5fsettingstypedef_15',['SPI_SettingsTypeDef',['../struct_s_p_i___settings_type_def.html',1,'']]], + ['sslaveconfig_16',['sSlaveConfig',['../struct_t_i_m___settings_type_def.html#a9694cf0910a69d48ff94f8aeac106969',1,'TIM_SettingsTypeDef']]], + ['stability_17',['stability',['../struct_evolve_optimizer__t.html#a80eb0b8525b6bb838484f5922b9d8f7c',1,'EvolveOptimizer_t']]], + ['state_18',['state',['../struct_g_p_i_o___l_e_d_type_def.html#ad28d93023a00e3c5669bd3deda122435',1,'GPIO_LEDTypeDef']]], + ['stickbaseprescaler_19',['sTickBasePrescaler',['../struct_t_i_m___settings_type_def.html#a11151fe125960cb8e61328ffd06b7718',1,'TIM_SettingsTypeDef']]], + ['stickbaseus_20',['sTickBaseUS',['../struct_t_i_m___settings_type_def.html#a58da1b4c0f6d12d7d9fb2f170b9b9e6e',1,'TIM_SettingsTypeDef']]], + ['stimahbfreqmhz_21',['sTimAHBFreqMHz',['../struct_t_i_m___settings_type_def.html#a7073358fd3a722687eb85238ab570014',1,'TIM_SettingsTypeDef']]], + ['stimfreqhz_22',['sTimFreqHz',['../struct_t_i_m___settings_type_def.html#af6057ff3f60f5e01b41d4a347b79a5e4',1,'TIM_SettingsTypeDef']]], + ['stimmode_23',['sTimMode',['../struct_t_i_m___settings_type_def.html#ab90e370c3edda88e76583293c250d2b0',1,'TIM_SettingsTypeDef']]], + ['sw_24',['Sw',['../struct_t_i_m___encoder_type_def.html#a99295760ff8b27d1e6f1710f29383a45',1,'TIM_EncoderTypeDef']]], + ['sw_5factivelvl_25',['Sw_ActiveLvl',['../struct_g_p_i_o___switch_type_def.html#a4fadf5ead3ebccad521a52c064eeb405',1,'GPIO_SwitchTypeDef']]], + ['sw_5ffilterdelay_26',['Sw_FilterDelay',['../struct_g_p_i_o___switch_type_def.html#a2600e599a961af2e280c721894df4c06',1,'GPIO_SwitchTypeDef']]], + ['sw_5foff_27',['SW_OFF',['../group___g_p_i_o___i_n_i_t.html#gacd8900c9ec0efde1da3253b718574067',1,'general_gpio.h']]], + ['sw_5fon_28',['SW_ON',['../group___g_p_i_o___i_n_i_t.html#ga19d9e3aced311179a2914e0c9b13d0f9',1,'general_gpio.h']]], + ['sw_5fpin_29',['Sw_Pin',['../struct_g_p_i_o___switch_type_def.html#a63d58d9cba49a5823175585ef2996032',1,'GPIO_SwitchTypeDef']]], + ['sw_5fport_30',['Sw_Port',['../struct_g_p_i_o___switch_type_def.html#afb369df75a6065fd89ac4ba97d98ab1a',1,'GPIO_SwitchTypeDef']]], + ['sw_5fprevstate_31',['Sw_PrevState',['../struct_g_p_i_o___switch_type_def.html#a245f1dc811279ce5d4598582db979a89',1,'GPIO_SwitchTypeDef']]], + ['switch_20tools_32',['Switch tools',['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html',1,'']]], + ['swo_5ftrace_5fenable_33',['SWO_TRACE_ENABLE',['../group___t_r_a_c_e___c_o_n_f_i_g.html#gab8db9704b5d11858aa879689b9d36336',1,'mylibs_config.h']]] ]; diff --git a/Doc/html/search/files_2.js b/Doc/html/search/files_2.js index 30872e3..045601b 100644 --- a/Doc/html/search/files_2.js +++ b/Doc/html/search/files_2.js @@ -2,6 +2,10 @@ var searchData= [ ['general_5fgpio_2ec_0',['general_gpio.c',['../general__gpio_8c.html',1,'']]], ['general_5fgpio_2eh_1',['general_gpio.h',['../general__gpio_8h.html',1,'']]], - ['general_5ftim_2ec_2',['general_tim.c',['../general__tim_8c.html',1,'']]], - ['general_5ftim_2eh_3',['general_tim.h',['../general__tim_8h.html',1,'']]] + ['general_5fspi_2ec_2',['general_spi.c',['../general__spi_8c.html',1,'']]], + ['general_5fspi_2eh_3',['general_spi.h',['../general__spi_8h.html',1,'']]], + ['general_5ftim_2ec_4',['general_tim.c',['../general__tim_8c.html',1,'']]], + ['general_5ftim_2eh_5',['general_tim.h',['../general__tim_8h.html',1,'']]], + ['general_5fuart_2ec_6',['general_uart.c',['../general__uart_8c.html',1,'']]], + ['general_5fuart_2eh_7',['general_uart.h',['../general__uart_8h.html',1,'']]] ]; diff --git a/Doc/html/search/functions_4.js b/Doc/html/search/functions_4.js index d14df27..63ad634 100644 --- a/Doc/html/search/functions_4.js +++ b/Doc/html/search/functions_4.js @@ -1,14 +1,8 @@ var searchData= [ - ['tim_5fbase_5finit_0',['TIM_Base_Init',['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga7044214f24a9868ba7e1650b55e639ec',1,'TIM_Base_Init(TIM_SettingsTypeDef *stim): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga7044214f24a9868ba7e1650b55e639ec',1,'TIM_Base_Init(TIM_SettingsTypeDef *stim): general_tim.c']]], - ['tim_5fbase_5fmspdeinit_1',['TIM_Base_MspDeInit',['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga879e3f1c919c02990736730275367115',1,'TIM_Base_MspDeInit(TIM_HandleTypeDef *htim): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#ga879e3f1c919c02990736730275367115',1,'TIM_Base_MspDeInit(TIM_HandleTypeDef *htim): general_tim.c']]], - ['tim_5fbase_5fmspinit_2',['TIM_Base_MspInit',['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaad47337be7ba2f6c0777c40d7278c931',1,'TIM_Base_MspInit(TIM_HandleTypeDef *htim, TIM_ITModeTypeDef it_mode): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html#gaad47337be7ba2f6c0777c40d7278c931',1,'TIM_Base_MspInit(TIM_HandleTypeDef *htim, TIM_ITModeTypeDef it_mode): general_tim.c']]], - ['tim_5fdelay_3',['TIM_Delay',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga88c552a133cb6e3015453cccab74c07e',1,'TIM_Delay(TIM_HandleTypeDef *htim, uint16_t delay): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga88c552a133cb6e3015453cccab74c07e',1,'TIM_Delay(TIM_HandleTypeDef *htim, uint16_t delay): general_tim.c']]], - ['tim_5fdelay_5fnonblocking_4',['TIM_Delay_NonBlocking',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga108637af414bff3373059273b815ce9b',1,'TIM_Delay_NonBlocking(TIM_HandleTypeDef *htim, uint16_t delay): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga108637af414bff3373059273b815ce9b',1,'TIM_Delay_NonBlocking(TIM_HandleTypeDef *htim, uint16_t delay): general_tim.c']]], - ['tim_5fdelay_5fstart_5',['TIM_Delay_Start',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga4c0dfde4e15f677600605348b4e97834',1,'TIM_Delay_Start(TIM_HandleTypeDef *htim): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html#ga4c0dfde4e15f677600605348b4e97834',1,'TIM_Delay_Start(TIM_HandleTypeDef *htim): general_tim.c']]], - ['tim_5fencoder_5finit_6',['TIM_Encoder_Init',['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc',1,'TIM_Encoder_Init(TIM_EncoderTypeDef *henc1, TIM_HandleTypeDef *htim): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc',1,'TIM_Encoder_Init(TIM_EncoderTypeDef *henc, TIM_HandleTypeDef *htim): general_tim.c']]], - ['tim_5fencoder_5fread_7',['TIM_Encoder_Read',['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#gac3bc6525f88c275e47eb864e6d567501',1,'TIM_Encoder_Read(TIM_EncoderTypeDef *henc): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#gac3bc6525f88c275e47eb864e6d567501',1,'TIM_Encoder_Read(TIM_EncoderTypeDef *henc): general_tim.c']]], - ['tim_5fencoder_5freadswitch_8',['TIM_Encoder_ReadSwitch',['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga117b795017e9e3a357ddefe323412761',1,'TIM_Encoder_ReadSwitch(TIM_EncoderTypeDef *henc): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html#ga117b795017e9e3a357ddefe323412761',1,'TIM_Encoder_ReadSwitch(TIM_EncoderTypeDef *henc): general_tim.c']]], - ['tim_5foc_5fcomparator_5finit_9',['TIM_OC_Comparator_Init',['../group___m_y_l_i_b_s___t_i_m___o_c.html#gae2608ca8023e9a0713af0b4fbfbc1889',1,'TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___o_c.html#gae2608ca8023e9a0713af0b4fbfbc1889',1,'TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL): general_tim.c']]], - ['tim_5foutput_5fpwm_5finit_10',['TIM_Output_PWM_Init',['../group___m_y_l_i_b_s___t_i_m___o_c.html#gadb2f465d89f609e035867e980c3a29c6',1,'TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN): general_tim.c'],['../group___m_y_l_i_b_s___t_i_m___o_c.html#gadb2f465d89f609e035867e980c3a29c6',1,'TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN): general_tim.c']]] + ['spi_5fbase_5finit_0',['SPI_Base_Init',['../group___m_y___l_i_b_s___s_p_i.html#ga0e177e3c57a8fcdc73b5602e72ec66ba',1,'SPI_Base_Init(SPI_SettingsTypeDef *sspi): general_spi.c'],['../group___m_y___l_i_b_s___s_p_i.html#ga0e177e3c57a8fcdc73b5602e72ec66ba',1,'SPI_Base_Init(SPI_SettingsTypeDef *sspi): general_spi.c']]], + ['spi_5fcheck_5finit_5fstruct_1',['SPI_Check_Init_Struct',['../group___m_y___l_i_b_s___s_p_i.html#ga333dd251bc878931086d48aa932b1a5f',1,'SPI_Check_Init_Struct(SPI_SettingsTypeDef *sspi): general_spi.c'],['../group___m_y___l_i_b_s___s_p_i.html#ga333dd251bc878931086d48aa932b1a5f',1,'SPI_Check_Init_Struct(SPI_SettingsTypeDef *sspi): general_spi.c']]], + ['spi_5fgpio_5finit_2',['SPI_GPIO_Init',['../general__spi_8c.html#ae80d21e5cab86571709a2619442733b5',1,'general_spi.c']]], + ['spi_5fmspdeinit_3',['SPI_MspDeInit',['../group___m_y___l_i_b_s___s_p_i.html#gac279cc3eaa35541edfe330a1844a85e4',1,'SPI_MspDeInit(SPI_HandleTypeDef *hspi): general_spi.c'],['../group___m_y___l_i_b_s___s_p_i.html#gac279cc3eaa35541edfe330a1844a85e4',1,'SPI_MspDeInit(SPI_HandleTypeDef *hspi): general_spi.c']]], + ['spi_5fmspinit_4',['SPI_MspInit',['../group___m_y___l_i_b_s___s_p_i.html#gab9f13318daf02bc5b5f302ae392dccac',1,'SPI_MspInit(SPI_HandleTypeDef *hspi): general_spi.c'],['../group___m_y___l_i_b_s___s_p_i.html#gab9f13318daf02bc5b5f302ae392dccac',1,'SPI_MspInit(SPI_HandleTypeDef *hspi): general_spi.c']]] ]; diff --git a/Doc/html/search/groups_10.js b/Doc/html/search/groups_10.js index a12cb46..461f68c 100644 --- a/Doc/html/search/groups_10.js +++ b/Doc/html/search/groups_10.js @@ -1,4 +1,5 @@ var searchData= [ - ['utils_20defines_0',['Utils defines',['../group___u_t_i_l_s___d_e_f_i_n_e_s.html',1,'']]] + ['uart_20tools_0',['UART Tools',['../group___m_y___l_i_b_s___u_a_r_t.html',1,'']]], + ['utils_20defines_1',['Utils defines',['../group___u_t_i_l_s___d_e_f_i_n_e_s.html',1,'']]] ]; diff --git a/Doc/html/search/groups_3.js b/Doc/html/search/groups_3.js index dadffcf..6a7d179 100644 --- a/Doc/html/search/groups_3.js +++ b/Doc/html/search/groups_3.js @@ -1,6 +1,6 @@ var searchData= [ - ['defines_0',['defines',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html',1,'Bit access defines'],['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html',1,'Delays defines'],['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html',1,'Error Handler defines'],['../group___t_r_a_c_e___g_p_i_o.html',1,'GPIO trace defines'],['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'Hardfault trace defines'],['../group___g_p_i_o___i_n_i_t.html',1,'Init defines'],['../group___t_i_m___i_n_i_t.html',1,'Init defines'],['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'Serial trace defines'],['../group___t_r_a_c_e.html',1,'Trace defines'],['../group___t_r_a_c_k_e_r_s.html',1,'Trackers defines'],['../group___u_t_i_l_s___d_e_f_i_n_e_s.html',1,'Utils defines']]], + ['defines_0',['defines',['../group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.html',1,'Bit access defines'],['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html',1,'Delays defines'],['../group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.html',1,'Error Handler defines'],['../group___t_r_a_c_e___g_p_i_o.html',1,'GPIO trace defines'],['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'Hardfault trace defines'],['../group___g_p_i_o___i_n_i_t.html',1,'Init defines'],['../group___s_p_i___i_n_i_t.html',1,'Init defines'],['../group___t_i_m___i_n_i_t.html',1,'Init defines'],['../group___u_a_r_t___i_n_i_t.html',1,'Init defines'],['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'Serial trace defines'],['../group___t_r_a_c_e.html',1,'Trace defines'],['../group___t_r_a_c_k_e_r_s.html',1,'Trackers defines'],['../group___u_t_i_l_s___d_e_f_i_n_e_s.html',1,'Utils defines']]], ['delay_20tools_1',['Delay tools',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html',1,'']]], ['delays_20defines_2',['Delays defines',['../group___d_e_l_a_y_s___d_e_f_i_n_e_s.html',1,'']]] ]; diff --git a/Doc/html/search/groups_8.js b/Doc/html/search/groups_8.js index 1023257..8230248 100644 --- a/Doc/html/search/groups_8.js +++ b/Doc/html/search/groups_8.js @@ -1,4 +1,4 @@ var searchData= [ - ['init_20defines_0',['Init defines',['../group___g_p_i_o___i_n_i_t.html',1,'Init defines'],['../group___t_i_m___i_n_i_t.html',1,'Init defines']]] + ['init_20defines_0',['Init defines',['../group___g_p_i_o___i_n_i_t.html',1,'Init defines'],['../group___s_p_i___i_n_i_t.html',1,'Init defines'],['../group___t_i_m___i_n_i_t.html',1,'Init defines'],['../group___u_a_r_t___i_n_i_t.html',1,'Init defines']]] ]; diff --git a/Doc/html/search/groups_e.js b/Doc/html/search/groups_e.js index 29e65af..4b963a4 100644 --- a/Doc/html/search/groups_e.js +++ b/Doc/html/search/groups_e.js @@ -1,5 +1,6 @@ var searchData= [ ['serial_20trace_20defines_0',['Serial trace defines',['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'']]], - ['switch_20tools_1',['Switch tools',['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html',1,'']]] + ['spi_20tools_1',['SPI Tools',['../group___m_y___l_i_b_s___s_p_i.html',1,'']]], + ['switch_20tools_2',['Switch tools',['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html',1,'']]] ]; diff --git a/Doc/html/search/groups_f.js b/Doc/html/search/groups_f.js index 0861945..0864006 100644 --- a/Doc/html/search/groups_f.js +++ b/Doc/html/search/groups_f.js @@ -1,14 +1,10 @@ var searchData= [ ['tim_20tools_0',['TIM Tools',['../group___m_y___l_i_b_s___t_i_m.html',1,'']]], - ['tools_1',['tools',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html',1,'Delay tools'],['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html',1,'Encoder tools']]], - ['tools_2',['General Tools',['../group___m_y_l_i_b_s___d_e_f_i_n_e_s.html',1,'']]], - ['tools_3',['tools',['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html',1,'General tools'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html',1,'General tools']]], - ['tools_4',['GPIO Tools',['../group___m_y___l_i_b_s___g_p_i_o.html',1,'']]], - ['tools_5',['tools',['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html',1,'LED tools'],['../group___m_y_l_i_b_s___t_i_m___o_c.html',1,'PWM/OC Channels tools'],['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html',1,'Switch tools']]], - ['tools_6',['TIM Tools',['../group___m_y___l_i_b_s___t_i_m.html',1,'']]], - ['trace_20configs_7',['Trace configs',['../group___t_r_a_c_e___c_o_n_f_i_g.html',1,'']]], - ['trace_20defines_8',['trace defines',['../group___t_r_a_c_e___g_p_i_o.html',1,'GPIO trace defines'],['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'Hardfault trace defines'],['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'Serial trace defines']]], - ['trace_20defines_9',['Trace defines',['../group___t_r_a_c_e.html',1,'']]], - ['trackers_20defines_10',['Trackers defines',['../group___t_r_a_c_k_e_r_s.html',1,'']]] + ['tools_1',['Tools',['../group___m_y_l_i_b_s___d_e_f_i_n_e_s.html',1,'General Tools'],['../group___m_y___l_i_b_s___g_p_i_o.html',1,'GPIO Tools'],['../group___m_y___l_i_b_s___s_p_i.html',1,'SPI Tools'],['../group___m_y___l_i_b_s___t_i_m.html',1,'TIM Tools'],['../group___m_y___l_i_b_s___u_a_r_t.html',1,'UART Tools']]], + ['tools_2',['tools',['../group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.html',1,'Delay tools'],['../group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.html',1,'Encoder tools'],['../group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.html',1,'General tools'],['../group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.html',1,'General tools'],['../group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.html',1,'LED tools'],['../group___m_y_l_i_b_s___t_i_m___o_c.html',1,'PWM/OC Channels tools'],['../group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.html',1,'Switch tools']]], + ['trace_20configs_3',['Trace configs',['../group___t_r_a_c_e___c_o_n_f_i_g.html',1,'']]], + ['trace_20defines_4',['Trace defines',['../group___t_r_a_c_e.html',1,'']]], + ['trace_20defines_5',['trace defines',['../group___t_r_a_c_e___g_p_i_o.html',1,'GPIO trace defines'],['../group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.html',1,'Hardfault trace defines'],['../group___t_r_a_c_e___s_e_r_i_a_l.html',1,'Serial trace defines']]], + ['trackers_20defines_6',['Trackers defines',['../group___t_r_a_c_k_e_r_s.html',1,'']]] ]; diff --git a/Doc/html/search/pages_0.js b/Doc/html/search/pages_0.js index 2e8c2c6..04631a1 100644 --- a/Doc/html/search/pages_0.js +++ b/Doc/html/search/pages_0.js @@ -1,4 +1,4 @@ var searchData= [ - ['mylibs_0',['MyLibs',['../index.html',1,'']]] + ['gpio_20my_5flibs_5fgpio_0',['Модуль GPIO <a class="el" href="group___m_y___l_i_b_s___g_p_i_o.html">GPIO Tools</a>',['../index.html#gpio_module',1,'']]] ]; diff --git a/Doc/html/search/pages_1.js b/Doc/html/search/pages_1.js index c604c22..c38a7d1 100644 --- a/Doc/html/search/pages_1.js +++ b/Doc/html/search/pages_1.js @@ -1,7 +1,9 @@ var searchData= [ ['my_5flibs_5fgpio_0',['Модуль GPIO <a class="el" href="group___m_y___l_i_b_s___g_p_i_o.html">GPIO Tools</a>',['../index.html#gpio_module',1,'']]], - ['my_5flibs_5ftim_1',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]], - ['mylibs_2',['MyLibs',['../index.html',1,'']]], - ['mylibs_5fdefines_3',['Общие утилиты (<a class="el" href="group___m_y_l_i_b_s___d_e_f_i_n_e_s.html">General Tools</a>)',['../index.html#utils_module',1,'']]] + ['my_5flibs_5fspi_1',['Модуль SPI <a class="el" href="group___m_y___l_i_b_s___s_p_i.html">SPI Tools</a>',['../index.html#spi_module',1,'']]], + ['my_5flibs_5ftim_2',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]], + ['my_5flibs_5fuart_3',['Модуль UART <a class="el" href="group___m_y___l_i_b_s___u_a_r_t.html">UART Tools</a>',['../index.html#uart_module',1,'']]], + ['mylibs_4',['MyLibs',['../index.html',1,'']]], + ['mylibs_5fdefines_5',['Общие утилиты (<a class="el" href="group___m_y_l_i_b_s___d_e_f_i_n_e_s.html">General Tools</a>)',['../index.html#utils_module',1,'']]] ]; diff --git a/Doc/html/search/pages_2.js b/Doc/html/search/pages_2.js index 8cbc609..6fc01ef 100644 --- a/Doc/html/search/pages_2.js +++ b/Doc/html/search/pages_2.js @@ -1,4 +1,4 @@ var searchData= [ - ['trace_0',['Трассировка <a class="el" href="group___t_r_a_c_e.html">Trace defines</a>',['../index.html#trace_module',1,'']]] + ['spi_20my_5flibs_5fspi_0',['Модуль SPI <a class="el" href="group___m_y___l_i_b_s___s_p_i.html">SPI Tools</a>',['../index.html#spi_module',1,'']]] ]; diff --git a/Doc/html/search/pages_3.js b/Doc/html/search/pages_3.js index 205b15e..8cbc609 100644 --- a/Doc/html/search/pages_3.js +++ b/Doc/html/search/pages_3.js @@ -1,4 +1,4 @@ var searchData= [ - ['возможности_0',['Основные возможности',['../index.html#features',1,'']]] + ['trace_0',['Трассировка <a class="el" href="group___t_r_a_c_e.html">Trace defines</a>',['../index.html#trace_module',1,'']]] ]; diff --git a/Doc/html/search/pages_4.js b/Doc/html/search/pages_4.js index 088670f..ba35ec5 100644 --- a/Doc/html/search/pages_4.js +++ b/Doc/html/search/pages_4.js @@ -1,4 +1,4 @@ var searchData= [ - ['зависимости_0',['Зависимости',['../index.html#dependencies',1,'']]] + ['uart_20my_5flibs_5fuart_0',['Модуль UART <a class="el" href="group___m_y___l_i_b_s___u_a_r_t.html">UART Tools</a>',['../index.html#uart_module',1,'']]] ]; diff --git a/Doc/html/search/pages_5.js b/Doc/html/search/pages_5.js index 4f064c9..205b15e 100644 --- a/Doc/html/search/pages_5.js +++ b/Doc/html/search/pages_5.js @@ -1,4 +1,4 @@ var searchData= [ - ['использование_0',['Использование',['../index.html#usage_basic',1,'']]] + ['возможности_0',['Основные возможности',['../index.html#features',1,'']]] ]; diff --git a/Doc/html/search/pages_6.js b/Doc/html/search/pages_6.js index 5143fc3..4f064c9 100644 --- a/Doc/html/search/pages_6.js +++ b/Doc/html/search/pages_6.js @@ -1,5 +1,4 @@ var searchData= [ - ['модуль_20таймеров_20my_5flibs_5ftim_0',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]], - ['модуль_20gpio_20my_5flibs_5fgpio_1',['Модуль GPIO <a class="el" href="group___m_y___l_i_b_s___g_p_i_o.html">GPIO Tools</a>',['../index.html#gpio_module',1,'']]] + ['использование_0',['Использование',['../index.html#usage_basic',1,'']]] ]; diff --git a/Doc/html/search/pages_7.js b/Doc/html/search/pages_7.js index ca20af9..09baad2 100644 --- a/Doc/html/search/pages_7.js +++ b/Doc/html/search/pages_7.js @@ -1,6 +1,7 @@ var searchData= [ - ['обзор_0',['Обзор',['../index.html#overview',1,'']]], - ['общие_20утилиты_20mylibs_5fdefines_1',['Общие утилиты (<a class="el" href="group___m_y_l_i_b_s___d_e_f_i_n_e_s.html">General Tools</a>)',['../index.html#utils_module',1,'']]], - ['основные_20возможности_2',['Основные возможности',['../index.html#features',1,'']]] + ['модуль_20таймеров_20my_5flibs_5ftim_0',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]], + ['модуль_20gpio_20my_5flibs_5fgpio_1',['Модуль GPIO <a class="el" href="group___m_y___l_i_b_s___g_p_i_o.html">GPIO Tools</a>',['../index.html#gpio_module',1,'']]], + ['модуль_20spi_20my_5flibs_5fspi_2',['Модуль SPI <a class="el" href="group___m_y___l_i_b_s___s_p_i.html">SPI Tools</a>',['../index.html#spi_module',1,'']]], + ['модуль_20uart_20my_5flibs_5fuart_3',['Модуль UART <a class="el" href="group___m_y___l_i_b_s___u_a_r_t.html">UART Tools</a>',['../index.html#uart_module',1,'']]] ]; diff --git a/Doc/html/search/pages_8.js b/Doc/html/search/pages_8.js index 77c91f2..ca20af9 100644 --- a/Doc/html/search/pages_8.js +++ b/Doc/html/search/pages_8.js @@ -1,6 +1,6 @@ var searchData= [ - ['пример_20работы_20с_20таймером_0',['Пример работы с таймером',['../index.html#tim_example',1,'']]], - ['пример_20работы_20с_20gpio_1',['Пример работы с GPIO',['../index.html#gpio_example',1,'']]], - ['проекта_2',['Структура проекта',['../index.html#structure',1,'']]] + ['обзор_0',['Обзор',['../index.html#overview',1,'']]], + ['общие_20утилиты_20mylibs_5fdefines_1',['Общие утилиты (<a class="el" href="group___m_y_l_i_b_s___d_e_f_i_n_e_s.html">General Tools</a>)',['../index.html#utils_module',1,'']]], + ['основные_20возможности_2',['Основные возможности',['../index.html#features',1,'']]] ]; diff --git a/Doc/html/search/pages_9.js b/Doc/html/search/pages_9.js index e75b48e..82a23b2 100644 --- a/Doc/html/search/pages_9.js +++ b/Doc/html/search/pages_9.js @@ -1,5 +1,4 @@ var searchData= [ - ['работы_20с_20таймером_0',['Пример работы с таймером',['../index.html#tim_example',1,'']]], - ['работы_20с_20gpio_1',['Пример работы с GPIO',['../index.html#gpio_example',1,'']]] + ['проекта_0',['Структура проекта',['../index.html#structure',1,'']]] ]; diff --git a/Doc/html/search/pages_a.js b/Doc/html/search/pages_a.js index 77b7b10..dd4f424 100644 --- a/Doc/html/search/pages_a.js +++ b/Doc/html/search/pages_a.js @@ -1,6 +1,4 @@ var searchData= [ - ['структура_20проекта_0',['Структура проекта',['../index.html#structure',1,'']]], - ['с_20таймером_1',['Пример работы с таймером',['../index.html#tim_example',1,'']]], - ['с_20gpio_2',['Пример работы с GPIO',['../index.html#gpio_example',1,'']]] + ['структура_20проекта_0',['Структура проекта',['../index.html#structure',1,'']]] ]; diff --git a/Doc/html/search/pages_b.js b/Doc/html/search/pages_b.js index 22224e1..25680da 100644 --- a/Doc/html/search/pages_b.js +++ b/Doc/html/search/pages_b.js @@ -1,6 +1,5 @@ var searchData= [ ['трассировка_20trace_0',['Трассировка <a class="el" href="group___t_r_a_c_e.html">Trace defines</a>',['../index.html#trace_module',1,'']]], - ['таймеров_20my_5flibs_5ftim_1',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]], - ['таймером_2',['Пример работы с таймером',['../index.html#tim_example',1,'']]] + ['таймеров_20my_5flibs_5ftim_1',['Модуль таймеров <a class="el" href="group___m_y___l_i_b_s___t_i_m.html">TIM Tools</a>',['../index.html#tim_module',1,'']]] ]; diff --git a/Doc/html/search/search.css b/Doc/html/search/search.css index 19f76f9..956f31f 100644 --- a/Doc/html/search/search.css +++ b/Doc/html/search/search.css @@ -5,8 +5,8 @@ display: flex; justify-content: center; align-items: center; - height: 36px; - margin-right: 1em; + height: 43px; + margin-right: 0; } /*---------------- Search box styling */ @@ -27,43 +27,23 @@ dark-mode-toggle { white-space : nowrap; background: var(--search-background-color); border-radius: 0.65em; - box-shadow: var(--search-box-shadow); + border: 1px solid var(--search-box-border-color); z-index: 102; + margin-right: 4px; } #MSearchBox .left { display: inline-block; vertical-align: middle; - height: 1.4em; + height: 1.6em; } -#MSearchSelect { - display: inline-block; - vertical-align: middle; - width: 20px; - height: 19px; - background-image: var(--search-magnification-select-image); - margin: 0 0 0 0.3em; - padding: 0; -} - -#MSearchSelectExt { - display: inline-block; - vertical-align: middle; - width: 10px; - height: 19px; - background-image: var(--search-magnification-image); - margin: 0 0 0 0.5em; - padding: 0; -} - - #MSearchField { display: inline-block; - vertical-align: middle; + vertical-align: top; width: 7.5em; - height: 19px; - margin: 0 0.15em; + height: 22px; + margin: 0 0 0 0.15em; padding: 0; line-height: 1em; border:none; @@ -86,7 +66,7 @@ dark-mode-toggle { display: inline-block; vertical-align: middle; width: 1.4em; - height: 1.4em; + height: 1.6em; } #MSearchClose { @@ -101,14 +81,100 @@ dark-mode-toggle { } #MSearchCloseImg { - padding: 0.3em; - margin: 0; + margin: 6px 0 0 4px; } +.close-icon { + width: 11px; + height: 11px; + background-color: var(--search-close-icon-bg-color); + border-radius: 50%; + position: relative; + display: flex; + justify-content: center; + align-items: center; + box-sizing: content-box; +} + +.close-icon:before, +.close-icon:after { + content: ''; + position: absolute; + width: 7px; + height: 1px; + background-color: var(--search-close-icon-fg-color); +} + +.close-icon:before { + transform: rotate(45deg); +} + +.close-icon:after { + transform: rotate(-45deg); +} + + .MSearchBoxActive #MSearchField { color: var(--search-active-color); } +.search-icon { + width: 20px; + height: 20px; + display: inline-block; + position: relative; + margin-left: 3px; +} + +#MSearchSelectExt.search-icon { + width: 10px; +} + +#MSearchSelectExt + input { + margin-left: 5px; +} + +.search-icon::before, .search-icon::after { + content: ''; + position: absolute; + border: 1.5px solid var(--search-foreground-color); + box-sizing: content-box; +} + +.search-icon::before { + width: 6px; + height: 6px; + border-radius: 50%; + top: 7px; + left: 2px; + background: var(--search-background-color); +} + +.search-icon::after { + border: 1px solid var(--search-foreground-color); + width: 0px; + height: 3px; + border-radius: 2px; + top: 15px; + left: 8px; + transform: rotate(-45deg); + transform-origin: top left; +} + +.search-icon-dropdown { + content: ''; + width: 0; + height: 0; + border-left: 3px solid transparent; + border-right: 3px solid transparent; + border-top: 3px solid var(--search-foreground-color); + top: 8px; + left: 15px; + transform: translateX(-50%); + position: absolute; +} + + /*---------------- Search filter selection */ @@ -119,15 +185,12 @@ dark-mode-toggle { left: 0; top: 0; border: 1px solid var(--search-filter-border-color); background-color: var(--search-filter-background-color); + backdrop-filter: var(--search-filter-backdrop-filter); + -webkit-backdrop-filter: var(--search-filter-backdrop-filter); z-index: 10001; padding-top: 4px; padding-bottom: 4px; - -moz-border-radius: 4px; - -webkit-border-top-left-radius: 4px; - -webkit-border-top-right-radius: 4px; - -webkit-border-bottom-left-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + border-radius: 4px; } .SelectItem { @@ -176,18 +239,39 @@ iframe#MSearchResults { height: 15em; } +@keyframes slideInSearchResults { + from { + opacity: 0; + transform: translate(0, 15px); + } + + to { + opacity: 1; + transform: translate(0, 20px); + } +} + #MSearchResultsWindow { display: none; position: absolute; - left: 0; top: 0; + left: auto; + right: 4px; + top: 0; border: 1px solid var(--search-results-border-color); background-color: var(--search-results-background-color); + backdrop-filter: var(--search-results-backdrop-filter); + -webkit-backdrop-filter: var(--search-results-backdrop-filter); z-index:10000; width: 300px; height: 400px; overflow: auto; + border-radius: 8px; + transform: translate(0, 20px); + animation: ease-out 280ms slideInSearchResults; + box-shadow: 0 2px 8px 0 rgba(0,0,0,.075); } + /* ----------------------------------- */ @@ -201,13 +285,13 @@ iframe#MSearchResults { } .SRPage .SREntry { - font-size: 8pt; - padding: 1px 5px; + font-size: 10pt; + padding: 2px 5px; } div.SRPage { margin: 5px 2px; - background-color: var(--search-results-background-color); + /*background-color: var(--search-results-background-color);*/ } .SRChildren { @@ -261,14 +345,17 @@ div.searchresults { margin-right: 10px; } +#searchBoxPos1 dark-mode-toggle { + margin-top: 4px; +} + /*---------------- External search page results */ .pages b { - color: white; + color: var(--nav-foreground-color); padding: 5px 5px 3px 5px; - background-image: var(--nav-gradient-active-image-parent); - background-repeat: repeat-x; - text-shadow: 0 1px 1px #000000; + background-color: var(--nav-menu-active-bg); + border-radius: 4px; } .pages { diff --git a/Doc/html/search/search.js b/Doc/html/search/search.js index 666af01..dc14410 100644 --- a/Doc/html/search/search.js +++ b/Doc/html/search/search.js @@ -607,6 +607,12 @@ function createResults(resultsPath) { elem.setAttribute('className',attr); } + const decodeHtml = (html) => { + const txt = document.createElement("textarea"); + txt.innerHTML = html; + return txt.value; + }; + const results = document.getElementById("SRResults"); results.innerHTML = ''; searchData.forEach((elem,index) => { @@ -620,10 +626,14 @@ function createResults(resultsPath) { srLink.setAttribute('id','Item'+index); setKeyActions(srLink,'return searchResults.Nav(event,'+index+')'); setClassAttr(srLink,'SRSymbol'); - srLink.innerHTML = elem[1][0]; + srLink.innerHTML = decodeHtml(elem[1][0]); srEntry.appendChild(srLink); if (elem[1].length==2) { // single result - srLink.setAttribute('href',resultsPath+elem[1][1][0]); + if (elem[1][1][0].startsWith('http://') || elem[1][1][0].startsWith('https://')) { // absolute path + srLink.setAttribute('href',elem[1][1][0]); + } else { // relative path + srLink.setAttribute('href',resultsPath+elem[1][1][0]); + } srLink.setAttribute('onclick','searchBox.CloseResultsWindow()'); if (elem[1][1][1]) { srLink.setAttribute('target','_parent'); @@ -632,7 +642,7 @@ function createResults(resultsPath) { } const srScope = document.createElement('span'); setClassAttr(srScope,'SRScope'); - srScope.innerHTML = elem[1][1][2]; + srScope.innerHTML = decodeHtml(elem[1][1][2]); srEntry.appendChild(srScope); } else { // multiple results srLink.setAttribute('href','javascript:searchResults.Toggle("SR_'+id+'")'); @@ -643,14 +653,18 @@ function createResults(resultsPath) { srChild.setAttribute('id','Item'+index+'_c'+c); setKeyActions(srChild,'return searchResults.NavChild(event,'+index+','+c+')'); setClassAttr(srChild,'SRScope'); - srChild.setAttribute('href',resultsPath+elem[1][c+1][0]); + if (elem[1][c+1][0].startsWith('http://') || elem[1][c+1][0].startsWith('https://')) { // absolute path + srChild.setAttribute('href',elem[1][c+1][0]); + } else { // relative path + srChild.setAttribute('href',resultsPath+elem[1][c+1][0]); + } srChild.setAttribute('onclick','searchBox.CloseResultsWindow()'); if (elem[1][c+1][1]) { srChild.setAttribute('target','_parent'); } else { srChild.setAttribute('target','_blank'); } - srChild.innerHTML = elem[1][c+1][2]; + srChild.innerHTML = decodeHtml(elem[1][c+1][2]); srChildren.appendChild(srChild); } srEntry.appendChild(srChildren); diff --git a/Doc/html/search/searchdata.js b/Doc/html/search/searchdata.js index 9a4156c..7f3006a 100644 --- a/Doc/html/search/searchdata.js +++ b/Doc/html/search/searchdata.js @@ -1,14 +1,14 @@ var indexSectionsWithContent = { - 0: "abcdefghilmnoprstuвзимопрсту", + 0: "abcdefghilmnoprstuвимопсту", 1: "eghrstu", 2: "begmt", - 3: "eghrt", + 3: "eghrstu", 4: "cdeghlmnprst", 5: "gt", 6: "lt", 7: "abcdefghilmoprstu", - 8: "m" + 8: "gmstuвимопсту" }; var indexSectionNames = diff --git a/Doc/html/search/variables_0.js b/Doc/html/search/variables_0.js index 0d2dad9..91d9d13 100644 --- a/Doc/html/search/variables_0.js +++ b/Doc/html/search/variables_0.js @@ -1,5 +1,8 @@ var searchData= [ ['cand_5findex_0',['cand_index',['../struct_evolve_optimizer__t.html#a0ae0e63ba351335d4445d927991c64ae',1,'EvolveOptimizer_t']]], - ['candidates_1',['candidates',['../struct_evolve_optimizer__t.html#aec67667fd1f1533e693e41c79bc28da4',1,'EvolveOptimizer_t']]] + ['candidates_1',['candidates',['../struct_evolve_optimizer__t.html#aec67667fd1f1533e693e41c79bc28da4',1,'EvolveOptimizer_t']]], + ['clk_5fgpio_5falternagefunc_2',['CLK_GPIO_AlternageFunc',['../struct_s_p_i___settings_type_def.html#a3f3748103a0b7861f6700042fd691ba1',1,'SPI_SettingsTypeDef']]], + ['clk_5fgpiox_3',['CLK_GPIOx',['../struct_s_p_i___settings_type_def.html#a6a15d48eccf92959de3a086031fdc979',1,'SPI_SettingsTypeDef']]], + ['clk_5fpin_4',['CLK_PIN',['../struct_s_p_i___settings_type_def.html#a3bcb1ed12da3544e02e6d36493669bdc',1,'SPI_SettingsTypeDef']]] ]; diff --git a/Doc/html/search/variables_1.js b/Doc/html/search/variables_1.js index fd94506..3bb10dc 100644 --- a/Doc/html/search/variables_1.js +++ b/Doc/html/search/variables_1.js @@ -1,4 +1,6 @@ var searchData= [ - ['data_0',['data',['../struct_r_t_t___flash_header__t.html#ae7276198385c8d6f6508f433d042d52a',1,'RTT_FlashHeader_t']]] + ['data_0',['data',['../struct_r_t_t___flash_header__t.html#ae7276198385c8d6f6508f433d042d52a',1,'RTT_FlashHeader_t']]], + ['dma_5fchannel_5fx_1',['DMA_CHANNEL_X',['../struct_s_p_i___settings_type_def.html#aa0edaa145076d2383b3e0095d156d474',1,'SPI_SettingsTypeDef::DMA_CHANNEL_X'],['../struct_u_a_r_t___settings_type_def.html#a15ce92b03f7f189bfbe1ab88a5f94d19',1,'UART_SettingsTypeDef::DMA_CHANNEL_X']]], + ['dmachannel_2',['DMAChannel',['../struct_s_p_i___settings_type_def.html#a3cfd9469b0617a68bbd2a161ba06bb95',1,'SPI_SettingsTypeDef::DMAChannel'],['../struct_u_a_r_t___settings_type_def.html#a1ecc9ac6a1d2747ade56770cbab6a613',1,'UART_SettingsTypeDef::DMAChannel']]] ]; diff --git a/Doc/html/search/variables_3.js b/Doc/html/search/variables_3.js index ebaa3e9..3e4add5 100644 --- a/Doc/html/search/variables_3.js +++ b/Doc/html/search/variables_3.js @@ -1,7 +1,11 @@ var searchData= [ - ['gpio_5fpin_5fsw_0',['GPIO_PIN_SW',['../struct_t_i_m___encoder_type_def.html#a6973108a83d2a3ea4fc3e0e8a501af80',1,'TIM_EncoderTypeDef']]], - ['gpio_5fpin_5fti1_1',['GPIO_PIN_TI1',['../struct_t_i_m___encoder_type_def.html#a4fc05ef011205a6702cb3d006bab677e',1,'TIM_EncoderTypeDef']]], - ['gpio_5fpin_5fti2_2',['GPIO_PIN_TI2',['../struct_t_i_m___encoder_type_def.html#a67ad037b92162546763fc9c425b5e3c5',1,'TIM_EncoderTypeDef']]], - ['gpiox_3',['GPIOx',['../struct_t_i_m___encoder_type_def.html#ad29873fc8cdc71462e6d8744621120e9',1,'TIM_EncoderTypeDef']]] + ['gen_5findex_0',['gen_index',['../struct_evolve_optimizer__t.html#ad0f464d7048a9ed0753b61f76f563108',1,'EvolveOptimizer_t']]], + ['gen_5fmut_1',['gen_mut',['../struct_evolve_optimizer__t.html#a3be8c0c34db8429210ff470497a56727',1,'EvolveOptimizer_t']]], + ['gpio_5fpin_5frx_2',['GPIO_PIN_RX',['../struct_u_a_r_t___settings_type_def.html#a3fba2b52788fe453348b5d92ed52ba49',1,'UART_SettingsTypeDef']]], + ['gpio_5fpin_5fsw_3',['GPIO_PIN_SW',['../struct_t_i_m___encoder_type_def.html#a6973108a83d2a3ea4fc3e0e8a501af80',1,'TIM_EncoderTypeDef']]], + ['gpio_5fpin_5fti1_4',['GPIO_PIN_TI1',['../struct_t_i_m___encoder_type_def.html#a4fc05ef011205a6702cb3d006bab677e',1,'TIM_EncoderTypeDef']]], + ['gpio_5fpin_5fti2_5',['GPIO_PIN_TI2',['../struct_t_i_m___encoder_type_def.html#a67ad037b92162546763fc9c425b5e3c5',1,'TIM_EncoderTypeDef']]], + ['gpio_5fpin_5ftx_6',['GPIO_PIN_TX',['../struct_u_a_r_t___settings_type_def.html#a5f1babfcfb436cd77f5614253c0a5bef',1,'UART_SettingsTypeDef']]], + ['gpiox_7',['GPIOx',['../struct_t_i_m___encoder_type_def.html#ad29873fc8cdc71462e6d8744621120e9',1,'TIM_EncoderTypeDef::GPIOx'],['../struct_u_a_r_t___settings_type_def.html#af6f9910d065bae715cdb4a1024143a8f',1,'UART_SettingsTypeDef::GPIOx']]] ]; diff --git a/Doc/html/search/variables_4.js b/Doc/html/search/variables_4.js index 020fcba..1d4c0a0 100644 --- a/Doc/html/search/variables_4.js +++ b/Doc/html/search/variables_4.js @@ -1,4 +1,6 @@ var searchData= [ - ['htim_0',['htim',['../struct_t_i_m___settings_type_def.html#ada49efdbd35a8e442c3cff630d42f34c',1,'TIM_SettingsTypeDef::htim'],['../struct_t_i_m___encoder_type_def.html#adc80bd5a90444c31d84157f35c59b95c',1,'TIM_EncoderTypeDef::htim']]] + ['hspi_0',['hspi',['../struct_s_p_i___settings_type_def.html#ad203d8b8d67e4f477d002d15b03ba422',1,'SPI_SettingsTypeDef']]], + ['htim_1',['htim',['../struct_t_i_m___settings_type_def.html#ada49efdbd35a8e442c3cff630d42f34c',1,'TIM_SettingsTypeDef::htim'],['../struct_t_i_m___encoder_type_def.html#adc80bd5a90444c31d84157f35c59b95c',1,'TIM_EncoderTypeDef::htim']]], + ['huart_2',['huart',['../struct_u_a_r_t___settings_type_def.html#accf2c9448a3ea8eb3b8c25a569276fea',1,'UART_SettingsTypeDef']]] ]; diff --git a/Doc/html/search/variables_6.js b/Doc/html/search/variables_6.js index 76205be..bd7bed0 100644 --- a/Doc/html/search/variables_6.js +++ b/Doc/html/search/variables_6.js @@ -1,4 +1,10 @@ var searchData= [ - ['mutation_5famp_0',['mutation_amp',['../struct_evolve_optimizer__t.html#af779c7aeba0053e36cee7aade160f1c8',1,'EvolveOptimizer_t']]] + ['miso_5fgpio_5falternagefunc_0',['MISO_GPIO_AlternageFunc',['../struct_s_p_i___settings_type_def.html#aecd7a5c6e205335b8ed229d74cd35d14',1,'SPI_SettingsTypeDef']]], + ['miso_5fgpiox_1',['MISO_GPIOx',['../struct_s_p_i___settings_type_def.html#a0d55a2941854f61934487f3d209cfa95',1,'SPI_SettingsTypeDef']]], + ['miso_5fpin_2',['MISO_PIN',['../struct_s_p_i___settings_type_def.html#a3366c654d7ec6dd41c6a0b504dc8509a',1,'SPI_SettingsTypeDef']]], + ['mosi_5fgpio_5falternagefunc_3',['MOSI_GPIO_AlternageFunc',['../struct_s_p_i___settings_type_def.html#afbe75a1c36650a4a9b41fa706a4c7eab',1,'SPI_SettingsTypeDef']]], + ['mosi_5fgpiox_4',['MOSI_GPIOx',['../struct_s_p_i___settings_type_def.html#a0af3bdb273818ff97eb4ff3cff918820',1,'SPI_SettingsTypeDef']]], + ['mosi_5fpin_5',['MOSI_PIN',['../struct_s_p_i___settings_type_def.html#a961208869faf4a7369aaf4edde75f176',1,'SPI_SettingsTypeDef']]], + ['mutation_5famp_6',['mutation_amp',['../struct_evolve_optimizer__t.html#af779c7aeba0053e36cee7aade160f1c8',1,'EvolveOptimizer_t']]] ]; diff --git a/Doc/html/struct_evolve_optimizer__t-members.html b/Doc/html/struct_evolve_optimizer__t-members.html index 34782f0..dbd3cfc 100644 --- a/Doc/html/struct_evolve_optimizer__t-members.html +++ b/Doc/html/struct_evolve_optimizer__t-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
        - + +
      @@ -73,10 +71,9 @@ $(function() {
    + diff --git a/Doc/html/struct_evolve_optimizer__t.html b/Doc/html/struct_evolve_optimizer__t.html index 36e2fab..b100ac5 100644 --- a/Doc/html/struct_evolve_optimizer__t.html +++ b/Doc/html/struct_evolve_optimizer__t.html @@ -3,7 +3,7 @@ - + MyLibs: EvolveOptimizer_t Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    EvolveOptimizer_t Struct Reference
    @@ -112,41 +106,36 @@ $(function(){initNavTree('struct_evolve_optimizer__t.html',''); initResizable();

    #include <evolve_optimizer.h>

    - - - - - - - + + + + - - -

    +

    Public Attributes

    float stability
     Коэффициент насколько стабильная популяция (0..1)(n_cand)
     
    uint16_t n_params
     Количество параметров
     
    uint16_t n_cand
     Количество кандидатов в популяции
     
    uint16_t n_best
     Количество лучших, усредняемых
     
    float mutation_amp
     Амплитуда мутации (0..1)
     
    uint16_t cand_index
     Индекс кандидата для обработки
     
    uint16_t gen_index
     Индекс популяции
    float gen_mut
     Амплитуда мутации у текущей популяции
    float loss [100]
     Loss для каждого кандидата
     
    float candidates [100][20]
     Параметры кандидатов
     
    uint16_t sorted_idx [100]
     Индексы отсортированных кандидатов
     
    -

    Detailed Description

    +

    Detailed Description

    Структура эволюционного оптимизатора

    Definition at line 102 of file evolve_optimizer.h.

    -

    Member Data Documentation

    +

    Member Data Documentation

    ◆ stability

    @@ -179,7 +168,7 @@ Public Attributes

    Количество параметров

    -

    Definition at line 104 of file evolve_optimizer.h.

    +

    Definition at line 105 of file evolve_optimizer.h.

    @@ -197,7 +186,7 @@ Public Attributes

    Количество кандидатов в популяции

    -

    Definition at line 105 of file evolve_optimizer.h.

    +

    Definition at line 106 of file evolve_optimizer.h.

    @@ -215,7 +204,7 @@ Public Attributes

    Количество лучших, усредняемых

    -

    Definition at line 106 of file evolve_optimizer.h.

    +

    Definition at line 107 of file evolve_optimizer.h.

    @@ -233,7 +222,7 @@ Public Attributes

    Амплитуда мутации (0..1)

    -

    Definition at line 107 of file evolve_optimizer.h.

    +

    Definition at line 108 of file evolve_optimizer.h.

    @@ -251,7 +240,43 @@ Public Attributes

    Индекс кандидата для обработки

    -

    Definition at line 108 of file evolve_optimizer.h.

    +

    Definition at line 110 of file evolve_optimizer.h.

    + + + + +

    ◆ gen_index

    + +
    +
    + + + + +
    uint16_t EvolveOptimizer_t::gen_index
    +
    + +

    Индекс популяции

    + +

    Definition at line 111 of file evolve_optimizer.h.

    + +
    +
    + +

    ◆ gen_mut

    + +
    +
    + + + + +
    float EvolveOptimizer_t::gen_mut
    +
    + +

    Амплитуда мутации у текущей популяции

    + +

    Definition at line 114 of file evolve_optimizer.h.

    @@ -269,7 +294,7 @@ Public Attributes

    Loss для каждого кандидата

    -

    Definition at line 109 of file evolve_optimizer.h.

    +

    Definition at line 116 of file evolve_optimizer.h.

    @@ -287,7 +312,7 @@ Public Attributes

    Параметры кандидатов

    -

    Definition at line 110 of file evolve_optimizer.h.

    +

    Definition at line 117 of file evolve_optimizer.h.

    @@ -305,20 +330,28 @@ Public Attributes

    Индексы отсортированных кандидатов

    -

    Definition at line 111 of file evolve_optimizer.h.

    +

    Definition at line 118 of file evolve_optimizer.h.


    The documentation for this struct was generated from the following file: + + diff --git a/Doc/html/struct_evolve_optimizer__t.js b/Doc/html/struct_evolve_optimizer__t.js index cf9289a..588d42a 100644 --- a/Doc/html/struct_evolve_optimizer__t.js +++ b/Doc/html/struct_evolve_optimizer__t.js @@ -6,6 +6,8 @@ var struct_evolve_optimizer__t = [ "n_best", "struct_evolve_optimizer__t.html#a950cd70cb6bff33b78ad35ee58c729a6", null ], [ "mutation_amp", "struct_evolve_optimizer__t.html#af779c7aeba0053e36cee7aade160f1c8", null ], [ "cand_index", "struct_evolve_optimizer__t.html#a0ae0e63ba351335d4445d927991c64ae", null ], + [ "gen_index", "struct_evolve_optimizer__t.html#ad0f464d7048a9ed0753b61f76f563108", null ], + [ "gen_mut", "struct_evolve_optimizer__t.html#a3be8c0c34db8429210ff470497a56727", null ], [ "loss", "struct_evolve_optimizer__t.html#a93f628397c2f8d4027f2906752b650df", null ], [ "candidates", "struct_evolve_optimizer__t.html#aec67667fd1f1533e693e41c79bc28da4", null ], [ "sorted_idx", "struct_evolve_optimizer__t.html#a74b81df1c298c99162310f3f7d91735a", null ] diff --git a/Doc/html/struct_g_p_i_o___l_e_d_type_def-members.html b/Doc/html/struct_g_p_i_o___l_e_d_type_def-members.html index cd97a90..beef91b 100644 --- a/Doc/html/struct_g_p_i_o___l_e_d_type_def-members.html +++ b/Doc/html/struct_g_p_i_o___l_e_d_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    tickprev (defined in GPIO_LEDTypeDef)GPIO_LEDTypeDef
    +
    diff --git a/Doc/html/struct_g_p_i_o___l_e_d_type_def.html b/Doc/html/struct_g_p_i_o___l_e_d_type_def.html index 8e74029..2908f1f 100644 --- a/Doc/html/struct_g_p_i_o___l_e_d_type_def.html +++ b/Doc/html/struct_g_p_i_o___l_e_d_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: GPIO_LEDTypeDef Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    GPIO_LEDTypeDef Struct Reference
    @@ -112,31 +106,25 @@ $(function(){initNavTree('struct_g_p_i_o___l_e_d_type_def.html',''); initResizab

    #include <general_gpio.h>

    - - - - - - -

    +

    Public Attributes

    GPIO_LEDStateTypeDef state
     Текущий режим работы светодиода
     
    GPIO_TypeDef * LED_Port
     GPIO порт ножки светодиода
     
    uint32_t LED_Pin
     GPIO пин ножки светодиода
     
    uint8_t LED_ActiveLvl
     Активный уровень ножки (при котором светодиод горит)
     
    uint32_t LED_Period
     Период моргания светодиода
     
    uint32_t tickprev
     
    -

    Detailed Description

    +

    Detailed Description

    Структура светодиода

    -

    Definition at line 93 of file general_gpio.h.

    -

    Member Data Documentation

    +

    Definition at line 73 of file general_gpio.h.

    +

    Member Data Documentation

    ◆ state

    @@ -151,7 +139,7 @@ Public Attributes

    Текущий режим работы светодиода

    -

    Definition at line 95 of file general_gpio.h.

    +

    Definition at line 75 of file general_gpio.h.

    @@ -169,7 +157,7 @@ Public Attributes

    GPIO порт ножки светодиода

    -

    Definition at line 97 of file general_gpio.h.

    +

    Definition at line 77 of file general_gpio.h.

    @@ -187,7 +175,7 @@ Public Attributes

    GPIO пин ножки светодиода

    -

    Definition at line 98 of file general_gpio.h.

    +

    Definition at line 78 of file general_gpio.h.

    @@ -205,7 +193,7 @@ Public Attributes

    Активный уровень ножки (при котором светодиод горит)

    -

    Definition at line 100 of file general_gpio.h.

    +

    Definition at line 80 of file general_gpio.h.

    @@ -223,7 +211,7 @@ Public Attributes

    Период моргания светодиода

    -

    Definition at line 101 of file general_gpio.h.

    +

    Definition at line 81 of file general_gpio.h.

    @@ -239,20 +227,28 @@ Public Attributes
    -

    Definition at line 103 of file general_gpio.h.

    +

    Definition at line 83 of file general_gpio.h.


    The documentation for this struct was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_gpio.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_gpio.h
    + + diff --git a/Doc/html/struct_g_p_i_o___switch_type_def-members.html b/Doc/html/struct_g_p_i_o___switch_type_def-members.html index 23156f4..4957c60 100644 --- a/Doc/html/struct_g_p_i_o___switch_type_def-members.html +++ b/Doc/html/struct_g_p_i_o___switch_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    +
    diff --git a/Doc/html/struct_g_p_i_o___switch_type_def.html b/Doc/html/struct_g_p_i_o___switch_type_def.html index 7e5088c..362fcb1 100644 --- a/Doc/html/struct_g_p_i_o___switch_type_def.html +++ b/Doc/html/struct_g_p_i_o___switch_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: GPIO_SwitchTypeDef Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    GPIO_SwitchTypeDef Struct Reference
    @@ -112,31 +106,25 @@ $(function(){initNavTree('struct_g_p_i_o___switch_type_def.html',''); initResiza

    #include <general_gpio.h>

    - - - - - - -

    +

    Public Attributes

    GPIO_TypeDef * Sw_Port
     GPIO порт ножки кнопки
     
    uint32_t Sw_Pin
     GPIO пин ножки кнопки
     
    uint8_t Sw_ActiveLvl
     Активный уровень ножки (при котором кнопка нажата)
     
    uint32_t Sw_PrevState
     Предыдущее состояние кнопки
     
    uint32_t Sw_FilterDelay
     Фильтр от дребезга (в мс)
     
    uint32_t tickprev
     
    -

    Detailed Description

    +

    Detailed Description

    Структура кнопки

    -

    Definition at line 110 of file general_gpio.h.

    -

    Member Data Documentation

    +

    Definition at line 90 of file general_gpio.h.

    +

    Member Data Documentation

    ◆ Sw_Port

    @@ -151,7 +139,7 @@ Public Attributes

    GPIO порт ножки кнопки

    -

    Definition at line 112 of file general_gpio.h.

    +

    Definition at line 92 of file general_gpio.h.

    @@ -169,7 +157,7 @@ Public Attributes

    GPIO пин ножки кнопки

    -

    Definition at line 113 of file general_gpio.h.

    +

    Definition at line 93 of file general_gpio.h.

    @@ -187,7 +175,7 @@ Public Attributes

    Активный уровень ножки (при котором кнопка нажата)

    -

    Definition at line 115 of file general_gpio.h.

    +

    Definition at line 95 of file general_gpio.h.

    @@ -205,7 +193,7 @@ Public Attributes

    Предыдущее состояние кнопки

    -

    Definition at line 116 of file general_gpio.h.

    +

    Definition at line 96 of file general_gpio.h.

    @@ -223,7 +211,7 @@ Public Attributes

    Фильтр от дребезга (в мс)

    -

    Definition at line 117 of file general_gpio.h.

    +

    Definition at line 97 of file general_gpio.h.

    @@ -239,20 +227,28 @@ Public Attributes
    -

    Definition at line 119 of file general_gpio.h.

    +

    Definition at line 99 of file general_gpio.h.


    The documentation for this struct was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_gpio.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_gpio.h
    + + diff --git a/Doc/html/struct_h_f___stack_frame__t-members.html b/Doc/html/struct_h_f___stack_frame__t-members.html index 7641c7d..dcf3ead 100644 --- a/Doc/html/struct_h_f___stack_frame__t-members.html +++ b/Doc/html/struct_h_f___stack_frame__t-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/struct_h_f___stack_frame__t.html b/Doc/html/struct_h_f___stack_frame__t.html index 10afeb7..7b3739c 100644 --- a/Doc/html/struct_h_f___stack_frame__t.html +++ b/Doc/html/struct_h_f___stack_frame__t.html @@ -3,7 +3,7 @@ - + MyLibs: HF_StackFrame_t Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    @@ -112,39 +106,31 @@ $(function(){initNavTree('struct_h_f___stack_frame__t.html',''); initResizable()

    #include <trace.h>

    - - - - - - - - -

    +

    Public Attributes

    uint32_t r0
     Регистр R0.
     
    uint32_t r1
     Регистр R1.
     
    uint32_t r2
     Регистр R2.
     
    uint32_t r3
     Регистр R3.
     
    uint32_t r12
     Регистр R12.
     
    uint32_t lr
     Link Register.
     
    uint32_t pc
     Program Counter.
     
    uint32_t psr
     Program Status Register.
     
    -

    Detailed Description

    +

    Detailed Description

    Контекст стек-фрейма процессора при HardFault.

    Сохраняет регистры R0-R3, R12, LR, PC, PSR для последующего анализа.

    -

    Definition at line 463 of file trace.h.

    -

    Member Data Documentation

    +

    Definition at line 476 of file trace.h.

    +

    Member Data Documentation

    ◆ r0

    @@ -159,7 +145,7 @@ Public Attributes

    Регистр R0.

    -

    Definition at line 464 of file trace.h.

    +

    Definition at line 477 of file trace.h.

    @@ -177,7 +163,7 @@ Public Attributes

    Регистр R1.

    -

    Definition at line 465 of file trace.h.

    +

    Definition at line 478 of file trace.h.

    @@ -195,7 +181,7 @@ Public Attributes

    Регистр R2.

    -

    Definition at line 466 of file trace.h.

    +

    Definition at line 479 of file trace.h.

    @@ -213,7 +199,7 @@ Public Attributes

    Регистр R3.

    -

    Definition at line 467 of file trace.h.

    +

    Definition at line 480 of file trace.h.

    @@ -231,7 +217,7 @@ Public Attributes

    Регистр R12.

    -

    Definition at line 468 of file trace.h.

    +

    Definition at line 481 of file trace.h.

    @@ -249,7 +235,7 @@ Public Attributes

    Link Register.

    -

    Definition at line 469 of file trace.h.

    +

    Definition at line 482 of file trace.h.

    @@ -267,7 +253,7 @@ Public Attributes

    Program Counter.

    -

    Definition at line 470 of file trace.h.

    +

    Definition at line 483 of file trace.h.

    @@ -285,20 +271,28 @@ Public Attributes

    Program Status Register.

    -

    Definition at line 471 of file trace.h.

    +

    Definition at line 484 of file trace.h.


    The documentation for this struct was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/trace.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/trace.h
    + + diff --git a/Doc/html/struct_r_t_t___flash_header__t-members.html b/Doc/html/struct_r_t_t___flash_header__t-members.html index 47d5610..f48c46e 100644 --- a/Doc/html/struct_r_t_t___flash_header__t-members.html +++ b/Doc/html/struct_r_t_t___flash_header__t-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/struct_r_t_t___flash_header__t.html b/Doc/html/struct_r_t_t___flash_header__t.html index cc17867..5a3cd42 100644 --- a/Doc/html/struct_r_t_t___flash_header__t.html +++ b/Doc/html/struct_r_t_t___flash_header__t.html @@ -3,7 +3,7 @@ - + MyLibs: RTT_FlashHeader_t Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    @@ -112,23 +106,20 @@ $(function(){initNavTree('struct_r_t_t___flash_header__t.html',''); initResizabl

    #include <trace.h>

    - - - -

    +

    Public Attributes

    uint32_t tag
     Уникальный идентификатор буфера
     
    uint32_t size
     Размер данных
     
    char data [1024]
     Буфер RTT.
     
    -

    Detailed Description

    +

    Detailed Description

    Структура RTT, которая будет положена в Flash.

    -

    Definition at line 180 of file trace.h.

    -

    Member Data Documentation

    +

    Definition at line 193 of file trace.h.

    +

    Member Data Documentation

    ◆ tag

    @@ -143,7 +134,7 @@ Public Attributes

    Уникальный идентификатор буфера

    -

    Definition at line 181 of file trace.h.

    +

    Definition at line 194 of file trace.h.

    @@ -161,7 +152,7 @@ Public Attributes

    Размер данных

    -

    Definition at line 182 of file trace.h.

    +

    Definition at line 195 of file trace.h.

    @@ -179,20 +170,28 @@ Public Attributes

    Буфер RTT.

    -

    Definition at line 183 of file trace.h.

    +

    Definition at line 196 of file trace.h.


    The documentation for this struct was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/trace.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/trace.h
    + + diff --git a/Doc/html/struct_s_p_i___settings_type_def-members.html b/Doc/html/struct_s_p_i___settings_type_def-members.html index dc63a06..4a1c06c 100644 --- a/Doc/html/struct_s_p_i___settings_type_def-members.html +++ b/Doc/html/struct_s_p_i___settings_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/struct_s_p_i___settings_type_def.html b/Doc/html/struct_s_p_i___settings_type_def.html index 4499565..7bfb07d 100644 --- a/Doc/html/struct_s_p_i___settings_type_def.html +++ b/Doc/html/struct_s_p_i___settings_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: SPI_SettingsTypeDef Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    SPI_SettingsTypeDef Struct Reference
    +
    SPI_SettingsTypeDef Struct Reference
    + +

    Структура настроек SPI. + More...

    + +

    #include <general_spi.h>

    - - + - + - + - + - + - + - + - + - + - + + + + +

    +

    Public Attributes

    SPI_HandleTypeDef hspi
     
     HAL handle SPI.
    GPIO_TypeDef * CLK_GPIOx
     
     Порт CLK.
    uint32_t CLK_PIN
     
     Пин CLK.
    uint32_t CLK_GPIO_AlternageFunc
     
     Альтернативная функция для CLK.
    GPIO_TypeDef * MISO_GPIOx
     
     Порт MISO.
    uint32_t MISO_PIN
     
     Пин MISO.
    uint32_t MISO_GPIO_AlternageFunc
     
     Альтернативная функция для MISO.
    GPIO_TypeDef * MOSI_GPIOx
     
     Порт MOSI.
    uint32_t MOSI_PIN
     
     Пин MOSI.
    uint32_t MOSI_GPIO_AlternageFunc
     
     Альтернативная функция для MOSI.
    DMA_Stream_TypeDef * DMAChannel
     Канал DMA (NULL если не нужен)
    uint32_t DMA_CHANNEL_X
     Номер канала DMA (0 если не нужен)
    -

    Detailed Description

    -
    -

    Definition at line 33 of file __general_spi.h.

    -

    Member Data Documentation

    +

    Detailed Description

    +

    Структура настроек SPI.

    +

    Содержит все необходимые параметры для инициализации SPI, включая GPIO и DMA.

    + +

    Definition at line 103 of file general_spi.h.

    +

    Member Data Documentation

    ◆ hspi

    @@ -146,7 +151,9 @@ Public Attributes
    -

    Definition at line 35 of file __general_spi.h.

    +

    HAL handle SPI.

    + +

    Definition at line 105 of file general_spi.h.

    @@ -162,7 +169,9 @@ Public Attributes
    -

    Definition at line 37 of file __general_spi.h.

    +

    Порт CLK.

    + +

    Definition at line 107 of file general_spi.h.

    @@ -178,7 +187,9 @@ Public Attributes
    -

    Definition at line 38 of file __general_spi.h.

    +

    Пин CLK.

    + +

    Definition at line 108 of file general_spi.h.

    @@ -194,7 +205,9 @@ Public Attributes
    -

    Definition at line 39 of file __general_spi.h.

    +

    Альтернативная функция для CLK.

    + +

    Definition at line 109 of file general_spi.h.

    @@ -210,7 +223,9 @@ Public Attributes
    -

    Definition at line 41 of file __general_spi.h.

    +

    Порт MISO.

    + +

    Definition at line 111 of file general_spi.h.

    @@ -226,7 +241,9 @@ Public Attributes
    -

    Definition at line 42 of file __general_spi.h.

    +

    Пин MISO.

    + +

    Definition at line 112 of file general_spi.h.

    @@ -242,7 +259,9 @@ Public Attributes
    -

    Definition at line 43 of file __general_spi.h.

    +

    Альтернативная функция для MISO.

    + +

    Definition at line 113 of file general_spi.h.

    @@ -258,7 +277,9 @@ Public Attributes
    -

    Definition at line 45 of file __general_spi.h.

    +

    Порт MOSI.

    + +

    Definition at line 115 of file general_spi.h.

    @@ -274,7 +295,9 @@ Public Attributes
    -

    Definition at line 46 of file __general_spi.h.

    +

    Пин MOSI.

    + +

    Definition at line 116 of file general_spi.h.

    @@ -290,20 +313,66 @@ Public Attributes
    -

    Definition at line 47 of file __general_spi.h.

    +

    Альтернативная функция для MOSI.

    + +

    Definition at line 117 of file general_spi.h.

    + +
    + + +

    ◆ DMAChannel

    + +
    +
    + + + + +
    DMA_Stream_TypeDef* SPI_SettingsTypeDef::DMAChannel
    +
    + +

    Канал DMA (NULL если не нужен)

    + +

    Definition at line 119 of file general_spi.h.

    + +
    +
    + +

    ◆ DMA_CHANNEL_X

    + +
    +
    + + + + +
    uint32_t SPI_SettingsTypeDef::DMA_CHANNEL_X
    +
    + +

    Номер канала DMA (0 если не нужен)

    + +

    Definition at line 120 of file general_spi.h.


    The documentation for this struct was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/__general_spi.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_spi.h
    + + diff --git a/Doc/html/struct_t_i_m___encoder_type_def-members.html b/Doc/html/struct_t_i_m___encoder_type_def-members.html index 430b6ed..0519215 100644 --- a/Doc/html/struct_t_i_m___encoder_type_def-members.html +++ b/Doc/html/struct_t_i_m___encoder_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/struct_t_i_m___encoder_type_def.html b/Doc/html/struct_t_i_m___encoder_type_def.html index 68dc357..564f84b 100644 --- a/Doc/html/struct_t_i_m___encoder_type_def.html +++ b/Doc/html/struct_t_i_m___encoder_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: TIM_EncoderTypeDef Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    TIM_EncoderTypeDef Struct Reference
    @@ -111,58 +105,48 @@ $(function(){initNavTree('struct_t_i_m___encoder_type_def.html',''); initResizab More...

    #include <general_tim.h>

    -
    - + Collaboration diagram for TIM_EncoderTypeDef:
    +
    Collaboration diagram for TIM_EncoderTypeDef:
    - - - - - - - - - -

    +

    Public Attributes

    int16_t Encoder_Diff
     Считанная разница
     
    uint16_t Encoder_Shdw
     Последние считанные тики
     
    TIM_HandleTypeDef * htim
     Указатель на HAL handle таймера
     
    TIM_Encoder_InitTypeDef sConfig
     Указатель на структуру настройки энкодера
     
    GPIO_TypeDef * GPIOx
     Порт, куда подключается энкодер
     
    uint32_t GPIO_PIN_TI1
     Пин, куда подключается канал TI1.
     
    uint32_t GPIO_PIN_TI2
     Пин, куда подключается канал TI2.
     
    uint32_t GPIO_PIN_SW
     Пин, куда кнопка энкодера (если есть)
     
    GPIO_SwitchTypeDef Sw
     Структура кнопки
     
    -

    Detailed Description

    +

    Detailed Description

    Структура инициализации енкодера


    Содержит все базовые структуры, которые нужны для инициализации таймера. Если структуры настроек не заданы, то они заполнятся сами дефолтными параметрами

    Также высокоуровневые настройки частоты работы таймера. Если какая-либо высокоуровневая настройка не задана, то по возможности берется низкоуровневая настройка из структур

    -

    Definition at line 140 of file general_tim.h.

    -

    Member Data Documentation

    +

    Definition at line 141 of file general_tim.h.

    +

    Member Data Documentation

    ◆ Encoder_Diff

    @@ -177,7 +161,7 @@ Public Attributes

    Считанная разница

    -

    Definition at line 142 of file general_tim.h.

    +

    Definition at line 143 of file general_tim.h.

    @@ -195,7 +179,7 @@ Public Attributes

    Последние считанные тики

    -

    Definition at line 143 of file general_tim.h.

    +

    Definition at line 144 of file general_tim.h.

    @@ -213,7 +197,7 @@ Public Attributes

    Указатель на HAL handle таймера

    -

    Definition at line 145 of file general_tim.h.

    +

    Definition at line 146 of file general_tim.h.

    @@ -231,7 +215,7 @@ Public Attributes

    Указатель на структуру настройки энкодера

    -

    Definition at line 146 of file general_tim.h.

    +

    Definition at line 147 of file general_tim.h.

    @@ -249,7 +233,7 @@ Public Attributes

    Порт, куда подключается энкодер

    -

    Definition at line 148 of file general_tim.h.

    +

    Definition at line 149 of file general_tim.h.

    @@ -267,7 +251,7 @@ Public Attributes

    Пин, куда подключается канал TI1.

    -

    Definition at line 149 of file general_tim.h.

    +

    Definition at line 150 of file general_tim.h.

    @@ -285,7 +269,7 @@ Public Attributes

    Пин, куда подключается канал TI2.

    -

    Definition at line 150 of file general_tim.h.

    +

    Definition at line 151 of file general_tim.h.

    @@ -303,7 +287,7 @@ Public Attributes

    Пин, куда кнопка энкодера (если есть)

    -

    Definition at line 151 of file general_tim.h.

    +

    Definition at line 152 of file general_tim.h.

    @@ -321,20 +305,28 @@ Public Attributes

    Структура кнопки

    -

    Definition at line 153 of file general_tim.h.

    +

    Definition at line 154 of file general_tim.h.


    The documentation for this struct was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_tim.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_tim.h
    + + diff --git a/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.map b/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.map index 23c67d8..7e20fbf 100644 --- a/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.map +++ b/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.map @@ -1,5 +1,5 @@ - + - + diff --git a/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.md5 b/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.md5 index 3bf5ef6..b7fa754 100644 --- a/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.md5 +++ b/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.md5 @@ -1 +1 @@ -941563dd38300d4589813f0d77aba757 \ No newline at end of file +2ea4c5426996fe33f0078eba5fb4ab62 \ No newline at end of file diff --git a/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.png b/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.png index c4f904c..9ea81a6 100644 Binary files a/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.png and b/Doc/html/struct_t_i_m___encoder_type_def__coll__graph.png differ diff --git a/Doc/html/struct_t_i_m___settings_type_def-members.html b/Doc/html/struct_t_i_m___settings_type_def-members.html index ccfa745..d78d7ea 100644 --- a/Doc/html/struct_t_i_m___settings_type_def-members.html +++ b/Doc/html/struct_t_i_m___settings_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/struct_t_i_m___settings_type_def.html b/Doc/html/struct_t_i_m___settings_type_def.html index 32bf216..175625a 100644 --- a/Doc/html/struct_t_i_m___settings_type_def.html +++ b/Doc/html/struct_t_i_m___settings_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: TIM_SettingsTypeDef Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    TIM_SettingsTypeDef Struct Reference
    @@ -112,50 +106,38 @@ $(function(){initNavTree('struct_t_i_m___settings_type_def.html',''); initResiza

    #include <general_tim.h>

    - - - - - - - - + - - + - - -

    +

    Public Attributes

    TIM_HandleTypeDef htim
     HAL handle таймера
     
    TIM_ClockConfigTypeDef sClockSourceConfig
     Настройки тактирования таймера
     
    TIM_SlaveConfigTypeDef sSlaveConfig
     Настройки слейв режима таймера
     
    TIM_MasterConfigTypeDef sMasterConfig
     Настройки мастер режима таймера
     
    TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig
     Настройки дедтаймов таймера
     
    TIM_ITModeTypeDef sTimMode
     Настройки прерывания таймера
    -
     
     Настройки прерывания таймера
    TIM_MHzTickBaseTypeDef sTickBaseUS
     Длительность одного тика
    -
     
     Длительность одного тика
    uint8_t sTickBasePrescaler
     Дополнительный делитель, для удобного деления sTickBaseUS.
     
    float sTimAHBFreqMHz
     Частота шины тактирования таймера
     
    float sTimFreqHz
     Желаемая частота таймера
     
    -

    Detailed Description

    +

    Detailed Description

    Структура инициализации таймера


    Содержит все базовые структуры, которые нужны для инициализации таймера. Если структуры настроек не заданы, то они заполнятся сами дефолтными параметрами

    Также высокоуровневые настройки частоты работы таймера. Если какая-либо высокоуровневая настройка не задана, то по возможности берется низкоуровневая настройка из структур

    -

    Definition at line 112 of file general_tim.h.

    -

    Member Data Documentation

    +

    Definition at line 113 of file general_tim.h.

    +

    Member Data Documentation

    ◆ htim

    @@ -170,7 +152,7 @@ Public Attributes

    HAL handle таймера

    -

    Definition at line 114 of file general_tim.h.

    +

    Definition at line 115 of file general_tim.h.

    @@ -188,7 +170,7 @@ Public Attributes

    Настройки тактирования таймера

    -

    Definition at line 115 of file general_tim.h.

    +

    Definition at line 116 of file general_tim.h.

    @@ -206,7 +188,7 @@ Public Attributes

    Настройки слейв режима таймера

    -

    Definition at line 116 of file general_tim.h.

    +

    Definition at line 117 of file general_tim.h.

    @@ -224,7 +206,7 @@ Public Attributes

    Настройки мастер режима таймера

    -

    Definition at line 117 of file general_tim.h.

    +

    Definition at line 118 of file general_tim.h.

    @@ -242,7 +224,7 @@ Public Attributes

    Настройки дедтаймов таймера

    -

    Definition at line 118 of file general_tim.h.

    +

    Definition at line 119 of file general_tim.h.

    @@ -258,10 +240,9 @@ Public Attributes
    -

    Настройки прерывания таймера
    -

    +

    Настройки прерывания таймера

    -

    Definition at line 120 of file general_tim.h.

    +

    Definition at line 121 of file general_tim.h.

    @@ -277,10 +258,9 @@ Public Attributes
    -

    Длительность одного тика
    -

    +

    Длительность одного тика

    -

    Definition at line 121 of file general_tim.h.

    +

    Definition at line 122 of file general_tim.h.

    @@ -298,7 +278,7 @@ Public Attributes

    Дополнительный делитель, для удобного деления sTickBaseUS.

    -

    Definition at line 122 of file general_tim.h.

    +

    Definition at line 123 of file general_tim.h.

    @@ -316,7 +296,7 @@ Public Attributes

    Частота шины тактирования таймера

    -

    Definition at line 123 of file general_tim.h.

    +

    Definition at line 124 of file general_tim.h.

    @@ -334,20 +314,28 @@ Public Attributes

    Желаемая частота таймера

    -

    Definition at line 124 of file general_tim.h.

    +

    Definition at line 125 of file general_tim.h.


    The documentation for this struct was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_tim.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_tim.h
    + + diff --git a/Doc/html/struct_u_a_r_t___settings_type_def-members.html b/Doc/html/struct_u_a_r_t___settings_type_def-members.html index 95a4d63..85a66a1 100644 --- a/Doc/html/struct_u_a_r_t___settings_type_def-members.html +++ b/Doc/html/struct_u_a_r_t___settings_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/struct_u_a_r_t___settings_type_def.html b/Doc/html/struct_u_a_r_t___settings_type_def.html index 43f2851..37b728c 100644 --- a/Doc/html/struct_u_a_r_t___settings_type_def.html +++ b/Doc/html/struct_u_a_r_t___settings_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: UART_SettingsTypeDef Struct Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    - -
    UART_SettingsTypeDef Struct Reference
    +
    UART_SettingsTypeDef Struct Reference
    + +

    Структура настроек UART. + More...

    + +

    #include <general_uart.h>

    - - + - + - + - + - + - +

    +

    Public Attributes

    UART_HandleTypeDef huart
     
     HAL handle UART.
    GPIO_TypeDef * GPIOx
     
     Порт для UART.
    uint16_t GPIO_PIN_RX
     
     Пин приема
    uint16_t GPIO_PIN_TX
     
     Пин передачи
    DMA_Stream_TypeDef * DMAChannel
     
     Канал DMA (NULL если не нужен)
    uint32_t DMA_CHANNEL_X
     
     Номер канала DMA (0 если не нужен)
    -

    Detailed Description

    -
    -

    Definition at line 45 of file __general_uart.h.

    -

    Member Data Documentation

    +

    Detailed Description

    +

    Структура настроек UART.

    +

    Содержит все необходимые параметры для инициализации UART, включая GPIO и DMA.

    + +

    Definition at line 96 of file general_uart.h.

    +

    Member Data Documentation

    ◆ huart

    @@ -138,7 +139,9 @@ Public Attributes
    -

    Definition at line 47 of file __general_uart.h.

    +

    HAL handle UART.

    + +

    Definition at line 98 of file general_uart.h.

    @@ -154,7 +157,9 @@ Public Attributes
    -

    Definition at line 49 of file __general_uart.h.

    +

    Порт для UART.

    + +

    Definition at line 100 of file general_uart.h.

    @@ -170,7 +175,9 @@ Public Attributes
    -

    Definition at line 50 of file __general_uart.h.

    +

    Пин приема

    + +

    Definition at line 101 of file general_uart.h.

    @@ -186,7 +193,9 @@ Public Attributes
    -

    Definition at line 51 of file __general_uart.h.

    +

    Пин передачи

    + +

    Definition at line 102 of file general_uart.h.

    @@ -202,7 +211,9 @@ Public Attributes
    -

    Definition at line 53 of file __general_uart.h.

    +

    Канал DMA (NULL если не нужен)

    + +

    Definition at line 104 of file general_uart.h.

    @@ -218,20 +229,30 @@ Public Attributes
    -

    Definition at line 54 of file __general_uart.h.

    +

    Номер канала DMA (0 если не нужен)

    + +

    Definition at line 105 of file general_uart.h.


    The documentation for this struct was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/__general_uart.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/general_uart.h
    + + diff --git a/Doc/html/tabs.css b/Doc/html/tabs.css index fe4854a..84f33ae 100644 --- a/Doc/html/tabs.css +++ b/Doc/html/tabs.css @@ -1 +1 @@ -.sm{position:relative;z-index:9999}.sm,.sm ul,.sm li{display:block;list-style:none;margin:0;padding:0;line-height:normal;direction:ltr;text-align:left;-webkit-tap-highlight-color:rgba(0,0,0,0)}.sm-rtl,.sm-rtl ul,.sm-rtl li{direction:rtl;text-align:right}.sm>li>h1,.sm>li>h2,.sm>li>h3,.sm>li>h4,.sm>li>h5,.sm>li>h6{margin:0;padding:0}.sm ul{display:none}.sm li,.sm a{position:relative}.sm a{display:block}.sm a.disabled{cursor:not-allowed}.sm:after{content:"\00a0";display:block;height:0;font:0/0 serif;clear:both;visibility:hidden;overflow:hidden}.sm,.sm *,.sm *:before,.sm *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.main-menu-btn{position:relative;display:inline-block;width:36px;height:36px;text-indent:36px;margin-left:8px;white-space:nowrap;overflow:hidden;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0)}.main-menu-btn-icon,.main-menu-btn-icon:before,.main-menu-btn-icon:after{position:absolute;top:50%;left:2px;height:2px;width:24px;background:var(--nav-menu-button-color);-webkit-transition:all .25s;transition:all .25s}.main-menu-btn-icon:before{content:'';top:-7px;left:0}.main-menu-btn-icon:after{content:'';top:7px;left:0}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon{height:0}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon:before{top:0;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon:after{top:0;-webkit-transform:rotate(45deg);transform:rotate(45deg)}#main-menu-state{position:absolute;width:1px;height:1px;margin:-1px;border:0;padding:0;overflow:hidden;clip:rect(1px,1px,1px,1px)}#main-menu-state:not(:checked) ~ #main-menu{display:none}#main-menu-state:checked ~ #main-menu{display:block}@media(min-width:768px){.main-menu-btn{position:absolute;top:-99999px}#main-menu-state:not(:checked) ~ #main-menu{display:block}}.sm-dox{background-image:var(--nav-gradient-image)}.sm-dox a,.sm-dox a:focus,.sm-dox a:hover,.sm-dox a:active{padding:0 12px;padding-right:43px;font-family:var(--font-family-nav);font-size:13px;font-weight:bold;line-height:36px;text-decoration:none;text-shadow:var(--nav-text-normal-shadow);color:var(--nav-text-normal-color);outline:0}.sm-dox a:hover{background-image:var(--nav-gradient-active-image);background-repeat:repeat-x;color:var(--nav-text-hover-color);text-shadow:var(--nav-text-hover-shadow)}.sm-dox a.current{color:#d23600}.sm-dox a.disabled{color:#bbb}.sm-dox a span.sub-arrow{position:absolute;top:50%;margin-top:-14px;left:auto;right:3px;width:28px;height:28px;overflow:hidden;font:bold 12px/28px monospace !important;text-align:center;text-shadow:none;background:var(--nav-menu-toggle-color);-moz-border-radius:5px;-webkit-border-radius:5px;border-radius:5px}.sm-dox a span.sub-arrow:before{display:block;content:'+'}.sm-dox a.highlighted span.sub-arrow:before{display:block;content:'-'}.sm-dox>li:first-child>a,.sm-dox>li:first-child>:not(ul) a{-moz-border-radius:5px 5px 0 0;-webkit-border-radius:5px;border-radius:5px 5px 0 0}.sm-dox>li:last-child>a,.sm-dox>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul{-moz-border-radius:0 0 5px 5px;-webkit-border-radius:0;border-radius:0 0 5px 5px}.sm-dox>li:last-child>a.highlighted,.sm-dox>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}.sm-dox ul{background:var(--nav-menu-background-color)}.sm-dox ul a,.sm-dox ul a:focus,.sm-dox ul a:hover,.sm-dox ul a:active{font-size:12px;border-left:8px solid transparent;line-height:36px;text-shadow:none;background-color:var(--nav-menu-background-color);background-image:none}.sm-dox ul a:hover{background-image:var(--nav-gradient-active-image);background-repeat:repeat-x;color:var(--nav-text-hover-color);text-shadow:0 1px 1px black}.sm-dox ul ul a,.sm-dox ul ul a:hover,.sm-dox ul ul a:focus,.sm-dox ul ul a:active{border-left:16px solid transparent}.sm-dox ul ul ul a,.sm-dox ul ul ul a:hover,.sm-dox ul ul ul a:focus,.sm-dox ul ul ul a:active{border-left:24px solid transparent}.sm-dox ul ul ul ul a,.sm-dox ul ul ul ul a:hover,.sm-dox ul ul ul ul a:focus,.sm-dox ul ul ul ul a:active{border-left:32px solid transparent}.sm-dox ul ul ul ul ul a,.sm-dox ul ul ul ul ul a:hover,.sm-dox ul ul ul ul ul a:focus,.sm-dox ul ul ul ul ul a:active{border-left:40px solid transparent}@media(min-width:768px){.sm-dox ul{position:absolute;width:12em}.sm-dox li{float:left}.sm-dox.sm-rtl li{float:right}.sm-dox ul li,.sm-dox.sm-rtl ul li,.sm-dox.sm-vertical li{float:none}.sm-dox a{white-space:nowrap}.sm-dox ul a,.sm-dox.sm-vertical a{white-space:normal}.sm-dox .sm-nowrap>li>a,.sm-dox .sm-nowrap>li>:not(ul) a{white-space:nowrap}.sm-dox{padding:0 10px;background-image:var(--nav-gradient-image);line-height:36px}.sm-dox a span.sub-arrow{top:50%;margin-top:-2px;right:12px;width:0;height:0;border-width:4px;border-style:solid dashed dashed dashed;border-color:var(--nav-text-normal-color) transparent transparent transparent;background:transparent;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}.sm-dox a,.sm-dox a:focus,.sm-dox a:active,.sm-dox a:hover,.sm-dox a.highlighted{padding:0 12px;background-image:var(--nav-separator-image);background-repeat:no-repeat;background-position:right;-moz-border-radius:0 !important;-webkit-border-radius:0;border-radius:0 !important}.sm-dox a:hover{background-image:var(--nav-gradient-active-image);background-repeat:repeat-x;color:var(--nav-text-hover-color);text-shadow:var(--nav-text-hover-shadow)}.sm-dox a:hover span.sub-arrow{border-color:var(--nav-text-hover-color) transparent transparent transparent}.sm-dox a.has-submenu{padding-right:24px}.sm-dox li{border-top:0}.sm-dox>li>ul:before,.sm-dox>li>ul:after{content:'';position:absolute;top:-18px;left:30px;width:0;height:0;overflow:hidden;border-width:9px;border-style:dashed dashed solid dashed;border-color:transparent transparent #bbb transparent}.sm-dox>li>ul:after{top:-16px;left:31px;border-width:8px;border-color:transparent transparent var(--nav-menu-background-color) transparent}.sm-dox ul{border:1px solid #bbb;padding:5px 0;background:var(--nav-menu-background-color);-moz-border-radius:5px !important;-webkit-border-radius:5px;border-radius:5px !important;-moz-box-shadow:0 5px 9px rgba(0,0,0,0.2);-webkit-box-shadow:0 5px 9px rgba(0,0,0,0.2);box-shadow:0 5px 9px rgba(0,0,0,0.2)}.sm-dox ul a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-color:transparent transparent transparent var(--nav-menu-foreground-color);border-style:dashed dashed dashed solid}.sm-dox ul a,.sm-dox ul a:hover,.sm-dox ul a:focus,.sm-dox ul a:active,.sm-dox ul a.highlighted{color:var(--nav-menu-foreground-color);background-image:none;border:0 !important}.sm-dox ul a:hover{background-image:var(--nav-gradient-active-image);background-repeat:repeat-x;color:var(--nav-text-hover-color);text-shadow:var(--nav-text-hover-shadow)}.sm-dox ul a:hover span.sub-arrow{border-color:transparent transparent transparent var(--nav-text-hover-color)}.sm-dox span.scroll-up,.sm-dox span.scroll-down{position:absolute;display:none;visibility:hidden;overflow:hidden;background:var(--nav-menu-background-color);height:36px}.sm-dox span.scroll-up:hover,.sm-dox span.scroll-down:hover{background:#eee}.sm-dox span.scroll-up:hover span.scroll-up-arrow,.sm-dox span.scroll-up:hover span.scroll-down-arrow{border-color:transparent transparent #d23600 transparent}.sm-dox span.scroll-down:hover span.scroll-down-arrow{border-color:#d23600 transparent transparent transparent}.sm-dox span.scroll-up-arrow,.sm-dox span.scroll-down-arrow{position:absolute;top:0;left:50%;margin-left:-6px;width:0;height:0;overflow:hidden;border-width:6px;border-style:dashed dashed solid dashed;border-color:transparent transparent var(--nav-menu-foreground-color) transparent}.sm-dox span.scroll-down-arrow{top:8px;border-style:solid dashed dashed dashed;border-color:var(--nav-menu-foreground-color) transparent transparent transparent}.sm-dox.sm-rtl a.has-submenu{padding-right:12px;padding-left:24px}.sm-dox.sm-rtl a span.sub-arrow{right:auto;left:12px}.sm-dox.sm-rtl.sm-vertical a.has-submenu{padding:10px 20px}.sm-dox.sm-rtl.sm-vertical a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-rtl>li>ul:before{left:auto;right:30px}.sm-dox.sm-rtl>li>ul:after{left:auto;right:31px}.sm-dox.sm-rtl ul a.has-submenu{padding:10px 20px !important}.sm-dox.sm-rtl ul a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-vertical{padding:10px 0;-moz-border-radius:5px;-webkit-border-radius:5px;border-radius:5px}.sm-dox.sm-vertical a{padding:10px 20px}.sm-dox.sm-vertical a:hover,.sm-dox.sm-vertical a:focus,.sm-dox.sm-vertical a:active,.sm-dox.sm-vertical a.highlighted{background:#fff}.sm-dox.sm-vertical a.disabled{background-image:var(--nav-gradient-image)}.sm-dox.sm-vertical a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-style:dashed dashed dashed solid;border-color:transparent transparent transparent #555}.sm-dox.sm-vertical>li>ul:before,.sm-dox.sm-vertical>li>ul:after{display:none}.sm-dox.sm-vertical ul a{padding:10px 20px}.sm-dox.sm-vertical ul a:hover,.sm-dox.sm-vertical ul a:focus,.sm-dox.sm-vertical ul a:active,.sm-dox.sm-vertical ul a.highlighted{background:#eee}.sm-dox.sm-vertical ul a.disabled{background:var(--nav-menu-background-color)}} \ No newline at end of file +.sm{position:relative;z-index:9999}.sm,.sm ul,.sm li{display:block;list-style:none;margin:0;padding:0;line-height:normal;direction:ltr;text-align:left;-webkit-tap-highlight-color:rgba(0,0,0,0)}.sm-rtl,.sm-rtl ul,.sm-rtl li{direction:rtl;text-align:right}.sm>li>h1,.sm>li>h2,.sm>li>h3,.sm>li>h4,.sm>li>h5,.sm>li>h6{margin:0;padding:0}.sm ul{display:none}.sm li,.sm a{position:relative}.sm a{display:block}.sm a.disabled{cursor:not-allowed}.sm:after{content:"\00a0";display:block;height:0;font:0/0 serif;clear:both;visibility:hidden;overflow:hidden}.sm,.sm *,.sm *:before,.sm *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.main-menu-btn{position:relative;display:inline-block;width:36px;height:36px;text-indent:36px;margin-left:8px;white-space:nowrap;overflow:hidden;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0)}.main-menu-btn-icon,.main-menu-btn-icon:before,.main-menu-btn-icon:after{position:absolute;top:50%;left:2px;height:2px;width:24px;background:var(--nav-menu-button-color);-webkit-transition:all .25s;transition:all .25s}.main-menu-btn-icon:before{content:'';top:-7px;left:0}.main-menu-btn-icon:after{content:'';top:7px;left:0}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon{height:0}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon:before{top:0;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon:after{top:0;-webkit-transform:rotate(45deg);transform:rotate(45deg)}#main-menu-state{position:absolute;width:1px;height:1px;margin:-1px;border:0;padding:0;overflow:hidden;clip:rect(1px,1px,1px,1px)}#main-menu-state:not(:checked) ~ #main-menu{display:none}#main-menu-state:checked ~ #main-menu{display:block}@media(min-width:768px){.main-menu-btn{position:absolute;top:-99999px}#main-menu-state:not(:checked) ~ #main-menu{display:block}}.sm-dox{background-color:var(--nav-menu-background-color)}.sm-dox a,.sm-dox a:focus,.sm-dox a:hover,.sm-dox a:active{padding:0 12px;padding-right:43px;font-family:var(--font-family-nav);font-size:13px;line-height:36px;text-decoration:none;color:var(--nav-text-normal-color);outline:0}.sm-dox a:hover{background-color:var(--nav-menu-active-bg);border-radius:5px}.sm-dox a.current{color:#d23600}.sm-dox a.disabled{color:#bbb}.sm-dox a span.sub-arrow{position:absolute;top:50%;margin-top:-14px;left:auto;right:3px;width:28px;height:28px;overflow:hidden;font:bold 12px/28px monospace !important;text-align:center;text-shadow:none;-moz-border-radius:5px;-webkit-border-radius:5px;border-radius:5px}.sm-dox a span.sub-arrow:before{display:block;content:'+'}.sm-dox a.highlighted span.sub-arrow:before{display:block;content:'-'}.sm-dox>li:first-child>a,.sm-dox>li:first-child>:not(ul) a{-moz-border-radius:5px 5px 0 0;-webkit-border-radius:5px;border-radius:5px 5px 0 0}.sm-dox>li:last-child>a,.sm-dox>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul{-moz-border-radius:0 0 5px 5px;-webkit-border-radius:0;border-radius:0 0 5px 5px}.sm-dox>li:last-child>a.highlighted,.sm-dox>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}.sm-dox ul{background:var(--nav-menu-background-color)}.sm-dox ul a,.sm-dox ul a:focus,.sm-dox ul a:hover,.sm-dox ul a:active{font-size:12px;border-left:8px solid transparent;line-height:36px;text-shadow:none;background-color:var(--nav-menu-background-color);background-image:none}.sm-dox ul a:hover{background-color:var(--nav-menu-active-bg);border-radius:5px}.sm-dox ul ul a,.sm-dox ul ul a:hover,.sm-dox ul ul a:focus,.sm-dox ul ul a:active{border-left:16px solid transparent}.sm-dox ul ul ul a,.sm-dox ul ul ul a:hover,.sm-dox ul ul ul a:focus,.sm-dox ul ul ul a:active{border-left:24px solid transparent}.sm-dox ul ul ul ul a,.sm-dox ul ul ul ul a:hover,.sm-dox ul ul ul ul a:focus,.sm-dox ul ul ul ul a:active{border-left:32px solid transparent}.sm-dox ul ul ul ul ul a,.sm-dox ul ul ul ul ul a:hover,.sm-dox ul ul ul ul ul a:focus,.sm-dox ul ul ul ul ul a:active{border-left:40px solid transparent}@media(min-width:768px){.sm-dox ul{position:absolute;width:12em}.sm-dox li{float:left}.sm-dox.sm-rtl li{float:right}.sm-dox ul li,.sm-dox.sm-rtl ul li,.sm-dox.sm-vertical li{float:none}.sm-dox a{white-space:nowrap}.sm-dox ul a,.sm-dox.sm-vertical a{white-space:normal}.sm-dox .sm-nowrap>li>a,.sm-dox .sm-nowrap>li>:not(ul) a{white-space:nowrap}.sm-dox{padding:0 10px;background-color:var(--nav-menu-background-color);line-height:36px}.sm-dox a span.sub-arrow{top:15px;right:10px;box-sizing:content-box;padding:0;margin:0;display:inline-block;width:5px;height:5px;background-color:var(--nav-menu-background-color);border-right:2px solid var(--nav-arrow-color);border-bottom:2px solid var(--nav-arrow-color);transform:rotate(45deg);-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}.sm-dox a,.sm-dox a:focus,.sm-dox a:active,.sm-dox a:hover,.sm-dox a.highlighted{padding:0 6px}.sm-dox a:hover{background-color:var(--nav-menu-active-bg);border-radius:5px !important}.sm-dox a:hover span.sub-arrow{background-color:var(--nav-menu-active-bg);border-right:2px solid var(--nav-arrow-selected-color);border-bottom:2px solid var(--nav-arrow-selected-color)}.sm-dox a.has-submenu{padding-right:24px}.sm-dox li{border-top:0;padding:3px}.sm-dox>li>ul:before,.sm-dox>li>ul:after{content:'';position:absolute;top:-18px;left:30px;width:0;height:0;overflow:hidden;border-width:9px;border-style:dashed dashed solid dashed;border-color:transparent transparent #bbb transparent}.sm-dox>li>ul:after{top:-16px;left:31px;border-width:8px;border-color:transparent transparent var(--nav-menu-background-color) transparent}.sm-dox ul{border:1px solid #bbb;padding:5px 0;background:var(--nav-menu-background-color);-moz-border-radius:5px !important;-webkit-border-radius:5px;border-radius:5px !important;-moz-box-shadow:0 5px 9px rgba(0,0,0,0.2);-webkit-box-shadow:0 5px 9px rgba(0,0,0,0.2);box-shadow:0 5px 9px rgba(0,0,0,0.2)}.sm-dox ul a span.sub-arrow{transform:rotate(-45deg)}.sm-dox ul a,.sm-dox ul a:hover,.sm-dox ul a:focus,.sm-dox ul a:active,.sm-dox ul a.highlighted{color:var(--nav-menu-foreground-color);background-image:none;border:0 !important}.sm-dox ul a:hover{background-color:var(--nav-menu-active-bg);border-radius:5px}.sm-dox span.scroll-up,.sm-dox span.scroll-down{position:absolute;display:none;visibility:hidden;overflow:hidden;background:var(--nav-menu-background-color);height:36px}.sm-dox span.scroll-up:hover,.sm-dox span.scroll-down:hover{background:#eee}.sm-dox span.scroll-up:hover span.scroll-up-arrow,.sm-dox span.scroll-up:hover span.scroll-down-arrow{border-color:transparent transparent #d23600 transparent}.sm-dox span.scroll-down:hover span.scroll-down-arrow{border-color:#d23600 transparent transparent transparent}.sm-dox span.scroll-up-arrow,.sm-dox span.scroll-down-arrow{position:absolute;top:0;left:50%;margin-left:-6px;width:0;height:0;overflow:hidden;border-width:6px;border-style:dashed dashed solid dashed;border-color:transparent transparent var(--nav-menu-foreground-color) transparent}.sm-dox span.scroll-down-arrow{top:8px;border-style:solid dashed dashed dashed;border-color:var(--nav-menu-foreground-color) transparent transparent transparent}.sm-dox.sm-rtl a.has-submenu{padding-right:6px;padding-left:24px}.sm-dox.sm-rtl a span.sub-arrow{right:auto;left:6px}.sm-dox.sm-rtl.sm-vertical a.has-submenu{padding:10px 20px}.sm-dox.sm-rtl.sm-vertical a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-rtl>li>ul:before{left:auto;right:30px}.sm-dox.sm-rtl>li>ul:after{left:auto;right:31px}.sm-dox.sm-rtl ul a.has-submenu{padding:10px 20px !important}.sm-dox.sm-rtl ul a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-vertical{padding:10px 0;-moz-border-radius:5px;-webkit-border-radius:5px;border-radius:5px}.sm-dox.sm-vertical a{padding:10px 20px}.sm-dox.sm-vertical a:hover,.sm-dox.sm-vertical a:focus,.sm-dox.sm-vertical a:active,.sm-dox.sm-vertical a.highlighted{background:#fff}.sm-dox.sm-vertical a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-style:dashed dashed dashed solid;border-color:transparent transparent transparent #555}.sm-dox.sm-vertical>li>ul:before,.sm-dox.sm-vertical>li>ul:after{display:none}.sm-dox.sm-vertical ul a{padding:10px 20px}.sm-dox.sm-vertical ul a:hover,.sm-dox.sm-vertical ul a:focus,.sm-dox.sm-vertical ul a:active,.sm-dox.sm-vertical ul a.highlighted{background:#eee}.sm-dox.sm-vertical ul a.disabled{background:var(--nav-menu-background-color)}} diff --git a/Doc/html/topics.html b/Doc/html/topics.html index 3bcb61d..8fdffb3 100644 --- a/Doc/html/topics.html +++ b/Doc/html/topics.html @@ -3,7 +3,7 @@ - + MyLibs: Topics @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    Here is a list of all topics with brief descriptions:
    [detail level 12345]
    - - + + - + - + - - - + + + - - - - - - + + + + + + + + + +
     My LibsВсе используемые MyLibs библиотеки
     ConfigsКонфигурации для библиотек MyLibs
     My LibsВсе используемые MyLibs библиотеки
     ConfigsКонфигурации для библиотек MyLibs
     Trace configsКонфигурация трекеров и трассировки
     Evolve configsКонфигурация однослойного персептрона и алгоритма обучения
     Libraries configsПодключение различных модулей библиотеки
     General ToolsОбщие макросы и typedef'ы, используемые по всему проекту
     General ToolsОбщие макросы и typedef'ы, используемые по всему проекту
     Bit access definesМакросы и typedef'ы для работы с битами в unsigned типах
     Evolve optimizerБиблиотека для эволюционного подбора параметров
     Error Handler definesДефайны для обработки ошибок
     Delays definesМакросы и определения для работы с задержками в миллисекундах
     Utils definesОбщие вспомогательные макросы
     Trace definesДефайны для работы с трассировкой
     Trace definesДефайны для работы с трассировкой
     Serial trace definesДефайны для работы с serial трассировкой (SWO, RTT)
     GPIO trace definesДефайны для работы с GPIO трассировкой
     Flash RTT BufferМакросы и функции для сохранения/чтения RTT буфера в Flash
     Hardfault trace definesМодуль трассировки HardFault с возможностью сохранения RTT буфера во Flash
     Trackers definesДефайны для работы с трекерами
     PeripheralМодули для управления периферией
     GPIO ToolsФункции и макросы для удобной работы с GPIO
     General toolsОбщие функции/макросы для работы с GPIO
     PeripheralМодули для управления периферией
     GPIO ToolsФункции и макросы для удобной работы с GPIO
     General toolsОбщие функции/макросы для работы с GPIO
     Init definesНастройка состояний кнопок и количества тиков в периоде ШИМ
     Switch toolsФункции для работы с GPIO, как с кнопкой
     LED toolsФункции для работы с GPIO, для управления светодиодом
     TIM ToolsФункции и макросы для удобной работы с TIM
     PWM/OC Channels toolsФункции для инициализации базовых функций каналов таймера
     Encoder toolsФункции для считывания энкодера
     Delay toolsФункции для формирования задержек с помощью таймеров
     General toolsФункции для базовой инициализации таймеров
     Init definesНастройка таймеров
     SPI ToolsФункции и макросы для удобной работы с SPI
     Init definesНастройка SPI
     TIM ToolsФункции и макросы для удобной работы с TIM
     General toolsФункции для базовой инициализации таймеров
     Init definesНастройка таймеров
     Delay toolsФункции для формирования задержек с помощью таймеров
     PWM/OC Channels toolsФункции для инициализации базовых функций каналов таймера
     Encoder toolsФункции для считывания энкодера
     UART ToolsФункции и макросы для удобной работы с UART
     Init definesНастройка UART
    +
    diff --git a/Doc/html/trace_8h.html b/Doc/html/trace_8h.html index cb80436..65e6345 100644 --- a/Doc/html/trace_8h.html +++ b/Doc/html/trace_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/trace.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/trace.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    trace.h File Reference
    @@ -113,14 +106,13 @@ $(function(){initNavTree('trace_8h.html',''); initResizable(); });
    #include "mylibs_defs.h"
    #include <string.h>
    #include "SEGGER_RTT.h"
    -
    - + Include dependency graph for trace.h:
    +
    Include dependency graph for trace.h:
    -
    - + This graph shows which files directly or indirectly include this file:
    +
    This graph shows which files directly or indirectly include this file:

    Go to the source code of this file.

    - - + - - + -

    +

    Classes

    struct  RTT_FlashHeader_t
    struct  RTT_FlashHeader_t
     Структура RTT, которая будет положена в Flash. More...
     
    struct  HF_StackFrame_t
    struct  HF_StackFrame_t
     Контекст стек-фрейма процессора при HardFault. More...
     
    - - + - - - - + + - - + -

    +

    Macros

    #define my_printf(...)   SEGGER_RTT_printf(0, __VA_ARGS__)
    #define my_printf(...)
     Универсальный макрос для вывода трассировки
     
    #define log_printf(TAG, fmt, ...)
     Макрос логирования с поддержкой уровней LOG_LEVEL.
     
    #define TRACE_GPIO_SET(_gpio_, _pin_)   (_gpio_)->BSRR = (((_pin_)))
     Макрос логирования с поддержкой уровней LOG_LEVEL.
    #define TRACE_GPIO_SET(_gpio_, _pin_)
     Установить указанную ножку GPIO.
     
    #define TRACE_GPIO_RESET(_gpio_, _pin_)   (_gpio_)->BSRR = ((_pin_)<<16)
    #define TRACE_GPIO_RESET(_gpio_, _pin_)
     Сбросить указанную ножку GPIO.
     
    - - - - - - -

    +

    Functions

    __STATIC_FORCEINLINE void RTT_FlashPrepare (void)
     Подготовка Flash к записи
     
    __STATIC_FORCEINLINE int RTT_SaveToFlash (uint32_t tag, uint32_t tail_size)
     Сохраняет последние символы RTT-буфера в Flash по тегу
     
    __STATIC_FORCEINLINE int RTT_ReadFromFlash (uint32_t tag, char *Buffer, uint32_t tail_size, uint32_t *read_size)
     Читает последние символы RTT-буфера из Flash по тегу
     
    __STATIC_FORCEINLINE int RTT_EraseFlash (void)
     Стирание сектора Flash с RTT-буфером
     
    __STATIC_FORCEINLINE int HF_CheckRecovered (int erase)
     Проверка и вывод последнего HardFault-трейса из Flash.
     
    __STATIC_FORCEINLINE void HF_HandleFault (void)
     Обработчик HardFault.
     
    -

    Detailed Description

    +

    Detailed Description

    Заголочный файл для работы с трассировкой.

    Definition in file trace.h.

    + +
    diff --git a/Doc/html/trace_8h__dep__incl.map b/Doc/html/trace_8h__dep__incl.map index a3f2a35..77208d6 100644 --- a/Doc/html/trace_8h__dep__incl.map +++ b/Doc/html/trace_8h__dep__incl.map @@ -1,5 +1,5 @@ - - - - + + + + diff --git a/Doc/html/trace_8h__dep__incl.md5 b/Doc/html/trace_8h__dep__incl.md5 index 7cae4e3..92c640d 100644 --- a/Doc/html/trace_8h__dep__incl.md5 +++ b/Doc/html/trace_8h__dep__incl.md5 @@ -1 +1 @@ -99f98c0a88d15e48ceee0c0796ad19d5 \ No newline at end of file +6db45c82fbfd5a7b1d1cecc0d0fad259 \ No newline at end of file diff --git a/Doc/html/trace_8h__dep__incl.png b/Doc/html/trace_8h__dep__incl.png index c8c439c..085fac8 100644 Binary files a/Doc/html/trace_8h__dep__incl.png and b/Doc/html/trace_8h__dep__incl.png differ diff --git a/Doc/html/trace_8h__incl.map b/Doc/html/trace_8h__incl.map index 01eafc0..ccf5247 100644 --- a/Doc/html/trace_8h__incl.map +++ b/Doc/html/trace_8h__incl.map @@ -1,5 +1,5 @@ - - + + diff --git a/Doc/html/trace_8h__incl.md5 b/Doc/html/trace_8h__incl.md5 index 7a1eeb2..ebc32ea 100644 --- a/Doc/html/trace_8h__incl.md5 +++ b/Doc/html/trace_8h__incl.md5 @@ -1 +1 @@ -3a6d24b597cc9be1714ca6f437269dfb \ No newline at end of file +4051482c4be4cefdf69e8f83da6d912d \ No newline at end of file diff --git a/Doc/html/trace_8h__incl.png b/Doc/html/trace_8h__incl.png index bee5a08..8ff10f6 100644 Binary files a/Doc/html/trace_8h__incl.png and b/Doc/html/trace_8h__incl.png differ diff --git a/Doc/html/trace_8h_source.html b/Doc/html/trace_8h_source.html index d102564..a586d30 100644 --- a/Doc/html/trace_8h_source.html +++ b/Doc/html/trace_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/trace.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/trace.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
    - + + -
    +
    20 - @ref SERIAL_TRACE_ENABLE - Если трассировка отключена, то все дефайны определяются как 'ничего'
    21 и на производительность кода не влияют
    22
    -
    23 - @ref RTT_TRACE_ENABLE - для RTT это будет вызов функции SEGGER_RTT_printf(), с подключением библиотеки SEGGER_RTT.h
    -
    24 Предварительно надо подключить библиотеку SEGGER RTT и вызвать функцию SEGGER_RTT_Init()
    -
    25
    -
    26 - @ref SWO_TRACE_ENABLE для SWO это будет просто printf()
    -
    27
    -
    28 Но библиотеку STDOUT надо подключить самостоятельно:
    -
    29
    -
    30 @verbatim
    -
    31 Manage Run-Time Environment -> Compiler -> I/O -> STDOUT
    -
    32 @endverbatim
    -
    33
    -
    34 Для SWO также надо включить трассировку:
    -
    35
    -
    36 @verbatim
    -
    37 Options For Target -> Debug -> Debugger Settings
    -
    38 @endverbatim
    -
    39
    -
    40 В вкладке Debug:
    -
    41 - Port = SW
    -
    42 В вкладке Trace:
    -
    43 - Указать Core Clock
    -
    44 - Выставить Trace Port = SWO
    -
    45 - ITM - выбрать нужный порт (для Keil нулевой порт)
    -
    46
    -
    47
    -
    48 * @{
    -
    49 *
    -
    50 * @def my_printf(...)
    -
    51 * @brief Универсальный макрос для вывода трассировки
    -
    52 * @details Варианты реализации:
    -
    53 * - RTT_TRACE_ENABLE `SEGGER_RTT_printf(0, ...)`
    -
    54 * - SWO_TRACE_ENABLE - `printf(...)`
    -
    55 * - NO_TRACE - пустой макрос
    -
    56 *
    -
    57 * @def log_printf(TAG, fmt, ...)
    -
    58 * @brief Макрос логирования с поддержкой уровней LOG_LEVEL
    -
    59 * @param TAG Тэг лога
    -
    60 * @param fmt, ... Форматируемая строка
    -
    61 * @details Варианты реализации:
    -
    62 * - LOG_LEVEL == 0 - логирование отключено (макрос пустой)
    -
    63 * - LOG_LEVEL == 1 - выводится время и TAG
    -
    64 * - LOG_LEVEL >= 2 - выводится время, TAG, имя файла и номер строки
    -
    65 */
    -
    66#ifdef SERIAL_TRACE_ENABLE
    -
    67
    -
    68 #if defined(RTT_TRACE_ENABLE)
    -
    69 #undef SWO_TRACE_ENABLE
    -
    70 #include "SEGGER_RTT.h"
    -
    71 #define my_printf(...) SEGGER_RTT_printf(0, __VA_ARGS__)
    -
    72 #elif defined(SWO_TRACE_ENABLE)
    -
    73 #undef RTT_TRACE_ENABLE
    -
    74 #define my_printf(...) printf(__VA_ARGS__)
    -
    75 #else // NO_TRACE
    -
    76 #define my_printf(...)
    -
    77 #warning No trace is selected. Serial debug wont work.
    -
    78 #endif // RTT_TRACE_ENABLE/SWO_TRACE_ENABLE/NO_TRACE
    -
    79#else //SERIAL_TRACE_ENABLE
    -
    80
    -
    81 #define my_printf(...)
    -
    82 #undef RTT_TRACE_ENABLE
    -
    83 #undef SWO_TRACE_ENABLE
    -
    84
    -
    85#endif //SERIAL_TRACE_ENABLE
    -
    86
    -
    87
    -
    88#ifndef LOG_LEVEL
    -
    89#define LOG_LEVEL 1 ///< @brief Уровень логирования (по умолчанию == 1)
    -
    90#endif
    -
    91
    -
    92#if LOG_LEVEL == 0 // лог отключен
    -
    93 #define \
    -
    94log_printf(TAG, fmt, ...)
    -
    95#elif LOG_LEVEL == 1 // только тэг
    -
    -
    96 #define log_printf(TAG, fmt, ...) \
    -
    97my_printf("\n[%lu] [%s] " fmt, \
    -
    98(unsigned long)uwTick, TAG, ##__VA_ARGS__)
    +
    23 - @ref RTT_TRACE_ENABLE - для RTT это будет вызов функции SEGGER_RTT_printf()
    +
    24
    +
    25 Предварительно надо подключить библиотеку SEGGER RTT (SEGGER_RTT.h) и вызвать функцию SEGGER_RTT_Init()
    +
    26
    +
    27 - @ref SWO_TRACE_ENABLE для SWO это будет просто printf()
    +
    28
    +
    29 Предварительно надо подключить библиотеку STDOUT и retarget под ITM:
    +
    30
    +
    31 @verbatim
    +
    32 Manage Run-Time Environment -> Compiler -> I/O -> STDOUT -> ITM
    +
    33 @endverbatim
    +
    34
    +
    35 Для SWO также надо включить трассировку:
    +
    36
    +
    37 @verbatim
    +
    38 Options For Target -> Debug -> Debugger Settings
    +
    39 @endverbatim
    +
    40
    +
    41 В вкладке Debug:
    +
    42 - Port = SW
    +
    43 В вкладке Trace:
    +
    44 - Указать Core Clock
    +
    45 - Выставить Trace Port = SWO
    +
    46 - ITM - выбрать нужный порт (для Keil нулевой порт)
    +
    47
    +
    48
    +
    49 * @{
    +
    50 *
    +
    51 * @def my_printf(...)
    +
    52 * @brief Универсальный макрос для вывода трассировки
    +
    53 * @details Варианты реализации:
    +
    54 * - RTT_TRACE_ENABLE `SEGGER_RTT_printf(0, ...)`
    +
    55 * - SWO_TRACE_ENABLE - `printf(...)`
    +
    56 * - NO_TRACE - пустой макрос
    +
    57 *
    +
    58 * @def log_printf(TAG, fmt, ...)
    +
    59 * @brief Макрос логирования с поддержкой уровней @ref LOG_LEVEL
    +
    60 * @param TAG Тэг лога
    +
    61 * @param fmt, ... Форматируемая строка
    +
    62 * @details Варианты реализации:
    +
    63 * - @ref LOG_LEVEL == 0 - логирование отключено (макрос пустой)
    +
    64 * - @ref LOG_LEVEL == 1 - выводится время @ref local_time и TAG
    +
    65 * @code
    +
    66 [123] [ADC] Measure Done
    +
    67 [456] [ADC] Measure Err
    +
    68 * @endcode
    +
    69 * - @ref LOG_LEVEL >= 2 - выводится время, TAG, имя файла и номер строки
    +
    70 * @code
    +
    71 [123] [ADC] (../Core/Src/adc.c:75) Measure Done
    +
    72 [456] [ADC] (../Core/Src/adc.c:80) Measure Err
    +
    73 * @endcode
    +
    74 */
    +
    75#ifdef SERIAL_TRACE_ENABLE
    +
    76
    +
    77 #if defined(RTT_TRACE_ENABLE)
    +
    78 #undef SWO_TRACE_ENABLE
    +
    79 #include "SEGGER_RTT.h"
    +
    80 #define my_printf(...) SEGGER_RTT_printf(0, __VA_ARGS__)
    +
    81 #elif defined(SWO_TRACE_ENABLE)
    +
    82 #undef RTT_TRACE_ENABLE
    +
    83 #define my_printf(...) printf(__VA_ARGS__)
    +
    84 #else // NO_TRACE
    +
    85 #define my_printf(...)
    +
    86 #warning No trace is selected. Serial debug wont work.
    +
    87 #endif // RTT_TRACE_ENABLE/SWO_TRACE_ENABLE/NO_TRACE
    +
    88#else //SERIAL_TRACE_ENABLE
    +
    89
    +
    90 #define my_printf(...)
    +
    91 #undef RTT_TRACE_ENABLE
    +
    92 #undef SWO_TRACE_ENABLE
    +
    93
    +
    94#endif //SERIAL_TRACE_ENABLE
    +
    95
    +
    96
    +
    97#ifndef local_time
    +
    98#define local_time() HAL_GetTick() ///< Локальное время
    +
    99#endif
    +
    100#ifndef LOG_LEVEL
    +
    101#define LOG_LEVEL 1 ///< @brief Уровень логирования (по умолчанию == 1)
    +
    102#endif
    +
    103
    +
    104
    +
    105#if LOG_LEVEL == 0 // лог отключен
    +
    106 #define \
    +
    107log_printf(TAG, fmt, ...)
    +
    108#elif LOG_LEVEL == 1 // только тэг
    +
    +
    109 #define log_printf(TAG, fmt, ...) \
    +
    110my_printf("\n[%lu] [%s] " fmt, \
    +
    111(unsigned long)local_time(), TAG, ##__VA_ARGS__)
    -
    99#elif LOG_LEVEL >= 2 // всё
    -
    100 #define log_printf(TAG, fmt, ...) \
    -
    101my_printf("\n[%lu] [%s] (%s:%d) " fmt, \
    -
    102(unsigned long)uwTick, TAG, __FILE__, __LINE__, ##__VA_ARGS__)
    -
    103#endif
    -
    104
    -
    105/** TRACE_SERIAL
    -
    106 * @}
    -
    107 */
    -
    108
    -
    109/**
    -
    110 * @addtogroup TRACE_GPIO GPIO trace defines
    -
    111 * @ingroup TRACE
    -
    112 * @brief Дефайны для работы с GPIO трассировкой
    -
    113 * @details Определяется дефайны для работы с GPIO трассировкой:
    -
    114 - TRACE_GPIO_RESET() - для сброса ножки GPIO (через BSRR)
    -
    115 - TRACE_GPIO_SET() - для выставления ножки GPIO (через BSRR)
    -
    116
    -
    117 - Если трассировка @ref GPIO_TRACE_ENABLE отключена, то все дефайны определяются как 'ничего'
    -
    118 и на производительность кода не влияют
    -
    119 * @{
    -
    120 *
    -
    121 * @def TRACE_GPIO_RESET(_gpio_, _pin_)
    -
    122 * @brief Сбросить указанную ножку GPIO
    -
    123 * @param _gpio_ Указатель на структуру GPIO (напр. GPIOA)
    -
    124 * @param _pin_ Номер ножки (напр. GPIO_PIN_0)
    -
    125 * @details Варианты реализации:
    -
    126 * - GPIO_TRACE_ENABLE не определён - макрос пустой
    -
    127 * - GPIO_TRACE_ENABLE определён - устанавливает бит сброса через BSRR ((_pin_)<<16)
    -
    128 *
    -
    129 * @def TRACE_GPIO_SET(_gpio_, _pin_)
    -
    130 * @brief Установить указанную ножку GPIO
    -
    131 * @param _gpio_ Указатель на структуру GPIO (например GPIOA)
    -
    132 * @param _pin_ Номер ножки (напр. GPIO_PIN_0)
    -
    133 * @details Варианты реализации:
    -
    134 * - GPIO_TRACE_ENABLE не определён - макрос пустой
    -
    135 * - GPIO_TRACE_ENABLE определён - устанавливает бит установки через BSRR (_pin_)
    -
    136 */
    -
    137#ifndef GPIO_TRACE_ENABLE
    -
    138 #define TRACE_GPIO_SET(_gpio_,_pin_)
    -
    139 #define TRACE_GPIO_RESET(_gpio_,_pin_)
    -
    140#else
    -
    141 #define TRACE_GPIO_SET(_gpio_,_pin_) (_gpio_)->BSRR = (((_pin_)))
    -
    142 #define TRACE_GPIO_RESET(_gpio_,_pin_) (_gpio_)->BSRR = ((_pin_)<<16)
    -
    143#endif //GPIO_TRACE_ENABLE
    -
    144
    -
    145
    -
    146/** TRACE_GPIO
    -
    147 * @}
    -
    148 */
    -
    149
    -
    150
    -
    151
    -
    152#if defined(HAL_MODULE_ENABLED) && defined(RTT_TRACE_ENABLE)
    -
    153
    -
    154/**
    -
    155 * @addtogroup TRACE_RTT_FLASH Flash RTT Buffer
    -
    156 * @ingroup TRACE
    -
    157 * @brief Макросы и функции для сохранения/чтения RTT буфера в Flash
    -
    158 * @details Модуль позволяет сохранять данные RTT буфера во Flash и читать их обратно по тегам.
    -
    159 * Теги работают следующим образом:
    -
    160 * - Базовый тег (младший байт = 0): модуль сам выбирает первый свободный слот во Flash;
    -
    161 * новые записи получают автоинкрементированный младший байт тега (от 0x00 до 0xFF).
    -
    162 * - Конкретный тег (младший байт != 0): запись или чтение происходит строго с указанным тегом;
    -
    163 * если слот с таким тегом уже занят, запись не выполняется.
    -
    164 * - Автоинкремент позволяет хранить несколько последовательных записей в пределах одного базового тега,
    -
    165 * без необходимости вручную отслеживать адреса Flash или позиции буферов.
    -
    166 *
    -
    167 * Параметры:
    -
    168 * - @ref RTT_FLASH_BUFFER_SIZE - Размер буфера RTT в Flash
    -
    169 * - @ref RTT_FLASH_SECTOR - Сектор FLASH куда положится RTT буфер
    -
    170 * - @ref RTT_FLASH_SECTOR_START - Начало сектора RTT_FLASH_SECTOR
    -
    171 * - @ref RTT_FLASH_SECTOR_END - Конец сектора RTT_FLASH_SECTOR
    -
    172 *
    -
    173 * @{
    -
    174 */
    -
    175
    -
    176
    -
    177/**
    -
    178 * @brief Структура RTT, которая будет положена в Flash
    -
    179 */
    -
    -
    180typedef struct {
    -
    181 uint32_t tag; ///< Уникальный идентификатор буфера
    -
    182 uint32_t size; ///< Размер данных
    -
    183 char data[RTT_FLASH_BUFFER_SIZE]; ///< Буфер RTT
    - -
    -
    185
    -
    186/**
    -
    187 * @brief Подготовка Flash к записи
    -
    188 * @details Сбрасывает ошибки Flash и ожидает готовности перед записью
    -
    189 */
    -
    -
    190__STATIC_FORCEINLINE void RTT_FlashPrepare(void)
    -
    191{
    -
    192 HAL_FLASH_Unlock();
    -
    193 __HAL_FLASH_CLEAR_FLAG(FLASH_FLAG_PGSERR | FLASH_FLAG_WRPERR | FLASH_FLAG_OPERR);
    -
    194 while (__HAL_FLASH_GET_FLAG(FLASH_FLAG_BSY)) {
    -
    195 __NOP();
    -
    196 }
    -
    197}
    +
    112#elif LOG_LEVEL >= 2 // всё
    +
    113 #define log_printf(TAG, fmt, ...) \
    +
    114my_printf("\n[%lu] [%s] (%s:%d) " fmt, \
    +
    115(unsigned long)local_time(), TAG, __FILE__, __LINE__, ##__VA_ARGS__)
    +
    116#endif
    +
    117
    +
    118/** TRACE_SERIAL
    +
    119 * @}
    +
    120 */
    +
    121
    +
    122/**
    +
    123 * @addtogroup TRACE_GPIO GPIO trace defines
    +
    124 * @ingroup TRACE
    +
    125 * @brief Дефайны для работы с GPIO трассировкой
    +
    126 * @details Определяется дефайны для работы с GPIO трассировкой:
    +
    127 - TRACE_GPIO_RESET() - для сброса ножки GPIO (через BSRR)
    +
    128 - TRACE_GPIO_SET() - для выставления ножки GPIO (через BSRR)
    +
    129
    +
    130 - Если трассировка @ref GPIO_TRACE_ENABLE отключена, то все дефайны определяются как 'ничего'
    +
    131 и на производительность кода не влияют
    +
    132 * @{
    +
    133 *
    +
    134 * @def TRACE_GPIO_RESET(_gpio_, _pin_)
    +
    135 * @brief Сбросить указанную ножку GPIO
    +
    136 * @param _gpio_ Указатель на структуру GPIO (напр. GPIOA)
    +
    137 * @param _pin_ Номер ножки (напр. GPIO_PIN_0)
    +
    138 * @details Варианты реализации:
    +
    139 * - GPIO_TRACE_ENABLE не определён - макрос пустой
    +
    140 * - GPIO_TRACE_ENABLE определён - устанавливает бит сброса через BSRR ((_pin_)<<16)
    +
    141 *
    +
    142 * @def TRACE_GPIO_SET(_gpio_, _pin_)
    +
    143 * @brief Установить указанную ножку GPIO
    +
    144 * @param _gpio_ Указатель на структуру GPIO (например GPIOA)
    +
    145 * @param _pin_ Номер ножки (напр. GPIO_PIN_0)
    +
    146 * @details Варианты реализации:
    +
    147 * - GPIO_TRACE_ENABLE не определён - макрос пустой
    +
    148 * - GPIO_TRACE_ENABLE определён - устанавливает бит установки через BSRR (_pin_)
    +
    149 */
    +
    150#ifndef GPIO_TRACE_ENABLE
    +
    151 #define TRACE_GPIO_SET(_gpio_,_pin_)
    +
    152 #define TRACE_GPIO_RESET(_gpio_,_pin_)
    +
    153#else
    +
    154 #define TRACE_GPIO_SET(_gpio_,_pin_) (_gpio_)->BSRR = (((_pin_)))
    +
    155 #define TRACE_GPIO_RESET(_gpio_,_pin_) (_gpio_)->BSRR = ((_pin_)<<16)
    +
    156#endif //GPIO_TRACE_ENABLE
    +
    157
    +
    158
    +
    159/** TRACE_GPIO
    +
    160 * @}
    +
    161 */
    +
    162
    +
    163
    +
    164
    +
    165#if defined(HAL_MODULE_ENABLED) && defined(RTT_TRACE_ENABLE)
    +
    166
    +
    167/**
    +
    168 * @addtogroup TRACE_RTT_FLASH Flash RTT Buffer
    +
    169 * @ingroup TRACE
    +
    170 * @brief Макросы и функции для сохранения/чтения RTT буфера в Flash
    +
    171 * @details Модуль позволяет сохранять данные RTT буфера во Flash и читать их обратно по тегам.
    +
    172 * Теги работают следующим образом:
    +
    173 * - Базовый тег (младший байт = 0): модуль сам выбирает первый свободный слот во Flash;
    +
    174 * новые записи получают автоинкрементированный младший байт тега (от 0x00 до 0xFF).
    +
    175 * - Конкретный тег (младший байт != 0): запись или чтение происходит строго с указанным тегом;
    +
    176 * если слот с таким тегом уже занят, запись не выполняется.
    +
    177 * - Автоинкремент позволяет хранить несколько последовательных записей в пределах одного базового тега,
    +
    178 * без необходимости вручную отслеживать адреса Flash или позиции буферов.
    +
    179 *
    +
    180 * Параметры:
    +
    181 * - @ref RTT_FLASH_BUFFER_SIZE - Размер буфера RTT в Flash
    +
    182 * - @ref RTT_FLASH_SECTOR - Сектор FLASH куда положится RTT буфер
    +
    183 * - @ref RTT_FLASH_SECTOR_START - Начало сектора RTT_FLASH_SECTOR
    +
    184 * - @ref RTT_FLASH_SECTOR_END - Конец сектора RTT_FLASH_SECTOR
    +
    185 *
    +
    186 * @{
    +
    187 */
    +
    188
    +
    189
    +
    190/**
    +
    191 * @brief Структура RTT, которая будет положена в Flash
    +
    192 */
    +
    +
    193typedef struct {
    +
    194 uint32_t tag; ///< Уникальный идентификатор буфера
    +
    195 uint32_t size; ///< Размер данных
    +
    196 char data[RTT_FLASH_BUFFER_SIZE]; ///< Буфер RTT
    +
    198
    199/**
    -
    200 * @brief Сохраняет последние символы RTT-буфера в Flash по тегу
    -
    201 * @param tag Базовый или конкретный идентификатор буфера.
    -
    202 * @param tail_size Количество последних символов RTT для копирования
    -
    203 * @param buf_num Указатель на переменную в которую запишется номер буфера для конкретного тега
    -
    204 * @return >=0 — номер буфера (тег) для записи, <0 — ошибка (нет места, тег уже занят, ошибка записи в флеш)
    -
    205 *
    -
    206 * @details Автоматически копирует последние tail_size символов из RTT-буфера
    -
    207 * и записывает их во Flash.
    -
    208 * Тег может быть базовым или конкретным:
    -
    209 * - Если базовый (младший байт == 0) — будет выбран первый свободный слот с автоинкрементом.
    -
    210 * Автоинкремент формируется в пределах от 0x1 до 0xFF
    -
    211 * - Если конкретный (младший байт != 0) — запись выполняется только с этим тегом, иначе ошибка.
    -
    212 *
    -
    213 */
    -
    -
    214__STATIC_FORCEINLINE int RTT_SaveToFlash(uint32_t tag, uint32_t tail_size)
    -
    215{
    -
    216 if (tag == 0xFFFFFFFF)
    -
    217 return -1; // Неверный тег
    -
    218
    -
    219 SEGGER_RTT_BUFFER_UP *up = &_SEGGER_RTT.aUp[0];
    -
    220 unsigned buf_size = up->SizeOfBuffer;
    -
    221 unsigned wr = up->WrOff;
    -
    222
    -
    223 // Ограничиваем по размеру буфера RTT и RTT_FLASH_BUFFER_SIZE
    -
    224 unsigned n = (tail_size > buf_size) ? buf_size : tail_size;
    -
    225 if (n > RTT_FLASH_BUFFER_SIZE)
    - -
    227
    -
    228 uint32_t addr = RTT_FLASH_SECTOR_START;
    -
    229 RTT_FlashHeader_t *flash_hdr = NULL;
    -
    230 uint32_t base_tag = tag & 0xFFFFFF00;
    -
    231 uint32_t next_tag = (tag & 0xFF) == 0 ? tag + 1 : tag;
    -
    232
    -
    233 // Ищем первый свободный слот, параллельно автоинкрементируем тег
    -
    234 while ((addr + sizeof(RTT_FlashHeader_t)) <= RTT_FLASH_SECTOR_END)
    -
    235 {
    -
    236 flash_hdr = (RTT_FlashHeader_t *)addr;
    -
    237
    -
    238 if (flash_hdr->tag == 0xFFFFFFFF)
    -
    239 break; // Нашли свободное место
    +
    200 * @brief Подготовка Flash к записи
    +
    201 * @details Сбрасывает ошибки Flash и ожидает готовности перед записью
    +
    202 */
    +
    +
    203__STATIC_FORCEINLINE void RTT_FlashPrepare(void)
    +
    204{
    +
    205 HAL_FLASH_Unlock();
    +
    206 __HAL_FLASH_CLEAR_FLAG(FLASH_FLAG_PGSERR | FLASH_FLAG_WRPERR | FLASH_FLAG_OPERR);
    +
    207 while (__HAL_FLASH_GET_FLAG(FLASH_FLAG_BSY)) {
    +
    208 __NOP();
    +
    209 }
    +
    210}
    +
    +
    211
    +
    212/**
    +
    213 * @brief Сохраняет последние символы RTT-буфера в Flash по тегу
    +
    214 * @param tag Базовый или конкретный идентификатор буфера.
    +
    215 * @param tail_size Количество последних символов RTT для копирования
    +
    216 * @param buf_num Указатель на переменную в которую запишется номер буфера для конкретного тега
    +
    217 * @return >=0 — номер буфера (тег) для записи, <0 — ошибка (нет места, тег уже занят, ошибка записи в флеш)
    +
    218 *
    +
    219 * @details Автоматически копирует последние tail_size символов из RTT-буфера
    +
    220 * и записывает их во Flash.
    +
    221 * Тег может быть базовым или конкретным:
    +
    222 * - Если базовый (младший байт == 0) — будет выбран первый свободный слот с автоинкрементом.
    +
    223 * Автоинкремент формируется в пределах от 0x1 до 0xFF
    +
    224 * - Если конкретный (младший байт != 0) — запись выполняется только с этим тегом, иначе ошибка.
    +
    225 *
    +
    226 */
    +
    +
    227__STATIC_FORCEINLINE int RTT_SaveToFlash(uint32_t tag, uint32_t tail_size)
    +
    228{
    +
    229 if (tag == 0xFFFFFFFF)
    +
    230 return -1; // Неверный тег
    +
    231
    +
    232 SEGGER_RTT_BUFFER_UP *up = &_SEGGER_RTT.aUp[0];
    +
    233 unsigned buf_size = up->SizeOfBuffer;
    +
    234 unsigned wr = up->WrOff;
    +
    235
    +
    236 // Ограничиваем по размеру буфера RTT и RTT_FLASH_BUFFER_SIZE
    +
    237 unsigned n = (tail_size > buf_size) ? buf_size : tail_size;
    +
    238 if (n > RTT_FLASH_BUFFER_SIZE)
    +
    240
    -
    241
    -
    242 if((flash_hdr->tag & 0xFFFFFF00) == base_tag) // выбраный тег
    -
    243 {
    -
    244 if ((tag & 0xFF) == 0) // если он базовый - ищем последний
    -
    245 next_tag = flash_hdr->tag + 1; // автоинкремент
    -
    246 else
    -
    247 if(flash_hdr->tag == tag) // если он конкретный и уже существует - то ошибка
    -
    248 return -1; // конкретный тег уже занят
    -
    249 }
    +
    241 uint32_t addr = RTT_FLASH_SECTOR_START;
    +
    242 RTT_FlashHeader_t *flash_hdr = NULL;
    +
    243 uint32_t base_tag = tag & 0xFFFFFF00;
    +
    244 uint32_t next_tag = (tag & 0xFF) == 0 ? tag + 1 : tag;
    +
    245
    +
    246 // Ищем первый свободный слот, параллельно автоинкрементируем тег
    +
    247 while ((addr + sizeof(RTT_FlashHeader_t)) <= RTT_FLASH_SECTOR_END)
    +
    248 {
    +
    249 flash_hdr = (RTT_FlashHeader_t *)addr;
    250
    -
    251
    -
    252 if(next_tag - tag > 0xFF)
    -
    253 return -1; // автоинкремент слишком большой
    +
    251 if (flash_hdr->tag == 0xFFFFFFFF)
    +
    252 break; // Нашли свободное место
    +
    253
    254
    -
    255 addr += sizeof(RTT_FlashHeader_t);
    -
    256 }
    -
    257
    -
    258 if ((addr + sizeof(RTT_FlashHeader_t)) > RTT_FLASH_SECTOR_END)
    -
    259 return -1; // Нет свободного места
    -
    260
    -
    261 // Копируем последние n символов из RTT
    -
    262 char temp[RTT_FLASH_BUFFER_SIZE];
    -
    263 unsigned valid_count = 0;
    -
    264
    -
    265 for (unsigned i = 0; i < n; i++)
    -
    266 {
    -
    267 unsigned idx = (wr + buf_size - n + i) % buf_size;
    -
    268 char c = up->pBuffer[idx];
    -
    269 if (c != 0)
    -
    270 temp[valid_count++] = c;
    -
    271 }
    -
    272
    - -
    274
    -
    275 // Формируем структуру в RAM
    -
    276 RTT_FlashHeader_t flash_data;
    -
    277 flash_data.tag = next_tag;
    -
    278 flash_data.size = valid_count;
    -
    279 memcpy(flash_data.data, temp, valid_count);
    -
    280
    -
    281 // Записываем структуру во Flash (по 4 байта)
    -
    282 const uint32_t *p = (const uint32_t *)&flash_data;
    -
    283 for (unsigned i = 0; i < sizeof(RTT_FlashHeader_t) / 4; i++)
    -
    284 {
    -
    285 if(HAL_FLASH_Program(FLASH_TYPEPROGRAM_WORD, addr + i * 4, p[i]) != HAL_OK)
    -
    286 return -1;
    -
    287 }
    -
    288
    -
    289 HAL_FLASH_Lock();
    -
    290 __DSB();
    -
    291 __ISB();
    -
    292
    +
    255 if((flash_hdr->tag & 0xFFFFFF00) == base_tag) // выбраный тег
    +
    256 {
    +
    257 if ((tag & 0xFF) == 0) // если он базовый - ищем последний
    +
    258 next_tag = flash_hdr->tag + 1; // автоинкремент
    +
    259 else
    +
    260 if(flash_hdr->tag == tag) // если он конкретный и уже существует - то ошибка
    +
    261 return -1; // конкретный тег уже занят
    +
    262 }
    +
    263
    +
    264
    +
    265 if(next_tag - tag > 0xFF)
    +
    266 return -1; // автоинкремент слишком большой
    +
    267
    +
    268 addr += sizeof(RTT_FlashHeader_t);
    +
    269 }
    +
    270
    +
    271 if ((addr + sizeof(RTT_FlashHeader_t)) > RTT_FLASH_SECTOR_END)
    +
    272 return -1; // Нет свободного места
    +
    273
    +
    274 // Копируем последние n символов из RTT
    +
    275 char temp[RTT_FLASH_BUFFER_SIZE];
    +
    276 unsigned valid_count = 0;
    +
    277
    +
    278 for (unsigned i = 0; i < n; i++)
    +
    279 {
    +
    280 unsigned idx = (wr + buf_size - n + i) % buf_size;
    +
    281 char c = up->pBuffer[idx];
    +
    282 if (c != 0)
    +
    283 temp[valid_count++] = c;
    +
    284 }
    +
    285
    + +
    287
    +
    288 // Формируем структуру в RAM
    +
    289 RTT_FlashHeader_t flash_data;
    +
    290 flash_data.tag = next_tag;
    +
    291 flash_data.size = valid_count;
    +
    292 memcpy(flash_data.data, temp, valid_count);
    293
    -
    294 return (int)(next_tag&0xFF);
    -
    295}
    +
    294 // Записываем структуру во Flash (по 4 байта)
    +
    295 const uint32_t *p = (const uint32_t *)&flash_data;
    +
    296 for (unsigned i = 0; i < sizeof(RTT_FlashHeader_t) / 4; i++)
    +
    297 {
    +
    298 if(HAL_FLASH_Program(FLASH_TYPEPROGRAM_WORD, addr + i * 4, p[i]) != HAL_OK)
    +
    299 return -1;
    +
    300 }
    +
    301
    +
    302 HAL_FLASH_Lock();
    +
    303 __DSB();
    +
    304 __ISB();
    +
    305
    +
    306
    +
    307 return (int)(next_tag&0xFF);
    +
    308}
    -
    296
    -
    297
    -
    298/**
    -
    299 * @brief Читает последние символы RTT-буфера из Flash по тегу
    -
    300 * @param tag Базовый или конкретный идентификатор буфера.
    -
    301 * @param Buffer Буфер назначения для копирования данных
    -
    302 * @param tail_size Количество последних символов, которые нужно прочитать
    -
    303 * @param read_size Количество считанных символов
    -
    304 * @return >=0 — номер буфера (тег) для записи, <0 — ошибка (тег не найден или структура повреждена)
    -
    305 *
    -
    306 * @details Копирует последние tail_size символов из найденной записи Flash в Buffer.
    -
    307 * Тег может быть базовым или конкретным:
    -
    308 * - Если базовый (младший байт == 0) — будет прочитана последняя запись из группы.
    -
    309 * - Если конкретный (младший байт != 0) — прочитывается именно эта запись.
    -
    310 */
    -
    -
    311__STATIC_FORCEINLINE int RTT_ReadFromFlash(uint32_t tag, char *Buffer, uint32_t tail_size, uint32_t *read_size)
    -
    312{
    -
    313 if (!Buffer || tail_size == 0)
    -
    314 return -1; // Неверные параметры
    -
    315
    -
    316 if (tag == 0xFFFFFFFF)
    -
    317 return -1; // Недопустимый тег
    -
    318
    -
    319 uint32_t addr = RTT_FLASH_SECTOR_START;
    -
    320 RTT_FlashHeader_t *flash_hdr = NULL;
    -
    321 RTT_FlashHeader_t *target_hdr = NULL;
    -
    322 uint32_t base_tag = tag & 0xFFFFFF00;
    -
    323
    -
    324 // Поиск записи по тегу
    -
    325 while ((addr + sizeof(RTT_FlashHeader_t)) <= RTT_FLASH_SECTOR_END)
    -
    326 {
    -
    327 flash_hdr = (RTT_FlashHeader_t *)addr;
    +
    309
    +
    310
    +
    311/**
    +
    312 * @brief Читает последние символы RTT-буфера из Flash по тегу
    +
    313 * @param tag Базовый или конкретный идентификатор буфера.
    +
    314 * @param Buffer Буфер назначения для копирования данных
    +
    315 * @param tail_size Количество последних символов, которые нужно прочитать
    +
    316 * @param read_size Количество считанных символов
    +
    317 * @return >=0 — номер буфера (тег) для записи, <0 — ошибка (тег не найден или структура повреждена)
    +
    318 *
    +
    319 * @details Копирует последние tail_size символов из найденной записи Flash в Buffer.
    +
    320 * Тег может быть базовым или конкретным:
    +
    321 * - Если базовый (младший байт == 0) — будет прочитана последняя запись из группы.
    +
    322 * - Если конкретный (младший байт != 0) — прочитывается именно эта запись.
    +
    323 */
    +
    +
    324__STATIC_FORCEINLINE int RTT_ReadFromFlash(uint32_t tag, char *Buffer, uint32_t tail_size, uint32_t *read_size)
    +
    325{
    +
    326 if (!Buffer || tail_size == 0)
    +
    327 return -1; // Неверные параметры
    328
    -
    329 if (flash_hdr->tag == 0xFFFFFFFF)
    -
    330 break; // Достигнут конец записанных структур
    +
    329 if (tag == 0xFFFFFFFF)
    +
    330 return -1; // Недопустимый тег
    331
    -
    332 // выбраный тег
    -
    333 if((flash_hdr->tag & 0xFFFFFF00) == base_tag)
    -
    334 {
    -
    335 if ((tag & 0xFF) == 0) // если он базовый - ищем последний
    -
    336 target_hdr = flash_hdr; // сохраняем последний в группе
    -
    337 else
    -
    338 if(flash_hdr->tag == tag) // если он конкретный и найден - берем его
    -
    339 {
    -
    340 target_hdr = flash_hdr;
    -
    341 break; // конкретный тег найден
    -
    342 }
    -
    343 }
    -
    344
    -
    345 addr += sizeof(RTT_FlashHeader_t);
    -
    346 }
    -
    347
    -
    348 if (!target_hdr) return -1; // Тег не найден
    -
    349
    -
    350 // Проверка корректности размера
    -
    351 if (target_hdr->size > RTT_FLASH_BUFFER_SIZE)
    -
    352 return -1; // Повреждённая запись
    -
    353
    -
    354 // Определяем количество читаемых символов
    -
    355 uint32_t n = (tail_size > target_hdr->size) ? target_hdr->size : tail_size;
    -
    356 // Начальная позиция для чтения последних tail_size символов
    -
    357 uint32_t start = target_hdr->size - n;
    -
    358 // Копируем данные из Flash в RAM
    -
    359 memcpy(Buffer, &target_hdr->data[start], n);
    -
    360
    -
    361 if(read_size != NULL)
    -
    362 {
    -
    363 *read_size = n;
    -
    364 }
    -
    365
    -
    366 __DSB();
    -
    367 __ISB();
    -
    368
    -
    369 return (int)(target_hdr->tag & 0xFF);
    -
    370}
    -
    -
    371
    -
    372/**
    -
    373 * @brief Стирание сектора Flash с RTT-буфером
    -
    374 */
    -
    -
    375__STATIC_FORCEINLINE int RTT_EraseFlash(void)
    -
    376{
    -
    377 FLASH_EraseInitTypeDef eraseInit;
    -
    378 uint32_t pageError = 0;
    -
    379
    - +
    332 uint32_t addr = RTT_FLASH_SECTOR_START;
    +
    333 RTT_FlashHeader_t *flash_hdr = NULL;
    +
    334 RTT_FlashHeader_t *target_hdr = NULL;
    +
    335 uint32_t base_tag = tag & 0xFFFFFF00;
    +
    336
    +
    337 // Поиск записи по тегу
    +
    338 while ((addr + sizeof(RTT_FlashHeader_t)) <= RTT_FLASH_SECTOR_END)
    +
    339 {
    +
    340 flash_hdr = (RTT_FlashHeader_t *)addr;
    +
    341
    +
    342 if (flash_hdr->tag == 0xFFFFFFFF)
    +
    343 break; // Достигнут конец записанных структур
    +
    344
    +
    345 // выбраный тег
    +
    346 if((flash_hdr->tag & 0xFFFFFF00) == base_tag)
    +
    347 {
    +
    348 if ((tag & 0xFF) == 0) // если он базовый - ищем последний
    +
    349 target_hdr = flash_hdr; // сохраняем последний в группе
    +
    350 else
    +
    351 if(flash_hdr->tag == tag) // если он конкретный и найден - берем его
    +
    352 {
    +
    353 target_hdr = flash_hdr;
    +
    354 break; // конкретный тег найден
    +
    355 }
    +
    356 }
    +
    357
    +
    358 addr += sizeof(RTT_FlashHeader_t);
    +
    359 }
    +
    360
    +
    361 if (!target_hdr) return -1; // Тег не найден
    +
    362
    +
    363 // Проверка корректности размера
    +
    364 if (target_hdr->size > RTT_FLASH_BUFFER_SIZE)
    +
    365 return -1; // Повреждённая запись
    +
    366
    +
    367 // Определяем количество читаемых символов
    +
    368 uint32_t n = (tail_size > target_hdr->size) ? target_hdr->size : tail_size;
    +
    369 // Начальная позиция для чтения последних tail_size символов
    +
    370 uint32_t start = target_hdr->size - n;
    +
    371 // Копируем данные из Flash в RAM
    +
    372 memcpy(Buffer, &target_hdr->data[start], n);
    +
    373
    +
    374 if(read_size != NULL)
    +
    375 {
    +
    376 *read_size = n;
    +
    377 }
    +
    378
    +
    379 __DSB();
    +
    380 __ISB();
    381
    -
    382 eraseInit.TypeErase = FLASH_TYPEERASE_SECTORS;
    -
    383 eraseInit.Sector = RTT_FLASH_SECTOR;
    -
    384 eraseInit.NbSectors = 1;
    -
    385
    -
    386 if (HAL_FLASHEx_Erase(&eraseInit, &pageError) != HAL_OK)
    -
    387 {
    -
    388 return -1;
    -
    389 }
    -
    390 return 0;
    -
    391 HAL_FLASH_Lock();
    -
    392}
    +
    382 return (int)(target_hdr->tag & 0xFF);
    +
    383}
    -
    393
    -
    394/** TRACE_RTT_FLASH
    -
    395 * @}
    -
    396 */
    -
    397
    -
    398#else // HAL_MODULE_ENABLED && RTT_TRACE_ENABLE
    -
    399#define RTT_FlashPrepare(...)
    -
    400#define RTT_EraseFlash(...) 0
    -
    401#define RTT_SaveToFlash(...) 0
    -
    402#define RTT_ReadFromFlash(...) 0
    -
    403#endif // HAL_MODULE_ENABLED && RTT_TRACE_ENABLE
    -
    404
    -
    405
    -
    406
    -
    407
    -
    408/**
    -
    409 * @addtogroup TRACE_HARDFAULT Hardfault trace defines
    -
    410 * @ingroup TRACE
    -
    411 * @brief Модуль трассировки HardFault с возможностью сохранения RTT буфера во Flash
    -
    412 * @details
    -
    413 * Этот модуль позволяет сохранять контекст процессора и последние символы RTT буфера при возникновении HardFault.
    -
    414 *
    -
    415 * Механизм работы:
    -
    416 * - При срабатывании HardFault вызывается HF_HandleFault(), который:
    -
    417 * 1. Получает указатель на стек, где произошёл HardFault (MSP или PSP).
    -
    418 * 2. Выводит значения регистров R0-R3, R12, LR, PC, PSR и системных регистров SCB.
    -
    419 * 3. Формирует строку с регистрами и копирует последние символы RTT буфера.
    -
    420 * 4. Сохраняет данные во Flash с базовым тегом HF_RTT_TAG_BASE.
    -
    421 * - Для восстановления последнего HardFault используется HF_CheckRecovered(), который:
    -
    422 * 1. Читает запись во Flash по базовому тегу.
    -
    423 * 2. Выводит сохранённый RTT буфер и контекст регистров.
    -
    424 * 3. Опционально стирает Flash после восстановления.
    -
    425 *
    -
    426 * Параметры:
    -
    427 * - @ref HARDFAULT_SERIAL_TRACE - Включить обработку и serial трассировку Hardfault
    -
    428 * Если отключена то вставляются заглушки, никак не влияющие на параметры и остальную программу
    -
    429 * - @ref HF_RTT_TAG_BASE - Базовый тег RTT Flash для HardFault
    -
    430 * - @ref HF_RTT_TAIL_SIZE - Размер буфера RTT, который сохранится при Hardfault
    -
    431 * - @ref HF_STACK_DUMP_WORDS - Сколько слов стека будет проанализировано во время Hardfault
    -
    432 * - @ref HF_FLASH_ADDR - Адрес FLASH куда положится RTT буфер
    -
    433 * - @ref HF_RAM_END - Конец RAM памяти (чтобы во время анализа стека не выйти за пределы)
    -
    434 *
    -
    435 @code
    -
    436 void Hardfault()
    -
    437 {
    -
    438 HF_HandleFault();
    -
    439 NVIC_SystemReset();
    -
    440 }
    -
    441
    -
    442 int main()
    -
    443 {
    -
    444 if(HF_CheckRecovered(0))
    -
    445 {
    -
    446 //set hardfault error
    -
    447 RTT_EraseFlash(); // erase rtt flash after message readed
    -
    448 }
    -
    449 }
    -
    450 @endcode
    -
    451 * @{
    -
    452 */
    -
    453#if defined(HAL_MODULE_ENABLED) && defined(HARDFAULT_SERIAL_TRACE)
    -
    454
    -
    455#ifndef HF_RTT_TAIL_SIZE
    -
    456#define HF_RTT_TAIL_SIZE RTT_FLASH_BUFFER_SIZE ///< Размер буфера RTT, который сохранится при Hardfault
    -
    457#endif
    -
    458
    -
    459/**
    -
    460 * @brief Контекст стек-фрейма процессора при HardFault
    -
    461 * @details Сохраняет регистры R0-R3, R12, LR, PC, PSR для последующего анализа.
    -
    462 */
    -
    -
    463typedef struct {
    -
    464 uint32_t r0; ///< Регистр R0
    -
    465 uint32_t r1; ///< Регистр R1
    -
    466 uint32_t r2; ///< Регистр R2
    -
    467 uint32_t r3; ///< Регистр R3
    -
    468 uint32_t r12; ///< Регистр R12
    -
    469 uint32_t lr; ///< Link Register
    -
    470 uint32_t pc; ///< Program Counter
    -
    471 uint32_t psr; ///< Program Status Register
    - +
    384
    +
    385/**
    +
    386 * @brief Стирание сектора Flash с RTT-буфером
    +
    387 */
    +
    +
    388__STATIC_FORCEINLINE int RTT_EraseFlash(void)
    +
    389{
    +
    390 FLASH_EraseInitTypeDef eraseInit;
    +
    391 uint32_t pageError = 0;
    +
    392
    + +
    394
    +
    395 eraseInit.TypeErase = FLASH_TYPEERASE_SECTORS;
    +
    396 eraseInit.Sector = RTT_FLASH_SECTOR;
    +
    397 eraseInit.NbSectors = 1;
    +
    398
    +
    399 if (HAL_FLASHEx_Erase(&eraseInit, &pageError) != HAL_OK)
    +
    400 {
    +
    401 return -1;
    +
    402 }
    +
    403 return 0;
    +
    404 HAL_FLASH_Lock();
    +
    405}
    -
    473
    -
    474/**
    -
    475 * @brief Проверка и вывод последнего HardFault-трейса из Flash
    -
    476 * @details
    -
    477 * Функция ищет последнюю запись HardFault по базовому тегу HF_RTT_TAG_BASE
    -
    478 * и выводит её содержимое в консоль. После успешного вывода Flash можно опционально очистить.
    -
    479 *
    -
    480 * @return int
    -
    481 * - 1 — данные HardFault найдены и выведены
    -
    482 * - 0 — данные отсутствуют или тег не найден
    -
    483 *
    -
    484 * @note Вызов рекомендуется при инициализации приложения для анализа предыдущего сбоя.
    -
    485 */
    -
    -
    486__STATIC_FORCEINLINE int HF_CheckRecovered(int erase)
    -
    487{
    -
    488 char buffer[RTT_FLASH_BUFFER_SIZE];
    -
    489 uint32_t read_size = 0;
    -
    490 int n_hardfault = RTT_ReadFromFlash(HF_RTT_TAG_BASE, buffer, HF_RTT_TAIL_SIZE, &read_size);
    -
    491 if (n_hardfault > 0)
    -
    492 {
    -
    493 my_printf("\n--- Recovered HardFault RTT buffer #%u ---\n", n_hardfault);
    -
    494 for (int i = 0; i < read_size; i++)
    -
    495 {
    -
    496 char c = buffer[i];
    -
    497 if (c == 0 || c == (char)0xFF) break;
    -
    498 my_printf("%c", c);
    -
    499 }
    -
    500
    -
    501 if(erase)
    - -
    503 my_printf("\n--------- HardFault Dump End ---------\n");
    -
    504 return 1;
    -
    505 }
    -
    506 return 0;
    -
    507}
    +
    406
    +
    407/** TRACE_RTT_FLASH
    +
    408 * @}
    +
    409 */
    +
    410
    +
    411#else // HAL_MODULE_ENABLED && RTT_TRACE_ENABLE
    +
    412#define RTT_FlashPrepare(...)
    +
    413#define RTT_EraseFlash(...) 0
    +
    414#define RTT_SaveToFlash(...) 0
    +
    415#define RTT_ReadFromFlash(...) 0
    +
    416#endif // HAL_MODULE_ENABLED && RTT_TRACE_ENABLE
    +
    417
    +
    418
    +
    419
    +
    420
    +
    421/**
    +
    422 * @addtogroup TRACE_HARDFAULT Hardfault trace defines
    +
    423 * @ingroup TRACE
    +
    424 * @brief Модуль трассировки HardFault с возможностью сохранения RTT буфера во Flash
    +
    425 * @details
    +
    426 * Этот модуль позволяет сохранять контекст процессора и последние символы RTT буфера при возникновении HardFault.
    +
    427 *
    +
    428 * Механизм работы:
    +
    429 * - При срабатывании HardFault вызывается HF_HandleFault(), который:
    +
    430 * 1. Получает указатель на стек, где произошёл HardFault (MSP или PSP).
    +
    431 * 2. Выводит значения регистров R0-R3, R12, LR, PC, PSR и системных регистров SCB.
    +
    432 * 3. Формирует строку с регистрами и копирует последние символы RTT буфера.
    +
    433 * 4. Сохраняет данные во Flash с базовым тегом HF_RTT_TAG_BASE.
    +
    434 * - Для восстановления последнего HardFault используется HF_CheckRecovered(), который:
    +
    435 * 1. Читает запись во Flash по базовому тегу.
    +
    436 * 2. Выводит сохранённый RTT буфер и контекст регистров.
    +
    437 * 3. Опционально стирает Flash после восстановления.
    +
    438 *
    +
    439 * Параметры:
    +
    440 * - @ref HARDFAULT_SERIAL_TRACE - Включить обработку и serial трассировку Hardfault
    +
    441 * Если отключена то вставляются заглушки, никак не влияющие на параметры и остальную программу
    +
    442 * - @ref HF_RTT_TAG_BASE - Базовый тег RTT Flash для HardFault
    +
    443 * - @ref HF_RTT_TAIL_SIZE - Размер буфера RTT, который сохранится при Hardfault
    +
    444 * - @ref HF_STACK_DUMP_WORDS - Сколько слов стека будет проанализировано во время Hardfault
    +
    445 * - @ref HF_FLASH_ADDR - Адрес FLASH куда положится RTT буфер
    +
    446 * - @ref HF_RAM_END - Конец RAM памяти (чтобы во время анализа стека не выйти за пределы)
    +
    447 *
    +
    448 @code
    +
    449 void Hardfault()
    +
    450 {
    +
    451 HF_HandleFault();
    +
    452 NVIC_SystemReset();
    +
    453 }
    +
    454
    +
    455 int main()
    +
    456 {
    +
    457 if(HF_CheckRecovered(0))
    +
    458 {
    +
    459 //set hardfault error
    +
    460 RTT_EraseFlash(); // erase rtt flash after message readed
    +
    461 }
    +
    462 }
    +
    463 @endcode
    +
    464 * @{
    +
    465 */
    +
    466#if defined(HAL_MODULE_ENABLED) && defined(HARDFAULT_SERIAL_TRACE)
    +
    467
    +
    468#ifndef HF_RTT_TAIL_SIZE
    +
    469#define HF_RTT_TAIL_SIZE RTT_FLASH_BUFFER_SIZE ///< Размер буфера RTT, который сохранится при Hardfault
    +
    470#endif
    +
    471
    +
    472/**
    +
    473 * @brief Контекст стек-фрейма процессора при HardFault
    +
    474 * @details Сохраняет регистры R0-R3, R12, LR, PC, PSR для последующего анализа.
    +
    475 */
    +
    +
    476typedef struct {
    +
    477 uint32_t r0; ///< Регистр R0
    +
    478 uint32_t r1; ///< Регистр R1
    +
    479 uint32_t r2; ///< Регистр R2
    +
    480 uint32_t r3; ///< Регистр R3
    +
    481 uint32_t r12; ///< Регистр R12
    +
    482 uint32_t lr; ///< Link Register
    +
    483 uint32_t pc; ///< Program Counter
    +
    484 uint32_t psr; ///< Program Status Register
    +
    -
    508
    -
    509
    -
    510static HF_StackFrame_t *stack_frame;
    -
    511static uint32_t stack_dump[HF_STACK_DUMP_WORDS];
    -
    512static void *ret_adr[10] = {0};
    -
    513/**
    -
    514 * @brief Обработчик HardFault
    -
    515 * @details
    -
    516 * Вызывается из прерывания HardFault или в любом месте где понятно что ошибка критическая.
    -
    517 * Последовательно выполняет:
    -
    518 * 1. Определяет активный стек (MSP или PSP) на момент сбоя.
    -
    519 * 2. Сохраняет значения регистров R0-R3, R12, LR, PC, PSR.
    -
    520 * 3. Выводит системные регистры CFSR, HFSR, DFSR, AFSR, MMFAR, BFAR.
    -
    521 * 4. Формирует stack trace с 3 уровнями возврата.
    -
    522 * 5. Копирует последние символы RTT буфера.
    -
    523 * 6. Сохраняет все данные во Flash через RTT_SaveToFlash с базовым тегом HF_RTT_TAG_BASE.
    -
    524 *
    -
    525 * @note Функция защищена, так как вызывается в контексте сбоя — минимизирует использование вызовов HAL.
    -
    526 */
    -
    -
    527__STATIC_FORCEINLINE void HF_HandleFault(void)
    -
    528{
    -
    529 // Получаем указатель на стек, где произошёл HardFault
    -
    530 __ASM volatile(
    -
    531 "TST lr, #4 \n"
    -
    532 "ITE EQ \n"
    -
    533 "MRSEQ %[ptr], MSP\n"
    -
    534 "MRSNE %[ptr], PSP\n"
    -
    535 : [ptr] "=r"(stack_frame)
    -
    536 );
    -
    537
    -
    538 my_printf("\n===== HardFault occurred! =====\n");
    -
    539 my_printf("R0 = 0x%08X\n", stack_frame->r0);
    -
    540 my_printf("R1 = 0x%08X\n", stack_frame->r1);
    -
    541 my_printf("R2 = 0x%08X\n", stack_frame->r2);
    -
    542 my_printf("R3 = 0x%08X\n", stack_frame->r3);
    -
    543 my_printf("R12 = 0x%08X\n", stack_frame->r12);
    -
    544 my_printf("LR = 0x%08X\n", stack_frame->lr);
    -
    545 my_printf("PC = 0x%08X\n", stack_frame->pc);
    -
    546 my_printf("PSR = 0x%08X\n", stack_frame->psr);
    -
    547
    -
    548 my_printf("CFSR = 0x%08X\n", SCB->CFSR);
    -
    549 my_printf("HFSR = 0x%08X\n", SCB->HFSR);
    -
    550 my_printf("DFSR = 0x%08X\n", SCB->DFSR);
    -
    551 my_printf("AFSR = 0x%08X\n", SCB->AFSR);
    -
    552 my_printf("MMFAR = 0x%08X\n", SCB->MMFAR);
    -
    553 my_printf("BFAR = 0x%08X\n", SCB->BFAR);
    -
    554
    -
    555 // --- Stack trace ---
    -
    556 my_printf("--- Stack trace ---\n");
    -
    557 ret_adr[0] = __builtin_return_address(0);
    -
    558 ret_adr[1] = __builtin_return_address(1);
    -
    559 ret_adr[2] = __builtin_return_address(2);
    +
    486
    +
    487/**
    +
    488 * @brief Проверка и вывод последнего HardFault-трейса из Flash
    +
    489 * @details
    +
    490 * Функция ищет последнюю запись HardFault по базовому тегу HF_RTT_TAG_BASE
    +
    491 * и выводит её содержимое в консоль. После успешного вывода Flash можно опционально очистить.
    +
    492 *
    +
    493 * @return int
    +
    494 * - 1 — данные HardFault найдены и выведены
    +
    495 * - 0 — данные отсутствуют или тег не найден
    +
    496 *
    +
    497 * @note Вызов рекомендуется при инициализации приложения для анализа предыдущего сбоя.
    +
    498 */
    +
    +
    499__STATIC_FORCEINLINE int HF_CheckRecovered(int erase)
    +
    500{
    +
    501 char buffer[RTT_FLASH_BUFFER_SIZE];
    +
    502 uint32_t read_size = 0;
    +
    503 int n_hardfault = RTT_ReadFromFlash(HF_RTT_TAG_BASE, buffer, HF_RTT_TAIL_SIZE, &read_size);
    +
    504 if (n_hardfault > 0)
    +
    505 {
    +
    506 my_printf("\n--- Recovered HardFault RTT buffer #%u ---\n", n_hardfault);
    +
    507 for (int i = 0; i < read_size; i++)
    +
    508 {
    +
    509 char c = buffer[i];
    +
    510 if (c == 0 || c == (char)0xFF) break;
    +
    511 my_printf("%c", c);
    +
    512 }
    +
    513
    +
    514 if(erase)
    + +
    516 my_printf("\n--------- HardFault Dump End ---------\n");
    +
    517 return 1;
    +
    518 }
    +
    519 return 0;
    +
    520}
    +
    +
    521
    +
    522
    +
    523static HF_StackFrame_t *stack_frame;
    +
    524static uint32_t stack_dump[HF_STACK_DUMP_WORDS];
    +
    525static void *ret_adr[10] = {0};
    +
    526/**
    +
    527 * @brief Обработчик HardFault
    +
    528 * @details
    +
    529 * Вызывается из прерывания HardFault или в любом месте где понятно что ошибка критическая.
    +
    530 * Последовательно выполняет:
    +
    531 * 1. Определяет активный стек (MSP или PSP) на момент сбоя.
    +
    532 * 2. Сохраняет значения регистров R0-R3, R12, LR, PC, PSR.
    +
    533 * 3. Выводит системные регистры CFSR, HFSR, DFSR, AFSR, MMFAR, BFAR.
    +
    534 * 4. Формирует stack trace с 3 уровнями возврата.
    +
    535 * 5. Копирует последние символы RTT буфера.
    +
    536 * 6. Сохраняет все данные во Flash через RTT_SaveToFlash с базовым тегом HF_RTT_TAG_BASE.
    +
    537 *
    +
    538 * @note Функция защищена, так как вызывается в контексте сбоя — минимизирует использование вызовов HAL.
    +
    539 */
    +
    +
    540__STATIC_FORCEINLINE void HF_HandleFault(void)
    +
    541{
    +
    542 // Получаем указатель на стек, где произошёл HardFault
    +
    543 __ASM volatile(
    +
    544 "TST lr, #4 \n"
    +
    545 "ITE EQ \n"
    +
    546 "MRSEQ %[ptr], MSP\n"
    +
    547 "MRSNE %[ptr], PSP\n"
    +
    548 : [ptr] "=r"(stack_frame)
    +
    549 );
    +
    550
    +
    551 my_printf("\n===== HardFault occurred! =====\n");
    +
    552 my_printf("R0 = 0x%08X\n", stack_frame->r0);
    +
    553 my_printf("R1 = 0x%08X\n", stack_frame->r1);
    +
    554 my_printf("R2 = 0x%08X\n", stack_frame->r2);
    +
    555 my_printf("R3 = 0x%08X\n", stack_frame->r3);
    +
    556 my_printf("R12 = 0x%08X\n", stack_frame->r12);
    +
    557 my_printf("LR = 0x%08X\n", stack_frame->lr);
    +
    558 my_printf("PC = 0x%08X\n", stack_frame->pc);
    +
    559 my_printf("PSR = 0x%08X\n", stack_frame->psr);
    560
    -
    561 for (int i = 0; i < 3; i++) // развернуть n уровней
    -
    562 {
    -
    563 if(ret_adr[i])
    -
    564 my_printf(" #%d: 0x%08lX\r\n", i, ret_adr[i]); // -1 для Thumb
    -
    565 }
    - -
    567}
    +
    561 my_printf("CFSR = 0x%08X\n", SCB->CFSR);
    +
    562 my_printf("HFSR = 0x%08X\n", SCB->HFSR);
    +
    563 my_printf("DFSR = 0x%08X\n", SCB->DFSR);
    +
    564 my_printf("AFSR = 0x%08X\n", SCB->AFSR);
    +
    565 my_printf("MMFAR = 0x%08X\n", SCB->MMFAR);
    +
    566 my_printf("BFAR = 0x%08X\n", SCB->BFAR);
    +
    567
    +
    568 // --- Stack trace ---
    +
    569 my_printf("--- Stack trace ---\n");
    +
    570 ret_adr[0] = __builtin_return_address(0);
    +
    571 ret_adr[1] = __builtin_return_address(1);
    +
    572 ret_adr[2] = __builtin_return_address(2);
    +
    573
    +
    574 for (int i = 0; i < 3; i++) // развернуть n уровней
    +
    575 {
    +
    576 if(ret_adr[i])
    +
    577 my_printf(" #%d: 0x%08lX\r\n", i, ret_adr[i]); // -1 для Thumb
    +
    578 }
    + +
    580}
    -
    568#else // HAL_MODULE_ENABLED && HARDFAULT_SERIAL_TRACE
    -
    569#define HF_CheckRecovered(...) 0
    -
    570#define HF_HandleFault(...)
    -
    571#endif // HAL_MODULE_ENABLED && HARDFAULT_SERIAL_TRACE
    -
    572/** TRACE_HARDFAULT
    -
    573 * @}
    -
    574 */
    -
    575
    -
    576
    -
    577
    -
    578#endif //__TRACE_H_
    +
    581#else // HAL_MODULE_ENABLED && HARDFAULT_SERIAL_TRACE
    +
    582#define HF_CheckRecovered(...) 0
    +
    583#define HF_HandleFault(...)
    +
    584#endif // HAL_MODULE_ENABLED && HARDFAULT_SERIAL_TRACE
    +
    585/** TRACE_HARDFAULT
    +
    586 * @}
    +
    587 */
    +
    588
    +
    589
    +
    590
    +
    591#endif //__TRACE_H_
    #define RTT_FLASH_SECTOR
    Сектор FLASH куда положится RTT буфер
    #define RTT_FLASH_BUFFER_SIZE
    Размер буфера RTT в Flash.
    #define RTT_FLASH_SECTOR_START
    Начало сектора RTT_FLASH_SECTOR.
    @@ -711,34 +716,35 @@ $(function(){initNavTree('trace_8h_source.html',''); initResizable(); });
    #define HF_RTT_TAG_BASE
    базовый тег для HardFault
    #define HF_RTT_TAIL_SIZE
    Размер буфера RTT, который сохранится при Hardfault.
    #define RTT_FLASH_SECTOR_END
    Конец сектора RTT_FLASH_SECTOR.
    -
    __STATIC_FORCEINLINE int HF_CheckRecovered(int erase)
    Проверка и вывод последнего HardFault-трейса из Flash.
    Definition trace.h:486
    -
    __STATIC_FORCEINLINE void HF_HandleFault(void)
    Обработчик HardFault.
    Definition trace.h:527
    -
    __STATIC_FORCEINLINE void RTT_FlashPrepare(void)
    Подготовка Flash к записи
    Definition trace.h:190
    -
    __STATIC_FORCEINLINE int RTT_ReadFromFlash(uint32_t tag, char *Buffer, uint32_t tail_size, uint32_t *read_size)
    Читает последние символы RTT-буфера из Flash по тегу
    Definition trace.h:311
    -
    __STATIC_FORCEINLINE int RTT_SaveToFlash(uint32_t tag, uint32_t tail_size)
    Сохраняет последние символы RTT-буфера в Flash по тегу
    Definition trace.h:214
    -
    __STATIC_FORCEINLINE int RTT_EraseFlash(void)
    Стирание сектора Flash с RTT-буфером
    Definition trace.h:375
    -
    #define my_printf(...)
    Универсальный макрос для вывода трассировки
    Definition trace.h:71
    +
    __STATIC_FORCEINLINE int HF_CheckRecovered(int erase)
    Проверка и вывод последнего HardFault-трейса из Flash.
    Definition trace.h:499
    +
    __STATIC_FORCEINLINE void HF_HandleFault(void)
    Обработчик HardFault.
    Definition trace.h:540
    +
    __STATIC_FORCEINLINE void RTT_FlashPrepare(void)
    Подготовка Flash к записи
    Definition trace.h:203
    +
    __STATIC_FORCEINLINE int RTT_ReadFromFlash(uint32_t tag, char *Buffer, uint32_t tail_size, uint32_t *read_size)
    Читает последние символы RTT-буфера из Flash по тегу
    Definition trace.h:324
    +
    __STATIC_FORCEINLINE int RTT_SaveToFlash(uint32_t tag, uint32_t tail_size)
    Сохраняет последние символы RTT-буфера в Flash по тегу
    Definition trace.h:227
    +
    __STATIC_FORCEINLINE int RTT_EraseFlash(void)
    Стирание сектора Flash с RTT-буфером
    Definition trace.h:388
    +
    #define my_printf(...)
    Универсальный макрос для вывода трассировки
    Definition trace.h:80
    Заголочный файл для дефайнов библиотеки MyLibsGeneral.
    -
    Контекст стек-фрейма процессора при HardFault.
    Definition trace.h:463
    -
    uint32_t pc
    Program Counter.
    Definition trace.h:470
    -
    uint32_t r1
    Регистр R1.
    Definition trace.h:465
    -
    uint32_t r0
    Регистр R0.
    Definition trace.h:464
    -
    uint32_t r3
    Регистр R3.
    Definition trace.h:467
    -
    uint32_t r2
    Регистр R2.
    Definition trace.h:466
    -
    uint32_t lr
    Link Register.
    Definition trace.h:469
    -
    uint32_t r12
    Регистр R12.
    Definition trace.h:468
    -
    uint32_t psr
    Program Status Register.
    Definition trace.h:471
    -
    Структура RTT, которая будет положена в Flash.
    Definition trace.h:180
    -
    uint32_t tag
    Уникальный идентификатор буфера
    Definition trace.h:181
    -
    char data[1024]
    Буфер RTT.
    Definition trace.h:183
    -
    uint32_t size
    Размер данных
    Definition trace.h:182
    +
    Контекст стек-фрейма процессора при HardFault.
    Definition trace.h:476
    +
    uint32_t pc
    Program Counter.
    Definition trace.h:483
    +
    uint32_t r1
    Регистр R1.
    Definition trace.h:478
    +
    uint32_t r0
    Регистр R0.
    Definition trace.h:477
    +
    uint32_t r3
    Регистр R3.
    Definition trace.h:480
    +
    uint32_t r2
    Регистр R2.
    Definition trace.h:479
    +
    uint32_t lr
    Link Register.
    Definition trace.h:482
    +
    uint32_t r12
    Регистр R12.
    Definition trace.h:481
    +
    uint32_t psr
    Program Status Register.
    Definition trace.h:484
    +
    Структура RTT, которая будет положена в Flash.
    Definition trace.h:193
    +
    uint32_t tag
    Уникальный идентификатор буфера
    Definition trace.h:194
    +
    char data[1024]
    Буфер RTT.
    Definition trace.h:196
    +
    uint32_t size
    Размер данных
    Definition trace.h:195
    +
    diff --git a/Doc/html/trackers_8h.html b/Doc/html/trackers_8h.html index 84a684b..ab445ec 100644 --- a/Doc/html/trackers_8h.html +++ b/Doc/html/trackers_8h.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/trackers.h File Reference +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/trackers.h File Reference - @@ -44,21 +43,20 @@ MathJax.Hub.Config({
    - + +
    @@ -73,10 +71,9 @@ $(function() {
    +
    -
    trackers.h File Reference
    @@ -109,111 +104,97 @@ $(function(){initNavTree('trackers_8h.html',''); initResizable(); });

    Заголочный файл для работы с трекерами Trackers defines. More...

    #include "mylibs_defs.h"
    -
    - + Include dependency graph for trackers.h:
    +
    Include dependency graph for trackers.h:
    -
    - + This graph shows which files directly or indirectly include this file:
    +
    This graph shows which files directly or indirectly include this file:

    Go to the source code of this file.

    - - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + - - + -

    +

    Macros

    #define TrackerTypeDef(num_user_vars)
     Структура для счетчиков отладки
     
    #define num_of_usercnts(_user_)   (sizeof(_user_) / sizeof(uint32_t))
    #define num_of_usercnts(_user_)
     Получить количетство пользовательских переменных
     
    #define assert_usertracker(_cntstruct_, _uservarnumb_)   ((_uservarnumb_) < num_of_usercnts((_cntstruct_).user))
    #define assert_usertracker(_cntstruct_, _uservarnumb_)
     Проверка существует ли указанная пользовательская переменная
     
    #define if_assert_usertracker(_cntstruct_, _uservarnumb_)   if(assert_usertracker(_cntstruct_, _uservarnumb_))
    #define if_assert_usertracker(_cntstruct_, _uservarnumb_)
     Условие для проверки существует ли указанная пользовательская переменная
     
    #define tern_assert_usertracker(_cntstruct_, _uservarnumb_)   (assert_usertracker(_cntstruct_, _uservarnumb_)) ? _uservarnumb_ : 0
    #define tern_assert_usertracker(_cntstruct_, _uservarnumb_)
     Тернарный оператор для проверки существует ли указанная пользовательская переменная
     
    #define TrackerGet_Ok(_cntstruct_)   (_cntstruct_).cnt_ok
    #define TrackerGet_Ok(_cntstruct_)
     Считать счетчик успешных событий
     
    #define TrackerGet_Err(_cntstruct_)   (_cntstruct_).cnt_err
    #define TrackerGet_Err(_cntstruct_)
     Считать счетчик ошибок
     
    #define TrackerGet_Warn(_cntstruct_)   (_cntstruct_).cnt_warn
    #define TrackerGet_Warn(_cntstruct_)
     Считать счетчик предупреждений
     
    #define TrackerGet_User(_cntstruct_, _uservarnumb_)   (_cntstruct_).user[tern_assert_usertracker(_cntstruct_, _uservarnumb_)]
    #define TrackerGet_User(_cntstruct_, _uservarnumb_)
     Считать пользовательскую переменную
     
    #define TrackerCnt_Ok(_cntstruct_)   (_cntstruct_).cnt_ok++
    #define TrackerCnt_Ok(_cntstruct_)
     Инкрементирование счетчика успешных событий
     
    #define TrackerCnt_Err(_cntstruct_)   (_cntstruct_).cnt_err++
    #define TrackerCnt_Err(_cntstruct_)
     Инкрементирование счетчика ошибок
     
    #define TrackerCnt_Warn(_cntstruct_)   (_cntstruct_).cnt_warn++
    #define TrackerCnt_Warn(_cntstruct_)
     Инкрементирование счетчика предупреждений
     
    #define TrackerCnt_User(_cntstruct_, _uservarnumb_)   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_]++;
    #define TrackerCnt_User(_cntstruct_, _uservarnumb_)
     Инкрементирование пользовательской переменной
     
    #define TrackerWrite_User(_cntstruct_, _uservarnumb_, _val_)   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = (_val_)
    #define TrackerWrite_User(_cntstruct_, _uservarnumb_, _val_)
     Запись числа в пользовательскую переменную
     
    #define TrackerClear_All(_cntstruct_)   memset(&(_cntstruct_), 0, sizeof(_cntstruct_))
    #define TrackerClear_All(_cntstruct_)
     Очистка всей структуры
     
    #define TrackerClear_Ok(_cntstruct_)   (_cntstruct_).cnt_ok = 0
    #define TrackerClear_Ok(_cntstruct_)
     Очистка счетчика успешных событий
     
    #define TrackerClear_Err(_cntstruct_)   (_cntstruct_).cnt_err = 0
    #define TrackerClear_Err(_cntstruct_)
     Очистка счетчика ошибок
     
    #define TrackerClear_Warn(_cntstruct_)   (_cntstruct_).cnt_warn = 0
    #define TrackerClear_Warn(_cntstruct_)
     Очистка счетчика предупреждений
     
    #define TrackerClear_User(_cntstruct_, _uservarnumb_)   if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = 0;
    #define TrackerClear_User(_cntstruct_, _uservarnumb_)
     Очистка пользовательской переменной
     
    #define TrackerClear_UserAll(_cntstruct_)   memset(&(_cntstruct_).user, 0, sizeof((_cntstruct_).user))
    #define TrackerClear_UserAll(_cntstruct_)
     Очистка всех пользовательских переменных
     
    -

    Detailed Description

    +

    Detailed Description

    Заголочный файл для работы с трекерами Trackers defines.

    Definition in file trackers.h.

    + +
    diff --git a/Doc/html/trackers_8h__dep__incl.map b/Doc/html/trackers_8h__dep__incl.map index 2d500d0..1b0fa3d 100644 --- a/Doc/html/trackers_8h__dep__incl.map +++ b/Doc/html/trackers_8h__dep__incl.map @@ -1,5 +1,5 @@ - - - - + + + + diff --git a/Doc/html/trackers_8h__dep__incl.md5 b/Doc/html/trackers_8h__dep__incl.md5 index f1a498d..90e66c4 100644 --- a/Doc/html/trackers_8h__dep__incl.md5 +++ b/Doc/html/trackers_8h__dep__incl.md5 @@ -1 +1 @@ -33dbfd4ef039421a18fe436f2a444bd1 \ No newline at end of file +0e606a2ac14f204c2f3eb519136b3d25 \ No newline at end of file diff --git a/Doc/html/trackers_8h__dep__incl.png b/Doc/html/trackers_8h__dep__incl.png index 5a4f162..3db1a10 100644 Binary files a/Doc/html/trackers_8h__dep__incl.png and b/Doc/html/trackers_8h__dep__incl.png differ diff --git a/Doc/html/trackers_8h__incl.map b/Doc/html/trackers_8h__incl.map index 3efb504..3e6b58f 100644 --- a/Doc/html/trackers_8h__incl.map +++ b/Doc/html/trackers_8h__incl.map @@ -1,9 +1,9 @@ - - - - - - - - + + + + + + + + diff --git a/Doc/html/trackers_8h__incl.md5 b/Doc/html/trackers_8h__incl.md5 index 72c1e03..b38f593 100644 --- a/Doc/html/trackers_8h__incl.md5 +++ b/Doc/html/trackers_8h__incl.md5 @@ -1 +1 @@ -727bb8e299b6891ca417cde17bb1a2f9 \ No newline at end of file +efe05b63911c6edeb90de988b14c85fc \ No newline at end of file diff --git a/Doc/html/trackers_8h__incl.png b/Doc/html/trackers_8h__incl.png index a6d1423..c95cf1a 100644 Binary files a/Doc/html/trackers_8h__incl.png and b/Doc/html/trackers_8h__incl.png differ diff --git a/Doc/html/trackers_8h_source.html b/Doc/html/trackers_8h_source.html index f8587f1..f618be6 100644 --- a/Doc/html/trackers_8h_source.html +++ b/Doc/html/trackers_8h_source.html @@ -3,15 +3,14 @@ - + -MyLibs: F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/trackers.h Source File +MyLibs: E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/trackers.h Source File - @@ -44,28 +43,22 @@ MathJax.Hub.Config({
    - + + -
    +
    Заголочный файл для дефайнов библиотеки MyLibsGeneral.
    + diff --git a/Doc/html/unionuint16___bit_type_def-members.html b/Doc/html/unionuint16___bit_type_def-members.html index 3bae288..50f13d1 100644 --- a/Doc/html/unionuint16___bit_type_def-members.html +++ b/Doc/html/unionuint16___bit_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/unionuint16___bit_type_def.html b/Doc/html/unionuint16___bit_type_def.html index e290dc4..a6cc4cb 100644 --- a/Doc/html/unionuint16___bit_type_def.html +++ b/Doc/html/unionuint16___bit_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: uint16_BitTypeDef Union Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    uint16_BitTypeDef Union Reference
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + +

    +

    Public Attributes

    uint16_t all
     
    +
    struct { 
     
       unsigned   bit0:1 
     
       unsigned   bit1:1 
     
       unsigned   bit2:1 
     
       unsigned   bit3:1 
     
       unsigned   bit4:1 
     
       unsigned   bit5:1 
     
       unsigned   bit6:1 
     
       unsigned   bit7:1 
     
       unsigned   bit8:1 
     
       unsigned   bit9:1 
     
       unsigned   bit10:1 
     
       unsigned   bit11:1 
     
       unsigned   bit12:1 
     
       unsigned   bit13:1 
     
       unsigned   bit14:1 
     
       unsigned   bit15:1 
     
    bit 
     
       unsigned   bit0:1 
       unsigned   bit1:1 
       unsigned   bit2:1 
       unsigned   bit3:1 
       unsigned   bit4:1 
       unsigned   bit5:1 
       unsigned   bit6:1 
       unsigned   bit7:1 
       unsigned   bit8:1 
       unsigned   bit9:1 
       unsigned   bit10:1 
       unsigned   bit11:1 
       unsigned   bit12:1 
       unsigned   bit13:1 
       unsigned   bit14:1 
       unsigned   bit15:1 
    bit
    -

    Detailed Description

    +

    Detailed Description

    Definition at line 55 of file bit_access.h.

    -

    Member Data Documentation

    +

    Member Data Documentation

    ◆ all

    @@ -426,15 +401,23 @@ struct { 

    The documentation for this union was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h
    + + diff --git a/Doc/html/unionuint32___bit_type_def-members.html b/Doc/html/unionuint32___bit_type_def-members.html index 1ebc9db..e728915 100644 --- a/Doc/html/unionuint32___bit_type_def-members.html +++ b/Doc/html/unionuint32___bit_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/unionuint32___bit_type_def.html b/Doc/html/unionuint32___bit_type_def.html index fbb4745..05761c6 100644 --- a/Doc/html/unionuint32___bit_type_def.html +++ b/Doc/html/unionuint32___bit_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: uint32_BitTypeDef Union Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    uint32_BitTypeDef Union Reference
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +

    Public Attributes

    uint32_t all
     
    +
    struct { 
     
       unsigned   bit0:1 
     
       unsigned   bit1:1 
     
       unsigned   bit2:1 
     
       unsigned   bit3:1 
     
       unsigned   bit4:1 
     
       unsigned   bit5:1 
     
       unsigned   bit6:1 
     
       unsigned   bit7:1 
     
       unsigned   bit8:1 
     
       unsigned   bit9:1 
     
       unsigned   bit10:1 
     
       unsigned   bit11:1 
     
       unsigned   bit12:1 
     
       unsigned   bit13:1 
     
       unsigned   bit14:1 
     
       unsigned   bit15:1 
     
       unsigned   bit16:1 
     
       unsigned   bit17:1 
     
       unsigned   bit18:1 
     
       unsigned   bit19:1 
     
       unsigned   bit20:1 
     
       unsigned   bit21:1 
     
       unsigned   bit22:1 
     
       unsigned   bit23:1 
     
       unsigned   bit24:1 
     
       unsigned   bit25:1 
     
       unsigned   bit26:1 
     
       unsigned   bit27:1 
     
       unsigned   bit28:1 
     
       unsigned   bit29:1 
     
       unsigned   bit30:1 
     
       unsigned   bit31:1 
     
    bit 
     
       unsigned   bit0:1 
       unsigned   bit1:1 
       unsigned   bit2:1 
       unsigned   bit3:1 
       unsigned   bit4:1 
       unsigned   bit5:1 
       unsigned   bit6:1 
       unsigned   bit7:1 
       unsigned   bit8:1 
       unsigned   bit9:1 
       unsigned   bit10:1 
       unsigned   bit11:1 
       unsigned   bit12:1 
       unsigned   bit13:1 
       unsigned   bit14:1 
       unsigned   bit15:1 
       unsigned   bit16:1 
       unsigned   bit17:1 
       unsigned   bit18:1 
       unsigned   bit19:1 
       unsigned   bit20:1 
       unsigned   bit21:1 
       unsigned   bit22:1 
       unsigned   bit23:1 
       unsigned   bit24:1 
       unsigned   bit25:1 
       unsigned   bit26:1 
       unsigned   bit27:1 
       unsigned   bit28:1 
       unsigned   bit29:1 
       unsigned   bit30:1 
       unsigned   bit31:1 
    bit
    -

    Detailed Description

    +

    Detailed Description

    Definition at line 80 of file bit_access.h.

    -

    Member Data Documentation

    +

    Member Data Documentation

    ◆ all

    @@ -714,15 +673,23 @@ struct { 

    The documentation for this union was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h
    + + diff --git a/Doc/html/unionuint64___bit_type_def-members.html b/Doc/html/unionuint64___bit_type_def-members.html index 39f8418..aa8f0ea 100644 --- a/Doc/html/unionuint64___bit_type_def-members.html +++ b/Doc/html/unionuint64___bit_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/unionuint64___bit_type_def.html b/Doc/html/unionuint64___bit_type_def.html index 7f31bd5..d9aa7f7 100644 --- a/Doc/html/unionuint64___bit_type_def.html +++ b/Doc/html/unionuint64___bit_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: uint64_BitTypeDef Union Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    uint64_BitTypeDef Union Reference
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +

    Public Attributes

    uint64_t all
     
    +
    struct { 
     
       unsigned   bit0:1 
     
       unsigned   bit1:1 
     
       unsigned   bit2:1 
     
       unsigned   bit3:1 
     
       unsigned   bit4:1 
     
       unsigned   bit5:1 
     
       unsigned   bit6:1 
     
       unsigned   bit7:1 
     
       unsigned   bit8:1 
     
       unsigned   bit9:1 
     
       unsigned   bit10:1 
     
       unsigned   bit11:1 
     
       unsigned   bit12:1 
     
       unsigned   bit13:1 
     
       unsigned   bit14:1 
     
       unsigned   bit15:1 
     
       unsigned   bit16:1 
     
       unsigned   bit17:1 
     
       unsigned   bit18:1 
     
       unsigned   bit19:1 
     
       unsigned   bit20:1 
     
       unsigned   bit21:1 
     
       unsigned   bit22:1 
     
       unsigned   bit23:1 
     
       unsigned   bit24:1 
     
       unsigned   bit25:1 
     
       unsigned   bit26:1 
     
       unsigned   bit27:1 
     
       unsigned   bit28:1 
     
       unsigned   bit29:1 
     
       unsigned   bit30:1 
     
       unsigned   bit31:1 
     
       unsigned   bit32:1 
     
       unsigned   bit33:1 
     
       unsigned   bit34:1 
     
       unsigned   bit35:1 
     
       unsigned   bit36:1 
     
       unsigned   bit37:1 
     
       unsigned   bit38:1 
     
       unsigned   bit39:1 
     
       unsigned   bit40:1 
     
       unsigned   bit41:1 
     
       unsigned   bit42:1 
     
       unsigned   bit43:1 
     
       unsigned   bit44:1 
     
       unsigned   bit45:1 
     
       unsigned   bit46:1 
     
       unsigned   bit47:1 
     
       unsigned   bit48:1 
     
       unsigned   bit49:1 
     
       unsigned   bit50:1 
     
       unsigned   bit51:1 
     
       unsigned   bit52:1 
     
       unsigned   bit53:1 
     
       unsigned   bit54:1 
     
       unsigned   bit55:1 
     
       unsigned   bit56:1 
     
       unsigned   bit57:1 
     
       unsigned   bit58:1 
     
       unsigned   bit59:1 
     
       unsigned   bit60:1 
     
       unsigned   bit61:1 
     
       unsigned   bit62:1 
     
       unsigned   bit63:1 
     
    bit 
     
       unsigned   bit0:1 
       unsigned   bit1:1 
       unsigned   bit2:1 
       unsigned   bit3:1 
       unsigned   bit4:1 
       unsigned   bit5:1 
       unsigned   bit6:1 
       unsigned   bit7:1 
       unsigned   bit8:1 
       unsigned   bit9:1 
       unsigned   bit10:1 
       unsigned   bit11:1 
       unsigned   bit12:1 
       unsigned   bit13:1 
       unsigned   bit14:1 
       unsigned   bit15:1 
       unsigned   bit16:1 
       unsigned   bit17:1 
       unsigned   bit18:1 
       unsigned   bit19:1 
       unsigned   bit20:1 
       unsigned   bit21:1 
       unsigned   bit22:1 
       unsigned   bit23:1 
       unsigned   bit24:1 
       unsigned   bit25:1 
       unsigned   bit26:1 
       unsigned   bit27:1 
       unsigned   bit28:1 
       unsigned   bit29:1 
       unsigned   bit30:1 
       unsigned   bit31:1 
       unsigned   bit32:1 
       unsigned   bit33:1 
       unsigned   bit34:1 
       unsigned   bit35:1 
       unsigned   bit36:1 
       unsigned   bit37:1 
       unsigned   bit38:1 
       unsigned   bit39:1 
       unsigned   bit40:1 
       unsigned   bit41:1 
       unsigned   bit42:1 
       unsigned   bit43:1 
       unsigned   bit44:1 
       unsigned   bit45:1 
       unsigned   bit46:1 
       unsigned   bit47:1 
       unsigned   bit48:1 
       unsigned   bit49:1 
       unsigned   bit50:1 
       unsigned   bit51:1 
       unsigned   bit52:1 
       unsigned   bit53:1 
       unsigned   bit54:1 
       unsigned   bit55:1 
       unsigned   bit56:1 
       unsigned   bit57:1 
       unsigned   bit58:1 
       unsigned   bit59:1 
       unsigned   bit60:1 
       unsigned   bit61:1 
       unsigned   bit62:1 
       unsigned   bit63:1 
    bit
    -

    Detailed Description

    +

    Detailed Description

    Definition at line 97 of file bit_access.h.

    -

    Member Data Documentation

    +

    Member Data Documentation

    ◆ all

    @@ -1290,15 +1217,23 @@ struct { 

    The documentation for this union was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h
    + + diff --git a/Doc/html/unionuint8___bit_type_def-members.html b/Doc/html/unionuint8___bit_type_def-members.html index 4e59f97..d5c72bf 100644 --- a/Doc/html/unionuint8___bit_type_def-members.html +++ b/Doc/html/unionuint8___bit_type_def-members.html @@ -3,7 +3,7 @@ - + MyLibs: Member List @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { + diff --git a/Doc/html/unionuint8___bit_type_def.html b/Doc/html/unionuint8___bit_type_def.html index 5f54a9c..53a402f 100644 --- a/Doc/html/unionuint8___bit_type_def.html +++ b/Doc/html/unionuint8___bit_type_def.html @@ -3,7 +3,7 @@ - + MyLibs: uint8_BitTypeDef Union Reference @@ -11,7 +11,6 @@ - @@ -44,21 +43,20 @@ MathJax.Hub.Config({ - + + @@ -73,10 +71,9 @@ $(function() { +
    -
    uint8_BitTypeDef Union Reference
    - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + +

    +

    Public Attributes

    uint8_t all
     
    +
    struct { 
     
       unsigned   bit0:1 
     
       unsigned   bit1:1 
     
       unsigned   bit2:1 
     
       unsigned   bit3:1 
     
       unsigned   bit4:1 
     
       unsigned   bit5:1 
     
       unsigned   bit6:1 
     
       unsigned   bit7:1 
     
    bit 
     
       unsigned   bit0:1 
       unsigned   bit1:1 
       unsigned   bit2:1 
       unsigned   bit3:1 
       unsigned   bit4:1 
       unsigned   bit5:1 
       unsigned   bit6:1 
       unsigned   bit7:1 
    bit
    -

    Detailed Description

    +

    Detailed Description

    Definition at line 39 of file bit_access.h.

    -

    Member Data Documentation

    +

    Member Data Documentation

    ◆ all

    @@ -282,15 +265,23 @@ struct { 

    The documentation for this union was generated from the following file:
      -
    • F:/Work/Projects/STM/.Elementary/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h
    • +
    • E:/.WORK/STM32/STM32_ExtendedLibs/MyLibsGeneral/Inc/bit_access.h
    + + diff --git a/Doc/latex/Makefile b/Doc/latex/Makefile index 7f82972..8e14614 100644 --- a/Doc/latex/Makefile +++ b/Doc/latex/Makefile @@ -9,19 +9,34 @@ all: $(MANUAL_FILE).pdf pdf: $(MANUAL_FILE).pdf $(MANUAL_FILE).pdf: clean $(MANUAL_FILE).tex - $(LATEX_CMD) $(MANUAL_FILE) + $(LATEX_CMD) $(MANUAL_FILE) || \ + if [ $$? != 0 ] ; then \ + \echo "Please consult $(MANUAL_FILE).log to see the error messages" ; \ + false; \ + fi $(MKIDX_CMD) $(MANUAL_FILE).idx - $(LATEX_CMD) $(MANUAL_FILE) + $(LATEX_CMD) $(MANUAL_FILE) || \ + if [ $$? != 0 ] ; then \ + \echo "Please consult $(MANUAL_FILE).log to see the error messages" ; \ + false; \ + fi latex_count=$(LATEX_COUNT) ; \ while grep -E -s 'Rerun (LaTeX|to get cross-references right|to get bibliographical references right)' $(MANUAL_FILE).log && [ $$latex_count -gt 0 ] ;\ do \ echo "Rerunning latex...." ;\ - $(LATEX_CMD) $(MANUAL_FILE) ;\ + $(LATEX_CMD) $(MANUAL_FILE) || \ + if [ $$? != 0 ] ; then \ + \echo "Please consult $(MANUAL_FILE).log to see the error messages" ; \ + false; \ + fi; \ latex_count=`expr $$latex_count - 1` ;\ done $(MKIDX_CMD) $(MANUAL_FILE).idx - $(LATEX_CMD) $(MANUAL_FILE) - + $(LATEX_CMD) $(MANUAL_FILE) || \ + if [ $$? != 0 ] ; then \ + \echo "Please consult $(MANUAL_FILE).log to see the error messages" ; \ + false; \ + fi clean: rm -f *.ps *.dvi *.aux *.toc *.idx *.ind *.ilg *.log *.out *.brf *.blg *.bbl $(MANUAL_FILE).pdf diff --git a/Doc/latex/____general__flash_8c_source.tex b/Doc/latex/____general__flash_8c_source.tex index b82fafe..f904808 100644 --- a/Doc/latex/____general__flash_8c_source.tex +++ b/Doc/latex/____general__flash_8c_source.tex @@ -1,8 +1,8 @@ \doxysection{\+\_\+\+\_\+general\+\_\+flash.\+c} -\hypertarget{____general__flash_8c_source}{}\label{____general__flash_8c_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/\_\_general\_flash.c@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/\_\_general\_flash.c}} +\hypertarget{____general__flash_8c_source}{}\label{____general__flash_8c_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/\_\_general\_flash.c@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/\_\_general\_flash.c}} \begin{DoxyCode}{0} -\DoxyCodeLine{\Hypertarget{____general__flash_8c_source_l00001}00001\ \textcolor{preprocessor}{\#include\ "{}general\_flash.h"{}}} +\DoxyCodeLine{\Hypertarget{____general__flash_8c_source_l00001}00001\ \textcolor{preprocessor}{\#include\ "{}\_\_general\_flash.h"{}}} \DoxyCodeLine{\Hypertarget{____general__flash_8c_source_l00002}00002\ FLASH\_EraseInitTypeDef\ EraseInitStruct;} \DoxyCodeLine{\Hypertarget{____general__flash_8c_source_l00003}00003\ \textcolor{keyword}{extern}\ HAL\_StatusTypeDef\ res\_hal;} \DoxyCodeLine{\Hypertarget{____general__flash_8c_source_l00004}00004\ \textcolor{keywordtype}{unsigned}\ CRC\_Update;} diff --git a/Doc/latex/____general__flash_8h_source.tex b/Doc/latex/____general__flash_8h_source.tex index 788727d..2922838 100644 --- a/Doc/latex/____general__flash_8h_source.tex +++ b/Doc/latex/____general__flash_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{\+\_\+\+\_\+general\+\_\+flash.\+h} -\hypertarget{____general__flash_8h_source}{}\label{____general__flash_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/\_\_general\_flash.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/\_\_general\_flash.h}} +\hypertarget{____general__flash_8h_source}{}\label{____general__flash_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/\_\_general\_flash.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/\_\_general\_flash.h}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00001}00001\ \textcolor{comment}{/**************************************************************************}} @@ -11,28 +11,28 @@ \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00007}00007\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00008}00008\ \textcolor{comment}{//////////////////////////////////////////////////////////////////////}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00009}00009\ \textcolor{comment}{/////////////////////////-\/-\/-\/USER\ SETTINGS-\/-\/-\//////////////////////////}} -\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00010}00010\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00010}00010\ } \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00011}00011\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00012}00012\ \textcolor{comment}{/////////////////////////-\/-\/-\/USER\ SETTINGS-\/-\/-\//////////////////////////}} -\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00013}00013\ \textcolor{comment}{}\textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{mylibs__defs_8h}{mylibs\_defs.h}}"{}}} +\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00013}00013\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{mylibs__defs_8h}{mylibs\_defs.h}}"{}}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00014}00014\ } \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00015}00015\ } \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00016}00016\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00017}00017\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00018}00018\ \textcolor{comment}{////////////////////////////-\/-\/-\/DEFINES-\/-\/-\/////////////////////////////}} -\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00019}00019\ \textcolor{comment}{}\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00019}00019\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00020}00020\ \textcolor{comment}{////////////////////////////-\/-\/-\/DEFINES-\/-\/-\/////////////////////////////}} -\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00021}00021\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00021}00021\ } \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00022}00022\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00023}00023\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00024}00024\ \textcolor{comment}{///////////////////////-\/-\/-\/STRUCTURES\ \&\ ENUMS-\/-\/-\///////////////////////}} -\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00025}00025\ \textcolor{comment}{}\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00025}00025\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00026}00026\ \textcolor{comment}{///////////////////////-\/-\/-\/STRUCTURES\ \&\ ENUMS-\/-\/-\///////////////////////}} -\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00027}00027\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00027}00027\ } \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00028}00028\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00029}00029\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00030}00030\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} -\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00031}00031\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00031}00031\ } \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00032}00032\ HAL\_StatusTypeDef\ FLASH\_Enable\_DualBankMode(\textcolor{keywordtype}{void});} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00033}00033\ HAL\_StatusTypeDef\ FLASH\_WriteProtection(uint32\_t\ BankN,\ uint32\_t\ WriteProtection);} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00034}00034\ \textcolor{comment}{/*\ functions\ for\ reading\ bytes/halswords/words\ */}} @@ -44,7 +44,7 @@ \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00040}00040\ HAL\_StatusTypeDef\ FLASH\_Write\_HalfWord(uint32\_t\ Address,\ uint16\_t\ Data);} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00041}00041\ HAL\_StatusTypeDef\ FLASH\_Write\_Word(uint32\_t\ Address,\ uint32\_t\ Data);\textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00042}00042\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} -\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00043}00043\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00043}00043\ } \DoxyCodeLine{\Hypertarget{____general__flash_8h_source_l00044}00044\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ \_\_FLASH\_GENERAL\_H\_}} \end{DoxyCode} diff --git a/Doc/latex/annotated.tex b/Doc/latex/annotated.tex index 6cc7cee..7c59474 100644 --- a/Doc/latex/annotated.tex +++ b/Doc/latex/annotated.tex @@ -5,10 +5,10 @@ Here are the classes, structs, unions and interfaces with brief descriptions\+:\ \item\contentsline{section}{\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\+\_\+\+Switch\+Type\+Def}} \\*Структура кнопки }{\pageref{struct_g_p_i_o___switch_type_def}}{} \item\contentsline{section}{\mbox{\hyperlink{struct_h_f___stack_frame__t}{HF\+\_\+\+Stack\+Frame\+\_\+t}} \\*Контекст стек-\/фрейма процессора при Hard\+Fault }{\pageref{struct_h_f___stack_frame__t}}{} \item\contentsline{section}{\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\+\_\+\+Flash\+Header\+\_\+t}} \\*Структура RTT, которая будет положена в Flash }{\pageref{struct_r_t_t___flash_header__t}}{} -\item\contentsline{section}{\mbox{\hyperlink{struct_s_p_i___settings_type_def}{SPI\+\_\+\+Settings\+Type\+Def}} }{\pageref{struct_s_p_i___settings_type_def}}{} +\item\contentsline{section}{\mbox{\hyperlink{struct_s_p_i___settings_type_def}{SPI\+\_\+\+Settings\+Type\+Def}} \\*Структура настроек SPI }{\pageref{struct_s_p_i___settings_type_def}}{} \item\contentsline{section}{\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \\*Структура инициализации енкодера }{\pageref{struct_t_i_m___encoder_type_def}}{} \item\contentsline{section}{\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\+\_\+\+Settings\+Type\+Def}} \\*Структура инициализации таймера }{\pageref{struct_t_i_m___settings_type_def}}{} -\item\contentsline{section}{\mbox{\hyperlink{struct_u_a_r_t___settings_type_def}{UART\+\_\+\+Settings\+Type\+Def}} }{\pageref{struct_u_a_r_t___settings_type_def}}{} +\item\contentsline{section}{\mbox{\hyperlink{struct_u_a_r_t___settings_type_def}{UART\+\_\+\+Settings\+Type\+Def}} \\*Структура настроек UART }{\pageref{struct_u_a_r_t___settings_type_def}}{} \item\contentsline{section}{\mbox{\hyperlink{unionuint16___bit_type_def}{uint16\+\_\+\+Bit\+Type\+Def}} }{\pageref{unionuint16___bit_type_def}}{} \item\contentsline{section}{\mbox{\hyperlink{unionuint32___bit_type_def}{uint32\+\_\+\+Bit\+Type\+Def}} }{\pageref{unionuint32___bit_type_def}}{} \item\contentsline{section}{\mbox{\hyperlink{unionuint64___bit_type_def}{uint64\+\_\+\+Bit\+Type\+Def}} }{\pageref{unionuint64___bit_type_def}}{} diff --git a/Doc/latex/bit__access_8h.tex b/Doc/latex/bit__access_8h.tex index 03df7db..4ce7302 100644 --- a/Doc/latex/bit__access_8h.tex +++ b/Doc/latex/bit__access_8h.tex @@ -1,23 +1,25 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/bit\+\_\+access.h File Reference} -\hypertarget{bit__access_8h}{}\label{bit__access_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/bit\_access.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/bit\_access.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/bit\+\_\+access.h File Reference} +\hypertarget{bit__access_8h}{}\label{bit__access_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/bit\_access.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/bit\_access.h}} Заголочный файл для дефайнов битового доступа. {\ttfamily \#include "{}mylibs\+\_\+defs.\+h"{}}\newline -Include dependency graph for bit\+\_\+access.\+h\+:\nopagebreak +Include dependency graph for bit\+\_\+access.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=233pt]{bit__access_8h__incl} +\includegraphics[width=229pt]{bit__access_8h__incl} \end{center} \end{figure} -This graph shows which files directly or indirectly include this file\+:\nopagebreak +This graph shows which files directly or indirectly include this file\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=233pt]{bit__access_8h__dep__incl} +\includegraphics[width=229pt]{bit__access_8h__dep__incl} \end{center} \end{figure} \doxysubsubsection*{Classes} @@ -34,13 +36,13 @@ union \mbox{\hyperlink{unionuint64___bit_type_def}{uint64\+\_\+\+Bit\+Type\+Def} \doxysubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga57dc3bb3472a66fc92312f89d42d2396}{uint8\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+)~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint8___bit_type_def}{uint8\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+ +\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga57dc3bb3472a66fc92312f89d42d2396}{uint8\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+) \begin{DoxyCompactList}\small\item\em Получить n-\/й бит из uint8\+\_\+t. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga6a122b536ad99ae611c8cf01437af086}{uint16\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+)~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint16___bit_type_def}{uint16\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+ +\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga6a122b536ad99ae611c8cf01437af086}{uint16\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+) \begin{DoxyCompactList}\small\item\em Получить n-\/й бит из uint16\+\_\+t. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_gafaa2080168b1b6f7281e8bfabab022d1}{uint32\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+)~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint32___bit_type_def}{uint32\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+ +\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_gafaa2080168b1b6f7281e8bfabab022d1}{uint32\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+) \begin{DoxyCompactList}\small\item\em Получить n-\/й бит из uint32\+\_\+t. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga47eb69ce9330a1c73fe8031240f02f0a}{uint64\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+)~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint64___bit_type_def}{uint64\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+ +\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga47eb69ce9330a1c73fe8031240f02f0a}{uint64\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+) \begin{DoxyCompactList}\small\item\em Получить n-\/й бит из uint64\+\_\+t. \end{DoxyCompactList}\end{DoxyCompactItemize} diff --git a/Doc/latex/bit__access_8h__dep__incl.md5 b/Doc/latex/bit__access_8h__dep__incl.md5 index 9c52014..d668a32 100644 --- a/Doc/latex/bit__access_8h__dep__incl.md5 +++ b/Doc/latex/bit__access_8h__dep__incl.md5 @@ -1 +1 @@ -f100d5df8d78acb2e79ae9c3faf7fd33 \ No newline at end of file +a0db7c46e6c8e84aaed5bb4becf5bf9c \ No newline at end of file diff --git a/Doc/latex/bit__access_8h__dep__incl.pdf b/Doc/latex/bit__access_8h__dep__incl.pdf index 43600f6..413e18b 100644 Binary files a/Doc/latex/bit__access_8h__dep__incl.pdf and b/Doc/latex/bit__access_8h__dep__incl.pdf differ diff --git a/Doc/latex/bit__access_8h__incl.md5 b/Doc/latex/bit__access_8h__incl.md5 index cb6e7b6..8982918 100644 --- a/Doc/latex/bit__access_8h__incl.md5 +++ b/Doc/latex/bit__access_8h__incl.md5 @@ -1 +1 @@ -201ec235709cefdcc9370ba71d46f128 \ No newline at end of file +04aae01d1a86d60c14b0ea57bbf11647 \ No newline at end of file diff --git a/Doc/latex/bit__access_8h__incl.pdf b/Doc/latex/bit__access_8h__incl.pdf index 4f94bcf..c3afe03 100644 Binary files a/Doc/latex/bit__access_8h__incl.pdf and b/Doc/latex/bit__access_8h__incl.pdf differ diff --git a/Doc/latex/bit__access_8h_source.tex b/Doc/latex/bit__access_8h_source.tex index 53b023f..f5e2fec 100644 --- a/Doc/latex/bit__access_8h_source.tex +++ b/Doc/latex/bit__access_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{bit\+\_\+access.\+h} -\hypertarget{bit__access_8h_source}{}\label{bit__access_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/bit\_access.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/bit\_access.h}} +\hypertarget{bit__access_8h_source}{}\label{bit__access_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/bit\_access.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/bit\_access.h}} \mbox{\hyperlink{bit__access_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{bit__access_8h_source_l00001}00001\ \textcolor{comment}{/**\ }} diff --git a/Doc/latex/doxygen.sty b/Doc/latex/doxygen.sty index 4bfc17f..6d8fc7b 100644 --- a/Doc/latex/doxygen.sty +++ b/Doc/latex/doxygen.sty @@ -122,6 +122,7 @@ % Used by @code ... @endcode \newenvironment{DoxyCode}[1]{% \par% + \vspace{2pt}% \scriptsize% \normalfont\ttfamily% \rightskip0pt plus 1fil% @@ -129,14 +130,14 @@ \settowidth{\CodeWidthChar}{?}% \settoheight{\CodeHeightChar}{?}% \setlength{\parskip}{0ex plus 0ex minus 0ex}% - \ifthenelse{\equal{#1}{0}} - { + \ifthenelse{\equal{#1}{0}}% + {% {\lccode`~32 \lowercase{\global\let~}\NiceSpace}\obeyspaces% - } - { + }% + {% {\lccode`~32 \lowercase{\global\let~}}\obeyspaces% - } - + }% + \vspace{2pt}% }{% \normalfont% \normalsize% @@ -199,6 +200,10 @@ \setlist[DoxyItemize,3]{label=\textasteriskcentered} \setlist[DoxyItemize,4]{label=\textperiodcentered} +% Used for check boxes +\newcommand{\DoxyUnchecked}{$\square$} +\newcommand{\DoxyChecked}{\rlap{\raisebox{0.3ex}{\hspace{0.4ex}\tiny \checkmark}}$\square$} + % Used by description lists (using
    ...
    ) \newenvironment{DoxyDescription}{% \description% @@ -236,6 +241,13 @@ \end{DoxyDesc}% } +% Used by @important +\newenvironment{DoxyImportant}[1]{% + \begin{DoxyDesc}{#1}% +}{% + \end{DoxyDesc}% +} + % Used by @author and @authors \newenvironment{DoxyAuthor}[1]{% \begin{DoxyDesc}{#1}% @@ -372,14 +384,16 @@ } % Used for fields simple class style enums -\newenvironment{DoxyEnumFields}[1]{% +\newenvironment{DoxyEnumFields}[2][]{% \tabulinesep=1mm% \par% - \begin{longtabu*}spread 0pt [l]{|X[-1,r]|X[-1,l]|}% - \multicolumn{2}{l}{\hspace{-6pt}\bfseries\fontseries{bc}\selectfont\color{darkgray} #1}\\[1ex]% + \ifthenelse{\equal{#1}{2}}% + {\begin{longtabu*}spread 0pt [l]{|X[-1,r]|X[-1,l]|}}% + {\begin{longtabu*}spread 0pt [l]{|X[-1,l]|X[-1,r]|X[-1,l]|}}% with init value + \multicolumn{2}{l}{\hspace{-6pt}\bfseries\fontseries{bc}\selectfont\color{darkgray} #2}\\[1ex]% \hline% \endfirsthead% - \multicolumn{2}{l}{\hspace{-6pt}\bfseries\fontseries{bc}\selectfont\color{darkgray} #1}\\[1ex]% + \multicolumn{2}{l}{\hspace{-6pt}\bfseries\fontseries{bc}\selectfont\color{darkgray} #2}\\[1ex]% \hline% \endhead% }{% @@ -389,7 +403,7 @@ % Used for parameters within a detailed function description \newenvironment{DoxyParamCaption}{% - \renewcommand{\item}[2][]{\\ \hspace*{2.0cm} ##1 {\em ##2}}% + \renewcommand{\item}[3][]{\\ \hspace*{2.0cm} ##1 {\em ##2}##3}% }{% } @@ -528,6 +542,37 @@ \mbox{\hyperlink{#1}{#2}}% } +% Used for the cite command +\newcommand{\DoxyCite}[3]{% + \ifthenelse{#3=1}% 1 with square parenthesis + { + \ifthenelse{\equal{#2}{number}}% + { \cite{#1} }% + {% + \ifthenelse{\equal{#2}{shortauthor}}% + { \citetext{\citeauthor{#1}} }% + {% + \ifthenelse{\equal{#2}{year}}% + { \citeyearpar{#1} }% + {}% + }% + }% + }% + {% + \ifthenelse{\equal{#2}{number}}% + { \citealp{#1} }% + {% + \ifthenelse{\equal{#2}{shortauthor}}% + { \citeauthor{#1} }% + {% + \ifthenelse{\equal{#2}{year}}% + { \citeyear{#1} }% + {}% + }% + }% + }% +} + % Used when hyperlinks are turned on % Third argument is the SectionType, see the doxygen internal % documentation for the values (relevant: Page ... Subsubsection). @@ -639,12 +684,12 @@ {1.5ex \@plus .2ex}% {\raggedright\normalfont\normalsize\bfseries}} -\newcommand\l@subsubsubsection{\@dottedtocline{4}{6.1em}{7.8em}} -\newcommand\l@subsubsubsubsection{\@dottedtocline{5}{6.1em}{9.4em}} -\newcommand\l@subsubsubsubsubsection{\@dottedtocline{6}{6.1em}{11em}} -\newcommand\l@subsubsubsubsubsubsection{\@dottedtocline{7}{6.1em}{12.6em}} -\renewcommand\l@paragraph{\@dottedtocline{8}{6.1em}{14.2em}} -\renewcommand\l@subparagraph{\@dottedtocline{9}{6.1em}{15.8em}} +\newcommand\l@subsubsubsection{\@dottedtocline{4}{10.0em}{7.8em}} +\newcommand\l@subsubsubsubsection{\@dottedtocline{5}{13.0em}{9.4em}} +\newcommand\l@subsubsubsubsubsection{\@dottedtocline{6}{15.0em}{11em}} +\newcommand\l@subsubsubsubsubsubsection{\@dottedtocline{7}{18.0em}{12.6em}} +\renewcommand\l@paragraph{\@dottedtocline{8}{21.0em}{14.2em}} +\renewcommand\l@subparagraph{\@dottedtocline{9}{24.0em}{15.8em}} \makeatother % the sectsty doesn't look to be maintained but gives, in our case, some warning like: % LaTeX Warning: Command \underline has changed. @@ -677,10 +722,16 @@ \doxysubparagraphfont{#1}% \doxyminisecfont{#1}}% % Define caption that is also suitable in a table +% for usage with hyperlinks \makeatletter \def\doxyfigcaption{% \H@refstepcounter{figure}% \@dblarg{\@caption{figure}}} + +% for usage without hyperlinks +\def\doxyfigcaptionnolink{% +\refstepcounter{figure}% +\@dblarg{\@caption{figure}}} \makeatother % Define alpha enumarative names for counters > 26 diff --git a/Doc/latex/evolve__optimizer_8h.tex b/Doc/latex/evolve__optimizer_8h.tex index eca0dbc..bc83850 100644 --- a/Doc/latex/evolve__optimizer_8h.tex +++ b/Doc/latex/evolve__optimizer_8h.tex @@ -1,5 +1,5 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/evolve\+\_\+optimizer.h File Reference} -\hypertarget{evolve__optimizer_8h}{}\label{evolve__optimizer_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/evolve\_optimizer.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/evolve\_optimizer.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/evolve\+\_\+optimizer.h File Reference} +\hypertarget{evolve__optimizer_8h}{}\label{evolve__optimizer_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/evolve\_optimizer.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/evolve\_optimizer.h}} Заголовочный файл для адаптивного подбора параметров @@ -8,18 +8,20 @@ {\ttfamily \#include "{}mylibs\+\_\+defs.\+h"{}}\newline {\ttfamily \#include $<$stdint.\+h$>$}\newline {\ttfamily \#include $<$stdlib.\+h$>$}\newline -Include dependency graph for evolve\+\_\+optimizer.\+h\+:\nopagebreak +Include dependency graph for evolve\+\_\+optimizer.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode \includegraphics[width=295pt]{evolve__optimizer_8h__incl} \end{center} \end{figure} -This graph shows which files directly or indirectly include this file\+:\nopagebreak +This graph shows which files directly or indirectly include this file\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=233pt]{evolve__optimizer_8h__dep__incl} +\includegraphics[width=229pt]{evolve__optimizer_8h__dep__incl} \end{center} \end{figure} \doxysubsubsection*{Classes} @@ -30,12 +32,10 @@ struct \mbox{\hyperlink{struct_evolve_optimizer__t}{Evolve\+Optimizer\+\_\+t}} \doxysubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga83abbcabaff9111c03ae2475ee72ea3e}{PARAM\+\_\+\+SCALE}}(x, min\+\_\+val, max\+\_\+val)~(((float)(x) -\/ (float)(min\+\_\+val)) / ((float)(max\+\_\+val) -\/ (float)(min\+\_\+val))) +\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga83abbcabaff9111c03ae2475ee72ea3e}{PARAM\+\_\+\+SCALE}}(x, min\+\_\+val, max\+\_\+val) \begin{DoxyCompactList}\small\item\em Линейное масштабирование x из диапазона \mbox{[}min\+\_\+val, max\+\_\+val\mbox{]} в диапазон \mbox{[}0, 1) \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3}{PARAM\+\_\+\+UNSCALE}}(val, min\+\_\+val, max\+\_\+val)~(((float)(val)) \texorpdfstring{$\ast$}{*} ((float)(max\+\_\+val) -\/ (float)(min\+\_\+val)) + (float)(min\+\_\+val)) +\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3}{PARAM\+\_\+\+UNSCALE}}(val, min\+\_\+val, max\+\_\+val) \begin{DoxyCompactList}\small\item\em Обратное линейное масштабирование значения из \mbox{[}0, 1) в диапазон \mbox{[}min\+\_\+val, max\+\_\+val\mbox{]}. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga9c853b02c22f26023c34d1d404b6d653}{local\+\_\+time}}()~HAL\+\_\+\+Get\+Tick() -\begin{DoxyCompactList}\small\item\em Локальное время \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6}{EVOLVE\+\_\+\+MUTATION\+\_\+\+MIN\+\_\+\+PCT}}~10 \begin{DoxyCompactList}\small\item\em Минимальная мутация (в процентах от Loss) \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga861c1c6a503c21441abcec0d57b848bc}{EVOLVE\+\_\+\+MUTATION\+\_\+\+MAX\+\_\+\+PCT}}~100 diff --git a/Doc/latex/evolve__optimizer_8h__dep__incl.md5 b/Doc/latex/evolve__optimizer_8h__dep__incl.md5 index b0eb260..17ac4cc 100644 --- a/Doc/latex/evolve__optimizer_8h__dep__incl.md5 +++ b/Doc/latex/evolve__optimizer_8h__dep__incl.md5 @@ -1 +1 @@ -ef7ed390ff839d8a446957116f861503 \ No newline at end of file +a385857375106a9066dc97059b8e5f66 \ No newline at end of file diff --git a/Doc/latex/evolve__optimizer_8h__dep__incl.pdf b/Doc/latex/evolve__optimizer_8h__dep__incl.pdf index 3145452..80575f5 100644 Binary files a/Doc/latex/evolve__optimizer_8h__dep__incl.pdf and b/Doc/latex/evolve__optimizer_8h__dep__incl.pdf differ diff --git a/Doc/latex/evolve__optimizer_8h__incl.md5 b/Doc/latex/evolve__optimizer_8h__incl.md5 index 453cf70..b0017bc 100644 --- a/Doc/latex/evolve__optimizer_8h__incl.md5 +++ b/Doc/latex/evolve__optimizer_8h__incl.md5 @@ -1 +1 @@ -84a2c30c997cd3aae7d0053ac8a120d1 \ No newline at end of file +e567d0680734fcff06b08511863dc20f \ No newline at end of file diff --git a/Doc/latex/evolve__optimizer_8h__incl.pdf b/Doc/latex/evolve__optimizer_8h__incl.pdf index 77ef99f..6ecb84a 100644 Binary files a/Doc/latex/evolve__optimizer_8h__incl.pdf and b/Doc/latex/evolve__optimizer_8h__incl.pdf differ diff --git a/Doc/latex/evolve__optimizer_8h_source.tex b/Doc/latex/evolve__optimizer_8h_source.tex index 9f5a03b..36909b1 100644 --- a/Doc/latex/evolve__optimizer_8h_source.tex +++ b/Doc/latex/evolve__optimizer_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{evolve\+\_\+optimizer.\+h} -\hypertarget{evolve__optimizer_8h_source}{}\label{evolve__optimizer_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/evolve\_optimizer.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/evolve\_optimizer.h}} +\hypertarget{evolve__optimizer_8h_source}{}\label{evolve__optimizer_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/evolve\_optimizer.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/evolve\_optimizer.h}} \mbox{\hyperlink{evolve__optimizer_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00001}00001\ \textcolor{comment}{/**}} @@ -84,7 +84,7 @@ \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00080}00080\ \textcolor{preprocessor}{(((float)(val))\ *\ ((float)(max\_val)\ -\/\ (float)(min\_val))\ +\ (float)(min\_val))}} \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00081}00081\ } \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00082}00082\ \textcolor{preprocessor}{\#ifndef\ local\_time}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00083}\mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga9c853b02c22f26023c34d1d404b6d653}{00083}}\ \textcolor{preprocessor}{\#define\ local\_time()\ \ HAL\_GetTick()\ }\textcolor{comment}{///<\ Локальное\ время}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00083}00083\ \textcolor{preprocessor}{\#define\ local\_time()\ \ HAL\_GetTick()\ }\textcolor{comment}{///<\ Локальное\ время}} \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00084}00084\ \textcolor{preprocessor}{\#endif}} \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00085}00085\ } \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00086}00086\ } @@ -105,229 +105,240 @@ \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00101}00101\ \textcolor{comment}{\ \ */}} \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00102}\mbox{\hyperlink{struct_evolve_optimizer__t}{00102}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{} \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00103}\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{00103}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Коэффициент\ насколько\ стабильная\ популяция\ (0..1)(@ref\ n\_cand)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00104}\mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{00104}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{n\_params}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Количество\ параметров}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00105}\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{00105}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Количество\ кандидатов\ в\ популяции}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00106}\mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{00106}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{n\_best}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Количество\ лучших,\ усредняемых}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00107}\mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}{00107}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}{mutation\_amp}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Амплитуда\ мутации\ (0..1)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00108}\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{00108}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Индекс\ кандидата\ для\ обработки}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00109}\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{00109}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ loss[\mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}];\ \ \ \ \textcolor{comment}{///<\ Loss\ для\ каждого\ кандидата}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00110}\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{00110}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ candidates[\mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}][\mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee}{EVOLVE\_MAX\_PARAMS}}];\ \textcolor{comment}{///<\ Параметры\ кандидатов}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00111}\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{00111}}\ \ \ uint16\_t\ \ sorted\_idx[\mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}];\ \textcolor{comment}{///<\ Индексы\ отсортированных\ кандидатов}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00112}00112\ \}\ \mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}};} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00113}00113\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00114}00114\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00115}00115\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00116}00116\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00117}00117\ \textcolor{comment}{\ *\ @cond\ EVOLVE\_INTERNAL}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00118}00118\ \textcolor{comment}{\ */}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00119}00119\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00120}00120\ \textcolor{comment}{//\ Вспомогательный\ указатель\ для\ сортировки}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00121}00121\ \textcolor{keyword}{static}\ \mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}}\ *g\_sort\_opt;\ \textcolor{comment}{//\ глобальный\ указатель\ на\ текущий\ оптимизатор}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00122}00122\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00123}00123\ \textcolor{comment}{//\ функция\ условия\ сортировки}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00124}00124\ \textcolor{keyword}{static}\ \textcolor{keywordtype}{int}\ cmp\_idx(\textcolor{keyword}{const}\ \textcolor{keywordtype}{void}\ *a,\ \textcolor{keyword}{const}\ \textcolor{keywordtype}{void}\ *b)\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00125}00125\ \ \ \textcolor{keywordflow}{if}\ (g\_sort\_opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[*(\textcolor{keyword}{const}\ uint16\_t*)a]\ <\ g\_sort\_opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[*(\textcolor{keyword}{const}\ uint16\_t*)b])\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00126}00126\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00127}00127\ \ \ \textcolor{keywordflow}{if}\ (g\_sort\_opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[*(\textcolor{keyword}{const}\ uint16\_t*)a]\ >\ g\_sort\_opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[*(\textcolor{keyword}{const}\ uint16\_t*)b])\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00128}00128\ \ \ \ \ \textcolor{keywordflow}{return}\ 1;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00129}00129\ \ \ \textcolor{keywordflow}{return}\ 0;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00130}00130\ \}\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00131}00131\ \textcolor{comment}{/**\ @endcond\ */}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00132}00132\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00133}00133\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00134}00134\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00135}00135\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00136}00136\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00137}00137\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00138}00138\ \textcolor{comment}{\ \ *\ @brief\ Инициализация\ эволюционного\ оптимизатора.}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00139}00139\ \textcolor{comment}{\ \ *\ @param\ opt\ \ \ \ \ \ \ \ \ \ Указатель\ на\ структуру\ оптимизатора}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00140}00140\ \textcolor{comment}{\ \ *\ @param\ n\_params\ \ \ \ \ Количество\ параметров\ в\ одном\ кандидате}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00141}00141\ \textcolor{comment}{\ \ *\ @param\ n\_cand\ \ \ \ \ \ \ Количество\ кандидатов}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00142}00142\ \textcolor{comment}{\ \ *\ @param\ n\_best\ \ \ \ \ \ \ Количество\ лучших,\ усредняемых}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00143}00143\ \textcolor{comment}{\ \ *\ @param\ mutation\_amp\ Амплитуда\ мутации\ (в\ диапазоне\ 0.0–1.0)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00144}00144\ \textcolor{comment}{\ \ *\ @param\ start\_params\ Начальные\ параметры\ (в\ диапазоне\ 0.0–1.0)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00145}00145\ \textcolor{comment}{\ \ *\ @return\ 0\ \ \ —\ если\ окей,\ }} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00146}00146\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ -\/1\ \ —\ если\ ошибка}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00147}00147\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00148}\mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga4e3ea118b5b9068619c57724a925ba21}{00148}}\ \_\_STATIC\_INLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga4e3ea118b5b9068619c57724a925ba21}{EvolveOptimizer\_Init}}(\mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}}*\ opt,} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00149}00149\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ uint16\_t\ n\_params,} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00150}00150\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ uint16\_t\ n\_cand,} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00151}00151\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ uint16\_t\ n\_best,} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00152}00152\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ mutation\_amp,} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00153}00153\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}*\ start\_params)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00154}00154\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00155}00155\ \ \ \textcolor{keywordflow}{if}((opt\ ==\ NULL)\ ||\ (start\_params\ ==\ NULL))} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00156}00156\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00157}00157\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00158}00158\ \ \ \textcolor{keywordflow}{if}(n\_params\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee}{EVOLVE\_MAX\_PARAMS}})} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00159}00159\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00160}00160\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{n\_params}}\ \ \ \ \ =\ n\_params;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00161}00161\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00162}00162\ \ \ \textcolor{keywordflow}{if}(n\_cand\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}})} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00163}00163\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00164}00164\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}}\ \ \ \ \ \ \ =\ n\_cand;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00165}00165\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00166}00166\ \ \ \textcolor{keywordflow}{if}(n\_best\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}/2)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00167}00167\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00168}00168\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{n\_best}}\ \ \ \ \ \ \ =\ n\_best;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00169}00169\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00170}00170\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00171}00171\ \ \ \textcolor{keywordflow}{if}((mutation\_amp\ >\ 1)\ ||\ (mutation\_amp\ <\ 0))} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00172}00172\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00173}00173\ \ \ \textcolor{keywordflow}{if}(mutation\_amp\ <=\ 0.001f)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00174}00174\ \ \ \ \ mutation\_amp\ =\ 0.001f;\ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00175}00175\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}{mutation\_amp}}\ \ =\ mutation\_amp;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00176}00176\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00177}00177\ \ \ uint32\_t\ seed\ =\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}();} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00178}00178\ \textcolor{preprocessor}{\#ifdef\ ADC1}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00179}00179\ \ \ seed\ +=\ (ADC1-\/>DR\ \&\ 0xFF);} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00180}00180\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00181}00181\ \ \ srand(seed);} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00182}00182\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00183}00183\ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ n\_cand;\ i++)\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00184}00184\ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ j\ =\ 0;\ j\ <\ n\_params;\ j++)\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00185}00185\ \ \ \ \ \ \ \textcolor{comment}{//\ Добавляем\ случайную\ мутацию\ вокруг\ стартового\ параметра}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00186}00186\ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ base\ =\ start\_params[j];} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00187}00187\ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ inv\_randmax\ =\ 1.0f\ /\ (float)RAND\_MAX;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00188}00188\ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ noise\ =\ ((float)rand()\ *\ inv\_randmax\ *\ 2.0f\ -\/\ 1.0f)\ *\ mutation\_amp;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00189}00189\ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ =\ base\ +\ noise;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00190}00190\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ <\ 0.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00191}00191\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ >\ 1.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ =\ 1.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00192}00192\ \ \ \ \ \}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00193}00193\ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[i]\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00194}00194\ \ \ \}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00195}00195\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00196}00196\ \ \ \textcolor{keywordflow}{return}\ 0;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00197}00197\ \}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00198}00198\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00199}00199\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00200}00200\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00201}00201\ \textcolor{comment}{\ \ *\ @brief\ Один\ шаг\ эволюционного\ оптимизатора.}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00202}00202\ \textcolor{comment}{\ \ *\ @param\ opt\ \ \ \ Указатель\ на\ структуру\ оптимизатора}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00203}00203\ \textcolor{comment}{\ \ *\ @param\ params\ Массив\ параметров,\ которые\ будут\ обновлены\ (на\ выходе\ —\ новые\ параметры)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00204}00204\ \textcolor{comment}{\ \ *\ @param\ loss\ \ \ Loss\ текущего\ кандидата}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00205}00205\ \textcolor{comment}{\ \ *\ @return\ 0\ \ \ —\ если\ окей,\ }} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00206}00206\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ -\/1\ \ —\ если\ ошибка}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00207}00207\ \textcolor{comment}{\ \ *\ @details}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00208}00208\ \textcolor{comment}{\ \ *\ Сохраняет\ loss\ текущего\ кандидата\ и\ формирует\ параметры\ следующего\ кандидата.}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00209}00209\ \textcolor{comment}{\ \ *\ Если\ накоплено\ n\_cand\ кандидатов,\ генерируется\ новое\ поколение.}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00210}00210\ \textcolor{comment}{\ \ *\ Новое\ поколение\ формируется\ случайным\ выбором\ из\ n\_best\ лучших\ с\ добавлением\ мутации.}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00211}00211\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00212}00212\ \textcolor{comment}{\ \ *\ На\ выходе\ params\ содержит\ параметры\ следующего\ кандидата\ для\ измерений.}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00213}00213\ \textcolor{comment}{\ \ *\ @note\ Функция\ использует\ глобальную\ внутреннюю\ переменную\ для\ сортировки.}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00214}00214\ \textcolor{comment}{\ \ *\ Надо\ убедится\ что\ только\ один\ экземпляр\ функции\ запущен\ в\ момент\ времени}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00215}00215\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00216}\mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaef44a1f3298514569cc2b396a92101ef}{00216}}\ \_\_STATIC\_INLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaef44a1f3298514569cc2b396a92101ef}{EvolveOptimizer\_Step}}(\mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}}*\ opt,} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00217}00217\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}*\ params,} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00218}00218\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ loss)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00219}00219\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00220}00220\ \ \ \textcolor{keywordflow}{if}((opt\ ==\ NULL)\ ||\ (params\ ==\ NULL))} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00221}00221\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00222}00222\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00223}00223\ \ \ uint16\_t\ n\_params\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{n\_params}};\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00224}00224\ \ \ \textcolor{keywordflow}{if}(n\_params\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee}{EVOLVE\_MAX\_PARAMS}})} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00225}00225\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00226}00226\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00227}00227\ \ \ uint16\_t\ n\_cand\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}};\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00228}00228\ \ \ \textcolor{keywordflow}{if}(n\_cand\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}})} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00229}00229\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00230}00230\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00231}00231\ \ \ uint16\_t\ n\_best\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{n\_best}};\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00232}00232\ \ \ \textcolor{keywordflow}{if}(n\_best\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}/2)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00233}00233\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00234}00234\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00235}00235\ \ \ \textcolor{keywordtype}{float}\ \ \ \ mut\ \ \ \ \ \ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}{mutation\_amp}};} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00236}00236\ \ \ \textcolor{keywordflow}{if}((mut\ >\ 1)\ ||(mut\ <\ 0))} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00237}00237\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00238}00238\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00239}00239\ \ \ \textcolor{comment}{//\ 1.\ Сохраняем\ loss\ текущего\ кандидата}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00240}00240\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}]\ =\ loss;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00241}00241\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}++;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00242}00242\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00243}00243\ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}\ >=\ n\_cand)\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00244}00244\ \ \ \ \ \textcolor{comment}{//\ 2.\ Сортируем\ текущее\ поколение\ по\ loss}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00245}00245\ \ \ \ \ \textcolor{keywordflow}{for}(uint16\_t\ i\ =\ 0;\ i\ <\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}};\ i++)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00246}00246\ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[i]\ =\ i;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00247}00247\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00248}00248\ \ \ \ \ g\_sort\_opt\ =\ opt;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00249}00249\ \ \ \ \ qsort(opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}},\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}},\ \textcolor{keyword}{sizeof}(uint16\_t),\ cmp\_idx);} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00250}00250\ \ \ \ \ g\_sort\_opt\ =\ NULL;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00104}00104\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00105}\mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{00105}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{n\_params}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Количество\ параметров}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00106}\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{00106}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Количество\ кандидатов\ в\ популяции}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00107}\mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{00107}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{n\_best}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Количество\ лучших,\ усредняемых}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00108}\mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}{00108}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}{mutation\_amp}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Амплитуда\ мутации\ (0..1)}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00109}00109\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00110}\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{00110}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Индекс\ кандидата\ для\ обработки}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00111}\mbox{\hyperlink{struct_evolve_optimizer__t_ad0f464d7048a9ed0753b61f76f563108}{00111}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_ad0f464d7048a9ed0753b61f76f563108}{gen\_index}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Индекс\ популяции\ \ }} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00112}00112\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00113}00113\ \ \ \textcolor{comment}{//INTERNAL}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00114}\mbox{\hyperlink{struct_evolve_optimizer__t_a3be8c0c34db8429210ff470497a56727}{00114}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a3be8c0c34db8429210ff470497a56727}{gen\_mut}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Амплитуда\ мутации\ у\ текущей\ популяции\ \ }} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00115}00115\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00116}\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{00116}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[\mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}];\ \ \ \ \textcolor{comment}{///<\ Loss\ для\ каждого\ кандидата}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00117}\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{00117}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[\mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}][\mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee}{EVOLVE\_MAX\_PARAMS}}];\ \textcolor{comment}{///<\ Параметры\ кандидатов}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00118}\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{00118}}\ \ \ uint16\_t\ \ \mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[\mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}];\ \textcolor{comment}{///<\ Индексы\ отсортированных\ кандидатов}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00119}00119\ \}\ \mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}};} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00120}00120\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00121}00121\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00122}00122\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00123}00123\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00124}00124\ \textcolor{comment}{\ *\ @cond\ EVOLVE\_INTERNAL}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00125}00125\ \textcolor{comment}{\ */}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00126}00126\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00127}00127\ \textcolor{comment}{//\ Вспомогательный\ указатель\ для\ сортировки}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00128}00128\ \textcolor{keyword}{static}\ \mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}}\ *g\_sort\_opt;\ \textcolor{comment}{//\ глобальный\ указатель\ на\ текущий\ оптимизатор}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00129}00129\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00130}00130\ \textcolor{comment}{//\ функция\ условия\ сортировки}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00131}00131\ \textcolor{keyword}{static}\ \textcolor{keywordtype}{int}\ cmp\_idx(\textcolor{keyword}{const}\ \textcolor{keywordtype}{void}\ *a,\ \textcolor{keyword}{const}\ \textcolor{keywordtype}{void}\ *b)\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00132}00132\ \ \ \textcolor{keywordflow}{if}\ (g\_sort\_opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[*(\textcolor{keyword}{const}\ uint16\_t*)a]\ <\ g\_sort\_opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[*(\textcolor{keyword}{const}\ uint16\_t*)b])\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00133}00133\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00134}00134\ \ \ \textcolor{keywordflow}{if}\ (g\_sort\_opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[*(\textcolor{keyword}{const}\ uint16\_t*)a]\ >\ g\_sort\_opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[*(\textcolor{keyword}{const}\ uint16\_t*)b])\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00135}00135\ \ \ \ \ \textcolor{keywordflow}{return}\ 1;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00136}00136\ \ \ \textcolor{keywordflow}{return}\ 0;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00137}00137\ \}\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00138}00138\ \textcolor{comment}{/**\ @endcond\ */}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00139}00139\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00140}00140\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00141}00141\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00142}00142\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00143}00143\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00144}00144\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00145}00145\ \textcolor{comment}{\ \ *\ @brief\ Инициализация\ эволюционного\ оптимизатора.}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00146}00146\ \textcolor{comment}{\ \ *\ @param\ opt\ \ \ \ \ \ \ \ \ \ Указатель\ на\ структуру\ оптимизатора}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00147}00147\ \textcolor{comment}{\ \ *\ @param\ n\_params\ \ \ \ \ Количество\ параметров\ в\ одном\ кандидате}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00148}00148\ \textcolor{comment}{\ \ *\ @param\ n\_cand\ \ \ \ \ \ \ Количество\ кандидатов}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00149}00149\ \textcolor{comment}{\ \ *\ @param\ n\_best\ \ \ \ \ \ \ Количество\ лучших,\ усредняемых}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00150}00150\ \textcolor{comment}{\ \ *\ @param\ mutation\_amp\ Амплитуда\ мутации\ (в\ диапазоне\ 0.0–1.0)}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00151}00151\ \textcolor{comment}{\ \ *\ @param\ start\_params\ Начальные\ параметры\ (в\ диапазоне\ 0.0–1.0)}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00152}00152\ \textcolor{comment}{\ \ *\ @return\ 0\ \ \ —\ если\ окей,\ }} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00153}00153\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ -\/1\ \ —\ если\ ошибка}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00154}00154\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00155}\mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga4e3ea118b5b9068619c57724a925ba21}{00155}}\ \_\_STATIC\_INLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga4e3ea118b5b9068619c57724a925ba21}{EvolveOptimizer\_Init}}(\mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}}*\ opt,} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00156}00156\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ uint16\_t\ n\_params,} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00157}00157\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ uint16\_t\ n\_cand,} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00158}00158\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ uint16\_t\ n\_best,} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00159}00159\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ mutation\_amp,} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00160}00160\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}*\ start\_params)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00161}00161\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00162}00162\ \ \ \textcolor{keywordflow}{if}((opt\ ==\ NULL)\ ||\ (start\_params\ ==\ NULL))} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00163}00163\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00164}00164\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00165}00165\ \ \ \textcolor{keywordflow}{if}(n\_params\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee}{EVOLVE\_MAX\_PARAMS}})} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00166}00166\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00167}00167\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{n\_params}}\ \ \ \ \ =\ n\_params;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00168}00168\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00169}00169\ \ \ \textcolor{keywordflow}{if}(n\_cand\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}})} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00170}00170\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00171}00171\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}}\ \ \ \ \ \ \ =\ n\_cand;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00172}00172\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00173}00173\ \ \ \textcolor{keywordflow}{if}(n\_best\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}/2)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00174}00174\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00175}00175\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{n\_best}}\ \ \ \ \ \ \ =\ n\_best;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00176}00176\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00177}00177\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00178}00178\ \ \ \textcolor{keywordflow}{if}((mutation\_amp\ >\ 1)\ ||\ (mutation\_amp\ <\ 0))} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00179}00179\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00180}00180\ \ \ \textcolor{keywordflow}{if}(mutation\_amp\ <=\ 0.001f)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00181}00181\ \ \ \ \ mutation\_amp\ =\ 0.001f;\ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00182}00182\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}{mutation\_amp}}\ \ =\ mutation\_amp;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00183}00183\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00184}00184\ \ \ uint32\_t\ seed\ =\ \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}();} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00185}00185\ \textcolor{preprocessor}{\#ifdef\ ADC1}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00186}00186\ \ \ seed\ +=\ (ADC1-\/>DR\ \&\ 0xFF);} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00187}00187\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00188}00188\ \ \ srand(seed);} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00189}00189\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00190}00190\ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ n\_cand;\ i++)\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00191}00191\ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ j\ =\ 0;\ j\ <\ n\_params;\ j++)\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00192}00192\ \ \ \ \ \ \ \textcolor{comment}{//\ Добавляем\ случайную\ мутацию\ вокруг\ стартового\ параметра}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00193}00193\ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ base\ =\ start\_params[j];} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00194}00194\ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ inv\_randmax\ =\ 1.0f\ /\ (float)RAND\_MAX;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00195}00195\ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ noise\ =\ ((float)rand()\ *\ inv\_randmax\ *\ 2.0f\ -\/\ 1.0f)\ *\ mutation\_amp;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00196}00196\ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ =\ base\ +\ noise;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00197}00197\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ <\ 0.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ =\ 0.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00198}00198\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ >\ 1.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[i][j]\ =\ 1.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00199}00199\ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00200}00200\ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[i]\ =\ 0.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00201}00201\ \ \ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00202}00202\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00203}00203\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}\ =\ 0;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00204}00204\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ad0f464d7048a9ed0753b61f76f563108}{gen\_index}}\ =\ 0;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00205}00205\ \ \ \textcolor{keywordflow}{return}\ 0;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00206}00206\ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00207}00207\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00208}00208\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00209}00209\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00210}00210\ \textcolor{comment}{\ \ *\ @brief\ Один\ шаг\ эволюционного\ оптимизатора.}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00211}00211\ \textcolor{comment}{\ \ *\ @param\ opt\ \ \ \ Указатель\ на\ структуру\ оптимизатора}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00212}00212\ \textcolor{comment}{\ \ *\ @param\ params\ Массив\ параметров,\ которые\ будут\ обновлены\ (на\ выходе\ —\ новые\ параметры)}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00213}00213\ \textcolor{comment}{\ \ *\ @param\ loss\ \ \ Loss\ текущего\ кандидата}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00214}00214\ \textcolor{comment}{\ \ *\ @return\ 0\ \ \ —\ если\ окей,\ }} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00215}00215\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ -\/1\ \ —\ если\ ошибка}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00216}00216\ \textcolor{comment}{\ \ *\ @details}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00217}00217\ \textcolor{comment}{\ \ *\ Сохраняет\ loss\ текущего\ кандидата\ и\ формирует\ параметры\ следующего\ кандидата.}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00218}00218\ \textcolor{comment}{\ \ *\ Если\ накоплено\ n\_cand\ кандидатов,\ генерируется\ новое\ поколение.}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00219}00219\ \textcolor{comment}{\ \ *\ Новое\ поколение\ формируется\ случайным\ выбором\ из\ n\_best\ лучших\ с\ добавлением\ мутации.}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00220}00220\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00221}00221\ \textcolor{comment}{\ \ *\ На\ выходе\ params\ содержит\ параметры\ следующего\ кандидата\ для\ измерений.}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00222}00222\ \textcolor{comment}{\ \ *\ @note\ Функция\ использует\ глобальную\ внутреннюю\ переменную\ для\ сортировки.}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00223}00223\ \textcolor{comment}{\ \ *\ Надо\ убедится\ что\ только\ один\ экземпляр\ функции\ запущен\ в\ момент\ времени}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00224}00224\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00225}\mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaef44a1f3298514569cc2b396a92101ef}{00225}}\ \_\_STATIC\_INLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaef44a1f3298514569cc2b396a92101ef}{EvolveOptimizer\_Step}}(\mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}}*\ opt,} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00226}00226\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}*\ params,} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00227}00227\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ loss)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00228}00228\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00229}00229\ \ \ \textcolor{keywordflow}{if}((opt\ ==\ NULL)\ ||\ (params\ ==\ NULL))} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00230}00230\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00231}00231\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00232}00232\ \ \ uint16\_t\ n\_params\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{n\_params}};\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00233}00233\ \ \ \textcolor{keywordflow}{if}(n\_params\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee}{EVOLVE\_MAX\_PARAMS}})} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00234}00234\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00235}00235\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00236}00236\ \ \ uint16\_t\ n\_cand\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}};\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00237}00237\ \ \ \textcolor{keywordflow}{if}(n\_cand\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}})} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00238}00238\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00239}00239\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00240}00240\ \ \ uint16\_t\ n\_best\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{n\_best}};\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00241}00241\ \ \ \textcolor{keywordflow}{if}(n\_best\ >\ \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\_MAX\_CANDIDATES}}/2)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00242}00242\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00243}00243\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00244}00244\ \ \ \textcolor{keywordtype}{float}\ \ \ \ mut\ \ \ \ \ \ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}{mutation\_amp}};} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00245}00245\ \ \ \textcolor{keywordflow}{if}((mut\ >\ 1)\ ||(mut\ <\ 0))} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00246}00246\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00247}00247\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00248}00248\ \ \ \textcolor{comment}{//\ 1.\ Сохраняем\ loss\ текущего\ кандидата}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00249}00249\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}]\ =\ loss;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00250}00250\ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}++;} \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00251}00251\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00252}00252\ \ \ \ \ \textcolor{comment}{//\ -\/-\/-\/\ Адаптивная\ мутация\ в\ зависимости\ от\ Loss\ -\/-\/-\/}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00253}00253\ \ \ \ \ \textcolor{keywordtype}{float}\ best\_loss\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[0]];} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00254}00254\ \ \ \ \ \textcolor{keywordtype}{float}\ worst\_loss\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}}\ -\/\ 1]];} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00255}00255\ \ \ \ \ \textcolor{keywordtype}{float}\ diff\ =\ worst\_loss\ -\/\ best\_loss;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00256}00256\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00257}00257\ \ \ \ \ \textcolor{keywordtype}{float}\ sum\_loss\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00258}00258\ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ n\_cand;\ i++)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00259}00259\ \ \ \ \ \ \ sum\_loss\ +=\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[i];} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00260}00260\ \ \ \ \ \textcolor{keywordtype}{float}\ avg\_loss\ =\ sum\_loss\ /\ (float)n\_cand;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00261}00261\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00262}00262\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00263}00263\ \ \ \ \ \textcolor{keywordtype}{float}\ loss\_ratio\ =\ (diff\ >\ 0.0f)\ ?\ ((avg\_loss\ -\/\ best\_loss)\ /\ diff)\ :\ 0.5f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00264}00264\ \ \ \ \ \textcolor{keywordflow}{if}\ (loss\_ratio\ <\ 0.0f)\ loss\_ratio\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00265}00265\ \ \ \ \ \textcolor{keywordflow}{if}\ (loss\_ratio\ >\ 1.0f)\ loss\_ratio\ =\ 1.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00266}00266\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00267}00267\ \ \ \ \ \textcolor{comment}{//\ Записываем\ стабильность\ популяции\ в\ структуру}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00268}00268\ \ \ \ \ \textcolor{keywordflow}{if}(diff\ <\ 0.0f)\ diff\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00269}00269\ \ \ \ \ \textcolor{keywordflow}{if}(diff\ >\ 1.0f)\ diff\ =\ 1.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00270}00270\ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ =\ (1.0f\ -\/\ worst\_loss)\ *\ (1.0f\ -\/\ (worst\_loss\ -\/\ best\_loss));} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00271}00271\ \ \ \ \ \textcolor{keywordflow}{if}(opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ <\ 0.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00272}00272\ \ \ \ \ \textcolor{keywordflow}{if}(opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ >\ 1.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ =\ 1.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00273}00273\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00274}00274\ \ \ \ \ \textcolor{keywordtype}{float}\ mut\_pct\ =\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6}{EVOLVE\_MUTATION\_MIN\_PCT}}\ +} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00275}00275\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (\mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga861c1c6a503c21441abcec0d57b848bc}{EVOLVE\_MUTATION\_MAX\_PCT}}\ -\/\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6}{EVOLVE\_MUTATION\_MIN\_PCT}})\ *\ loss\_ratio;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00276}00276\ \ \ \ \ \textcolor{keywordtype}{float}\ adaptive\_mut\ =\ mut\ *\ (mut\_pct\ /\ 100.0f);} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00277}00277\ \ \ \ \ \textcolor{keywordflow}{if}\ (adaptive\_mut\ <\ 0.0001f)\ adaptive\_mut\ =\ 0.0001f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00278}00278\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00279}00279\ \ \ \ \ \textcolor{comment}{//\ 3.\ Генерируем\ новое\ поколение}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00280}00280\ \ \ \ \ uint16\_t\ n\_elite\ =\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga38607e23d9234524bc7de5869b15b8eb}{ELOVLE\_N\_ELITE\_CANDIDATE}};} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00281}00281\ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ c\ =\ 0;\ c\ <\ n\_cand;\ c++)\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00282}00282\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (c\ <\ n\_elite)\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00283}00283\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ n\_params;\ i++)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00284}00284\ \ \ \ \ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[c]][i];} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00285}00285\ \ \ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[c]\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00286}00286\ \ \ \ \ \ \ \}\ \textcolor{keywordflow}{else}\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00287}00287\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ n\_params;\ i++)\ \{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00288}00288\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ inv\_randmax\ =\ 1.0f\ /\ (float)RAND\_MAX;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00289}00289\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ noise\ =\ ((float)rand()\ *\ inv\_randmax\ *\ 2.0f\ -\/\ 1.0f)\ *\ adaptive\_mut;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00290}00290\ \ \ \ \ \ \ \ \ \ \ uint16\_t\ parent\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[rand()\ \%\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{n\_best}}];} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00291}00291\ \ \ \ \ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[parent][i]\ +\ noise;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00292}00292\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ <\ 0.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00293}00293\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ >\ 1.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ =\ 1.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00294}00294\ \ \ \ \ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00252}00252\ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}\ >=\ n\_cand)\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00253}00253\ \ \ \ \ \textcolor{comment}{//\ 2.\ Сортируем\ текущее\ поколение\ по\ loss}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00254}00254\ \ \ \ \ \textcolor{keywordflow}{for}(uint16\_t\ i\ =\ 0;\ i\ <\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}};\ i++)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00255}00255\ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[i]\ =\ i;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00256}00256\ \ \ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00257}00257\ \ \ \ \ g\_sort\_opt\ =\ opt;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00258}00258\ \ \ \ \ qsort(opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}},\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}},\ \textcolor{keyword}{sizeof}(uint16\_t),\ cmp\_idx);} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00259}00259\ \ \ \ \ g\_sort\_opt\ =\ NULL;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00260}00260\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00261}00261\ \ \ \ \ \textcolor{comment}{//\ -\/-\/-\/\ Адаптивная\ мутация\ в\ зависимости\ от\ Loss\ -\/-\/-\/}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00262}00262\ \ \ \ \ \textcolor{keywordtype}{float}\ best\_loss\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[0]];} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00263}00263\ \ \ \ \ \textcolor{keywordtype}{float}\ worst\_loss\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}{n\_cand}}\ -\/\ 1]];} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00264}00264\ \ \ \ \ \textcolor{keywordtype}{float}\ diff\ =\ worst\_loss\ -\/\ best\_loss;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00265}00265\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00266}00266\ \ \ \ \ \textcolor{keywordtype}{float}\ sum\_loss\ =\ 0.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00267}00267\ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ n\_cand;\ i++)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00268}00268\ \ \ \ \ \ \ sum\_loss\ +=\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[i];} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00269}00269\ \ \ \ \ \textcolor{keywordtype}{float}\ avg\_loss\ =\ sum\_loss\ /\ (float)n\_cand;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00270}00270\ \ \ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00271}00271\ \ \ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00272}00272\ \ \ \ \ \textcolor{keywordtype}{float}\ loss\_ratio\ =\ (diff\ >\ 0.0f)\ ?\ ((avg\_loss\ -\/\ best\_loss)\ /\ diff)\ :\ 0.5f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00273}00273\ \ \ \ \ \textcolor{keywordflow}{if}\ (loss\_ratio\ <\ 0.0f)\ loss\_ratio\ =\ 0.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00274}00274\ \ \ \ \ \textcolor{keywordflow}{if}\ (loss\_ratio\ >\ 1.0f)\ loss\_ratio\ =\ 1.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00275}00275\ \ \ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00276}00276\ \ \ \ \ \textcolor{comment}{//\ Записываем\ стабильность\ популяции\ в\ структуру}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00277}00277\ \ \ \ \ \textcolor{keywordflow}{if}(diff\ <\ 0.0f)\ diff\ =\ 0.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00278}00278\ \ \ \ \ \textcolor{keywordflow}{if}(diff\ >\ 1.0f)\ diff\ =\ 1.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00279}00279\ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ =\ (1.0f\ -\/\ worst\_loss)\ *\ (1.0f\ -\/\ (worst\_loss\ -\/\ best\_loss));} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00280}00280\ \ \ \ \ \textcolor{keywordflow}{if}(opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ <\ 0.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ =\ 0.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00281}00281\ \ \ \ \ \textcolor{keywordflow}{if}(opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ >\ 1.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}{stability}}\ =\ 1.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00282}00282\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00283}00283\ \ \ \ \ \textcolor{keywordtype}{float}\ mut\_pct\ =\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6}{EVOLVE\_MUTATION\_MIN\_PCT}}\ +} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00284}00284\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (\mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga861c1c6a503c21441abcec0d57b848bc}{EVOLVE\_MUTATION\_MAX\_PCT}}\ -\/\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6}{EVOLVE\_MUTATION\_MIN\_PCT}})\ *\ loss\_ratio;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00285}00285\ \ \ \ \ \textcolor{keywordtype}{float}\ adaptive\_mut\ =\ mut\ *\ (mut\_pct\ /\ 100.0f);} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00286}00286\ \ \ \ \ \textcolor{keywordflow}{if}\ (adaptive\_mut\ <\ 0.0001f)\ adaptive\_mut\ =\ 0.0001f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00287}00287\ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a3be8c0c34db8429210ff470497a56727}{gen\_mut}}\ =\ adaptive\_mut;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00288}00288\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00289}00289\ \ \ \ \ \textcolor{comment}{//\ 3.\ Генерируем\ новое\ поколение}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00290}00290\ \ \ \ \ uint16\_t\ n\_elite\ =\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga38607e23d9234524bc7de5869b15b8eb}{ELOVLE\_N\_ELITE\_CANDIDATE}};} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00291}00291\ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ c\ =\ 0;\ c\ <\ n\_cand;\ c++)\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00292}00292\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (c\ <\ n\_elite)\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00293}00293\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ n\_params;\ i++)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00294}00294\ \ \ \ \ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[c]][i];} \DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00295}00295\ \ \ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[c]\ =\ 0.0f;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00296}00296\ \ \ \ \ \ \ \}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00297}00297\ \ \ \ \ \}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00298}00298\ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}\ =\ 0;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00299}00299\ \ \ \}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00300}00300\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00301}00301\ \ \ \textcolor{comment}{//\ 4.\ Возвращаем\ параметры\ следующего\ кандидата}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00302}00302\ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{n\_params}};\ i++)} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00303}00303\ \ \ \ \ params[i]\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}][i];} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00304}00304\ \ \ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00305}00305\ \ \ \textcolor{keywordflow}{return}\ 0;} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00306}00306\ \}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00307}00307\ \textcolor{preprocessor}{\#else\ }\textcolor{comment}{//\ ENABLE\_EVOLVE\_OPTIMIZATION}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00308}00308\ \textcolor{comment}{//заглушки}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00309}00309\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00310}00310\ \ \ uint16\_t\ n\_params;\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00311}00311\ \ \ uint16\_t\ n\_cand;\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00312}00312\ \ \ uint16\_t\ n\_best;\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00313}00313\ \ \ \textcolor{keywordtype}{float}\ mutation\_amp;\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00314}00314\ \ \ \textcolor{keywordtype}{float}\ loss[0];\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00315}00315\ \ \ \textcolor{keywordtype}{float}\ candidates[0][0];\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00316}00316\ \}\ \mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}};} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00317}00317\ \textcolor{preprocessor}{\#define\ EvolveOptimizer\_Init(opt,\ n\_params,\ n\_cand,\ n\_best,\ mutation\_amp,\ start\_params)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00318}00318\ \textcolor{preprocessor}{\#define\ EvolveOptimizer\_Step(opt,\ params,\ LossFunc)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00319}00319\ \textcolor{preprocessor}{\#define\ PARAM\_SCALE(x,\ min\_val,\ max\_val)\ \ \ \ \ \ \ \ \ (x)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00320}00320\ \textcolor{preprocessor}{\#define\ PARAM\_UNSCALE(val,\ min\_val,\ max\_val)\ \ \ \ \ (val)}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00321}00321\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ ENABLE\_EVOLVE\_OPTIMIZATION}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00322}00322\ } -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00323}00323\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ \_\_EVOLVE\_OPTIMIZER\_H\_}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00324}00324\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00325}00325\ \textcolor{comment}{/**\ EVOLVE\_OPTIMIZER}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00326}00326\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00327}00327\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00296}00296\ \ \ \ \ \ \ \}\ \textcolor{keywordflow}{else}\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00297}00297\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ n\_params;\ i++)\ \{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00298}00298\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ inv\_randmax\ =\ 1.0f\ /\ (float)RAND\_MAX;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00299}00299\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordtype}{float}\ noise\ =\ ((float)rand()\ *\ inv\_randmax\ *\ 2.0f\ -\/\ 1.0f)\ *\ adaptive\_mut;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00300}00300\ \ \ \ \ \ \ \ \ \ \ uint16\_t\ parent\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}{sorted\_idx}}[rand()\ \%\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}{n\_best}}];} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00301}00301\ \ \ \ \ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[parent][i]\ +\ noise;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00302}00302\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ <\ 0.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ =\ 0.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00303}00303\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ >\ 1.0f)\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[c][i]\ =\ 1.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00304}00304\ \ \ \ \ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00305}00305\ \ \ \ \ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}}[c]\ =\ 0.0f;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00306}00306\ \ \ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00307}00307\ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00308}00308\ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}\ =\ 0;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00309}00309\ \ \ \ \ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_ad0f464d7048a9ed0753b61f76f563108}{gen\_index}}++;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00310}00310\ \ \ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00311}00311\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00312}00312\ \ \ \textcolor{comment}{//\ 4.\ Возвращаем\ параметры\ следующего\ кандидата}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00313}00313\ \ \ \textcolor{keywordflow}{for}\ (uint16\_t\ i\ =\ 0;\ i\ <\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}{n\_params}};\ i++)} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00314}00314\ \ \ \ \ params[i]\ =\ opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}}[opt-\/>\mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\_index}}][i];} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00315}00315\ \ \ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00316}00316\ \ \ \textcolor{keywordflow}{return}\ 0;} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00317}00317\ \}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00318}00318\ \textcolor{preprocessor}{\#else\ }\textcolor{comment}{//\ ENABLE\_EVOLVE\_OPTIMIZATION}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00319}00319\ \textcolor{comment}{//заглушки}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00320}00320\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00321}00321\ \ \ uint16\_t\ n\_params;\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00322}00322\ \ \ uint16\_t\ n\_cand;\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00323}00323\ \ \ uint16\_t\ n\_best;\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00324}00324\ \ \ \textcolor{keywordtype}{float}\ mutation\_amp;\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00325}00325\ \ \ \textcolor{keywordtype}{float}\ loss[0];\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00326}00326\ \ \ \textcolor{keywordtype}{float}\ candidates[0][0];\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00327}00327\ \}\ \mbox{\hyperlink{struct_evolve_optimizer__t}{EvolveOptimizer\_t}};} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00328}00328\ \textcolor{preprocessor}{\#define\ EvolveOptimizer\_Init(opt,\ n\_params,\ n\_cand,\ n\_best,\ mutation\_amp,\ start\_params)}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00329}00329\ \textcolor{preprocessor}{\#define\ EvolveOptimizer\_Step(opt,\ params,\ LossFunc)}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00330}00330\ \textcolor{preprocessor}{\#define\ PARAM\_SCALE(x,\ min\_val,\ max\_val)\ \ \ \ \ \ \ \ \ (x)}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00331}00331\ \textcolor{preprocessor}{\#define\ PARAM\_UNSCALE(val,\ min\_val,\ max\_val)\ \ \ \ \ (val)}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00332}00332\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ ENABLE\_EVOLVE\_OPTIMIZATION}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00333}00333\ } +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00334}00334\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ \_\_EVOLVE\_OPTIMIZER\_H\_}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00335}00335\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00336}00336\ \textcolor{comment}{/**\ EVOLVE\_OPTIMIZER}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00337}00337\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{evolve__optimizer_8h_source_l00338}00338\ \textcolor{comment}{\ \ */}} \end{DoxyCode} diff --git a/Doc/latex/files.tex b/Doc/latex/files.tex index 5ca56a4..7997671 100644 --- a/Doc/latex/files.tex +++ b/Doc/latex/files.tex @@ -1,21 +1,21 @@ \doxysection{File List} Here is a list of all documented files with brief descriptions\+:\begin{DoxyCompactList} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\mbox{\hyperlink{mainpage_8h_source}{mainpage.\+h}} }{\pageref{mainpage_8h_source}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{____general__flash_8h_source}{\+\_\+\+\_\+general\+\_\+flash.\+h}} }{\pageref{____general__flash_8h_source}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}} }{\pageref{____general__spi_8h_source}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{____general__uart_8h_source}{\+\_\+\+\_\+general\+\_\+uart.\+h}} }{\pageref{____general__uart_8h_source}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}} \\*Заголочный файл для дефайнов битового доступа }{\pageref{bit__access_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{evolve__optimizer_8h}{evolve\+\_\+optimizer.\+h}} \\*Заголовочный файл для адаптивного подбора параметров }{\pageref{evolve__optimizer_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__gpio_8h}{general\+\_\+gpio.\+h}} \\*Заголовочный файл для модуля инициализации портов и работы с ними }{\pageref{general__gpio_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__tim_8h}{general\+\_\+tim.\+h}} \\*Заголовочный файл для модуля инициализации таймеров и работы с ними }{\pageref{general__tim_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{mylibs__config_8h}{mylibs\+\_\+config.\+h}} \\*Конфигурации для библиотек My\+Libs }{\pageref{mylibs__config_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{mylibs__defs_8h}{mylibs\+\_\+defs.\+h}} \\*Заголочный файл для дефайнов библиотеки My\+Libs\+General }{\pageref{mylibs__defs_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{mylibs__include_8h}{mylibs\+\_\+include.\+h}} \\*Заголочный файл для всех библиотек }{\pageref{mylibs__include_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{trace_8h}{trace.\+h}} \\*Заголочный файл для работы с трассировкой }{\pageref{trace_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{trackers_8h}{trackers.\+h}} \\*Заголочный файл для работы с трекерами \doxylink{group___t_r_a_c_k_e_r_s}{Trackers defines} }{\pageref{trackers_8h}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{____general__flash_8c_source}{\+\_\+\+\_\+general\+\_\+flash.\+c}} }{\pageref{____general__flash_8c_source}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{____general__spi_8c_source}{\+\_\+\+\_\+general\+\_\+spi.\+c}} }{\pageref{____general__spi_8c_source}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{____general__uart_8c_source}{\+\_\+\+\_\+general\+\_\+uart.\+c}} }{\pageref{____general__uart_8c_source}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{general__gpio_8c}{general\+\_\+gpio.\+c}} \\*Модуль для инициализации портов и работы с ними }{\pageref{general__gpio_8c}}{} -\item\contentsline{section}{F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{general__tim_8c}{general\+\_\+tim.\+c}} \\*Модуль для инициализации таймеров и работы с ними }{\pageref{general__tim_8c}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\mbox{\hyperlink{mainpage_8h_source}{mainpage.\+h}} }{\pageref{mainpage_8h_source}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{____general__flash_8h_source}{\+\_\+\+\_\+general\+\_\+flash.\+h}} }{\pageref{____general__flash_8h_source}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}} \\*Заголочный файл для дефайнов битового доступа }{\pageref{bit__access_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{evolve__optimizer_8h}{evolve\+\_\+optimizer.\+h}} \\*Заголовочный файл для адаптивного подбора параметров }{\pageref{evolve__optimizer_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__gpio_8h}{general\+\_\+gpio.\+h}} \\*Заголовочный файл для модуля инициализации портов и работы с ними }{\pageref{general__gpio_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__spi_8h}{general\+\_\+spi.\+h}} \\*Заголовочный файл для модуля инициализации SPI }{\pageref{general__spi_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__tim_8h}{general\+\_\+tim.\+h}} \\*Заголовочный файл для модуля инициализации таймеров и работы с ними }{\pageref{general__tim_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__uart_8h}{general\+\_\+uart.\+h}} \\*Заголовочный файл для модуля инициализации UART }{\pageref{general__uart_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{mylibs__config_8h}{mylibs\+\_\+config.\+h}} \\*Конфигурации для библиотек My\+Libs }{\pageref{mylibs__config_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{mylibs__defs_8h}{mylibs\+\_\+defs.\+h}} \\*Заголочный файл для дефайнов библиотеки My\+Libs\+General }{\pageref{mylibs__defs_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{mylibs__include_8h}{mylibs\+\_\+include.\+h}} \\*Заголочный файл для всех библиотек }{\pageref{mylibs__include_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{trace_8h}{trace.\+h}} \\*Заголочный файл для работы с трассировкой }{\pageref{trace_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{trackers_8h}{trackers.\+h}} \\*Заголочный файл для работы с трекерами \doxylink{group___t_r_a_c_k_e_r_s}{Trackers defines} }{\pageref{trackers_8h}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{____general__flash_8c_source}{\+\_\+\+\_\+general\+\_\+flash.\+c}} }{\pageref{____general__flash_8c_source}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{general__gpio_8c}{general\+\_\+gpio.\+c}} \\*Модуль для инициализации портов и работы с ними }{\pageref{general__gpio_8c}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{general__spi_8c}{general\+\_\+spi.\+c}} \\*Модуль для инициализации SPI }{\pageref{general__spi_8c}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{general__tim_8c}{general\+\_\+tim.\+c}} \\*Модуль для инициализации таймеров и работы с ними }{\pageref{general__tim_8c}}{} +\item\contentsline{section}{E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/\mbox{\hyperlink{general__uart_8c}{general\+\_\+uart.\+c}} \\*Модуль для инициализации UART }{\pageref{general__uart_8c}}{} \end{DoxyCompactList} diff --git a/Doc/latex/general__gpio_8c.tex b/Doc/latex/general__gpio_8c.tex index 46422d9..2a58371 100644 --- a/Doc/latex/general__gpio_8c.tex +++ b/Doc/latex/general__gpio_8c.tex @@ -1,16 +1,17 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/general\+\_\+gpio.c File Reference} -\hypertarget{general__gpio_8c}{}\label{general__gpio_8c}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_gpio.c@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_gpio.c}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/general\+\_\+gpio.c File Reference} +\hypertarget{general__gpio_8c}{}\label{general__gpio_8c}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_gpio.c@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_gpio.c}} Модуль для инициализации портов и работы с ними. {\ttfamily \#include "{}general\+\_\+gpio.\+h"{}}\newline -Include dependency graph for general\+\_\+gpio.\+c\+:\nopagebreak +Include dependency graph for general\+\_\+gpio.\+c\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=266pt]{general__gpio_8c__incl} +\includegraphics[width=229pt]{general__gpio_8c__incl} \end{center} \end{figure} \doxysubsubsection*{Functions} diff --git a/Doc/latex/general__gpio_8c__incl.md5 b/Doc/latex/general__gpio_8c__incl.md5 index 68c4ba4..e665dcd 100644 --- a/Doc/latex/general__gpio_8c__incl.md5 +++ b/Doc/latex/general__gpio_8c__incl.md5 @@ -1 +1 @@ -d6b4b5162b176a9d1f8fd88ea3e36d44 \ No newline at end of file +06087ea6fdcbd10af4ee99fd98be927c \ No newline at end of file diff --git a/Doc/latex/general__gpio_8c__incl.pdf b/Doc/latex/general__gpio_8c__incl.pdf index f259800..c1e3f5a 100644 Binary files a/Doc/latex/general__gpio_8c__incl.pdf and b/Doc/latex/general__gpio_8c__incl.pdf differ diff --git a/Doc/latex/general__gpio_8c_source.tex b/Doc/latex/general__gpio_8c_source.tex index 97bdc9c..b85216a 100644 --- a/Doc/latex/general__gpio_8c_source.tex +++ b/Doc/latex/general__gpio_8c_source.tex @@ -1,5 +1,5 @@ \doxysection{general\+\_\+gpio.\+c} -\hypertarget{general__gpio_8c_source}{}\label{general__gpio_8c_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_gpio.c@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_gpio.c}} +\hypertarget{general__gpio_8c_source}{}\label{general__gpio_8c_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_gpio.c@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_gpio.c}} \mbox{\hyperlink{general__gpio_8c}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00001}00001\ \textcolor{comment}{/**\ }} @@ -193,7 +193,7 @@ \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00189}00189\ \ \ \textcolor{comment}{/*\ Режим\ моргания\ светодиода\ */}} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00190}00190\ \ \ \textcolor{keywordflow}{if}(led-\/>\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435}{state}}\ ==\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a2445895bed5dcbedc82ea3ef02bec6fb}{LED\_IS\_BLINKING}})} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00191}00191\ \ \ \{} -\DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00192}00192\ \ \ \ \ uint32\_t\ tickcurrent\ =\ HAL\_GetTick();} +\DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00192}00192\ \ \ \ \ uint32\_t\ tickcurrent\ =\ \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}();} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00193}00193\ \ \ \ \ \textcolor{comment}{/*\ Ожидание\ истечения\ периода\ моргания\ */}} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00194}00194\ \ \ \ \ \textcolor{keywordflow}{if}((tickcurrent\ -\/\ led-\/>tickprev)\ >\ led-\/>\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec}{LED\_Period}})} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00195}00195\ \ \ \ \ \{} @@ -208,7 +208,7 @@ \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00204}00204\ \ \ \{} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00205}00205\ \ \ \ \ \textcolor{keyword}{static}\ \textcolor{keywordtype}{unsigned}\ direction\ =\ 0;} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00206}00206\ \ \ \ \ \textcolor{keyword}{static}\ \textcolor{keywordtype}{int}\ duty\ =\ 0;} -\DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00207}00207\ \ \ \ \ uint32\_t\ tickcurrent\ =\ HAL\_GetTick();} +\DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00207}00207\ \ \ \ \ uint32\_t\ tickcurrent\ =\ \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}();} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00208}00208\ \ \ \ \ \textcolor{comment}{/*\ Ожидание\ момента\ изменения\ яркости\ */}} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00209}00209\ \ \ \ \ \textcolor{comment}{/*\ Период\ ШИМ\ 20\ мс,\ поэтому\ менять\ яроксть\ надо\ 40\ раз\ за\ период\ (туда\ обратно)\ */}} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00210}00210\ \ \ \ \ \textcolor{keywordflow}{if}((tickcurrent\ -\/\ led-\/>tickprev)\ >\ led-\/>\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec}{LED\_Period}}/(\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga1d42e219765ec526d99e306638ac0023}{LED\_PWM\_TICKS}}*2))} @@ -292,9 +292,9 @@ \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00288}00288\ \ \ \ \ \textcolor{keywordflow}{if}(sw-\/>\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}{Sw\_FilterDelay}})\ \textcolor{comment}{//\ если\ включена\ защита\ от\ дребезга}} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00289}00289\ \ \ \ \ \{} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00290}00290\ \ \ \ \ \ \ \textcolor{keywordflow}{if}(sw-\/>tickprev\ ==\ 0)} -\DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00291}00291\ \ \ \ \ \ \ \ \ sw-\/>tickprev\ =\ HAL\_GetTick();} +\DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00291}00291\ \ \ \ \ \ \ \ \ sw-\/>tickprev\ =\ \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}();} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00292}00292\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00293}00293\ \ \ \ \ \ \ \textcolor{keywordflow}{if}((HAL\_GetTick()\ -\/\ sw-\/>tickprev)\ >=\ sw-\/>\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}{Sw\_FilterDelay}})} +\DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00293}00293\ \ \ \ \ \ \ \textcolor{keywordflow}{if}((\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}()\ -\/\ sw-\/>tickprev)\ >=\ sw-\/>\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}{Sw\_FilterDelay}})} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00294}00294\ \ \ \ \ \ \ \{} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00295}00295\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}(HAL\_GPIO\_ReadPin(sw-\/>\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a}{Sw\_Port}},\ sw-\/>\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032}{Sw\_Pin}})\ ==\ sw-\/>\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405}{Sw\_ActiveLvl}})} \DoxyCodeLine{\Hypertarget{general__gpio_8c_source_l00296}00296\ \ \ \ \ \ \ \ \ \{} diff --git a/Doc/latex/general__gpio_8h.tex b/Doc/latex/general__gpio_8h.tex index 2748149..677dff9 100644 --- a/Doc/latex/general__gpio_8h.tex +++ b/Doc/latex/general__gpio_8h.tex @@ -1,19 +1,21 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/general\+\_\+gpio.h File Reference} -\hypertarget{general__gpio_8h}{}\label{general__gpio_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_gpio.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_gpio.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/general\+\_\+gpio.h File Reference} +\hypertarget{general__gpio_8h}{}\label{general__gpio_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_gpio.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_gpio.h}} Заголовочный файл для модуля инициализации портов и работы с ними. {\ttfamily \#include "{}mylibs\+\_\+defs.\+h"{}}\newline -Include dependency graph for general\+\_\+gpio.\+h\+:\nopagebreak +Include dependency graph for general\+\_\+gpio.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=265pt]{general__gpio_8h__incl} +\includegraphics[width=229pt]{general__gpio_8h__incl} \end{center} \end{figure} -This graph shows which files directly or indirectly include this file\+:\nopagebreak +This graph shows which files directly or indirectly include this file\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode @@ -39,9 +41,7 @@ struct \mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\+\_\+\+Switch\+Ty \#define \mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga19d9e3aced311179a2914e0c9b13d0f9}{SW\+\_\+\+ON}}~1 \begin{DoxyCompactList}\small\item\em Состояние пина при нажатой кнопке \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___g_p_i_o___i_n_i_t_gacd8900c9ec0efde1da3253b718574067}{SW\+\_\+\+OFF}}~0 -\begin{DoxyCompactList}\small\item\em Состояние пина при отжатой кнопке \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga580b842096340b066c28b24d6b315be6}{GPIO\+\_\+\+TIM\+\_\+\+Alternate\+\_\+\+Mapping}}(INSTANCE) -\begin{DoxyCompactList}\small\item\em Маппинг альтернативной функции TIM между GPIO. \end{DoxyCompactList}\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Состояние пина при отжатой кнопке \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsection*{Enumerations} \begin{DoxyCompactItemize} \item diff --git a/Doc/latex/general__gpio_8h__dep__incl.md5 b/Doc/latex/general__gpio_8h__dep__incl.md5 index 56ec0dc..daf1c10 100644 --- a/Doc/latex/general__gpio_8h__dep__incl.md5 +++ b/Doc/latex/general__gpio_8h__dep__incl.md5 @@ -1 +1 @@ -ad2bfd356854f9f0812ccb26fdf5c988 \ No newline at end of file +78ab8e4e6ebf3449d861764d1b38a0a8 \ No newline at end of file diff --git a/Doc/latex/general__gpio_8h__dep__incl.pdf b/Doc/latex/general__gpio_8h__dep__incl.pdf index 6b3454f..cdcacaa 100644 Binary files a/Doc/latex/general__gpio_8h__dep__incl.pdf and b/Doc/latex/general__gpio_8h__dep__incl.pdf differ diff --git a/Doc/latex/general__gpio_8h__incl.md5 b/Doc/latex/general__gpio_8h__incl.md5 index e609b83..4ec2cb9 100644 --- a/Doc/latex/general__gpio_8h__incl.md5 +++ b/Doc/latex/general__gpio_8h__incl.md5 @@ -1 +1 @@ -6f17442ee0a3e2ee4f9dbda2a2e7f4a9 \ No newline at end of file +c4bc3b9676509254c26d2cac446951d4 \ No newline at end of file diff --git a/Doc/latex/general__gpio_8h__incl.pdf b/Doc/latex/general__gpio_8h__incl.pdf index f9043ee..9fb4186 100644 Binary files a/Doc/latex/general__gpio_8h__incl.pdf and b/Doc/latex/general__gpio_8h__incl.pdf differ diff --git a/Doc/latex/general__gpio_8h_source.tex b/Doc/latex/general__gpio_8h_source.tex index 70a6234..5965b70 100644 --- a/Doc/latex/general__gpio_8h_source.tex +++ b/Doc/latex/general__gpio_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{general\+\_\+gpio.\+h} -\hypertarget{general__gpio_8h_source}{}\label{general__gpio_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_gpio.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_gpio.h}} +\hypertarget{general__gpio_8h_source}{}\label{general__gpio_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_gpio.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_gpio.h}} \mbox{\hyperlink{general__gpio_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00001}00001\ \textcolor{comment}{/**\ }} @@ -31,159 +31,213 @@ \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00027}00027\ \textcolor{comment}{\ \ *\ @\{}} \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00028}00028\ \textcolor{comment}{\ \ */}} \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00029}00029\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00030}00030\ \textcolor{preprocessor}{\#ifndef\ LED\_PWM\_TICKS}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00031}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga1d42e219765ec526d99e306638ac0023}{00031}}\ \textcolor{preprocessor}{\#define\ LED\_PWM\_TICKS\ 15\ }\textcolor{comment}{///<\ Количество\ тиков\ в\ периоде\ ШИМ}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00030}00030\ \textcolor{preprocessor}{\#ifndef\ local\_time}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00031}00031\ \textcolor{preprocessor}{\#define\ local\_time()\ \ HAL\_GetTick()\ }\textcolor{comment}{///<\ Локальное\ время}} \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00032}00032\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00033}00033\ \ \ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00034}00034\ \textcolor{preprocessor}{\#ifndef\ LED\_ON}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00035}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_gaf2e697ac60e05813d45ea2c9c9e79c25}{00035}}\ \textcolor{preprocessor}{\#define\ LED\_ON\ 1\ \ }\textcolor{comment}{///<\ Состояние\ пина\ для\ включения\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00033}00033\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00034}00034\ \textcolor{preprocessor}{\#ifndef\ LED\_PWM\_TICKS}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00035}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga1d42e219765ec526d99e306638ac0023}{00035}}\ \textcolor{preprocessor}{\#define\ LED\_PWM\_TICKS\ 15\ }\textcolor{comment}{///<\ Количество\ тиков\ в\ периоде\ ШИМ}} \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00036}00036\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00037}00037\ \textcolor{preprocessor}{\#ifndef\ LED\_OFF}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00038}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga80700bb63bd56ebabbb4728aa433fd29}{00038}}\ \textcolor{preprocessor}{\#define\ LED\_OFF\ 0\ }\textcolor{comment}{///<\ Состояние\ пина\ для\ выключения\ светодиода}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00039}00039\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00040}00040\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00041}00041\ \textcolor{preprocessor}{\#ifndef\ SW\_ON}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00042}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga19d9e3aced311179a2914e0c9b13d0f9}{00042}}\ \textcolor{preprocessor}{\#define\ SW\_ON\ 1\ \ \ }\textcolor{comment}{///<\ Состояние\ пина\ при\ нажатой\ кнопке}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00037}00037\ \ \ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00038}00038\ \textcolor{preprocessor}{\#ifndef\ LED\_ON}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00039}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_gaf2e697ac60e05813d45ea2c9c9e79c25}{00039}}\ \textcolor{preprocessor}{\#define\ LED\_ON\ 1\ \ }\textcolor{comment}{///<\ Состояние\ пина\ для\ включения\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00040}00040\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00041}00041\ \textcolor{preprocessor}{\#ifndef\ LED\_OFF}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00042}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga80700bb63bd56ebabbb4728aa433fd29}{00042}}\ \textcolor{preprocessor}{\#define\ LED\_OFF\ 0\ }\textcolor{comment}{///<\ Состояние\ пина\ для\ выключения\ светодиода}} \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00043}00043\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00044}00044\ \textcolor{preprocessor}{\#ifndef\ SW\_OFF}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00045}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_gacd8900c9ec0efde1da3253b718574067}{00045}}\ \textcolor{preprocessor}{\#define\ SW\_OFF\ 0\ \ }\textcolor{comment}{///<\ Состояние\ пина\ при\ отжатой\ кнопке}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00046}00046\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00047}00047\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00048}00048\ \textcolor{comment}{/**\ GPIO\_INIT}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00049}00049\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00050}00050\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00051}00051\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00052}00052\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00053}00053\ \textcolor{comment}{//\ /**}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00054}00054\ \textcolor{comment}{//\ \ \ *\ @brief\ Маппинг\ альтернативной\ функции\ SPI\ между\ GPIO}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00055}00055\ \textcolor{comment}{//\ \ \ *\ @ingroup\ \ MYLIBS\_GPIO\_GENERAL}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00056}00056\ \textcolor{comment}{//\ \ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00057}00057\ \textcolor{comment}{//\ \#define\ SPI\_Alternate\_Mapping(INSTANCE)\ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00058}00058\ \textcolor{comment}{//\ ((((INSTANCE)\ ==\ TIM1)\ \ ||\ ((INSTANCE)\ ==\ TIM2))?\ \ \ \ \ GPIO\_AF1\_TIM1:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00059}00059\ \textcolor{comment}{//\ (((INSTANCE)\ ==\ TIM3)\ \ \ ||\ ((INSTANCE)\ ==\ TIM4)\ \ \ ||\ ((INSTANCE)\ ==\ TIM5))?\ GPIO\_AF2\_TIM3:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00060}00060\ \textcolor{comment}{//\ (((INSTANCE)\ ==\ TIM8)\ \ \ ||\ ((INSTANCE)\ ==\ TIM9)\ \ \ ||\ ((INSTANCE)\ ==\ TIM10)\ ||\ ((INSTANCE)\ ==\ TIM11))?\ GPIO\_AF3\_TIM8:\ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00061}00061\ \textcolor{comment}{//\ (((INSTANCE)\ ==\ TIM12)\ \ ||\ ((INSTANCE)\ ==\ TIM13)\ \ ||\ ((INSTANCE)\ ==\ TIM14))?\ GPIO\_AF9\_TIM12:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00062}00062\ \textcolor{comment}{//\ (0))}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00063}00063\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00064}00064\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00065}00065\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00066}00066\ \textcolor{comment}{\ \ *\ @brief\ Маппинг\ альтернативной\ функции\ TIM\ между\ GPIO}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00067}00067\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_GPIO\_GENERAL}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00068}00068\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00069}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga580b842096340b066c28b24d6b315be6}{00069}}\ \textcolor{preprocessor}{\#define\ GPIO\_TIM\_Alternate\_Mapping(INSTANCE)\ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00070}00070\ \textcolor{preprocessor}{((((INSTANCE)\ ==\ TIM1)\ \ ||\ ((INSTANCE)\ ==\ TIM2))?\ GPIO\_AF1\_TIM1:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00071}00071\ \textcolor{preprocessor}{(((INSTANCE)\ ==\ TIM3)\ \ \ ||\ ((INSTANCE)\ ==\ TIM4)\ \ \ ||\ ((INSTANCE)\ ==\ TIM5))?\ GPIO\_AF2\_TIM3:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00072}00072\ \textcolor{preprocessor}{(((INSTANCE)\ ==\ TIM8)\ \ \ ||\ ((INSTANCE)\ ==\ TIM9)\ \ \ ||\ ((INSTANCE)\ ==\ TIM10)\ ||\ ((INSTANCE)\ ==\ TIM11))?\ GPIO\_AF3\_TIM8:\ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00073}00073\ \textcolor{preprocessor}{(((INSTANCE)\ ==\ TIM12)\ \ ||\ ((INSTANCE)\ ==\ TIM13)\ \ ||\ ((INSTANCE)\ ==\ TIM14))?\ GPIO\_AF9\_TIM12:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00074}00074\ \textcolor{preprocessor}{(0))}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00075}00075\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00076}00076\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00077}00077\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00078}00078\ \textcolor{comment}{\ \ *\ @brief\ Режимы\ работы\ светодиода}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00079}00079\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_GPIO\_LEDS}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00080}00080\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00081}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{00081}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{enum}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00082}00082\ \{} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00083}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a74276cd2464314e422e8a144483f74ae}{00083}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a74276cd2464314e422e8a144483f74ae}{LED\_IS\_OFF}}\ =\ 0,\ \ \ \ \ \ \ \textcolor{comment}{///<\ Светодиод\ выключен}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00084}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1af6abfb9c5b95abbdb239590f2cd245ea}{00084}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1af6abfb9c5b95abbdb239590f2cd245ea}{LED\_IS\_ON}}\ =\ 1,\ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Светодиод\ включен}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00085}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a2445895bed5dcbedc82ea3ef02bec6fb}{00085}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a2445895bed5dcbedc82ea3ef02bec6fb}{LED\_IS\_BLINKING}}\ =\ 2,\ \ \textcolor{comment}{///<\ Моргание\ светодиодом}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00086}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1aa610f6df44c939aa7d45e318036fa03b}{00086}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1aa610f6df44c939aa7d45e318036fa03b}{LED\_IS\_FADING}}\ =\ 3,\ \ \ \ \textcolor{comment}{///<\ Плавное\ моргание\ светодиодом}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00087}00087\ \}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{GPIO\_LEDStateTypeDef}};} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00088}00088\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00089}00089\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00090}00090\ \textcolor{comment}{\ \ *\ @brief\ Структура\ светодиода}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00091}00091\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_GPIO\_LEDS}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00092}00092\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00093}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{00093}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00094}00094\ \{} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00095}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435}{00095}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{GPIO\_LEDStateTypeDef}}\ \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435}{state}};\ \ \ \ \ \textcolor{comment}{///<\ Текущий\ режим\ работы\ светодиода}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00096}00096\ \ \ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00097}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a831923d4d157267ecc2f1add1c49adcf}{00097}}\ \ \ GPIO\_TypeDef\ \ *\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a831923d4d157267ecc2f1add1c49adcf}{LED\_Port}};\ \ \ \ \ \ \ \ \textcolor{comment}{///<\ GPIO\ порт\ ножки\ светодиода}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00098}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a684ff60e4c94daf2221524cdc6fcc978}{00098}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a684ff60e4c94daf2221524cdc6fcc978}{LED\_Pin}};\ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ GPIO\ пин\ ножки\ светодиода}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00099}00099\ \ \ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00100}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_abe9aadc0b28d042267f7155e187a1816}{00100}}\ \ \ uint8\_t\ \ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_abe9aadc0b28d042267f7155e187a1816}{LED\_ActiveLvl}};\ \ \ \ \textcolor{comment}{///<\ Активный\ уровень\ ножки\ (при\ котором\ светодиод\ горит)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00101}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec}{00101}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec}{LED\_Period}};\ \ \ \ \ \ \ \textcolor{comment}{///<\ Период\ моргания\ светодиода}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00102}00102\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00103}00103\ \ \ uint32\_t\ \ \ \ \ \ tickprev;} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00104}00104\ \}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}};} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00105}00105\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00106}00106\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00107}00107\ \textcolor{comment}{\ \ *\ @brief\ Структура\ кнопки}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00108}00108\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_GPIO\_SWITCH}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00109}00109\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00110}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{00110}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00111}00111\ \{} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00112}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a}{00112}}\ \ \ GPIO\_TypeDef\ \ *\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a}{Sw\_Port}};\ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ GPIO\ порт\ ножки\ кнопки}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00113}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032}{00113}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032}{Sw\_Pin}};\ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ GPIO\ пин\ ножки\ кнопки}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00114}00114\ \ \ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00115}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405}{00115}}\ \ \ uint8\_t\ \ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405}{Sw\_ActiveLvl}};\ \ \ \ \ \textcolor{comment}{///<\ Активный\ уровень\ ножки\ (при\ котором\ кнопка\ нажата)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00116}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a245f1dc811279ce5d4598582db979a89}{00116}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a245f1dc811279ce5d4598582db979a89}{Sw\_PrevState}};\ \ \ \ \ \textcolor{comment}{///<\ Предыдущее\ состояние\ кнопки}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00117}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}{00117}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}{Sw\_FilterDelay}};\ \ \ \textcolor{comment}{///<\ Фильтр\ от\ дребезга\ (в\ мс)}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00118}00118\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00119}00119\ \ \ uint32\_t\ \ \ \ \ \ tickprev;\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00120}00120\ \}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}};} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00121}00121\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00044}00044\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00045}00045\ \textcolor{preprocessor}{\#ifndef\ SW\_ON}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00046}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga19d9e3aced311179a2914e0c9b13d0f9}{00046}}\ \textcolor{preprocessor}{\#define\ SW\_ON\ 1\ \ \ }\textcolor{comment}{///<\ Состояние\ пина\ при\ нажатой\ кнопке}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00047}00047\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00048}00048\ \textcolor{preprocessor}{\#ifndef\ SW\_OFF}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00049}\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_gacd8900c9ec0efde1da3253b718574067}{00049}}\ \textcolor{preprocessor}{\#define\ SW\_OFF\ 0\ \ }\textcolor{comment}{///<\ Состояние\ пина\ при\ отжатой\ кнопке}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00050}00050\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00051}00051\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00052}00052\ \textcolor{comment}{/**\ GPIO\_INIT}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00053}00053\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00054}00054\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00055}00055\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00056}00056\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00057}00057\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00058}00058\ \textcolor{comment}{\ \ *\ @brief\ Режимы\ работы\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00059}00059\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_GPIO\_LEDS}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00060}00060\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00061}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{00061}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{enum}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00062}00062\ \{} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00063}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a74276cd2464314e422e8a144483f74ae}{00063}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a74276cd2464314e422e8a144483f74ae}{LED\_IS\_OFF}}\ =\ 0,\ \ \ \ \ \ \ \textcolor{comment}{///<\ Светодиод\ выключен}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00064}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1af6abfb9c5b95abbdb239590f2cd245ea}{00064}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1af6abfb9c5b95abbdb239590f2cd245ea}{LED\_IS\_ON}}\ =\ 1,\ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Светодиод\ включен}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00065}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a2445895bed5dcbedc82ea3ef02bec6fb}{00065}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a2445895bed5dcbedc82ea3ef02bec6fb}{LED\_IS\_BLINKING}}\ =\ 2,\ \ \textcolor{comment}{///<\ Моргание\ светодиодом}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00066}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1aa610f6df44c939aa7d45e318036fa03b}{00066}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1aa610f6df44c939aa7d45e318036fa03b}{LED\_IS\_FADING}}\ =\ 3,\ \ \ \ \textcolor{comment}{///<\ Плавное\ моргание\ светодиодом}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00067}00067\ \}\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{GPIO\_LEDStateTypeDef}};} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00068}00068\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00069}00069\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00070}00070\ \textcolor{comment}{\ \ *\ @brief\ Структура\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00071}00071\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_GPIO\_LEDS}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00072}00072\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00073}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{00073}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00074}00074\ \{} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00075}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435}{00075}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{GPIO\_LEDStateTypeDef}}\ \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435}{state}};\ \ \ \ \ \textcolor{comment}{///<\ Текущий\ режим\ работы\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00076}00076\ \ \ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00077}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a831923d4d157267ecc2f1add1c49adcf}{00077}}\ \ \ GPIO\_TypeDef\ \ *\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a831923d4d157267ecc2f1add1c49adcf}{LED\_Port}};\ \ \ \ \ \ \ \ \textcolor{comment}{///<\ GPIO\ порт\ ножки\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00078}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a684ff60e4c94daf2221524cdc6fcc978}{00078}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a684ff60e4c94daf2221524cdc6fcc978}{LED\_Pin}};\ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ GPIO\ пин\ ножки\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00079}00079\ \ \ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00080}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_abe9aadc0b28d042267f7155e187a1816}{00080}}\ \ \ uint8\_t\ \ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_abe9aadc0b28d042267f7155e187a1816}{LED\_ActiveLvl}};\ \ \ \ \textcolor{comment}{///<\ Активный\ уровень\ ножки\ (при\ котором\ светодиод\ горит)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00081}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec}{00081}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec}{LED\_Period}};\ \ \ \ \ \ \ \textcolor{comment}{///<\ Период\ моргания\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00082}00082\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00083}00083\ \ \ uint32\_t\ \ \ \ \ \ tickprev;} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00084}00084\ \}\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}};} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00085}00085\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00086}00086\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00087}00087\ \textcolor{comment}{\ \ *\ @brief\ Структура\ кнопки}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00088}00088\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_GPIO\_SWITCH}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00089}00089\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00090}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{00090}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00091}00091\ \{} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00092}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a}{00092}}\ \ \ GPIO\_TypeDef\ \ *\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a}{Sw\_Port}};\ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ GPIO\ порт\ ножки\ кнопки}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00093}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032}{00093}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032}{Sw\_Pin}};\ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ GPIO\ пин\ ножки\ кнопки}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00094}00094\ \ \ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00095}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405}{00095}}\ \ \ uint8\_t\ \ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405}{Sw\_ActiveLvl}};\ \ \ \ \ \textcolor{comment}{///<\ Активный\ уровень\ ножки\ (при\ котором\ кнопка\ нажата)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00096}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a245f1dc811279ce5d4598582db979a89}{00096}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a245f1dc811279ce5d4598582db979a89}{Sw\_PrevState}};\ \ \ \ \ \textcolor{comment}{///<\ Предыдущее\ состояние\ кнопки}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00097}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}{00097}}\ \ \ uint32\_t\ \ \ \ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}{Sw\_FilterDelay}};\ \ \ \textcolor{comment}{///<\ Фильтр\ от\ дребезга\ (в\ мс)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00098}00098\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00099}00099\ \ \ uint32\_t\ \ \ \ \ \ tickprev;\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00100}00100\ \}\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}};} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00101}00101\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00102}00102\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00103}00103\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00104}00104\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00105}00105\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00106}00106\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_GPIO\_GENERAL\ \ General\ tools}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00107}00107\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_GPIO}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00108}00108\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Общие\ функции/макросы\ для\ работы\ с\ GPIO}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00109}00109\ \textcolor{comment}{\ \ *\ @par\ Пример\ использования:}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00110}00110\ \textcolor{comment}{\ \ \ \ @code}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00111}00111\ \textcolor{comment}{\ \ \ \ //\ Включаем\ тактирование\ порта\ GPIOA}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00112}00112\ \textcolor{comment}{\ \ \ \ GPIO\_Clock\_Enable(GPIOA);}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00113}00113\ \textcolor{comment}{\ \ \ \ @endcode}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00114}00114\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00115}00115\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00116}00116\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00117}00117\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga962f010f783b81fcdd27eb6b53db28e6}{GPIO\_Clock\_Enable}}(GPIO\_TypeDef\ *GPIOx);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00118}00118\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00119}00119\ \textcolor{comment}{/**\ MYLIBS\_GPIO\_GENERAL}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00120}00120\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00121}00121\ \textcolor{comment}{\ \ */}} \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00122}00122\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00123}00123\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00124}00124\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00125}00125\ \textcolor{comment}{}\textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00126}00126\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_GPIO\_GENERAL\ \ General\ tools}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00127}00127\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_GPIO}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00128}00128\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Общие\ функции/макросы\ для\ работы\ с\ GPIO}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00129}00129\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00130}00130\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00131}00131\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00132}00132\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga962f010f783b81fcdd27eb6b53db28e6}{GPIO\_Clock\_Enable}}(GPIO\_TypeDef\ *GPIOx);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00133}00133\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00134}00134\ \textcolor{comment}{/**\ MYLIBS\_GPIO\_GENERAL}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00135}00135\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00136}00136\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00137}00137\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00138}00138\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00139}00139\ \textcolor{comment}{*\ @addtogroup\ MYLIBS\_GPIO\_SWITCH\ \ Switch\ tools}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00140}00140\ \textcolor{comment}{*\ @ingroup\ \ \ \ MY\_LIBS\_GPIO}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00141}00141\ \textcolor{comment}{*\ @brief\ \ \ \ \ \ Функции\ для\ работы\ с\ GPIO,\ как\ с\ кнопкой}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00142}00142\ \textcolor{comment}{*\ @\{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00143}00143\ \textcolor{comment}{*/}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00144}00144\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00145}00145\ \textcolor{comment}{/*\ Инициализировать\ кнопку\ (структуру\ кнопки)\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00146}00146\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_gacafee0e68877f2b25df843356871d1f7}{GPIO\_Switch\_Init}}(\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}}\ *sw,\ GPIO\_TypeDef\ *GPIOx,\ uint32\_t\ GPIO\_PIN\_X,\ uint8\_t\ SW\_On\_State);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00147}00147\ \textcolor{comment}{/*\ Считать\ состоянии\ кнопки\ запуска\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00148}00148\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_ga960b24335b2026abcad126ab8c422d70}{GPIO\_Read\_Switch}}(\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}}\ *swstart);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00149}00149\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00150}00150\ \textcolor{comment}{/**\ MYLIBS\_GPIO\_SWITCH}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00151}00151\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00152}00152\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00153}00153\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00123}00123\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00124}00124\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_GPIO\_SWITCH\ \ Switch\ tools}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00125}00125\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_GPIO}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00126}00126\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ работы\ с\ GPIO,\ как\ с\ кнопкой}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00127}00127\ \textcolor{comment}{\ \ *\ @par\ Пример\ использования:}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00128}00128\ \textcolor{comment}{\ \ \ \ @code}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00129}00129\ \textcolor{comment}{\ \ \ \ MX\_GPIO\_Init();\ //\ инициализация\ пина\ аппаратная}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00130}00130\ \textcolor{comment}{\ \ \ \ }} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00131}00131\ \textcolor{comment}{\ \ \ \ //\ Инициализация\ кнопки\ на\ порте\ GPIOB,\ пин\ 0,\ активный\ уровень\ 1}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00132}00132\ \textcolor{comment}{\ \ \ \ GPIO\_SwitchTypeDef\ sw1;}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00133}00133\ \textcolor{comment}{\ \ \ \ GPIO\_Switch\_Init(\&sw1,\ GPIOB,\ GPIO\_PIN\_0,\ 1);\ //\ или\ дефайн\ SW\_ON/SW\_OFF}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00134}00134\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00135}00135\ \textcolor{comment}{\ \ \ \ //\ Считываем\ состояние\ кнопки}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00136}00136\ \textcolor{comment}{\ \ \ \ if(GPIO\_Read\_Switch(\&sw1))}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00137}00137\ \textcolor{comment}{\ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00138}00138\ \textcolor{comment}{\ \ \ \ \ \ \ \ //\ Кнопка\ нажата}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00139}00139\ \textcolor{comment}{\ \ \ \ \ \ \ \ LED\_ON();}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00140}00140\ \textcolor{comment}{\ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00141}00141\ \textcolor{comment}{\ \ \ \ else}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00142}00142\ \textcolor{comment}{\ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00143}00143\ \textcolor{comment}{\ \ \ \ \ \ \ \ //\ Кнопка\ отжата}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00144}00144\ \textcolor{comment}{\ \ \ \ \ \ \ \ LED\_OFF();}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00145}00145\ \textcolor{comment}{\ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00146}00146\ \textcolor{comment}{\ \ \ \ @endcode}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00147}00147\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00148}00148\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00149}00149\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00150}00150\ \textcolor{comment}{/*\ Инициализировать\ кнопку\ (структуру\ кнопки)\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00151}00151\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_gacafee0e68877f2b25df843356871d1f7}{GPIO\_Switch\_Init}}(\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}}\ *sw,\ GPIO\_TypeDef\ *GPIOx,\ uint32\_t\ GPIO\_PIN\_X,\ uint8\_t\ SW\_On\_State);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00152}00152\ \textcolor{comment}{/*\ Считать\ состоянии\ кнопки\ запуска\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00153}00153\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_ga960b24335b2026abcad126ab8c422d70}{GPIO\_Read\_Switch}}(\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}}\ *swstart);} \DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00154}00154\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00155}00155\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00156}00156\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_GPIO\_LEDS\ \ LED\ tools}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00157}00157\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_GPIO}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00158}00158\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ работы\ с\ GPIO,\ для\ управления\ светодиодом}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00159}00159\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00160}00160\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00161}00161\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00162}00162\ \textcolor{comment}{/*\ Инициализировать\ светодиод\ (структуру\ светодиода)\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00163}00163\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gac936453c7a0841c0b17bcfdae4958084}{GPIO\_LED\_Init}}(\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led,\ GPIO\_TypeDef\ *GPIOx,\ uint32\_t\ GPIO\_PIN\_X,\ uint8\_t\ LED\_On\_State);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00164}00164\ \textcolor{comment}{/*\ Включить\ светодиод\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00165}00165\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ga4b9572949326b050694cd55d0a7e5f6c}{GPIO\_LED\_On}}\ (\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00166}00166\ \textcolor{comment}{/*\ Выключить\ светодиод\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00167}00167\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaadda2d4f021390a4e392210a5ace5357}{GPIO\_LED\_Off}}\ (\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00168}00168\ \textcolor{comment}{/*\ Выставить\ светодиод\ по\ переменной\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00169}00169\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gae78b570447d55a462a679a89dbaa8ea2}{GPIO\_LED\_Set}}\ (\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led,\ uint8\_t\ led\_state);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00170}00170\ \textcolor{comment}{/*\ Активировать\ моргание\ светодиодом\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00171}00171\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaf22f44ecaf6a1932b47edc5a845b03a9}{GPIO\_LED\_Blink\_Start}}\ (\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led,\ uint32\_t\ period);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00172}00172\ \textcolor{comment}{/*\ Активировать\ моргание\ светодиодом\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00173}00173\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaa00f20021781464af3dfe74aa3e59a0a}{GPIO\_LED\_Fading\_Start}}(\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led,\ uint32\_t\ period);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00174}00174\ \textcolor{comment}{/*\ Управление\ динамическими\ режимами\ свечения\ светодиода\ */}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00175}00175\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d472b6340c7f19bb2}{GPIO\_LED\_Dynamic\_Handle}}(\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led);} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00176}00176\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00177}00177\ \textcolor{comment}{/**\ MYLIBS\_GPIO\_LEDS}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00178}00178\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00179}00179\ \textcolor{comment}{\ \ */}\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00180}00180\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00181}00181\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00182}00182\ } -\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00183}00183\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ \_\_GPIO\_GENERAL\_H\_}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00155}00155\ \textcolor{comment}{/**\ MYLIBS\_GPIO\_SWITCH}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00156}00156\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00157}00157\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00158}00158\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00159}00159\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00160}00160\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00161}00161\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_GPIO\_LEDS\ \ LED\ tools}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00162}00162\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_GPIO}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00163}00163\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ работы\ с\ GPIO,\ для\ управления\ светодиодом}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00164}00164\ \textcolor{comment}{\ \ *\ @par\ Пример\ использования:}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00165}00165\ \textcolor{comment}{\ \ \ \ @code}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00166}00166\ \textcolor{comment}{\ \ \ \ MX\_GPIO\_Init();\ //\ инициализация\ пина\ аппаратная}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00167}00167\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00168}00168\ \textcolor{comment}{\ \ \ \ //\ Инициализация\ светодиода\ на\ порте\ GPIOA,\ пин\ 5,\ активный\ уровень\ 0}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00169}00169\ \textcolor{comment}{\ \ \ \ GPIO\_LEDTypeDef\ led;}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00170}00170\ \textcolor{comment}{\ \ \ \ GPIO\_LED\_Init(\&led,\ GPIOA,\ GPIO\_PIN\_5,\ 0);\ //\ или\ дефайн\ LED\_ON/LED\_OFF}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00171}00171\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00172}00172\ \textcolor{comment}{\ \ \ \ //\ Включение\ светодиода}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00173}00173\ \textcolor{comment}{\ \ \ \ GPIO\_LED\_On(\&led);}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00174}00174\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00175}00175\ \textcolor{comment}{\ \ \ \ //\ Запуск\ моргания}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00176}00176\ \textcolor{comment}{\ \ \ \ GPIO\_LED\_Blink\_Start(\&led,\ 500);\ //\ Период\ 500\ мс}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00177}00177\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00178}00178\ \textcolor{comment}{\ \ \ \ //\ В\ основном\ цикле}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00179}00179\ \textcolor{comment}{\ \ \ \ while\ (1)\ \{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00180}00180\ \textcolor{comment}{\ \ \ \ \ \ GPIO\_LED\_Dynamic\_Handle(\&led);}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00181}00181\ \textcolor{comment}{\ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00182}00182\ \textcolor{comment}{\ \ \ \ @endcode}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00183}00183\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00184}00184\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00185}00185\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00186}00186\ \textcolor{comment}{/*\ Инициализировать\ светодиод\ (структуру\ светодиода)\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00187}00187\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gac936453c7a0841c0b17bcfdae4958084}{GPIO\_LED\_Init}}(\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led,\ GPIO\_TypeDef\ *GPIOx,\ uint32\_t\ GPIO\_PIN\_X,\ uint8\_t\ LED\_On\_State);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00188}00188\ \textcolor{comment}{/*\ Включить\ светодиод\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00189}00189\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ga4b9572949326b050694cd55d0a7e5f6c}{GPIO\_LED\_On}}\ (\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00190}00190\ \textcolor{comment}{/*\ Выключить\ светодиод\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00191}00191\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaadda2d4f021390a4e392210a5ace5357}{GPIO\_LED\_Off}}\ (\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00192}00192\ \textcolor{comment}{/*\ Выставить\ светодиод\ по\ переменной\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00193}00193\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gae78b570447d55a462a679a89dbaa8ea2}{GPIO\_LED\_Set}}\ (\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led,\ uint8\_t\ led\_state);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00194}00194\ \textcolor{comment}{/*\ Активировать\ моргание\ светодиодом\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00195}00195\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaf22f44ecaf6a1932b47edc5a845b03a9}{GPIO\_LED\_Blink\_Start}}\ (\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led,\ uint32\_t\ period);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00196}00196\ \textcolor{comment}{/*\ Активировать\ моргание\ светодиодом\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00197}00197\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaa00f20021781464af3dfe74aa3e59a0a}{GPIO\_LED\_Fading\_Start}}(\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led,\ uint32\_t\ period);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00198}00198\ \textcolor{comment}{/*\ Управление\ динамическими\ режимами\ свечения\ светодиода\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00199}00199\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d472b6340c7f19bb2}{GPIO\_LED\_Dynamic\_Handle}}(\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ *led);} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00200}00200\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00201}00201\ \textcolor{comment}{/**\ MYLIBS\_GPIO\_LEDS}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00202}00202\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00203}00203\ \textcolor{comment}{\ \ */}\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00204}00204\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00205}00205\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00206}00206\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00207}00207\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00208}00208\ \textcolor{comment}{\ *\ @cond\ GPIO\_INTERNAL}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00209}00209\ \textcolor{comment}{\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00210}00210\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00211}00211\ \textcolor{comment}{//\ /**}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00212}00212\ \textcolor{comment}{//\ \ \ *\ @brief\ Маппинг\ альтернативной\ функции\ SPI\ между\ GPIO}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00213}00213\ \textcolor{comment}{//\ \ \ *\ @ingroup\ \ MYLIBS\_GPIO\_GENERAL}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00214}00214\ \textcolor{comment}{//\ \ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00215}00215\ \textcolor{comment}{//\ \#define\ SPI\_Alternate\_Mapping(INSTANCE)\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00216}00216\ \textcolor{comment}{//\ ((((INSTANCE)\ ==\ TIM1)\ \ ||\ ((INSTANCE)\ ==\ TIM2))?\ \ \ \ \ GPIO\_AF1\_TIM1:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00217}00217\ \textcolor{comment}{//\ (((INSTANCE)\ ==\ TIM3)\ \ \ ||\ ((INSTANCE)\ ==\ TIM4)\ \ \ ||\ ((INSTANCE)\ ==\ TIM5))?\ GPIO\_AF2\_TIM3:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00218}00218\ \textcolor{comment}{//\ (((INSTANCE)\ ==\ TIM8)\ \ \ ||\ ((INSTANCE)\ ==\ TIM9)\ \ \ ||\ ((INSTANCE)\ ==\ TIM10)\ ||\ ((INSTANCE)\ ==\ TIM11))?\ GPIO\_AF3\_TIM8:\ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00219}00219\ \textcolor{comment}{//\ (((INSTANCE)\ ==\ TIM12)\ \ ||\ ((INSTANCE)\ ==\ TIM13)\ \ ||\ ((INSTANCE)\ ==\ TIM14))?\ GPIO\_AF9\_TIM12:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00220}00220\ \textcolor{comment}{//\ (0))}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00221}00221\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00222}00222\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00223}00223\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00224}00224\ \textcolor{comment}{\ \ *\ @brief\ Маппинг\ альтернативной\ функции\ TIM\ между\ GPIO}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00225}00225\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_GPIO\_GENERAL}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00226}00226\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00227}00227\ \textcolor{preprocessor}{\#define\ GPIO\_TIM\_Alternate\_Mapping(INSTANCE)\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00228}00228\ \textcolor{preprocessor}{((((INSTANCE)\ ==\ TIM1)\ \ ||\ ((INSTANCE)\ ==\ TIM2))?\ GPIO\_AF1\_TIM1:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00229}00229\ \textcolor{preprocessor}{(((INSTANCE)\ ==\ TIM3)\ \ \ ||\ ((INSTANCE)\ ==\ TIM4)\ \ \ ||\ ((INSTANCE)\ ==\ TIM5))?\ GPIO\_AF2\_TIM3:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00230}00230\ \textcolor{preprocessor}{(((INSTANCE)\ ==\ TIM8)\ \ \ ||\ ((INSTANCE)\ ==\ TIM9)\ \ \ ||\ ((INSTANCE)\ ==\ TIM10)\ ||\ ((INSTANCE)\ ==\ TIM11))?\ GPIO\_AF3\_TIM8:\ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00231}00231\ \textcolor{preprocessor}{(((INSTANCE)\ ==\ TIM12)\ \ ||\ ((INSTANCE)\ ==\ TIM13)\ \ ||\ ((INSTANCE)\ ==\ TIM14))?\ GPIO\_AF9\_TIM12:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00232}00232\ \textcolor{preprocessor}{(0))}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00233}00233\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00234}00234\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00235}00235\ \textcolor{comment}{/**\ @endcond\ */}} +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00236}00236\ } +\DoxyCodeLine{\Hypertarget{general__gpio_8h_source_l00237}00237\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ \_\_GPIO\_GENERAL\_H\_}} \end{DoxyCode} diff --git a/Doc/latex/general__tim_8c.tex b/Doc/latex/general__tim_8c.tex index 6127350..c305423 100644 --- a/Doc/latex/general__tim_8c.tex +++ b/Doc/latex/general__tim_8c.tex @@ -1,16 +1,17 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/general\+\_\+tim.c File Reference} -\hypertarget{general__tim_8c}{}\label{general__tim_8c}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_tim.c@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_tim.c}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Src/general\+\_\+tim.c File Reference} +\hypertarget{general__tim_8c}{}\label{general__tim_8c}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_tim.c@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_tim.c}} Модуль для инициализации таймеров и работы с ними. {\ttfamily \#include "{}general\+\_\+tim.\+h"{}}\newline -Include dependency graph for general\+\_\+tim.\+c\+:\nopagebreak +Include dependency graph for general\+\_\+tim.\+c\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=262pt]{general__tim_8c__incl} +\includegraphics[width=229pt]{general__tim_8c__incl} \end{center} \end{figure} \doxysubsubsection*{Functions} diff --git a/Doc/latex/general__tim_8c__incl.md5 b/Doc/latex/general__tim_8c__incl.md5 index 696c0fd..8497f91 100644 --- a/Doc/latex/general__tim_8c__incl.md5 +++ b/Doc/latex/general__tim_8c__incl.md5 @@ -1 +1 @@ -72a5e02c33b34ceb71e8065b44df034a \ No newline at end of file +018b6018bdcb384d431e75597bba52d4 \ No newline at end of file diff --git a/Doc/latex/general__tim_8c__incl.pdf b/Doc/latex/general__tim_8c__incl.pdf index 130e172..8adfc4c 100644 Binary files a/Doc/latex/general__tim_8c__incl.pdf and b/Doc/latex/general__tim_8c__incl.pdf differ diff --git a/Doc/latex/general__tim_8c_source.tex b/Doc/latex/general__tim_8c_source.tex index 06906f9..ff74590 100644 --- a/Doc/latex/general__tim_8c_source.tex +++ b/Doc/latex/general__tim_8c_source.tex @@ -1,5 +1,5 @@ \doxysection{general\+\_\+tim.\+c} -\hypertarget{general__tim_8c_source}{}\label{general__tim_8c_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_tim.c@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_tim.c}} +\hypertarget{general__tim_8c_source}{}\label{general__tim_8c_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_tim.c@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Src/general\_tim.c}} \mbox{\hyperlink{general__tim_8c}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00001}00001\ \textcolor{comment}{/**\ }} @@ -199,7 +199,7 @@ \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00195}00195\ \ \ GPIO\_InitStruct.Mode\ =\ GPIO\_MODE\_AF\_PP;} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00196}00196\ \ \ GPIO\_InitStruct.Pull\ =\ GPIO\_PULLUP;} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00197}00197\ \ \ GPIO\_InitStruct.Speed\ =\ GPIO\_SPEED\_FREQ\_LOW;} -\DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00198}00198\ \ \ GPIO\_InitStruct.Alternate\ =\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga580b842096340b066c28b24d6b315be6}{GPIO\_TIM\_Alternate\_Mapping}}(henc-\/>\mbox{\hyperlink{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}{htim}}-\/>Instance);} +\DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00198}00198\ \ \ GPIO\_InitStruct.Alternate\ =\ GPIO\_TIM\_Alternate\_Mapping(henc-\/>\mbox{\hyperlink{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}{htim}}-\/>Instance);} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00199}00199\ \ \ \textcolor{keywordflow}{if}(GPIO\_InitStruct.Alternate)} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00200}00200\ \ \ \ \ HAL\_GPIO\_Init(henc-\/>\mbox{\hyperlink{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9}{GPIOx}},\ \&GPIO\_InitStruct);} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00201}00201\ \ \ } @@ -259,7 +259,7 @@ \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00255}00255\ \ \ \textcolor{keywordflow}{else}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00256}00256\ \ \ \ \ GPIO\_InitStruct.Pull\ =\ GPIO\_PULLUP;} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00257}00257\ \ \ GPIO\_InitStruct.Speed\ =\ GPIO\_SPEED\_FREQ\_LOW;\ \ } -\DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00258}00258\ \ \ GPIO\_InitStruct.Alternate\ =\ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga580b842096340b066c28b24d6b315be6}{GPIO\_TIM\_Alternate\_Mapping}}(htim-\/>Instance);} +\DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00258}00258\ \ \ GPIO\_InitStruct.Alternate\ =\ GPIO\_TIM\_Alternate\_Mapping(htim-\/>Instance);} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00259}00259\ \ \ \textcolor{keywordflow}{if}(GPIO\_InitStruct.Alternate)} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00260}00260\ \ \ \ \ HAL\_GPIO\_Init(GPIOx,\ \&GPIO\_InitStruct);} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00261}00261\ \ \ } @@ -407,7 +407,7 @@ \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00403}00403\ \textcolor{comment}{\ \ *\ @brief\ \ Инициализация\ CLK\ и\ NVIC\ таймеров.}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00404}00404\ \textcolor{comment}{\ \ *\ @param\ \ htim\ Указатель\ на\ хендл\ таймера.}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00405}00405\ \textcolor{comment}{\ \ *\ @note\ \ \ Чтобы\ не\ генерировать\ функцию\ с\ иницилизацией\ неиспользуемых\ таймеров,}} -\DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00406}00406\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ дефайнами\ в\ general\_tim.h\ определяются\ используемые\ таймеры.}} +\DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00406}00406\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ дефайнами\ @ref\ TIM\_INIT\ в\ @ref\ general\_tim.h\ определяются\ используемые\ таймеры.}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00407}00407\ \textcolor{comment}{\ \ */}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00408}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931}{00408}}\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931}{TIM\_Base\_MspInit}}(TIM\_HandleTypeDef*\ htim,\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\_ITModeTypeDef}}\ it\_mode)} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00409}00409\ \{} @@ -616,7 +616,7 @@ \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00612}00612\ \textcolor{comment}{\ \ *\ @brief\ \ Деинициализация\ CLK\ и\ NVIC\ таймеров.}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00613}00613\ \textcolor{comment}{\ \ *\ @param\ \ htim\ Указатель\ на\ хендл\ таймера.}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00614}00614\ \textcolor{comment}{\ \ *\ @note\ \ \ Чтобы\ не\ генерировать\ функцию\ с\ деиницилизацией\ неиспользуемых\ таймеров,}} -\DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00615}00615\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ дефайнами\ в\ general\_tim.h\ определяются\ используемые\ таймеры.}} +\DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00615}00615\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ дефайнами\ @ref\ TIM\_INIT\ в\ @ref\ general\_tim.h\ определяются\ используемые\ таймеры.}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00616}00616\ \textcolor{comment}{\ \ */}} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00617}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115}{00617}}\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115}{TIM\_Base\_MspDeInit}}(TIM\_HandleTypeDef*\ htim)} \DoxyCodeLine{\Hypertarget{general__tim_8c_source_l00618}00618\ \{} diff --git a/Doc/latex/general__tim_8h.tex b/Doc/latex/general__tim_8h.tex index 5e69f8f..b359f78 100644 --- a/Doc/latex/general__tim_8h.tex +++ b/Doc/latex/general__tim_8h.tex @@ -1,5 +1,5 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/general\+\_\+tim.h File Reference} -\hypertarget{general__tim_8h}{}\label{general__tim_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_tim.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_tim.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/general\+\_\+tim.h File Reference} +\hypertarget{general__tim_8h}{}\label{general__tim_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_tim.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_tim.h}} Заголовочный файл для модуля инициализации таймеров и работы с ними. @@ -7,14 +7,16 @@ {\ttfamily \#include "{}mylibs\+\_\+defs.\+h"{}}\newline {\ttfamily \#include "{}general\+\_\+gpio.\+h"{}}\newline -Include dependency graph for general\+\_\+tim.\+h\+:\nopagebreak +Include dependency graph for general\+\_\+tim.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=260pt]{general__tim_8h__incl} +\includegraphics[width=229pt]{general__tim_8h__incl} \end{center} \end{figure} -This graph shows which files directly or indirectly include this file\+:\nopagebreak +This graph shows which files directly or indirectly include this file\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode @@ -86,6 +88,18 @@ enum \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325 \doxysubsubsection*{Functions} \begin{DoxyCompactItemize} \item +HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec}{TIM\+\_\+\+Base\+\_\+\+Init}} (\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\+\_\+\+Settings\+Type\+Def}} \texorpdfstring{$\ast$}{*}stim) +\begin{DoxyCompactList}\small\item\em Инициализация таймера. \end{DoxyCompactList}\item +void \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931}{TIM\+\_\+\+Base\+\_\+\+Msp\+Init}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim, \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}} it\+\_\+mode) +\begin{DoxyCompactList}\small\item\em Инициализация CLK и NVIC таймеров. \end{DoxyCompactList}\item +void \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115}{TIM\+\_\+\+Base\+\_\+\+Msp\+De\+Init}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim) +\begin{DoxyCompactList}\small\item\em Деинициализация CLK и NVIC таймеров. \end{DoxyCompactList}\item +HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834}{TIM\+\_\+\+Delay\+\_\+\+Start}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim) +\begin{DoxyCompactList}\small\item\em Начать отсчет неблокирующей задержки. \end{DoxyCompactList}\item +HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e}{TIM\+\_\+\+Delay}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim, uint16\+\_\+t delay) +\begin{DoxyCompactList}\small\item\em Задержка в тиках таймера (блокирующая). \end{DoxyCompactList}\item +HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b}{TIM\+\_\+\+Delay\+\_\+\+Non\+Blocking}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim, uint16\+\_\+t delay) +\begin{DoxyCompactList}\small\item\em Задержка в тиках таймера (неблокирующая). \end{DoxyCompactList}\item HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_gadb2f465d89f609e035867e980c3a29c6}{TIM\+\_\+\+Output\+\_\+\+PWM\+\_\+\+Init}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim, TIM\+\_\+\+OC\+\_\+\+Init\+Type\+Def \texorpdfstring{$\ast$}{*}s\+Config\+OC, uint32\+\_\+t TIM\+\_\+\+CHANNEL, GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}GPIOx, uint32\+\_\+t PWM\+\_\+\+PIN) \begin{DoxyCompactList}\small\item\em Инициализация выхода ШИМ таймера. \end{DoxyCompactList}\item HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_gae2608ca8023e9a0713af0b4fbfbc1889}{TIM\+\_\+\+OC\+\_\+\+Comparator\+\_\+\+Init}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim, uint32\+\_\+t TIM\+\_\+\+CHANNEL) @@ -95,19 +109,7 @@ HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_ HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_gac3bc6525f88c275e47eb864e6d567501}{TIM\+\_\+\+Encoder\+\_\+\+Read}} (\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \texorpdfstring{$\ast$}{*}henc) \begin{DoxyCompactList}\small\item\em Считать энкодер. \end{DoxyCompactList}\item int \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e3a357ddefe323412761}{TIM\+\_\+\+Encoder\+\_\+\+Read\+Switch}} (\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \texorpdfstring{$\ast$}{*}henc) -\begin{DoxyCompactList}\small\item\em Считать кнопку энкодера. \end{DoxyCompactList}\item -HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834}{TIM\+\_\+\+Delay\+\_\+\+Start}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim) -\begin{DoxyCompactList}\small\item\em Начать отсчет неблокирующей задержки. \end{DoxyCompactList}\item -HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e}{TIM\+\_\+\+Delay}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim, uint16\+\_\+t delay) -\begin{DoxyCompactList}\small\item\em Задержка в тиках таймера (блокирующая). \end{DoxyCompactList}\item -HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b}{TIM\+\_\+\+Delay\+\_\+\+Non\+Blocking}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim, uint16\+\_\+t delay) -\begin{DoxyCompactList}\small\item\em Задержка в тиках таймера (неблокирующая). \end{DoxyCompactList}\item -HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec}{TIM\+\_\+\+Base\+\_\+\+Init}} (\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\+\_\+\+Settings\+Type\+Def}} \texorpdfstring{$\ast$}{*}stim) -\begin{DoxyCompactList}\small\item\em Инициализация таймера. \end{DoxyCompactList}\item -void \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931}{TIM\+\_\+\+Base\+\_\+\+Msp\+Init}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim, \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}} it\+\_\+mode) -\begin{DoxyCompactList}\small\item\em Инициализация CLK и NVIC таймеров. \end{DoxyCompactList}\item -void \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115}{TIM\+\_\+\+Base\+\_\+\+Msp\+De\+Init}} (TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}htim) -\begin{DoxyCompactList}\small\item\em Деинициализация CLK и NVIC таймеров. \end{DoxyCompactList}\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Считать кнопку энкодера. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsection{Detailed Description} @@ -119,24 +121,26 @@ Definition in file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h +\label{doc-define-members} +\Hypertarget{general__tim_8h_doc-define-members} \doxysubsection{Macro Definition Documentation} -\Hypertarget{general__tim_8h_a867308f75c1be4f2090bcda3bcd900c9}\label{general__tim_8h_a867308f75c1be4f2090bcda3bcd900c9} -\index{general\_tim.h@{general\_tim.h}!TIM\_IT\_CONF\_Pos@{TIM\_IT\_CONF\_Pos}} +\Hypertarget{general__tim_8h_a867308f75c1be4f2090bcda3bcd900c9}\index{general\_tim.h@{general\_tim.h}!TIM\_IT\_CONF\_Pos@{TIM\_IT\_CONF\_Pos}} \index{TIM\_IT\_CONF\_Pos@{TIM\_IT\_CONF\_Pos}!general\_tim.h@{general\_tim.h}} \doxysubsubsection{\texorpdfstring{TIM\_IT\_CONF\_Pos}{TIM\_IT\_CONF\_Pos}} -{\footnotesize\ttfamily \#define TIM\+\_\+\+IT\+\_\+\+CONF\+\_\+\+Pos~0} +{\footnotesize\ttfamily \label{general__tim_8h_a867308f75c1be4f2090bcda3bcd900c9} +\#define TIM\+\_\+\+IT\+\_\+\+CONF\+\_\+\+Pos~0} -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00056}{56}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00057}{57}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{general__tim_8h_a8c43257cbfd6ac70b6eb0839e47bbd07}\label{general__tim_8h_a8c43257cbfd6ac70b6eb0839e47bbd07} -\index{general\_tim.h@{general\_tim.h}!TIM\_IT\_CONF@{TIM\_IT\_CONF}} +\Hypertarget{general__tim_8h_a8c43257cbfd6ac70b6eb0839e47bbd07}\index{general\_tim.h@{general\_tim.h}!TIM\_IT\_CONF@{TIM\_IT\_CONF}} \index{TIM\_IT\_CONF@{TIM\_IT\_CONF}!general\_tim.h@{general\_tim.h}} \doxysubsubsection{\texorpdfstring{TIM\_IT\_CONF}{TIM\_IT\_CONF}} -{\footnotesize\ttfamily \#define TIM\+\_\+\+IT\+\_\+\+CONF~(1$<$$<$(TIM\+\_\+\+IT\+\_\+\+CONF\+\_\+\+Pos))} +{\footnotesize\ttfamily \label{general__tim_8h_a8c43257cbfd6ac70b6eb0839e47bbd07} +\#define TIM\+\_\+\+IT\+\_\+\+CONF~(1$<$$<$(TIM\+\_\+\+IT\+\_\+\+CONF\+\_\+\+Pos))} -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00063}{63}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00064}{64}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. diff --git a/Doc/latex/general__tim_8h__dep__incl.md5 b/Doc/latex/general__tim_8h__dep__incl.md5 index 7a3703b..85cb58d 100644 --- a/Doc/latex/general__tim_8h__dep__incl.md5 +++ b/Doc/latex/general__tim_8h__dep__incl.md5 @@ -1 +1 @@ -a485be779e2e5c082a1deb15eb121995 \ No newline at end of file +48912ae69413105687efed9fcdd23d2d \ No newline at end of file diff --git a/Doc/latex/general__tim_8h__dep__incl.pdf b/Doc/latex/general__tim_8h__dep__incl.pdf index e465df7..d15d109 100644 Binary files a/Doc/latex/general__tim_8h__dep__incl.pdf and b/Doc/latex/general__tim_8h__dep__incl.pdf differ diff --git a/Doc/latex/general__tim_8h__incl.md5 b/Doc/latex/general__tim_8h__incl.md5 index 7522afe..e11dc17 100644 --- a/Doc/latex/general__tim_8h__incl.md5 +++ b/Doc/latex/general__tim_8h__incl.md5 @@ -1 +1 @@ -7a5e6f29199b63105a7df21ee26a08f8 \ No newline at end of file +72b7b62252ba432b33a3132214cb26dd \ No newline at end of file diff --git a/Doc/latex/general__tim_8h__incl.pdf b/Doc/latex/general__tim_8h__incl.pdf index c44349e..2bc48e2 100644 Binary files a/Doc/latex/general__tim_8h__incl.pdf and b/Doc/latex/general__tim_8h__incl.pdf differ diff --git a/Doc/latex/general__tim_8h_source.tex b/Doc/latex/general__tim_8h_source.tex index 9e69885..0f6d77b 100644 --- a/Doc/latex/general__tim_8h_source.tex +++ b/Doc/latex/general__tim_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{general\+\_\+tim.\+h} -\hypertarget{general__tim_8h_source}{}\label{general__tim_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_tim.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_tim.h}} +\hypertarget{general__tim_8h_source}{}\label{general__tim_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_tim.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/general\_tim.h}} \mbox{\hyperlink{general__tim_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00001}00001\ \textcolor{comment}{/**\ }} @@ -16,215 +16,292 @@ \DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00012}00012\ \textcolor{comment}{\ \ -\/\ @ref\ \ MYLIBS\_TIM\_DELAY\ \ \ \ —\ функции\ задержки\ через\ таймеры\ (blocking\ и\ non-\/blocking).}} \DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00013}00013\ \textcolor{comment}{\ \ -\/\ @ref\ \ MYLIBS\_TIM\_OC\ \ \ \ \ \ \ —\ настройка\ каналов\ Output\ Compare\ и\ PWM.}} \DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00014}00014\ \textcolor{comment}{\ \ -\/\ @ref\ \ MYLIBS\_TIM\_ENCODER\ \ —\ работа\ с\ энкодерами,\ чтение\ положения\ и\ кнопки.}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00015}00015\ \textcolor{comment}{*\ \ @note\ Требуется\ подключение\ модуля\ TIM\ в\ библиотеке\ HAL\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00016}00016\ \textcolor{comment}{@code\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00017}00017\ \textcolor{comment}{\#define\ HAL\_TIM\_MODULE\_ENABLED}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00018}00018\ \textcolor{comment}{@endcode}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00019}00019\ \textcolor{comment}{*************************************************************************/}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00020}00020\ \textcolor{preprocessor}{\#ifndef\ \_\_TIM\_GENERAL\_H\_}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00021}00021\ \textcolor{preprocessor}{\#define\ \_\_TIM\_GENERAL\_H\_}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00022}00022\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00023}00023\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00024}00024\ \textcolor{comment}{/////////////////////////-\/-\/-\/USER\ SETTINGS-\/-\/-\//////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00025}00025\ \textcolor{comment}{}\textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00026}00026\ \textcolor{comment}{\ \ *\ @addtogroup\ TIM\_INIT\ Init\ defines}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00027}00027\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MYLIBS\_TIM\_GENERAL}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00028}00028\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Настройка\ таймеров}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00029}00029\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00030}00030\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00031}00031\ \textcolor{preprocessor}{\#define\ HAL\_TIM\_MODULE\_ENABLED}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00032}00032\ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00033}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga54a98c21365e0bc45b81555d2b101f2b}{00033}}\ \textcolor{preprocessor}{\#define\ USE\_TIM1\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM1\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00034}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga72535a44955b43cbcd56e25039ab32eb}{00034}}\ \textcolor{preprocessor}{\#define\ USE\_TIM2\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM2\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00035}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga5b5685a43273b6e37242a4aba3ee0617}{00035}}\ \textcolor{preprocessor}{\#define\ USE\_TIM3\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM3\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00036}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga1493b39c9214501180b81b4c892f9be0}{00036}}\ \textcolor{preprocessor}{\#define\ USE\_TIM4\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM4\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00037}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga252f4fba93fc265110e83760e0590af3}{00037}}\ \textcolor{preprocessor}{\#define\ USE\_TIM5\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM5\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00038}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga8fe31b98160627d19038222910be3f46}{00038}}\ \textcolor{preprocessor}{\#define\ USE\_TIM6\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM6\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00039}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga7cdc54cc8cbbb6e9f60001f1e3e6ec67}{00039}}\ \textcolor{preprocessor}{\#define\ USE\_TIM7\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM7\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00040}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga28ba33d7c6bf22821dafa5bcee4854be}{00040}}\ \textcolor{preprocessor}{\#define\ USE\_TIM8\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM8\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00041}\mbox{\hyperlink{group___t_i_m___i_n_i_t_gaac627c0e98c9594cc41b1b46eb39e44a}{00041}}\ \textcolor{preprocessor}{\#define\ USE\_TIM9\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM9\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00042}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga98c0691052d1da2c4053dd3586ff7ce9}{00042}}\ \textcolor{preprocessor}{\#define\ USE\_TIM10\ \ \ }\textcolor{comment}{///<\ Включить\ TIM10\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00043}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga176c97f06ebcf14e06e5c5bdbfac44c2}{00043}}\ \textcolor{preprocessor}{\#define\ USE\_TIM11\ \ \ }\textcolor{comment}{///<\ Включить\ TIM11\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00044}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga4e2b0e6cdf9eed74581b575c3fd9516b}{00044}}\ \textcolor{preprocessor}{\#define\ USE\_TIM12\ \ \ }\textcolor{comment}{///<\ Включить\ TIM12\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00045}\mbox{\hyperlink{group___t_i_m___i_n_i_t_gaf48ef87650517652ddec039a189507ac}{00045}}\ \textcolor{preprocessor}{\#define\ USE\_TIM13\ \ \ }\textcolor{comment}{///<\ Включить\ TIM13\ в\ @ref\ TIM\_Base\_MspInit}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00046}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga9ae40be31d5271abe3e49f896d916d5c}{00046}}\ \textcolor{preprocessor}{\#define\ USE\_TIM14\ \ \ }\textcolor{comment}{///<\ Включить\ TIM14\ в\ @ref\ TIM\_Base\_MspInit}\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00047}00047\ \textcolor{comment}{/**\ TIM\_INIT}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00048}00048\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00049}00049\ \textcolor{comment}{\ \ */}\textcolor{preprocessor}{}\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00050}00050\ \textcolor{comment}{/////////////////////////-\/-\/-\/USER\ SETTINGS-\/-\/-\//////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00051}00051\ \textcolor{comment}{}\textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{mylibs__defs_8h}{mylibs\_defs.h}}"{}}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00052}00052\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{general__gpio_8h}{general\_gpio.h}}"{}}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00053}00053\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00054}00054\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00055}00055\ \textcolor{comment}{////////////////////////////-\/-\/-\/DEFINES-\/-\/-\/////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00056}00056\ \textcolor{comment}{}\textcolor{preprocessor}{\#define\ TIM\_IT\_CONF\_Pos\ \ \ \ \ \ \ \ \ \ \ 0}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00057}00057\ \textcolor{comment}{//\#define\ TIM\_PWM\_CONF\_Pos\ \ \ \ \ \ \ \ \ \ 1}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00058}00058\ \textcolor{comment}{//\#define\ TIM\_CLCK\_SRC\_CONF\_Pos\ \ \ \ \ 2}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00059}00059\ \textcolor{comment}{//\#define\ TIM\_SLAVE\_CONF\_Pos\ \ \ \ \ \ \ \ 3}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00060}00060\ \textcolor{comment}{//\#define\ TIM\_MASTER\_CONF\_Pos\ \ \ \ \ \ \ 4}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00061}00061\ \textcolor{comment}{//\#define\ TIM\_BDTR\_CONF\_Pos\ \ \ \ \ \ \ \ \ 5}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00062}00062\ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00063}00063\ \textcolor{preprocessor}{\#define\ TIM\_IT\_CONF\ \ \ (1<<(TIM\_IT\_CONF\_Pos))}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00064}00064\ \textcolor{comment}{//\#define\ TIM\_PWM\_CONF\ \ \ \ \ \ (1<<(TIM\_PWM\_Pos))}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00065}00065\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00066}00066\ \textcolor{comment}{////////////////////////////-\/-\/-\/DEFINES-\/-\/-\/////////////////////////////]}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00067}00067\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00015}00015\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00016}00016\ \textcolor{comment}{*\ \ @note\ Требуется\ подключение\ модуля\ TIM\ в\ библиотеке\ HAL\ и\ GPIO\ (@ref\ MY\_LIBS\_GPIO)\ из\ MyLibs}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00017}00017\ \textcolor{comment}{@code\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00018}00018\ \textcolor{comment}{\#define\ HAL\_TIM\_MODULE\_ENABLED}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00019}00019\ \textcolor{comment}{@endcode}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00020}00020\ \textcolor{comment}{*************************************************************************/}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00021}00021\ \textcolor{preprocessor}{\#ifndef\ \_\_TIM\_GENERAL\_H\_}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00022}00022\ \textcolor{preprocessor}{\#define\ \_\_TIM\_GENERAL\_H\_}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00023}00023\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00024}00024\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00025}00025\ \textcolor{comment}{/////////////////////////-\/-\/-\/USER\ SETTINGS-\/-\/-\//////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00026}00026\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00027}00027\ \textcolor{comment}{\ \ *\ @addtogroup\ TIM\_INIT\ Init\ defines}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00028}00028\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MYLIBS\_TIM\_GENERAL}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00029}00029\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Настройка\ таймеров}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00030}00030\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00031}00031\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00032}00032\ \textcolor{preprocessor}{\#define\ HAL\_TIM\_MODULE\_ENABLED}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00033}00033\ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00034}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga54a98c21365e0bc45b81555d2b101f2b}{00034}}\ \textcolor{preprocessor}{\#define\ USE\_TIM1\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM1\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00035}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga72535a44955b43cbcd56e25039ab32eb}{00035}}\ \textcolor{preprocessor}{\#define\ USE\_TIM2\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM2\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00036}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga5b5685a43273b6e37242a4aba3ee0617}{00036}}\ \textcolor{preprocessor}{\#define\ USE\_TIM3\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM3\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00037}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga1493b39c9214501180b81b4c892f9be0}{00037}}\ \textcolor{preprocessor}{\#define\ USE\_TIM4\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM4\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00038}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga252f4fba93fc265110e83760e0590af3}{00038}}\ \textcolor{preprocessor}{\#define\ USE\_TIM5\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM5\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00039}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga8fe31b98160627d19038222910be3f46}{00039}}\ \textcolor{preprocessor}{\#define\ USE\_TIM6\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM6\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00040}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga7cdc54cc8cbbb6e9f60001f1e3e6ec67}{00040}}\ \textcolor{preprocessor}{\#define\ USE\_TIM7\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM7\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00041}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga28ba33d7c6bf22821dafa5bcee4854be}{00041}}\ \textcolor{preprocessor}{\#define\ USE\_TIM8\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM8\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00042}\mbox{\hyperlink{group___t_i_m___i_n_i_t_gaac627c0e98c9594cc41b1b46eb39e44a}{00042}}\ \textcolor{preprocessor}{\#define\ USE\_TIM9\ \ \ \ }\textcolor{comment}{///<\ Включить\ TIM9\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00043}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga98c0691052d1da2c4053dd3586ff7ce9}{00043}}\ \textcolor{preprocessor}{\#define\ USE\_TIM10\ \ \ }\textcolor{comment}{///<\ Включить\ TIM10\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00044}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga176c97f06ebcf14e06e5c5bdbfac44c2}{00044}}\ \textcolor{preprocessor}{\#define\ USE\_TIM11\ \ \ }\textcolor{comment}{///<\ Включить\ TIM11\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00045}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga4e2b0e6cdf9eed74581b575c3fd9516b}{00045}}\ \textcolor{preprocessor}{\#define\ USE\_TIM12\ \ \ }\textcolor{comment}{///<\ Включить\ TIM12\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00046}\mbox{\hyperlink{group___t_i_m___i_n_i_t_gaf48ef87650517652ddec039a189507ac}{00046}}\ \textcolor{preprocessor}{\#define\ USE\_TIM13\ \ \ }\textcolor{comment}{///<\ Включить\ TIM13\ в\ @ref\ TIM\_Base\_MspInit}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00047}\mbox{\hyperlink{group___t_i_m___i_n_i_t_ga9ae40be31d5271abe3e49f896d916d5c}{00047}}\ \textcolor{preprocessor}{\#define\ USE\_TIM14\ \ \ }\textcolor{comment}{///<\ Включить\ TIM14\ в\ @ref\ TIM\_Base\_MspInit}\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00048}00048\ \textcolor{comment}{/**\ TIM\_INIT}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00049}00049\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00050}00050\ \textcolor{comment}{\ \ */}\textcolor{preprocessor}{}\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00051}00051\ \textcolor{comment}{/////////////////////////-\/-\/-\/USER\ SETTINGS-\/-\/-\//////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00052}00052\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{mylibs__defs_8h}{mylibs\_defs.h}}"{}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00053}00053\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{general__gpio_8h}{general\_gpio.h}}"{}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00054}00054\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00055}00055\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00056}00056\ \textcolor{comment}{////////////////////////////-\/-\/-\/DEFINES-\/-\/-\/////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00057}00057\ \textcolor{preprocessor}{\#define\ TIM\_IT\_CONF\_Pos\ \ \ \ \ \ \ \ \ \ \ 0}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00058}00058\ \textcolor{comment}{//\#define\ TIM\_PWM\_CONF\_Pos\ \ \ \ \ \ \ \ \ \ 1}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00059}00059\ \textcolor{comment}{//\#define\ TIM\_CLCK\_SRC\_CONF\_Pos\ \ \ \ \ 2}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00060}00060\ \textcolor{comment}{//\#define\ TIM\_SLAVE\_CONF\_Pos\ \ \ \ \ \ \ \ 3}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00061}00061\ \textcolor{comment}{//\#define\ TIM\_MASTER\_CONF\_Pos\ \ \ \ \ \ \ 4}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00062}00062\ \textcolor{comment}{//\#define\ TIM\_BDTR\_CONF\_Pos\ \ \ \ \ \ \ \ \ 5}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00063}00063\ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00064}00064\ \textcolor{preprocessor}{\#define\ TIM\_IT\_CONF\ \ \ (1<<(TIM\_IT\_CONF\_Pos))}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00065}00065\ \textcolor{comment}{//\#define\ TIM\_PWM\_CONF\ \ \ \ \ \ (1<<(TIM\_PWM\_Pos))}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00066}00066\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00067}00067\ \textcolor{comment}{////////////////////////////-\/-\/-\/DEFINES-\/-\/-\/////////////////////////////]}} \DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00068}00068\ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00069}00069\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00070}00070\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00071}00071\ \textcolor{comment}{///////////////////////-\/-\/-\/STRUCTURES\ \&\ ENUMS-\/-\/-\///////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00072}00072\ \textcolor{comment}{}\textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00073}00073\ \textcolor{comment}{\ \ *\ @brief\ Режим\ прерываний\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00074}00074\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_TIM\_GENERAL}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00075}00075\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00076}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{00076}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{enum}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00077}00077\ \{} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00078}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787ab0869828a4dfd62eaa44868ca27835f8}{00078}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787ab0869828a4dfd62eaa44868ca27835f8}{TIM\_DEFAULT}}\ =\ \ \ \ \ \ \ \ \ 0,\ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Прерываний\ отключены}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00079}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787a89ecf1ef6d45ead2efcb7dd30396114c}{00079}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787a89ecf1ef6d45ead2efcb7dd30396114c}{TIM\_IT\_MODE}}\ =\ \ \ \ \ \ \ \ \ TIM\_IT\_CONF,\ \ \textcolor{comment}{///<\ Прерываний\ включены}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00080}00080\ \textcolor{comment}{//\ \ TIM\_PWM\_MODE\ =\ \ \ \ \ \ \ \ TIM\_PWM\_ENABLE,}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00081}00081\ \textcolor{comment}{//\ \ TIM\_PWM\_IT\_MODE\ =\ \ \ \ \ TIM\_PWM\_ENABLE\ |\ TIM\_IT\_CONF,}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00082}00082\ \}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\_ITModeTypeDef}};} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00083}00083\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00084}00084\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00085}00085\ \textcolor{comment}{\ \ *\ @brief\ Длительность\ тика\ таймера\ (частота\ тактирования\ таймера)}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00086}00086\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_TIM\_GENERAL}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00087}00087\ \textcolor{comment}{\ \ *\ @details\ \ enum\ дает\ базовые\ длительности,\ но\ можно\ выставить\ другие}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00088}00088\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ (напр\ 500\ -\/\ 0.5\ мс)}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00089}00089\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00090}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{00090}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{enum}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00091}00091\ \{} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00092}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800ae838122c0e83bc57ad31b546bf2f00e5}{00092}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800ae838122c0e83bc57ad31b546bf2f00e5}{TIM\_Base\_Disable}}\ =\ \ \ \ \ \ 0,\ \ \ \ \ \ \textcolor{comment}{///<\ Таймер\ отключен}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00093}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a63df3123d0ddc592b189ed1594456ea2}{00093}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a63df3123d0ddc592b189ed1594456ea2}{TIM\_TickBase\_1US}}\ =\ \ \ \ \ \ 1,\ \ \ \ \ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 1\ \ \ \ МГц}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00094}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a060b01e890891fd17c8f95b55a94139f}{00094}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a060b01e890891fd17c8f95b55a94139f}{TIM\_TickBase\_10US}}\ =\ \ \ \ \ 10,\ \ \ \ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 100\ \ кГц}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00095}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a096ef0ab67788487f69d8877c6d89b30}{00095}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a096ef0ab67788487f69d8877c6d89b30}{TIM\_TickBase\_100US}}\ =\ \ \ \ 100,\ \ \ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 10\ \ \ кГц}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00096}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a6a66c5ed1d966c9e30f0219b664d2b25}{00096}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a6a66c5ed1d966c9e30f0219b664d2b25}{TIM\_TickBase\_1MS}}\ =\ \ \ \ \ \ 1000,\ \ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 1\ \ \ \ кГц}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00097}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a7421a08abd119e71aa99eea5ab5d6daa}{00097}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a7421a08abd119e71aa99eea5ab5d6daa}{TIM\_TickBase\_10MS}}\ =\ \ \ \ \ 10000,\ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 100\ \ Гц}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00098}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a18527a2d781eb4365aecd9a3184fc1da}{00098}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a18527a2d781eb4365aecd9a3184fc1da}{TIM\_TickBase\_100MS}}\ =\ \ \ \ 100000,\ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 10\ \ \ Гц}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00099}00099\ \}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\_MHzTickBaseTypeDef}};} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00100}00100\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00101}00101\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00102}00102\ \textcolor{comment}{\ \ *\ @brief\ Структура\ инициализации\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00103}00103\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_TIM\_GENERAL}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00104}00104\ \textcolor{comment}{\ \ *\ @details\ \ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00105}00105\ \textcolor{comment}{\ \ *\ Содержит\ все\ базовые\ структуры,\ которые\ нужны\ для\ инициализации\ таймера.}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00106}00106\ \textcolor{comment}{\ \ *\ Если\ структуры\ настроек\ не\ заданы,\ то\ они\ заполнятся\ сами\ дефолтными\ параметрами\ \ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00107}00107\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00108}00108\ \textcolor{comment}{\ \ *\ Также\ высокоуровневые\ настройки\ частоты\ работы\ таймера.\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00109}00109\ \textcolor{comment}{\ \ *\ Если\ какая-\/либо\ высокоуровневая\ настройка\ не\ задана,\ то\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00110}00110\ \textcolor{comment}{\ \ *\ по\ возможности\ берется\ низкоуровневая\ настройка\ из\ структур}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00111}00111\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00112}\mbox{\hyperlink{struct_t_i_m___settings_type_def}{00112}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\textcolor{comment}{//\ struct\ with\ settings\ for\ custom\ function}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00113}00113\ \{} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00114}\mbox{\hyperlink{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}{00114}}\ \ \ TIM\_HandleTypeDef\ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}{htim}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ HAL\ handle\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00115}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a3805f627567798c3cd1d79a0da42bea0}{00115}}\ \ \ TIM\_ClockConfigTypeDef\ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a3805f627567798c3cd1d79a0da42bea0}{sClockSourceConfig}};\ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Настройки\ тактирования\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00116}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a9694cf0910a69d48ff94f8aeac106969}{00116}}\ \ \ TIM\_SlaveConfigTypeDef\ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a9694cf0910a69d48ff94f8aeac106969}{sSlaveConfig}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Настройки\ слейв\ режима\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00117}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a2d9d277dd395424b964445ec1bc65b21}{00117}}\ \ \ TIM\_MasterConfigTypeDef\ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a2d9d277dd395424b964445ec1bc65b21}{sMasterConfig}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Настройки\ мастер\ режима\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00118}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7}{00118}}\ \ \ TIM\_BreakDeadTimeConfigTypeDef\ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7}{sBreakDeadTimeConfig}};\ \ \textcolor{comment}{///<\ Настройки\ дедтаймов\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00119}00119\ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00120}\mbox{\hyperlink{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}{00120}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\_ITModeTypeDef}}\ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}{sTimMode}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Настройки\ прерывания\ таймера\ \ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00121}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}{00121}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\_MHzTickBaseTypeDef}}\ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}{sTickBaseUS}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Длительность\ одного\ тика\ \ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00122}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718}{00122}}\ \ \ uint8\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718}{sTickBasePrescaler}};\ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Дополнительный\ делитель,\ для\ удобного\ деления\ @ref\ sTickBaseUS}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00123}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}{00123}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}{sTimAHBFreqMHz}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Частота\ шины\ тактирования\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00124}\mbox{\hyperlink{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4}{00124}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4}{sTimFreqHz}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Желаемая\ частота\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00125}00125\ \ \ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00126}00126\ \}\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\_SettingsTypeDef}};} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00127}00127\ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00128}00128\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00129}00129\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00130}00130\ \textcolor{comment}{\ \ *\ @brief\ Структура\ инициализации\ енкодера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00131}00131\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_TIM\_ENCODER}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00132}00132\ \textcolor{comment}{\ \ *\ @details\ \ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00133}00133\ \textcolor{comment}{\ \ *\ Содержит\ все\ базовые\ структуры,\ которые\ нужны\ для\ инициализации\ таймера.}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00134}00134\ \textcolor{comment}{\ \ *\ Если\ структуры\ настроек\ не\ заданы,\ то\ они\ заполнятся\ сами\ дефолтными\ параметрами\ \ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00135}00135\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00136}00136\ \textcolor{comment}{\ \ *\ Также\ высокоуровневые\ настройки\ частоты\ работы\ таймера.\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00137}00137\ \textcolor{comment}{\ \ *\ Если\ какая-\/либо\ высокоуровневая\ настройка\ не\ задана,\ то\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00138}00138\ \textcolor{comment}{\ \ *\ по\ возможности\ берется\ низкоуровневая\ настройка\ из\ структур}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00139}00139\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00140}\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{00140}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\textcolor{comment}{//\ struct\ with\ variables\ for\ encoder}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00141}00141\ \{} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00142}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6f769f027b760a4b496e2b2b77bf54a3}{00142}}\ \ \ int16\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6f769f027b760a4b496e2b2b77bf54a3}{Encoder\_Diff}};\ \ \ \textcolor{comment}{///<\ Считанная\ разница}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00143}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a0dacce3dde7df3122583869d96a372a2}{00143}}\ \ \ uint16\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a0dacce3dde7df3122583869d96a372a2}{Encoder\_Shdw}};\ \ \ \textcolor{comment}{///<\ Последние\ считанные\ тики}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00144}00144\ \ \ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00145}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}{00145}}\ \ \ TIM\_HandleTypeDef\ \ \ \ \ \ \ *\mbox{\hyperlink{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}{htim}};\ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Указатель\ на\ HAL\ handle\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00146}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a021f0c585e9e62d68a4b09f630d8b6e5}{00146}}\ \ \ TIM\_Encoder\_InitTypeDef\ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a021f0c585e9e62d68a4b09f630d8b6e5}{sConfig}};\ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Указатель\ на\ структуру\ настройки\ энкодера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00147}00147\ \ \ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00148}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9}{00148}}\ \ \ GPIO\_TypeDef\ \ \ \ \ \ \ \ \ \ \ \ *\mbox{\hyperlink{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9}{GPIOx}};\ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Порт,\ куда\ подключается\ энкодер}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00149}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e}{00149}}\ \ \ uint32\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e}{GPIO\_PIN\_TI1}};\ \ \ \textcolor{comment}{///<\ Пин,\ куда\ подключается\ канал\ TI1}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00150}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5}{00150}}\ \ \ uint32\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5}{GPIO\_PIN\_TI2}};\ \ \ \textcolor{comment}{///<\ Пин,\ куда\ подключается\ канал\ TI2}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00151}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea4fc3e0e8a501af80}{00151}}\ \ \ uint32\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea4fc3e0e8a501af80}{GPIO\_PIN\_SW}};\ \ \ \ \textcolor{comment}{///<\ Пин,\ куда\ кнопка\ энкодера\ (если\ есть)}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00152}00152\ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00153}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a99295760ff8b27d1e6f1710f29383a45}{00153}}\ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}}\ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a99295760ff8b27d1e6f1710f29383a45}{Sw}};\ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Структура\ кнопки}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00154}00154\ \ \ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00155}00155\ \}\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}};\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00156}00156\ \textcolor{comment}{///////////////////////-\/-\/-\/STRUCTURES\ \&\ ENUMS-\/-\/-\///////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00157}00157\ \textcolor{comment}{}\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00158}00158\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00159}00159\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00160}00160\ \textcolor{comment}{}\textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00161}00161\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_TIM\_OC\ PWM/OC\ Channels\ tools}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00162}00162\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_TIM}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00163}00163\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ инициализации\ базовых\ функций\ каналов\ таймера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00164}00164\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00165}00165\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00166}00166\ \textcolor{comment}{/*\ Initialize\ PWM\ Channel\ and\ GPIO\ for\ output\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00167}00167\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_gadb2f465d89f609e035867e980c3a29c6}{TIM\_Output\_PWM\_Init}}(TIM\_HandleTypeDef\ *htim,\ TIM\_OC\_InitTypeDef\ *sConfigOC,\ uint32\_t\ TIM\_CHANNEL,\ GPIO\_TypeDef\ *GPIOx,\ uint32\_t\ PWM\_PIN);} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00168}00168\ \textcolor{comment}{/*\ Initialize\ OC\ Comparator\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00169}00169\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_gae2608ca8023e9a0713af0b4fbfbc1889}{TIM\_OC\_Comparator\_Init}}(TIM\_HandleTypeDef\ *htim,\ uint32\_t\ TIM\_CHANNEL);\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00170}00170\ \textcolor{comment}{/**\ MYLIBS\_TIM\_ENCODER}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00171}00171\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00172}00172\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00173}00173\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00174}00174\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00175}00175\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_TIM\_ENCODER\ Encoder\ tools}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00176}00176\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_TIM}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00177}00177\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ считывания\ энкодера}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00178}00178\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00179}00179\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00180}00180\ \textcolor{comment}{/*\ Initialize\ TIM\ Encoder\ functional\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00181}00181\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc}{TIM\_Encoder\_Init}}(\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}}\ *henc1,\ TIM\_HandleTypeDef\ *htim);} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00182}00182\ \textcolor{comment}{/*\ Считать\ энкодер\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00183}00183\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_gac3bc6525f88c275e47eb864e6d567501}{TIM\_Encoder\_Read}}(\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}}\ *henc);} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00184}00184\ \textcolor{comment}{/*\ Считать\ кнопку\ энкодера\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00185}00185\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e3a357ddefe323412761}{TIM\_Encoder\_ReadSwitch}}(\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}}\ *henc);\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00186}00186\ \textcolor{comment}{/**\ MYLIBS\_TIM\_ENCODER}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00187}00187\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00188}00188\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00189}00189\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00190}00190\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00191}00191\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_TIM\_DELAY\ \ Delay\ tools}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00192}00192\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_TIM}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00193}00193\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ формирования\ задержек\ с\ помощью\ таймеров}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00194}00194\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00069}00069\ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00070}00070\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00071}00071\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00072}00072\ \textcolor{comment}{///////////////////////-\/-\/-\/STRUCTURES\ \&\ ENUMS-\/-\/-\///////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00073}00073\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00074}00074\ \textcolor{comment}{\ \ *\ @brief\ Режим\ прерываний\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00075}00075\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_TIM\_GENERAL}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00076}00076\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00077}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{00077}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{enum}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00078}00078\ \{} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00079}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787ab0869828a4dfd62eaa44868ca27835f8}{00079}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787ab0869828a4dfd62eaa44868ca27835f8}{TIM\_DEFAULT}}\ =\ \ \ \ \ \ \ \ \ 0,\ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Прерываний\ отключены}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00080}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787a89ecf1ef6d45ead2efcb7dd30396114c}{00080}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787a89ecf1ef6d45ead2efcb7dd30396114c}{TIM\_IT\_MODE}}\ =\ \ \ \ \ \ \ \ \ TIM\_IT\_CONF,\ \ \textcolor{comment}{///<\ Прерываний\ включены}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00081}00081\ \textcolor{comment}{//\ \ TIM\_PWM\_MODE\ =\ \ \ \ \ \ \ \ TIM\_PWM\_ENABLE,}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00082}00082\ \textcolor{comment}{//\ \ TIM\_PWM\_IT\_MODE\ =\ \ \ \ \ TIM\_PWM\_ENABLE\ |\ TIM\_IT\_CONF,}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00083}00083\ \}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\_ITModeTypeDef}};} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00084}00084\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00085}00085\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00086}00086\ \textcolor{comment}{\ \ *\ @brief\ Длительность\ тика\ таймера\ (частота\ тактирования\ таймера)}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00087}00087\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_TIM\_GENERAL}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00088}00088\ \textcolor{comment}{\ \ *\ @details\ \ enum\ дает\ базовые\ длительности,\ но\ можно\ выставить\ другие}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00089}00089\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ (напр\ 500\ -\/\ 0.5\ мс)}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00090}00090\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00091}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{00091}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{enum}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00092}00092\ \{} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00093}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800ae838122c0e83bc57ad31b546bf2f00e5}{00093}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800ae838122c0e83bc57ad31b546bf2f00e5}{TIM\_Base\_Disable}}\ =\ \ \ \ \ \ 0,\ \ \ \ \ \ \textcolor{comment}{///<\ Таймер\ отключен}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00094}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a63df3123d0ddc592b189ed1594456ea2}{00094}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a63df3123d0ddc592b189ed1594456ea2}{TIM\_TickBase\_1US}}\ =\ \ \ \ \ \ 1,\ \ \ \ \ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 1\ \ \ \ МГц}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00095}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a060b01e890891fd17c8f95b55a94139f}{00095}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a060b01e890891fd17c8f95b55a94139f}{TIM\_TickBase\_10US}}\ =\ \ \ \ \ 10,\ \ \ \ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 100\ \ кГц}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00096}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a096ef0ab67788487f69d8877c6d89b30}{00096}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a096ef0ab67788487f69d8877c6d89b30}{TIM\_TickBase\_100US}}\ =\ \ \ \ 100,\ \ \ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 10\ \ \ кГц}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00097}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a6a66c5ed1d966c9e30f0219b664d2b25}{00097}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a6a66c5ed1d966c9e30f0219b664d2b25}{TIM\_TickBase\_1MS}}\ =\ \ \ \ \ \ 1000,\ \ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 1\ \ \ \ кГц}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00098}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a7421a08abd119e71aa99eea5ab5d6daa}{00098}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a7421a08abd119e71aa99eea5ab5d6daa}{TIM\_TickBase\_10MS}}\ =\ \ \ \ \ 10000,\ \ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 100\ \ Гц}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00099}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a18527a2d781eb4365aecd9a3184fc1da}{00099}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a18527a2d781eb4365aecd9a3184fc1da}{TIM\_TickBase\_100MS}}\ =\ \ \ \ 100000,\ \textcolor{comment}{///<\ Таймер\ тактируется\ с\ частотой\ 10\ \ \ Гц}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00100}00100\ \}\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\_MHzTickBaseTypeDef}};} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00101}00101\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00102}00102\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00103}00103\ \textcolor{comment}{\ \ *\ @brief\ Структура\ инициализации\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00104}00104\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_TIM\_GENERAL}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00105}00105\ \textcolor{comment}{\ \ *\ @details\ \ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00106}00106\ \textcolor{comment}{\ \ *\ Содержит\ все\ базовые\ структуры,\ которые\ нужны\ для\ инициализации\ таймера.}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00107}00107\ \textcolor{comment}{\ \ *\ Если\ структуры\ настроек\ не\ заданы,\ то\ они\ заполнятся\ сами\ дефолтными\ параметрами\ \ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00108}00108\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00109}00109\ \textcolor{comment}{\ \ *\ Также\ высокоуровневые\ настройки\ частоты\ работы\ таймера.\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00110}00110\ \textcolor{comment}{\ \ *\ Если\ какая-\/либо\ высокоуровневая\ настройка\ не\ задана,\ то\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00111}00111\ \textcolor{comment}{\ \ *\ по\ возможности\ берется\ низкоуровневая\ настройка\ из\ структур}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00112}00112\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00113}\mbox{\hyperlink{struct_t_i_m___settings_type_def}{00113}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\textcolor{comment}{//\ struct\ with\ settings\ for\ custom\ function}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00114}00114\ \{} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00115}\mbox{\hyperlink{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}{00115}}\ \ \ TIM\_HandleTypeDef\ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}{htim}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ HAL\ handle\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00116}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a3805f627567798c3cd1d79a0da42bea0}{00116}}\ \ \ TIM\_ClockConfigTypeDef\ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a3805f627567798c3cd1d79a0da42bea0}{sClockSourceConfig}};\ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Настройки\ тактирования\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00117}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a9694cf0910a69d48ff94f8aeac106969}{00117}}\ \ \ TIM\_SlaveConfigTypeDef\ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a9694cf0910a69d48ff94f8aeac106969}{sSlaveConfig}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Настройки\ слейв\ режима\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00118}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a2d9d277dd395424b964445ec1bc65b21}{00118}}\ \ \ TIM\_MasterConfigTypeDef\ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a2d9d277dd395424b964445ec1bc65b21}{sMasterConfig}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Настройки\ мастер\ режима\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00119}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7}{00119}}\ \ \ TIM\_BreakDeadTimeConfigTypeDef\ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7}{sBreakDeadTimeConfig}};\ \ \textcolor{comment}{///<\ Настройки\ дедтаймов\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00120}00120\ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00121}\mbox{\hyperlink{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}{00121}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\_ITModeTypeDef}}\ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}{sTimMode}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Настройки\ прерывания\ таймера\ \ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00122}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}{00122}}\ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\_MHzTickBaseTypeDef}}\ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}{sTickBaseUS}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Длительность\ одного\ тика\ \ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00123}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718}{00123}}\ \ \ uint8\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718}{sTickBasePrescaler}};\ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Дополнительный\ делитель,\ для\ удобного\ деления\ @ref\ sTickBaseUS}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00124}\mbox{\hyperlink{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}{00124}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}{sTimAHBFreqMHz}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Частота\ шины\ тактирования\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00125}\mbox{\hyperlink{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4}{00125}}\ \ \ \textcolor{keywordtype}{float}\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4}{sTimFreqHz}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Желаемая\ частота\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00126}00126\ \ \ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00127}00127\ \}\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\_SettingsTypeDef}};} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00128}00128\ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00129}00129\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00130}00130\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00131}00131\ \textcolor{comment}{\ \ *\ @brief\ Структура\ инициализации\ енкодера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00132}00132\ \textcolor{comment}{\ \ *\ @ingroup\ \ MYLIBS\_TIM\_ENCODER}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00133}00133\ \textcolor{comment}{\ \ *\ @details\ \ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00134}00134\ \textcolor{comment}{\ \ *\ Содержит\ все\ базовые\ структуры,\ которые\ нужны\ для\ инициализации\ таймера.}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00135}00135\ \textcolor{comment}{\ \ *\ Если\ структуры\ настроек\ не\ заданы,\ то\ они\ заполнятся\ сами\ дефолтными\ параметрами\ \ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00136}00136\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00137}00137\ \textcolor{comment}{\ \ *\ Также\ высокоуровневые\ настройки\ частоты\ работы\ таймера.\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00138}00138\ \textcolor{comment}{\ \ *\ Если\ какая-\/либо\ высокоуровневая\ настройка\ не\ задана,\ то\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00139}00139\ \textcolor{comment}{\ \ *\ по\ возможности\ берется\ низкоуровневая\ настройка\ из\ структур}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00140}00140\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00141}\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{00141}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\textcolor{comment}{//\ struct\ with\ variables\ for\ encoder}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00142}00142\ \{} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00143}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6f769f027b760a4b496e2b2b77bf54a3}{00143}}\ \ \ int16\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6f769f027b760a4b496e2b2b77bf54a3}{Encoder\_Diff}};\ \ \ \textcolor{comment}{///<\ Считанная\ разница}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00144}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a0dacce3dde7df3122583869d96a372a2}{00144}}\ \ \ uint16\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a0dacce3dde7df3122583869d96a372a2}{Encoder\_Shdw}};\ \ \ \textcolor{comment}{///<\ Последние\ считанные\ тики}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00145}00145\ \ \ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00146}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}{00146}}\ \ \ TIM\_HandleTypeDef\ \ \ \ \ \ \ *\mbox{\hyperlink{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}{htim}};\ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Указатель\ на\ HAL\ handle\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00147}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a021f0c585e9e62d68a4b09f630d8b6e5}{00147}}\ \ \ TIM\_Encoder\_InitTypeDef\ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a021f0c585e9e62d68a4b09f630d8b6e5}{sConfig}};\ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Указатель\ на\ структуру\ настройки\ энкодера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00148}00148\ \ \ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00149}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9}{00149}}\ \ \ GPIO\_TypeDef\ \ \ \ \ \ \ \ \ \ \ \ *\mbox{\hyperlink{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9}{GPIOx}};\ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Порт,\ куда\ подключается\ энкодер}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00150}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e}{00150}}\ \ \ uint32\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e}{GPIO\_PIN\_TI1}};\ \ \ \textcolor{comment}{///<\ Пин,\ куда\ подключается\ канал\ TI1}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00151}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5}{00151}}\ \ \ uint32\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5}{GPIO\_PIN\_TI2}};\ \ \ \textcolor{comment}{///<\ Пин,\ куда\ подключается\ канал\ TI2}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00152}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea4fc3e0e8a501af80}{00152}}\ \ \ uint32\_t\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea4fc3e0e8a501af80}{GPIO\_PIN\_SW}};\ \ \ \ \textcolor{comment}{///<\ Пин,\ куда\ кнопка\ энкодера\ (если\ есть)}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00153}00153\ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00154}\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a99295760ff8b27d1e6f1710f29383a45}{00154}}\ \ \ \mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}}\ \ \ \ \ \ \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a99295760ff8b27d1e6f1710f29383a45}{Sw}};\ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Структура\ кнопки}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00155}00155\ \ \ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00156}00156\ \}\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}};\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00157}00157\ \textcolor{comment}{///////////////////////-\/-\/-\/STRUCTURES\ \&\ ENUMS-\/-\/-\///////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00158}00158\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00159}00159\ \textcolor{comment}{/////////////////////////////////////////////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00160}00160\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00161}00161\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00162}00162\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_TIM\_GENERAL\ \ General\ tools}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00163}00163\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_TIM}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00164}00164\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ базовой\ инициализации\ таймеров}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00165}00165\ \textcolor{comment}{\ \ *\ @par\ Пример\ использования:}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00166}00166\ \textcolor{comment}{\ \ \ \ @code}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00167}00167\ \textcolor{comment}{\ \ \ \ TIM\_SettingsTypeDef\ tim2Settings;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00168}00168\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00169}00169\ \textcolor{comment}{\ \ \ \ void\ TIM2\_Init(void)}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00170}00170\ \textcolor{comment}{\ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00171}00171\ \textcolor{comment}{\ \ \ \ \ \ \ \ //\ Настройка\ таймера\ TIM2\ на\ 1\ кГц\ с\ прерываниями\ с\ шагом\ таймера\ 10\ мкс}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00172}00172\ \textcolor{comment}{\ \ \ \ \ \ \ \ tim2Settings.htim.Instance\ =\ TIM2;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00173}00173\ \textcolor{comment}{\ \ \ \ \ \ \ \ tim2Settings.sTimMode\ =\ TIM\_IT\_MODE;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00174}00174\ \textcolor{comment}{\ \ \ \ \ \ \ \ tim2Settings.sTickBaseUS\ =\ TIM\_TickBase\_10US;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00175}00175\ \textcolor{comment}{\ \ \ \ \ \ \ \ tim2Settings.sTickBasePrescaler\ =\ 1;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00176}00176\ \textcolor{comment}{\ \ \ \ \ \ \ \ tim2Settings.sTimFreqHz\ =\ 1000;\ //\ 1\ кГц}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00177}00177\ \textcolor{comment}{\ \ \ \ \ \ \ \ tim2Settings.sTimAHBFreqMHz\ =\ 72000000;\ //\ Hz}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00178}00178\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00179}00179\ \textcolor{comment}{\ \ \ \ \ \ \ \ if(TIM\_Base\_Init(\&tim2Settings)\ !=\ HAL\_OK)}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00180}00180\ \textcolor{comment}{\ \ \ \ \ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00181}00181\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ Error\_Handler();}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00182}00182\ \textcolor{comment}{\ \ \ \ \ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00183}00183\ \textcolor{comment}{\ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00184}00184\ \textcolor{comment}{\ \ \ \ @endcode}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00185}00185\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00186}00186\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00187}00187\ \textcolor{comment}{/*\ Initialize\ TIM\ with\ TIM\_SettingsTypeDef\ structure\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00188}00188\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec}{TIM\_Base\_Init}}(\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\_SettingsTypeDef}}*\ stim);} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00189}00189\ \textcolor{comment}{/*\ Initialize\ TIMs\ clock\ and\ interrupt\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00190}00190\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931}{TIM\_Base\_MspInit}}(TIM\_HandleTypeDef*\ htim,\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\_ITModeTypeDef}}\ it\_mode);} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00191}00191\ \textcolor{comment}{/*\ DeInitialize\ TIMs\ clock\ and\ interrupt\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00192}00192\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115}{TIM\_Base\_MspDeInit}}(TIM\_HandleTypeDef*\ htim);\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00193}00193\ \textcolor{comment}{/**\ MYLIBS\_TIM\_GENERAL}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00194}00194\ \textcolor{comment}{\ \ *\ @\}}} \DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00195}00195\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00196}00196\ \textcolor{comment}{/*\ Start\ delay\ via\ TIM\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00197}00197\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834}{TIM\_Delay\_Start}}(TIM\_HandleTypeDef\ *htim);} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00198}00198\ \textcolor{comment}{/*\ Delay\ via\ TIM\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00199}00199\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e}{TIM\_Delay}}(TIM\_HandleTypeDef\ *htim,\ uint16\_t\ delay);} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00200}00200\ \textcolor{comment}{/*\ Wait\ Delay\ via\ TIM\ without\ blocking\ app\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00201}00201\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b}{TIM\_Delay\_NonBlocking}}(TIM\_HandleTypeDef\ *htim,\ uint16\_t\ delay);\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00202}00202\ \textcolor{comment}{/**\ MYLIBS\_TIM\_DELAY}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00203}00203\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00204}00204\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00205}00205\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00206}00206\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00207}00207\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_TIM\_GENERAL\ \ General\ tools}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00208}00208\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_TIM}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00209}00209\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ базовой\ инициализации\ таймеров}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00210}00210\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00211}00211\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00212}00212\ \textcolor{comment}{/*\ Initialize\ TIM\ with\ TIM\_SettingsTypeDef\ structure\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00213}00213\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec}{TIM\_Base\_Init}}(\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\_SettingsTypeDef}}*\ stim);} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00214}00214\ \textcolor{comment}{/*\ Initialize\ TIMs\ clock\ and\ interrupt\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00215}00215\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931}{TIM\_Base\_MspInit}}(TIM\_HandleTypeDef*\ htim,\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\_ITModeTypeDef}}\ it\_mode);} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00216}00216\ \textcolor{comment}{/*\ DeInitialize\ TIMs\ clock\ and\ interrupt\ */}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00217}00217\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115}{TIM\_Base\_MspDeInit}}(TIM\_HandleTypeDef*\ htim);\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00218}00218\ \textcolor{comment}{/**\ MYLIBS\_TIM\_GENERAL}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00219}00219\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00220}00220\ \textcolor{comment}{\ \ */}\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00221}00221\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00222}00222\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00223}00223\ } -\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00224}00224\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ \_\_TIM\_GENERAL\_H\_}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00196}00196\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00197}00197\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00198}00198\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_TIM\_DELAY\ \ Delay\ tools}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00199}00199\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_TIM}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00200}00200\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ формирования\ задержек\ с\ помощью\ таймеров}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00201}00201\ \textcolor{comment}{\ \ *\ @par\ Пример\ использования:}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00202}00202\ \textcolor{comment}{\ \ \ \ @code}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00203}00203\ \textcolor{comment}{\ \ \ \ TIM\_HandleTypeDef\ htim2;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00204}00204\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00205}00205\ \textcolor{comment}{\ \ \ \ //\ блокирующая\ задержка\ 500\ тиков\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00206}00206\ \textcolor{comment}{\ \ \ \ LED\_ON();}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00207}00207\ \textcolor{comment}{\ \ \ \ TIM\_Delay(\&htim2,\ 500);}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00208}00208\ \textcolor{comment}{\ \ \ \ LED\_OFF();}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00209}00209\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00210}00210\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00211}00211\ \textcolor{comment}{\ \ \ \ while(1)}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00212}00212\ \textcolor{comment}{\ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00213}00213\ \textcolor{comment}{\ \ \ \ \ \ //\ не\ блокирующая\ задержка\ 200\ тиков\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00214}00214\ \textcolor{comment}{\ \ \ \ \ \ if(TIM\_Delay\_NonBlocking(\&htim2,\ 200)\ ==\ HAL\_OK)}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00215}00215\ \textcolor{comment}{\ \ \ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00216}00216\ \textcolor{comment}{\ \ \ \ \ \ \ \ TIM\_Delay\_Start(\&htim2);}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00217}00217\ \textcolor{comment}{\ \ \ \ \ \ \ \ LED\_TOOGLE();}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00218}00218\ \textcolor{comment}{\ \ \ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00219}00219\ \textcolor{comment}{\ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00220}00220\ \textcolor{comment}{\ \ \ \ @endcode}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00221}00221\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00222}00222\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00223}00223\ \textcolor{comment}{/*\ Start\ delay\ via\ TIM\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00224}00224\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834}{TIM\_Delay\_Start}}(TIM\_HandleTypeDef\ *htim);} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00225}00225\ \textcolor{comment}{/*\ Delay\ via\ TIM\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00226}00226\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e}{TIM\_Delay}}(TIM\_HandleTypeDef\ *htim,\ uint16\_t\ delay);} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00227}00227\ \textcolor{comment}{/*\ Wait\ Delay\ via\ TIM\ without\ blocking\ app\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00228}00228\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b}{TIM\_Delay\_NonBlocking}}(TIM\_HandleTypeDef\ *htim,\ uint16\_t\ delay);\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00229}00229\ \textcolor{comment}{/**\ MYLIBS\_TIM\_DELAY}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00230}00230\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00231}00231\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00232}00232\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00233}00233\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00234}00234\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_TIM\_OC\ PWM/OC\ Channels\ tools}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00235}00235\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_TIM}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00236}00236\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ инициализации\ базовых\ функций\ каналов\ таймера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00237}00237\ \textcolor{comment}{\ \ *\ @par\ Пример\ использования:}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00238}00238\ \textcolor{comment}{\ \ \ \ @code}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00239}00239\ \textcolor{comment}{\ \ \ \ void\ PWM\_Channel\_Init\_Example(void)}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00240}00240\ \textcolor{comment}{\ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00241}00241\ \textcolor{comment}{\ \ \ \ \ \ \ \ TIM\_HandleTypeDef\ htim3;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00242}00242\ \textcolor{comment}{\ \ \ \ \ \ \ \ TIM\_OC\_InitTypeDef\ sConfigOC;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00243}00243\ \textcolor{comment}{\ \ \ \ \ \ \ \ GPIO\_TypeDef\ *GPIOx\ =\ GPIOB;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00244}00244\ \textcolor{comment}{\ \ \ \ \ \ \ \ uint32\_t\ PWM\_PIN\ =\ GPIO\_PIN\_0;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00245}00245\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00246}00246\ \textcolor{comment}{\ \ \ \ \ \ \ \ //\ Настройка\ таймера\ и\ канала\ PWM}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00247}00247\ \textcolor{comment}{\ \ \ \ \ \ \ \ TIM\_Output\_PWM\_Init(\&htim3,\ \&sConfigOC,\ TIM\_CHANNEL\_1,\ GPIOx,\ PWM\_PIN);}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00248}00248\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00249}00249\ \textcolor{comment}{\ \ \ \ \ \ \ \ //\ Настройка\ компаратора\ OC}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00250}00250\ \textcolor{comment}{\ \ \ \ \ \ \ \ TIM\_OC\_Comparator\_Init(\&htim3,\ TIM\_CHANNEL\_1);}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00251}00251\ \textcolor{comment}{\ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00252}00252\ \textcolor{comment}{\ \ \ \ @endcode}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00253}00253\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00254}00254\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00255}00255\ \textcolor{comment}{/*\ Initialize\ PWM\ Channel\ and\ GPIO\ for\ output\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00256}00256\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_gadb2f465d89f609e035867e980c3a29c6}{TIM\_Output\_PWM\_Init}}(TIM\_HandleTypeDef\ *htim,\ TIM\_OC\_InitTypeDef\ *sConfigOC,\ uint32\_t\ TIM\_CHANNEL,\ GPIO\_TypeDef\ *GPIOx,\ uint32\_t\ PWM\_PIN);} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00257}00257\ \textcolor{comment}{/*\ Initialize\ OC\ Comparator\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00258}00258\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_gae2608ca8023e9a0713af0b4fbfbc1889}{TIM\_OC\_Comparator\_Init}}(TIM\_HandleTypeDef\ *htim,\ uint32\_t\ TIM\_CHANNEL);\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00259}00259\ \textcolor{comment}{/**\ MYLIBS\_TIM\_ENCODER}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00260}00260\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00261}00261\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00262}00262\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00263}00263\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00264}00264\ \textcolor{comment}{\ \ *\ @addtogroup\ MYLIBS\_TIM\_ENCODER\ Encoder\ tools}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00265}00265\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MY\_LIBS\_TIM}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00266}00266\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Функции\ для\ считывания\ энкодера}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00267}00267\ \textcolor{comment}{\ \ *\ @par\ Пример\ использования:}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00268}00268\ \textcolor{comment}{\ \ \ \ @code}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00269}00269\ \textcolor{comment}{\ \ \ \ TIM\_EncoderTypeDef\ henc1;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00270}00270\ \textcolor{comment}{\ \ \ \ TIM\_HandleTypeDef\ htim4;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00271}00271\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00272}00272\ \textcolor{comment}{\ \ \ \ //\ инициализация}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00273}00273\ \textcolor{comment}{\ \ \ \ henc1.htim\ =\ \&htim4;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00274}00274\ \textcolor{comment}{\ \ \ \ henc1.GPIOx\ =\ GPIOA;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00275}00275\ \textcolor{comment}{\ \ \ \ henc1.GPIO\_PIN\_TI1\ =\ GPIO\_PIN\_0;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00276}00276\ \textcolor{comment}{\ \ \ \ henc1.GPIO\_PIN\_TI2\ =\ GPIO\_PIN\_1;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00277}00277\ \textcolor{comment}{\ \ \ \ TIM\_Encoder\_Init(\&henc1,\ \&htim4);}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00278}00278\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00279}00279\ \textcolor{comment}{\ \ \ \ //\ считывание\ энкодера\ и\ кнопки}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00280}00280\ \textcolor{comment}{\ \ \ \ int16\_t\ delta\ =\ TIM\_Encoder\_Read(\&henc1);}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00281}00281\ \textcolor{comment}{\ \ \ \ setpoint\_tmp\ +=\ delta;}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00282}00282\ \textcolor{comment}{\ \ \ \ if(TIM\_Encoder\_ReadSwitch(\&henc1))}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00283}00283\ \textcolor{comment}{\ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00284}00284\ \textcolor{comment}{\ \ \ \ \ \ setpoint\ =\ setpoint\_tmp;\ //\ подтвердить\ новое\ значение}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00285}00285\ \textcolor{comment}{\ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00286}00286\ \textcolor{comment}{\ \ \ \ @endcode}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00287}00287\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00288}00288\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00289}00289\ \textcolor{comment}{/*\ Initialize\ TIM\ Encoder\ functional\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00290}00290\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc}{TIM\_Encoder\_Init}}(\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}}\ *henc1,\ TIM\_HandleTypeDef\ *htim);} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00291}00291\ \textcolor{comment}{/*\ Считать\ энкодер\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00292}00292\ HAL\_StatusTypeDef\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_gac3bc6525f88c275e47eb864e6d567501}{TIM\_Encoder\_Read}}(\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}}\ *henc);} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00293}00293\ \textcolor{comment}{/*\ Считать\ кнопку\ энкодера\ */}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00294}00294\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e3a357ddefe323412761}{TIM\_Encoder\_ReadSwitch}}(\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}}\ *henc);\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00295}00295\ \textcolor{comment}{/**\ MYLIBS\_TIM\_ENCODER}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00296}00296\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00297}00297\ \textcolor{comment}{\ \ */}\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00298}00298\ \textcolor{comment}{///////////////////////////-\/-\/-\/FUNCTIONS-\/-\/-\////////////////////////////}} +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00299}00299\ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00300}00300\ } +\DoxyCodeLine{\Hypertarget{general__tim_8h_source_l00301}00301\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ \_\_TIM\_GENERAL\_H\_}} \end{DoxyCode} diff --git a/Doc/latex/group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.tex b/Doc/latex/group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.tex index d4a1132..4038bb6 100644 --- a/Doc/latex/group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.tex +++ b/Doc/latex/group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Bit access defines} +\doxysubsubsection{Bit access defines } \hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s}{}\label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s}\index{Bit access defines@{Bit access defines}} @@ -26,13 +26,13 @@ union \mbox{\hyperlink{unionuint64___bit_type_def}{uint64\+\_\+\+Bit\+Type\+Def} \doxysubsubsubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga57dc3bb3472a66fc92312f89d42d2396}{uint8\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+)~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint8___bit_type_def}{uint8\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+ +\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga57dc3bb3472a66fc92312f89d42d2396}{uint8\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+) \begin{DoxyCompactList}\small\item\em Получить n-\/й бит из uint8\+\_\+t. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga6a122b536ad99ae611c8cf01437af086}{uint16\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+)~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint16___bit_type_def}{uint16\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+ +\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga6a122b536ad99ae611c8cf01437af086}{uint16\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+) \begin{DoxyCompactList}\small\item\em Получить n-\/й бит из uint16\+\_\+t. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_gafaa2080168b1b6f7281e8bfabab022d1}{uint32\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+)~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint32___bit_type_def}{uint32\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+ +\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_gafaa2080168b1b6f7281e8bfabab022d1}{uint32\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+) \begin{DoxyCompactList}\small\item\em Получить n-\/й бит из uint32\+\_\+t. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga47eb69ce9330a1c73fe8031240f02f0a}{uint64\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+)~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint64___bit_type_def}{uint64\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+ +\#define \mbox{\hyperlink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga47eb69ce9330a1c73fe8031240f02f0a}{uint64\+\_\+bit}}(\+\_\+uint8\+\_\+, \+\_\+bit\+\_\+) \begin{DoxyCompactList}\small\item\em Получить n-\/й бит из uint64\+\_\+t. \end{DoxyCompactList}\end{DoxyCompactItemize} @@ -68,13 +68,20 @@ union \mbox{\hyperlink{unionuint64___bit_type_def}{uint64\+\_\+\+Bit\+Type\+Def} \item Доступ реализован через приведение к {\ttfamily union} с битовыми полями, поэтому это безопасный способ работы с отдельными битами без ручного сдвига и маскирования. \end{DoxyItemize} +\label{doc-define-members} +\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga57dc3bb3472a66fc92312f89d42d2396}\label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga57dc3bb3472a66fc92312f89d42d2396} -\index{Bit access defines@{Bit access defines}!uint8\_bit@{uint8\_bit}} +\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga57dc3bb3472a66fc92312f89d42d2396}\index{Bit access defines@{Bit access defines}!uint8\_bit@{uint8\_bit}} \index{uint8\_bit@{uint8\_bit}!Bit access defines@{Bit access defines}} \doxysubsubsubsubsection{\texorpdfstring{uint8\_bit}{uint8\_bit}} -{\footnotesize\ttfamily \#define uint8\+\_\+bit(\begin{DoxyParamCaption}\item[{}]{\+\_\+uint8\+\_\+, }\item[{}]{\+\_\+bit\+\_\+ }\end{DoxyParamCaption})~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint8___bit_type_def}{uint8\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+} +{\footnotesize\ttfamily \label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga57dc3bb3472a66fc92312f89d42d2396} +\#define uint8\+\_\+bit(\begin{DoxyParamCaption}\item[{}]{\+\_\+uint8\+\_\+}{, }\item[{}]{\+\_\+bit\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(*(\mbox{\hyperlink{unionuint8___bit_type_def}{uint8\_BitTypeDef}}\ *)(\&(\_uint8\_))).bit.bit\#\#\_bit\_} + +\end{DoxyCode} Получить n-\/й бит из uint8\+\_\+t. @@ -96,12 +103,17 @@ union \mbox{\hyperlink{unionuint64___bit_type_def}{uint64\+\_\+\+Bit\+Type\+Def} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00129}{129}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga6a122b536ad99ae611c8cf01437af086}\label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga6a122b536ad99ae611c8cf01437af086} -\index{Bit access defines@{Bit access defines}!uint16\_bit@{uint16\_bit}} +\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga6a122b536ad99ae611c8cf01437af086}\index{Bit access defines@{Bit access defines}!uint16\_bit@{uint16\_bit}} \index{uint16\_bit@{uint16\_bit}!Bit access defines@{Bit access defines}} \doxysubsubsubsubsection{\texorpdfstring{uint16\_bit}{uint16\_bit}} -{\footnotesize\ttfamily \#define uint16\+\_\+bit(\begin{DoxyParamCaption}\item[{}]{\+\_\+uint8\+\_\+, }\item[{}]{\+\_\+bit\+\_\+ }\end{DoxyParamCaption})~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint16___bit_type_def}{uint16\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+} +{\footnotesize\ttfamily \label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga6a122b536ad99ae611c8cf01437af086} +\#define uint16\+\_\+bit(\begin{DoxyParamCaption}\item[{}]{\+\_\+uint8\+\_\+}{, }\item[{}]{\+\_\+bit\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(*(\mbox{\hyperlink{unionuint16___bit_type_def}{uint16\_BitTypeDef}}\ *)(\&(\_uint8\_))).bit.bit\#\#\_bit\_} + +\end{DoxyCode} Получить n-\/й бит из uint16\+\_\+t. @@ -123,12 +135,17 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00129}{129}} of file Definition at line \mbox{\hyperlink{bit__access_8h_source_l00137}{137}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_gafaa2080168b1b6f7281e8bfabab022d1}\label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_gafaa2080168b1b6f7281e8bfabab022d1} -\index{Bit access defines@{Bit access defines}!uint32\_bit@{uint32\_bit}} +\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_gafaa2080168b1b6f7281e8bfabab022d1}\index{Bit access defines@{Bit access defines}!uint32\_bit@{uint32\_bit}} \index{uint32\_bit@{uint32\_bit}!Bit access defines@{Bit access defines}} \doxysubsubsubsubsection{\texorpdfstring{uint32\_bit}{uint32\_bit}} -{\footnotesize\ttfamily \#define uint32\+\_\+bit(\begin{DoxyParamCaption}\item[{}]{\+\_\+uint8\+\_\+, }\item[{}]{\+\_\+bit\+\_\+ }\end{DoxyParamCaption})~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint32___bit_type_def}{uint32\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+} +{\footnotesize\ttfamily \label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_gafaa2080168b1b6f7281e8bfabab022d1} +\#define uint32\+\_\+bit(\begin{DoxyParamCaption}\item[{}]{\+\_\+uint8\+\_\+}{, }\item[{}]{\+\_\+bit\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(*(\mbox{\hyperlink{unionuint32___bit_type_def}{uint32\_BitTypeDef}}\ *)(\&(\_uint8\_))).bit.bit\#\#\_bit\_} + +\end{DoxyCode} Получить n-\/й бит из uint32\+\_\+t. @@ -150,12 +167,17 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00137}{137}} of file Definition at line \mbox{\hyperlink{bit__access_8h_source_l00145}{145}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga47eb69ce9330a1c73fe8031240f02f0a}\label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga47eb69ce9330a1c73fe8031240f02f0a} -\index{Bit access defines@{Bit access defines}!uint64\_bit@{uint64\_bit}} +\Hypertarget{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga47eb69ce9330a1c73fe8031240f02f0a}\index{Bit access defines@{Bit access defines}!uint64\_bit@{uint64\_bit}} \index{uint64\_bit@{uint64\_bit}!Bit access defines@{Bit access defines}} \doxysubsubsubsubsection{\texorpdfstring{uint64\_bit}{uint64\_bit}} -{\footnotesize\ttfamily \#define uint64\+\_\+bit(\begin{DoxyParamCaption}\item[{}]{\+\_\+uint8\+\_\+, }\item[{}]{\+\_\+bit\+\_\+ }\end{DoxyParamCaption})~(\texorpdfstring{$\ast$}{*}(\mbox{\hyperlink{unionuint64___bit_type_def}{uint64\+\_\+\+Bit\+Type\+Def}} \texorpdfstring{$\ast$}{*})(\&(\+\_\+uint8\+\_\+))).bit.\+bit\#\#\+\_\+bit\+\_\+} +{\footnotesize\ttfamily \label{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s_ga47eb69ce9330a1c73fe8031240f02f0a} +\#define uint64\+\_\+bit(\begin{DoxyParamCaption}\item[{}]{\+\_\+uint8\+\_\+}{, }\item[{}]{\+\_\+bit\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(*(\mbox{\hyperlink{unionuint64___bit_type_def}{uint64\_BitTypeDef}}\ *)(\&(\_uint8\_))).bit.bit\#\#\_bit\_} + +\end{DoxyCode} Получить n-\/й бит из uint64\+\_\+t. diff --git a/Doc/latex/group___d_e_l_a_y_s___d_e_f_i_n_e_s.tex b/Doc/latex/group___d_e_l_a_y_s___d_e_f_i_n_e_s.tex index e127538..483828b 100644 --- a/Doc/latex/group___d_e_l_a_y_s___d_e_f_i_n_e_s.tex +++ b/Doc/latex/group___d_e_l_a_y_s___d_e_f_i_n_e_s.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Delays defines} +\doxysubsubsection{Delays defines } \hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s}{}\label{group___d_e_l_a_y_s___d_e_f_i_n_e_s}\index{Delays defines@{Delays defines}} @@ -15,13 +15,13 @@ Collaboration diagram for Delays defines\+:\nopagebreak \doxysubsubsubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479}{ms\+Delay}}(\+\_\+ms\+\_\+)~HAL\+\_\+\+Delay(\+\_\+ms\+\_\+) -\begin{DoxyCompactList}\small\item\em Задержка на указанное количество миллисекунд. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25}{ms\+Delay\+Start}}(\+\_\+pvar\+\_\+)~\texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) = HAL\+\_\+\+Get\+Tick() +\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479}{ms\+Delay}}(\+\_\+ms\+\_\+) +\begin{DoxyCompactList}\small\item\em Блокирующая задержка на указанное количество миллисекунд. \end{DoxyCompactList}\item +\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25}{ms\+Delay\+Start}}(\+\_\+pvar\+\_\+) \begin{DoxyCompactList}\small\item\em Начать отсчет задержки. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85}{ms\+Delay\+While\+Active}}(\+\_\+ms\+\_\+, \+\_\+pvar\+\_\+)~(HAL\+\_\+\+Get\+Tick() -\/ \texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) $<$ \+\_\+ms\+\_\+) +\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85}{ms\+Delay\+While\+Active}}(\+\_\+ms\+\_\+, \+\_\+pvar\+\_\+) \begin{DoxyCompactList}\small\item\em Проверяет, активна ли задержка. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}{ms\+Delay\+Wait\+Done}}(\+\_\+ms\+\_\+, \+\_\+pvar\+\_\+)~(HAL\+\_\+\+Get\+Tick() -\/ \texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) $>$= \+\_\+ms\+\_\+) +\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}{ms\+Delay\+Wait\+Done}}(\+\_\+ms\+\_\+, \+\_\+pvar\+\_\+) \begin{DoxyCompactList}\small\item\em Проверяет, завершилась ли задержка. \end{DoxyCompactList}\end{DoxyCompactItemize} @@ -36,16 +36,23 @@ Collaboration diagram for Delays defines\+:\nopagebreak \item \doxylink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}{ms\+Delay\+Wait\+Done} — проверка, завершена ли задержка. Эти макросы удобны для реализации неблокирующих задержек. \end{DoxyItemize} +\label{doc-define-members} +\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479}\label{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479} -\index{Delays defines@{Delays defines}!msDelay@{msDelay}} +\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479}\index{Delays defines@{Delays defines}!msDelay@{msDelay}} \index{msDelay@{msDelay}!Delays defines@{Delays defines}} \doxysubsubsubsubsection{\texorpdfstring{msDelay}{msDelay}} -{\footnotesize\ttfamily \#define ms\+Delay(\begin{DoxyParamCaption}\item[{}]{\+\_\+ms\+\_\+ }\end{DoxyParamCaption})~HAL\+\_\+\+Delay(\+\_\+ms\+\_\+)} +{\footnotesize\ttfamily \label{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479} +\#define ms\+Delay(\begin{DoxyParamCaption}\item[{}]{\+\_\+ms\+\_\+}{}\end{DoxyParamCaption})} + +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{osDelay(\_ms\_)} + +\end{DoxyCode} - -Задержка на указанное количество миллисекунд. +Блокирующая задержка на указанное количество миллисекунд. \begin{DoxyParams}{Parameters} @@ -53,18 +60,23 @@ Collaboration diagram for Delays defines\+:\nopagebreak \hline \end{DoxyParams} \begin{DoxyNote}{Note} -Использует HAL\+\_\+\+Delay или os\+Delay в зависимости от FREERTOS\+\_\+\+DELAY. +Использует задержку через \doxylink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\+\_\+time} или os\+Delay в зависимости от \doxylink{group___l_i_b_s___c_o_n_f_i_g_ga57c369737d5c0cfdb7baeecba0a4b151}{FREERTOS\+\_\+\+DELAY}. \end{DoxyNote} -Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00082}{82}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00080}{80}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25}\label{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25} -\index{Delays defines@{Delays defines}!msDelayStart@{msDelayStart}} +\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25}\index{Delays defines@{Delays defines}!msDelayStart@{msDelayStart}} \index{msDelayStart@{msDelayStart}!Delays defines@{Delays defines}} \doxysubsubsubsubsection{\texorpdfstring{msDelayStart}{msDelayStart}} -{\footnotesize\ttfamily \#define ms\+Delay\+Start(\begin{DoxyParamCaption}\item[{}]{\+\_\+pvar\+\_\+ }\end{DoxyParamCaption})~\texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) = HAL\+\_\+\+Get\+Tick()} +{\footnotesize\ttfamily \label{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25} +\#define ms\+Delay\+Start(\begin{DoxyParamCaption}\item[{}]{\+\_\+pvar\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{*(\_pvar\_)\ =\ \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}()} + +\end{DoxyCode} Начать отсчет задержки. @@ -74,18 +86,23 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00082}{82}} of file {\em \+\_\+pvar\+\_\+} & Указатель на переменную типа uint32\+\_\+t для хранения времени старта.\\ \hline \end{DoxyParams} -После вызова этого макроса переменная {\itshape pvar} содержит текущее количество миллисекунд с момента запуска системы (HAL\+\_\+\+Get\+Tick). +После вызова этого макроса переменная {\itshape pvar} содержит текущее количество миллисекунд с момента запуска системы (\doxylink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\+\_\+time}). Используется для реализации неблокирующих задержек. -Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00094}{94}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00098}{98}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85}\label{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85} -\index{Delays defines@{Delays defines}!msDelayWhileActive@{msDelayWhileActive}} +\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85}\index{Delays defines@{Delays defines}!msDelayWhileActive@{msDelayWhileActive}} \index{msDelayWhileActive@{msDelayWhileActive}!Delays defines@{Delays defines}} \doxysubsubsubsubsection{\texorpdfstring{msDelayWhileActive}{msDelayWhileActive}} -{\footnotesize\ttfamily \#define ms\+Delay\+While\+Active(\begin{DoxyParamCaption}\item[{}]{\+\_\+ms\+\_\+, }\item[{}]{\+\_\+pvar\+\_\+ }\end{DoxyParamCaption})~(HAL\+\_\+\+Get\+Tick() -\/ \texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) $<$ \+\_\+ms\+\_\+)} +{\footnotesize\ttfamily \label{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85} +\#define ms\+Delay\+While\+Active(\begin{DoxyParamCaption}\item[{}]{\+\_\+ms\+\_\+}{, }\item[{}]{\+\_\+pvar\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}()\ -\/\ *(\_pvar\_)\ <\ \_ms\_)} + +\end{DoxyCode} Проверяет, активна ли задержка. @@ -113,14 +130,19 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00094}{94}} of file \end{DoxyCode} -Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00111}{111}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00115}{115}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}\label{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518} -\index{Delays defines@{Delays defines}!msDelayWaitDone@{msDelayWaitDone}} +\Hypertarget{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}\index{Delays defines@{Delays defines}!msDelayWaitDone@{msDelayWaitDone}} \index{msDelayWaitDone@{msDelayWaitDone}!Delays defines@{Delays defines}} \doxysubsubsubsubsection{\texorpdfstring{msDelayWaitDone}{msDelayWaitDone}} -{\footnotesize\ttfamily \#define ms\+Delay\+Wait\+Done(\begin{DoxyParamCaption}\item[{}]{\+\_\+ms\+\_\+, }\item[{}]{\+\_\+pvar\+\_\+ }\end{DoxyParamCaption})~(HAL\+\_\+\+Get\+Tick() -\/ \texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) $>$= \+\_\+ms\+\_\+)} +{\footnotesize\ttfamily \label{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518} +\#define ms\+Delay\+Wait\+Done(\begin{DoxyParamCaption}\item[{}]{\+\_\+ms\+\_\+}{, }\item[{}]{\+\_\+pvar\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}()\ -\/\ *(\_pvar\_)\ >=\ \_ms\_)} + +\end{DoxyCode} Проверяет, завершилась ли задержка. @@ -148,5 +170,5 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00111}{111}} of file \end{DoxyCode} -Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00128}{128}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00132}{132}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. diff --git a/Doc/latex/group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.tex b/Doc/latex/group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.tex index 54906b7..c4cbba2 100644 --- a/Doc/latex/group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.tex +++ b/Doc/latex/group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Error Handler defines} +\doxysubsubsection{Error Handler defines } \hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s}{}\label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s}\index{Error Handler defines@{Error Handler defines}} @@ -15,17 +15,17 @@ Collaboration diagram for Error Handler defines\+:\nopagebreak \doxysubsubsubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gae110df81afd885a390bbeb152d7b709f}{My\+Libs\+\_\+\+Error\+\_\+\+Handler}}(params)~Error\+\_\+\+Handler(params) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gae110df81afd885a390bbeb152d7b709f}{My\+Libs\+\_\+\+Error\+\_\+\+Handler}}(params) \begin{DoxyCompactList}\small\item\em Error\+\_\+\+Handler который будет вызыватся в библиотеке \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga5d066a5b9781f9437e75d98677489eb9}{check\+\_\+null\+\_\+ptr\+\_\+1}}(p1)~(p1 == NULL) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga5d066a5b9781f9437e75d98677489eb9}{check\+\_\+null\+\_\+ptr\+\_\+1}}(p1) \begin{DoxyCompactList}\small\item\em Проверить один указатель на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga27b363f333cacdccc15f5174e096b5b3}{check\+\_\+null\+\_\+ptr\+\_\+2}}(p1, p2)~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& p2 == NULL)) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga27b363f333cacdccc15f5174e096b5b3}{check\+\_\+null\+\_\+ptr\+\_\+2}}(p1, p2) \begin{DoxyCompactList}\small\item\em Проверить два указателя на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga838b40542faa9aa273d18f921b21fda2}{check\+\_\+null\+\_\+ptr\+\_\+3}}(p1, p2, p3)~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& p3 == NULL)))) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga838b40542faa9aa273d18f921b21fda2}{check\+\_\+null\+\_\+ptr\+\_\+3}}(p1, p2, p3) \begin{DoxyCompactList}\small\item\em Проверить три указателя на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga590973be111afc3f9ba15e6939530254}{check\+\_\+null\+\_\+ptr\+\_\+4}}(p1, p2, p3, p4)~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& ((p3 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p3 != NULL \&\& p4 == NULL)))))) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga590973be111afc3f9ba15e6939530254}{check\+\_\+null\+\_\+ptr\+\_\+4}}(p1, p2, p3, p4) \begin{DoxyCompactList}\small\item\em Проверить четыре указателя на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gaab0aafd7a4a21ec4f338b19269f65490}{check\+\_\+null\+\_\+ptr\+\_\+5}}(p1, p2, p3, p4, p5)~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& ((p3 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p3 != NULL \&\& ((p4 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p4 != NULL \&\& p5 == NULL)))))))) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gaab0aafd7a4a21ec4f338b19269f65490}{check\+\_\+null\+\_\+ptr\+\_\+5}}(p1, p2, p3, p4, p5) \begin{DoxyCompactList}\small\item\em Проверить пять указателей на NULL. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsubsubsection*{Functions} \begin{DoxyCompactItemize} @@ -40,13 +40,20 @@ void {\bfseries Error\+\_\+\+Handler} (void) +\label{doc-define-members} +\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gae110df81afd885a390bbeb152d7b709f}\label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gae110df81afd885a390bbeb152d7b709f} -\index{Error Handler defines@{Error Handler defines}!MyLibs\_Error\_Handler@{MyLibs\_Error\_Handler}} +\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gae110df81afd885a390bbeb152d7b709f}\index{Error Handler defines@{Error Handler defines}!MyLibs\_Error\_Handler@{MyLibs\_Error\_Handler}} \index{MyLibs\_Error\_Handler@{MyLibs\_Error\_Handler}!Error Handler defines@{Error Handler defines}} \doxysubsubsubsubsection{\texorpdfstring{MyLibs\_Error\_Handler}{MyLibs\_Error\_Handler}} -{\footnotesize\ttfamily \#define My\+Libs\+\_\+\+Error\+\_\+\+Handler(\begin{DoxyParamCaption}\item[{}]{params }\end{DoxyParamCaption})~Error\+\_\+\+Handler(params)} +{\footnotesize\ttfamily \label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gae110df81afd885a390bbeb152d7b709f} +\#define My\+Libs\+\_\+\+Error\+\_\+\+Handler(\begin{DoxyParamCaption}\item[{}]{params}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{Error\_Handler(params)} + +\end{DoxyCode} Error\+\_\+\+Handler который будет вызыватся в библиотеке @@ -55,12 +62,17 @@ Error\+\_\+\+Handler который будет вызыватся в библи Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00031}{31}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga5d066a5b9781f9437e75d98677489eb9}\label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga5d066a5b9781f9437e75d98677489eb9} -\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_1@{check\_null\_ptr\_1}} +\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga5d066a5b9781f9437e75d98677489eb9}\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_1@{check\_null\_ptr\_1}} \index{check\_null\_ptr\_1@{check\_null\_ptr\_1}!Error Handler defines@{Error Handler defines}} \doxysubsubsubsubsection{\texorpdfstring{check\_null\_ptr\_1}{check\_null\_ptr\_1}} -{\footnotesize\ttfamily \#define check\+\_\+null\+\_\+ptr\+\_\+1(\begin{DoxyParamCaption}\item[{}]{p1 }\end{DoxyParamCaption})~(p1 == NULL)} +{\footnotesize\ttfamily \label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga5d066a5b9781f9437e75d98677489eb9} +\#define check\+\_\+null\+\_\+ptr\+\_\+1(\begin{DoxyParamCaption}\item[{}]{p1}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(p1\ ==\ NULL)} + +\end{DoxyCode} Проверить один указатель на NULL. @@ -69,12 +81,17 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00031}{31}} of file Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00038}{38}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga27b363f333cacdccc15f5174e096b5b3}\label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga27b363f333cacdccc15f5174e096b5b3} -\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_2@{check\_null\_ptr\_2}} +\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga27b363f333cacdccc15f5174e096b5b3}\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_2@{check\_null\_ptr\_2}} \index{check\_null\_ptr\_2@{check\_null\_ptr\_2}!Error Handler defines@{Error Handler defines}} \doxysubsubsubsubsection{\texorpdfstring{check\_null\_ptr\_2}{check\_null\_ptr\_2}} -{\footnotesize\ttfamily \#define check\+\_\+null\+\_\+ptr\+\_\+2(\begin{DoxyParamCaption}\item[{}]{p1, }\item[{}]{p2 }\end{DoxyParamCaption})~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& p2 == NULL))} +{\footnotesize\ttfamily \label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga27b363f333cacdccc15f5174e096b5b3} +\#define check\+\_\+null\+\_\+ptr\+\_\+2(\begin{DoxyParamCaption}\item[{}]{p1}{, }\item[{}]{p2}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{((p1\ ==\ NULL)\ ||\ (p1\ !=\ NULL\ \&\&\ p2\ ==\ NULL))} + +\end{DoxyCode} Проверить два указателя на NULL. @@ -83,12 +100,17 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00038}{38}} of file Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00041}{41}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga838b40542faa9aa273d18f921b21fda2}\label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga838b40542faa9aa273d18f921b21fda2} -\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_3@{check\_null\_ptr\_3}} +\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga838b40542faa9aa273d18f921b21fda2}\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_3@{check\_null\_ptr\_3}} \index{check\_null\_ptr\_3@{check\_null\_ptr\_3}!Error Handler defines@{Error Handler defines}} \doxysubsubsubsubsection{\texorpdfstring{check\_null\_ptr\_3}{check\_null\_ptr\_3}} -{\footnotesize\ttfamily \#define check\+\_\+null\+\_\+ptr\+\_\+3(\begin{DoxyParamCaption}\item[{}]{p1, }\item[{}]{p2, }\item[{}]{p3 }\end{DoxyParamCaption})~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& p3 == NULL))))} +{\footnotesize\ttfamily \label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga838b40542faa9aa273d18f921b21fda2} +\#define check\+\_\+null\+\_\+ptr\+\_\+3(\begin{DoxyParamCaption}\item[{}]{p1}{, }\item[{}]{p2}{, }\item[{}]{p3}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{((p1\ ==\ NULL)\ ||\ (p1\ !=\ NULL\ \&\&\ ((p2\ ==\ NULL)\ ||\ (p2\ !=\ NULL\ \&\&\ p3\ ==\ NULL))))} + +\end{DoxyCode} Проверить три указателя на NULL. @@ -97,12 +119,17 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00041}{41}} of file Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00044}{44}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga590973be111afc3f9ba15e6939530254}\label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga590973be111afc3f9ba15e6939530254} -\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_4@{check\_null\_ptr\_4}} +\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga590973be111afc3f9ba15e6939530254}\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_4@{check\_null\_ptr\_4}} \index{check\_null\_ptr\_4@{check\_null\_ptr\_4}!Error Handler defines@{Error Handler defines}} \doxysubsubsubsubsection{\texorpdfstring{check\_null\_ptr\_4}{check\_null\_ptr\_4}} -{\footnotesize\ttfamily \#define check\+\_\+null\+\_\+ptr\+\_\+4(\begin{DoxyParamCaption}\item[{}]{p1, }\item[{}]{p2, }\item[{}]{p3, }\item[{}]{p4 }\end{DoxyParamCaption})~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& ((p3 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p3 != NULL \&\& p4 == NULL))))))} +{\footnotesize\ttfamily \label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga590973be111afc3f9ba15e6939530254} +\#define check\+\_\+null\+\_\+ptr\+\_\+4(\begin{DoxyParamCaption}\item[{}]{p1}{, }\item[{}]{p2}{, }\item[{}]{p3}{, }\item[{}]{p4}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{((p1\ ==\ NULL)\ ||\ (p1\ !=\ NULL\ \&\&\ ((p2\ ==\ NULL)\ ||\ (p2\ !=\ NULL\ \&\&\ ((p3\ ==\ NULL)\ ||\ (p3\ !=\ NULL\ \&\&\ p4\ ==\ NULL))))))} + +\end{DoxyCode} Проверить четыре указателя на NULL. @@ -111,12 +138,17 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00044}{44}} of file Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00047}{47}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gaab0aafd7a4a21ec4f338b19269f65490}\label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gaab0aafd7a4a21ec4f338b19269f65490} -\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_5@{check\_null\_ptr\_5}} +\Hypertarget{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gaab0aafd7a4a21ec4f338b19269f65490}\index{Error Handler defines@{Error Handler defines}!check\_null\_ptr\_5@{check\_null\_ptr\_5}} \index{check\_null\_ptr\_5@{check\_null\_ptr\_5}!Error Handler defines@{Error Handler defines}} \doxysubsubsubsubsection{\texorpdfstring{check\_null\_ptr\_5}{check\_null\_ptr\_5}} -{\footnotesize\ttfamily \#define check\+\_\+null\+\_\+ptr\+\_\+5(\begin{DoxyParamCaption}\item[{}]{p1, }\item[{}]{p2, }\item[{}]{p3, }\item[{}]{p4, }\item[{}]{p5 }\end{DoxyParamCaption})~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& ((p3 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p3 != NULL \&\& ((p4 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p4 != NULL \&\& p5 == NULL))))))))} +{\footnotesize\ttfamily \label{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gaab0aafd7a4a21ec4f338b19269f65490} +\#define check\+\_\+null\+\_\+ptr\+\_\+5(\begin{DoxyParamCaption}\item[{}]{p1}{, }\item[{}]{p2}{, }\item[{}]{p3}{, }\item[{}]{p4}{, }\item[{}]{p5}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{((p1\ ==\ NULL)\ ||\ (p1\ !=\ NULL\ \&\&\ ((p2\ ==\ NULL)\ ||\ (p2\ !=\ NULL\ \&\&\ ((p3\ ==\ NULL)\ ||\ (p3\ !=\ NULL\ \&\&\ ((p4\ ==\ NULL)\ ||\ (p4\ !=\ NULL\ \&\&\ p5\ ==\ NULL))))))))} + +\end{DoxyCode} Проверить пять указателей на NULL. diff --git a/Doc/latex/group___e_v_o_l_v_e___c_o_n_f_i_g.tex b/Doc/latex/group___e_v_o_l_v_e___c_o_n_f_i_g.tex index 82a20c6..e26da1c 100644 --- a/Doc/latex/group___e_v_o_l_v_e___c_o_n_f_i_g.tex +++ b/Doc/latex/group___e_v_o_l_v_e___c_o_n_f_i_g.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Evolve configs} +\doxysubsubsection{Evolve configs } \hypertarget{group___e_v_o_l_v_e___c_o_n_f_i_g}{}\label{group___e_v_o_l_v_e___c_o_n_f_i_g}\index{Evolve configs@{Evolve configs}} @@ -28,12 +28,14 @@ Collaboration diagram for Evolve configs\+:\nopagebreak +\label{doc-define-members} +\Hypertarget{group___e_v_o_l_v_e___c_o_n_f_i_g_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___e_v_o_l_v_e___c_o_n_f_i_g_ga2cac097081444a7a9b040f4b11550e47}\label{group___e_v_o_l_v_e___c_o_n_f_i_g_ga2cac097081444a7a9b040f4b11550e47} -\index{Evolve configs@{Evolve configs}!ENABLE\_EVOLVE\_OPTIMIZATION@{ENABLE\_EVOLVE\_OPTIMIZATION}} +\Hypertarget{group___e_v_o_l_v_e___c_o_n_f_i_g_ga2cac097081444a7a9b040f4b11550e47}\index{Evolve configs@{Evolve configs}!ENABLE\_EVOLVE\_OPTIMIZATION@{ENABLE\_EVOLVE\_OPTIMIZATION}} \index{ENABLE\_EVOLVE\_OPTIMIZATION@{ENABLE\_EVOLVE\_OPTIMIZATION}!Evolve configs@{Evolve configs}} \doxysubsubsubsubsection{\texorpdfstring{ENABLE\_EVOLVE\_OPTIMIZATION}{ENABLE\_EVOLVE\_OPTIMIZATION}} -{\footnotesize\ttfamily \#define ENABLE\+\_\+\+EVOLVE\+\_\+\+OPTIMIZATION} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___c_o_n_f_i_g_ga2cac097081444a7a9b040f4b11550e47} +\#define ENABLE\+\_\+\+EVOLVE\+\_\+\+OPTIMIZATION} @@ -43,11 +45,11 @@ Collaboration diagram for Evolve configs\+:\nopagebreak Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00064}{64}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee}\label{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee} -\index{Evolve configs@{Evolve configs}!EVOLVE\_MAX\_PARAMS@{EVOLVE\_MAX\_PARAMS}} +\Hypertarget{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee}\index{Evolve configs@{Evolve configs}!EVOLVE\_MAX\_PARAMS@{EVOLVE\_MAX\_PARAMS}} \index{EVOLVE\_MAX\_PARAMS@{EVOLVE\_MAX\_PARAMS}!Evolve configs@{Evolve configs}} \doxysubsubsubsubsection{\texorpdfstring{EVOLVE\_MAX\_PARAMS}{EVOLVE\_MAX\_PARAMS}} -{\footnotesize\ttfamily \#define EVOLVE\+\_\+\+MAX\+\_\+\+PARAMS~20} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___c_o_n_f_i_g_ga80d6162495fc3776d8902610657d4fee} +\#define EVOLVE\+\_\+\+MAX\+\_\+\+PARAMS~20} @@ -57,11 +59,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00064}{64}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00065}{65}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}\label{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971} -\index{Evolve configs@{Evolve configs}!EVOLVE\_MAX\_CANDIDATES@{EVOLVE\_MAX\_CANDIDATES}} +\Hypertarget{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}\index{Evolve configs@{Evolve configs}!EVOLVE\_MAX\_CANDIDATES@{EVOLVE\_MAX\_CANDIDATES}} \index{EVOLVE\_MAX\_CANDIDATES@{EVOLVE\_MAX\_CANDIDATES}!Evolve configs@{Evolve configs}} \doxysubsubsubsubsection{\texorpdfstring{EVOLVE\_MAX\_CANDIDATES}{EVOLVE\_MAX\_CANDIDATES}} -{\footnotesize\ttfamily \#define EVOLVE\+\_\+\+MAX\+\_\+\+CANDIDATES~100} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971} +\#define EVOLVE\+\_\+\+MAX\+\_\+\+CANDIDATES~100} diff --git a/Doc/latex/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.tex b/Doc/latex/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.tex index 5d69cd9..0a8f274 100644 --- a/Doc/latex/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.tex +++ b/Doc/latex/group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Evolve optimizer} +\doxysubsubsection{Evolve optimizer } \hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r}{}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r}\index{Evolve optimizer@{Evolve optimizer}} @@ -20,12 +20,10 @@ struct \mbox{\hyperlink{struct_evolve_optimizer__t}{Evolve\+Optimizer\+\_\+t}} \doxysubsubsubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga83abbcabaff9111c03ae2475ee72ea3e}{PARAM\+\_\+\+SCALE}}(x, min\+\_\+val, max\+\_\+val)~(((float)(x) -\/ (float)(min\+\_\+val)) / ((float)(max\+\_\+val) -\/ (float)(min\+\_\+val))) +\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga83abbcabaff9111c03ae2475ee72ea3e}{PARAM\+\_\+\+SCALE}}(x, min\+\_\+val, max\+\_\+val) \begin{DoxyCompactList}\small\item\em Линейное масштабирование x из диапазона \mbox{[}min\+\_\+val, max\+\_\+val\mbox{]} в диапазон \mbox{[}0, 1) \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3}{PARAM\+\_\+\+UNSCALE}}(val, min\+\_\+val, max\+\_\+val)~(((float)(val)) \texorpdfstring{$\ast$}{*} ((float)(max\+\_\+val) -\/ (float)(min\+\_\+val)) + (float)(min\+\_\+val)) +\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3}{PARAM\+\_\+\+UNSCALE}}(val, min\+\_\+val, max\+\_\+val) \begin{DoxyCompactList}\small\item\em Обратное линейное масштабирование значения из \mbox{[}0, 1) в диапазон \mbox{[}min\+\_\+val, max\+\_\+val\mbox{]}. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga9c853b02c22f26023c34d1d404b6d653}{local\+\_\+time}}()~HAL\+\_\+\+Get\+Tick() -\begin{DoxyCompactList}\small\item\em Локальное время \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6}{EVOLVE\+\_\+\+MUTATION\+\_\+\+MIN\+\_\+\+PCT}}~10 \begin{DoxyCompactList}\small\item\em Минимальная мутация (в процентах от Loss) \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga861c1c6a503c21441abcec0d57b848bc}{EVOLVE\+\_\+\+MUTATION\+\_\+\+MAX\+\_\+\+PCT}}~100 @@ -97,18 +95,24 @@ struct \mbox{\hyperlink{struct_evolve_optimizer__t}{Evolve\+Optimizer\+\_\+t}} \DoxyCodeLine{param\_i16\ =\ \mbox{\hyperlink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3}{PARAM\_UNSCALE}}(params[3],\ \ 500.0f,\ 5000.0f);} \end{DoxyCode} - ~\newline \end{DoxyParagraph} +\label{doc-define-members} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga83abbcabaff9111c03ae2475ee72ea3e}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga83abbcabaff9111c03ae2475ee72ea3e} -\index{Evolve optimizer@{Evolve optimizer}!PARAM\_SCALE@{PARAM\_SCALE}} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga83abbcabaff9111c03ae2475ee72ea3e}\index{Evolve optimizer@{Evolve optimizer}!PARAM\_SCALE@{PARAM\_SCALE}} \index{PARAM\_SCALE@{PARAM\_SCALE}!Evolve optimizer@{Evolve optimizer}} \doxysubsubsubsubsection{\texorpdfstring{PARAM\_SCALE}{PARAM\_SCALE}} -{\footnotesize\ttfamily \#define PARAM\+\_\+\+SCALE(\begin{DoxyParamCaption}\item[{}]{x, }\item[{}]{min\+\_\+val, }\item[{}]{max\+\_\+val }\end{DoxyParamCaption})~(((float)(x) -\/ (float)(min\+\_\+val)) / ((float)(max\+\_\+val) -\/ (float)(min\+\_\+val)))} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga83abbcabaff9111c03ae2475ee72ea3e} +\#define PARAM\+\_\+\+SCALE(\begin{DoxyParamCaption}\item[{}]{x}{, }\item[{}]{min\+\_\+val}{, }\item[{}]{max\+\_\+val}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(((float)(x)\ -\/\ (float)(min\_val))\ /\ ((float)(max\_val)\ -\/\ (float)(min\_val)))} + +\end{DoxyCode} Линейное масштабирование x из диапазона \mbox{[}min\+\_\+val, max\+\_\+val\mbox{]} в диапазон \mbox{[}0, 1) @@ -117,12 +121,17 @@ struct \mbox{\hyperlink{struct_evolve_optimizer__t}{Evolve\+Optimizer\+\_\+t}} Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00073}{73}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3} -\index{Evolve optimizer@{Evolve optimizer}!PARAM\_UNSCALE@{PARAM\_UNSCALE}} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3}\index{Evolve optimizer@{Evolve optimizer}!PARAM\_UNSCALE@{PARAM\_UNSCALE}} \index{PARAM\_UNSCALE@{PARAM\_UNSCALE}!Evolve optimizer@{Evolve optimizer}} \doxysubsubsubsubsection{\texorpdfstring{PARAM\_UNSCALE}{PARAM\_UNSCALE}} -{\footnotesize\ttfamily \#define PARAM\+\_\+\+UNSCALE(\begin{DoxyParamCaption}\item[{}]{val, }\item[{}]{min\+\_\+val, }\item[{}]{max\+\_\+val }\end{DoxyParamCaption})~(((float)(val)) \texorpdfstring{$\ast$}{*} ((float)(max\+\_\+val) -\/ (float)(min\+\_\+val)) + (float)(min\+\_\+val))} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaa1d5510fe5f0bd989473f3ebe324bde3} +\#define PARAM\+\_\+\+UNSCALE(\begin{DoxyParamCaption}\item[{}]{val}{, }\item[{}]{min\+\_\+val}{, }\item[{}]{max\+\_\+val}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(((float)(val))\ *\ ((float)(max\_val)\ -\/\ (float)(min\_val))\ +\ (float)(min\_val))} + +\end{DoxyCode} Обратное линейное масштабирование значения из \mbox{[}0, 1) в диапазон \mbox{[}min\+\_\+val, max\+\_\+val\mbox{]}. @@ -131,25 +140,11 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00073}{73}} of Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00079}{79}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga9c853b02c22f26023c34d1d404b6d653}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga9c853b02c22f26023c34d1d404b6d653} -\index{Evolve optimizer@{Evolve optimizer}!local\_time@{local\_time}} -\index{local\_time@{local\_time}!Evolve optimizer@{Evolve optimizer}} -\doxysubsubsubsubsection{\texorpdfstring{local\_time}{local\_time}} -{\footnotesize\ttfamily \#define local\+\_\+time(\begin{DoxyParamCaption}{ }\end{DoxyParamCaption})~HAL\+\_\+\+Get\+Tick()} - - - -Локальное время - - - -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00083}{83}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. - -\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6} -\index{Evolve optimizer@{Evolve optimizer}!EVOLVE\_MUTATION\_MIN\_PCT@{EVOLVE\_MUTATION\_MIN\_PCT}} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6}\index{Evolve optimizer@{Evolve optimizer}!EVOLVE\_MUTATION\_MIN\_PCT@{EVOLVE\_MUTATION\_MIN\_PCT}} \index{EVOLVE\_MUTATION\_MIN\_PCT@{EVOLVE\_MUTATION\_MIN\_PCT}!Evolve optimizer@{Evolve optimizer}} \doxysubsubsubsubsection{\texorpdfstring{EVOLVE\_MUTATION\_MIN\_PCT}{EVOLVE\_MUTATION\_MIN\_PCT}} -{\footnotesize\ttfamily \#define EVOLVE\+\_\+\+MUTATION\+\_\+\+MIN\+\_\+\+PCT~10} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga2f2b1be34ad4eb1bf3267237200cd6c6} +\#define EVOLVE\+\_\+\+MUTATION\+\_\+\+MIN\+\_\+\+PCT~10} @@ -159,11 +154,11 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00083}{83}} of Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00089}{89}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga861c1c6a503c21441abcec0d57b848bc}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga861c1c6a503c21441abcec0d57b848bc} -\index{Evolve optimizer@{Evolve optimizer}!EVOLVE\_MUTATION\_MAX\_PCT@{EVOLVE\_MUTATION\_MAX\_PCT}} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga861c1c6a503c21441abcec0d57b848bc}\index{Evolve optimizer@{Evolve optimizer}!EVOLVE\_MUTATION\_MAX\_PCT@{EVOLVE\_MUTATION\_MAX\_PCT}} \index{EVOLVE\_MUTATION\_MAX\_PCT@{EVOLVE\_MUTATION\_MAX\_PCT}!Evolve optimizer@{Evolve optimizer}} \doxysubsubsubsubsection{\texorpdfstring{EVOLVE\_MUTATION\_MAX\_PCT}{EVOLVE\_MUTATION\_MAX\_PCT}} -{\footnotesize\ttfamily \#define EVOLVE\+\_\+\+MUTATION\+\_\+\+MAX\+\_\+\+PCT~100} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga861c1c6a503c21441abcec0d57b848bc} +\#define EVOLVE\+\_\+\+MUTATION\+\_\+\+MAX\+\_\+\+PCT~100} @@ -173,11 +168,11 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00089}{89}} of Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00092}{92}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga38607e23d9234524bc7de5869b15b8eb}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga38607e23d9234524bc7de5869b15b8eb} -\index{Evolve optimizer@{Evolve optimizer}!ELOVLE\_N\_ELITE\_CANDIDATE@{ELOVLE\_N\_ELITE\_CANDIDATE}} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga38607e23d9234524bc7de5869b15b8eb}\index{Evolve optimizer@{Evolve optimizer}!ELOVLE\_N\_ELITE\_CANDIDATE@{ELOVLE\_N\_ELITE\_CANDIDATE}} \index{ELOVLE\_N\_ELITE\_CANDIDATE@{ELOVLE\_N\_ELITE\_CANDIDATE}!Evolve optimizer@{Evolve optimizer}} \doxysubsubsubsubsection{\texorpdfstring{ELOVLE\_N\_ELITE\_CANDIDATE}{ELOVLE\_N\_ELITE\_CANDIDATE}} -{\footnotesize\ttfamily \#define ELOVLE\+\_\+\+N\+\_\+\+ELITE\+\_\+\+CANDIDATE~2} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga38607e23d9234524bc7de5869b15b8eb} +\#define ELOVLE\+\_\+\+N\+\_\+\+ELITE\+\_\+\+CANDIDATE~2} @@ -189,12 +184,14 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00095}{95}} of +\label{doc-func-members} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_doc-func-members} \doxysubsubsubsection{Function Documentation} -\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga4e3ea118b5b9068619c57724a925ba21}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga4e3ea118b5b9068619c57724a925ba21} -\index{Evolve optimizer@{Evolve optimizer}!EvolveOptimizer\_Init@{EvolveOptimizer\_Init}} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga4e3ea118b5b9068619c57724a925ba21}\index{Evolve optimizer@{Evolve optimizer}!EvolveOptimizer\_Init@{EvolveOptimizer\_Init}} \index{EvolveOptimizer\_Init@{EvolveOptimizer\_Init}!Evolve optimizer@{Evolve optimizer}} \doxysubsubsubsubsection{\texorpdfstring{EvolveOptimizer\_Init()}{EvolveOptimizer\_Init()}} -{\footnotesize\ttfamily \+\_\+\+\_\+\+STATIC\+\_\+\+INLINE int Evolve\+Optimizer\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_evolve_optimizer__t}{Evolve\+Optimizer\+\_\+t}} \texorpdfstring{$\ast$}{*}}]{opt, }\item[{uint16\+\_\+t}]{n\+\_\+params, }\item[{uint16\+\_\+t}]{n\+\_\+cand, }\item[{uint16\+\_\+t}]{n\+\_\+best, }\item[{float}]{mutation\+\_\+amp, }\item[{float \texorpdfstring{$\ast$}{*}}]{start\+\_\+params }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_ga4e3ea118b5b9068619c57724a925ba21} +\+\_\+\+\_\+\+STATIC\+\_\+\+INLINE int Evolve\+Optimizer\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_evolve_optimizer__t}{Evolve\+Optimizer\+\_\+t}} \texorpdfstring{$\ast$}{*}}]{opt}{, }\item[{uint16\+\_\+t}]{n\+\_\+params}{, }\item[{uint16\+\_\+t}]{n\+\_\+cand}{, }\item[{uint16\+\_\+t}]{n\+\_\+best}{, }\item[{float}]{mutation\+\_\+amp}{, }\item[{float \texorpdfstring{$\ast$}{*}}]{start\+\_\+params}{}\end{DoxyParamCaption})} @@ -220,13 +217,13 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00095}{95}} of \end{DoxyReturn} -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00148}{148}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00155}{155}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaef44a1f3298514569cc2b396a92101ef}\label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaef44a1f3298514569cc2b396a92101ef} -\index{Evolve optimizer@{Evolve optimizer}!EvolveOptimizer\_Step@{EvolveOptimizer\_Step}} +\Hypertarget{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaef44a1f3298514569cc2b396a92101ef}\index{Evolve optimizer@{Evolve optimizer}!EvolveOptimizer\_Step@{EvolveOptimizer\_Step}} \index{EvolveOptimizer\_Step@{EvolveOptimizer\_Step}!Evolve optimizer@{Evolve optimizer}} \doxysubsubsubsubsection{\texorpdfstring{EvolveOptimizer\_Step()}{EvolveOptimizer\_Step()}} -{\footnotesize\ttfamily \+\_\+\+\_\+\+STATIC\+\_\+\+INLINE int Evolve\+Optimizer\+\_\+\+Step (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_evolve_optimizer__t}{Evolve\+Optimizer\+\_\+t}} \texorpdfstring{$\ast$}{*}}]{opt, }\item[{float \texorpdfstring{$\ast$}{*}}]{params, }\item[{float}]{loss }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r_gaef44a1f3298514569cc2b396a92101ef} +\+\_\+\+\_\+\+STATIC\+\_\+\+INLINE int Evolve\+Optimizer\+\_\+\+Step (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_evolve_optimizer__t}{Evolve\+Optimizer\+\_\+t}} \texorpdfstring{$\ast$}{*}}]{opt}{, }\item[{float \texorpdfstring{$\ast$}{*}}]{params}{, }\item[{float}]{loss}{}\end{DoxyParamCaption})} @@ -251,5 +248,5 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00148}{148}} of \end{DoxyNote} -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00216}{216}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00225}{225}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. diff --git a/Doc/latex/group___g_p_i_o___i_n_i_t.tex b/Doc/latex/group___g_p_i_o___i_n_i_t.tex index 860c2ce..d70cca7 100644 --- a/Doc/latex/group___g_p_i_o___i_n_i_t.tex +++ b/Doc/latex/group___g_p_i_o___i_n_i_t.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsubsection{Init defines} +\doxysubsubsubsubsection{Init defines } \hypertarget{group___g_p_i_o___i_n_i_t}{}\label{group___g_p_i_o___i_n_i_t}\index{Init defines@{Init defines}} @@ -32,12 +32,14 @@ Collaboration diagram for Init defines\+:\nopagebreak +\label{doc-define-members} +\Hypertarget{group___g_p_i_o___i_n_i_t_doc-define-members} \doxysubsubsubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___g_p_i_o___i_n_i_t_ga1d42e219765ec526d99e306638ac0023}\label{group___g_p_i_o___i_n_i_t_ga1d42e219765ec526d99e306638ac0023} -\index{Init defines@{Init defines}!LED\_PWM\_TICKS@{LED\_PWM\_TICKS}} +\Hypertarget{group___g_p_i_o___i_n_i_t_ga1d42e219765ec526d99e306638ac0023}\index{Init defines@{Init defines}!LED\_PWM\_TICKS@{LED\_PWM\_TICKS}} \index{LED\_PWM\_TICKS@{LED\_PWM\_TICKS}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{LED\_PWM\_TICKS}{LED\_PWM\_TICKS}} -{\footnotesize\ttfamily \#define LED\+\_\+\+PWM\+\_\+\+TICKS~15} +{\footnotesize\ttfamily \label{group___g_p_i_o___i_n_i_t_ga1d42e219765ec526d99e306638ac0023} +\#define LED\+\_\+\+PWM\+\_\+\+TICKS~15} @@ -45,13 +47,13 @@ Collaboration diagram for Init defines\+:\nopagebreak -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00031}{31}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00035}{35}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{group___g_p_i_o___i_n_i_t_gaf2e697ac60e05813d45ea2c9c9e79c25}\label{group___g_p_i_o___i_n_i_t_gaf2e697ac60e05813d45ea2c9c9e79c25} -\index{Init defines@{Init defines}!LED\_ON@{LED\_ON}} +\Hypertarget{group___g_p_i_o___i_n_i_t_gaf2e697ac60e05813d45ea2c9c9e79c25}\index{Init defines@{Init defines}!LED\_ON@{LED\_ON}} \index{LED\_ON@{LED\_ON}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{LED\_ON}{LED\_ON}} -{\footnotesize\ttfamily \#define LED\+\_\+\+ON~1} +{\footnotesize\ttfamily \label{group___g_p_i_o___i_n_i_t_gaf2e697ac60e05813d45ea2c9c9e79c25} +\#define LED\+\_\+\+ON~1} @@ -59,13 +61,13 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00031}{31}} of file -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00035}{35}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00039}{39}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{group___g_p_i_o___i_n_i_t_ga80700bb63bd56ebabbb4728aa433fd29}\label{group___g_p_i_o___i_n_i_t_ga80700bb63bd56ebabbb4728aa433fd29} -\index{Init defines@{Init defines}!LED\_OFF@{LED\_OFF}} +\Hypertarget{group___g_p_i_o___i_n_i_t_ga80700bb63bd56ebabbb4728aa433fd29}\index{Init defines@{Init defines}!LED\_OFF@{LED\_OFF}} \index{LED\_OFF@{LED\_OFF}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{LED\_OFF}{LED\_OFF}} -{\footnotesize\ttfamily \#define LED\+\_\+\+OFF~0} +{\footnotesize\ttfamily \label{group___g_p_i_o___i_n_i_t_ga80700bb63bd56ebabbb4728aa433fd29} +\#define LED\+\_\+\+OFF~0} @@ -73,13 +75,13 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00035}{35}} of file -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00038}{38}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00042}{42}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{group___g_p_i_o___i_n_i_t_ga19d9e3aced311179a2914e0c9b13d0f9}\label{group___g_p_i_o___i_n_i_t_ga19d9e3aced311179a2914e0c9b13d0f9} -\index{Init defines@{Init defines}!SW\_ON@{SW\_ON}} +\Hypertarget{group___g_p_i_o___i_n_i_t_ga19d9e3aced311179a2914e0c9b13d0f9}\index{Init defines@{Init defines}!SW\_ON@{SW\_ON}} \index{SW\_ON@{SW\_ON}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{SW\_ON}{SW\_ON}} -{\footnotesize\ttfamily \#define SW\+\_\+\+ON~1} +{\footnotesize\ttfamily \label{group___g_p_i_o___i_n_i_t_ga19d9e3aced311179a2914e0c9b13d0f9} +\#define SW\+\_\+\+ON~1} @@ -87,13 +89,13 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00038}{38}} of file -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00042}{42}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00046}{46}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{group___g_p_i_o___i_n_i_t_gacd8900c9ec0efde1da3253b718574067}\label{group___g_p_i_o___i_n_i_t_gacd8900c9ec0efde1da3253b718574067} -\index{Init defines@{Init defines}!SW\_OFF@{SW\_OFF}} +\Hypertarget{group___g_p_i_o___i_n_i_t_gacd8900c9ec0efde1da3253b718574067}\index{Init defines@{Init defines}!SW\_OFF@{SW\_OFF}} \index{SW\_OFF@{SW\_OFF}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{SW\_OFF}{SW\_OFF}} -{\footnotesize\ttfamily \#define SW\+\_\+\+OFF~0} +{\footnotesize\ttfamily \label{group___g_p_i_o___i_n_i_t_gacd8900c9ec0efde1da3253b718574067} +\#define SW\+\_\+\+OFF~0} @@ -101,5 +103,5 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00042}{42}} of file -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00045}{45}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00049}{49}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. diff --git a/Doc/latex/group___l_i_b_s___c_o_n_f_i_g.tex b/Doc/latex/group___l_i_b_s___c_o_n_f_i_g.tex index 07a864c..5bee9ab 100644 --- a/Doc/latex/group___l_i_b_s___c_o_n_f_i_g.tex +++ b/Doc/latex/group___l_i_b_s___c_o_n_f_i_g.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Libraries configs} +\doxysubsubsection{Libraries configs } \hypertarget{group___l_i_b_s___c_o_n_f_i_g}{}\label{group___l_i_b_s___c_o_n_f_i_g}\index{Libraries configs@{Libraries configs}} @@ -15,6 +15,8 @@ Collaboration diagram for Libraries configs\+:\nopagebreak \doxysubsubsubsubsection*{Macros} \begin{DoxyCompactItemize} \item +\#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\+\_\+time}}() +\begin{DoxyCompactList}\small\item\em Локальное время \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga66560656d080d6551627a19dfb847c66}{INCLUDE\+\_\+\+EVOLVE\+\_\+\+OPTIMIZER}} \begin{DoxyCompactList}\small\item\em Подключить библиотеку для оптимизации параметров \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_gaf4ddb2a71ec0d05c2480e197cd17c0be}{INCLUDE\+\_\+\+BIT\+\_\+\+ACCESS\+\_\+\+LIB}} @@ -24,7 +26,9 @@ Collaboration diagram for Libraries configs\+:\nopagebreak \#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga0a3ca94b616997069dd53e2c6c2687d7}{INCLUDE\+\_\+\+TRACE\+\_\+\+LIB}} \begin{DoxyCompactList}\small\item\em Подключить библиотеку с трейсами \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga181a46326e46b60afb160190832c7281}{INCLUDE\+\_\+\+GENERAL\+\_\+\+PERIPH\+\_\+\+LIBS}} -\begin{DoxyCompactList}\small\item\em Подключить библиотеку с периферией \end{DoxyCompactList}\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Подключить библиотеку с периферией \end{DoxyCompactList}\item +\#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga57c369737d5c0cfdb7baeecba0a4b151}{FREERTOS\+\_\+\+DELAY}} +\begin{DoxyCompactList}\small\item\em Использовать Free\+RTOS задержку, вместо HAL. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsubsection{Detailed Description} @@ -32,12 +36,33 @@ Collaboration diagram for Libraries configs\+:\nopagebreak +\label{doc-define-members} +\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga66560656d080d6551627a19dfb847c66}\label{group___l_i_b_s___c_o_n_f_i_g_ga66560656d080d6551627a19dfb847c66} -\index{Libraries configs@{Libraries configs}!INCLUDE\_EVOLVE\_OPTIMIZER@{INCLUDE\_EVOLVE\_OPTIMIZER}} +\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}\index{Libraries configs@{Libraries configs}!local\_time@{local\_time}} +\index{local\_time@{local\_time}!Libraries configs@{Libraries configs}} +\doxysubsubsubsubsection{\texorpdfstring{local\_time}{local\_time}} +{\footnotesize\ttfamily \label{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653} +\#define local\+\_\+time(\begin{DoxyParamCaption}{}{}\end{DoxyParamCaption})} + +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{uwTick} + +\end{DoxyCode} + + +Локальное время + + + +Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00080}{80}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. + +\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga66560656d080d6551627a19dfb847c66}\index{Libraries configs@{Libraries configs}!INCLUDE\_EVOLVE\_OPTIMIZER@{INCLUDE\_EVOLVE\_OPTIMIZER}} \index{INCLUDE\_EVOLVE\_OPTIMIZER@{INCLUDE\_EVOLVE\_OPTIMIZER}!Libraries configs@{Libraries configs}} \doxysubsubsubsubsection{\texorpdfstring{INCLUDE\_EVOLVE\_OPTIMIZER}{INCLUDE\_EVOLVE\_OPTIMIZER}} -{\footnotesize\ttfamily \#define INCLUDE\+\_\+\+EVOLVE\+\_\+\+OPTIMIZER} +{\footnotesize\ttfamily \label{group___l_i_b_s___c_o_n_f_i_g_ga66560656d080d6551627a19dfb847c66} +\#define INCLUDE\+\_\+\+EVOLVE\+\_\+\+OPTIMIZER} @@ -45,13 +70,13 @@ Collaboration diagram for Libraries configs\+:\nopagebreak -Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00080}{80}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00082}{82}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_gaf4ddb2a71ec0d05c2480e197cd17c0be}\label{group___l_i_b_s___c_o_n_f_i_g_gaf4ddb2a71ec0d05c2480e197cd17c0be} -\index{Libraries configs@{Libraries configs}!INCLUDE\_BIT\_ACCESS\_LIB@{INCLUDE\_BIT\_ACCESS\_LIB}} +\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_gaf4ddb2a71ec0d05c2480e197cd17c0be}\index{Libraries configs@{Libraries configs}!INCLUDE\_BIT\_ACCESS\_LIB@{INCLUDE\_BIT\_ACCESS\_LIB}} \index{INCLUDE\_BIT\_ACCESS\_LIB@{INCLUDE\_BIT\_ACCESS\_LIB}!Libraries configs@{Libraries configs}} \doxysubsubsubsubsection{\texorpdfstring{INCLUDE\_BIT\_ACCESS\_LIB}{INCLUDE\_BIT\_ACCESS\_LIB}} -{\footnotesize\ttfamily \#define INCLUDE\+\_\+\+BIT\+\_\+\+ACCESS\+\_\+\+LIB} +{\footnotesize\ttfamily \label{group___l_i_b_s___c_o_n_f_i_g_gaf4ddb2a71ec0d05c2480e197cd17c0be} +\#define INCLUDE\+\_\+\+BIT\+\_\+\+ACCESS\+\_\+\+LIB} @@ -59,13 +84,13 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00080}{80}} of fil -Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00081}{81}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00083}{83}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga4403055986b70bb02b8d37073a122e32}\label{group___l_i_b_s___c_o_n_f_i_g_ga4403055986b70bb02b8d37073a122e32} -\index{Libraries configs@{Libraries configs}!INCLUDE\_TRACKERS\_LIB@{INCLUDE\_TRACKERS\_LIB}} +\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga4403055986b70bb02b8d37073a122e32}\index{Libraries configs@{Libraries configs}!INCLUDE\_TRACKERS\_LIB@{INCLUDE\_TRACKERS\_LIB}} \index{INCLUDE\_TRACKERS\_LIB@{INCLUDE\_TRACKERS\_LIB}!Libraries configs@{Libraries configs}} \doxysubsubsubsubsection{\texorpdfstring{INCLUDE\_TRACKERS\_LIB}{INCLUDE\_TRACKERS\_LIB}} -{\footnotesize\ttfamily \#define INCLUDE\+\_\+\+TRACKERS\+\_\+\+LIB} +{\footnotesize\ttfamily \label{group___l_i_b_s___c_o_n_f_i_g_ga4403055986b70bb02b8d37073a122e32} +\#define INCLUDE\+\_\+\+TRACKERS\+\_\+\+LIB} @@ -73,13 +98,13 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00081}{81}} of fil -Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00082}{82}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00084}{84}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga0a3ca94b616997069dd53e2c6c2687d7}\label{group___l_i_b_s___c_o_n_f_i_g_ga0a3ca94b616997069dd53e2c6c2687d7} -\index{Libraries configs@{Libraries configs}!INCLUDE\_TRACE\_LIB@{INCLUDE\_TRACE\_LIB}} +\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga0a3ca94b616997069dd53e2c6c2687d7}\index{Libraries configs@{Libraries configs}!INCLUDE\_TRACE\_LIB@{INCLUDE\_TRACE\_LIB}} \index{INCLUDE\_TRACE\_LIB@{INCLUDE\_TRACE\_LIB}!Libraries configs@{Libraries configs}} \doxysubsubsubsubsection{\texorpdfstring{INCLUDE\_TRACE\_LIB}{INCLUDE\_TRACE\_LIB}} -{\footnotesize\ttfamily \#define INCLUDE\+\_\+\+TRACE\+\_\+\+LIB} +{\footnotesize\ttfamily \label{group___l_i_b_s___c_o_n_f_i_g_ga0a3ca94b616997069dd53e2c6c2687d7} +\#define INCLUDE\+\_\+\+TRACE\+\_\+\+LIB} @@ -87,13 +112,13 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00082}{82}} of fil -Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00083}{83}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00085}{85}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga181a46326e46b60afb160190832c7281}\label{group___l_i_b_s___c_o_n_f_i_g_ga181a46326e46b60afb160190832c7281} -\index{Libraries configs@{Libraries configs}!INCLUDE\_GENERAL\_PERIPH\_LIBS@{INCLUDE\_GENERAL\_PERIPH\_LIBS}} +\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga181a46326e46b60afb160190832c7281}\index{Libraries configs@{Libraries configs}!INCLUDE\_GENERAL\_PERIPH\_LIBS@{INCLUDE\_GENERAL\_PERIPH\_LIBS}} \index{INCLUDE\_GENERAL\_PERIPH\_LIBS@{INCLUDE\_GENERAL\_PERIPH\_LIBS}!Libraries configs@{Libraries configs}} \doxysubsubsubsubsection{\texorpdfstring{INCLUDE\_GENERAL\_PERIPH\_LIBS}{INCLUDE\_GENERAL\_PERIPH\_LIBS}} -{\footnotesize\ttfamily \#define INCLUDE\+\_\+\+GENERAL\+\_\+\+PERIPH\+\_\+\+LIBS} +{\footnotesize\ttfamily \label{group___l_i_b_s___c_o_n_f_i_g_ga181a46326e46b60afb160190832c7281} +\#define INCLUDE\+\_\+\+GENERAL\+\_\+\+PERIPH\+\_\+\+LIBS} @@ -101,5 +126,19 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00083}{83}} of fil -Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00084}{84}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00086}{86}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. + +\Hypertarget{group___l_i_b_s___c_o_n_f_i_g_ga57c369737d5c0cfdb7baeecba0a4b151}\index{Libraries configs@{Libraries configs}!FREERTOS\_DELAY@{FREERTOS\_DELAY}} +\index{FREERTOS\_DELAY@{FREERTOS\_DELAY}!Libraries configs@{Libraries configs}} +\doxysubsubsubsubsection{\texorpdfstring{FREERTOS\_DELAY}{FREERTOS\_DELAY}} +{\footnotesize\ttfamily \label{group___l_i_b_s___c_o_n_f_i_g_ga57c369737d5c0cfdb7baeecba0a4b151} +\#define FREERTOS\+\_\+\+DELAY} + + + +Использовать Free\+RTOS задержку, вместо HAL. + + + +Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00087}{87}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. diff --git a/Doc/latex/group___m_y___l_i_b_s___g_p_i_o.tex b/Doc/latex/group___m_y___l_i_b_s___g_p_i_o.tex index 9604806..775dad4 100644 --- a/Doc/latex/group___m_y___l_i_b_s___g_p_i_o.tex +++ b/Doc/latex/group___m_y___l_i_b_s___g_p_i_o.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{GPIO Tools} +\doxysubsubsection{GPIO Tools } \hypertarget{group___m_y___l_i_b_s___g_p_i_o}{}\label{group___m_y___l_i_b_s___g_p_i_o}\index{GPIO Tools@{GPIO Tools}} diff --git a/Doc/latex/group___m_y___l_i_b_s___t_i_m.md5 b/Doc/latex/group___m_y___l_i_b_s___t_i_m.md5 index 588e808..ab26041 100644 --- a/Doc/latex/group___m_y___l_i_b_s___t_i_m.md5 +++ b/Doc/latex/group___m_y___l_i_b_s___t_i_m.md5 @@ -1 +1 @@ -bddd90356fb04fa1e92560356c210866 \ No newline at end of file +936137dd7521a28e69e9d997087dab56 \ No newline at end of file diff --git a/Doc/latex/group___m_y___l_i_b_s___t_i_m.pdf b/Doc/latex/group___m_y___l_i_b_s___t_i_m.pdf index fec6f21..9f0f342 100644 Binary files a/Doc/latex/group___m_y___l_i_b_s___t_i_m.pdf and b/Doc/latex/group___m_y___l_i_b_s___t_i_m.pdf differ diff --git a/Doc/latex/group___m_y___l_i_b_s___t_i_m.tex b/Doc/latex/group___m_y___l_i_b_s___t_i_m.tex index 6b4ceeb..15c5f40 100644 --- a/Doc/latex/group___m_y___l_i_b_s___t_i_m.tex +++ b/Doc/latex/group___m_y___l_i_b_s___t_i_m.tex @@ -1,11 +1,12 @@ -\doxysubsubsection{TIM Tools} +\doxysubsubsection{TIM Tools } \hypertarget{group___m_y___l_i_b_s___t_i_m}{}\label{group___m_y___l_i_b_s___t_i_m}\index{TIM Tools@{TIM Tools}} Функции и макросы для удобной работы с TIM. -Collaboration diagram for TIM Tools\+:\nopagebreak +Collaboration diagram for TIM Tools\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode @@ -15,14 +16,14 @@ Collaboration diagram for TIM Tools\+:\nopagebreak \doxysubsubsubsubsection*{Topics} \begin{DoxyCompactItemize} \item +\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l}{General tools}} +\begin{DoxyCompactList}\small\item\em Функции для базовой инициализации таймеров \end{DoxyCompactList}\item +\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y}{Delay tools}} +\begin{DoxyCompactList}\small\item\em Функции для формирования задержек с помощью таймеров \end{DoxyCompactList}\item \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c}{PWM/\+OC Channels tools}} \begin{DoxyCompactList}\small\item\em Функции для инициализации базовых функций каналов таймера \end{DoxyCompactList}\item \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r}{Encoder tools}} -\begin{DoxyCompactList}\small\item\em Функции для считывания энкодера \end{DoxyCompactList}\item -\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y}{Delay tools}} -\begin{DoxyCompactList}\small\item\em Функции для формирования задержек с помощью таймеров \end{DoxyCompactList}\item -\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l}{General tools}} -\begin{DoxyCompactList}\small\item\em Функции для базовой инициализации таймеров \end{DoxyCompactList}\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Функции для считывания энкодера \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsubsection{Detailed Description} @@ -33,8 +34,10 @@ Collaboration diagram for TIM Tools\+:\nopagebreak \item \doxylink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l}{General tools} — базовая инициализация таймеров и прерываний. \item \doxylink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y}{Delay tools} — функции задержки через таймеры (blocking и non-\/blocking). \item \doxylink{group___m_y_l_i_b_s___t_i_m___o_c}{PWM/\+OC Channels tools} — настройка каналов Output Compare и PWM. -\item \doxylink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r}{Encoder tools} — работа с энкодерами, чтение положения и кнопки. \begin{DoxyNote}{Note} -Требуется подключение модуля TIM в библиотеке HAL +\item \doxylink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r}{Encoder tools} — работа с энкодерами, чтение положения и кнопки. + +\begin{DoxyNote}{Note} +Требуется подключение модуля TIM в библиотеке HAL и GPIO (\doxylink{group___m_y___l_i_b_s___g_p_i_o}{GPIO Tools}) из My\+Libs \begin{DoxyCode}{0} \DoxyCodeLine{\textcolor{preprocessor}{\#define\ HAL\_TIM\_MODULE\_ENABLED}} @@ -42,7 +45,7 @@ Collaboration diagram for TIM Tools\+:\nopagebreak \end{DoxyNote} -\end{DoxyItemize}\input{group___m_y_l_i_b_s___t_i_m___o_c} -\input{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r} +\end{DoxyItemize}\input{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l} \input{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y} -\input{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l} +\input{group___m_y_l_i_b_s___t_i_m___o_c} +\input{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r} diff --git a/Doc/latex/group___m_y_l_i_b_s___a_l_l.tex b/Doc/latex/group___m_y_l_i_b_s___a_l_l.tex index 6be6234..cd0caf7 100644 --- a/Doc/latex/group___m_y_l_i_b_s___a_l_l.tex +++ b/Doc/latex/group___m_y_l_i_b_s___a_l_l.tex @@ -1,4 +1,4 @@ -\doxysection{My Libs} +\doxysection{My Libs } \hypertarget{group___m_y_l_i_b_s___a_l_l}{}\label{group___m_y_l_i_b_s___a_l_l}\index{My Libs@{My Libs}} diff --git a/Doc/latex/group___m_y_l_i_b_s___c_o_n_f_i_g.tex b/Doc/latex/group___m_y_l_i_b_s___c_o_n_f_i_g.tex index 1ccb529..94de885 100644 --- a/Doc/latex/group___m_y_l_i_b_s___c_o_n_f_i_g.tex +++ b/Doc/latex/group___m_y_l_i_b_s___c_o_n_f_i_g.tex @@ -1,4 +1,4 @@ -\doxysubsection{Configs} +\doxysubsection{Configs } \hypertarget{group___m_y_l_i_b_s___c_o_n_f_i_g}{}\label{group___m_y_l_i_b_s___c_o_n_f_i_g}\index{Configs@{Configs}} diff --git a/Doc/latex/group___m_y_l_i_b_s___d_e_f_i_n_e_s.tex b/Doc/latex/group___m_y_l_i_b_s___d_e_f_i_n_e_s.tex index a144e29..2216629 100644 --- a/Doc/latex/group___m_y_l_i_b_s___d_e_f_i_n_e_s.tex +++ b/Doc/latex/group___m_y_l_i_b_s___d_e_f_i_n_e_s.tex @@ -1,4 +1,4 @@ -\doxysubsection{General Tools} +\doxysubsection{General Tools } \hypertarget{group___m_y_l_i_b_s___d_e_f_i_n_e_s}{}\label{group___m_y_l_i_b_s___d_e_f_i_n_e_s}\index{General Tools@{General Tools}} diff --git a/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.tex b/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.tex index dfa5778..58d47fe 100644 --- a/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.tex +++ b/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{General tools} +\doxysubsubsubsection{General tools } \hypertarget{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l}{}\label{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l}\index{General tools@{General tools}} @@ -17,11 +17,6 @@ Collaboration diagram for General tools\+:\nopagebreak \item \mbox{\hyperlink{group___g_p_i_o___i_n_i_t}{Init defines}} \begin{DoxyCompactList}\small\item\em Настройка состояний кнопок и количества тиков в периоде ШИМ \end{DoxyCompactList}\end{DoxyCompactItemize} -\doxysubsubsubsubsubsection*{Macros} -\begin{DoxyCompactItemize} -\item -\#define \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga580b842096340b066c28b24d6b315be6}{GPIO\+\_\+\+TIM\+\_\+\+Alternate\+\_\+\+Mapping}}(INSTANCE) -\begin{DoxyCompactList}\small\item\em Маппинг альтернативной функции TIM между GPIO. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsubsubsubsection*{Functions} \begin{DoxyCompactItemize} \item @@ -32,40 +27,25 @@ HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_ \doxysubsubsubsubsection{Detailed Description} Общие функции/макросы для работы с GPIO. +\begin{DoxyParagraph}{Пример использования\+:} - -\doxysubsubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga580b842096340b066c28b24d6b315be6}\label{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga580b842096340b066c28b24d6b315be6} -\index{General tools@{General tools}!GPIO\_TIM\_Alternate\_Mapping@{GPIO\_TIM\_Alternate\_Mapping}} -\index{GPIO\_TIM\_Alternate\_Mapping@{GPIO\_TIM\_Alternate\_Mapping}!General tools@{General tools}} -\doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_TIM\_Alternate\_Mapping}{GPIO\_TIM\_Alternate\_Mapping}} -{\footnotesize\ttfamily \#define GPIO\+\_\+\+TIM\+\_\+\+Alternate\+\_\+\+Mapping(\begin{DoxyParamCaption}\item[{}]{INSTANCE }\end{DoxyParamCaption})} - -{\bfseries Value\+:} \begin{DoxyCode}{0} -\DoxyCodeLine{((((INSTANCE)\ ==\ TIM1)\ \ ||\ ((INSTANCE)\ ==\ TIM2))?\ GPIO\_AF1\_TIM1:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)} -\DoxyCodeLine{(((INSTANCE)\ ==\ TIM3)\ \ \ ||\ ((INSTANCE)\ ==\ TIM4)\ \ \ ||\ ((INSTANCE)\ ==\ TIM5))?\ GPIO\_AF2\_TIM3:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)} -\DoxyCodeLine{(((INSTANCE)\ ==\ TIM8)\ \ \ ||\ ((INSTANCE)\ ==\ TIM9)\ \ \ ||\ ((INSTANCE)\ ==\ TIM10)\ ||\ ((INSTANCE)\ ==\ TIM11))?\ GPIO\_AF3\_TIM8:\ \ \(\backslash\)} -\DoxyCodeLine{(((INSTANCE)\ ==\ TIM12)\ \ ||\ ((INSTANCE)\ ==\ TIM13)\ \ ||\ ((INSTANCE)\ ==\ TIM14))?\ GPIO\_AF9\_TIM12:\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)} -\DoxyCodeLine{(0))} +\DoxyCodeLine{\textcolor{comment}{//\ Включаем\ тактирование\ порта\ GPIOA}} +\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga962f010f783b81fcdd27eb6b53db28e6}{GPIO\_Clock\_Enable}}(GPIOA);} \end{DoxyCode} + +\end{DoxyParagraph} -Маппинг альтернативной функции TIM между GPIO. - - - -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00069}{69}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. - - - +\label{doc-func-members} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga962f010f783b81fcdd27eb6b53db28e6}\label{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga962f010f783b81fcdd27eb6b53db28e6} -\index{General tools@{General tools}!GPIO\_Clock\_Enable@{GPIO\_Clock\_Enable}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga962f010f783b81fcdd27eb6b53db28e6}\index{General tools@{General tools}!GPIO\_Clock\_Enable@{GPIO\_Clock\_Enable}} \index{GPIO\_Clock\_Enable@{GPIO\_Clock\_Enable}!General tools@{General tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_Clock\_Enable()}{GPIO\_Clock\_Enable()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+Clock\+\_\+\+Enable (\begin{DoxyParamCaption}\item[{GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}}]{GPIOx }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l_ga962f010f783b81fcdd27eb6b53db28e6} +HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+Clock\+\_\+\+Enable (\begin{DoxyParamCaption}\item[{GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}}]{GPIOx}{}\end{DoxyParamCaption})} diff --git a/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.tex b/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.tex index 78a19ef..56f72a6 100644 --- a/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.tex +++ b/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___l_e_d_s.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{LED tools} +\doxysubsubsubsection{LED tools } \hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s}{}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s}\index{LED tools@{LED tools}} @@ -48,20 +48,45 @@ void \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d \doxysubsubsubsubsection{Detailed Description} Функции для работы с GPIO, для управления светодиодом +\begin{DoxyParagraph}{Пример использования\+:} + +\begin{DoxyCode}{0} +\DoxyCodeLine{MX\_GPIO\_Init();\ \textcolor{comment}{//\ инициализация\ пина\ аппаратная}} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ Инициализация\ светодиода\ на\ порте\ GPIOA,\ пин\ 5,\ активный\ уровень\ 0}} +\DoxyCodeLine{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ led;} +\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gac936453c7a0841c0b17bcfdae4958084}{GPIO\_LED\_Init}}(\&led,\ GPIOA,\ GPIO\_PIN\_5,\ 0);\ \textcolor{comment}{//\ или\ дефайн\ LED\_ON/LED\_OFF}} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ Включение\ светодиода}} +\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ga4b9572949326b050694cd55d0a7e5f6c}{GPIO\_LED\_On}}(\&led);} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ Запуск\ моргания}} +\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaf22f44ecaf6a1932b47edc5a845b03a9}{GPIO\_LED\_Blink\_Start}}(\&led,\ 500);\ \textcolor{comment}{//\ Период\ 500\ мс}} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ В\ основном\ цикле}} +\DoxyCodeLine{\textcolor{keywordflow}{while}\ (1)\ \{} +\DoxyCodeLine{\ \ \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d472b6340c7f19bb2}{GPIO\_LED\_Dynamic\_Handle}}(\&led);} +\DoxyCodeLine{\}} + +\end{DoxyCode} + +\end{DoxyParagraph} +\label{doc-enum-members} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_doc-enum-members} \doxysubsubsubsubsection{Enumeration Type Documentation} -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1} -\index{LED tools@{LED tools}!GPIO\_LEDStateTypeDef@{GPIO\_LEDStateTypeDef}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}\index{LED tools@{LED tools}!GPIO\_LEDStateTypeDef@{GPIO\_LEDStateTypeDef}} \index{GPIO\_LEDStateTypeDef@{GPIO\_LEDStateTypeDef}!LED tools@{LED tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_LEDStateTypeDef}{GPIO\_LEDStateTypeDef}} -{\footnotesize\ttfamily enum \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{GPIO\+\_\+\+LEDState\+Type\+Def}}} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1} +enum \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{GPIO\+\_\+\+LEDState\+Type\+Def}}} Режимы работы светодиода -\begin{DoxyEnumFields}{Enumerator} +\begin{DoxyEnumFields}[2]{Enumerator} \raisebox{\heightof{T}}[0pt][0pt]{\index{LED\_IS\_OFF@{LED\_IS\_OFF}!LED tools@{LED tools}}\index{LED tools@{LED tools}!LED\_IS\_OFF@{LED\_IS\_OFF}}}\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a74276cd2464314e422e8a144483f74ae}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ggaac2b90d8b8c9579b6aa5d3bbda9b1ff1a74276cd2464314e422e8a144483f74ae} LED\+\_\+\+IS\+\_\+\+OFF&Светодиод выключен \\ \hline @@ -81,16 +106,18 @@ LED\+\_\+\+IS\+\_\+\+FADING&Плавное моргание светодиодо \end{DoxyEnumFields} -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00081}{81}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00061}{61}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +\label{doc-func-members} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gac936453c7a0841c0b17bcfdae4958084}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gac936453c7a0841c0b17bcfdae4958084} -\index{LED tools@{LED tools}!GPIO\_LED\_Init@{GPIO\_LED\_Init}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gac936453c7a0841c0b17bcfdae4958084}\index{LED tools@{LED tools}!GPIO\_LED\_Init@{GPIO\_LED\_Init}} \index{GPIO\_LED\_Init@{GPIO\_LED\_Init}!LED tools@{LED tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_LED\_Init()}{GPIO\_LED\_Init()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led, }\item[{GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}}]{GPIOx, }\item[{uint32\+\_\+t}]{GPIO\+\_\+\+PIN\+\_\+X, }\item[{uint8\+\_\+t}]{LED\+\_\+\+Active\+Level }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gac936453c7a0841c0b17bcfdae4958084} +HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led}{, }\item[{GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}}]{GPIOx}{, }\item[{uint32\+\_\+t}]{GPIO\+\_\+\+PIN\+\_\+X}{, }\item[{uint8\+\_\+t}]{LED\+\_\+\+Active\+Level}{}\end{DoxyParamCaption})} @@ -111,11 +138,11 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00081}{81}} of file Definition at line \mbox{\hyperlink{general__gpio_8c_source_l00073}{73}} of file \mbox{\hyperlink{general__gpio_8c_source}{general\+\_\+gpio.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ga4b9572949326b050694cd55d0a7e5f6c}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ga4b9572949326b050694cd55d0a7e5f6c} -\index{LED tools@{LED tools}!GPIO\_LED\_On@{GPIO\_LED\_On}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ga4b9572949326b050694cd55d0a7e5f6c}\index{LED tools@{LED tools}!GPIO\_LED\_On@{GPIO\_LED\_On}} \index{GPIO\_LED\_On@{GPIO\_LED\_On}!LED tools@{LED tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_LED\_On()}{GPIO\_LED\_On()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+On (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ga4b9572949326b050694cd55d0a7e5f6c} +HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+On (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led}{}\end{DoxyParamCaption})} @@ -133,11 +160,11 @@ HAL Status Definition at line \mbox{\hyperlink{general__gpio_8c_source_l00091}{91}} of file \mbox{\hyperlink{general__gpio_8c_source}{general\+\_\+gpio.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaadda2d4f021390a4e392210a5ace5357}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaadda2d4f021390a4e392210a5ace5357} -\index{LED tools@{LED tools}!GPIO\_LED\_Off@{GPIO\_LED\_Off}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaadda2d4f021390a4e392210a5ace5357}\index{LED tools@{LED tools}!GPIO\_LED\_Off@{GPIO\_LED\_Off}} \index{GPIO\_LED\_Off@{GPIO\_LED\_Off}!LED tools@{LED tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_LED\_Off()}{GPIO\_LED\_Off()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Off (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaadda2d4f021390a4e392210a5ace5357} +HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Off (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led}{}\end{DoxyParamCaption})} @@ -155,11 +182,11 @@ HAL Status Definition at line \mbox{\hyperlink{general__gpio_8c_source_l00107}{107}} of file \mbox{\hyperlink{general__gpio_8c_source}{general\+\_\+gpio.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gae78b570447d55a462a679a89dbaa8ea2}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gae78b570447d55a462a679a89dbaa8ea2} -\index{LED tools@{LED tools}!GPIO\_LED\_Set@{GPIO\_LED\_Set}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gae78b570447d55a462a679a89dbaa8ea2}\index{LED tools@{LED tools}!GPIO\_LED\_Set@{GPIO\_LED\_Set}} \index{GPIO\_LED\_Set@{GPIO\_LED\_Set}!LED tools@{LED tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_LED\_Set()}{GPIO\_LED\_Set()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Set (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led, }\item[{uint8\+\_\+t}]{led\+\_\+state }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gae78b570447d55a462a679a89dbaa8ea2} +HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Set (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led}{, }\item[{uint8\+\_\+t}]{led\+\_\+state}{}\end{DoxyParamCaption})} @@ -179,11 +206,11 @@ HAL Status Definition at line \mbox{\hyperlink{general__gpio_8c_source_l00125}{125}} of file \mbox{\hyperlink{general__gpio_8c_source}{general\+\_\+gpio.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaf22f44ecaf6a1932b47edc5a845b03a9}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaf22f44ecaf6a1932b47edc5a845b03a9} -\index{LED tools@{LED tools}!GPIO\_LED\_Blink\_Start@{GPIO\_LED\_Blink\_Start}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaf22f44ecaf6a1932b47edc5a845b03a9}\index{LED tools@{LED tools}!GPIO\_LED\_Blink\_Start@{GPIO\_LED\_Blink\_Start}} \index{GPIO\_LED\_Blink\_Start@{GPIO\_LED\_Blink\_Start}!LED tools@{LED tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_LED\_Blink\_Start()}{GPIO\_LED\_Blink\_Start()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Blink\+\_\+\+Start (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led, }\item[{uint32\+\_\+t}]{period }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaf22f44ecaf6a1932b47edc5a845b03a9} +HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Blink\+\_\+\+Start (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led}{, }\item[{uint32\+\_\+t}]{period}{}\end{DoxyParamCaption})} @@ -203,11 +230,11 @@ HAL Status Definition at line \mbox{\hyperlink{general__gpio_8c_source_l00146}{146}} of file \mbox{\hyperlink{general__gpio_8c_source}{general\+\_\+gpio.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaa00f20021781464af3dfe74aa3e59a0a}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaa00f20021781464af3dfe74aa3e59a0a} -\index{LED tools@{LED tools}!GPIO\_LED\_Fading\_Start@{GPIO\_LED\_Fading\_Start}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaa00f20021781464af3dfe74aa3e59a0a}\index{LED tools@{LED tools}!GPIO\_LED\_Fading\_Start@{GPIO\_LED\_Fading\_Start}} \index{GPIO\_LED\_Fading\_Start@{GPIO\_LED\_Fading\_Start}!LED tools@{LED tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_LED\_Fading\_Start()}{GPIO\_LED\_Fading\_Start()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Fading\+\_\+\+Start (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led, }\item[{uint32\+\_\+t}]{period }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaa00f20021781464af3dfe74aa3e59a0a} +HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+LED\+\_\+\+Fading\+\_\+\+Start (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led}{, }\item[{uint32\+\_\+t}]{period}{}\end{DoxyParamCaption})} @@ -227,11 +254,11 @@ HAL Status Definition at line \mbox{\hyperlink{general__gpio_8c_source_l00164}{164}} of file \mbox{\hyperlink{general__gpio_8c_source}{general\+\_\+gpio.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d472b6340c7f19bb2}\label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d472b6340c7f19bb2} -\index{LED tools@{LED tools}!GPIO\_LED\_Dynamic\_Handle@{GPIO\_LED\_Dynamic\_Handle}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d472b6340c7f19bb2}\index{LED tools@{LED tools}!GPIO\_LED\_Dynamic\_Handle@{GPIO\_LED\_Dynamic\_Handle}} \index{GPIO\_LED\_Dynamic\_Handle@{GPIO\_LED\_Dynamic\_Handle}!LED tools@{LED tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_LED\_Dynamic\_Handle()}{GPIO\_LED\_Dynamic\_Handle()}} -{\footnotesize\ttfamily void GPIO\+\_\+\+LED\+\_\+\+Dynamic\+\_\+\+Handle (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d472b6340c7f19bb2} +void GPIO\+\_\+\+LED\+\_\+\+Dynamic\+\_\+\+Handle (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\+\_\+\+LEDType\+Def}} \texorpdfstring{$\ast$}{*}}]{led}{}\end{DoxyParamCaption})} diff --git a/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.tex b/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.tex index 52e0bdf..29fe4c9 100644 --- a/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.tex +++ b/Doc/latex/group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{Switch tools} +\doxysubsubsubsection{Switch tools } \hypertarget{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h}{}\label{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h}\index{Switch tools@{Switch tools}} @@ -29,14 +29,40 @@ int \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_ga960b24335b202 \doxysubsubsubsubsection{Detailed Description} Функции для работы с GPIO, как с кнопкой +\begin{DoxyParagraph}{Пример использования\+:} + +\begin{DoxyCode}{0} +\DoxyCodeLine{MX\_GPIO\_Init();\ \textcolor{comment}{//\ инициализация\ пина\ аппаратная}} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ Инициализация\ кнопки\ на\ порте\ GPIOB,\ пин\ 0,\ активный\ уровень\ 1}} +\DoxyCodeLine{\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\_SwitchTypeDef}}\ sw1;} +\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_gacafee0e68877f2b25df843356871d1f7}{GPIO\_Switch\_Init}}(\&sw1,\ GPIOB,\ GPIO\_PIN\_0,\ 1);\ \textcolor{comment}{//\ или\ дефайн\ SW\_ON/SW\_OFF}} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ Считываем\ состояние\ кнопки}} +\DoxyCodeLine{\textcolor{keywordflow}{if}(\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_ga960b24335b2026abcad126ab8c422d70}{GPIO\_Read\_Switch}}(\&sw1))} +\DoxyCodeLine{\{} +\DoxyCodeLine{\ \ \ \ \textcolor{comment}{//\ Кнопка\ нажата}} +\DoxyCodeLine{\ \ \ \ \mbox{\hyperlink{group___g_p_i_o___i_n_i_t_gaf2e697ac60e05813d45ea2c9c9e79c25}{LED\_ON}}();} +\DoxyCodeLine{\}} +\DoxyCodeLine{\textcolor{keywordflow}{else}} +\DoxyCodeLine{\{} +\DoxyCodeLine{\ \ \ \ \textcolor{comment}{//\ Кнопка\ отжата}} +\DoxyCodeLine{\ \ \ \ \mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga80700bb63bd56ebabbb4728aa433fd29}{LED\_OFF}}();} +\DoxyCodeLine{\}} + +\end{DoxyCode} + +\end{DoxyParagraph} +\label{doc-func-members} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_gacafee0e68877f2b25df843356871d1f7}\label{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_gacafee0e68877f2b25df843356871d1f7} -\index{Switch tools@{Switch tools}!GPIO\_Switch\_Init@{GPIO\_Switch\_Init}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_gacafee0e68877f2b25df843356871d1f7}\index{Switch tools@{Switch tools}!GPIO\_Switch\_Init@{GPIO\_Switch\_Init}} \index{GPIO\_Switch\_Init@{GPIO\_Switch\_Init}!Switch tools@{Switch tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_Switch\_Init()}{GPIO\_Switch\_Init()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+Switch\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\+\_\+\+Switch\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{sw, }\item[{GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}}]{GPIOx, }\item[{uint32\+\_\+t}]{GPIO\+\_\+\+PIN\+\_\+X, }\item[{uint8\+\_\+t}]{SW\+\_\+\+Active\+Level }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_gacafee0e68877f2b25df843356871d1f7} +HAL\+\_\+\+Status\+Type\+Def GPIO\+\_\+\+Switch\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\+\_\+\+Switch\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{sw}{, }\item[{GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}}]{GPIOx}{, }\item[{uint32\+\_\+t}]{GPIO\+\_\+\+PIN\+\_\+X}{, }\item[{uint8\+\_\+t}]{SW\+\_\+\+Active\+Level}{}\end{DoxyParamCaption})} @@ -60,11 +86,11 @@ HAL Status Definition at line \mbox{\hyperlink{general__gpio_8c_source_l00258}{258}} of file \mbox{\hyperlink{general__gpio_8c_source}{general\+\_\+gpio.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_ga960b24335b2026abcad126ab8c422d70}\label{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_ga960b24335b2026abcad126ab8c422d70} -\index{Switch tools@{Switch tools}!GPIO\_Read\_Switch@{GPIO\_Read\_Switch}} +\Hypertarget{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_ga960b24335b2026abcad126ab8c422d70}\index{Switch tools@{Switch tools}!GPIO\_Read\_Switch@{GPIO\_Read\_Switch}} \index{GPIO\_Read\_Switch@{GPIO\_Read\_Switch}!Switch tools@{Switch tools}} \doxysubsubsubsubsubsection{\texorpdfstring{GPIO\_Read\_Switch()}{GPIO\_Read\_Switch()}} -{\footnotesize\ttfamily int GPIO\+\_\+\+Read\+\_\+\+Switch (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\+\_\+\+Switch\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{sw }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h_ga960b24335b2026abcad126ab8c422d70} +int GPIO\+\_\+\+Read\+\_\+\+Switch (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\+\_\+\+Switch\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{sw}{}\end{DoxyParamCaption})} diff --git a/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.md5 b/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.md5 index ee8c449..2e10e09 100644 --- a/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.md5 +++ b/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.md5 @@ -1 +1 @@ -9a24bce9b60d282ebbaf04d75a3cfad4 \ No newline at end of file +1044283365b108883d0b7a448ff91792 \ No newline at end of file diff --git a/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.pdf b/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.pdf index 8eff0ac..cf8790b 100644 Binary files a/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.pdf and b/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.pdf differ diff --git a/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.tex b/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.tex index 34a3794..f146bd7 100644 --- a/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.tex +++ b/Doc/latex/group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l.tex @@ -1,15 +1,16 @@ -\doxysubsection{Peripheral} +\doxysubsection{Peripheral } \hypertarget{group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l}{}\label{group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l}\index{Peripheral@{Peripheral}} Модули для управления периферией -Collaboration diagram for Peripheral\+:\nopagebreak +Collaboration diagram for Peripheral\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=328pt]{group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l} +\includegraphics[width=331pt]{group___m_y_l_i_b_s___p_e_r_i_p_h_e_r_a_l} \end{center} \end{figure} \doxysubsubsubsection*{Topics} @@ -17,12 +18,18 @@ Collaboration diagram for Peripheral\+:\nopagebreak \item \mbox{\hyperlink{group___m_y___l_i_b_s___g_p_i_o}{GPIO Tools}} \begin{DoxyCompactList}\small\item\em Функции и макросы для удобной работы с GPIO. \end{DoxyCompactList}\item +\mbox{\hyperlink{group___m_y___l_i_b_s___s_p_i}{SPI Tools}} +\begin{DoxyCompactList}\small\item\em Функции и макросы для удобной работы с SPI. \end{DoxyCompactList}\item \mbox{\hyperlink{group___m_y___l_i_b_s___t_i_m}{TIM Tools}} -\begin{DoxyCompactList}\small\item\em Функции и макросы для удобной работы с TIM. \end{DoxyCompactList}\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Функции и макросы для удобной работы с TIM. \end{DoxyCompactList}\item +\mbox{\hyperlink{group___m_y___l_i_b_s___u_a_r_t}{UART Tools}} +\begin{DoxyCompactList}\small\item\em Функции и макросы для удобной работы с UART. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsection{Detailed Description} Модули для управления периферией \input{group___m_y___l_i_b_s___g_p_i_o} +\input{group___m_y___l_i_b_s___s_p_i} \input{group___m_y___l_i_b_s___t_i_m} +\input{group___m_y___l_i_b_s___u_a_r_t} diff --git a/Doc/latex/group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.tex b/Doc/latex/group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.tex index 36b886e..e3c4d71 100644 --- a/Doc/latex/group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.tex +++ b/Doc/latex/group___m_y_l_i_b_s___t_i_m___d_e_l_a_y.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{Delay tools} +\doxysubsubsubsection{Delay tools } \hypertarget{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y}{}\label{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y}\index{Delay tools@{Delay tools}} @@ -26,14 +26,40 @@ HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_ \doxysubsubsubsubsection{Detailed Description} Функции для формирования задержек с помощью таймеров +\begin{DoxyParagraph}{Пример использования\+:} + +\begin{DoxyCode}{0} +\DoxyCodeLine{TIM\_HandleTypeDef\ htim2;} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ блокирующая\ задержка\ 500\ тиков\ таймера}} +\DoxyCodeLine{\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_gaf2e697ac60e05813d45ea2c9c9e79c25}{LED\_ON}}();} +\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e}{TIM\_Delay}}(\&htim2,\ 500);} +\DoxyCodeLine{\mbox{\hyperlink{group___g_p_i_o___i_n_i_t_ga80700bb63bd56ebabbb4728aa433fd29}{LED\_OFF}}();} +\DoxyCodeLine{} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{keywordflow}{while}(1)} +\DoxyCodeLine{\{} +\DoxyCodeLine{\ \ \textcolor{comment}{//\ не\ блокирующая\ задержка\ 200\ тиков\ таймера}} +\DoxyCodeLine{\ \ \textcolor{keywordflow}{if}(\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b}{TIM\_Delay\_NonBlocking}}(\&htim2,\ 200)\ ==\ HAL\_OK)} +\DoxyCodeLine{\ \ \{} +\DoxyCodeLine{\ \ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834}{TIM\_Delay\_Start}}(\&htim2);} +\DoxyCodeLine{\ \ \ \ LED\_TOOGLE();} +\DoxyCodeLine{\ \ \}} +\DoxyCodeLine{\}} + +\end{DoxyCode} + +\end{DoxyParagraph} +\label{doc-func-members} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834}\label{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834} -\index{Delay tools@{Delay tools}!TIM\_Delay\_Start@{TIM\_Delay\_Start}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834}\index{Delay tools@{Delay tools}!TIM\_Delay\_Start@{TIM\_Delay\_Start}} \index{TIM\_Delay\_Start@{TIM\_Delay\_Start}!Delay tools@{Delay tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Delay\_Start()}{TIM\_Delay\_Start()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Delay\+\_\+\+Start (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga4c0dfde4e15f677600605348b4e97834} +HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Delay\+\_\+\+Start (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim}{}\end{DoxyParamCaption})} @@ -51,11 +77,11 @@ HAL status. Definition at line \mbox{\hyperlink{general__tim_8c_source_l00363}{363}} of file \mbox{\hyperlink{general__tim_8c_source}{general\+\_\+tim.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e}\label{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e} -\index{Delay tools@{Delay tools}!TIM\_Delay@{TIM\_Delay}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e}\index{Delay tools@{Delay tools}!TIM\_Delay@{TIM\_Delay}} \index{TIM\_Delay@{TIM\_Delay}!Delay tools@{Delay tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Delay()}{TIM\_Delay()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Delay (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim, }\item[{uint16\+\_\+t}]{delay }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga88c552a133cb6e3015453cccab74c07e} +HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Delay (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim}{, }\item[{uint16\+\_\+t}]{delay}{}\end{DoxyParamCaption})} @@ -75,11 +101,11 @@ HAL status. Definition at line \mbox{\hyperlink{general__tim_8c_source_l00337}{337}} of file \mbox{\hyperlink{general__tim_8c_source}{general\+\_\+tim.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b}\label{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b} -\index{Delay tools@{Delay tools}!TIM\_Delay\_NonBlocking@{TIM\_Delay\_NonBlocking}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b}\index{Delay tools@{Delay tools}!TIM\_Delay\_NonBlocking@{TIM\_Delay\_NonBlocking}} \index{TIM\_Delay\_NonBlocking@{TIM\_Delay\_NonBlocking}!Delay tools@{Delay tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Delay\_NonBlocking()}{TIM\_Delay\_NonBlocking()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Delay\+\_\+\+Non\+Blocking (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim, }\item[{uint16\+\_\+t}]{delay }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y_ga108637af414bff3373059273b815ce9b} +HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Delay\+\_\+\+Non\+Blocking (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim}{, }\item[{uint16\+\_\+t}]{delay}{}\end{DoxyParamCaption})} diff --git a/Doc/latex/group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.tex b/Doc/latex/group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.tex index 8654cc5..8ae68bd 100644 --- a/Doc/latex/group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.tex +++ b/Doc/latex/group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{Encoder tools} +\doxysubsubsubsection{Encoder tools } \hypertarget{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r}{}\label{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r}\index{Encoder tools@{Encoder tools}} @@ -31,14 +31,40 @@ int \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e \doxysubsubsubsubsection{Detailed Description} Функции для считывания энкодера +\begin{DoxyParagraph}{Пример использования\+:} + +\begin{DoxyCode}{0} +\DoxyCodeLine{\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\_EncoderTypeDef}}\ henc1;} +\DoxyCodeLine{TIM\_HandleTypeDef\ htim4;} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ инициализация}} +\DoxyCodeLine{henc1.\mbox{\hyperlink{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}{htim}}\ =\ \&htim4;} +\DoxyCodeLine{henc1.\mbox{\hyperlink{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9}{GPIOx}}\ =\ GPIOA;} +\DoxyCodeLine{henc1.\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e}{GPIO\_PIN\_TI1}}\ =\ GPIO\_PIN\_0;} +\DoxyCodeLine{henc1.\mbox{\hyperlink{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5}{GPIO\_PIN\_TI2}}\ =\ GPIO\_PIN\_1;} +\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc}{TIM\_Encoder\_Init}}(\&henc1,\ \&htim4);} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{comment}{//\ считывание\ энкодера\ и\ кнопки}} +\DoxyCodeLine{int16\_t\ delta\ =\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_gac3bc6525f88c275e47eb864e6d567501}{TIM\_Encoder\_Read}}(\&henc1);} +\DoxyCodeLine{setpoint\_tmp\ +=\ delta;} +\DoxyCodeLine{\textcolor{keywordflow}{if}(\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e3a357ddefe323412761}{TIM\_Encoder\_ReadSwitch}}(\&henc1))} +\DoxyCodeLine{\{} +\DoxyCodeLine{\ \ setpoint\ =\ setpoint\_tmp;\ \textcolor{comment}{//\ подтвердить\ новое\ значение}} +\DoxyCodeLine{\}} + +\end{DoxyCode} + +\end{DoxyParagraph} +\label{doc-func-members} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc}\label{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc} -\index{Encoder tools@{Encoder tools}!TIM\_Encoder\_Init@{TIM\_Encoder\_Init}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc}\index{Encoder tools@{Encoder tools}!TIM\_Encoder\_Init@{TIM\_Encoder\_Init}} \index{TIM\_Encoder\_Init@{TIM\_Encoder\_Init}!Encoder tools@{Encoder tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Encoder\_Init()}{TIM\_Encoder\_Init()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Encoder\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{henc, }\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga8d16c3b7e7c6decc54c5c3d1a8bf0fbc} +HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Encoder\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{henc}{, }\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim}{}\end{DoxyParamCaption})} @@ -61,11 +87,11 @@ HAL status. Definition at line \mbox{\hyperlink{general__tim_8c_source_l00168}{168}} of file \mbox{\hyperlink{general__tim_8c_source}{general\+\_\+tim.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_gac3bc6525f88c275e47eb864e6d567501}\label{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_gac3bc6525f88c275e47eb864e6d567501} -\index{Encoder tools@{Encoder tools}!TIM\_Encoder\_Read@{TIM\_Encoder\_Read}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_gac3bc6525f88c275e47eb864e6d567501}\index{Encoder tools@{Encoder tools}!TIM\_Encoder\_Read@{TIM\_Encoder\_Read}} \index{TIM\_Encoder\_Read@{TIM\_Encoder\_Read}!Encoder tools@{Encoder tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Encoder\_Read()}{TIM\_Encoder\_Read()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Encoder\+\_\+\+Read (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{henc }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_gac3bc6525f88c275e47eb864e6d567501} +HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Encoder\+\_\+\+Read (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{henc}{}\end{DoxyParamCaption})} @@ -83,11 +109,11 @@ HAL status. Definition at line \mbox{\hyperlink{general__tim_8c_source_l00303}{303}} of file \mbox{\hyperlink{general__tim_8c_source}{general\+\_\+tim.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e3a357ddefe323412761}\label{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e3a357ddefe323412761} -\index{Encoder tools@{Encoder tools}!TIM\_Encoder\_ReadSwitch@{TIM\_Encoder\_ReadSwitch}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e3a357ddefe323412761}\index{Encoder tools@{Encoder tools}!TIM\_Encoder\_ReadSwitch@{TIM\_Encoder\_ReadSwitch}} \index{TIM\_Encoder\_ReadSwitch@{TIM\_Encoder\_ReadSwitch}!Encoder tools@{Encoder tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Encoder\_ReadSwitch()}{TIM\_Encoder\_ReadSwitch()}} -{\footnotesize\ttfamily int TIM\+\_\+\+Encoder\+\_\+\+Read\+Switch (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{henc }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r_ga117b795017e9e3a357ddefe323412761} +int TIM\+\_\+\+Encoder\+\_\+\+Read\+Switch (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_t_i_m___encoder_type_def}{TIM\+\_\+\+Encoder\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{henc}{}\end{DoxyParamCaption})} diff --git a/Doc/latex/group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.tex b/Doc/latex/group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.tex index 345eb21..e615c4a 100644 --- a/Doc/latex/group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.tex +++ b/Doc/latex/group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{General tools} +\doxysubsubsubsection{General tools } \hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l}{}\label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l}\index{General tools@{General tools}} @@ -54,20 +54,46 @@ void \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c \doxysubsubsubsubsection{Detailed Description} Функции для базовой инициализации таймеров +\begin{DoxyParagraph}{Пример использования\+:} + +\begin{DoxyCode}{0} +\DoxyCodeLine{\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\_SettingsTypeDef}}\ tim2Settings;} +\DoxyCodeLine{} +\DoxyCodeLine{\textcolor{keywordtype}{void}\ TIM2\_Init(\textcolor{keywordtype}{void})} +\DoxyCodeLine{\{} +\DoxyCodeLine{\ \ \ \ \textcolor{comment}{//\ Настройка\ таймера\ TIM2\ на\ 1\ кГц\ с\ прерываниями\ с\ шагом\ таймера\ 10\ мкс}} +\DoxyCodeLine{\ \ \ \ tim2Settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}{htim}}.Instance\ =\ TIM2;} +\DoxyCodeLine{\ \ \ \ tim2Settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}{sTimMode}}\ =\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787a89ecf1ef6d45ead2efcb7dd30396114c}{TIM\_IT\_MODE}};} +\DoxyCodeLine{\ \ \ \ tim2Settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}{sTickBaseUS}}\ =\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a060b01e890891fd17c8f95b55a94139f}{TIM\_TickBase\_10US}};} +\DoxyCodeLine{\ \ \ \ tim2Settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718}{sTickBasePrescaler}}\ =\ 1;} +\DoxyCodeLine{\ \ \ \ tim2Settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4}{sTimFreqHz}}\ =\ 1000;\ \textcolor{comment}{//\ 1\ кГц}} +\DoxyCodeLine{\ \ \ \ tim2Settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}{sTimAHBFreqMHz}}\ =\ 72000000;\ \textcolor{comment}{//\ Hz}} +\DoxyCodeLine{} +\DoxyCodeLine{\ \ \ \ \textcolor{keywordflow}{if}(\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec}{TIM\_Base\_Init}}(\&tim2Settings)\ !=\ HAL\_OK)} +\DoxyCodeLine{\ \ \ \ \{} +\DoxyCodeLine{\ \ \ \ \ \ \ \ Error\_Handler();} +\DoxyCodeLine{\ \ \ \ \}} +\DoxyCodeLine{\}} + +\end{DoxyCode} + +\end{DoxyParagraph} +\label{doc-enum-members} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_doc-enum-members} \doxysubsubsubsubsection{Enumeration Type Documentation} -\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}\label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787} -\index{General tools@{General tools}!TIM\_ITModeTypeDef@{TIM\_ITModeTypeDef}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}\index{General tools@{General tools}!TIM\_ITModeTypeDef@{TIM\_ITModeTypeDef}} \index{TIM\_ITModeTypeDef@{TIM\_ITModeTypeDef}!General tools@{General tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_ITModeTypeDef}{TIM\_ITModeTypeDef}} -{\footnotesize\ttfamily enum \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}}} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787} +enum \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}}} Режим прерываний таймера -\begin{DoxyEnumFields}{Enumerator} +\begin{DoxyEnumFields}[2]{Enumerator} \raisebox{\heightof{T}}[0pt][0pt]{\index{TIM\_DEFAULT@{TIM\_DEFAULT}!General tools@{General tools}}\index{General tools@{General tools}!TIM\_DEFAULT@{TIM\_DEFAULT}}}\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787ab0869828a4dfd62eaa44868ca27835f8}\label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaeb611874216a4661fb83366b99b9e787ab0869828a4dfd62eaa44868ca27835f8} TIM\+\_\+\+DEFAULT&Прерываний отключены \\ \hline @@ -79,19 +105,19 @@ TIM\+\_\+\+IT\+\_\+\+MODE&Прерываний включены \\ \end{DoxyEnumFields} -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00076}{76}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00077}{77}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}\label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800} -\index{General tools@{General tools}!TIM\_MHzTickBaseTypeDef@{TIM\_MHzTickBaseTypeDef}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}\index{General tools@{General tools}!TIM\_MHzTickBaseTypeDef@{TIM\_MHzTickBaseTypeDef}} \index{TIM\_MHzTickBaseTypeDef@{TIM\_MHzTickBaseTypeDef}!General tools@{General tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_MHzTickBaseTypeDef}{TIM\_MHzTickBaseTypeDef}} -{\footnotesize\ttfamily enum \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\+\_\+\+MHz\+Tick\+Base\+Type\+Def}}} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800} +enum \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\+\_\+\+MHz\+Tick\+Base\+Type\+Def}}} Длительность тика таймера (частота тактирования таймера) -enum дает базовые длительности, но можно выставить другие (напр 500 -\/ 0.\+5 мс) \begin{DoxyEnumFields}{Enumerator} +enum дает базовые длительности, но можно выставить другие (напр 500 -\/ 0.\+5 мс) \begin{DoxyEnumFields}[2]{Enumerator} \raisebox{\heightof{T}}[0pt][0pt]{\index{TIM\_Base\_Disable@{TIM\_Base\_Disable}!General tools@{General tools}}\index{General tools@{General tools}!TIM\_Base\_Disable@{TIM\_Base\_Disable}}}\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800ae838122c0e83bc57ad31b546bf2f00e5}\label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800ae838122c0e83bc57ad31b546bf2f00e5} TIM\+\_\+\+Base\+\_\+\+Disable&Таймер отключен \\ \hline @@ -123,16 +149,18 @@ TIM\+\_\+\+Tick\+Base\+\_\+100\+MS&Таймер тактируется с час \end{DoxyEnumFields} -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00090}{90}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00091}{91}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +\label{doc-func-members} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec}\label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec} -\index{General tools@{General tools}!TIM\_Base\_Init@{TIM\_Base\_Init}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec}\index{General tools@{General tools}!TIM\_Base\_Init@{TIM\_Base\_Init}} \index{TIM\_Base\_Init@{TIM\_Base\_Init}!General tools@{General tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Base\_Init()}{TIM\_Base\_Init()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Base\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\+\_\+\+Settings\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{stim }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec} +HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Base\+\_\+\+Init (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\+\_\+\+Settings\+Type\+Def}} \texorpdfstring{$\ast$}{*}}]{stim}{}\end{DoxyParamCaption})} @@ -162,11 +190,11 @@ HAL status. Definition at line \mbox{\hyperlink{general__tim_8c_source_l00034}{34}} of file \mbox{\hyperlink{general__tim_8c_source}{general\+\_\+tim.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931}\label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931} -\index{General tools@{General tools}!TIM\_Base\_MspInit@{TIM\_Base\_MspInit}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931}\index{General tools@{General tools}!TIM\_Base\_MspInit@{TIM\_Base\_MspInit}} \index{TIM\_Base\_MspInit@{TIM\_Base\_MspInit}!General tools@{General tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Base\_MspInit()}{TIM\_Base\_MspInit()}} -{\footnotesize\ttfamily void TIM\+\_\+\+Base\+\_\+\+Msp\+Init (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim, }\item[{\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}}}]{it\+\_\+mode }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaad47337be7ba2f6c0777c40d7278c931} +void TIM\+\_\+\+Base\+\_\+\+Msp\+Init (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim}{, }\item[{\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}}}]{it\+\_\+mode}{}\end{DoxyParamCaption})} @@ -178,17 +206,17 @@ Definition at line \mbox{\hyperlink{general__tim_8c_source_l00034}{34}} of file \hline \end{DoxyParams} \begin{DoxyNote}{Note} -Чтобы не генерировать функцию с иницилизацией неиспользуемых таймеров, дефайнами в \doxylink{general__tim_8h}{general\+\_\+tim.\+h} определяются используемые таймеры. +Чтобы не генерировать функцию с иницилизацией неиспользуемых таймеров, дефайнами \doxylink{group___t_i_m___i_n_i_t}{Init defines} в \doxylink{general__tim_8h}{general\+\_\+tim.\+h} определяются используемые таймеры. \end{DoxyNote} Definition at line \mbox{\hyperlink{general__tim_8c_source_l00408}{408}} of file \mbox{\hyperlink{general__tim_8c_source}{general\+\_\+tim.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115}\label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115} -\index{General tools@{General tools}!TIM\_Base\_MspDeInit@{TIM\_Base\_MspDeInit}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115}\index{General tools@{General tools}!TIM\_Base\_MspDeInit@{TIM\_Base\_MspDeInit}} \index{TIM\_Base\_MspDeInit@{TIM\_Base\_MspDeInit}!General tools@{General tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Base\_MspDeInit()}{TIM\_Base\_MspDeInit()}} -{\footnotesize\ttfamily void TIM\+\_\+\+Base\+\_\+\+Msp\+De\+Init (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga879e3f1c919c02990736730275367115} +void TIM\+\_\+\+Base\+\_\+\+Msp\+De\+Init (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim}{}\end{DoxyParamCaption})} @@ -200,7 +228,7 @@ Definition at line \mbox{\hyperlink{general__tim_8c_source_l00408}{408}} of file \hline \end{DoxyParams} \begin{DoxyNote}{Note} -Чтобы не генерировать функцию с деиницилизацией неиспользуемых таймеров, дефайнами в \doxylink{general__tim_8h}{general\+\_\+tim.\+h} определяются используемые таймеры. +Чтобы не генерировать функцию с деиницилизацией неиспользуемых таймеров, дефайнами \doxylink{group___t_i_m___i_n_i_t}{Init defines} в \doxylink{general__tim_8h}{general\+\_\+tim.\+h} определяются используемые таймеры. \end{DoxyNote} diff --git a/Doc/latex/group___m_y_l_i_b_s___t_i_m___o_c.tex b/Doc/latex/group___m_y_l_i_b_s___t_i_m___o_c.tex index b760e6e..8773efc 100644 --- a/Doc/latex/group___m_y_l_i_b_s___t_i_m___o_c.tex +++ b/Doc/latex/group___m_y_l_i_b_s___t_i_m___o_c.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{PWM/\+OC Channels tools} +\doxysubsubsubsection{PWM/\+OC Channels tools } \hypertarget{group___m_y_l_i_b_s___t_i_m___o_c}{}\label{group___m_y_l_i_b_s___t_i_m___o_c}\index{PWM/OC Channels tools@{PWM/OC Channels tools}} @@ -24,14 +24,36 @@ HAL\+\_\+\+Status\+Type\+Def \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_ \doxysubsubsubsubsection{Detailed Description} Функции для инициализации базовых функций каналов таймера +\begin{DoxyParagraph}{Пример использования\+:} + +\begin{DoxyCode}{0} +\DoxyCodeLine{\textcolor{keywordtype}{void}\ PWM\_Channel\_Init\_Example(\textcolor{keywordtype}{void})} +\DoxyCodeLine{\{} +\DoxyCodeLine{\ \ \ \ TIM\_HandleTypeDef\ htim3;} +\DoxyCodeLine{\ \ \ \ TIM\_OC\_InitTypeDef\ sConfigOC;} +\DoxyCodeLine{\ \ \ \ GPIO\_TypeDef\ *GPIOx\ =\ GPIOB;} +\DoxyCodeLine{\ \ \ \ uint32\_t\ PWM\_PIN\ =\ GPIO\_PIN\_0;} +\DoxyCodeLine{} +\DoxyCodeLine{\ \ \ \ \textcolor{comment}{//\ Настройка\ таймера\ и\ канала\ PWM}} +\DoxyCodeLine{\ \ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_gadb2f465d89f609e035867e980c3a29c6}{TIM\_Output\_PWM\_Init}}(\&htim3,\ \&sConfigOC,\ TIM\_CHANNEL\_1,\ GPIOx,\ PWM\_PIN);} +\DoxyCodeLine{} +\DoxyCodeLine{\ \ \ \ \textcolor{comment}{//\ Настройка\ компаратора\ OC}} +\DoxyCodeLine{\ \ \ \ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___o_c_gae2608ca8023e9a0713af0b4fbfbc1889}{TIM\_OC\_Comparator\_Init}}(\&htim3,\ TIM\_CHANNEL\_1);} +\DoxyCodeLine{\}} + +\end{DoxyCode} + +\end{DoxyParagraph} +\label{doc-func-members} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___o_c_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___m_y_l_i_b_s___t_i_m___o_c_gadb2f465d89f609e035867e980c3a29c6}\label{group___m_y_l_i_b_s___t_i_m___o_c_gadb2f465d89f609e035867e980c3a29c6} -\index{PWM/OC Channels tools@{PWM/OC Channels tools}!TIM\_Output\_PWM\_Init@{TIM\_Output\_PWM\_Init}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___o_c_gadb2f465d89f609e035867e980c3a29c6}\index{PWM/OC Channels tools@{PWM/OC Channels tools}!TIM\_Output\_PWM\_Init@{TIM\_Output\_PWM\_Init}} \index{TIM\_Output\_PWM\_Init@{TIM\_Output\_PWM\_Init}!PWM/OC Channels tools@{PWM/OC Channels tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_Output\_PWM\_Init()}{TIM\_Output\_PWM\_Init()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Output\+\_\+\+PWM\+\_\+\+Init (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim, }\item[{TIM\+\_\+\+OC\+\_\+\+Init\+Type\+Def \texorpdfstring{$\ast$}{*}}]{s\+Config\+OC, }\item[{uint32\+\_\+t}]{TIM\+\_\+\+CHANNEL, }\item[{GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}}]{GPIOx, }\item[{uint32\+\_\+t}]{GPIO\+\_\+\+PIN }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___o_c_gadb2f465d89f609e035867e980c3a29c6} +HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+Output\+\_\+\+PWM\+\_\+\+Init (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim}{, }\item[{TIM\+\_\+\+OC\+\_\+\+Init\+Type\+Def \texorpdfstring{$\ast$}{*}}]{s\+Config\+OC}{, }\item[{uint32\+\_\+t}]{TIM\+\_\+\+CHANNEL}{, }\item[{GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*}}]{GPIOx}{, }\item[{uint32\+\_\+t}]{GPIO\+\_\+\+PIN}{}\end{DoxyParamCaption})} @@ -60,11 +82,11 @@ HAL status. Definition at line \mbox{\hyperlink{general__tim_8c_source_l00226}{226}} of file \mbox{\hyperlink{general__tim_8c_source}{general\+\_\+tim.\+c}}. -\Hypertarget{group___m_y_l_i_b_s___t_i_m___o_c_gae2608ca8023e9a0713af0b4fbfbc1889}\label{group___m_y_l_i_b_s___t_i_m___o_c_gae2608ca8023e9a0713af0b4fbfbc1889} -\index{PWM/OC Channels tools@{PWM/OC Channels tools}!TIM\_OC\_Comparator\_Init@{TIM\_OC\_Comparator\_Init}} +\Hypertarget{group___m_y_l_i_b_s___t_i_m___o_c_gae2608ca8023e9a0713af0b4fbfbc1889}\index{PWM/OC Channels tools@{PWM/OC Channels tools}!TIM\_OC\_Comparator\_Init@{TIM\_OC\_Comparator\_Init}} \index{TIM\_OC\_Comparator\_Init@{TIM\_OC\_Comparator\_Init}!PWM/OC Channels tools@{PWM/OC Channels tools}} \doxysubsubsubsubsubsection{\texorpdfstring{TIM\_OC\_Comparator\_Init()}{TIM\_OC\_Comparator\_Init()}} -{\footnotesize\ttfamily HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+OC\+\_\+\+Comparator\+\_\+\+Init (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim, }\item[{uint32\+\_\+t}]{TIM\+\_\+\+CHANNEL }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___m_y_l_i_b_s___t_i_m___o_c_gae2608ca8023e9a0713af0b4fbfbc1889} +HAL\+\_\+\+Status\+Type\+Def TIM\+\_\+\+OC\+\_\+\+Comparator\+\_\+\+Init (\begin{DoxyParamCaption}\item[{TIM\+\_\+\+Handle\+Type\+Def \texorpdfstring{$\ast$}{*}}]{htim}{, }\item[{uint32\+\_\+t}]{TIM\+\_\+\+CHANNEL}{}\end{DoxyParamCaption})} diff --git a/Doc/latex/group___t_i_m___i_n_i_t.tex b/Doc/latex/group___t_i_m___i_n_i_t.tex index cce8c68..8453b3d 100644 --- a/Doc/latex/group___t_i_m___i_n_i_t.tex +++ b/Doc/latex/group___t_i_m___i_n_i_t.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsubsection{Init defines} +\doxysubsubsubsubsection{Init defines } \hypertarget{group___t_i_m___i_n_i_t}{}\label{group___t_i_m___i_n_i_t}\index{Init defines@{Init defines}} @@ -52,22 +52,24 @@ Collaboration diagram for Init defines\+:\nopagebreak +\label{doc-define-members} +\Hypertarget{group___t_i_m___i_n_i_t_doc-define-members} \doxysubsubsubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___t_i_m___i_n_i_t_ga23382b8f04b3e6db2c59dfa1ef5ea4a2}\label{group___t_i_m___i_n_i_t_ga23382b8f04b3e6db2c59dfa1ef5ea4a2} -\index{Init defines@{Init defines}!HAL\_TIM\_MODULE\_ENABLED@{HAL\_TIM\_MODULE\_ENABLED}} +\Hypertarget{group___t_i_m___i_n_i_t_ga23382b8f04b3e6db2c59dfa1ef5ea4a2}\index{Init defines@{Init defines}!HAL\_TIM\_MODULE\_ENABLED@{HAL\_TIM\_MODULE\_ENABLED}} \index{HAL\_TIM\_MODULE\_ENABLED@{HAL\_TIM\_MODULE\_ENABLED}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{HAL\_TIM\_MODULE\_ENABLED}{HAL\_TIM\_MODULE\_ENABLED}} -{\footnotesize\ttfamily \#define HAL\+\_\+\+TIM\+\_\+\+MODULE\+\_\+\+ENABLED} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga23382b8f04b3e6db2c59dfa1ef5ea4a2} +\#define HAL\+\_\+\+TIM\+\_\+\+MODULE\+\_\+\+ENABLED} -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00031}{31}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00032}{32}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga54a98c21365e0bc45b81555d2b101f2b}\label{group___t_i_m___i_n_i_t_ga54a98c21365e0bc45b81555d2b101f2b} -\index{Init defines@{Init defines}!USE\_TIM1@{USE\_TIM1}} +\Hypertarget{group___t_i_m___i_n_i_t_ga54a98c21365e0bc45b81555d2b101f2b}\index{Init defines@{Init defines}!USE\_TIM1@{USE\_TIM1}} \index{USE\_TIM1@{USE\_TIM1}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM1}{USE\_TIM1}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM1} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga54a98c21365e0bc45b81555d2b101f2b} +\#define USE\+\_\+\+TIM1} @@ -75,13 +77,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00031}{31}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00033}{33}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00034}{34}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga72535a44955b43cbcd56e25039ab32eb}\label{group___t_i_m___i_n_i_t_ga72535a44955b43cbcd56e25039ab32eb} -\index{Init defines@{Init defines}!USE\_TIM2@{USE\_TIM2}} +\Hypertarget{group___t_i_m___i_n_i_t_ga72535a44955b43cbcd56e25039ab32eb}\index{Init defines@{Init defines}!USE\_TIM2@{USE\_TIM2}} \index{USE\_TIM2@{USE\_TIM2}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM2}{USE\_TIM2}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM2} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga72535a44955b43cbcd56e25039ab32eb} +\#define USE\+\_\+\+TIM2} @@ -89,13 +91,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00033}{33}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00034}{34}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00035}{35}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga5b5685a43273b6e37242a4aba3ee0617}\label{group___t_i_m___i_n_i_t_ga5b5685a43273b6e37242a4aba3ee0617} -\index{Init defines@{Init defines}!USE\_TIM3@{USE\_TIM3}} +\Hypertarget{group___t_i_m___i_n_i_t_ga5b5685a43273b6e37242a4aba3ee0617}\index{Init defines@{Init defines}!USE\_TIM3@{USE\_TIM3}} \index{USE\_TIM3@{USE\_TIM3}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM3}{USE\_TIM3}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM3} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga5b5685a43273b6e37242a4aba3ee0617} +\#define USE\+\_\+\+TIM3} @@ -103,13 +105,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00034}{34}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00035}{35}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00036}{36}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga1493b39c9214501180b81b4c892f9be0}\label{group___t_i_m___i_n_i_t_ga1493b39c9214501180b81b4c892f9be0} -\index{Init defines@{Init defines}!USE\_TIM4@{USE\_TIM4}} +\Hypertarget{group___t_i_m___i_n_i_t_ga1493b39c9214501180b81b4c892f9be0}\index{Init defines@{Init defines}!USE\_TIM4@{USE\_TIM4}} \index{USE\_TIM4@{USE\_TIM4}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM4}{USE\_TIM4}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM4} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga1493b39c9214501180b81b4c892f9be0} +\#define USE\+\_\+\+TIM4} @@ -117,13 +119,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00035}{35}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00036}{36}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00037}{37}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga252f4fba93fc265110e83760e0590af3}\label{group___t_i_m___i_n_i_t_ga252f4fba93fc265110e83760e0590af3} -\index{Init defines@{Init defines}!USE\_TIM5@{USE\_TIM5}} +\Hypertarget{group___t_i_m___i_n_i_t_ga252f4fba93fc265110e83760e0590af3}\index{Init defines@{Init defines}!USE\_TIM5@{USE\_TIM5}} \index{USE\_TIM5@{USE\_TIM5}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM5}{USE\_TIM5}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM5} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga252f4fba93fc265110e83760e0590af3} +\#define USE\+\_\+\+TIM5} @@ -131,13 +133,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00036}{36}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00037}{37}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00038}{38}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga8fe31b98160627d19038222910be3f46}\label{group___t_i_m___i_n_i_t_ga8fe31b98160627d19038222910be3f46} -\index{Init defines@{Init defines}!USE\_TIM6@{USE\_TIM6}} +\Hypertarget{group___t_i_m___i_n_i_t_ga8fe31b98160627d19038222910be3f46}\index{Init defines@{Init defines}!USE\_TIM6@{USE\_TIM6}} \index{USE\_TIM6@{USE\_TIM6}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM6}{USE\_TIM6}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM6} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga8fe31b98160627d19038222910be3f46} +\#define USE\+\_\+\+TIM6} @@ -145,13 +147,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00037}{37}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00038}{38}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00039}{39}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga7cdc54cc8cbbb6e9f60001f1e3e6ec67}\label{group___t_i_m___i_n_i_t_ga7cdc54cc8cbbb6e9f60001f1e3e6ec67} -\index{Init defines@{Init defines}!USE\_TIM7@{USE\_TIM7}} +\Hypertarget{group___t_i_m___i_n_i_t_ga7cdc54cc8cbbb6e9f60001f1e3e6ec67}\index{Init defines@{Init defines}!USE\_TIM7@{USE\_TIM7}} \index{USE\_TIM7@{USE\_TIM7}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM7}{USE\_TIM7}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM7} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga7cdc54cc8cbbb6e9f60001f1e3e6ec67} +\#define USE\+\_\+\+TIM7} @@ -159,13 +161,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00038}{38}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00039}{39}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00040}{40}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga28ba33d7c6bf22821dafa5bcee4854be}\label{group___t_i_m___i_n_i_t_ga28ba33d7c6bf22821dafa5bcee4854be} -\index{Init defines@{Init defines}!USE\_TIM8@{USE\_TIM8}} +\Hypertarget{group___t_i_m___i_n_i_t_ga28ba33d7c6bf22821dafa5bcee4854be}\index{Init defines@{Init defines}!USE\_TIM8@{USE\_TIM8}} \index{USE\_TIM8@{USE\_TIM8}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM8}{USE\_TIM8}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM8} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga28ba33d7c6bf22821dafa5bcee4854be} +\#define USE\+\_\+\+TIM8} @@ -173,13 +175,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00039}{39}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00040}{40}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00041}{41}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_gaac627c0e98c9594cc41b1b46eb39e44a}\label{group___t_i_m___i_n_i_t_gaac627c0e98c9594cc41b1b46eb39e44a} -\index{Init defines@{Init defines}!USE\_TIM9@{USE\_TIM9}} +\Hypertarget{group___t_i_m___i_n_i_t_gaac627c0e98c9594cc41b1b46eb39e44a}\index{Init defines@{Init defines}!USE\_TIM9@{USE\_TIM9}} \index{USE\_TIM9@{USE\_TIM9}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM9}{USE\_TIM9}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM9} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_gaac627c0e98c9594cc41b1b46eb39e44a} +\#define USE\+\_\+\+TIM9} @@ -187,13 +189,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00040}{40}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00041}{41}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00042}{42}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga98c0691052d1da2c4053dd3586ff7ce9}\label{group___t_i_m___i_n_i_t_ga98c0691052d1da2c4053dd3586ff7ce9} -\index{Init defines@{Init defines}!USE\_TIM10@{USE\_TIM10}} +\Hypertarget{group___t_i_m___i_n_i_t_ga98c0691052d1da2c4053dd3586ff7ce9}\index{Init defines@{Init defines}!USE\_TIM10@{USE\_TIM10}} \index{USE\_TIM10@{USE\_TIM10}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM10}{USE\_TIM10}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM10} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga98c0691052d1da2c4053dd3586ff7ce9} +\#define USE\+\_\+\+TIM10} @@ -201,13 +203,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00041}{41}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00042}{42}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00043}{43}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga176c97f06ebcf14e06e5c5bdbfac44c2}\label{group___t_i_m___i_n_i_t_ga176c97f06ebcf14e06e5c5bdbfac44c2} -\index{Init defines@{Init defines}!USE\_TIM11@{USE\_TIM11}} +\Hypertarget{group___t_i_m___i_n_i_t_ga176c97f06ebcf14e06e5c5bdbfac44c2}\index{Init defines@{Init defines}!USE\_TIM11@{USE\_TIM11}} \index{USE\_TIM11@{USE\_TIM11}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM11}{USE\_TIM11}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM11} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga176c97f06ebcf14e06e5c5bdbfac44c2} +\#define USE\+\_\+\+TIM11} @@ -215,13 +217,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00042}{42}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00043}{43}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00044}{44}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga4e2b0e6cdf9eed74581b575c3fd9516b}\label{group___t_i_m___i_n_i_t_ga4e2b0e6cdf9eed74581b575c3fd9516b} -\index{Init defines@{Init defines}!USE\_TIM12@{USE\_TIM12}} +\Hypertarget{group___t_i_m___i_n_i_t_ga4e2b0e6cdf9eed74581b575c3fd9516b}\index{Init defines@{Init defines}!USE\_TIM12@{USE\_TIM12}} \index{USE\_TIM12@{USE\_TIM12}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM12}{USE\_TIM12}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM12} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga4e2b0e6cdf9eed74581b575c3fd9516b} +\#define USE\+\_\+\+TIM12} @@ -229,13 +231,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00043}{43}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00044}{44}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00045}{45}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_gaf48ef87650517652ddec039a189507ac}\label{group___t_i_m___i_n_i_t_gaf48ef87650517652ddec039a189507ac} -\index{Init defines@{Init defines}!USE\_TIM13@{USE\_TIM13}} +\Hypertarget{group___t_i_m___i_n_i_t_gaf48ef87650517652ddec039a189507ac}\index{Init defines@{Init defines}!USE\_TIM13@{USE\_TIM13}} \index{USE\_TIM13@{USE\_TIM13}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM13}{USE\_TIM13}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM13} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_gaf48ef87650517652ddec039a189507ac} +\#define USE\+\_\+\+TIM13} @@ -243,13 +245,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00044}{44}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00045}{45}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00046}{46}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{group___t_i_m___i_n_i_t_ga9ae40be31d5271abe3e49f896d916d5c}\label{group___t_i_m___i_n_i_t_ga9ae40be31d5271abe3e49f896d916d5c} -\index{Init defines@{Init defines}!USE\_TIM14@{USE\_TIM14}} +\Hypertarget{group___t_i_m___i_n_i_t_ga9ae40be31d5271abe3e49f896d916d5c}\index{Init defines@{Init defines}!USE\_TIM14@{USE\_TIM14}} \index{USE\_TIM14@{USE\_TIM14}!Init defines@{Init defines}} \doxysubsubsubsubsubsubsection{\texorpdfstring{USE\_TIM14}{USE\_TIM14}} -{\footnotesize\ttfamily \#define USE\+\_\+\+TIM14} +{\footnotesize\ttfamily \label{group___t_i_m___i_n_i_t_ga9ae40be31d5271abe3e49f896d916d5c} +\#define USE\+\_\+\+TIM14} @@ -257,5 +259,5 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00045}{45}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00046}{46}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00047}{47}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. diff --git a/Doc/latex/group___t_r_a_c_e.tex b/Doc/latex/group___t_r_a_c_e.tex index 96c475c..3dbdd57 100644 --- a/Doc/latex/group___t_r_a_c_e.tex +++ b/Doc/latex/group___t_r_a_c_e.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Trace defines} +\doxysubsubsection{Trace defines } \hypertarget{group___t_r_a_c_e}{}\label{group___t_r_a_c_e}\index{Trace defines@{Trace defines}} diff --git a/Doc/latex/group___t_r_a_c_e___c_o_n_f_i_g.tex b/Doc/latex/group___t_r_a_c_e___c_o_n_f_i_g.tex index 500562a..cf8e2ac 100644 --- a/Doc/latex/group___t_r_a_c_e___c_o_n_f_i_g.tex +++ b/Doc/latex/group___t_r_a_c_e___c_o_n_f_i_g.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Trace configs} +\doxysubsubsection{Trace configs } \hypertarget{group___t_r_a_c_e___c_o_n_f_i_g}{}\label{group___t_r_a_c_e___c_o_n_f_i_g}\index{Trace configs@{Trace configs}} @@ -54,12 +54,14 @@ Collaboration diagram for Trace configs\+:\nopagebreak +\label{doc-define-members} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gac9eaedc31ab023ce7d6403999216e496}\label{group___t_r_a_c_e___c_o_n_f_i_g_gac9eaedc31ab023ce7d6403999216e496} -\index{Trace configs@{Trace configs}!TRACKERS\_ENABLE@{TRACKERS\_ENABLE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gac9eaedc31ab023ce7d6403999216e496}\index{Trace configs@{Trace configs}!TRACKERS\_ENABLE@{TRACKERS\_ENABLE}} \index{TRACKERS\_ENABLE@{TRACKERS\_ENABLE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{TRACKERS\_ENABLE}{TRACKERS\_ENABLE}} -{\footnotesize\ttfamily \#define TRACKERS\+\_\+\+ENABLE} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_gac9eaedc31ab023ce7d6403999216e496} +\#define TRACKERS\+\_\+\+ENABLE} @@ -69,11 +71,11 @@ Collaboration diagram for Trace configs\+:\nopagebreak Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00025}{25}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga76936505ca200d2e61226b7ba68f27c6}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga76936505ca200d2e61226b7ba68f27c6} -\index{Trace configs@{Trace configs}!SERIAL\_TRACE\_ENABLE@{SERIAL\_TRACE\_ENABLE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga76936505ca200d2e61226b7ba68f27c6}\index{Trace configs@{Trace configs}!SERIAL\_TRACE\_ENABLE@{SERIAL\_TRACE\_ENABLE}} \index{SERIAL\_TRACE\_ENABLE@{SERIAL\_TRACE\_ENABLE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{SERIAL\_TRACE\_ENABLE}{SERIAL\_TRACE\_ENABLE}} -{\footnotesize\ttfamily \#define SERIAL\+\_\+\+TRACE\+\_\+\+ENABLE} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga76936505ca200d2e61226b7ba68f27c6} +\#define SERIAL\+\_\+\+TRACE\+\_\+\+ENABLE} @@ -83,11 +85,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00025}{25}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00026}{26}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga00ff2175bdc1fb11c8ec970ea3010dd8}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga00ff2175bdc1fb11c8ec970ea3010dd8} -\index{Trace configs@{Trace configs}!RTT\_TRACE\_ENABLE@{RTT\_TRACE\_ENABLE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga00ff2175bdc1fb11c8ec970ea3010dd8}\index{Trace configs@{Trace configs}!RTT\_TRACE\_ENABLE@{RTT\_TRACE\_ENABLE}} \index{RTT\_TRACE\_ENABLE@{RTT\_TRACE\_ENABLE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{RTT\_TRACE\_ENABLE}{RTT\_TRACE\_ENABLE}} -{\footnotesize\ttfamily \#define RTT\+\_\+\+TRACE\+\_\+\+ENABLE} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga00ff2175bdc1fb11c8ec970ea3010dd8} +\#define RTT\+\_\+\+TRACE\+\_\+\+ENABLE} @@ -97,11 +99,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00026}{26}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00027}{27}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gab8db9704b5d11858aa879689b9d36336}\label{group___t_r_a_c_e___c_o_n_f_i_g_gab8db9704b5d11858aa879689b9d36336} -\index{Trace configs@{Trace configs}!SWO\_TRACE\_ENABLE@{SWO\_TRACE\_ENABLE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gab8db9704b5d11858aa879689b9d36336}\index{Trace configs@{Trace configs}!SWO\_TRACE\_ENABLE@{SWO\_TRACE\_ENABLE}} \index{SWO\_TRACE\_ENABLE@{SWO\_TRACE\_ENABLE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{SWO\_TRACE\_ENABLE}{SWO\_TRACE\_ENABLE}} -{\footnotesize\ttfamily \#define SWO\+\_\+\+TRACE\+\_\+\+ENABLE} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_gab8db9704b5d11858aa879689b9d36336} +\#define SWO\+\_\+\+TRACE\+\_\+\+ENABLE} @@ -111,11 +113,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00027}{27}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00028}{28}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05} -\index{Trace configs@{Trace configs}!LOG\_LEVEL@{LOG\_LEVEL}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05}\index{Trace configs@{Trace configs}!LOG\_LEVEL@{LOG\_LEVEL}} \index{LOG\_LEVEL@{LOG\_LEVEL}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{LOG\_LEVEL}{LOG\_LEVEL}} -{\footnotesize\ttfamily \#define LOG\+\_\+\+LEVEL~1} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05} +\#define LOG\+\_\+\+LEVEL~1} @@ -130,11 +132,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00028}{28}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00035}{35}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3} -\index{Trace configs@{Trace configs}!RTT\_FLASH\_BUFFER\_SIZE@{RTT\_FLASH\_BUFFER\_SIZE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}\index{Trace configs@{Trace configs}!RTT\_FLASH\_BUFFER\_SIZE@{RTT\_FLASH\_BUFFER\_SIZE}} \index{RTT\_FLASH\_BUFFER\_SIZE@{RTT\_FLASH\_BUFFER\_SIZE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{RTT\_FLASH\_BUFFER\_SIZE}{RTT\_FLASH\_BUFFER\_SIZE}} -{\footnotesize\ttfamily \#define RTT\+\_\+\+FLASH\+\_\+\+BUFFER\+\_\+\+SIZE~1024} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3} +\#define RTT\+\_\+\+FLASH\+\_\+\+BUFFER\+\_\+\+SIZE~1024} @@ -144,11 +146,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00035}{35}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00037}{37}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga3bc1b76864e1d32cbdd174d4caae7724}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga3bc1b76864e1d32cbdd174d4caae7724} -\index{Trace configs@{Trace configs}!RTT\_FLASH\_SECTOR@{RTT\_FLASH\_SECTOR}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga3bc1b76864e1d32cbdd174d4caae7724}\index{Trace configs@{Trace configs}!RTT\_FLASH\_SECTOR@{RTT\_FLASH\_SECTOR}} \index{RTT\_FLASH\_SECTOR@{RTT\_FLASH\_SECTOR}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{RTT\_FLASH\_SECTOR}{RTT\_FLASH\_SECTOR}} -{\footnotesize\ttfamily \#define RTT\+\_\+\+FLASH\+\_\+\+SECTOR~FLASH\+\_\+\+SECTOR\+\_\+11} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga3bc1b76864e1d32cbdd174d4caae7724} +\#define RTT\+\_\+\+FLASH\+\_\+\+SECTOR~FLASH\+\_\+\+SECTOR\+\_\+11} @@ -158,11 +160,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00037}{37}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00038}{38}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga8e56f75d3ab8a89ddde1404ae23c3297}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga8e56f75d3ab8a89ddde1404ae23c3297} -\index{Trace configs@{Trace configs}!RTT\_FLASH\_SECTOR\_START@{RTT\_FLASH\_SECTOR\_START}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga8e56f75d3ab8a89ddde1404ae23c3297}\index{Trace configs@{Trace configs}!RTT\_FLASH\_SECTOR\_START@{RTT\_FLASH\_SECTOR\_START}} \index{RTT\_FLASH\_SECTOR\_START@{RTT\_FLASH\_SECTOR\_START}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{RTT\_FLASH\_SECTOR\_START}{RTT\_FLASH\_SECTOR\_START}} -{\footnotesize\ttfamily \#define RTT\+\_\+\+FLASH\+\_\+\+SECTOR\+\_\+\+START~0x080\+E0000} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga8e56f75d3ab8a89ddde1404ae23c3297} +\#define RTT\+\_\+\+FLASH\+\_\+\+SECTOR\+\_\+\+START~0x080\+E0000} @@ -172,11 +174,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00038}{38}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00039}{39}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}\label{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d} -\index{Trace configs@{Trace configs}!RTT\_FLASH\_SECTOR\_END@{RTT\_FLASH\_SECTOR\_END}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}\index{Trace configs@{Trace configs}!RTT\_FLASH\_SECTOR\_END@{RTT\_FLASH\_SECTOR\_END}} \index{RTT\_FLASH\_SECTOR\_END@{RTT\_FLASH\_SECTOR\_END}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{RTT\_FLASH\_SECTOR\_END}{RTT\_FLASH\_SECTOR\_END}} -{\footnotesize\ttfamily \#define RTT\+\_\+\+FLASH\+\_\+\+SECTOR\+\_\+\+END~0x080\+FFFFF} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d} +\#define RTT\+\_\+\+FLASH\+\_\+\+SECTOR\+\_\+\+END~0x080\+FFFFF} @@ -186,11 +188,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00039}{39}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00040}{40}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga47f454f804b4dbc26cae079e8d8641e6}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga47f454f804b4dbc26cae079e8d8641e6} -\index{Trace configs@{Trace configs}!HARDFAULT\_SERIAL\_TRACE@{HARDFAULT\_SERIAL\_TRACE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga47f454f804b4dbc26cae079e8d8641e6}\index{Trace configs@{Trace configs}!HARDFAULT\_SERIAL\_TRACE@{HARDFAULT\_SERIAL\_TRACE}} \index{HARDFAULT\_SERIAL\_TRACE@{HARDFAULT\_SERIAL\_TRACE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{HARDFAULT\_SERIAL\_TRACE}{HARDFAULT\_SERIAL\_TRACE}} -{\footnotesize\ttfamily \#define HARDFAULT\+\_\+\+SERIAL\+\_\+\+TRACE} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga47f454f804b4dbc26cae079e8d8641e6} +\#define HARDFAULT\+\_\+\+SERIAL\+\_\+\+TRACE} @@ -200,11 +202,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00040}{40}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00043}{43}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gadc960255719c7eff4bdfaa850be9b313}\label{group___t_r_a_c_e___c_o_n_f_i_g_gadc960255719c7eff4bdfaa850be9b313} -\index{Trace configs@{Trace configs}!HF\_RTT\_TAG\_BASE@{HF\_RTT\_TAG\_BASE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gadc960255719c7eff4bdfaa850be9b313}\index{Trace configs@{Trace configs}!HF\_RTT\_TAG\_BASE@{HF\_RTT\_TAG\_BASE}} \index{HF\_RTT\_TAG\_BASE@{HF\_RTT\_TAG\_BASE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{HF\_RTT\_TAG\_BASE}{HF\_RTT\_TAG\_BASE}} -{\footnotesize\ttfamily \#define HF\+\_\+\+RTT\+\_\+\+TAG\+\_\+\+BASE~0x\+DEAD0000} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_gadc960255719c7eff4bdfaa850be9b313} +\#define HF\+\_\+\+RTT\+\_\+\+TAG\+\_\+\+BASE~0x\+DEAD0000} @@ -214,11 +216,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00043}{43}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00044}{44}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gafcc7ea03d4df8f1909e580b519a7f3ca}\label{group___t_r_a_c_e___c_o_n_f_i_g_gafcc7ea03d4df8f1909e580b519a7f3ca} -\index{Trace configs@{Trace configs}!HF\_RTT\_TAIL\_SIZE@{HF\_RTT\_TAIL\_SIZE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gafcc7ea03d4df8f1909e580b519a7f3ca}\index{Trace configs@{Trace configs}!HF\_RTT\_TAIL\_SIZE@{HF\_RTT\_TAIL\_SIZE}} \index{HF\_RTT\_TAIL\_SIZE@{HF\_RTT\_TAIL\_SIZE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{HF\_RTT\_TAIL\_SIZE}{HF\_RTT\_TAIL\_SIZE}} -{\footnotesize\ttfamily \#define HF\+\_\+\+RTT\+\_\+\+TAIL\+\_\+\+SIZE~\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\+\_\+\+FLASH\+\_\+\+BUFFER\+\_\+\+SIZE}}} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_gafcc7ea03d4df8f1909e580b519a7f3ca} +\#define HF\+\_\+\+RTT\+\_\+\+TAIL\+\_\+\+SIZE~\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\+\_\+\+FLASH\+\_\+\+BUFFER\+\_\+\+SIZE}}} @@ -228,11 +230,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00044}{44}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00045}{45}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gaa31234688b333a505aaa57b8ecdedf5b}\label{group___t_r_a_c_e___c_o_n_f_i_g_gaa31234688b333a505aaa57b8ecdedf5b} -\index{Trace configs@{Trace configs}!HF\_STACK\_DUMP\_WORDS@{HF\_STACK\_DUMP\_WORDS}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_gaa31234688b333a505aaa57b8ecdedf5b}\index{Trace configs@{Trace configs}!HF\_STACK\_DUMP\_WORDS@{HF\_STACK\_DUMP\_WORDS}} \index{HF\_STACK\_DUMP\_WORDS@{HF\_STACK\_DUMP\_WORDS}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{HF\_STACK\_DUMP\_WORDS}{HF\_STACK\_DUMP\_WORDS}} -{\footnotesize\ttfamily \#define HF\+\_\+\+STACK\+\_\+\+DUMP\+\_\+\+WORDS~32} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_gaa31234688b333a505aaa57b8ecdedf5b} +\#define HF\+\_\+\+STACK\+\_\+\+DUMP\+\_\+\+WORDS~32} @@ -242,11 +244,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00045}{45}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00046}{46}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga0c602733a4a359bf8c095d71cd4d0f63}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga0c602733a4a359bf8c095d71cd4d0f63} -\index{Trace configs@{Trace configs}!HF\_FLASH\_ADDR@{HF\_FLASH\_ADDR}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga0c602733a4a359bf8c095d71cd4d0f63}\index{Trace configs@{Trace configs}!HF\_FLASH\_ADDR@{HF\_FLASH\_ADDR}} \index{HF\_FLASH\_ADDR@{HF\_FLASH\_ADDR}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{HF\_FLASH\_ADDR}{HF\_FLASH\_ADDR}} -{\footnotesize\ttfamily \#define HF\+\_\+\+FLASH\+\_\+\+ADDR~((uint32\+\_\+t)0x080\+FF000)} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga0c602733a4a359bf8c095d71cd4d0f63} +\#define HF\+\_\+\+FLASH\+\_\+\+ADDR~((uint32\+\_\+t)0x080\+FF000)} @@ -256,11 +258,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00046}{46}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00047}{47}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga92d0d14732edb7dfa21d483304bdb051}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga92d0d14732edb7dfa21d483304bdb051} -\index{Trace configs@{Trace configs}!HF\_RAM\_END@{HF\_RAM\_END}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga92d0d14732edb7dfa21d483304bdb051}\index{Trace configs@{Trace configs}!HF\_RAM\_END@{HF\_RAM\_END}} \index{HF\_RAM\_END@{HF\_RAM\_END}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{HF\_RAM\_END}{HF\_RAM\_END}} -{\footnotesize\ttfamily \#define HF\+\_\+\+RAM\+\_\+\+END~0x20030000} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga92d0d14732edb7dfa21d483304bdb051} +\#define HF\+\_\+\+RAM\+\_\+\+END~0x20030000} @@ -270,11 +272,11 @@ Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00047}{47}} of fil Definition at line \mbox{\hyperlink{mylibs__config_8h_source_l00048}{48}} of file \mbox{\hyperlink{mylibs__config_8h_source}{mylibs\+\_\+config.\+h}}. -\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga4222e0e400ad81737cefcabeb03fd23b}\label{group___t_r_a_c_e___c_o_n_f_i_g_ga4222e0e400ad81737cefcabeb03fd23b} -\index{Trace configs@{Trace configs}!GPIO\_TRACE\_ENABLE@{GPIO\_TRACE\_ENABLE}} +\Hypertarget{group___t_r_a_c_e___c_o_n_f_i_g_ga4222e0e400ad81737cefcabeb03fd23b}\index{Trace configs@{Trace configs}!GPIO\_TRACE\_ENABLE@{GPIO\_TRACE\_ENABLE}} \index{GPIO\_TRACE\_ENABLE@{GPIO\_TRACE\_ENABLE}!Trace configs@{Trace configs}} \doxysubsubsubsubsection{\texorpdfstring{GPIO\_TRACE\_ENABLE}{GPIO\_TRACE\_ENABLE}} -{\footnotesize\ttfamily \#define GPIO\+\_\+\+TRACE\+\_\+\+ENABLE} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___c_o_n_f_i_g_ga4222e0e400ad81737cefcabeb03fd23b} +\#define GPIO\+\_\+\+TRACE\+\_\+\+ENABLE} diff --git a/Doc/latex/group___t_r_a_c_e___g_p_i_o.tex b/Doc/latex/group___t_r_a_c_e___g_p_i_o.tex index 1b2279c..c8a24d6 100644 --- a/Doc/latex/group___t_r_a_c_e___g_p_i_o.tex +++ b/Doc/latex/group___t_r_a_c_e___g_p_i_o.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{GPIO trace defines} +\doxysubsubsubsection{GPIO trace defines } \hypertarget{group___t_r_a_c_e___g_p_i_o}{}\label{group___t_r_a_c_e___g_p_i_o}\index{GPIO trace defines@{GPIO trace defines}} @@ -15,9 +15,9 @@ Collaboration diagram for GPIO trace defines\+:\nopagebreak \doxysubsubsubsubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}{TRACE\+\_\+\+GPIO\+\_\+\+RESET}}(\+\_\+gpio\+\_\+, \+\_\+pin\+\_\+)~(\+\_\+gpio\+\_\+)-\/$>$BSRR = ((\+\_\+pin\+\_\+)$<$$<$16) +\#define \mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}{TRACE\+\_\+\+GPIO\+\_\+\+RESET}}(\+\_\+gpio\+\_\+, \+\_\+pin\+\_\+) \begin{DoxyCompactList}\small\item\em Сбросить указанную ножку GPIO. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}{TRACE\+\_\+\+GPIO\+\_\+\+SET}}(\+\_\+gpio\+\_\+, \+\_\+pin\+\_\+)~(\+\_\+gpio\+\_\+)-\/$>$BSRR = (((\+\_\+pin\+\_\+))) +\#define \mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}{TRACE\+\_\+\+GPIO\+\_\+\+SET}}(\+\_\+gpio\+\_\+, \+\_\+pin\+\_\+) \begin{DoxyCompactList}\small\item\em Установить указанную ножку GPIO. \end{DoxyCompactList}\end{DoxyCompactItemize} @@ -28,17 +28,23 @@ Collaboration diagram for GPIO trace defines\+:\nopagebreak \begin{DoxyItemize} \item \doxylink{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}{TRACE\+\_\+\+GPIO\+\_\+\+RESET()} -\/ для сброса ножки GPIO (через BSRR) \item \doxylink{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}{TRACE\+\_\+\+GPIO\+\_\+\+SET()} -\/ для выставления ножки GPIO (через BSRR) -\item Если трассировка \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga4222e0e400ad81737cefcabeb03fd23b}{GPIO\+\_\+\+TRACE\+\_\+\+ENABLE} отключена, то все дефайны определяются как \textquotesingle{}ничего\textquotesingle{} и на производительность кода не влияют ~\newline - +\item Если трассировка \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga4222e0e400ad81737cefcabeb03fd23b}{GPIO\+\_\+\+TRACE\+\_\+\+ENABLE} отключена, то все дефайны определяются как \textquotesingle{}ничего\textquotesingle{} и на производительность кода не влияют \end{DoxyItemize} +\label{doc-define-members} +\Hypertarget{group___t_r_a_c_e___g_p_i_o_doc-define-members} \doxysubsubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}\label{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a} -\index{GPIO trace defines@{GPIO trace defines}!TRACE\_GPIO\_RESET@{TRACE\_GPIO\_RESET}} +\Hypertarget{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}\index{GPIO trace defines@{GPIO trace defines}!TRACE\_GPIO\_RESET@{TRACE\_GPIO\_RESET}} \index{TRACE\_GPIO\_RESET@{TRACE\_GPIO\_RESET}!GPIO trace defines@{GPIO trace defines}} \doxysubsubsubsubsubsection{\texorpdfstring{TRACE\_GPIO\_RESET}{TRACE\_GPIO\_RESET}} -{\footnotesize\ttfamily \#define TRACE\+\_\+\+GPIO\+\_\+\+RESET(\begin{DoxyParamCaption}\item[{}]{\+\_\+gpio\+\_\+, }\item[{}]{\+\_\+pin\+\_\+ }\end{DoxyParamCaption})~(\+\_\+gpio\+\_\+)-\/$>$BSRR = ((\+\_\+pin\+\_\+)$<$$<$16)} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a} +\#define TRACE\+\_\+\+GPIO\+\_\+\+RESET(\begin{DoxyParamCaption}\item[{}]{\+\_\+gpio\+\_\+}{, }\item[{}]{\+\_\+pin\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_gpio\_)-\/>BSRR\ =\ ((\_pin\_)<<16)} + +\end{DoxyCode} Сбросить указанную ножку GPIO. @@ -56,14 +62,19 @@ Collaboration diagram for GPIO trace defines\+:\nopagebreak \item GPIO\+\_\+\+TRACE\+\_\+\+ENABLE определён -\/ устанавливает бит сброса через BSRR (({\itshape pin})\texorpdfstring{$<$}{<}\texorpdfstring{$<$}{<}16) \end{DoxyItemize} -Definition at line \mbox{\hyperlink{trace_8h_source_l00142}{142}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00155}{155}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}\label{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb} -\index{GPIO trace defines@{GPIO trace defines}!TRACE\_GPIO\_SET@{TRACE\_GPIO\_SET}} +\Hypertarget{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}\index{GPIO trace defines@{GPIO trace defines}!TRACE\_GPIO\_SET@{TRACE\_GPIO\_SET}} \index{TRACE\_GPIO\_SET@{TRACE\_GPIO\_SET}!GPIO trace defines@{GPIO trace defines}} \doxysubsubsubsubsubsection{\texorpdfstring{TRACE\_GPIO\_SET}{TRACE\_GPIO\_SET}} -{\footnotesize\ttfamily \#define TRACE\+\_\+\+GPIO\+\_\+\+SET(\begin{DoxyParamCaption}\item[{}]{\+\_\+gpio\+\_\+, }\item[{}]{\+\_\+pin\+\_\+ }\end{DoxyParamCaption})~(\+\_\+gpio\+\_\+)-\/$>$BSRR = (((\+\_\+pin\+\_\+)))} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb} +\#define TRACE\+\_\+\+GPIO\+\_\+\+SET(\begin{DoxyParamCaption}\item[{}]{\+\_\+gpio\+\_\+}{, }\item[{}]{\+\_\+pin\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_gpio\_)-\/>BSRR\ =\ (((\_pin\_)))} + +\end{DoxyCode} Установить указанную ножку GPIO. @@ -81,5 +92,5 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00142}{142}} of file \mbox{ \item GPIO\+\_\+\+TRACE\+\_\+\+ENABLE определён -\/ устанавливает бит установки через BSRR ({\itshape pin}) \end{DoxyItemize} -Definition at line \mbox{\hyperlink{trace_8h_source_l00141}{141}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00154}{154}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. diff --git a/Doc/latex/group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.tex b/Doc/latex/group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.tex index 612592f..0c67ade 100644 --- a/Doc/latex/group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.tex +++ b/Doc/latex/group___t_r_a_c_e___h_a_r_d_f_a_u_l_t.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{Hardfault trace defines} +\doxysubsubsubsection{Hardfault trace defines } \hypertarget{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t}{}\label{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t}\index{Hardfault trace defines@{Hardfault trace defines}} @@ -78,12 +78,14 @@ struct \mbox{\hyperlink{struct_h_f___stack_frame__t}{HF\+\_\+\+Stack\+Frame\+\_\ \end{DoxyCode} +\label{doc-func-members} +\Hypertarget{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_ga03f8b6f3b537ee1c8e91065c60db504f}\label{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_ga03f8b6f3b537ee1c8e91065c60db504f} -\index{Hardfault trace defines@{Hardfault trace defines}!HF\_CheckRecovered@{HF\_CheckRecovered}} +\Hypertarget{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_ga03f8b6f3b537ee1c8e91065c60db504f}\index{Hardfault trace defines@{Hardfault trace defines}!HF\_CheckRecovered@{HF\_CheckRecovered}} \index{HF\_CheckRecovered@{HF\_CheckRecovered}!Hardfault trace defines@{Hardfault trace defines}} \doxysubsubsubsubsubsection{\texorpdfstring{HF\_CheckRecovered()}{HF\_CheckRecovered()}} -{\footnotesize\ttfamily \+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE int HF\+\_\+\+Check\+Recovered (\begin{DoxyParamCaption}\item[{int}]{erase }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_ga03f8b6f3b537ee1c8e91065c60db504f} +\+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE int HF\+\_\+\+Check\+Recovered (\begin{DoxyParamCaption}\item[{int}]{erase}{}\end{DoxyParamCaption})} @@ -103,13 +105,13 @@ int \end{DoxyNote} -Definition at line \mbox{\hyperlink{trace_8h_source_l00486}{486}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00499}{499}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_gadd8e10e7ec3b0204f7f92062ecd452f7}\label{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_gadd8e10e7ec3b0204f7f92062ecd452f7} -\index{Hardfault trace defines@{Hardfault trace defines}!HF\_HandleFault@{HF\_HandleFault}} +\Hypertarget{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_gadd8e10e7ec3b0204f7f92062ecd452f7}\index{Hardfault trace defines@{Hardfault trace defines}!HF\_HandleFault@{HF\_HandleFault}} \index{HF\_HandleFault@{HF\_HandleFault}!Hardfault trace defines@{Hardfault trace defines}} \doxysubsubsubsubsubsection{\texorpdfstring{HF\_HandleFault()}{HF\_HandleFault()}} -{\footnotesize\ttfamily \+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE void HF\+\_\+\+Handle\+Fault (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_gadd8e10e7ec3b0204f7f92062ecd452f7} +\+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE void HF\+\_\+\+Handle\+Fault (\begin{DoxyParamCaption}\item[{void}]{}{}\end{DoxyParamCaption})} @@ -130,5 +132,5 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00486}{486}} of file \mbox{ \end{DoxyNote} -Definition at line \mbox{\hyperlink{trace_8h_source_l00527}{527}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00540}{540}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. diff --git a/Doc/latex/group___t_r_a_c_e___r_t_t___f_l_a_s_h.tex b/Doc/latex/group___t_r_a_c_e___r_t_t___f_l_a_s_h.tex index 67d4bf1..bb0d50f 100644 --- a/Doc/latex/group___t_r_a_c_e___r_t_t___f_l_a_s_h.tex +++ b/Doc/latex/group___t_r_a_c_e___r_t_t___f_l_a_s_h.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{Flash RTT Buffer} +\doxysubsubsubsection{Flash RTT Buffer } \hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h}{}\label{group___t_r_a_c_e___r_t_t___f_l_a_s_h}\index{Flash RTT Buffer@{Flash RTT Buffer}} @@ -56,12 +56,14 @@ struct \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\+\_\+\+Flash\+Header \item \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}{RTT\+\_\+\+FLASH\+\_\+\+SECTOR\+\_\+\+END} -\/ Конец сектора RTT\+\_\+\+FLASH\+\_\+\+SECTOR \end{DoxyItemize} +\label{doc-func-members} +\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_doc-func-members} \doxysubsubsubsubsection{Function Documentation} -\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}\label{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6} -\index{Flash RTT Buffer@{Flash RTT Buffer}!RTT\_FlashPrepare@{RTT\_FlashPrepare}} +\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}\index{Flash RTT Buffer@{Flash RTT Buffer}!RTT\_FlashPrepare@{RTT\_FlashPrepare}} \index{RTT\_FlashPrepare@{RTT\_FlashPrepare}!Flash RTT Buffer@{Flash RTT Buffer}} \doxysubsubsubsubsubsection{\texorpdfstring{RTT\_FlashPrepare()}{RTT\_FlashPrepare()}} -{\footnotesize\ttfamily \+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE void RTT\+\_\+\+Flash\+Prepare (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6} +\+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE void RTT\+\_\+\+Flash\+Prepare (\begin{DoxyParamCaption}\item[{void}]{}{}\end{DoxyParamCaption})} @@ -69,13 +71,13 @@ struct \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\+\_\+\+Flash\+Header Сбрасывает ошибки Flash и ожидает готовности перед записью -Definition at line \mbox{\hyperlink{trace_8h_source_l00190}{190}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00203}{203}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63}\label{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63} -\index{Flash RTT Buffer@{Flash RTT Buffer}!RTT\_SaveToFlash@{RTT\_SaveToFlash}} +\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63}\index{Flash RTT Buffer@{Flash RTT Buffer}!RTT\_SaveToFlash@{RTT\_SaveToFlash}} \index{RTT\_SaveToFlash@{RTT\_SaveToFlash}!Flash RTT Buffer@{Flash RTT Buffer}} \doxysubsubsubsubsubsection{\texorpdfstring{RTT\_SaveToFlash()}{RTT\_SaveToFlash()}} -{\footnotesize\ttfamily \+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE int RTT\+\_\+\+Save\+To\+Flash (\begin{DoxyParamCaption}\item[{uint32\+\_\+t}]{tag, }\item[{uint32\+\_\+t}]{tail\+\_\+size }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63} +\+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE int RTT\+\_\+\+Save\+To\+Flash (\begin{DoxyParamCaption}\item[{uint32\+\_\+t}]{tag}{, }\item[{uint32\+\_\+t}]{tail\+\_\+size}{}\end{DoxyParamCaption})} @@ -99,13 +101,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00190}{190}} of file \mbox{ \item Если конкретный (младший байт != 0) — запись выполняется только с этим тегом, иначе ошибка. \end{DoxyItemize} -Definition at line \mbox{\hyperlink{trace_8h_source_l00214}{214}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00227}{227}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146}\label{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146} -\index{Flash RTT Buffer@{Flash RTT Buffer}!RTT\_ReadFromFlash@{RTT\_ReadFromFlash}} +\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146}\index{Flash RTT Buffer@{Flash RTT Buffer}!RTT\_ReadFromFlash@{RTT\_ReadFromFlash}} \index{RTT\_ReadFromFlash@{RTT\_ReadFromFlash}!Flash RTT Buffer@{Flash RTT Buffer}} \doxysubsubsubsubsubsection{\texorpdfstring{RTT\_ReadFromFlash()}{RTT\_ReadFromFlash()}} -{\footnotesize\ttfamily \+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE int RTT\+\_\+\+Read\+From\+Flash (\begin{DoxyParamCaption}\item[{uint32\+\_\+t}]{tag, }\item[{char \texorpdfstring{$\ast$}{*}}]{Buffer, }\item[{uint32\+\_\+t}]{tail\+\_\+size, }\item[{uint32\+\_\+t \texorpdfstring{$\ast$}{*}}]{read\+\_\+size }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146} +\+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE int RTT\+\_\+\+Read\+From\+Flash (\begin{DoxyParamCaption}\item[{uint32\+\_\+t}]{tag}{, }\item[{char \texorpdfstring{$\ast$}{*}}]{Buffer}{, }\item[{uint32\+\_\+t}]{tail\+\_\+size}{, }\item[{uint32\+\_\+t \texorpdfstring{$\ast$}{*}}]{read\+\_\+size}{}\end{DoxyParamCaption})} @@ -131,13 +133,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00214}{214}} of file \mbox{ \item Если конкретный (младший байт != 0) — прочитывается именно эта запись. \end{DoxyItemize} -Definition at line \mbox{\hyperlink{trace_8h_source_l00311}{311}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00324}{324}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1}\label{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1} -\index{Flash RTT Buffer@{Flash RTT Buffer}!RTT\_EraseFlash@{RTT\_EraseFlash}} +\Hypertarget{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1}\index{Flash RTT Buffer@{Flash RTT Buffer}!RTT\_EraseFlash@{RTT\_EraseFlash}} \index{RTT\_EraseFlash@{RTT\_EraseFlash}!Flash RTT Buffer@{Flash RTT Buffer}} \doxysubsubsubsubsubsection{\texorpdfstring{RTT\_EraseFlash()}{RTT\_EraseFlash()}} -{\footnotesize\ttfamily \+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE int RTT\+\_\+\+Erase\+Flash (\begin{DoxyParamCaption}\item[{void}]{ }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1} +\+\_\+\+\_\+\+STATIC\+\_\+\+FORCEINLINE int RTT\+\_\+\+Erase\+Flash (\begin{DoxyParamCaption}\item[{void}]{}{}\end{DoxyParamCaption})} @@ -145,5 +147,5 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00311}{311}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00375}{375}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00388}{388}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. diff --git a/Doc/latex/group___t_r_a_c_e___s_e_r_i_a_l.tex b/Doc/latex/group___t_r_a_c_e___s_e_r_i_a_l.tex index be600cd..ac7dce5 100644 --- a/Doc/latex/group___t_r_a_c_e___s_e_r_i_a_l.tex +++ b/Doc/latex/group___t_r_a_c_e___s_e_r_i_a_l.tex @@ -1,4 +1,4 @@ -\doxysubsubsubsection{Serial trace defines} +\doxysubsubsubsection{Serial trace defines } \hypertarget{group___t_r_a_c_e___s_e_r_i_a_l}{}\label{group___t_r_a_c_e___s_e_r_i_a_l}\index{Serial trace defines@{Serial trace defines}} @@ -15,10 +15,10 @@ Collaboration diagram for Serial trace defines\+:\nopagebreak \doxysubsubsubsubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\+\_\+printf}}(...)~SEGGER\+\_\+\+RTT\+\_\+printf(0, \+\_\+\+\_\+\+VA\+\_\+\+ARGS\+\_\+\+\_\+) +\#define \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\+\_\+printf}}(...) \begin{DoxyCompactList}\small\item\em Универсальный макрос для вывода трассировки \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26}{log\+\_\+printf}}(TAG, fmt, ...) -\begin{DoxyCompactList}\small\item\em Макрос логирования с поддержкой уровней LOG\+\_\+\+LEVEL. \end{DoxyCompactList}\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Макрос логирования с поддержкой уровней \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05}{LOG\+\_\+\+LEVEL}. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsubsubsection{Detailed Description} @@ -27,18 +27,22 @@ Collaboration diagram for Serial trace defines\+:\nopagebreak В зависимости от настроек определяется дефайн \doxylink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\+\_\+printf()} и \doxylink{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26}{log\+\_\+printf()} для работы с трассировкой\+: \begin{DoxyItemize} \item \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga76936505ca200d2e61226b7ba68f27c6}{SERIAL\+\_\+\+TRACE\+\_\+\+ENABLE} -\/ Если трассировка отключена, то все дефайны определяются как \textquotesingle{}ничего\textquotesingle{} и на производительность кода не влияют -\item \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga00ff2175bdc1fb11c8ec970ea3010dd8}{RTT\+\_\+\+TRACE\+\_\+\+ENABLE} -\/ для RTT это будет вызов функции SEGGER\+\_\+\+RTT\+\_\+printf(), с подключением библиотеки SEGGER\+\_\+\+RTT.\+h Предварительно надо подключить библиотеку SEGGER RTT и вызвать функцию SEGGER\+\_\+\+RTT\+\_\+\+Init() +\item \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga00ff2175bdc1fb11c8ec970ea3010dd8}{RTT\+\_\+\+TRACE\+\_\+\+ENABLE} -\/ для RTT это будет вызов функции SEGGER\+\_\+\+RTT\+\_\+printf() + +Предварительно надо подключить библиотеку SEGGER RTT (SEGGER\+\_\+\+RTT.\+h) и вызвать функцию SEGGER\+\_\+\+RTT\+\_\+\+Init() \item \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_gab8db9704b5d11858aa879689b9d36336}{SWO\+\_\+\+TRACE\+\_\+\+ENABLE} для SWO это будет просто printf() -Но библиотеку STDOUT надо подключить самостоятельно\+: +Предварительно надо подключить библиотеку STDOUT и retarget под ITM\+: -\begin{DoxyVerb} Manage Run-Time Environment -> Compiler -> I/O -> STDOUT \end{DoxyVerb} +\begin{DoxyVerb} Manage Run-Time Environment -> Compiler -> I/O -> STDOUT -> ITM +\end{DoxyVerb} Для SWO также надо включить трассировку\+: ~\newline -\begin{DoxyVerb} Options For Target -> Debug -> Debugger Settings\end{DoxyVerb} +\begin{DoxyVerb} Options For Target -> Debug -> Debugger Settings +\end{DoxyVerb} В вкладке Debug\+: @@ -46,18 +50,24 @@ Collaboration diagram for Serial trace defines\+:\nopagebreak \item Port = SW В вкладке Trace\+: \item Указать Core Clock \item Выставить Trace Port = SWO -\item ITM -\/ выбрать нужный порт (для Keil нулевой порт) ~\newline - +\item ITM -\/ выбрать нужный порт (для Keil нулевой порт) \end{DoxyItemize} \end{DoxyItemize} +\label{doc-define-members} +\Hypertarget{group___t_r_a_c_e___s_e_r_i_a_l_doc-define-members} \doxysubsubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}\label{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa} -\index{Serial trace defines@{Serial trace defines}!my\_printf@{my\_printf}} +\Hypertarget{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}\index{Serial trace defines@{Serial trace defines}!my\_printf@{my\_printf}} \index{my\_printf@{my\_printf}!Serial trace defines@{Serial trace defines}} \doxysubsubsubsubsubsection{\texorpdfstring{my\_printf}{my\_printf}} -{\footnotesize\ttfamily \#define my\+\_\+printf(\begin{DoxyParamCaption}\item[{}]{... }\end{DoxyParamCaption})~SEGGER\+\_\+\+RTT\+\_\+printf(0, \+\_\+\+\_\+\+VA\+\_\+\+ARGS\+\_\+\+\_\+)} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa} +\#define my\+\_\+printf(\begin{DoxyParamCaption}\item[{}]{}...{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{SEGGER\_RTT\_printf(0,\ \_\_VA\_ARGS\_\_)} + +\end{DoxyCode} Универсальный макрос для вывода трассировки @@ -69,23 +79,23 @@ Collaboration diagram for Serial trace defines\+:\nopagebreak \item NO\+\_\+\+TRACE -\/ пустой макрос \end{DoxyItemize} -Definition at line \mbox{\hyperlink{trace_8h_source_l00071}{71}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00080}{80}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26}\label{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26} -\index{Serial trace defines@{Serial trace defines}!log\_printf@{log\_printf}} +\Hypertarget{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26}\index{Serial trace defines@{Serial trace defines}!log\_printf@{log\_printf}} \index{log\_printf@{log\_printf}!Serial trace defines@{Serial trace defines}} \doxysubsubsubsubsubsection{\texorpdfstring{log\_printf}{log\_printf}} -{\footnotesize\ttfamily \#define log\+\_\+printf(\begin{DoxyParamCaption}\item[{}]{TAG, }\item[{}]{fmt, }\item[{}]{... }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26} +\#define log\+\_\+printf(\begin{DoxyParamCaption}\item[{}]{TAG}{, }\item[{}]{fmt}{, }\item[{}]{}...{}\end{DoxyParamCaption})} {\bfseries Value\+:} \begin{DoxyCode}{0} \DoxyCodeLine{\mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\(\backslash\)n[\%lu]\ [\%s]\ "{}}\ fmt,\ \(\backslash\)} -\DoxyCodeLine{(\textcolor{keywordtype}{unsigned}\ \textcolor{keywordtype}{long})uwTick,\ TAG,\ \#\#\_\_VA\_ARGS\_\_)} +\DoxyCodeLine{(\textcolor{keywordtype}{unsigned}\ \textcolor{keywordtype}{long})\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\_time}}(),\ TAG,\ \#\#\_\_VA\_ARGS\_\_)} \end{DoxyCode} -Макрос логирования с поддержкой уровней LOG\+\_\+\+LEVEL. +Макрос логирования с поддержкой уровней \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05}{LOG\+\_\+\+LEVEL}. \begin{DoxyParams}{Parameters} @@ -96,10 +106,22 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00071}{71}} of file \mbox{\ \end{DoxyParams} Варианты реализации\+: \begin{DoxyItemize} -\item LOG\+\_\+\+LEVEL == 0 -\/ логирование отключено (макрос пустой) -\item LOG\+\_\+\+LEVEL == 1 -\/ выводится время и TAG -\item LOG\+\_\+\+LEVEL \texorpdfstring{$>$}{>}= 2 -\/ выводится время, TAG, имя файла и номер строки +\item \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05}{LOG\+\_\+\+LEVEL} == 0 -\/ логирование отключено (макрос пустой) +\item \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05}{LOG\+\_\+\+LEVEL} == 1 -\/ выводится время \doxylink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\+\_\+time} и TAG +\begin{DoxyCode}{0} +\DoxyCodeLine{[123]\ [ADC]\ Measure\ Done} +\DoxyCodeLine{[456]\ [ADC]\ Measure\ Err} + +\end{DoxyCode} + +\item \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05}{LOG\+\_\+\+LEVEL} \texorpdfstring{$>$}{>}= 2 -\/ выводится время, TAG, имя файла и номер строки +\begin{DoxyCode}{0} +\DoxyCodeLine{[123]\ [ADC]\ (../Core/Src/adc.c:75)\ Measure\ Done} +\DoxyCodeLine{[456]\ [ADC]\ (../Core/Src/adc.c:80)\ Measure\ Err} + +\end{DoxyCode} + \end{DoxyItemize} -Definition at line \mbox{\hyperlink{trace_8h_source_l00096}{96}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00109}{109}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. diff --git a/Doc/latex/group___t_r_a_c_k_e_r_s.tex b/Doc/latex/group___t_r_a_c_k_e_r_s.tex index 8d342a4..9f4c6e3 100644 --- a/Doc/latex/group___t_r_a_c_k_e_r_s.tex +++ b/Doc/latex/group___t_r_a_c_k_e_r_s.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Trackers defines} +\doxysubsubsection{Trackers defines } \hypertarget{group___t_r_a_c_k_e_r_s}{}\label{group___t_r_a_c_k_e_r_s}\index{Trackers defines@{Trackers defines}} @@ -17,43 +17,43 @@ Collaboration diagram for Trackers defines\+:\nopagebreak \item \#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga50ccb119acf302969b7fdcb58f2130e4}{Tracker\+Type\+Def}}(num\+\_\+user\+\_\+vars) \begin{DoxyCompactList}\small\item\em Структура для счетчиков отладки \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}{num\+\_\+of\+\_\+usercnts}}(\+\_\+user\+\_\+)~(sizeof(\+\_\+user\+\_\+) / sizeof(uint32\+\_\+t)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}{num\+\_\+of\+\_\+usercnts}}(\+\_\+user\+\_\+) \begin{DoxyCompactList}\small\item\em Получить количетство пользовательских переменных \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~((\+\_\+uservarnumb\+\_\+) $<$ \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}{num\+\_\+of\+\_\+usercnts}}((\+\_\+cntstruct\+\_\+).user)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Проверка существует ли указанная пользовательская переменная \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~if(\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Условие для проверки существует ли указанная пользовательская переменная \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}{tern\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~(\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)) ? \+\_\+uservarnumb\+\_\+ \+: 0 +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}{tern\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Тернарный оператор для проверки существует ли указанная пользовательская переменная \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gab880911066605602a966641682090169}{Tracker\+Get\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gab880911066605602a966641682090169}{Tracker\+Get\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Считать счетчик успешных событий \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga9dc91e6b798a081f95f2ccef2c288e5e}{Tracker\+Get\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga9dc91e6b798a081f95f2ccef2c288e5e}{Tracker\+Get\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Считать счетчик ошибок \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga47ac59a406ee74d4cd9fe0fbaf63a758}{Tracker\+Get\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga47ac59a406ee74d4cd9fe0fbaf63a758}{Tracker\+Get\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Считать счетчик предупреждений \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga4b08632669043dfdbd219dda03502bdb}{Tracker\+Get\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~(\+\_\+cntstruct\+\_\+).user\mbox{[}\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}{tern\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)\mbox{]} +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga4b08632669043dfdbd219dda03502bdb}{Tracker\+Get\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Считать пользовательскую переменную \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga23de0006aa08984cfeddb6aa5e512fa1}{Tracker\+Cnt\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok++ +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga23de0006aa08984cfeddb6aa5e512fa1}{Tracker\+Cnt\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Инкрементирование счетчика успешных событий \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga49af29ab3927cad105c1d2b018a767e9}{Tracker\+Cnt\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err++ +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga49af29ab3927cad105c1d2b018a767e9}{Tracker\+Cnt\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Инкрементирование счетчика ошибок \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga8017fb05a56a1b667244f1f786fa9c57}{Tracker\+Cnt\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn++ +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga8017fb05a56a1b667244f1f786fa9c57}{Tracker\+Cnt\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Инкрементирование счетчика предупреждений \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga1b7549afc4a1760b54a9b93b0f6d105e}{Tracker\+Cnt\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]}++; +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga1b7549afc4a1760b54a9b93b0f6d105e}{Tracker\+Cnt\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Инкрементирование пользовательской переменной \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad2f4062a9ac8c2ab062a364f640ebc51}{Tracker\+Write\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+, \+\_\+val\+\_\+)~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]} = (\+\_\+val\+\_\+) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad2f4062a9ac8c2ab062a364f640ebc51}{Tracker\+Write\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+, \+\_\+val\+\_\+) \begin{DoxyCompactList}\small\item\em Запись числа в пользовательскую переменную \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga704f7b9f8c65c9bcec48ce7cb77a2d3b}{Tracker\+Clear\+\_\+\+All}}(\+\_\+cntstruct\+\_\+)~memset(\&(\+\_\+cntstruct\+\_\+), 0, sizeof(\+\_\+cntstruct\+\_\+)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga704f7b9f8c65c9bcec48ce7cb77a2d3b}{Tracker\+Clear\+\_\+\+All}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка всей структуры \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga5dd8bac8c7ab5832019d55d7a68371b9}{Tracker\+Clear\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok = 0 +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga5dd8bac8c7ab5832019d55d7a68371b9}{Tracker\+Clear\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка счетчика успешных событий \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74}{Tracker\+Clear\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err = 0 +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74}{Tracker\+Clear\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка счетчика ошибок \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead}{Tracker\+Clear\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn = 0 +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead}{Tracker\+Clear\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка счетчика предупреждений \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d}{Tracker\+Clear\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]} = 0; +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d}{Tracker\+Clear\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка пользовательской переменной \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5}{Tracker\+Clear\+\_\+\+User\+All}}(\+\_\+cntstruct\+\_\+)~memset(\&(\+\_\+cntstruct\+\_\+).user, 0, sizeof((\+\_\+cntstruct\+\_\+).user)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5}{Tracker\+Clear\+\_\+\+User\+All}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка всех пользовательских переменных \end{DoxyCompactList}\end{DoxyCompactItemize} @@ -111,17 +111,18 @@ Collaboration diagram for Trackers defines\+:\nopagebreak \item \doxylink{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74}{Tracker\+Clear\+\_\+\+Err()} \item \doxylink{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead}{Tracker\+Clear\+\_\+\+Warn()} \item \doxylink{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d}{Tracker\+Clear\+\_\+\+User(n)} -\item \doxylink{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5}{Tracker\+Clear\+\_\+\+User\+All()} ~\newline - +\item \doxylink{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5}{Tracker\+Clear\+\_\+\+User\+All()} \end{DoxyItemize} \end{DoxyItemize} +\label{doc-define-members} +\Hypertarget{group___t_r_a_c_k_e_r_s_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___t_r_a_c_k_e_r_s_ga50ccb119acf302969b7fdcb58f2130e4}\label{group___t_r_a_c_k_e_r_s_ga50ccb119acf302969b7fdcb58f2130e4} -\index{Trackers defines@{Trackers defines}!TrackerTypeDef@{TrackerTypeDef}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga50ccb119acf302969b7fdcb58f2130e4}\index{Trackers defines@{Trackers defines}!TrackerTypeDef@{TrackerTypeDef}} \index{TrackerTypeDef@{TrackerTypeDef}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerTypeDef}{TrackerTypeDef}} -{\footnotesize\ttfamily \#define Tracker\+Type\+Def(\begin{DoxyParamCaption}\item[{}]{num\+\_\+user\+\_\+vars }\end{DoxyParamCaption})} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga50ccb119acf302969b7fdcb58f2130e4} +\#define Tracker\+Type\+Def(\begin{DoxyParamCaption}\item[{}]{num\+\_\+user\+\_\+vars}{}\end{DoxyParamCaption})} {\bfseries Value\+:} \begin{DoxyCode}{0} @@ -149,12 +150,17 @@ Collaboration diagram for Trackers defines\+:\nopagebreak Definition at line \mbox{\hyperlink{trackers_8h_source_l00070}{70}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}\label{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc} -\index{Trackers defines@{Trackers defines}!num\_of\_usercnts@{num\_of\_usercnts}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}\index{Trackers defines@{Trackers defines}!num\_of\_usercnts@{num\_of\_usercnts}} \index{num\_of\_usercnts@{num\_of\_usercnts}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{num\_of\_usercnts}{num\_of\_usercnts}} -{\footnotesize\ttfamily \#define num\+\_\+of\+\_\+usercnts(\begin{DoxyParamCaption}\item[{}]{\+\_\+user\+\_\+ }\end{DoxyParamCaption})~(sizeof(\+\_\+user\+\_\+) / sizeof(uint32\+\_\+t))} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc} +\#define num\+\_\+of\+\_\+usercnts(\begin{DoxyParamCaption}\item[{}]{\+\_\+user\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\textcolor{keyword}{sizeof}(\_user\_)\ /\ \textcolor{keyword}{sizeof}(uint32\_t))} + +\end{DoxyCode} Получить количетство пользовательских переменных @@ -163,12 +169,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00070}{70}} of file \mbo Definition at line \mbox{\hyperlink{trackers_8h_source_l00080}{80}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}\label{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e} -\index{Trackers defines@{Trackers defines}!assert\_usertracker@{assert\_usertracker}} +\Hypertarget{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}\index{Trackers defines@{Trackers defines}!assert\_usertracker@{assert\_usertracker}} \index{assert\_usertracker@{assert\_usertracker}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{assert\_usertracker}{assert\_usertracker}} -{\footnotesize\ttfamily \#define assert\+\_\+usertracker(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+, }\item[{}]{\+\_\+uservarnumb\+\_\+ }\end{DoxyParamCaption})~((\+\_\+uservarnumb\+\_\+) $<$ \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}{num\+\_\+of\+\_\+usercnts}}((\+\_\+cntstruct\+\_\+).user))} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e} +\#define assert\+\_\+usertracker(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{, }\item[{}]{\+\_\+uservarnumb\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{((\_uservarnumb\_)\ <\ \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}{num\_of\_usercnts}}((\_cntstruct\_).user))} + +\end{DoxyCode} Проверка существует ли указанная пользовательская переменная @@ -177,12 +188,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00080}{80}} of file \mbo Definition at line \mbox{\hyperlink{trackers_8h_source_l00082}{82}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}\label{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07} -\index{Trackers defines@{Trackers defines}!if\_assert\_usertracker@{if\_assert\_usertracker}} +\Hypertarget{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}\index{Trackers defines@{Trackers defines}!if\_assert\_usertracker@{if\_assert\_usertracker}} \index{if\_assert\_usertracker@{if\_assert\_usertracker}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{if\_assert\_usertracker}{if\_assert\_usertracker}} -{\footnotesize\ttfamily \#define if\+\_\+assert\+\_\+usertracker(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+, }\item[{}]{\+\_\+uservarnumb\+\_\+ }\end{DoxyParamCaption})~if(\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+))} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07} +\#define if\+\_\+assert\+\_\+usertracker(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{, }\item[{}]{\+\_\+uservarnumb\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{\textcolor{keywordflow}{if}(\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\_usertracker}}(\_cntstruct\_,\ \_uservarnumb\_))} + +\end{DoxyCode} Условие для проверки существует ли указанная пользовательская переменная @@ -191,12 +207,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00082}{82}} of file \mbo Definition at line \mbox{\hyperlink{trackers_8h_source_l00084}{84}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}\label{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30} -\index{Trackers defines@{Trackers defines}!tern\_assert\_usertracker@{tern\_assert\_usertracker}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}\index{Trackers defines@{Trackers defines}!tern\_assert\_usertracker@{tern\_assert\_usertracker}} \index{tern\_assert\_usertracker@{tern\_assert\_usertracker}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{tern\_assert\_usertracker}{tern\_assert\_usertracker}} -{\footnotesize\ttfamily \#define tern\+\_\+assert\+\_\+usertracker(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+, }\item[{}]{\+\_\+uservarnumb\+\_\+ }\end{DoxyParamCaption})~(\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)) ? \+\_\+uservarnumb\+\_\+ \+: 0} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30} +\#define tern\+\_\+assert\+\_\+usertracker(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{, }\item[{}]{\+\_\+uservarnumb\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\_usertracker}}(\_cntstruct\_,\ \_uservarnumb\_))\ ?\ \_uservarnumb\_\ :\ 0} + +\end{DoxyCode} Тернарный оператор для проверки существует ли указанная пользовательская переменная @@ -205,12 +226,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00084}{84}} of file \mbo Definition at line \mbox{\hyperlink{trackers_8h_source_l00086}{86}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_gab880911066605602a966641682090169}\label{group___t_r_a_c_k_e_r_s_gab880911066605602a966641682090169} -\index{Trackers defines@{Trackers defines}!TrackerGet\_Ok@{TrackerGet\_Ok}} +\Hypertarget{group___t_r_a_c_k_e_r_s_gab880911066605602a966641682090169}\index{Trackers defines@{Trackers defines}!TrackerGet\_Ok@{TrackerGet\_Ok}} \index{TrackerGet\_Ok@{TrackerGet\_Ok}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerGet\_Ok}{TrackerGet\_Ok}} -{\footnotesize\ttfamily \#define Tracker\+Get\+\_\+\+Ok(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_gab880911066605602a966641682090169} +\#define Tracker\+Get\+\_\+\+Ok(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_ok} + +\end{DoxyCode} Считать счетчик успешных событий @@ -219,12 +245,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00086}{86}} of file \mbo Definition at line \mbox{\hyperlink{trackers_8h_source_l00090}{90}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga9dc91e6b798a081f95f2ccef2c288e5e}\label{group___t_r_a_c_k_e_r_s_ga9dc91e6b798a081f95f2ccef2c288e5e} -\index{Trackers defines@{Trackers defines}!TrackerGet\_Err@{TrackerGet\_Err}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga9dc91e6b798a081f95f2ccef2c288e5e}\index{Trackers defines@{Trackers defines}!TrackerGet\_Err@{TrackerGet\_Err}} \index{TrackerGet\_Err@{TrackerGet\_Err}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerGet\_Err}{TrackerGet\_Err}} -{\footnotesize\ttfamily \#define Tracker\+Get\+\_\+\+Err(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga9dc91e6b798a081f95f2ccef2c288e5e} +\#define Tracker\+Get\+\_\+\+Err(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_err} + +\end{DoxyCode} Считать счетчик ошибок @@ -233,12 +264,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00090}{90}} of file \mbo Definition at line \mbox{\hyperlink{trackers_8h_source_l00092}{92}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga47ac59a406ee74d4cd9fe0fbaf63a758}\label{group___t_r_a_c_k_e_r_s_ga47ac59a406ee74d4cd9fe0fbaf63a758} -\index{Trackers defines@{Trackers defines}!TrackerGet\_Warn@{TrackerGet\_Warn}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga47ac59a406ee74d4cd9fe0fbaf63a758}\index{Trackers defines@{Trackers defines}!TrackerGet\_Warn@{TrackerGet\_Warn}} \index{TrackerGet\_Warn@{TrackerGet\_Warn}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerGet\_Warn}{TrackerGet\_Warn}} -{\footnotesize\ttfamily \#define Tracker\+Get\+\_\+\+Warn(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga47ac59a406ee74d4cd9fe0fbaf63a758} +\#define Tracker\+Get\+\_\+\+Warn(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_warn} + +\end{DoxyCode} Считать счетчик предупреждений @@ -247,12 +283,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00092}{92}} of file \mbo Definition at line \mbox{\hyperlink{trackers_8h_source_l00094}{94}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga4b08632669043dfdbd219dda03502bdb}\label{group___t_r_a_c_k_e_r_s_ga4b08632669043dfdbd219dda03502bdb} -\index{Trackers defines@{Trackers defines}!TrackerGet\_User@{TrackerGet\_User}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga4b08632669043dfdbd219dda03502bdb}\index{Trackers defines@{Trackers defines}!TrackerGet\_User@{TrackerGet\_User}} \index{TrackerGet\_User@{TrackerGet\_User}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerGet\_User}{TrackerGet\_User}} -{\footnotesize\ttfamily \#define Tracker\+Get\+\_\+\+User(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+, }\item[{}]{\+\_\+uservarnumb\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).user\mbox{[}\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}{tern\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)\mbox{]}} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga4b08632669043dfdbd219dda03502bdb} +\#define Tracker\+Get\+\_\+\+User(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{, }\item[{}]{\+\_\+uservarnumb\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).user[\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}{tern\_assert\_usertracker}}(\_cntstruct\_,\ \_uservarnumb\_)]} + +\end{DoxyCode} Считать пользовательскую переменную @@ -268,12 +309,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00094}{94}} of file \mbo Definition at line \mbox{\hyperlink{trackers_8h_source_l00106}{106}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga23de0006aa08984cfeddb6aa5e512fa1}\label{group___t_r_a_c_k_e_r_s_ga23de0006aa08984cfeddb6aa5e512fa1} -\index{Trackers defines@{Trackers defines}!TrackerCnt\_Ok@{TrackerCnt\_Ok}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga23de0006aa08984cfeddb6aa5e512fa1}\index{Trackers defines@{Trackers defines}!TrackerCnt\_Ok@{TrackerCnt\_Ok}} \index{TrackerCnt\_Ok@{TrackerCnt\_Ok}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerCnt\_Ok}{TrackerCnt\_Ok}} -{\footnotesize\ttfamily \#define Tracker\+Cnt\+\_\+\+Ok(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok++} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga23de0006aa08984cfeddb6aa5e512fa1} +\#define Tracker\+Cnt\+\_\+\+Ok(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_ok++} + +\end{DoxyCode} Инкрементирование счетчика успешных событий @@ -282,12 +328,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00106}{106}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00111}{111}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga49af29ab3927cad105c1d2b018a767e9}\label{group___t_r_a_c_k_e_r_s_ga49af29ab3927cad105c1d2b018a767e9} -\index{Trackers defines@{Trackers defines}!TrackerCnt\_Err@{TrackerCnt\_Err}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga49af29ab3927cad105c1d2b018a767e9}\index{Trackers defines@{Trackers defines}!TrackerCnt\_Err@{TrackerCnt\_Err}} \index{TrackerCnt\_Err@{TrackerCnt\_Err}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerCnt\_Err}{TrackerCnt\_Err}} -{\footnotesize\ttfamily \#define Tracker\+Cnt\+\_\+\+Err(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err++} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga49af29ab3927cad105c1d2b018a767e9} +\#define Tracker\+Cnt\+\_\+\+Err(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_err++} + +\end{DoxyCode} Инкрементирование счетчика ошибок @@ -296,12 +347,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00111}{111}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00113}{113}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga8017fb05a56a1b667244f1f786fa9c57}\label{group___t_r_a_c_k_e_r_s_ga8017fb05a56a1b667244f1f786fa9c57} -\index{Trackers defines@{Trackers defines}!TrackerCnt\_Warn@{TrackerCnt\_Warn}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga8017fb05a56a1b667244f1f786fa9c57}\index{Trackers defines@{Trackers defines}!TrackerCnt\_Warn@{TrackerCnt\_Warn}} \index{TrackerCnt\_Warn@{TrackerCnt\_Warn}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerCnt\_Warn}{TrackerCnt\_Warn}} -{\footnotesize\ttfamily \#define Tracker\+Cnt\+\_\+\+Warn(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn++} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga8017fb05a56a1b667244f1f786fa9c57} +\#define Tracker\+Cnt\+\_\+\+Warn(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_warn++} + +\end{DoxyCode} Инкрементирование счетчика предупреждений @@ -310,12 +366,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00113}{113}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00115}{115}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga1b7549afc4a1760b54a9b93b0f6d105e}\label{group___t_r_a_c_k_e_r_s_ga1b7549afc4a1760b54a9b93b0f6d105e} -\index{Trackers defines@{Trackers defines}!TrackerCnt\_User@{TrackerCnt\_User}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga1b7549afc4a1760b54a9b93b0f6d105e}\index{Trackers defines@{Trackers defines}!TrackerCnt\_User@{TrackerCnt\_User}} \index{TrackerCnt\_User@{TrackerCnt\_User}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerCnt\_User}{TrackerCnt\_User}} -{\footnotesize\ttfamily \#define Tracker\+Cnt\+\_\+\+User(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+, }\item[{}]{\+\_\+uservarnumb\+\_\+ }\end{DoxyParamCaption})~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]}++;} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga1b7549afc4a1760b54a9b93b0f6d105e} +\#define Tracker\+Cnt\+\_\+\+User(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{, }\item[{}]{\+\_\+uservarnumb\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\_assert\_usertracker}}(\_cntstruct\_,\ \_uservarnumb\_)\ (\_cntstruct\_).user[\_uservarnumb\_]++;} + +\end{DoxyCode} Инкрементирование пользовательской переменной @@ -324,12 +385,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00115}{115}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00117}{117}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_gad2f4062a9ac8c2ab062a364f640ebc51}\label{group___t_r_a_c_k_e_r_s_gad2f4062a9ac8c2ab062a364f640ebc51} -\index{Trackers defines@{Trackers defines}!TrackerWrite\_User@{TrackerWrite\_User}} +\Hypertarget{group___t_r_a_c_k_e_r_s_gad2f4062a9ac8c2ab062a364f640ebc51}\index{Trackers defines@{Trackers defines}!TrackerWrite\_User@{TrackerWrite\_User}} \index{TrackerWrite\_User@{TrackerWrite\_User}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerWrite\_User}{TrackerWrite\_User}} -{\footnotesize\ttfamily \#define Tracker\+Write\+\_\+\+User(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+, }\item[{}]{\+\_\+uservarnumb\+\_\+, }\item[{}]{\+\_\+val\+\_\+ }\end{DoxyParamCaption})~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]} = (\+\_\+val\+\_\+)} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_gad2f4062a9ac8c2ab062a364f640ebc51} +\#define Tracker\+Write\+\_\+\+User(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{, }\item[{}]{\+\_\+uservarnumb\+\_\+}{, }\item[{}]{\+\_\+val\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\_assert\_usertracker}}(\_cntstruct\_,\ \_uservarnumb\_)\ (\_cntstruct\_).user[\_uservarnumb\_]\ =\ (\_val\_)} + +\end{DoxyCode} Запись числа в пользовательскую переменную @@ -338,12 +404,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00117}{117}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00119}{119}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga704f7b9f8c65c9bcec48ce7cb77a2d3b}\label{group___t_r_a_c_k_e_r_s_ga704f7b9f8c65c9bcec48ce7cb77a2d3b} -\index{Trackers defines@{Trackers defines}!TrackerClear\_All@{TrackerClear\_All}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga704f7b9f8c65c9bcec48ce7cb77a2d3b}\index{Trackers defines@{Trackers defines}!TrackerClear\_All@{TrackerClear\_All}} \index{TrackerClear\_All@{TrackerClear\_All}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerClear\_All}{TrackerClear\_All}} -{\footnotesize\ttfamily \#define Tracker\+Clear\+\_\+\+All(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~memset(\&(\+\_\+cntstruct\+\_\+), 0, sizeof(\+\_\+cntstruct\+\_\+))} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga704f7b9f8c65c9bcec48ce7cb77a2d3b} +\#define Tracker\+Clear\+\_\+\+All(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{memset(\&(\_cntstruct\_),\ 0,\ \textcolor{keyword}{sizeof}(\_cntstruct\_))} + +\end{DoxyCode} Очистка всей структуры @@ -352,12 +423,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00119}{119}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00122}{122}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga5dd8bac8c7ab5832019d55d7a68371b9}\label{group___t_r_a_c_k_e_r_s_ga5dd8bac8c7ab5832019d55d7a68371b9} -\index{Trackers defines@{Trackers defines}!TrackerClear\_Ok@{TrackerClear\_Ok}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga5dd8bac8c7ab5832019d55d7a68371b9}\index{Trackers defines@{Trackers defines}!TrackerClear\_Ok@{TrackerClear\_Ok}} \index{TrackerClear\_Ok@{TrackerClear\_Ok}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerClear\_Ok}{TrackerClear\_Ok}} -{\footnotesize\ttfamily \#define Tracker\+Clear\+\_\+\+Ok(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok = 0} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga5dd8bac8c7ab5832019d55d7a68371b9} +\#define Tracker\+Clear\+\_\+\+Ok(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_ok\ =\ 0} + +\end{DoxyCode} Очистка счетчика успешных событий @@ -366,12 +442,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00122}{122}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00124}{124}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74}\label{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74} -\index{Trackers defines@{Trackers defines}!TrackerClear\_Err@{TrackerClear\_Err}} +\Hypertarget{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74}\index{Trackers defines@{Trackers defines}!TrackerClear\_Err@{TrackerClear\_Err}} \index{TrackerClear\_Err@{TrackerClear\_Err}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerClear\_Err}{TrackerClear\_Err}} -{\footnotesize\ttfamily \#define Tracker\+Clear\+\_\+\+Err(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err = 0} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74} +\#define Tracker\+Clear\+\_\+\+Err(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_err\ =\ 0} + +\end{DoxyCode} Очистка счетчика ошибок @@ -380,12 +461,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00124}{124}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00126}{126}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead}\label{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead} -\index{Trackers defines@{Trackers defines}!TrackerClear\_Warn@{TrackerClear\_Warn}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead}\index{Trackers defines@{Trackers defines}!TrackerClear\_Warn@{TrackerClear\_Warn}} \index{TrackerClear\_Warn@{TrackerClear\_Warn}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerClear\_Warn}{TrackerClear\_Warn}} -{\footnotesize\ttfamily \#define Tracker\+Clear\+\_\+\+Warn(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn = 0} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead} +\#define Tracker\+Clear\+\_\+\+Warn(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\_cntstruct\_).cnt\_warn\ =\ 0} + +\end{DoxyCode} Очистка счетчика предупреждений @@ -394,12 +480,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00126}{126}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00128}{128}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d}\label{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d} -\index{Trackers defines@{Trackers defines}!TrackerClear\_User@{TrackerClear\_User}} +\Hypertarget{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d}\index{Trackers defines@{Trackers defines}!TrackerClear\_User@{TrackerClear\_User}} \index{TrackerClear\_User@{TrackerClear\_User}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerClear\_User}{TrackerClear\_User}} -{\footnotesize\ttfamily \#define Tracker\+Clear\+\_\+\+User(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+, }\item[{}]{\+\_\+uservarnumb\+\_\+ }\end{DoxyParamCaption})~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]} = 0;} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d} +\#define Tracker\+Clear\+\_\+\+User(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{, }\item[{}]{\+\_\+uservarnumb\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\_assert\_usertracker}}(\_cntstruct\_,\ \_uservarnumb\_)\ (\_cntstruct\_).user[\_uservarnumb\_]\ =\ 0;} + +\end{DoxyCode} Очистка пользовательской переменной @@ -408,12 +499,17 @@ Definition at line \mbox{\hyperlink{trackers_8h_source_l00128}{128}} of file \mb Definition at line \mbox{\hyperlink{trackers_8h_source_l00130}{130}} of file \mbox{\hyperlink{trackers_8h_source}{trackers.\+h}}. -\Hypertarget{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5}\label{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5} -\index{Trackers defines@{Trackers defines}!TrackerClear\_UserAll@{TrackerClear\_UserAll}} +\Hypertarget{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5}\index{Trackers defines@{Trackers defines}!TrackerClear\_UserAll@{TrackerClear\_UserAll}} \index{TrackerClear\_UserAll@{TrackerClear\_UserAll}!Trackers defines@{Trackers defines}} \doxysubsubsubsubsection{\texorpdfstring{TrackerClear\_UserAll}{TrackerClear\_UserAll}} -{\footnotesize\ttfamily \#define Tracker\+Clear\+\_\+\+User\+All(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+ }\end{DoxyParamCaption})~memset(\&(\+\_\+cntstruct\+\_\+).user, 0, sizeof((\+\_\+cntstruct\+\_\+).user))} +{\footnotesize\ttfamily \label{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5} +\#define Tracker\+Clear\+\_\+\+User\+All(\begin{DoxyParamCaption}\item[{}]{\+\_\+cntstruct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{memset(\&(\_cntstruct\_).user,\ 0,\ \textcolor{keyword}{sizeof}((\_cntstruct\_).user))} + +\end{DoxyCode} Очистка всех пользовательских переменных diff --git a/Doc/latex/group___u_t_i_l_s___d_e_f_i_n_e_s.tex b/Doc/latex/group___u_t_i_l_s___d_e_f_i_n_e_s.tex index 58c3c5a..956f6f4 100644 --- a/Doc/latex/group___u_t_i_l_s___d_e_f_i_n_e_s.tex +++ b/Doc/latex/group___u_t_i_l_s___d_e_f_i_n_e_s.tex @@ -1,4 +1,4 @@ -\doxysubsubsection{Utils defines} +\doxysubsubsection{Utils defines } \hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s}{}\label{group___u_t_i_l_s___d_e_f_i_n_e_s}\index{Utils defines@{Utils defines}} @@ -15,13 +15,13 @@ Collaboration diagram for Utils defines\+:\nopagebreak \doxysubsubsubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be}{Clear\+Struct}}(\+\_\+struct\+\_\+)~memset(\&(\+\_\+struct\+\_\+), 0, sizeof(\+\_\+struct\+\_\+)) +\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be}{Clear\+Struct}}(\+\_\+struct\+\_\+) \begin{DoxyCompactList}\small\item\em Обнуление структуры. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e}{Divide\+\_\+\+Up}}(\+\_\+val\+\_\+, \+\_\+div\+\_\+)~((\+\_\+val\+\_\+ -\/ 1) / \+\_\+div\+\_\+) + 1 /\texorpdfstring{$\ast$}{*} через мат выражение \texorpdfstring{$\ast$}{*}/ +\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e}{Divide\+\_\+\+Up}}(\+\_\+val\+\_\+, \+\_\+div\+\_\+) \begin{DoxyCompactList}\small\item\em Деление с округлением вверх \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291}{Byte\+Swap16}}(v)~(((v\&0x\+FF00) $>$$>$ (8)) \texorpdfstring{$\vert$}{|} ((v\&0x00\+FF) $<$$<$ (8))) +\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291}{Byte\+Swap16}}(v) \begin{DoxyCompactList}\small\item\em Swap between Little Endian and Big Endian. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759}{ABS}}(x)~( ((x) $>$ 0)? (x) \+: -\/(x)) +\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759}{ABS}}(x) \begin{DoxyCompactList}\small\item\em Абсолютное значение числа \end{DoxyCompactList}\end{DoxyCompactItemize} @@ -30,13 +30,20 @@ Collaboration diagram for Utils defines\+:\nopagebreak +\label{doc-define-members} +\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_doc-define-members} \doxysubsubsubsection{Macro Definition Documentation} -\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be}\label{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be} -\index{Utils defines@{Utils defines}!ClearStruct@{ClearStruct}} +\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be}\index{Utils defines@{Utils defines}!ClearStruct@{ClearStruct}} \index{ClearStruct@{ClearStruct}!Utils defines@{Utils defines}} \doxysubsubsubsubsection{\texorpdfstring{ClearStruct}{ClearStruct}} -{\footnotesize\ttfamily \#define Clear\+Struct(\begin{DoxyParamCaption}\item[{}]{\+\_\+struct\+\_\+ }\end{DoxyParamCaption})~memset(\&(\+\_\+struct\+\_\+), 0, sizeof(\+\_\+struct\+\_\+))} +{\footnotesize\ttfamily \label{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be} +\#define Clear\+Struct(\begin{DoxyParamCaption}\item[{}]{\+\_\+struct\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{memset(\&(\_struct\_),\ 0,\ \textcolor{keyword}{sizeof}(\_struct\_))} + +\end{DoxyCode} Обнуление структуры. @@ -48,14 +55,19 @@ Collaboration diagram for Utils defines\+:\nopagebreak \end{DoxyParams} Макрос использует memset для обнуления всей памяти структуры. Используется для быстрой и безопасной инициализации переменных структур до нуля. -Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00151}{151}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00155}{155}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e}\label{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e} -\index{Utils defines@{Utils defines}!Divide\_Up@{Divide\_Up}} +\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e}\index{Utils defines@{Utils defines}!Divide\_Up@{Divide\_Up}} \index{Divide\_Up@{Divide\_Up}!Utils defines@{Utils defines}} \doxysubsubsubsubsection{\texorpdfstring{Divide\_Up}{Divide\_Up}} -{\footnotesize\ttfamily \#define Divide\+\_\+\+Up(\begin{DoxyParamCaption}\item[{}]{\+\_\+val\+\_\+, }\item[{}]{\+\_\+div\+\_\+ }\end{DoxyParamCaption})~((\+\_\+val\+\_\+ -\/ 1) / \+\_\+div\+\_\+) + 1 /\texorpdfstring{$\ast$}{*} через мат выражение \texorpdfstring{$\ast$}{*}/} +{\footnotesize\ttfamily \label{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e} +\#define Divide\+\_\+\+Up(\begin{DoxyParamCaption}\item[{}]{\+\_\+val\+\_\+}{, }\item[{}]{\+\_\+div\+\_\+}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{((\_val\_\ -\/\ 1)\ /\ \_div\_)\ +\ 1\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{/*\ через\ мат\ выражение\ */}} + +\end{DoxyCode} Деление с округлением вверх @@ -72,14 +84,19 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00151}{151}} of file \end{DoxyReturn} Если результат деления без остатка\+: он возвращается как есть Если с остатком -\/ округляется вверх -Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00162}{162}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00166}{166}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291}\label{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291} -\index{Utils defines@{Utils defines}!ByteSwap16@{ByteSwap16}} +\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291}\index{Utils defines@{Utils defines}!ByteSwap16@{ByteSwap16}} \index{ByteSwap16@{ByteSwap16}!Utils defines@{Utils defines}} \doxysubsubsubsubsection{\texorpdfstring{ByteSwap16}{ByteSwap16}} -{\footnotesize\ttfamily \#define Byte\+Swap16(\begin{DoxyParamCaption}\item[{}]{v }\end{DoxyParamCaption})~(((v\&0x\+FF00) $>$$>$ (8)) \texorpdfstring{$\vert$}{|} ((v\&0x00\+FF) $<$$<$ (8)))} +{\footnotesize\ttfamily \label{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291} +\#define Byte\+Swap16(\begin{DoxyParamCaption}\item[{}]{v}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(((v\&0xFF00)\ >>\ (8))\ |\ ((v\&0x00FF)\ <<\ (8)))} + +\end{DoxyCode} Swap between Little Endian and Big Endian. @@ -94,14 +111,19 @@ Swap between Little Endian and Big Endian. \end{DoxyReturn} Переключения между двумя типами хранения слова\+: HI-\/\+LO байты и LO-\/\+HI байты. -Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00170}{170}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00174}{174}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. -\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759}\label{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759} -\index{Utils defines@{Utils defines}!ABS@{ABS}} +\Hypertarget{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759}\index{Utils defines@{Utils defines}!ABS@{ABS}} \index{ABS@{ABS}!Utils defines@{Utils defines}} \doxysubsubsubsubsection{\texorpdfstring{ABS}{ABS}} -{\footnotesize\ttfamily \#define ABS(\begin{DoxyParamCaption}\item[{}]{x }\end{DoxyParamCaption})~( ((x) $>$ 0)? (x) \+: -\/(x))} +{\footnotesize\ttfamily \label{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759} +\#define ABS(\begin{DoxyParamCaption}\item[{}]{x}{}\end{DoxyParamCaption})} +{\bfseries Value\+:} +\begin{DoxyCode}{0} +\DoxyCodeLine{(\ ((x)\ >\ 0)?\ (x)\ :\ -\/(x))} + +\end{DoxyCode} Абсолютное значение числа @@ -116,5 +138,5 @@ Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00170}{170}} of file \end{DoxyReturn} Берет число по модулю. Хз как работает библиотечный abs в stdlib.\+h, мб это быстрее, но вряд ли конечно. -Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00178}{178}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. +Definition at line \mbox{\hyperlink{mylibs__defs_8h_source_l00182}{182}} of file \mbox{\hyperlink{mylibs__defs_8h_source}{mylibs\+\_\+defs.\+h}}. diff --git a/Doc/latex/index.tex b/Doc/latex/index.tex index 87fb315..ae07843 100644 --- a/Doc/latex/index.tex +++ b/Doc/latex/index.tex @@ -1,34 +1,42 @@ -\chapter{My\+Libs} +\chapter{My\+Libs } \hypertarget{index}{}\label{index}\index{MyLibs@{MyLibs}} \hypertarget{index_overview}{}\doxysection{\texorpdfstring{Обзор}{Обзор}}\label{index_overview} -My\+Libs -\/ это набор библиотек для удобной работы с периферией микроконтроллеров STM32.\hypertarget{index_features}{}\doxysubsection{\texorpdfstring{Основные возможности}{Основные возможности}}\label{index_features} -\hypertarget{index_utils_module}{}\doxysubsubsection{\texorpdfstring{Общие утилиты (\doxylink{group___m_y_l_i_b_s___d_e_f_i_n_e_s}{General Tools})}{Общие утилиты (\doxylink{group___m_y_l_i_b_s___d_e_f_i_n_e_s}{General Tools})}}\label{index_utils_module} +My\+Libs -\/ это набор библиотек для удобной работы с STM32.\hypertarget{index_features}{}\doxysubsection{\texorpdfstring{Основные возможности}{Основные возможности}}\label{index_features} +\hypertarget{index_utils_module}{}\doxysubsubsection{\texorpdfstring{Общие утилиты (\protect\doxylink{group___m_y_l_i_b_s___d_e_f_i_n_e_s}{General Tools})}{Общие утилиты ({General Tools})}}\label{index_utils_module} \begin{DoxyItemize} \item Макросы для задержек и утилит (\doxylink{group___d_e_l_a_y_s___d_e_f_i_n_e_s}{Delays defines} и \doxylink{group___u_t_i_l_s___d_e_f_i_n_e_s}{Utils defines}) \item Трекеры для статистики и отладки (\doxylink{group___t_r_a_c_k_e_r_s}{Trackers defines} и \doxylink{group___t_r_a_c_e}{Trace defines}) \item Эволюционный алгоритм для оптимизации параметров (\doxylink{group___e_v_o_l_v_e___o_p_t_i_m_i_z_e_r}{Evolve optimizer}) \item Битовый доступ к регистрам через union (\doxylink{group___b_i_t___a_c_c_e_s_s___d_e_f_i_n_e_s}{Bit access defines}) -\end{DoxyItemize}\hypertarget{index_trace_module}{}\doxysubsubsection{\texorpdfstring{Трассировка \doxylink{group___t_r_a_c_e}{Trace defines}}{Трассировка \doxylink{group___t_r_a_c_e}{Trace defines}}}\label{index_trace_module} +\end{DoxyItemize}\hypertarget{index_trace_module}{}\doxysubsubsection{\texorpdfstring{Трассировка \protect\doxylink{group___t_r_a_c_e}{Trace defines}}{Трассировка {Trace defines}}}\label{index_trace_module} \begin{DoxyItemize} \item Serial трассировка через SWO и RTT (\doxylink{group___t_r_a_c_e___s_e_r_i_a_l}{Serial trace defines}) \item GPIO трассировка для отладки (\doxylink{group___t_r_a_c_e___g_p_i_o}{GPIO trace defines}) \item Сохранение логов в Flash память (\doxylink{group___t_r_a_c_e___r_t_t___f_l_a_s_h}{Flash RTT Buffer}) \item Обработка Hard\+Fault с сохранением контекста (\doxylink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t}{Hardfault trace defines}) -\end{DoxyItemize}\hypertarget{index_gpio_module}{}\doxysubsubsection{\texorpdfstring{Модуль GPIO \doxylink{group___m_y___l_i_b_s___g_p_i_o}{GPIO Tools}}{Модуль GPIO \doxylink{group___m_y___l_i_b_s___g_p_i_o}{GPIO Tools}}}\label{index_gpio_module} +\end{DoxyItemize}\hypertarget{index_gpio_module}{}\doxysubsubsection{\texorpdfstring{Модуль GPIO \protect\doxylink{group___m_y___l_i_b_s___g_p_i_o}{GPIO Tools}}{Модуль GPIO {GPIO Tools}}}\label{index_gpio_module} \begin{DoxyItemize} \item Инициализация портов и тактирования (\doxylink{group___m_y_l_i_b_s___g_p_i_o___g_e_n_e_r_a_l}{General tools}) \item Управление светодиодами (включение/выключение, моргание, плавное затухание) (\doxylink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s}{LED tools}) \item Работа с кнопками (чтение состояния, фильтрация дребезга) (\doxylink{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h}{Switch tools}) -\end{DoxyItemize}\hypertarget{index_tim_module}{}\doxysubsubsection{\texorpdfstring{Модуль таймеров \doxylink{group___m_y___l_i_b_s___t_i_m}{TIM Tools}}{Модуль таймеров \doxylink{group___m_y___l_i_b_s___t_i_m}{TIM Tools}}}\label{index_tim_module} +\end{DoxyItemize}\hypertarget{index_tim_module}{}\doxysubsubsection{\texorpdfstring{Модуль таймеров \protect\doxylink{group___m_y___l_i_b_s___t_i_m}{TIM Tools}}{Модуль таймеров {TIM Tools}}}\label{index_tim_module} \begin{DoxyItemize} \item Базовая инициализация таймеров (\doxylink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l}{General tools}) \item Формирование задержек (блокирующие и неблокирующие) (\doxylink{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y}{Delay tools}) \item Работа с энкодерами (чтение положения, обработка кнопок) (\doxylink{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r}{Encoder tools}) \item Настройка ШИМ и Output Compare (\doxylink{group___m_y_l_i_b_s___t_i_m___o_c}{PWM/\+OC Channels tools}) +\end{DoxyItemize}\hypertarget{index_uart_module}{}\doxysubsubsection{\texorpdfstring{Модуль UART \protect\doxylink{group___m_y___l_i_b_s___u_a_r_t}{UART Tools}}{Модуль UART {UART Tools}}}\label{index_uart_module} + +\begin{DoxyItemize} +\item Базовая инициализация UART и его пинов одной функцией (\doxylink{group___m_y___l_i_b_s___u_a_r_t_gab9f07396b778505c934143e89953e154}{UART\+\_\+\+Base\+\_\+\+Init}) +\end{DoxyItemize}\hypertarget{index_spi_module}{}\doxysubsubsection{\texorpdfstring{Модуль SPI \protect\doxylink{group___m_y___l_i_b_s___s_p_i}{SPI Tools}}{Модуль SPI {SPI Tools}}}\label{index_spi_module} + +\begin{DoxyItemize} +\item Базовая инициализация SPI и пинов одной функцией (\doxylink{group___m_y___l_i_b_s___s_p_i_ga0e177e3c57a8fcdc73b5602e72ec66ba}{SPI\+\_\+\+Base\+\_\+\+Init}) \end{DoxyItemize}\hypertarget{index_structure}{}\doxysubsection{\texorpdfstring{Структура проекта}{Структура проекта}}\label{index_structure} \begin{DoxyCode}{0} @@ -37,13 +45,18 @@ My\+Libs -\/ это набор библиотек для удобной рабо \DoxyCodeLine{│\ \ \ ├──\ mylibs\_config.h\ \ \ \ \ \ \#\ Конфигурация\ библиотек} \DoxyCodeLine{│\ \ \ ├──\ mylibs\_defs.h\ \ \ \ \ \ \ \ \#\ Общие\ определения\ и\ макросы} \DoxyCodeLine{│\ \ \ ├──\ bit\_access.h\ \ \ \ \ \ \ \ \ \#\ Битовый\ доступ\ к\ регистрам} +\DoxyCodeLine{│\ \ \ ├──\ evolve\_optimizer.h\ \ \ \#\ Оптимизатор\ (генетический\ алгоритм)} \DoxyCodeLine{│\ \ \ ├──\ trackers.h\ \ \ \ \ \ \ \ \ \ \ \#\ Трекеры\ для\ отладки} \DoxyCodeLine{│\ \ \ ├──\ trace.h\ \ \ \ \ \ \ \ \ \ \ \ \ \ \#\ Трассировка\ и\ логирование} \DoxyCodeLine{│\ \ \ ├──\ general\_gpio.h\ \ \ \ \ \ \ \#\ Работа\ с\ GPIO} +\DoxyCodeLine{\ \ \ \ ├──\ general\_spi.h\ \ \ \ \ \ \ \ \#\ Работа\ с\ SPI} \DoxyCodeLine{│\ \ \ └──\ general\_tim.h\ \ \ \ \ \ \ \ \#\ Работа\ с\ таймерами} +\DoxyCodeLine{\ \ \ \ ├──\ general\_uart.h\ \ \ \ \ \ \ \#\ Работа\ с\ UART} \DoxyCodeLine{└──\ src/\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \#\ Исходные\ файлы} \DoxyCodeLine{\ \ \ \ ├──\ general\_gpio.c\ \ \ \ \ \ \ \#\ Реализация\ GPIO} +\DoxyCodeLine{\ \ \ \ ├──\ general\_spi.c\ \ \ \ \ \ \ \ \#\ Реализация\ SPI} \DoxyCodeLine{\ \ \ \ └──\ general\_tim.c\ \ \ \ \ \ \ \ \#\ Реализация\ TIM} +\DoxyCodeLine{\ \ \ \ ├──\ general\_uart.c\ \ \ \ \ \ \ \#\ Реализация\ UART} \end{DoxyCode} \hypertarget{index_usage_basic}{}\doxysubsection{\texorpdfstring{Использование}{Использование}}\label{index_usage_basic} @@ -58,46 +71,5 @@ My\+Libs -\/ это набор библиотек для удобной рабо \end{DoxyCode} -\item Используйте нужные модули в своем коде -\end{DoxyEnumerate}\hypertarget{index_gpio_example}{}\doxysubsubsection{\texorpdfstring{Пример работы с GPIO}{Пример работы с GPIO}}\label{index_gpio_example} - -\begin{DoxyCode}{0} -\DoxyCodeLine{\textcolor{comment}{//\ Инициализация\ светодиода}} -\DoxyCodeLine{MX\_GPIO\_Init();} -\DoxyCodeLine{\mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def}{GPIO\_LEDTypeDef}}\ led;} -\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gac936453c7a0841c0b17bcfdae4958084}{GPIO\_LED\_Init}}(\&led,\ GPIOA,\ GPIO\_PIN\_5,\ 1);} -\DoxyCodeLine{} -\DoxyCodeLine{\textcolor{comment}{//\ Включение\ светодиода}} -\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_ga4b9572949326b050694cd55d0a7e5f6c}{GPIO\_LED\_On}}(\&led);} -\DoxyCodeLine{} -\DoxyCodeLine{\textcolor{comment}{//\ Запуск\ моргания}} -\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaf22f44ecaf6a1932b47edc5a845b03a9}{GPIO\_LED\_Blink\_Start}}(\&led,\ 500);\ \textcolor{comment}{//\ Период\ 500\ мс}} -\DoxyCodeLine{} -\DoxyCodeLine{\textcolor{comment}{//\ В\ основном\ цикле}} -\DoxyCodeLine{\textcolor{keywordflow}{while}\ (1)\ \{} -\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gad6e6189824406c4d472b6340c7f19bb2}{GPIO\_LED\_Dynamic\_Handle}}(\&led);} -\DoxyCodeLine{\}} - -\end{DoxyCode} -\hypertarget{index_tim_example}{}\doxysubsubsection{\texorpdfstring{Пример работы с таймером}{Пример работы с таймером}}\label{index_tim_example} - -\begin{DoxyCode}{0} -\DoxyCodeLine{\textcolor{comment}{//\ Настройка\ таймера}} -\DoxyCodeLine{\mbox{\hyperlink{struct_t_i_m___settings_type_def}{TIM\_SettingsTypeDef}}\ tim\_settings\ =\ \{0\};} -\DoxyCodeLine{tim\_settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}{htim}}.Instance\ =\ TIM2;} -\DoxyCodeLine{tim\_settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}{sTimAHBFreqMHz}}\ =\ SystemCoreClock;} -\DoxyCodeLine{tim\_settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}{sTickBaseUS}}\ =\ \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ggaa0a51c870325217ac099881f09dd0800a6a66c5ed1d966c9e30f0219b664d2b25}{TIM\_TickBase\_1MS}};} -\DoxyCodeLine{tim\_settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4}{sTimFreqHz}}\ =\ 1000;\ \textcolor{comment}{//\ 1\ кГц}} -\DoxyCodeLine{tim\_settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}{sTimMode}}\ =\ TIM\_IT\_CONF;} -\DoxyCodeLine{} -\DoxyCodeLine{\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_ga7044214f24a9868ba7e1650b55e639ec}{TIM\_Base\_Init}}(\&tim\_settings);} -\DoxyCodeLine{HAL\_TIM\_Base\_Start(\&tim\_settings.\mbox{\hyperlink{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}{htim}});} - -\end{DoxyCode} -\hypertarget{index_dependencies}{}\doxysubsection{\texorpdfstring{Зависимости}{Зависимости}}\label{index_dependencies} - -\begin{DoxyItemize} -\item HAL библиотека STM32 -\item SEGGER RTT (опционально, для RTT трассировки) -\item Free\+RTOS (опционально, для Free\+RTOS задержек) -\end{DoxyItemize} \ No newline at end of file +\item Используйте нужные модули в своем коде. Примеры использования приведены в соответствующей теме +\end{DoxyEnumerate} \ No newline at end of file diff --git a/Doc/latex/longtable_doxygen.sty b/Doc/latex/longtable_doxygen.sty index e94b78b..39a44b8 100644 --- a/Doc/latex/longtable_doxygen.sty +++ b/Doc/latex/longtable_doxygen.sty @@ -164,7 +164,7 @@ \ifdim \dimen@>\z@\vfil\break\fi \global\@colroom\@colht \ifvoid\LT@foot\else - \advance\vsize-\ht\LT@foot + \global\advance\vsize-\ht\LT@foot \global\advance\@colroom-\ht\LT@foot \dimen@\pagegoal\advance\dimen@-\ht\LT@foot\pagegoal\dimen@ \maxdepth\z@ @@ -193,9 +193,13 @@ \LT@final@warn \fi \endgraf\penalty -\LT@end@pen + \ifvoid\LT@foot\else + \global\advance\vsize\ht\LT@foot + \global\advance\@colroom\ht\LT@foot + \dimen@\pagegoal\advance\dimen@\ht\LT@foot\pagegoal\dimen@ + \fi \endgroup \global\@mparbottom\z@ - \pagegoal\vsize \endgraf\penalty\z@\addvspace\LTpost \ifvoid\footins\else\insert\footins{}\fi} \def\LT@nofcols#1&{% @@ -392,18 +396,17 @@ \setbox\z@\vbox{\unvbox\@cclv}% \ifdim \ht\LT@lastfoot>\ht\LT@foot \dimen@\pagegoal + \advance\dimen@\ht\LT@foot \advance\dimen@-\ht\LT@lastfoot \ifdim\dimen@<\ht\z@ \setbox\@cclv\vbox{\unvbox\z@\copy\LT@foot\vss}% \@makecol \@outputpage + \global\vsize\@colroom \setbox\z@\vbox{\box\LT@head}% \fi \fi - \global\@colroom\@colht - \global\vsize\@colht - \vbox - {\unvbox\z@\box\ifvoid\LT@lastfoot\LT@foot\else\LT@lastfoot\fi}% + \unvbox\z@\ifvoid\LT@lastfoot\copy\LT@foot\else\box\LT@lastfoot\fi \fi \else \setbox\@cclv\vbox{\unvbox\@cclv\copy\LT@foot\vss}% diff --git a/Doc/latex/mainpage_8h_source.tex b/Doc/latex/mainpage_8h_source.tex index 7067a67..f9eba08 100644 --- a/Doc/latex/mainpage_8h_source.tex +++ b/Doc/latex/mainpage_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{mainpage.\+h} -\hypertarget{mainpage_8h_source}{}\label{mainpage_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/mainpage.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/mainpage.h}} +\hypertarget{mainpage_8h_source}{}\label{mainpage_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/mainpage.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/mainpage.h}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00001}00001\ \textcolor{comment}{}} @@ -7,7 +7,7 @@ \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00003}00003\ \textcolor{comment}{@mainpage}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00004}00004\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00005}00005\ \textcolor{comment}{@section\ overview\ Обзор}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00006}00006\ \textcolor{comment}{MyLibs\ -\/\ это\ набор\ библиотек\ для\ удобной\ работы\ с\ периферией\ микроконтроллеров\ STM32.}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00006}00006\ \textcolor{comment}{MyLibs\ -\/\ это\ набор\ библиотек\ для\ удобной\ работы\ с\ STM32.}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00007}00007\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00008}00008\ \textcolor{comment}{@subsection\ features\ Основные\ возможности}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00009}00009\ \textcolor{comment}{}} @@ -34,77 +34,47 @@ \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00030}00030\ \textcolor{comment}{-\/\ Работа\ с\ энкодерами\ (чтение\ положения,\ обработка\ кнопок)\ (@ref\ MYLIBS\_TIM\_ENCODER)}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00031}00031\ \textcolor{comment}{-\/\ Настройка\ ШИМ\ и\ Output\ Compare\ (@ref\ MYLIBS\_TIM\_OC)}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00032}00032\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00033}00033\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00034}00034\ \textcolor{comment}{@subsection\ structure\ Структура\ проекта}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00033}00033\ \textcolor{comment}{@subsubsection\ uart\_module\ Модуль\ UART\ @ref\ MY\_LIBS\_UART}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00034}00034\ \textcolor{comment}{-\/\ Базовая\ инициализация\ UART\ и\ его\ пинов\ одной\ функцией\ (@ref\ UART\_Base\_Init)}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00035}00035\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00036}00036\ \textcolor{comment}{@code}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00037}00037\ \textcolor{comment}{├──\ inc/\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \#\ Заголовочные\ файлы}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00038}00038\ \textcolor{comment}{│\ \ \ ├──\ mylibs\_include.h\ \ \ \ \ \#\ Главный\ include\ файл}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00039}00039\ \textcolor{comment}{│\ \ \ ├──\ mylibs\_config.h\ \ \ \ \ \ \#\ Конфигурация\ библиотек}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00040}00040\ \textcolor{comment}{│\ \ \ ├──\ mylibs\_defs.h\ \ \ \ \ \ \ \ \#\ Общие\ определения\ и\ макросы}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00041}00041\ \textcolor{comment}{│\ \ \ ├──\ bit\_access.h\ \ \ \ \ \ \ \ \ \#\ Битовый\ доступ\ к\ регистрам}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00042}00042\ \textcolor{comment}{│\ \ \ ├──\ trackers.h\ \ \ \ \ \ \ \ \ \ \ \#\ Трекеры\ для\ отладки}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00043}00043\ \textcolor{comment}{│\ \ \ ├──\ trace.h\ \ \ \ \ \ \ \ \ \ \ \ \ \ \#\ Трассировка\ и\ логирование}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00044}00044\ \textcolor{comment}{│\ \ \ ├──\ general\_gpio.h\ \ \ \ \ \ \ \#\ Работа\ с\ GPIO}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00045}00045\ \textcolor{comment}{│\ \ \ └──\ general\_tim.h\ \ \ \ \ \ \ \ \#\ Работа\ с\ таймерами}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00046}00046\ \textcolor{comment}{└──\ src/\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \#\ Исходные\ файлы}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00047}00047\ \textcolor{comment}{\ \ \ \ ├──\ general\_gpio.c\ \ \ \ \ \ \ \#\ Реализация\ GPIO}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00048}00048\ \textcolor{comment}{\ \ \ \ └──\ general\_tim.c\ \ \ \ \ \ \ \ \#\ Реализация\ TIM}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00049}00049\ \textcolor{comment}{@endcode}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00050}00050\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00051}00051\ \textcolor{comment}{@subsection\ usage\_basic\ Использование}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00052}00052\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00053}00053\ \textcolor{comment}{Инструкция\ по\ подключению:}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00054}00054\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00055}00055\ \textcolor{comment}{1.\ Настройте\ конфигурацию\ @ref\ MYLIBS\_CONFIG\ в\ @ref\ mylibs\_config.h\ }} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00056}00056\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00057}00057\ \textcolor{comment}{2.\ Подключите\ главный\ заголовочный\ файл:}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00058}00058\ \textcolor{comment}{@code}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00059}00059\ \textcolor{comment}{\#include\ "{}mylibs\_include.h"{}}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00060}00060\ \textcolor{comment}{@endcode}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00061}00061\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00062}00062\ \textcolor{comment}{3.\ Используйте\ нужные\ модули\ в\ своем\ коде}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00063}00063\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00064}00064\ \textcolor{comment}{@subsubsection\ gpio\_example\ Пример\ работы\ с\ GPIO}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00065}00065\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00066}00066\ \textcolor{comment}{@code}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00067}00067\ \textcolor{comment}{//\ Инициализация\ светодиода}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00068}00068\ \textcolor{comment}{MX\_GPIO\_Init();}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00069}00069\ \textcolor{comment}{GPIO\_LEDTypeDef\ led;}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00070}00070\ \textcolor{comment}{GPIO\_LED\_Init(\&led,\ GPIOA,\ GPIO\_PIN\_5,\ 1);}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00036}00036\ \textcolor{comment}{@subsubsection\ spi\_module\ Модуль\ SPI\ @ref\ MY\_LIBS\_SPI}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00037}00037\ \textcolor{comment}{-\/\ Базовая\ инициализация\ SPI\ и\ пинов\ одной\ функцией\ (@ref\ SPI\_Base\_Init)}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00038}00038\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00039}00039\ \textcolor{comment}{@subsection\ structure\ Структура\ проекта}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00040}00040\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00041}00041\ \textcolor{comment}{@code}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00042}00042\ \textcolor{comment}{├──\ inc/\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \#\ Заголовочные\ файлы}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00043}00043\ \textcolor{comment}{│\ \ \ ├──\ mylibs\_include.h\ \ \ \ \ \#\ Главный\ include\ файл}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00044}00044\ \textcolor{comment}{│\ \ \ ├──\ mylibs\_config.h\ \ \ \ \ \ \#\ Конфигурация\ библиотек}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00045}00045\ \textcolor{comment}{│\ \ \ ├──\ mylibs\_defs.h\ \ \ \ \ \ \ \ \#\ Общие\ определения\ и\ макросы}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00046}00046\ \textcolor{comment}{│\ \ \ ├──\ bit\_access.h\ \ \ \ \ \ \ \ \ \#\ Битовый\ доступ\ к\ регистрам}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00047}00047\ \textcolor{comment}{│\ \ \ ├──\ evolve\_optimizer.h\ \ \ \#\ Оптимизатор\ (генетический\ алгоритм)}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00048}00048\ \textcolor{comment}{│\ \ \ ├──\ trackers.h\ \ \ \ \ \ \ \ \ \ \ \#\ Трекеры\ для\ отладки}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00049}00049\ \textcolor{comment}{│\ \ \ ├──\ trace.h\ \ \ \ \ \ \ \ \ \ \ \ \ \ \#\ Трассировка\ и\ логирование}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00050}00050\ \textcolor{comment}{│\ \ \ ├──\ general\_gpio.h\ \ \ \ \ \ \ \#\ Работа\ с\ GPIO}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00051}00051\ \textcolor{comment}{\ \ \ \ ├──\ general\_spi.h\ \ \ \ \ \ \ \ \#\ Работа\ с\ SPI}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00052}00052\ \textcolor{comment}{│\ \ \ └──\ general\_tim.h\ \ \ \ \ \ \ \ \#\ Работа\ с\ таймерами}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00053}00053\ \textcolor{comment}{\ \ \ \ ├──\ general\_uart.h\ \ \ \ \ \ \ \#\ Работа\ с\ UART}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00054}00054\ \textcolor{comment}{└──\ src/\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \#\ Исходные\ файлы}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00055}00055\ \textcolor{comment}{\ \ \ \ ├──\ general\_gpio.c\ \ \ \ \ \ \ \#\ Реализация\ GPIO}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00056}00056\ \textcolor{comment}{\ \ \ \ ├──\ general\_spi.c\ \ \ \ \ \ \ \ \#\ Реализация\ SPI}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00057}00057\ \textcolor{comment}{\ \ \ \ └──\ general\_tim.c\ \ \ \ \ \ \ \ \#\ Реализация\ TIM}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00058}00058\ \textcolor{comment}{\ \ \ \ ├──\ general\_uart.c\ \ \ \ \ \ \ \#\ Реализация\ UART}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00059}00059\ \textcolor{comment}{@endcode}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00060}00060\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00061}00061\ \textcolor{comment}{@subsection\ usage\_basic\ Использование}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00062}00062\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00063}00063\ \textcolor{comment}{Инструкция\ по\ подключению:}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00064}00064\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00065}00065\ \textcolor{comment}{1.\ Настройте\ конфигурацию\ @ref\ MYLIBS\_CONFIG\ в\ @ref\ mylibs\_config.h\ }} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00066}00066\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00067}00067\ \textcolor{comment}{2.\ Подключите\ главный\ заголовочный\ файл:}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00068}00068\ \textcolor{comment}{@code}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00069}00069\ \textcolor{comment}{\#include\ "{}mylibs\_include.h"{}}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00070}00070\ \textcolor{comment}{@endcode}} \DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00071}00071\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00072}00072\ \textcolor{comment}{//\ Включение\ светодиода}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00073}00073\ \textcolor{comment}{GPIO\_LED\_On(\&led);}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00074}00074\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00075}00075\ \textcolor{comment}{//\ Запуск\ моргания}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00076}00076\ \textcolor{comment}{GPIO\_LED\_Blink\_Start(\&led,\ 500);\ //\ Период\ 500\ мс}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00077}00077\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00078}00078\ \textcolor{comment}{//\ В\ основном\ цикле}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00079}00079\ \textcolor{comment}{while\ (1)\ \{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00080}00080\ \textcolor{comment}{GPIO\_LED\_Dynamic\_Handle(\&led);}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00081}00081\ \textcolor{comment}{\}}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00082}00082\ \textcolor{comment}{@endcode}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00083}00083\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00084}00084\ \textcolor{comment}{@subsubsection\ tim\_example\ Пример\ работы\ с\ таймером}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00085}00085\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00086}00086\ \textcolor{comment}{@code}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00087}00087\ \textcolor{comment}{//\ Настройка\ таймера}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00088}00088\ \textcolor{comment}{TIM\_SettingsTypeDef\ tim\_settings\ =\ \{0\};}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00089}00089\ \textcolor{comment}{tim\_settings.htim.Instance\ =\ TIM2;}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00090}00090\ \textcolor{comment}{tim\_settings.sTimAHBFreqMHz\ =\ SystemCoreClock;}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00091}00091\ \textcolor{comment}{tim\_settings.sTickBaseUS\ =\ TIM\_TickBase\_1MS;}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00092}00092\ \textcolor{comment}{tim\_settings.sTimFreqHz\ =\ 1000;\ //\ 1\ кГц}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00093}00093\ \textcolor{comment}{tim\_settings.sTimMode\ =\ TIM\_IT\_CONF;}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00094}00094\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00095}00095\ \textcolor{comment}{TIM\_Base\_Init(\&tim\_settings);}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00096}00096\ \textcolor{comment}{HAL\_TIM\_Base\_Start(\&tim\_settings.htim);}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00097}00097\ \textcolor{comment}{@endcode}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00098}00098\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00099}00099\ \textcolor{comment}{@subsection\ dependencies\ Зависимости}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00100}00100\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00101}00101\ \textcolor{comment}{-\/\ HAL\ библиотека\ STM32}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00102}00102\ \textcolor{comment}{-\/\ SEGGER\ RTT\ (опционально,\ для\ RTT\ трассировки)}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00103}00103\ \textcolor{comment}{-\/\ FreeRTOS\ (опционально,\ для\ FreeRTOS\ задержек)}} -\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00104}00104\ \textcolor{comment}{\ */}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00072}00072\ \textcolor{comment}{3.\ Используйте\ нужные\ модули\ в\ своем\ коде.\ Примеры\ использования\ приведены\ в\ соответствующей\ теме}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00073}00073\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mainpage_8h_source_l00074}00074\ \textcolor{comment}{\ */}} \end{DoxyCode} diff --git a/Doc/latex/make.bat b/Doc/latex/make.bat index 96da1c8..ccd0c1b 100644 --- a/Doc/latex/make.bat +++ b/Doc/latex/make.bat @@ -1,5 +1,5 @@ pushd %~dp0 -if not %errorlevel% == 0 goto :end +if not %errorlevel% == 0 goto :end1 set ORG_LATEX_CMD=%LATEX_CMD% set ORG_MKIDX_CMD=%MKIDX_CMD% @@ -16,10 +16,12 @@ del /s /f *.ps *.dvi *.aux *.toc *.idx *.ind *.ilg *.log *.out *.brf *.blg *.bbl %LATEX_CMD% %MANUAL_FILE% +@if ERRORLEVEL 1 goto :error echo ---- %MKIDX_CMD% %MANUAL_FILE%.idx echo ---- %LATEX_CMD% %MANUAL_FILE% +@if ERRORLEVEL 1 goto :error setlocal enabledelayedexpansion set count=%LATEX_COUNT% @@ -34,12 +36,21 @@ if !count! EQU 0 goto :skip echo ---- %LATEX_CMD% %MANUAL_FILE% +@if ERRORLEVEL 1 goto :error goto :repeat :skip endlocal %MKIDX_CMD% %MANUAL_FILE%.idx %LATEX_CMD% %MANUAL_FILE% +@if ERRORLEVEL 1 goto :error +goto :end +:error +@echo =============== +@echo Please consult %MANUAL_FILE%.log to see the error messages +@echo =============== + +:end @REM reset environment popd set LATEX_CMD=%ORG_LATEX_CMD% @@ -53,4 +64,4 @@ set ORG_MANUAL_FILE= set LATEX_COUNT=%ORG_LATEX_COUNT% set ORG_LATEX_COUNT= -:end +:end1 diff --git a/Doc/latex/mylibs__config_8h.tex b/Doc/latex/mylibs__config_8h.tex index a5b9c86..ebfbb44 100644 --- a/Doc/latex/mylibs__config_8h.tex +++ b/Doc/latex/mylibs__config_8h.tex @@ -1,19 +1,21 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/mylibs\+\_\+config.h File Reference} -\hypertarget{mylibs__config_8h}{}\label{mylibs__config_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_config.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_config.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/mylibs\+\_\+config.h File Reference} +\hypertarget{mylibs__config_8h}{}\label{mylibs__config_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_config.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_config.h}} Конфигурации для библиотек My\+Libs. {\ttfamily \#include "{}stm32f4xx\+\_\+hal.\+h"{}}\newline -Include dependency graph for mylibs\+\_\+config.\+h\+:\nopagebreak +Include dependency graph for mylibs\+\_\+config.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=233pt]{mylibs__config_8h__incl} +\includegraphics[width=229pt]{mylibs__config_8h__incl} \end{center} \end{figure} -This graph shows which files directly or indirectly include this file\+:\nopagebreak +This graph shows which files directly or indirectly include this file\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode @@ -61,6 +63,8 @@ This graph shows which files directly or indirectly include this file\+:\nopageb \begin{DoxyCompactList}\small\item\em Максимальное количество параметров \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___e_v_o_l_v_e___c_o_n_f_i_g_ga7c1396e5c95c766afccdb45cbfcf5971}{EVOLVE\+\_\+\+MAX\+\_\+\+CANDIDATES}}~100 \begin{DoxyCompactList}\small\item\em Максимальное количество кандидатов для обучения \end{DoxyCompactList}\item +\#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{local\+\_\+time}}() +\begin{DoxyCompactList}\small\item\em Локальное время \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga66560656d080d6551627a19dfb847c66}{INCLUDE\+\_\+\+EVOLVE\+\_\+\+OPTIMIZER}} \begin{DoxyCompactList}\small\item\em Подключить библиотеку для оптимизации параметров \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_gaf4ddb2a71ec0d05c2480e197cd17c0be}{INCLUDE\+\_\+\+BIT\+\_\+\+ACCESS\+\_\+\+LIB}} @@ -70,7 +74,9 @@ This graph shows which files directly or indirectly include this file\+:\nopageb \#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga0a3ca94b616997069dd53e2c6c2687d7}{INCLUDE\+\_\+\+TRACE\+\_\+\+LIB}} \begin{DoxyCompactList}\small\item\em Подключить библиотеку с трейсами \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga181a46326e46b60afb160190832c7281}{INCLUDE\+\_\+\+GENERAL\+\_\+\+PERIPH\+\_\+\+LIBS}} -\begin{DoxyCompactList}\small\item\em Подключить библиотеку с периферией \end{DoxyCompactList}\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Подключить библиотеку с периферией \end{DoxyCompactList}\item +\#define \mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga57c369737d5c0cfdb7baeecba0a4b151}{FREERTOS\+\_\+\+DELAY}} +\begin{DoxyCompactList}\small\item\em Использовать Free\+RTOS задержку, вместо HAL. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsection{Detailed Description} diff --git a/Doc/latex/mylibs__config_8h__dep__incl.md5 b/Doc/latex/mylibs__config_8h__dep__incl.md5 index 1bc1f47..77d2196 100644 --- a/Doc/latex/mylibs__config_8h__dep__incl.md5 +++ b/Doc/latex/mylibs__config_8h__dep__incl.md5 @@ -1 +1 @@ -dfdd61dc82258e402e33665df3248b95 \ No newline at end of file +082ebf45da1eebb6c29f7ba296f9fb91 \ No newline at end of file diff --git a/Doc/latex/mylibs__config_8h__dep__incl.pdf b/Doc/latex/mylibs__config_8h__dep__incl.pdf index 220546e..55fcc32 100644 Binary files a/Doc/latex/mylibs__config_8h__dep__incl.pdf and b/Doc/latex/mylibs__config_8h__dep__incl.pdf differ diff --git a/Doc/latex/mylibs__config_8h__incl.md5 b/Doc/latex/mylibs__config_8h__incl.md5 index 7d171f1..05972e8 100644 --- a/Doc/latex/mylibs__config_8h__incl.md5 +++ b/Doc/latex/mylibs__config_8h__incl.md5 @@ -1 +1 @@ -427d243444c5f0fad6dcdd2d1fe989d2 \ No newline at end of file +7f343940c93fbed727067d075d8fdd8d \ No newline at end of file diff --git a/Doc/latex/mylibs__config_8h__incl.pdf b/Doc/latex/mylibs__config_8h__incl.pdf index 7e62295..a46ec9c 100644 Binary files a/Doc/latex/mylibs__config_8h__incl.pdf and b/Doc/latex/mylibs__config_8h__incl.pdf differ diff --git a/Doc/latex/mylibs__config_8h_source.tex b/Doc/latex/mylibs__config_8h_source.tex index 9e84b10..d5de1f6 100644 --- a/Doc/latex/mylibs__config_8h_source.tex +++ b/Doc/latex/mylibs__config_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{mylibs\+\_\+config.\+h} -\hypertarget{mylibs__config_8h_source}{}\label{mylibs__config_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_config.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_config.h}} +\hypertarget{mylibs__config_8h_source}{}\label{mylibs__config_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_config.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_config.h}} \mbox{\hyperlink{mylibs__config_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00001}00001\ \textcolor{comment}{/**\ }} @@ -81,20 +81,22 @@ \DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00077}00077\ \textcolor{comment}{\ \ *\ @\{}} \DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00078}00078\ \textcolor{comment}{\ \ */}} \DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00079}00079\ } -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00080}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga66560656d080d6551627a19dfb847c66}{00080}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_EVOLVE\_OPTIMIZER\ \ \ \ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ для\ оптимизации\ параметров}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00081}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_gaf4ddb2a71ec0d05c2480e197cd17c0be}{00081}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_BIT\_ACCESS\_LIB\ \ \ \ \ \ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ с\ typedef\ с\ битовыми\ полями}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00082}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga4403055986b70bb02b8d37073a122e32}{00082}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_TRACKERS\_LIB\ \ \ \ \ \ \ \ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ с\ трекерами}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00083}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga0a3ca94b616997069dd53e2c6c2687d7}{00083}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_TRACE\_LIB\ \ \ \ \ \ \ \ \ \ \ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ с\ трейсами}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00084}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga181a46326e46b60afb160190832c7281}{00084}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_GENERAL\_PERIPH\_LIBS\ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ с\ периферией}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00085}00085\ \textcolor{comment}{//\#define\ FREERTOS\_DELAY\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ///<\ Использовать\ FreeRTOS\ задержку,\ вместо\ HAL}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00086}00086\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00087}00087\ \textcolor{comment}{/**\ LIBS\_CONFIG}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00088}00088\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00089}00089\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00090}00090\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00091}00091\ \textcolor{comment}{/**\ MYLIBS\_CONFIG}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00092}00092\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00093}00093\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00094}00094\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\_\_MYLIBS\_CONFIG\_H\_}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00080}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga9c853b02c22f26023c34d1d404b6d653}{00080}}\ \textcolor{preprocessor}{\#define\ local\_time()\ \ \ \ \ \ uwTick\ \ \ \ \ \ }\textcolor{comment}{///<\ Локальное\ время}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00081}00081\ } +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00082}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga66560656d080d6551627a19dfb847c66}{00082}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_EVOLVE\_OPTIMIZER\ \ \ \ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ для\ оптимизации\ параметров}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00083}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_gaf4ddb2a71ec0d05c2480e197cd17c0be}{00083}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_BIT\_ACCESS\_LIB\ \ \ \ \ \ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ с\ typedef\ с\ битовыми\ полями}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00084}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga4403055986b70bb02b8d37073a122e32}{00084}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_TRACKERS\_LIB\ \ \ \ \ \ \ \ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ с\ трекерами}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00085}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga0a3ca94b616997069dd53e2c6c2687d7}{00085}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_TRACE\_LIB\ \ \ \ \ \ \ \ \ \ \ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ с\ трейсами}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00086}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga181a46326e46b60afb160190832c7281}{00086}}\ \textcolor{preprocessor}{\#define\ INCLUDE\_GENERAL\_PERIPH\_LIBS\ \ \ }\textcolor{comment}{///<\ Подключить\ библиотеку\ с\ периферией}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00087}\mbox{\hyperlink{group___l_i_b_s___c_o_n_f_i_g_ga57c369737d5c0cfdb7baeecba0a4b151}{00087}}\ \textcolor{preprocessor}{\#define\ FREERTOS\_DELAY\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\textcolor{comment}{///<\ Использовать\ FreeRTOS\ задержку,\ вместо\ HAL}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00088}00088\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00089}00089\ \textcolor{comment}{/**\ LIBS\_CONFIG}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00090}00090\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00091}00091\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00092}00092\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00093}00093\ \textcolor{comment}{/**\ MYLIBS\_CONFIG}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00094}00094\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00095}00095\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__config_8h_source_l00096}00096\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\_\_MYLIBS\_CONFIG\_H\_}} \end{DoxyCode} diff --git a/Doc/latex/mylibs__defs_8h.tex b/Doc/latex/mylibs__defs_8h.tex index 0dd64aa..5167839 100644 --- a/Doc/latex/mylibs__defs_8h.tex +++ b/Doc/latex/mylibs__defs_8h.tex @@ -1,19 +1,21 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/mylibs\+\_\+defs.h File Reference} -\hypertarget{mylibs__defs_8h}{}\label{mylibs__defs_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_defs.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_defs.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/mylibs\+\_\+defs.h File Reference} +\hypertarget{mylibs__defs_8h}{}\label{mylibs__defs_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_defs.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_defs.h}} Заголочный файл для дефайнов библиотеки My\+Libs\+General. {\ttfamily \#include "{}mylibs\+\_\+config.\+h"{}}\newline -Include dependency graph for mylibs\+\_\+defs.\+h\+:\nopagebreak +Include dependency graph for mylibs\+\_\+defs.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=263pt]{mylibs__defs_8h__incl} +\includegraphics[width=229pt]{mylibs__defs_8h__incl} \end{center} \end{figure} -This graph shows which files directly or indirectly include this file\+:\nopagebreak +This graph shows which files directly or indirectly include this file\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode @@ -23,33 +25,33 @@ This graph shows which files directly or indirectly include this file\+:\nopageb \doxysubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gae110df81afd885a390bbeb152d7b709f}{My\+Libs\+\_\+\+Error\+\_\+\+Handler}}(params)~Error\+\_\+\+Handler(params) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gae110df81afd885a390bbeb152d7b709f}{My\+Libs\+\_\+\+Error\+\_\+\+Handler}}(params) \begin{DoxyCompactList}\small\item\em Error\+\_\+\+Handler который будет вызыватся в библиотеке \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga5d066a5b9781f9437e75d98677489eb9}{check\+\_\+null\+\_\+ptr\+\_\+1}}(p1)~(p1 == NULL) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga5d066a5b9781f9437e75d98677489eb9}{check\+\_\+null\+\_\+ptr\+\_\+1}}(p1) \begin{DoxyCompactList}\small\item\em Проверить один указатель на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga27b363f333cacdccc15f5174e096b5b3}{check\+\_\+null\+\_\+ptr\+\_\+2}}(p1, p2)~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& p2 == NULL)) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga27b363f333cacdccc15f5174e096b5b3}{check\+\_\+null\+\_\+ptr\+\_\+2}}(p1, p2) \begin{DoxyCompactList}\small\item\em Проверить два указателя на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga838b40542faa9aa273d18f921b21fda2}{check\+\_\+null\+\_\+ptr\+\_\+3}}(p1, p2, p3)~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& p3 == NULL)))) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga838b40542faa9aa273d18f921b21fda2}{check\+\_\+null\+\_\+ptr\+\_\+3}}(p1, p2, p3) \begin{DoxyCompactList}\small\item\em Проверить три указателя на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga590973be111afc3f9ba15e6939530254}{check\+\_\+null\+\_\+ptr\+\_\+4}}(p1, p2, p3, p4)~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& ((p3 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p3 != NULL \&\& p4 == NULL)))))) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_ga590973be111afc3f9ba15e6939530254}{check\+\_\+null\+\_\+ptr\+\_\+4}}(p1, p2, p3, p4) \begin{DoxyCompactList}\small\item\em Проверить четыре указателя на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gaab0aafd7a4a21ec4f338b19269f65490}{check\+\_\+null\+\_\+ptr\+\_\+5}}(p1, p2, p3, p4, p5)~((p1 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p1 != NULL \&\& ((p2 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p2 != NULL \&\& ((p3 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p3 != NULL \&\& ((p4 == NULL) \texorpdfstring{$\vert$}{|}\texorpdfstring{$\vert$}{|} (p4 != NULL \&\& p5 == NULL)))))))) +\#define \mbox{\hyperlink{group___e_r_r_o_r___h_a_n_d_l_e_r___d_e_f_i_n_e_s_gaab0aafd7a4a21ec4f338b19269f65490}{check\+\_\+null\+\_\+ptr\+\_\+5}}(p1, p2, p3, p4, p5) \begin{DoxyCompactList}\small\item\em Проверить пять указателей на NULL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479}{ms\+Delay}}(\+\_\+ms\+\_\+)~HAL\+\_\+\+Delay(\+\_\+ms\+\_\+) -\begin{DoxyCompactList}\small\item\em Задержка на указанное количество миллисекунд. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25}{ms\+Delay\+Start}}(\+\_\+pvar\+\_\+)~\texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) = HAL\+\_\+\+Get\+Tick() +\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479}{ms\+Delay}}(\+\_\+ms\+\_\+) +\begin{DoxyCompactList}\small\item\em Блокирующая задержка на указанное количество миллисекунд. \end{DoxyCompactList}\item +\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25}{ms\+Delay\+Start}}(\+\_\+pvar\+\_\+) \begin{DoxyCompactList}\small\item\em Начать отсчет задержки. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85}{ms\+Delay\+While\+Active}}(\+\_\+ms\+\_\+, \+\_\+pvar\+\_\+)~(HAL\+\_\+\+Get\+Tick() -\/ \texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) $<$ \+\_\+ms\+\_\+) +\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85}{ms\+Delay\+While\+Active}}(\+\_\+ms\+\_\+, \+\_\+pvar\+\_\+) \begin{DoxyCompactList}\small\item\em Проверяет, активна ли задержка. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}{ms\+Delay\+Wait\+Done}}(\+\_\+ms\+\_\+, \+\_\+pvar\+\_\+)~(HAL\+\_\+\+Get\+Tick() -\/ \texorpdfstring{$\ast$}{*}(\+\_\+pvar\+\_\+) $>$= \+\_\+ms\+\_\+) +\#define \mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}{ms\+Delay\+Wait\+Done}}(\+\_\+ms\+\_\+, \+\_\+pvar\+\_\+) \begin{DoxyCompactList}\small\item\em Проверяет, завершилась ли задержка. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be}{Clear\+Struct}}(\+\_\+struct\+\_\+)~memset(\&(\+\_\+struct\+\_\+), 0, sizeof(\+\_\+struct\+\_\+)) +\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be}{Clear\+Struct}}(\+\_\+struct\+\_\+) \begin{DoxyCompactList}\small\item\em Обнуление структуры. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e}{Divide\+\_\+\+Up}}(\+\_\+val\+\_\+, \+\_\+div\+\_\+)~((\+\_\+val\+\_\+ -\/ 1) / \+\_\+div\+\_\+) + 1 /\texorpdfstring{$\ast$}{*} через мат выражение \texorpdfstring{$\ast$}{*}/ +\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e}{Divide\+\_\+\+Up}}(\+\_\+val\+\_\+, \+\_\+div\+\_\+) \begin{DoxyCompactList}\small\item\em Деление с округлением вверх \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291}{Byte\+Swap16}}(v)~(((v\&0x\+FF00) $>$$>$ (8)) \texorpdfstring{$\vert$}{|} ((v\&0x00\+FF) $<$$<$ (8))) +\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291}{Byte\+Swap16}}(v) \begin{DoxyCompactList}\small\item\em Swap between Little Endian and Big Endian. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759}{ABS}}(x)~( ((x) $>$ 0)? (x) \+: -\/(x)) +\#define \mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759}{ABS}}(x) \begin{DoxyCompactList}\small\item\em Абсолютное значение числа \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsection*{Functions} \begin{DoxyCompactItemize} diff --git a/Doc/latex/mylibs__defs_8h__dep__incl.md5 b/Doc/latex/mylibs__defs_8h__dep__incl.md5 index 5c2d1b7..2454bdf 100644 --- a/Doc/latex/mylibs__defs_8h__dep__incl.md5 +++ b/Doc/latex/mylibs__defs_8h__dep__incl.md5 @@ -1 +1 @@ -a0add19dd86a580c165837823a871204 \ No newline at end of file +0085824f98ba0aa8e935c0ada2fd3b2e \ No newline at end of file diff --git a/Doc/latex/mylibs__defs_8h__dep__incl.pdf b/Doc/latex/mylibs__defs_8h__dep__incl.pdf index 65f15a3..75731ac 100644 Binary files a/Doc/latex/mylibs__defs_8h__dep__incl.pdf and b/Doc/latex/mylibs__defs_8h__dep__incl.pdf differ diff --git a/Doc/latex/mylibs__defs_8h__incl.md5 b/Doc/latex/mylibs__defs_8h__incl.md5 index ef4b4a9..836cb7e 100644 --- a/Doc/latex/mylibs__defs_8h__incl.md5 +++ b/Doc/latex/mylibs__defs_8h__incl.md5 @@ -1 +1 @@ -b0594a81c6dada4780f453ea023ebb76 \ No newline at end of file +b5e99873d7ab78385a101e5850699d2c \ No newline at end of file diff --git a/Doc/latex/mylibs__defs_8h__incl.pdf b/Doc/latex/mylibs__defs_8h__incl.pdf index 5b23485..42ff48d 100644 Binary files a/Doc/latex/mylibs__defs_8h__incl.pdf and b/Doc/latex/mylibs__defs_8h__incl.pdf differ diff --git a/Doc/latex/mylibs__defs_8h_source.tex b/Doc/latex/mylibs__defs_8h_source.tex index 366b229..a44b4a6 100644 --- a/Doc/latex/mylibs__defs_8h_source.tex +++ b/Doc/latex/mylibs__defs_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{mylibs\+\_\+defs.\+h} -\hypertarget{mylibs__defs_8h_source}{}\label{mylibs__defs_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_defs.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_defs.h}} +\hypertarget{mylibs__defs_8h_source}{}\label{mylibs__defs_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_defs.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_defs.h}} \mbox{\hyperlink{mylibs__defs_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00001}00001\ \textcolor{comment}{/**\ }} @@ -76,115 +76,137 @@ \DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00072}00072\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00073}00073\ \textcolor{comment}{/**\ }} \DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00074}00074\ \textcolor{comment}{\ \ *\ @def\ msDelay(\_ms\_)}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00075}00075\ \textcolor{comment}{\ \ *\ @brief\ Задержка\ на\ указанное\ количество\ миллисекунд.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00075}00075\ \textcolor{comment}{\ \ *\ @brief\ Блокирующая\ задержка\ на\ указанное\ количество\ миллисекунд.}} \DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00076}00076\ \textcolor{comment}{\ \ *\ @param\ \_ms\_\ Время\ задержки\ в\ миллисекундах.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00077}00077\ \textcolor{comment}{\ \ *\ @note\ Использует\ HAL\_Delay\ или\ osDelay\ в\ зависимости\ от\ @ref\ FREERTOS\_DELAY.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00077}00077\ \textcolor{comment}{\ \ *\ @note\ Использует\ задержку\ через\ @ref\ local\_time\ или\ osDelay\ в\ зависимости\ от\ @ref\ FREERTOS\_DELAY.}} \DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00078}00078\ \textcolor{comment}{\ \ */}} \DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00079}00079\ \textcolor{preprocessor}{\#ifdef\ FREERTOS\_DELAY}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00080}00080\ \textcolor{preprocessor}{\ \ \#define\ msDelay(\_ms\_)\ \ \ \ \ \ \ osDelay(\_ms\_)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00080}\mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479}{00080}}\ \textcolor{preprocessor}{\ \ \#define\ msDelay(\_ms\_)\ \ \ \ \ \ \ osDelay(\_ms\_)}} \DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00081}00081\ \textcolor{preprocessor}{\#else}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00082}\mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gabeb97579daeb622c6651ed03c4a27479}{00082}}\ \textcolor{preprocessor}{\ \ \#define\ msDelay(\_ms\_)\ \ \ \ \ \ \ HAL\_Delay(\_ms\_)}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00083}00083\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00084}00084\ } -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00085}00085\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00086}00086\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00087}00087\ \textcolor{comment}{\ \ *\ @brief\ Начать\ отсчет\ задержки.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00088}00088\ \textcolor{comment}{\ \ *\ @param\ \_pvar\_\ Указатель\ на\ переменную\ типа\ uint32\_t\ для\ хранения\ времени\ старта.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00089}00089\ \textcolor{comment}{\ \ *\ @details\ После\ вызова\ этого\ макроса\ переменная\ \_pvar\_\ содержит\ текущее\ количество\ миллисекунд}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00090}00090\ \textcolor{comment}{\ \ *\ с\ момента\ запуска\ системы\ (HAL\_GetTick).\ }} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00091}00091\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00092}00092\ \textcolor{comment}{\ \ *\ Используется\ для\ реализации\ неблокирующих\ задержек.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00093}00093\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00094}\mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25}{00094}}\ \textcolor{preprocessor}{\#define\ msDelayStart(\_pvar\_)\ \ \ \ \ \ \ \ \ \ \ \ *(\_pvar\_)\ =\ HAL\_GetTick()}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00095}00095\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00096}00096\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00097}00097\ \textcolor{comment}{\ *\ @brief\ Проверяет,\ активна\ ли\ задержка.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00098}00098\ \textcolor{comment}{\ *\ @param\ \_ms\_\ Длительность\ задержки\ в\ миллисекундах.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00099}00099\ \textcolor{comment}{\ *\ @param\ \_pvar\_\ Указатель\ на\ переменную,\ в\ которой\ сохранено\ время\ начала\ (@ref\ msDelayStart).}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00100}00100\ \textcolor{comment}{\ *\ @retval\ 1\ Задержка\ еще\ активна.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00101}00101\ \textcolor{comment}{\ *\ @retval\ 0\ Задержка\ завершена.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00102}00102\ \textcolor{comment}{\ *\ @details}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00103}00103\ \textcolor{comment}{\ *\ Возвращает\ true,\ пока\ время\ задержки\ не\ истекло.\ Используется\ в\ проверках,}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00104}00104\ \textcolor{comment}{\ *\ когда\ нужно\ **действовать,\ пока\ задержка\ выполняется**.\ Пример:}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00105}00105\ \textcolor{comment}{\ *\ @code}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00106}00106\ \textcolor{comment}{\ *\ while(msDelayWhileActive(1000,\ \&tick))\ \{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00107}00107\ \textcolor{comment}{\ *\ \ \ \ \ //\ выполняем\ другие\ задачи,\ задержка\ не\ блокирует\ поток}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00108}00108\ \textcolor{comment}{\ *\ \}}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00109}00109\ \textcolor{comment}{\ *\ @endcode}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00110}00110\ \textcolor{comment}{\ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00111}\mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85}{00111}}\ \textcolor{preprocessor}{\#define\ msDelayWhileActive(\_ms\_,\ \_pvar\_)\ \ \ \ (HAL\_GetTick()\ -\/\ *(\_pvar\_)\ <\ \_ms\_)}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00112}00112\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00113}00113\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00114}00114\ \textcolor{comment}{\ *\ @brief\ Проверяет,\ завершилась\ ли\ задержка.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00115}00115\ \textcolor{comment}{\ *\ @param\ \_ms\_\ Длительность\ задержки\ в\ миллисекундах.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00116}00116\ \textcolor{comment}{\ *\ @param\ \_pvar\_\ Указатель\ на\ переменную,\ в\ которой\ сохранено\ время\ начала\ (msDelayStart).}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00117}00117\ \textcolor{comment}{\ *\ @retval\ 1\ Задержка\ завершена.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00118}00118\ \textcolor{comment}{\ *\ @retval\ 0\ Задержка\ еще\ активна.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00119}00119\ \textcolor{comment}{\ *\ @details}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00120}00120\ \textcolor{comment}{\ *\ Возвращает\ true,\ когда\ задержка\ уже\ завершена.\ Используется\ в\ проверках,}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00121}00121\ \textcolor{comment}{\ *\ когда\ нужно\ **выполнить\ действие\ только\ после\ окончания\ задержки**.\ Пример:}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00122}00122\ \textcolor{comment}{\ *\ @code}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00123}00123\ \textcolor{comment}{\ *\ if(msDelayWaitDone(1000,\ \&tick))\ \{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00124}00124\ \textcolor{comment}{\ *\ \ \ \ \ //\ выполняем\ действие\ после\ завершения\ задержки}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00125}00125\ \textcolor{comment}{\ *\ \}}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00126}00126\ \textcolor{comment}{\ *\ @endcode}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00127}00127\ \textcolor{comment}{\ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00128}\mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}{00128}}\ \textcolor{preprocessor}{\#define\ msDelayWaitDone(\_ms\_,\ \_pvar\_)\ \ \ \ (HAL\_GetTick()\ -\/\ *(\_pvar\_)\ >=\ \_ms\_)}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00129}00129\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00130}00130\ \textcolor{comment}{/**\ DELAYS\_DEFINES}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00131}00131\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00132}00132\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00133}00133\ } -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00134}00134\ } -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00135}00135\ \textcolor{comment}{/***************************************************************************}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00136}00136\ \textcolor{comment}{*******************************UTIL\_DEFINES********************************/}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00137}00137\ \textcolor{keyword}{static}\ \textcolor{keywordtype}{int}\ dummy;\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00138}00138\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00139}00139\ \textcolor{comment}{\ \ *\ @addtogroup\ UTILS\_DEFINES\ \ \ \ \ \ Utils\ defines}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00140}00140\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MYLIBS\_DEFINES}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00141}00141\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Общие\ вспомогательные\ макросы}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00142}00142\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00143}00143\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00144}00144\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00145}00145\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00146}00146\ \textcolor{comment}{\ *\ @brief\ Обнуление\ структуры.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00147}00147\ \textcolor{comment}{\ *\ @param\ \_struct\_\ Структура,\ которую\ нужно\ обнулить.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00148}00148\ \textcolor{comment}{\ *\ @details\ Макрос\ использует\ memset\ для\ обнуления\ всей\ памяти\ структуры.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00149}00149\ \textcolor{comment}{\ *\ Используется\ для\ быстрой\ и\ безопасной\ инициализации\ переменных\ структур\ до\ нуля.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00150}00150\ \textcolor{comment}{\ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00151}\mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be}{00151}}\ \textcolor{preprocessor}{\#define\ ClearStruct(\_struct\_)\ \ \ \ \ memset(\&(\_struct\_),\ 0,\ sizeof(\_struct\_))}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00152}00152\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00153}00153\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00154}00154\ \textcolor{comment}{\ \ *\ @brief\ \ Деление\ с\ округлением\ вверх}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00155}00155\ \textcolor{comment}{\ \ *\ @param\ \_val\_\ Делимое.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00156}00156\ \textcolor{comment}{\ \ *\ @param\ \_div\_\ Делитель.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00157}00157\ \textcolor{comment}{\ \ *\ @return\ Результат\ деления,\ округленный\ вверх.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00158}00158\ \textcolor{comment}{\ \ *\ @details\ \ Если\ результат\ деления\ без\ остатка:\ он\ возвращается\ как\ есть}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00159}00159\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ \ \ Если\ с\ остатком\ -\/\ округляется\ вверх}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00160}00160\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00161}00161\ \textcolor{comment}{//\#define\ Divide\_Up(\_val\_,\ \_div\_)\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (((\_val\_)\%(\_div\_))?\ (\_val\_)/(\_div\_)+1\ :\ (\_val\_)/\_div\_)\ \ /*\ через\ тернарный\ оператор\ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00162}\mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e}{00162}}\ \textcolor{preprocessor}{\#define\ Divide\_Up(\_val\_,\ \_div\_)\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ((\_val\_\ -\/\ 1)\ /\ \_div\_)\ +\ 1\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\textcolor{comment}{/*\ через\ мат\ выражение\ */}\textcolor{preprocessor}{\ }} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00163}00163\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00164}00164\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00165}00165\ \textcolor{comment}{\ \ *\ @brief\ \ Swap\ between\ Little\ Endian\ and\ Big\ Endian}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00166}00166\ \textcolor{comment}{\ \ *\ @param\ v\ Исходное\ 16-\/битное\ значение.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00167}00167\ \textcolor{comment}{\ \ *\ @return\ Результат\ с\ поменяными\ местами\ старшим\ и\ младшим\ байтом.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00168}00168\ \textcolor{comment}{\ \ *\ @details\ \ Переключения\ между\ двумя\ типами\ хранения\ слова:\ HI-\/LO\ байты\ и\ LO-\/HI\ байты.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00169}00169\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00170}\mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291}{00170}}\ \textcolor{preprocessor}{\#define\ ByteSwap16(v)\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (((v\&0xFF00)\ >>\ (8))\ |\ ((v\&0x00FF)\ <<\ (8)))}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00171}00171\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00172}00172\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00173}00173\ \textcolor{comment}{\ \ *\ @brief\ \ Абсолютное\ значение\ числа}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00174}00174\ \textcolor{comment}{\ \ *\ @param\ x\ Число.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00175}00175\ \textcolor{comment}{\ \ *\ @return\ Абсолютное\ значение\ числа\ x.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00176}00176\ \textcolor{comment}{\ \ *\ @details\ \ Берет\ число\ по\ модулю.\ Хз\ как\ работает\ библиотечный\ abs\ в\ stdlib.h,\ мб\ это\ быстрее,\ но\ вряд\ ли\ конечно.}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00177}00177\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00178}\mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759}{00178}}\ \textcolor{preprocessor}{\#define\ ABS(x)\ (\ ((x)\ >\ 0)?\ (x)\ :\ -\/(x))}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00179}00179\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00180}00180\ \textcolor{comment}{/**\ UTILS\_DEFINES}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00181}00181\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00182}00182\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00183}00183\ \ \ } -\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00184}00184\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\_\_MYLIBS\_DEFINES\_H\_}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00082}00082\ \textcolor{preprocessor}{\ \ \#define\ msDelay(\_ms\_)\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00083}00083\ \textcolor{preprocessor}{\ \ \ \ do\ \{\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00084}00084\ \textcolor{preprocessor}{\ \ \ \ \ \ \ \ uint32\_t\ \_start\_\ =\ local\_time();\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00085}00085\ \textcolor{preprocessor}{\ \ \ \ \ \ \ \ while\ (local\_time()\ -\/\ \_start\_\ <\ (\_ms\_))\ \{\}\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00086}00086\ \textcolor{preprocessor}{\ \ \ \ \}\ while(0)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00087}00087\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00088}00088\ } +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00089}00089\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00090}00090\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00091}00091\ \textcolor{comment}{\ \ *\ @brief\ Начать\ отсчет\ задержки.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00092}00092\ \textcolor{comment}{\ \ *\ @param\ \_pvar\_\ Указатель\ на\ переменную\ типа\ uint32\_t\ для\ хранения\ времени\ старта.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00093}00093\ \textcolor{comment}{\ \ *\ @details\ После\ вызова\ этого\ макроса\ переменная\ \_pvar\_\ содержит\ текущее\ количество\ миллисекунд}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00094}00094\ \textcolor{comment}{\ \ *\ с\ момента\ запуска\ системы\ (@ref\ local\_time).\ }} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00095}00095\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00096}00096\ \textcolor{comment}{\ \ *\ Используется\ для\ реализации\ неблокирующих\ задержек.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00097}00097\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00098}\mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga8a5051b1292d1019fe8dd3fc5521ab25}{00098}}\ \textcolor{preprocessor}{\#define\ msDelayStart(\_pvar\_)\ \ \ \ \ \ \ \ \ \ \ \ *(\_pvar\_)\ =\ local\_time()}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00099}00099\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00100}00100\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00101}00101\ \textcolor{comment}{\ *\ @brief\ Проверяет,\ активна\ ли\ задержка.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00102}00102\ \textcolor{comment}{\ *\ @param\ \_ms\_\ Длительность\ задержки\ в\ миллисекундах.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00103}00103\ \textcolor{comment}{\ *\ @param\ \_pvar\_\ Указатель\ на\ переменную,\ в\ которой\ сохранено\ время\ начала\ (@ref\ msDelayStart).}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00104}00104\ \textcolor{comment}{\ *\ @retval\ 1\ Задержка\ еще\ активна.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00105}00105\ \textcolor{comment}{\ *\ @retval\ 0\ Задержка\ завершена.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00106}00106\ \textcolor{comment}{\ *\ @details}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00107}00107\ \textcolor{comment}{\ *\ Возвращает\ true,\ пока\ время\ задержки\ не\ истекло.\ Используется\ в\ проверках,}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00108}00108\ \textcolor{comment}{\ *\ когда\ нужно\ **действовать,\ пока\ задержка\ выполняется**.\ Пример:}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00109}00109\ \textcolor{comment}{\ *\ @code}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00110}00110\ \textcolor{comment}{\ *\ while(msDelayWhileActive(1000,\ \&tick))\ \{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00111}00111\ \textcolor{comment}{\ *\ \ \ \ \ //\ выполняем\ другие\ задачи,\ задержка\ не\ блокирует\ поток}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00112}00112\ \textcolor{comment}{\ *\ \}}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00113}00113\ \textcolor{comment}{\ *\ @endcode}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00114}00114\ \textcolor{comment}{\ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00115}\mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_ga0b97e172659a59ee4fa56f851643ae85}{00115}}\ \textcolor{preprocessor}{\#define\ msDelayWhileActive(\_ms\_,\ \_pvar\_)\ \ \ \ (local\_time()\ -\/\ *(\_pvar\_)\ <\ \_ms\_)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00116}00116\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00117}00117\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00118}00118\ \textcolor{comment}{\ *\ @brief\ Проверяет,\ завершилась\ ли\ задержка.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00119}00119\ \textcolor{comment}{\ *\ @param\ \_ms\_\ Длительность\ задержки\ в\ миллисекундах.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00120}00120\ \textcolor{comment}{\ *\ @param\ \_pvar\_\ Указатель\ на\ переменную,\ в\ которой\ сохранено\ время\ начала\ (msDelayStart).}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00121}00121\ \textcolor{comment}{\ *\ @retval\ 1\ Задержка\ завершена.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00122}00122\ \textcolor{comment}{\ *\ @retval\ 0\ Задержка\ еще\ активна.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00123}00123\ \textcolor{comment}{\ *\ @details}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00124}00124\ \textcolor{comment}{\ *\ Возвращает\ true,\ когда\ задержка\ уже\ завершена.\ Используется\ в\ проверках,}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00125}00125\ \textcolor{comment}{\ *\ когда\ нужно\ **выполнить\ действие\ только\ после\ окончания\ задержки**.\ Пример:}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00126}00126\ \textcolor{comment}{\ *\ @code}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00127}00127\ \textcolor{comment}{\ *\ if(msDelayWaitDone(1000,\ \&tick))\ \{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00128}00128\ \textcolor{comment}{\ *\ \ \ \ \ //\ выполняем\ действие\ после\ завершения\ задержки}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00129}00129\ \textcolor{comment}{\ *\ \}}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00130}00130\ \textcolor{comment}{\ *\ @endcode}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00131}00131\ \textcolor{comment}{\ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00132}\mbox{\hyperlink{group___d_e_l_a_y_s___d_e_f_i_n_e_s_gaed082c07b9fc4d1894330d885b9b5518}{00132}}\ \textcolor{preprocessor}{\#define\ msDelayWaitDone(\_ms\_,\ \_pvar\_)\ \ \ \ (local\_time()\ -\/\ *(\_pvar\_)\ >=\ \_ms\_)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00133}00133\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00134}00134\ \textcolor{comment}{/**\ DELAYS\_DEFINES}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00135}00135\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00136}00136\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00137}00137\ } +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00138}00138\ } +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00139}00139\ \textcolor{comment}{/***************************************************************************}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00140}00140\ \textcolor{comment}{*******************************UTIL\_DEFINES********************************/}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00141}00141\ \textcolor{keyword}{static}\ \textcolor{keywordtype}{int}\ dummy;\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00142}00142\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00143}00143\ \textcolor{comment}{\ \ *\ @addtogroup\ UTILS\_DEFINES\ \ \ \ \ \ Utils\ defines}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00144}00144\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ MYLIBS\_DEFINES}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00145}00145\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Общие\ вспомогательные\ макросы}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00146}00146\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00147}00147\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00148}00148\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00149}00149\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00150}00150\ \textcolor{comment}{\ *\ @brief\ Обнуление\ структуры.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00151}00151\ \textcolor{comment}{\ *\ @param\ \_struct\_\ Структура,\ которую\ нужно\ обнулить.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00152}00152\ \textcolor{comment}{\ *\ @details\ Макрос\ использует\ memset\ для\ обнуления\ всей\ памяти\ структуры.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00153}00153\ \textcolor{comment}{\ *\ Используется\ для\ быстрой\ и\ безопасной\ инициализации\ переменных\ структур\ до\ нуля.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00154}00154\ \textcolor{comment}{\ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00155}\mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gaf5e598848326d48e86167e5099a029be}{00155}}\ \textcolor{preprocessor}{\#define\ ClearStruct(\_struct\_)\ \ \ \ \ memset(\&(\_struct\_),\ 0,\ sizeof(\_struct\_))}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00156}00156\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00157}00157\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00158}00158\ \textcolor{comment}{\ \ *\ @brief\ \ Деление\ с\ округлением\ вверх}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00159}00159\ \textcolor{comment}{\ \ *\ @param\ \_val\_\ Делимое.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00160}00160\ \textcolor{comment}{\ \ *\ @param\ \_div\_\ Делитель.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00161}00161\ \textcolor{comment}{\ \ *\ @return\ Результат\ деления,\ округленный\ вверх.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00162}00162\ \textcolor{comment}{\ \ *\ @details\ \ Если\ результат\ деления\ без\ остатка:\ он\ возвращается\ как\ есть}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00163}00163\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ \ \ Если\ с\ остатком\ -\/\ округляется\ вверх}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00164}00164\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00165}00165\ \textcolor{comment}{//\#define\ Divide\_Up(\_val\_,\ \_div\_)\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (((\_val\_)\%(\_div\_))?\ (\_val\_)/(\_div\_)+1\ :\ (\_val\_)/\_div\_)\ \ /*\ через\ тернарный\ оператор\ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00166}\mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_gabf45f2b60eedf80cf9d1dbe4302a741e}{00166}}\ \textcolor{preprocessor}{\#define\ Divide\_Up(\_val\_,\ \_div\_)\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ((\_val\_\ -\/\ 1)\ /\ \_div\_)\ +\ 1\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\textcolor{comment}{/*\ через\ мат\ выражение\ */}\textcolor{preprocessor}{\ }} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00167}00167\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00168}00168\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00169}00169\ \textcolor{comment}{\ \ *\ @brief\ \ Swap\ between\ Little\ Endian\ and\ Big\ Endian}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00170}00170\ \textcolor{comment}{\ \ *\ @param\ v\ Исходное\ 16-\/битное\ значение.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00171}00171\ \textcolor{comment}{\ \ *\ @return\ Результат\ с\ поменяными\ местами\ старшим\ и\ младшим\ байтом.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00172}00172\ \textcolor{comment}{\ \ *\ @details\ \ Переключения\ между\ двумя\ типами\ хранения\ слова:\ HI-\/LO\ байты\ и\ LO-\/HI\ байты.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00173}00173\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00174}\mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga0f22e895ac7781c3d1b68fee182c4291}{00174}}\ \textcolor{preprocessor}{\#define\ ByteSwap16(v)\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (((v\&0xFF00)\ >>\ (8))\ |\ ((v\&0x00FF)\ <<\ (8)))}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00175}00175\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00176}00176\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00177}00177\ \textcolor{comment}{\ \ *\ @brief\ \ Абсолютное\ значение\ числа}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00178}00178\ \textcolor{comment}{\ \ *\ @param\ x\ Число.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00179}00179\ \textcolor{comment}{\ \ *\ @return\ Абсолютное\ значение\ числа\ x.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00180}00180\ \textcolor{comment}{\ \ *\ @details\ \ Берет\ число\ по\ модулю.\ Хз\ как\ работает\ библиотечный\ abs\ в\ stdlib.h,\ мб\ это\ быстрее,\ но\ вряд\ ли\ конечно.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00181}00181\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00182}\mbox{\hyperlink{group___u_t_i_l_s___d_e_f_i_n_e_s_ga996f7be338ccb40d1a2a5abc1ad61759}{00182}}\ \textcolor{preprocessor}{\#define\ ABS(x)\ (\ ((x)\ >\ 0)?\ (x)\ :\ -\/(x))}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00183}00183\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00184}00184\ \textcolor{comment}{/**\ UTILS\_DEFINES}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00185}00185\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00186}00186\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00187}00187\ \ \ } +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00188}00188\ } +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00189}00189\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00190}00190\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00191}00191\ \textcolor{comment}{\ *\ @cond\ LIBS\_INTERNAL}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00192}00192\ \textcolor{comment}{\ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00193}00193\ } +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00194}00194\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00195}00195\ \textcolor{comment}{/**\ \ }} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00196}00196\ \textcolor{comment}{\ \ *\ @brief\ \ Аналог\ HAL\ макроса\ для\ привязки\ DMA\ к\ UART.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00197}00197\ \textcolor{comment}{\ \ *\ @note\ \ \ @ref\ \_\_HAL\_LINKDMA.}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00198}00198\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00199}00199\ \textcolor{preprocessor}{\#define\ \_\_USER\_LINKDMA(\_\_HANDLE\_\_,\ \_\_PPP\_DMA\_FIELD\_\_,\ \_\_DMA\_HANDLE\_\_)\ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00200}00200\ \textcolor{preprocessor}{do\{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00201}00201\ \textcolor{preprocessor}{(\_\_HANDLE\_\_)-\/>\_\_PPP\_DMA\_FIELD\_\_\ =\ (\_\_DMA\_HANDLE\_\_);\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00202}00202\ \textcolor{preprocessor}{(\_\_DMA\_HANDLE\_\_)-\/>Parent\ =\ (\_\_HANDLE\_\_);\}\ while(0U)}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00203}00203\ } +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00204}00204\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00205}00205\ \textcolor{comment}{/**\ @endcond\ */}} +\DoxyCodeLine{\Hypertarget{mylibs__defs_8h_source_l00206}00206\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\_\_MYLIBS\_DEFINES\_H\_}} \end{DoxyCode} diff --git a/Doc/latex/mylibs__include_8h.tex b/Doc/latex/mylibs__include_8h.tex index 76892b9..6b0b211 100644 --- a/Doc/latex/mylibs__include_8h.tex +++ b/Doc/latex/mylibs__include_8h.tex @@ -1,5 +1,5 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/mylibs\+\_\+include.h File Reference} -\hypertarget{mylibs__include_8h}{}\label{mylibs__include_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_include.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_include.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/mylibs\+\_\+include.h File Reference} +\hypertarget{mylibs__include_8h}{}\label{mylibs__include_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_include.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_include.h}} Заголочный файл для всех библиотек @@ -11,10 +11,11 @@ {\ttfamily \#include "{}trackers.\+h"{}}\newline {\ttfamily \#include "{}trace.\+h"{}}\newline {\ttfamily \#include "{}evolve\+\_\+optimizer.\+h"{}}\newline -{\ttfamily \#include "{}general\+\_\+flash.\+h"{}}\newline +{\ttfamily \#include "{}\+\_\+\+\_\+general\+\_\+flash.\+h"{}}\newline {\ttfamily \#include "{}general\+\_\+gpio.\+h"{}}\newline {\ttfamily \#include "{}general\+\_\+tim.\+h"{}}\newline -Include dependency graph for mylibs\+\_\+include.\+h\+:\nopagebreak +Include dependency graph for mylibs\+\_\+include.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode diff --git a/Doc/latex/mylibs__include_8h__incl.md5 b/Doc/latex/mylibs__include_8h__incl.md5 index f52fb61..c15d6e6 100644 --- a/Doc/latex/mylibs__include_8h__incl.md5 +++ b/Doc/latex/mylibs__include_8h__incl.md5 @@ -1 +1 @@ -8121715bde1cc32481a3a48c6e1c486d \ No newline at end of file +eb944b0f31d4c04035027b6a55300940 \ No newline at end of file diff --git a/Doc/latex/mylibs__include_8h__incl.pdf b/Doc/latex/mylibs__include_8h__incl.pdf index 882ee8f..49c6588 100644 Binary files a/Doc/latex/mylibs__include_8h__incl.pdf and b/Doc/latex/mylibs__include_8h__incl.pdf differ diff --git a/Doc/latex/mylibs__include_8h_source.tex b/Doc/latex/mylibs__include_8h_source.tex index 46d0545..37dcfd4 100644 --- a/Doc/latex/mylibs__include_8h_source.tex +++ b/Doc/latex/mylibs__include_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{mylibs\+\_\+include.\+h} -\hypertarget{mylibs__include_8h_source}{}\label{mylibs__include_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_include.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_include.h}} +\hypertarget{mylibs__include_8h_source}{}\label{mylibs__include_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_include.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/mylibs\_include.h}} \mbox{\hyperlink{mylibs__include_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00001}00001\ \textcolor{comment}{/**\ }} @@ -102,13 +102,13 @@ \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00098}00098\ } \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00099}00099\ \textcolor{preprocessor}{\#ifdef\ INCLUDE\_GENERAL\_PERIPH\_LIBS}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00100}00100\ } -\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00101}00101\ \textcolor{preprocessor}{\#include\ "{}general\_flash.h"{}}} +\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00101}00101\ \textcolor{preprocessor}{\#include\ "{}\_\_general\_flash.h"{}}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00102}00102\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{general__gpio_8h}{general\_gpio.h}}"{}}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00103}00103\ \textcolor{preprocessor}{\#ifdef\ HAL\_SPI\_MODULE\_ENABLED}} -\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00104}00104\ \textcolor{preprocessor}{\#include\ "{}general\_spi.h"{}}} +\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00104}00104\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{general__spi_8h}{general\_spi.h}}"{}}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00105}00105\ \textcolor{preprocessor}{\#endif}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00106}00106\ \textcolor{preprocessor}{\#ifdef\ HAL\_UART\_MODULE\_ENABLED}} -\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00107}00107\ \textcolor{preprocessor}{\#include\ "{}general\_uart.h"{}}} +\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00107}00107\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{general__uart_8h}{general\_uart.h}}"{}}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00108}00108\ \textcolor{preprocessor}{\#endif}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00109}00109\ \textcolor{preprocessor}{\#ifdef\ HAL\_TIM\_MODULE\_ENABLED}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00110}00110\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{general__tim_8h}{general\_tim.h}}"{}}} @@ -120,11 +120,11 @@ \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00116}00116\ } \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00117}00117\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00118}00118\ \textcolor{comment}{/////////////////////////-\/-\/-\/USER\ SETTINGS-\/-\/-\//////////////////////////}} -\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00119}00119\ \textcolor{comment}{}\textcolor{comment}{//\ user\ includes}} +\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00119}00119\ \textcolor{comment}{//\ user\ includes}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00120}00120\ } \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00121}00121\ \textcolor{comment}{//\ user\ settings}\textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00122}00122\ \textcolor{comment}{/////////////////////////-\/-\/-\/USER\ SETTINGS-\/-\/-\//////////////////////////}} -\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00123}00123\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00123}00123\ } \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00124}00124\ } \DoxyCodeLine{\Hypertarget{mylibs__include_8h_source_l00125}00125\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ \_\_MYLIBS\_INCLUDE\_H\_}} diff --git a/Doc/latex/refman.tex b/Doc/latex/refman.tex index 1555761..f372478 100644 --- a/Doc/latex/refman.tex +++ b/Doc/latex/refman.tex @@ -1,7 +1,16 @@ % Handle batch mode % to overcome problems with too many open files \let\mypdfximage\pdfximage\def\pdfximage{\immediate\mypdfximage} - \pdfminorversion=7 + \RequirePackage{iftex} + \ifLuaTeX + \directlua{pdf.setminorversion(7)} + \fi + \ifXeTeX + \special{pdf:minorversion 7} + \fi + \ifPDFTeX + \pdfminorversion=7 + \fi % Set document class depending on configuration \documentclass[twoside]{book} %% moved from doxygen.sty due to workaround for LaTex 2019 version and unmaintained tabu package @@ -22,10 +31,18 @@ \let\protected@wlog\@@protected@wlog \makeatother \IfFormatAtLeastTF{2016/01/01}{}{\usepackage{fixltx2e}} % for \textsubscript - \IfFormatAtLeastTF{2015/01/01}{\pdfsuppresswarningpagegroup=1}{} + \ifPDFTeX + \IfFormatAtLeastTF{2015/01/01}{\pdfsuppresswarningpagegroup=1}{} + \fi \usepackage{doxygen} \usepackage{graphicx} - \usepackage[utf8]{inputenc} + \iftutex + \usepackage{fontspec} + \defaultfontfeatures{Ligatures={TeX}} + \usepackage{unicode-math} + \else + \usepackage[utf8]{inputenc} + \fi \usepackage{makeidx} \PassOptionsToPackage{warn}{textcomp} \usepackage{textcomp} @@ -34,7 +51,10 @@ % NLS support packages % Define default fonts % Font selection - \usepackage[T1]{fontenc} + \iftutex + \else + \usepackage[T1]{fontenc} + \fi % set main and monospaced font \usepackage[scaled=.90]{helvet} \usepackage{courier} @@ -115,13 +135,14 @@ } % ToC, LoF, LoT, bibliography, and index % Indices & bibliography - \usepackage{natbib} + \usepackage[numbers]{natbib} \usepackage[titles]{tocloft} \setcounter{tocdepth}{3} \setcounter{secnumdepth}{5} % creating indexes \makeindex - \usepackage{newunicodechar} + \ifPDFTeX +\usepackage{newunicodechar} \makeatletter \def\doxynewunicodechar#1#2{% \@tempswafalse @@ -140,15 +161,20 @@ \doxynewunicodechar{⁻}{${}^{-}$}% Superscript minus \doxynewunicodechar{²}{${}^{2}$}% Superscript two \doxynewunicodechar{³}{${}^{3}$}% Superscript three +\fi % Hyperlinks % Hyperlinks (required, but should be loaded last) - \ifpdf + \ifPDFTeX \usepackage[pdftex,pagebackref=true]{hyperref} \else - \ifxetex - \usepackage[pagebackref=true]{hyperref} + \ifXeTeX + \usepackage[xetex,pagebackref=true]{hyperref} \else - \usepackage[ps2pdf,pagebackref=true]{hyperref} + \ifLuaTeX + \usepackage[luatex,pagebackref=true]{hyperref} + \else + \usepackage[ps2pdf,pagebackref=true]{hyperref} + \fi \fi \fi \hypersetup{% @@ -196,7 +222,7 @@ {\Large My\+Libs}\\ [1ex]\large 1.\+0 \\ \vspace*{1cm} - {\large Generated by Doxygen 1.10.0}\\ + {\large Generated by Doxygen 1.14.0}\\ \end{center} \end{titlepage} \clearemptydoublepage @@ -232,16 +258,18 @@ \input{unionuint8___bit_type_def} \chapter{File Documentation} \input{____general__flash_8h_source} -\input{____general__spi_8h_source} -\input{____general__uart_8h_source} \input{bit__access_8h} \input{bit__access_8h_source} \input{evolve__optimizer_8h} \input{evolve__optimizer_8h_source} \input{general__gpio_8h} \input{general__gpio_8h_source} +\input{general__spi_8h} +\input{general__spi_8h_source} \input{general__tim_8h} \input{general__tim_8h_source} +\input{general__uart_8h} +\input{general__uart_8h_source} \input{mylibs__config_8h} \input{mylibs__config_8h_source} \input{mylibs__defs_8h} @@ -254,12 +282,14 @@ \input{trackers_8h_source} \input{mainpage_8h_source} \input{____general__flash_8c_source} -\input{____general__spi_8c_source} -\input{____general__uart_8c_source} \input{general__gpio_8c} \input{general__gpio_8c_source} +\input{general__spi_8c} +\input{general__spi_8c_source} \input{general__tim_8c} \input{general__tim_8c_source} +\input{general__uart_8c} +\input{general__uart_8c_source} %--- End generated contents --- % Index \backmatter diff --git a/Doc/latex/struct_evolve_optimizer__t.tex b/Doc/latex/struct_evolve_optimizer__t.tex index 3cfe9cd..ae00363 100644 --- a/Doc/latex/struct_evolve_optimizer__t.tex +++ b/Doc/latex/struct_evolve_optimizer__t.tex @@ -24,6 +24,10 @@ float \mbox{\hyperlink{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f \begin{DoxyCompactList}\small\item\em Амплитуда мутации (0..1) \end{DoxyCompactList}\item uint16\+\_\+t \mbox{\hyperlink{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}{cand\+\_\+index}} \begin{DoxyCompactList}\small\item\em Индекс кандидата для обработки \end{DoxyCompactList}\item +uint16\+\_\+t \mbox{\hyperlink{struct_evolve_optimizer__t_ad0f464d7048a9ed0753b61f76f563108}{gen\+\_\+index}} +\begin{DoxyCompactList}\small\item\em Индекс популяции \end{DoxyCompactList}\item +float \mbox{\hyperlink{struct_evolve_optimizer__t_a3be8c0c34db8429210ff470497a56727}{gen\+\_\+mut}} +\begin{DoxyCompactList}\small\item\em Амплитуда мутации у текущей популяции \end{DoxyCompactList}\item float \mbox{\hyperlink{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}{loss}} \mbox{[}100\mbox{]} \begin{DoxyCompactList}\small\item\em Loss для каждого кандидата \end{DoxyCompactList}\item float \mbox{\hyperlink{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}{candidates}} \mbox{[}100\mbox{]}\mbox{[}20\mbox{]} @@ -39,12 +43,14 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00102}{102}} of +\label{doc-variable-members} +\Hypertarget{struct_evolve_optimizer__t_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}\label{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!stability@{stability}} +\Hypertarget{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!stability@{stability}} \index{stability@{stability}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{stability}{stability}} -{\footnotesize\ttfamily float Evolve\+Optimizer\+\_\+t\+::stability} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_a80eb0b8525b6bb838484f5922b9d8f7c} +float Evolve\+Optimizer\+\_\+t\+::stability} @@ -54,11 +60,11 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00102}{102}} of Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00103}{103}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}\label{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!n\_params@{n\_params}} +\Hypertarget{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!n\_params@{n\_params}} \index{n\_params@{n\_params}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{n\_params}{n\_params}} -{\footnotesize\ttfamily uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::n\+\_\+params} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_a1c270fce82e0c97e6c88fd0971c1eed8} +uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::n\+\_\+params} @@ -66,13 +72,13 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00103}{103}} of -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00104}{104}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00105}{105}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}\label{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!n\_cand@{n\_cand}} +\Hypertarget{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!n\_cand@{n\_cand}} \index{n\_cand@{n\_cand}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{n\_cand}{n\_cand}} -{\footnotesize\ttfamily uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::n\+\_\+cand} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_ac35c7ca8cede4ab9c53a2845a91cd1b1} +uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::n\+\_\+cand} @@ -80,13 +86,13 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00104}{104}} of -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00105}{105}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00106}{106}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}\label{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!n\_best@{n\_best}} +\Hypertarget{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!n\_best@{n\_best}} \index{n\_best@{n\_best}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{n\_best}{n\_best}} -{\footnotesize\ttfamily uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::n\+\_\+best} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_a950cd70cb6bff33b78ad35ee58c729a6} +uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::n\+\_\+best} @@ -94,13 +100,13 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00105}{105}} of -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00106}{106}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00107}{107}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}\label{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!mutation\_amp@{mutation\_amp}} +\Hypertarget{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!mutation\_amp@{mutation\_amp}} \index{mutation\_amp@{mutation\_amp}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{mutation\_amp}{mutation\_amp}} -{\footnotesize\ttfamily float Evolve\+Optimizer\+\_\+t\+::mutation\+\_\+amp} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_af779c7aeba0053e36cee7aade160f1c8} +float Evolve\+Optimizer\+\_\+t\+::mutation\+\_\+amp} @@ -108,13 +114,13 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00106}{106}} of -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00107}{107}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00108}{108}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}\label{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!cand\_index@{cand\_index}} +\Hypertarget{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!cand\_index@{cand\_index}} \index{cand\_index@{cand\_index}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{cand\_index}{cand\_index}} -{\footnotesize\ttfamily uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::cand\+\_\+index} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_a0ae0e63ba351335d4445d927991c64ae} +uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::cand\+\_\+index} @@ -122,13 +128,41 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00107}{107}} of -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00108}{108}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00110}{110}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}\label{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!loss@{loss}} +\Hypertarget{struct_evolve_optimizer__t_ad0f464d7048a9ed0753b61f76f563108}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!gen\_index@{gen\_index}} +\index{gen\_index@{gen\_index}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} +\doxysubsubsection{\texorpdfstring{gen\_index}{gen\_index}} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_ad0f464d7048a9ed0753b61f76f563108} +uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::gen\+\_\+index} + + + +Индекс популяции + + + +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00111}{111}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. + +\Hypertarget{struct_evolve_optimizer__t_a3be8c0c34db8429210ff470497a56727}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!gen\_mut@{gen\_mut}} +\index{gen\_mut@{gen\_mut}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} +\doxysubsubsection{\texorpdfstring{gen\_mut}{gen\_mut}} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_a3be8c0c34db8429210ff470497a56727} +float Evolve\+Optimizer\+\_\+t\+::gen\+\_\+mut} + + + +Амплитуда мутации у текущей популяции + + + +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00114}{114}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. + +\Hypertarget{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!loss@{loss}} \index{loss@{loss}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{loss}{loss}} -{\footnotesize\ttfamily float Evolve\+Optimizer\+\_\+t\+::loss\mbox{[}100\mbox{]}} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_a93f628397c2f8d4027f2906752b650df} +float Evolve\+Optimizer\+\_\+t\+::loss\mbox{[}100\mbox{]}} @@ -136,13 +170,13 @@ Loss для каждого кандидата -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00109}{109}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00116}{116}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}\label{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!candidates@{candidates}} +\Hypertarget{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!candidates@{candidates}} \index{candidates@{candidates}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{candidates}{candidates}} -{\footnotesize\ttfamily float Evolve\+Optimizer\+\_\+t\+::candidates\mbox{[}100\mbox{]}\mbox{[}20\mbox{]}} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_aec67667fd1f1533e693e41c79bc28da4} +float Evolve\+Optimizer\+\_\+t\+::candidates\mbox{[}100\mbox{]}\mbox{[}20\mbox{]}} @@ -150,13 +184,13 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00109}{109}} of -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00110}{110}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00117}{117}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. -\Hypertarget{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}\label{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a} -\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!sorted\_idx@{sorted\_idx}} +\Hypertarget{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a}\index{EvolveOptimizer\_t@{EvolveOptimizer\_t}!sorted\_idx@{sorted\_idx}} \index{sorted\_idx@{sorted\_idx}!EvolveOptimizer\_t@{EvolveOptimizer\_t}} \doxysubsubsection{\texorpdfstring{sorted\_idx}{sorted\_idx}} -{\footnotesize\ttfamily uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::sorted\+\_\+idx\mbox{[}100\mbox{]}} +{\footnotesize\ttfamily \label{struct_evolve_optimizer__t_a74b81df1c298c99162310f3f7d91735a} +uint16\+\_\+t Evolve\+Optimizer\+\_\+t\+::sorted\+\_\+idx\mbox{[}100\mbox{]}} @@ -164,10 +198,10 @@ Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00110}{110}} of -Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00111}{111}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. +Definition at line \mbox{\hyperlink{evolve__optimizer_8h_source_l00118}{118}} of file \mbox{\hyperlink{evolve__optimizer_8h_source}{evolve\+\_\+optimizer.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{evolve__optimizer_8h}{evolve\+\_\+optimizer.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{evolve__optimizer_8h}{evolve\+\_\+optimizer.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/struct_g_p_i_o___l_e_d_type_def.tex b/Doc/latex/struct_g_p_i_o___l_e_d_type_def.tex index 3ea2200..d77e973 100644 --- a/Doc/latex/struct_g_p_i_o___l_e_d_type_def.tex +++ b/Doc/latex/struct_g_p_i_o___l_e_d_type_def.tex @@ -29,16 +29,18 @@ uint32\+\_\+t \mbox{\hyperlink{struct_g_p_i_o___l_e_d_type_def_a8c43c12787f4a89f \doxysubsection{Detailed Description} Структура светодиода -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00093}{93}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00073}{73}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +\label{doc-variable-members} +\Hypertarget{struct_g_p_i_o___l_e_d_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435}\label{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435} -\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!state@{state}} +\Hypertarget{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435}\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!state@{state}} \index{state@{state}!GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}} \doxysubsubsection{\texorpdfstring{state}{state}} -{\footnotesize\ttfamily \mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{GPIO\+\_\+\+LEDState\+Type\+Def}} GPIO\+\_\+\+LEDType\+Def\+::state} +{\footnotesize\ttfamily \label{struct_g_p_i_o___l_e_d_type_def_ad28d93023a00e3c5669bd3deda122435} +\mbox{\hyperlink{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s_gaac2b90d8b8c9579b6aa5d3bbda9b1ff1}{GPIO\+\_\+\+LEDState\+Type\+Def}} GPIO\+\_\+\+LEDType\+Def\+::state} @@ -46,13 +48,13 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00093}{93}} of file -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00095}{95}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00075}{75}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___l_e_d_type_def_a831923d4d157267ecc2f1add1c49adcf}\label{struct_g_p_i_o___l_e_d_type_def_a831923d4d157267ecc2f1add1c49adcf} -\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!LED\_Port@{LED\_Port}} +\Hypertarget{struct_g_p_i_o___l_e_d_type_def_a831923d4d157267ecc2f1add1c49adcf}\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!LED\_Port@{LED\_Port}} \index{LED\_Port@{LED\_Port}!GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}} \doxysubsubsection{\texorpdfstring{LED\_Port}{LED\_Port}} -{\footnotesize\ttfamily GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} GPIO\+\_\+\+LEDType\+Def\+::\+LED\+\_\+\+Port} +{\footnotesize\ttfamily \label{struct_g_p_i_o___l_e_d_type_def_a831923d4d157267ecc2f1add1c49adcf} +GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} GPIO\+\_\+\+LEDType\+Def\+::\+LED\+\_\+\+Port} @@ -60,13 +62,13 @@ GPIO порт ножки светодиода -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00097}{97}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00077}{77}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___l_e_d_type_def_a684ff60e4c94daf2221524cdc6fcc978}\label{struct_g_p_i_o___l_e_d_type_def_a684ff60e4c94daf2221524cdc6fcc978} -\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!LED\_Pin@{LED\_Pin}} +\Hypertarget{struct_g_p_i_o___l_e_d_type_def_a684ff60e4c94daf2221524cdc6fcc978}\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!LED\_Pin@{LED\_Pin}} \index{LED\_Pin@{LED\_Pin}!GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}} \doxysubsubsection{\texorpdfstring{LED\_Pin}{LED\_Pin}} -{\footnotesize\ttfamily uint32\+\_\+t GPIO\+\_\+\+LEDType\+Def\+::\+LED\+\_\+\+Pin} +{\footnotesize\ttfamily \label{struct_g_p_i_o___l_e_d_type_def_a684ff60e4c94daf2221524cdc6fcc978} +uint32\+\_\+t GPIO\+\_\+\+LEDType\+Def\+::\+LED\+\_\+\+Pin} @@ -74,13 +76,13 @@ GPIO пин ножки светодиода -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00098}{98}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00078}{78}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___l_e_d_type_def_abe9aadc0b28d042267f7155e187a1816}\label{struct_g_p_i_o___l_e_d_type_def_abe9aadc0b28d042267f7155e187a1816} -\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!LED\_ActiveLvl@{LED\_ActiveLvl}} +\Hypertarget{struct_g_p_i_o___l_e_d_type_def_abe9aadc0b28d042267f7155e187a1816}\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!LED\_ActiveLvl@{LED\_ActiveLvl}} \index{LED\_ActiveLvl@{LED\_ActiveLvl}!GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}} \doxysubsubsection{\texorpdfstring{LED\_ActiveLvl}{LED\_ActiveLvl}} -{\footnotesize\ttfamily uint8\+\_\+t GPIO\+\_\+\+LEDType\+Def\+::\+LED\+\_\+\+Active\+Lvl} +{\footnotesize\ttfamily \label{struct_g_p_i_o___l_e_d_type_def_abe9aadc0b28d042267f7155e187a1816} +uint8\+\_\+t GPIO\+\_\+\+LEDType\+Def\+::\+LED\+\_\+\+Active\+Lvl} @@ -88,13 +90,13 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00098}{98}} of file -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00100}{100}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00080}{80}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec}\label{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec} -\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!LED\_Period@{LED\_Period}} +\Hypertarget{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec}\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!LED\_Period@{LED\_Period}} \index{LED\_Period@{LED\_Period}!GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}} \doxysubsubsection{\texorpdfstring{LED\_Period}{LED\_Period}} -{\footnotesize\ttfamily uint32\+\_\+t GPIO\+\_\+\+LEDType\+Def\+::\+LED\+\_\+\+Period} +{\footnotesize\ttfamily \label{struct_g_p_i_o___l_e_d_type_def_a6cc026931a4681732f9a329ae03098ec} +uint32\+\_\+t GPIO\+\_\+\+LEDType\+Def\+::\+LED\+\_\+\+Period} @@ -102,20 +104,20 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00100}{100}} of fil -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00101}{101}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00081}{81}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___l_e_d_type_def_a8c43c12787f4a89f4a785f91a979ba68}\label{struct_g_p_i_o___l_e_d_type_def_a8c43c12787f4a89f4a785f91a979ba68} -\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!tickprev@{tickprev}} +\Hypertarget{struct_g_p_i_o___l_e_d_type_def_a8c43c12787f4a89f4a785f91a979ba68}\index{GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}!tickprev@{tickprev}} \index{tickprev@{tickprev}!GPIO\_LEDTypeDef@{GPIO\_LEDTypeDef}} \doxysubsubsection{\texorpdfstring{tickprev}{tickprev}} -{\footnotesize\ttfamily uint32\+\_\+t GPIO\+\_\+\+LEDType\+Def\+::tickprev} +{\footnotesize\ttfamily \label{struct_g_p_i_o___l_e_d_type_def_a8c43c12787f4a89f4a785f91a979ba68} +uint32\+\_\+t GPIO\+\_\+\+LEDType\+Def\+::tickprev} -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00103}{103}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00083}{83}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__gpio_8h}{general\+\_\+gpio.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__gpio_8h}{general\+\_\+gpio.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/struct_g_p_i_o___switch_type_def.tex b/Doc/latex/struct_g_p_i_o___switch_type_def.tex index 336ccdb..907d240 100644 --- a/Doc/latex/struct_g_p_i_o___switch_type_def.tex +++ b/Doc/latex/struct_g_p_i_o___switch_type_def.tex @@ -29,16 +29,18 @@ uint32\+\_\+t \mbox{\hyperlink{struct_g_p_i_o___switch_type_def_a13f97b867ff1a77 \doxysubsection{Detailed Description} Структура кнопки -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00110}{110}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00090}{90}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +\label{doc-variable-members} +\Hypertarget{struct_g_p_i_o___switch_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a}\label{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a} -\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_Port@{Sw\_Port}} +\Hypertarget{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a}\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_Port@{Sw\_Port}} \index{Sw\_Port@{Sw\_Port}!GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}} \doxysubsubsection{\texorpdfstring{Sw\_Port}{Sw\_Port}} -{\footnotesize\ttfamily GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Port} +{\footnotesize\ttfamily \label{struct_g_p_i_o___switch_type_def_afb369df75a6065fd89ac4ba97d98ab1a} +GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Port} @@ -46,13 +48,13 @@ GPIO порт ножки кнопки -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00112}{112}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00092}{92}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032}\label{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032} -\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_Pin@{Sw\_Pin}} +\Hypertarget{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032}\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_Pin@{Sw\_Pin}} \index{Sw\_Pin@{Sw\_Pin}!GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}} \doxysubsubsection{\texorpdfstring{Sw\_Pin}{Sw\_Pin}} -{\footnotesize\ttfamily uint32\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Pin} +{\footnotesize\ttfamily \label{struct_g_p_i_o___switch_type_def_a63d58d9cba49a5823175585ef2996032} +uint32\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Pin} @@ -60,13 +62,13 @@ GPIO пин ножки кнопки -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00113}{113}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00093}{93}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405}\label{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405} -\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_ActiveLvl@{Sw\_ActiveLvl}} +\Hypertarget{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405}\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_ActiveLvl@{Sw\_ActiveLvl}} \index{Sw\_ActiveLvl@{Sw\_ActiveLvl}!GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}} \doxysubsubsection{\texorpdfstring{Sw\_ActiveLvl}{Sw\_ActiveLvl}} -{\footnotesize\ttfamily uint8\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Active\+Lvl} +{\footnotesize\ttfamily \label{struct_g_p_i_o___switch_type_def_a4fadf5ead3ebccad521a52c064eeb405} +uint8\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Active\+Lvl} @@ -74,13 +76,13 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00113}{113}} of fil -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00115}{115}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00095}{95}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___switch_type_def_a245f1dc811279ce5d4598582db979a89}\label{struct_g_p_i_o___switch_type_def_a245f1dc811279ce5d4598582db979a89} -\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_PrevState@{Sw\_PrevState}} +\Hypertarget{struct_g_p_i_o___switch_type_def_a245f1dc811279ce5d4598582db979a89}\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_PrevState@{Sw\_PrevState}} \index{Sw\_PrevState@{Sw\_PrevState}!GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}} \doxysubsubsection{\texorpdfstring{Sw\_PrevState}{Sw\_PrevState}} -{\footnotesize\ttfamily uint32\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Prev\+State} +{\footnotesize\ttfamily \label{struct_g_p_i_o___switch_type_def_a245f1dc811279ce5d4598582db979a89} +uint32\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Prev\+State} @@ -88,13 +90,13 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00115}{115}} of fil -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00116}{116}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00096}{96}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}\label{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06} -\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_FilterDelay@{Sw\_FilterDelay}} +\Hypertarget{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06}\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!Sw\_FilterDelay@{Sw\_FilterDelay}} \index{Sw\_FilterDelay@{Sw\_FilterDelay}!GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}} \doxysubsubsection{\texorpdfstring{Sw\_FilterDelay}{Sw\_FilterDelay}} -{\footnotesize\ttfamily uint32\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Filter\+Delay} +{\footnotesize\ttfamily \label{struct_g_p_i_o___switch_type_def_a2600e599a961af2e280c721894df4c06} +uint32\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::\+Sw\+\_\+\+Filter\+Delay} @@ -102,20 +104,20 @@ Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00116}{116}} of fil -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00117}{117}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00097}{97}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. -\Hypertarget{struct_g_p_i_o___switch_type_def_a13f97b867ff1a77ef182c9b13d964ca6}\label{struct_g_p_i_o___switch_type_def_a13f97b867ff1a77ef182c9b13d964ca6} -\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!tickprev@{tickprev}} +\Hypertarget{struct_g_p_i_o___switch_type_def_a13f97b867ff1a77ef182c9b13d964ca6}\index{GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}!tickprev@{tickprev}} \index{tickprev@{tickprev}!GPIO\_SwitchTypeDef@{GPIO\_SwitchTypeDef}} \doxysubsubsection{\texorpdfstring{tickprev}{tickprev}} -{\footnotesize\ttfamily uint32\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::tickprev} +{\footnotesize\ttfamily \label{struct_g_p_i_o___switch_type_def_a13f97b867ff1a77ef182c9b13d964ca6} +uint32\+\_\+t GPIO\+\_\+\+Switch\+Type\+Def\+::tickprev} -Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00119}{119}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. +Definition at line \mbox{\hyperlink{general__gpio_8h_source_l00099}{99}} of file \mbox{\hyperlink{general__gpio_8h_source}{general\+\_\+gpio.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__gpio_8h}{general\+\_\+gpio.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__gpio_8h}{general\+\_\+gpio.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/struct_h_f___stack_frame__t.tex b/Doc/latex/struct_h_f___stack_frame__t.tex index a5f99ad..97e98a2 100644 --- a/Doc/latex/struct_h_f___stack_frame__t.tex +++ b/Doc/latex/struct_h_f___stack_frame__t.tex @@ -35,16 +35,18 @@ uint32\+\_\+t \mbox{\hyperlink{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd Сохраняет регистры R0-\/\+R3, R12, LR, PC, PSR для последующего анализа. -Definition at line \mbox{\hyperlink{trace_8h_source_l00463}{463}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00476}{476}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +\label{doc-variable-members} +\Hypertarget{struct_h_f___stack_frame__t_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413}\label{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413} -\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r0@{r0}} +\Hypertarget{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413}\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r0@{r0}} \index{r0@{r0}!HF\_StackFrame\_t@{HF\_StackFrame\_t}} \doxysubsubsection{\texorpdfstring{r0}{r0}} -{\footnotesize\ttfamily uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r0} +{\footnotesize\ttfamily \label{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413} +uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r0} @@ -52,13 +54,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00463}{463}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00464}{464}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00477}{477}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea}\label{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea} -\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r1@{r1}} +\Hypertarget{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea}\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r1@{r1}} \index{r1@{r1}!HF\_StackFrame\_t@{HF\_StackFrame\_t}} \doxysubsubsection{\texorpdfstring{r1}{r1}} -{\footnotesize\ttfamily uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r1} +{\footnotesize\ttfamily \label{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea} +uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r1} @@ -66,13 +68,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00464}{464}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00465}{465}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00478}{478}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b}\label{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b} -\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r2@{r2}} +\Hypertarget{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b}\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r2@{r2}} \index{r2@{r2}!HF\_StackFrame\_t@{HF\_StackFrame\_t}} \doxysubsubsection{\texorpdfstring{r2}{r2}} -{\footnotesize\ttfamily uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r2} +{\footnotesize\ttfamily \label{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b} +uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r2} @@ -80,13 +82,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00465}{465}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00466}{466}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00479}{479}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3}\label{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3} -\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r3@{r3}} +\Hypertarget{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3}\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r3@{r3}} \index{r3@{r3}!HF\_StackFrame\_t@{HF\_StackFrame\_t}} \doxysubsubsection{\texorpdfstring{r3}{r3}} -{\footnotesize\ttfamily uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r3} +{\footnotesize\ttfamily \label{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3} +uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r3} @@ -94,13 +96,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00466}{466}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00467}{467}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00480}{480}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b}\label{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b} -\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r12@{r12}} +\Hypertarget{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b}\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!r12@{r12}} \index{r12@{r12}!HF\_StackFrame\_t@{HF\_StackFrame\_t}} \doxysubsubsection{\texorpdfstring{r12}{r12}} -{\footnotesize\ttfamily uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r12} +{\footnotesize\ttfamily \label{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b} +uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::r12} @@ -108,13 +110,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00467}{467}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00468}{468}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00481}{481}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577}\label{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577} -\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!lr@{lr}} +\Hypertarget{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577}\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!lr@{lr}} \index{lr@{lr}!HF\_StackFrame\_t@{HF\_StackFrame\_t}} \doxysubsubsection{\texorpdfstring{lr}{lr}} -{\footnotesize\ttfamily uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::lr} +{\footnotesize\ttfamily \label{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577} +uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::lr} @@ -122,13 +124,13 @@ Link Register. -Definition at line \mbox{\hyperlink{trace_8h_source_l00469}{469}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00482}{482}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732}\label{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732} -\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!pc@{pc}} +\Hypertarget{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732}\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!pc@{pc}} \index{pc@{pc}!HF\_StackFrame\_t@{HF\_StackFrame\_t}} \doxysubsubsection{\texorpdfstring{pc}{pc}} -{\footnotesize\ttfamily uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::pc} +{\footnotesize\ttfamily \label{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732} +uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::pc} @@ -136,13 +138,13 @@ Program Counter. -Definition at line \mbox{\hyperlink{trace_8h_source_l00470}{470}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00483}{483}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9}\label{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9} -\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!psr@{psr}} +\Hypertarget{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9}\index{HF\_StackFrame\_t@{HF\_StackFrame\_t}!psr@{psr}} \index{psr@{psr}!HF\_StackFrame\_t@{HF\_StackFrame\_t}} \doxysubsubsection{\texorpdfstring{psr}{psr}} -{\footnotesize\ttfamily uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::psr} +{\footnotesize\ttfamily \label{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9} +uint32\+\_\+t HF\+\_\+\+Stack\+Frame\+\_\+t\+::psr} @@ -150,10 +152,10 @@ Program Status Register. -Definition at line \mbox{\hyperlink{trace_8h_source_l00471}{471}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00484}{484}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{trace_8h}{trace.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{trace_8h}{trace.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/struct_r_t_t___flash_header__t.tex b/Doc/latex/struct_r_t_t___flash_header__t.tex index 67dbed1..657aad4 100644 --- a/Doc/latex/struct_r_t_t___flash_header__t.tex +++ b/Doc/latex/struct_r_t_t___flash_header__t.tex @@ -23,16 +23,18 @@ char \mbox{\hyperlink{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d0 \doxysubsection{Detailed Description} Структура RTT, которая будет положена в Flash. -Definition at line \mbox{\hyperlink{trace_8h_source_l00180}{180}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00193}{193}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +\label{doc-variable-members} +\Hypertarget{struct_r_t_t___flash_header__t_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}\label{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57} -\index{RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}!tag@{tag}} +\Hypertarget{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}\index{RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}!tag@{tag}} \index{tag@{tag}!RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}} \doxysubsubsection{\texorpdfstring{tag}{tag}} -{\footnotesize\ttfamily uint32\+\_\+t RTT\+\_\+\+Flash\+Header\+\_\+t\+::tag} +{\footnotesize\ttfamily \label{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57} +uint32\+\_\+t RTT\+\_\+\+Flash\+Header\+\_\+t\+::tag} @@ -40,13 +42,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00180}{180}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00181}{181}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00194}{194}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}\label{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699} -\index{RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}!size@{size}} +\Hypertarget{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}\index{RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}!size@{size}} \index{size@{size}!RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}} \doxysubsubsection{\texorpdfstring{size}{size}} -{\footnotesize\ttfamily uint32\+\_\+t RTT\+\_\+\+Flash\+Header\+\_\+t\+::size} +{\footnotesize\ttfamily \label{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699} +uint32\+\_\+t RTT\+\_\+\+Flash\+Header\+\_\+t\+::size} @@ -54,13 +56,13 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00181}{181}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00182}{182}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00195}{195}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. -\Hypertarget{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}\label{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a} -\index{RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}!data@{data}} +\Hypertarget{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}\index{RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}!data@{data}} \index{data@{data}!RTT\_FlashHeader\_t@{RTT\_FlashHeader\_t}} \doxysubsubsection{\texorpdfstring{data}{data}} -{\footnotesize\ttfamily char RTT\+\_\+\+Flash\+Header\+\_\+t\+::data\mbox{[}1024\mbox{]}} +{\footnotesize\ttfamily \label{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a} +char RTT\+\_\+\+Flash\+Header\+\_\+t\+::data\mbox{[}1024\mbox{]}} @@ -68,10 +70,10 @@ Definition at line \mbox{\hyperlink{trace_8h_source_l00182}{182}} of file \mbox{ -Definition at line \mbox{\hyperlink{trace_8h_source_l00183}{183}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. +Definition at line \mbox{\hyperlink{trace_8h_source_l00196}{196}} of file \mbox{\hyperlink{trace_8h_source}{trace.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{trace_8h}{trace.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{trace_8h}{trace.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/struct_s_p_i___settings_type_def.tex b/Doc/latex/struct_s_p_i___settings_type_def.tex index d337f11..8fd1dbb 100644 --- a/Doc/latex/struct_s_p_i___settings_type_def.tex +++ b/Doc/latex/struct_s_p_i___settings_type_def.tex @@ -1,140 +1,225 @@ \doxysection{SPI\+\_\+\+Settings\+Type\+Def Struct Reference} \hypertarget{struct_s_p_i___settings_type_def}{}\label{struct_s_p_i___settings_type_def}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} + + +Структура настроек SPI. + + + + +{\ttfamily \#include $<$general\+\_\+spi.\+h$>$} + \doxysubsubsection*{Public Attributes} \begin{DoxyCompactItemize} \item SPI\+\_\+\+Handle\+Type\+Def \mbox{\hyperlink{struct_s_p_i___settings_type_def_ad203d8b8d67e4f477d002d15b03ba422}{hspi}} -\item +\begin{DoxyCompactList}\small\item\em HAL handle SPI. \end{DoxyCompactList}\item GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*} \mbox{\hyperlink{struct_s_p_i___settings_type_def_a6a15d48eccf92959de3a086031fdc979}{CLK\+\_\+\+GPIOx}} -\item +\begin{DoxyCompactList}\small\item\em Порт CLK. \end{DoxyCompactList}\item uint32\+\_\+t \mbox{\hyperlink{struct_s_p_i___settings_type_def_a3bcb1ed12da3544e02e6d36493669bdc}{CLK\+\_\+\+PIN}} -\item +\begin{DoxyCompactList}\small\item\em Пин CLK. \end{DoxyCompactList}\item uint32\+\_\+t \mbox{\hyperlink{struct_s_p_i___settings_type_def_a3f3748103a0b7861f6700042fd691ba1}{CLK\+\_\+\+GPIO\+\_\+\+Alternage\+Func}} -\item +\begin{DoxyCompactList}\small\item\em Альтернативная функция для CLK. \end{DoxyCompactList}\item GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*} \mbox{\hyperlink{struct_s_p_i___settings_type_def_a0d55a2941854f61934487f3d209cfa95}{MISO\+\_\+\+GPIOx}} -\item +\begin{DoxyCompactList}\small\item\em Порт MISO. \end{DoxyCompactList}\item uint32\+\_\+t \mbox{\hyperlink{struct_s_p_i___settings_type_def_a3366c654d7ec6dd41c6a0b504dc8509a}{MISO\+\_\+\+PIN}} -\item +\begin{DoxyCompactList}\small\item\em Пин MISO. \end{DoxyCompactList}\item uint32\+\_\+t \mbox{\hyperlink{struct_s_p_i___settings_type_def_aecd7a5c6e205335b8ed229d74cd35d14}{MISO\+\_\+\+GPIO\+\_\+\+Alternage\+Func}} -\item +\begin{DoxyCompactList}\small\item\em Альтернативная функция для MISO. \end{DoxyCompactList}\item GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*} \mbox{\hyperlink{struct_s_p_i___settings_type_def_a0af3bdb273818ff97eb4ff3cff918820}{MOSI\+\_\+\+GPIOx}} -\item +\begin{DoxyCompactList}\small\item\em Порт MOSI. \end{DoxyCompactList}\item uint32\+\_\+t \mbox{\hyperlink{struct_s_p_i___settings_type_def_a961208869faf4a7369aaf4edde75f176}{MOSI\+\_\+\+PIN}} -\item +\begin{DoxyCompactList}\small\item\em Пин MOSI. \end{DoxyCompactList}\item uint32\+\_\+t \mbox{\hyperlink{struct_s_p_i___settings_type_def_afbe75a1c36650a4a9b41fa706a4c7eab}{MOSI\+\_\+\+GPIO\+\_\+\+Alternage\+Func}} -\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Альтернативная функция для MOSI. \end{DoxyCompactList}\item +DMA\+\_\+\+Stream\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*} \mbox{\hyperlink{struct_s_p_i___settings_type_def_a3cfd9469b0617a68bbd2a161ba06bb95}{DMAChannel}} +\begin{DoxyCompactList}\small\item\em Канал DMA (NULL если не нужен) \end{DoxyCompactList}\item +uint32\+\_\+t \mbox{\hyperlink{struct_s_p_i___settings_type_def_aa0edaa145076d2383b3e0095d156d474}{DMA\+\_\+\+CHANNEL\+\_\+X}} +\begin{DoxyCompactList}\small\item\em Номер канала DMA (0 если не нужен) \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsection{Detailed Description} +Структура настроек SPI. +Содержит все необходимые параметры для инициализации SPI, включая GPIO и DMA. -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00033}{33}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00103}{103}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. +\label{doc-variable-members} +\Hypertarget{struct_s_p_i___settings_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_s_p_i___settings_type_def_ad203d8b8d67e4f477d002d15b03ba422}\label{struct_s_p_i___settings_type_def_ad203d8b8d67e4f477d002d15b03ba422} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!hspi@{hspi}} +\Hypertarget{struct_s_p_i___settings_type_def_ad203d8b8d67e4f477d002d15b03ba422}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!hspi@{hspi}} \index{hspi@{hspi}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{hspi}{hspi}} -{\footnotesize\ttfamily SPI\+\_\+\+Handle\+Type\+Def SPI\+\_\+\+Settings\+Type\+Def\+::hspi} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_ad203d8b8d67e4f477d002d15b03ba422} +SPI\+\_\+\+Handle\+Type\+Def SPI\+\_\+\+Settings\+Type\+Def\+::hspi} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00035}{35}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +HAL handle SPI. -\Hypertarget{struct_s_p_i___settings_type_def_a6a15d48eccf92959de3a086031fdc979}\label{struct_s_p_i___settings_type_def_a6a15d48eccf92959de3a086031fdc979} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!CLK\_GPIOx@{CLK\_GPIOx}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00105}{105}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_a6a15d48eccf92959de3a086031fdc979}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!CLK\_GPIOx@{CLK\_GPIOx}} \index{CLK\_GPIOx@{CLK\_GPIOx}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{CLK\_GPIOx}{CLK\_GPIOx}} -{\footnotesize\ttfamily GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} SPI\+\_\+\+Settings\+Type\+Def\+::\+CLK\+\_\+\+GPIOx} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_a6a15d48eccf92959de3a086031fdc979} +GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} SPI\+\_\+\+Settings\+Type\+Def\+::\+CLK\+\_\+\+GPIOx} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00037}{37}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Порт CLK. -\Hypertarget{struct_s_p_i___settings_type_def_a3bcb1ed12da3544e02e6d36493669bdc}\label{struct_s_p_i___settings_type_def_a3bcb1ed12da3544e02e6d36493669bdc} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!CLK\_PIN@{CLK\_PIN}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00107}{107}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_a3bcb1ed12da3544e02e6d36493669bdc}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!CLK\_PIN@{CLK\_PIN}} \index{CLK\_PIN@{CLK\_PIN}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{CLK\_PIN}{CLK\_PIN}} -{\footnotesize\ttfamily uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+CLK\+\_\+\+PIN} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_a3bcb1ed12da3544e02e6d36493669bdc} +uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+CLK\+\_\+\+PIN} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00038}{38}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Пин CLK. -\Hypertarget{struct_s_p_i___settings_type_def_a3f3748103a0b7861f6700042fd691ba1}\label{struct_s_p_i___settings_type_def_a3f3748103a0b7861f6700042fd691ba1} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!CLK\_GPIO\_AlternageFunc@{CLK\_GPIO\_AlternageFunc}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00108}{108}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_a3f3748103a0b7861f6700042fd691ba1}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!CLK\_GPIO\_AlternageFunc@{CLK\_GPIO\_AlternageFunc}} \index{CLK\_GPIO\_AlternageFunc@{CLK\_GPIO\_AlternageFunc}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{CLK\_GPIO\_AlternageFunc}{CLK\_GPIO\_AlternageFunc}} -{\footnotesize\ttfamily uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+CLK\+\_\+\+GPIO\+\_\+\+Alternage\+Func} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_a3f3748103a0b7861f6700042fd691ba1} +uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+CLK\+\_\+\+GPIO\+\_\+\+Alternage\+Func} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00039}{39}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Альтернативная функция для CLK. -\Hypertarget{struct_s_p_i___settings_type_def_a0d55a2941854f61934487f3d209cfa95}\label{struct_s_p_i___settings_type_def_a0d55a2941854f61934487f3d209cfa95} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MISO\_GPIOx@{MISO\_GPIOx}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00109}{109}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_a0d55a2941854f61934487f3d209cfa95}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MISO\_GPIOx@{MISO\_GPIOx}} \index{MISO\_GPIOx@{MISO\_GPIOx}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{MISO\_GPIOx}{MISO\_GPIOx}} -{\footnotesize\ttfamily GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} SPI\+\_\+\+Settings\+Type\+Def\+::\+MISO\+\_\+\+GPIOx} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_a0d55a2941854f61934487f3d209cfa95} +GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} SPI\+\_\+\+Settings\+Type\+Def\+::\+MISO\+\_\+\+GPIOx} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00041}{41}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Порт MISO. -\Hypertarget{struct_s_p_i___settings_type_def_a3366c654d7ec6dd41c6a0b504dc8509a}\label{struct_s_p_i___settings_type_def_a3366c654d7ec6dd41c6a0b504dc8509a} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MISO\_PIN@{MISO\_PIN}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00111}{111}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_a3366c654d7ec6dd41c6a0b504dc8509a}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MISO\_PIN@{MISO\_PIN}} \index{MISO\_PIN@{MISO\_PIN}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{MISO\_PIN}{MISO\_PIN}} -{\footnotesize\ttfamily uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+MISO\+\_\+\+PIN} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_a3366c654d7ec6dd41c6a0b504dc8509a} +uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+MISO\+\_\+\+PIN} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00042}{42}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Пин MISO. -\Hypertarget{struct_s_p_i___settings_type_def_aecd7a5c6e205335b8ed229d74cd35d14}\label{struct_s_p_i___settings_type_def_aecd7a5c6e205335b8ed229d74cd35d14} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MISO\_GPIO\_AlternageFunc@{MISO\_GPIO\_AlternageFunc}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00112}{112}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_aecd7a5c6e205335b8ed229d74cd35d14}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MISO\_GPIO\_AlternageFunc@{MISO\_GPIO\_AlternageFunc}} \index{MISO\_GPIO\_AlternageFunc@{MISO\_GPIO\_AlternageFunc}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{MISO\_GPIO\_AlternageFunc}{MISO\_GPIO\_AlternageFunc}} -{\footnotesize\ttfamily uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+MISO\+\_\+\+GPIO\+\_\+\+Alternage\+Func} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_aecd7a5c6e205335b8ed229d74cd35d14} +uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+MISO\+\_\+\+GPIO\+\_\+\+Alternage\+Func} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00043}{43}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Альтернативная функция для MISO. -\Hypertarget{struct_s_p_i___settings_type_def_a0af3bdb273818ff97eb4ff3cff918820}\label{struct_s_p_i___settings_type_def_a0af3bdb273818ff97eb4ff3cff918820} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MOSI\_GPIOx@{MOSI\_GPIOx}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00113}{113}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_a0af3bdb273818ff97eb4ff3cff918820}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MOSI\_GPIOx@{MOSI\_GPIOx}} \index{MOSI\_GPIOx@{MOSI\_GPIOx}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{MOSI\_GPIOx}{MOSI\_GPIOx}} -{\footnotesize\ttfamily GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} SPI\+\_\+\+Settings\+Type\+Def\+::\+MOSI\+\_\+\+GPIOx} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_a0af3bdb273818ff97eb4ff3cff918820} +GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} SPI\+\_\+\+Settings\+Type\+Def\+::\+MOSI\+\_\+\+GPIOx} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00045}{45}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Порт MOSI. -\Hypertarget{struct_s_p_i___settings_type_def_a961208869faf4a7369aaf4edde75f176}\label{struct_s_p_i___settings_type_def_a961208869faf4a7369aaf4edde75f176} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MOSI\_PIN@{MOSI\_PIN}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00115}{115}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_a961208869faf4a7369aaf4edde75f176}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MOSI\_PIN@{MOSI\_PIN}} \index{MOSI\_PIN@{MOSI\_PIN}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{MOSI\_PIN}{MOSI\_PIN}} -{\footnotesize\ttfamily uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+MOSI\+\_\+\+PIN} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_a961208869faf4a7369aaf4edde75f176} +uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+MOSI\+\_\+\+PIN} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00046}{46}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Пин MOSI. -\Hypertarget{struct_s_p_i___settings_type_def_afbe75a1c36650a4a9b41fa706a4c7eab}\label{struct_s_p_i___settings_type_def_afbe75a1c36650a4a9b41fa706a4c7eab} -\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MOSI\_GPIO\_AlternageFunc@{MOSI\_GPIO\_AlternageFunc}} + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00116}{116}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_afbe75a1c36650a4a9b41fa706a4c7eab}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!MOSI\_GPIO\_AlternageFunc@{MOSI\_GPIO\_AlternageFunc}} \index{MOSI\_GPIO\_AlternageFunc@{MOSI\_GPIO\_AlternageFunc}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{MOSI\_GPIO\_AlternageFunc}{MOSI\_GPIO\_AlternageFunc}} -{\footnotesize\ttfamily uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+MOSI\+\_\+\+GPIO\+\_\+\+Alternage\+Func} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_afbe75a1c36650a4a9b41fa706a4c7eab} +uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+MOSI\+\_\+\+GPIO\+\_\+\+Alternage\+Func} -Definition at line \mbox{\hyperlink{____general__spi_8h_source_l00047}{47}} of file \mbox{\hyperlink{____general__spi_8h_source}{\+\_\+\+\_\+general\+\_\+spi.\+h}}. +Альтернативная функция для MOSI. + + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00117}{117}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_a3cfd9469b0617a68bbd2a161ba06bb95}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!DMAChannel@{DMAChannel}} +\index{DMAChannel@{DMAChannel}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} +\doxysubsubsection{\texorpdfstring{DMAChannel}{DMAChannel}} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_a3cfd9469b0617a68bbd2a161ba06bb95} +DMA\+\_\+\+Stream\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} SPI\+\_\+\+Settings\+Type\+Def\+::\+DMAChannel} + + + +Канал DMA (NULL если не нужен) + + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00119}{119}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. + +\Hypertarget{struct_s_p_i___settings_type_def_aa0edaa145076d2383b3e0095d156d474}\index{SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}!DMA\_CHANNEL\_X@{DMA\_CHANNEL\_X}} +\index{DMA\_CHANNEL\_X@{DMA\_CHANNEL\_X}!SPI\_SettingsTypeDef@{SPI\_SettingsTypeDef}} +\doxysubsubsection{\texorpdfstring{DMA\_CHANNEL\_X}{DMA\_CHANNEL\_X}} +{\footnotesize\ttfamily \label{struct_s_p_i___settings_type_def_aa0edaa145076d2383b3e0095d156d474} +uint32\+\_\+t SPI\+\_\+\+Settings\+Type\+Def\+::\+DMA\+\_\+\+CHANNEL\+\_\+X} + + + +Номер канала DMA (0 если не нужен) + + + +Definition at line \mbox{\hyperlink{general__spi_8h_source_l00120}{120}} of file \mbox{\hyperlink{general__spi_8h_source}{general\+\_\+spi.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\+\_\+\+\_\+general\+\_\+spi.\+h\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__spi_8h}{general\+\_\+spi.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/struct_t_i_m___encoder_type_def.tex b/Doc/latex/struct_t_i_m___encoder_type_def.tex index d67e813..79f641d 100644 --- a/Doc/latex/struct_t_i_m___encoder_type_def.tex +++ b/Doc/latex/struct_t_i_m___encoder_type_def.tex @@ -11,7 +11,8 @@ -Collaboration diagram for TIM\+\_\+\+Encoder\+Type\+Def\+:\nopagebreak +Collaboration diagram for TIM\+\_\+\+Encoder\+Type\+Def\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode @@ -50,16 +51,18 @@ uint32\+\_\+t \mbox{\hyperlink{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea Также высокоуровневые настройки частоты работы таймера. Если какая-\/либо высокоуровневая настройка не задана, то по возможности берется низкоуровневая настройка из структур -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00140}{140}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00141}{141}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +\label{doc-variable-members} +\Hypertarget{struct_t_i_m___encoder_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_t_i_m___encoder_type_def_a6f769f027b760a4b496e2b2b77bf54a3}\label{struct_t_i_m___encoder_type_def_a6f769f027b760a4b496e2b2b77bf54a3} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!Encoder\_Diff@{Encoder\_Diff}} +\Hypertarget{struct_t_i_m___encoder_type_def_a6f769f027b760a4b496e2b2b77bf54a3}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!Encoder\_Diff@{Encoder\_Diff}} \index{Encoder\_Diff@{Encoder\_Diff}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{Encoder\_Diff}{Encoder\_Diff}} -{\footnotesize\ttfamily int16\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+Encoder\+\_\+\+Diff} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_a6f769f027b760a4b496e2b2b77bf54a3} +int16\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+Encoder\+\_\+\+Diff} @@ -67,13 +70,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00140}{140}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00142}{142}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00143}{143}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___encoder_type_def_a0dacce3dde7df3122583869d96a372a2}\label{struct_t_i_m___encoder_type_def_a0dacce3dde7df3122583869d96a372a2} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!Encoder\_Shdw@{Encoder\_Shdw}} +\Hypertarget{struct_t_i_m___encoder_type_def_a0dacce3dde7df3122583869d96a372a2}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!Encoder\_Shdw@{Encoder\_Shdw}} \index{Encoder\_Shdw@{Encoder\_Shdw}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{Encoder\_Shdw}{Encoder\_Shdw}} -{\footnotesize\ttfamily uint16\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+Encoder\+\_\+\+Shdw} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_a0dacce3dde7df3122583869d96a372a2} +uint16\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+Encoder\+\_\+\+Shdw} @@ -81,13 +84,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00142}{142}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00143}{143}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00144}{144}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}\label{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!htim@{htim}} +\Hypertarget{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!htim@{htim}} \index{htim@{htim}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{htim}{htim}} -{\footnotesize\ttfamily TIM\+\_\+\+Handle\+Type\+Def\texorpdfstring{$\ast$}{*} TIM\+\_\+\+Encoder\+Type\+Def\+::htim} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_adc80bd5a90444c31d84157f35c59b95c} +TIM\+\_\+\+Handle\+Type\+Def\texorpdfstring{$\ast$}{*} TIM\+\_\+\+Encoder\+Type\+Def\+::htim} @@ -95,13 +98,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00143}{143}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00145}{145}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00146}{146}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___encoder_type_def_a021f0c585e9e62d68a4b09f630d8b6e5}\label{struct_t_i_m___encoder_type_def_a021f0c585e9e62d68a4b09f630d8b6e5} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!sConfig@{sConfig}} +\Hypertarget{struct_t_i_m___encoder_type_def_a021f0c585e9e62d68a4b09f630d8b6e5}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!sConfig@{sConfig}} \index{sConfig@{sConfig}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{sConfig}{sConfig}} -{\footnotesize\ttfamily TIM\+\_\+\+Encoder\+\_\+\+Init\+Type\+Def TIM\+\_\+\+Encoder\+Type\+Def\+::s\+Config} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_a021f0c585e9e62d68a4b09f630d8b6e5} +TIM\+\_\+\+Encoder\+\_\+\+Init\+Type\+Def TIM\+\_\+\+Encoder\+Type\+Def\+::s\+Config} @@ -109,13 +112,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00145}{145}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00146}{146}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00147}{147}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9}\label{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!GPIOx@{GPIOx}} +\Hypertarget{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!GPIOx@{GPIOx}} \index{GPIOx@{GPIOx}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{GPIOx}{GPIOx}} -{\footnotesize\ttfamily GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} TIM\+\_\+\+Encoder\+Type\+Def\+::\+GPIOx} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_ad29873fc8cdc71462e6d8744621120e9} +GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} TIM\+\_\+\+Encoder\+Type\+Def\+::\+GPIOx} @@ -123,13 +126,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00146}{146}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00148}{148}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00149}{149}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e}\label{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!GPIO\_PIN\_TI1@{GPIO\_PIN\_TI1}} +\Hypertarget{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!GPIO\_PIN\_TI1@{GPIO\_PIN\_TI1}} \index{GPIO\_PIN\_TI1@{GPIO\_PIN\_TI1}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{GPIO\_PIN\_TI1}{GPIO\_PIN\_TI1}} -{\footnotesize\ttfamily uint32\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+TI1} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_a4fc05ef011205a6702cb3d006bab677e} +uint32\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+TI1} @@ -137,13 +140,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00148}{148}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00149}{149}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00150}{150}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5}\label{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!GPIO\_PIN\_TI2@{GPIO\_PIN\_TI2}} +\Hypertarget{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!GPIO\_PIN\_TI2@{GPIO\_PIN\_TI2}} \index{GPIO\_PIN\_TI2@{GPIO\_PIN\_TI2}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{GPIO\_PIN\_TI2}{GPIO\_PIN\_TI2}} -{\footnotesize\ttfamily uint32\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+TI2} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_a67ad037b92162546763fc9c425b5e3c5} +uint32\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+TI2} @@ -151,13 +154,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00149}{149}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00150}{150}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00151}{151}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea4fc3e0e8a501af80}\label{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea4fc3e0e8a501af80} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!GPIO\_PIN\_SW@{GPIO\_PIN\_SW}} +\Hypertarget{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea4fc3e0e8a501af80}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!GPIO\_PIN\_SW@{GPIO\_PIN\_SW}} \index{GPIO\_PIN\_SW@{GPIO\_PIN\_SW}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{GPIO\_PIN\_SW}{GPIO\_PIN\_SW}} -{\footnotesize\ttfamily uint32\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+SW} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_a6973108a83d2a3ea4fc3e0e8a501af80} +uint32\+\_\+t TIM\+\_\+\+Encoder\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+SW} @@ -165,13 +168,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00150}{150}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00151}{151}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00152}{152}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___encoder_type_def_a99295760ff8b27d1e6f1710f29383a45}\label{struct_t_i_m___encoder_type_def_a99295760ff8b27d1e6f1710f29383a45} -\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!Sw@{Sw}} +\Hypertarget{struct_t_i_m___encoder_type_def_a99295760ff8b27d1e6f1710f29383a45}\index{TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}!Sw@{Sw}} \index{Sw@{Sw}!TIM\_EncoderTypeDef@{TIM\_EncoderTypeDef}} \doxysubsubsection{\texorpdfstring{Sw}{Sw}} -{\footnotesize\ttfamily \mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\+\_\+\+Switch\+Type\+Def}} TIM\+\_\+\+Encoder\+Type\+Def\+::\+Sw} +{\footnotesize\ttfamily \label{struct_t_i_m___encoder_type_def_a99295760ff8b27d1e6f1710f29383a45} +\mbox{\hyperlink{struct_g_p_i_o___switch_type_def}{GPIO\+\_\+\+Switch\+Type\+Def}} TIM\+\_\+\+Encoder\+Type\+Def\+::\+Sw} @@ -179,10 +182,10 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00151}{151}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00153}{153}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00154}{154}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__tim_8h}{general\+\_\+tim.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__tim_8h}{general\+\_\+tim.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/struct_t_i_m___encoder_type_def__coll__graph.md5 b/Doc/latex/struct_t_i_m___encoder_type_def__coll__graph.md5 index e513bf2..89dacb9 100644 --- a/Doc/latex/struct_t_i_m___encoder_type_def__coll__graph.md5 +++ b/Doc/latex/struct_t_i_m___encoder_type_def__coll__graph.md5 @@ -1 +1 @@ -ea7ef1dc3c0c867000fb2dc7a8519e34 \ No newline at end of file +7ad33b5006a3bba719adf0e8727fd280 \ No newline at end of file diff --git a/Doc/latex/struct_t_i_m___encoder_type_def__coll__graph.pdf b/Doc/latex/struct_t_i_m___encoder_type_def__coll__graph.pdf index cbfcb96..b1e4907 100644 Binary files a/Doc/latex/struct_t_i_m___encoder_type_def__coll__graph.pdf and b/Doc/latex/struct_t_i_m___encoder_type_def__coll__graph.pdf differ diff --git a/Doc/latex/struct_t_i_m___settings_type_def.tex b/Doc/latex/struct_t_i_m___settings_type_def.tex index 62f9c47..12e4737 100644 --- a/Doc/latex/struct_t_i_m___settings_type_def.tex +++ b/Doc/latex/struct_t_i_m___settings_type_def.tex @@ -23,11 +23,9 @@ TIM\+\_\+\+Master\+Config\+Type\+Def \mbox{\hyperlink{struct_t_i_m___settings_ty TIM\+\_\+\+Break\+Dead\+Time\+Config\+Type\+Def \mbox{\hyperlink{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7}{s\+Break\+Dead\+Time\+Config}} \begin{DoxyCompactList}\small\item\em Настройки дедтаймов таймера \end{DoxyCompactList}\item \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}} \mbox{\hyperlink{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}{s\+Tim\+Mode}} -\begin{DoxyCompactList}\small\item\em Настройки прерывания таймера ~\newline - \end{DoxyCompactList}\item +\begin{DoxyCompactList}\small\item\em Настройки прерывания таймера \end{DoxyCompactList}\item \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\+\_\+\+MHz\+Tick\+Base\+Type\+Def}} \mbox{\hyperlink{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}{s\+Tick\+Base\+US}} -\begin{DoxyCompactList}\small\item\em Длительность одного тика ~\newline - \end{DoxyCompactList}\item +\begin{DoxyCompactList}\small\item\em Длительность одного тика \end{DoxyCompactList}\item uint8\+\_\+t \mbox{\hyperlink{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718}{s\+Tick\+Base\+Prescaler}} \begin{DoxyCompactList}\small\item\em Дополнительный делитель, для удобного деления \doxylink{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}{s\+Tick\+Base\+US}. \end{DoxyCompactList}\item float \mbox{\hyperlink{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}{s\+Tim\+AHBFreq\+MHz}} @@ -45,16 +43,18 @@ float \mbox{\hyperlink{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a3 Также высокоуровневые настройки частоты работы таймера. Если какая-\/либо высокоуровневая настройка не задана, то по возможности берется низкоуровневая настройка из структур -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00112}{112}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00113}{113}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +\label{doc-variable-members} +\Hypertarget{struct_t_i_m___settings_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}\label{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!htim@{htim}} +\Hypertarget{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!htim@{htim}} \index{htim@{htim}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{htim}{htim}} -{\footnotesize\ttfamily TIM\+\_\+\+Handle\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::htim} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_ada49efdbd35a8e442c3cff630d42f34c} +TIM\+\_\+\+Handle\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::htim} @@ -62,13 +62,13 @@ HAL handle таймера -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00114}{114}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00115}{115}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___settings_type_def_a3805f627567798c3cd1d79a0da42bea0}\label{struct_t_i_m___settings_type_def_a3805f627567798c3cd1d79a0da42bea0} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sClockSourceConfig@{sClockSourceConfig}} +\Hypertarget{struct_t_i_m___settings_type_def_a3805f627567798c3cd1d79a0da42bea0}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sClockSourceConfig@{sClockSourceConfig}} \index{sClockSourceConfig@{sClockSourceConfig}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{sClockSourceConfig}{sClockSourceConfig}} -{\footnotesize\ttfamily TIM\+\_\+\+Clock\+Config\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::s\+Clock\+Source\+Config} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_a3805f627567798c3cd1d79a0da42bea0} +TIM\+\_\+\+Clock\+Config\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::s\+Clock\+Source\+Config} @@ -76,13 +76,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00114}{114}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00115}{115}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00116}{116}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___settings_type_def_a9694cf0910a69d48ff94f8aeac106969}\label{struct_t_i_m___settings_type_def_a9694cf0910a69d48ff94f8aeac106969} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sSlaveConfig@{sSlaveConfig}} +\Hypertarget{struct_t_i_m___settings_type_def_a9694cf0910a69d48ff94f8aeac106969}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sSlaveConfig@{sSlaveConfig}} \index{sSlaveConfig@{sSlaveConfig}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{sSlaveConfig}{sSlaveConfig}} -{\footnotesize\ttfamily TIM\+\_\+\+Slave\+Config\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::s\+Slave\+Config} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_a9694cf0910a69d48ff94f8aeac106969} +TIM\+\_\+\+Slave\+Config\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::s\+Slave\+Config} @@ -90,13 +90,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00115}{115}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00116}{116}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00117}{117}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___settings_type_def_a2d9d277dd395424b964445ec1bc65b21}\label{struct_t_i_m___settings_type_def_a2d9d277dd395424b964445ec1bc65b21} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sMasterConfig@{sMasterConfig}} +\Hypertarget{struct_t_i_m___settings_type_def_a2d9d277dd395424b964445ec1bc65b21}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sMasterConfig@{sMasterConfig}} \index{sMasterConfig@{sMasterConfig}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{sMasterConfig}{sMasterConfig}} -{\footnotesize\ttfamily TIM\+\_\+\+Master\+Config\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::s\+Master\+Config} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_a2d9d277dd395424b964445ec1bc65b21} +TIM\+\_\+\+Master\+Config\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::s\+Master\+Config} @@ -104,13 +104,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00116}{116}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00117}{117}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00118}{118}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7}\label{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sBreakDeadTimeConfig@{sBreakDeadTimeConfig}} +\Hypertarget{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sBreakDeadTimeConfig@{sBreakDeadTimeConfig}} \index{sBreakDeadTimeConfig@{sBreakDeadTimeConfig}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{sBreakDeadTimeConfig}{sBreakDeadTimeConfig}} -{\footnotesize\ttfamily TIM\+\_\+\+Break\+Dead\+Time\+Config\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::s\+Break\+Dead\+Time\+Config} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_a961f19f0e1672715c27bc94d7871dbb7} +TIM\+\_\+\+Break\+Dead\+Time\+Config\+Type\+Def TIM\+\_\+\+Settings\+Type\+Def\+::s\+Break\+Dead\+Time\+Config} @@ -118,43 +118,41 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00117}{117}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00118}{118}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00119}{119}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}\label{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTimMode@{sTimMode}} +\Hypertarget{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTimMode@{sTimMode}} \index{sTimMode@{sTimMode}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{sTimMode}{sTimMode}} -{\footnotesize\ttfamily \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}} TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tim\+Mode} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_ab90e370c3edda88e76583293c250d2b0} +\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaeb611874216a4661fb83366b99b9e787}{TIM\+\_\+\+ITMode\+Type\+Def}} TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tim\+Mode} -Настройки прерывания таймера ~\newline - - - - -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00120}{120}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. - -\Hypertarget{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}\label{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTickBaseUS@{sTickBaseUS}} -\index{sTickBaseUS@{sTickBaseUS}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} -\doxysubsubsection{\texorpdfstring{sTickBaseUS}{sTickBaseUS}} -{\footnotesize\ttfamily \mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\+\_\+\+MHz\+Tick\+Base\+Type\+Def}} TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tick\+Base\+US} - - - -Длительность одного тика ~\newline - +Настройки прерывания таймера Definition at line \mbox{\hyperlink{general__tim_8h_source_l00121}{121}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718}\label{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTickBasePrescaler@{sTickBasePrescaler}} +\Hypertarget{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTickBaseUS@{sTickBaseUS}} +\index{sTickBaseUS@{sTickBaseUS}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} +\doxysubsubsection{\texorpdfstring{sTickBaseUS}{sTickBaseUS}} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_a58da1b4c0f6d12d7d9fb2f170b9b9e6e} +\mbox{\hyperlink{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l_gaa0a51c870325217ac099881f09dd0800}{TIM\+\_\+\+MHz\+Tick\+Base\+Type\+Def}} TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tick\+Base\+US} + + + +Длительность одного тика + + + +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00122}{122}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. + +\Hypertarget{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTickBasePrescaler@{sTickBasePrescaler}} \index{sTickBasePrescaler@{sTickBasePrescaler}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{sTickBasePrescaler}{sTickBasePrescaler}} -{\footnotesize\ttfamily uint8\+\_\+t TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tick\+Base\+Prescaler} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_a11151fe125960cb8e61328ffd06b7718} +uint8\+\_\+t TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tick\+Base\+Prescaler} @@ -162,13 +160,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00121}{121}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00122}{122}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00123}{123}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}\label{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTimAHBFreqMHz@{sTimAHBFreqMHz}} +\Hypertarget{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTimAHBFreqMHz@{sTimAHBFreqMHz}} \index{sTimAHBFreqMHz@{sTimAHBFreqMHz}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{sTimAHBFreqMHz}{sTimAHBFreqMHz}} -{\footnotesize\ttfamily float TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tim\+AHBFreq\+MHz} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_a7073358fd3a722687eb85238ab570014} +float TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tim\+AHBFreq\+MHz} @@ -176,13 +174,13 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00122}{122}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00123}{123}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00124}{124}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. -\Hypertarget{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4}\label{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4} -\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTimFreqHz@{sTimFreqHz}} +\Hypertarget{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4}\index{TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}!sTimFreqHz@{sTimFreqHz}} \index{sTimFreqHz@{sTimFreqHz}!TIM\_SettingsTypeDef@{TIM\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{sTimFreqHz}{sTimFreqHz}} -{\footnotesize\ttfamily float TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tim\+Freq\+Hz} +{\footnotesize\ttfamily \label{struct_t_i_m___settings_type_def_af6057ff3f60f5e01b41d4a347b79a5e4} +float TIM\+\_\+\+Settings\+Type\+Def\+::s\+Tim\+Freq\+Hz} @@ -190,10 +188,10 @@ Definition at line \mbox{\hyperlink{general__tim_8h_source_l00123}{123}} of file -Definition at line \mbox{\hyperlink{general__tim_8h_source_l00124}{124}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. +Definition at line \mbox{\hyperlink{general__tim_8h_source_l00125}{125}} of file \mbox{\hyperlink{general__tim_8h_source}{general\+\_\+tim.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__tim_8h}{general\+\_\+tim.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__tim_8h}{general\+\_\+tim.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/struct_u_a_r_t___settings_type_def.tex b/Doc/latex/struct_u_a_r_t___settings_type_def.tex index 96f519c..8625686 100644 --- a/Doc/latex/struct_u_a_r_t___settings_type_def.tex +++ b/Doc/latex/struct_u_a_r_t___settings_type_def.tex @@ -1,92 +1,129 @@ \doxysection{UART\+\_\+\+Settings\+Type\+Def Struct Reference} \hypertarget{struct_u_a_r_t___settings_type_def}{}\label{struct_u_a_r_t___settings_type_def}\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}} + + +Структура настроек UART. + + + + +{\ttfamily \#include $<$general\+\_\+uart.\+h$>$} + \doxysubsubsection*{Public Attributes} \begin{DoxyCompactItemize} \item UART\+\_\+\+Handle\+Type\+Def \mbox{\hyperlink{struct_u_a_r_t___settings_type_def_accf2c9448a3ea8eb3b8c25a569276fea}{huart}} -\item +\begin{DoxyCompactList}\small\item\em HAL handle UART. \end{DoxyCompactList}\item GPIO\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*} \mbox{\hyperlink{struct_u_a_r_t___settings_type_def_af6f9910d065bae715cdb4a1024143a8f}{GPIOx}} -\item +\begin{DoxyCompactList}\small\item\em Порт для UART. \end{DoxyCompactList}\item uint16\+\_\+t \mbox{\hyperlink{struct_u_a_r_t___settings_type_def_a3fba2b52788fe453348b5d92ed52ba49}{GPIO\+\_\+\+PIN\+\_\+\+RX}} -\item +\begin{DoxyCompactList}\small\item\em Пин приема \end{DoxyCompactList}\item uint16\+\_\+t \mbox{\hyperlink{struct_u_a_r_t___settings_type_def_a5f1babfcfb436cd77f5614253c0a5bef}{GPIO\+\_\+\+PIN\+\_\+\+TX}} -\item +\begin{DoxyCompactList}\small\item\em Пин передачи \end{DoxyCompactList}\item DMA\+\_\+\+Stream\+\_\+\+Type\+Def \texorpdfstring{$\ast$}{*} \mbox{\hyperlink{struct_u_a_r_t___settings_type_def_a1ecc9ac6a1d2747ade56770cbab6a613}{DMAChannel}} -\item +\begin{DoxyCompactList}\small\item\em Канал DMA (NULL если не нужен) \end{DoxyCompactList}\item uint32\+\_\+t \mbox{\hyperlink{struct_u_a_r_t___settings_type_def_a15ce92b03f7f189bfbe1ab88a5f94d19}{DMA\+\_\+\+CHANNEL\+\_\+X}} -\end{DoxyCompactItemize} +\begin{DoxyCompactList}\small\item\em Номер канала DMA (0 если не нужен) \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsection{Detailed Description} +Структура настроек UART. +Содержит все необходимые параметры для инициализации UART, включая GPIO и DMA. -Definition at line \mbox{\hyperlink{____general__uart_8h_source_l00045}{45}} of file \mbox{\hyperlink{____general__uart_8h_source}{\+\_\+\+\_\+general\+\_\+uart.\+h}}. +Definition at line \mbox{\hyperlink{general__uart_8h_source_l00096}{96}} of file \mbox{\hyperlink{general__uart_8h_source}{general\+\_\+uart.\+h}}. +\label{doc-variable-members} +\Hypertarget{struct_u_a_r_t___settings_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{struct_u_a_r_t___settings_type_def_accf2c9448a3ea8eb3b8c25a569276fea}\label{struct_u_a_r_t___settings_type_def_accf2c9448a3ea8eb3b8c25a569276fea} -\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!huart@{huart}} +\Hypertarget{struct_u_a_r_t___settings_type_def_accf2c9448a3ea8eb3b8c25a569276fea}\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!huart@{huart}} \index{huart@{huart}!UART\_SettingsTypeDef@{UART\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{huart}{huart}} -{\footnotesize\ttfamily UART\+\_\+\+Handle\+Type\+Def UART\+\_\+\+Settings\+Type\+Def\+::huart} +{\footnotesize\ttfamily \label{struct_u_a_r_t___settings_type_def_accf2c9448a3ea8eb3b8c25a569276fea} +UART\+\_\+\+Handle\+Type\+Def UART\+\_\+\+Settings\+Type\+Def\+::huart} -Definition at line \mbox{\hyperlink{____general__uart_8h_source_l00047}{47}} of file \mbox{\hyperlink{____general__uart_8h_source}{\+\_\+\+\_\+general\+\_\+uart.\+h}}. +HAL handle UART. -\Hypertarget{struct_u_a_r_t___settings_type_def_af6f9910d065bae715cdb4a1024143a8f}\label{struct_u_a_r_t___settings_type_def_af6f9910d065bae715cdb4a1024143a8f} -\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!GPIOx@{GPIOx}} + + +Definition at line \mbox{\hyperlink{general__uart_8h_source_l00098}{98}} of file \mbox{\hyperlink{general__uart_8h_source}{general\+\_\+uart.\+h}}. + +\Hypertarget{struct_u_a_r_t___settings_type_def_af6f9910d065bae715cdb4a1024143a8f}\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!GPIOx@{GPIOx}} \index{GPIOx@{GPIOx}!UART\_SettingsTypeDef@{UART\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{GPIOx}{GPIOx}} -{\footnotesize\ttfamily GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} UART\+\_\+\+Settings\+Type\+Def\+::\+GPIOx} +{\footnotesize\ttfamily \label{struct_u_a_r_t___settings_type_def_af6f9910d065bae715cdb4a1024143a8f} +GPIO\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} UART\+\_\+\+Settings\+Type\+Def\+::\+GPIOx} -Definition at line \mbox{\hyperlink{____general__uart_8h_source_l00049}{49}} of file \mbox{\hyperlink{____general__uart_8h_source}{\+\_\+\+\_\+general\+\_\+uart.\+h}}. +Порт для UART. -\Hypertarget{struct_u_a_r_t___settings_type_def_a3fba2b52788fe453348b5d92ed52ba49}\label{struct_u_a_r_t___settings_type_def_a3fba2b52788fe453348b5d92ed52ba49} -\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!GPIO\_PIN\_RX@{GPIO\_PIN\_RX}} + + +Definition at line \mbox{\hyperlink{general__uart_8h_source_l00100}{100}} of file \mbox{\hyperlink{general__uart_8h_source}{general\+\_\+uart.\+h}}. + +\Hypertarget{struct_u_a_r_t___settings_type_def_a3fba2b52788fe453348b5d92ed52ba49}\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!GPIO\_PIN\_RX@{GPIO\_PIN\_RX}} \index{GPIO\_PIN\_RX@{GPIO\_PIN\_RX}!UART\_SettingsTypeDef@{UART\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{GPIO\_PIN\_RX}{GPIO\_PIN\_RX}} -{\footnotesize\ttfamily uint16\+\_\+t UART\+\_\+\+Settings\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+RX} +{\footnotesize\ttfamily \label{struct_u_a_r_t___settings_type_def_a3fba2b52788fe453348b5d92ed52ba49} +uint16\+\_\+t UART\+\_\+\+Settings\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+RX} -Definition at line \mbox{\hyperlink{____general__uart_8h_source_l00050}{50}} of file \mbox{\hyperlink{____general__uart_8h_source}{\+\_\+\+\_\+general\+\_\+uart.\+h}}. +Пин приема -\Hypertarget{struct_u_a_r_t___settings_type_def_a5f1babfcfb436cd77f5614253c0a5bef}\label{struct_u_a_r_t___settings_type_def_a5f1babfcfb436cd77f5614253c0a5bef} -\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!GPIO\_PIN\_TX@{GPIO\_PIN\_TX}} + + +Definition at line \mbox{\hyperlink{general__uart_8h_source_l00101}{101}} of file \mbox{\hyperlink{general__uart_8h_source}{general\+\_\+uart.\+h}}. + +\Hypertarget{struct_u_a_r_t___settings_type_def_a5f1babfcfb436cd77f5614253c0a5bef}\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!GPIO\_PIN\_TX@{GPIO\_PIN\_TX}} \index{GPIO\_PIN\_TX@{GPIO\_PIN\_TX}!UART\_SettingsTypeDef@{UART\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{GPIO\_PIN\_TX}{GPIO\_PIN\_TX}} -{\footnotesize\ttfamily uint16\+\_\+t UART\+\_\+\+Settings\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+TX} +{\footnotesize\ttfamily \label{struct_u_a_r_t___settings_type_def_a5f1babfcfb436cd77f5614253c0a5bef} +uint16\+\_\+t UART\+\_\+\+Settings\+Type\+Def\+::\+GPIO\+\_\+\+PIN\+\_\+\+TX} -Definition at line \mbox{\hyperlink{____general__uart_8h_source_l00051}{51}} of file \mbox{\hyperlink{____general__uart_8h_source}{\+\_\+\+\_\+general\+\_\+uart.\+h}}. +Пин передачи -\Hypertarget{struct_u_a_r_t___settings_type_def_a1ecc9ac6a1d2747ade56770cbab6a613}\label{struct_u_a_r_t___settings_type_def_a1ecc9ac6a1d2747ade56770cbab6a613} -\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!DMAChannel@{DMAChannel}} + + +Definition at line \mbox{\hyperlink{general__uart_8h_source_l00102}{102}} of file \mbox{\hyperlink{general__uart_8h_source}{general\+\_\+uart.\+h}}. + +\Hypertarget{struct_u_a_r_t___settings_type_def_a1ecc9ac6a1d2747ade56770cbab6a613}\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!DMAChannel@{DMAChannel}} \index{DMAChannel@{DMAChannel}!UART\_SettingsTypeDef@{UART\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{DMAChannel}{DMAChannel}} -{\footnotesize\ttfamily DMA\+\_\+\+Stream\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} UART\+\_\+\+Settings\+Type\+Def\+::\+DMAChannel} +{\footnotesize\ttfamily \label{struct_u_a_r_t___settings_type_def_a1ecc9ac6a1d2747ade56770cbab6a613} +DMA\+\_\+\+Stream\+\_\+\+Type\+Def\texorpdfstring{$\ast$}{*} UART\+\_\+\+Settings\+Type\+Def\+::\+DMAChannel} -Definition at line \mbox{\hyperlink{____general__uart_8h_source_l00053}{53}} of file \mbox{\hyperlink{____general__uart_8h_source}{\+\_\+\+\_\+general\+\_\+uart.\+h}}. +Канал DMA (NULL если не нужен) -\Hypertarget{struct_u_a_r_t___settings_type_def_a15ce92b03f7f189bfbe1ab88a5f94d19}\label{struct_u_a_r_t___settings_type_def_a15ce92b03f7f189bfbe1ab88a5f94d19} -\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!DMA\_CHANNEL\_X@{DMA\_CHANNEL\_X}} + + +Definition at line \mbox{\hyperlink{general__uart_8h_source_l00104}{104}} of file \mbox{\hyperlink{general__uart_8h_source}{general\+\_\+uart.\+h}}. + +\Hypertarget{struct_u_a_r_t___settings_type_def_a15ce92b03f7f189bfbe1ab88a5f94d19}\index{UART\_SettingsTypeDef@{UART\_SettingsTypeDef}!DMA\_CHANNEL\_X@{DMA\_CHANNEL\_X}} \index{DMA\_CHANNEL\_X@{DMA\_CHANNEL\_X}!UART\_SettingsTypeDef@{UART\_SettingsTypeDef}} \doxysubsubsection{\texorpdfstring{DMA\_CHANNEL\_X}{DMA\_CHANNEL\_X}} -{\footnotesize\ttfamily uint32\+\_\+t UART\+\_\+\+Settings\+Type\+Def\+::\+DMA\+\_\+\+CHANNEL\+\_\+X} +{\footnotesize\ttfamily \label{struct_u_a_r_t___settings_type_def_a15ce92b03f7f189bfbe1ab88a5f94d19} +uint32\+\_\+t UART\+\_\+\+Settings\+Type\+Def\+::\+DMA\+\_\+\+CHANNEL\+\_\+X} -Definition at line \mbox{\hyperlink{____general__uart_8h_source_l00054}{54}} of file \mbox{\hyperlink{____general__uart_8h_source}{\+\_\+\+\_\+general\+\_\+uart.\+h}}. +Номер канала DMA (0 если не нужен) + + + +Definition at line \mbox{\hyperlink{general__uart_8h_source_l00105}{105}} of file \mbox{\hyperlink{general__uart_8h_source}{general\+\_\+uart.\+h}}. The documentation for this struct was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\+\_\+\+\_\+general\+\_\+uart.\+h\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{general__uart_8h}{general\+\_\+uart.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/topics.tex b/Doc/latex/topics.tex index 03634c8..3fddd5c 100644 --- a/Doc/latex/topics.tex +++ b/Doc/latex/topics.tex @@ -35,15 +35,23 @@ Here is a list of all topics with brief descriptions\+:\begin{DoxyCompactList} \item \contentsline{section}{Switch tools}{\pageref{group___m_y_l_i_b_s___g_p_i_o___s_w_i_t_c_h}}{} \item \contentsline{section}{LED tools}{\pageref{group___m_y_l_i_b_s___g_p_i_o___l_e_d_s}}{} \end{DoxyCompactList} +\item \contentsline{section}{SPI Tools}{\pageref{group___m_y___l_i_b_s___s_p_i}}{} +\begin{DoxyCompactList} +\item \contentsline{section}{Init defines}{\pageref{group___s_p_i___i_n_i_t}}{} +\end{DoxyCompactList} \item \contentsline{section}{TIM Tools}{\pageref{group___m_y___l_i_b_s___t_i_m}}{} \begin{DoxyCompactList} -\item \contentsline{section}{PWM/\+OC Channels tools}{\pageref{group___m_y_l_i_b_s___t_i_m___o_c}}{} -\item \contentsline{section}{Encoder tools}{\pageref{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r}}{} -\item \contentsline{section}{Delay tools}{\pageref{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y}}{} \item \contentsline{section}{General tools}{\pageref{group___m_y_l_i_b_s___t_i_m___g_e_n_e_r_a_l}}{} \begin{DoxyCompactList} \item \contentsline{section}{Init defines}{\pageref{group___t_i_m___i_n_i_t}}{} \end{DoxyCompactList} +\item \contentsline{section}{Delay tools}{\pageref{group___m_y_l_i_b_s___t_i_m___d_e_l_a_y}}{} +\item \contentsline{section}{PWM/\+OC Channels tools}{\pageref{group___m_y_l_i_b_s___t_i_m___o_c}}{} +\item \contentsline{section}{Encoder tools}{\pageref{group___m_y_l_i_b_s___t_i_m___e_n_c_o_d_e_r}}{} +\end{DoxyCompactList} +\item \contentsline{section}{UART Tools}{\pageref{group___m_y___l_i_b_s___u_a_r_t}}{} +\begin{DoxyCompactList} +\item \contentsline{section}{Init defines}{\pageref{group___u_a_r_t___i_n_i_t}}{} \end{DoxyCompactList} \end{DoxyCompactList} \end{DoxyCompactList} diff --git a/Doc/latex/trace_8h.tex b/Doc/latex/trace_8h.tex index 6e582dc..1502d40 100644 --- a/Doc/latex/trace_8h.tex +++ b/Doc/latex/trace_8h.tex @@ -1,5 +1,5 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/trace.h File Reference} -\hypertarget{trace_8h}{}\label{trace_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trace.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trace.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/trace.h File Reference} +\hypertarget{trace_8h}{}\label{trace_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trace.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trace.h}} Заголочный файл для работы с трассировкой. @@ -8,18 +8,20 @@ {\ttfamily \#include "{}mylibs\+\_\+defs.\+h"{}}\newline {\ttfamily \#include $<$string.\+h$>$}\newline {\ttfamily \#include "{}SEGGER\+\_\+\+RTT.\+h"{}}\newline -Include dependency graph for trace.\+h\+:\nopagebreak +Include dependency graph for trace.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode \includegraphics[width=337pt]{trace_8h__incl} \end{center} \end{figure} -This graph shows which files directly or indirectly include this file\+:\nopagebreak +This graph shows which files directly or indirectly include this file\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=233pt]{trace_8h__dep__incl} +\includegraphics[width=229pt]{trace_8h__dep__incl} \end{center} \end{figure} \doxysubsubsection*{Classes} @@ -32,13 +34,13 @@ struct \mbox{\hyperlink{struct_h_f___stack_frame__t}{HF\+\_\+\+Stack\+Frame\+\_\ \doxysubsubsection*{Macros} \begin{DoxyCompactItemize} \item -\#define \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\+\_\+printf}}(...)~SEGGER\+\_\+\+RTT\+\_\+printf(0, \+\_\+\+\_\+\+VA\+\_\+\+ARGS\+\_\+\+\_\+) +\#define \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\+\_\+printf}}(...) \begin{DoxyCompactList}\small\item\em Универсальный макрос для вывода трассировки \end{DoxyCompactList}\item \#define \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26}{log\+\_\+printf}}(TAG, fmt, ...) -\begin{DoxyCompactList}\small\item\em Макрос логирования с поддержкой уровней LOG\+\_\+\+LEVEL. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}{TRACE\+\_\+\+GPIO\+\_\+\+SET}}(\+\_\+gpio\+\_\+, \+\_\+pin\+\_\+)~(\+\_\+gpio\+\_\+)-\/$>$BSRR = (((\+\_\+pin\+\_\+))) +\begin{DoxyCompactList}\small\item\em Макрос логирования с поддержкой уровней \doxylink{group___t_r_a_c_e___c_o_n_f_i_g_ga0b87e0d3bf5853bcbb0b66a7c48fdc05}{LOG\+\_\+\+LEVEL}. \end{DoxyCompactList}\item +\#define \mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}{TRACE\+\_\+\+GPIO\+\_\+\+SET}}(\+\_\+gpio\+\_\+, \+\_\+pin\+\_\+) \begin{DoxyCompactList}\small\item\em Установить указанную ножку GPIO. \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}{TRACE\+\_\+\+GPIO\+\_\+\+RESET}}(\+\_\+gpio\+\_\+, \+\_\+pin\+\_\+)~(\+\_\+gpio\+\_\+)-\/$>$BSRR = ((\+\_\+pin\+\_\+)$<$$<$16) +\#define \mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}{TRACE\+\_\+\+GPIO\+\_\+\+RESET}}(\+\_\+gpio\+\_\+, \+\_\+pin\+\_\+) \begin{DoxyCompactList}\small\item\em Сбросить указанную ножку GPIO. \end{DoxyCompactList}\end{DoxyCompactItemize} \doxysubsubsection*{Functions} \begin{DoxyCompactItemize} diff --git a/Doc/latex/trace_8h__dep__incl.md5 b/Doc/latex/trace_8h__dep__incl.md5 index 1128197..fc64bec 100644 --- a/Doc/latex/trace_8h__dep__incl.md5 +++ b/Doc/latex/trace_8h__dep__incl.md5 @@ -1 +1 @@ -ed66c693e6b28b2992bca99d933335c9 \ No newline at end of file +d1d9b9839489bb966fdfc05554f4505c \ No newline at end of file diff --git a/Doc/latex/trace_8h__dep__incl.pdf b/Doc/latex/trace_8h__dep__incl.pdf index 005a6b4..8bb4048 100644 Binary files a/Doc/latex/trace_8h__dep__incl.pdf and b/Doc/latex/trace_8h__dep__incl.pdf differ diff --git a/Doc/latex/trace_8h__incl.md5 b/Doc/latex/trace_8h__incl.md5 index a1c8f34..3bf9e8b 100644 --- a/Doc/latex/trace_8h__incl.md5 +++ b/Doc/latex/trace_8h__incl.md5 @@ -1 +1 @@ -c825fc7596c334c4e6a628692e58fd83 \ No newline at end of file +25ced8a2b2c0bbd5a0a97e1ea1708d17 \ No newline at end of file diff --git a/Doc/latex/trace_8h__incl.pdf b/Doc/latex/trace_8h__incl.pdf index 69ff32c..77a15ef 100644 Binary files a/Doc/latex/trace_8h__incl.pdf and b/Doc/latex/trace_8h__incl.pdf differ diff --git a/Doc/latex/trace_8h_source.tex b/Doc/latex/trace_8h_source.tex index 930babd..8a6a204 100644 --- a/Doc/latex/trace_8h_source.tex +++ b/Doc/latex/trace_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{trace.\+h} -\hypertarget{trace_8h_source}{}\label{trace_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trace.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trace.h}} +\hypertarget{trace_8h_source}{}\label{trace_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trace.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trace.h}} \mbox{\hyperlink{trace_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00001}00001\ \textcolor{comment}{/**\ }} @@ -24,561 +24,574 @@ \DoxyCodeLine{\Hypertarget{trace_8h_source_l00020}00020\ \textcolor{comment}{\ \ \ \ -\/\ @ref\ SERIAL\_TRACE\_ENABLE\ -\/\ Если\ трассировка\ \ отключена,\ то\ все\ дефайны\ определяются\ как\ 'ничего'\ }} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00021}00021\ \textcolor{comment}{\ \ \ \ \ \ и\ на\ производительность\ кода\ не\ влияют}} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00022}00022\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00023}00023\ \textcolor{comment}{\ \ \ \ -\/\ @ref\ RTT\_TRACE\_ENABLE\ -\/\ для\ RTT\ это\ будет\ вызов\ функции\ SEGGER\_RTT\_printf(),\ с\ подключением\ библиотеки\ SEGGER\_RTT.h}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00024}00024\ \textcolor{comment}{\ \ \ \ \ \ Предварительно\ надо\ подключить\ библиотеку\ SEGGER\ RTT\ и\ вызвать\ функцию\ SEGGER\_RTT\_Init()}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00025}00025\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00026}00026\ \textcolor{comment}{\ \ \ \ -\/\ @ref\ SWO\_TRACE\_ENABLE\ для\ SWO\ это\ будет\ просто\ printf()}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00027}00027\ \textcolor{comment}{\ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00028}00028\ \textcolor{comment}{\ \ \ \ \ \ Но\ библиотеку\ STDOUT\ надо\ подключить\ самостоятельно:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00029}00029\ \textcolor{comment}{\ \ \ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00030}00030\ \textcolor{comment}{\ \ \ \ \ \ @verbatim}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00031}00031\ \textcolor{comment}{\ \ \ \ \ \ \ \ Manage\ Run-\/Time\ Environment\ -\/>\ Compiler\ -\/>\ I/O\ -\/>\ STDOUT\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00032}00032\ \textcolor{comment}{\ \ \ \ \ \ @endverbatim}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00033}00033\ \textcolor{comment}{\ \ \ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00034}00034\ \textcolor{comment}{\ \ \ \ \ \ Для\ SWO\ также\ надо\ включить\ трассировку:\ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00035}00035\ \textcolor{comment}{\ \ \ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00036}00036\ \textcolor{comment}{\ \ \ \ \ \ @verbatim}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00037}00037\ \textcolor{comment}{\ \ \ \ \ \ \ \ Options\ For\ Target\ -\/>\ Debug\ -\/>\ Debugger\ Settings}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00038}00038\ \textcolor{comment}{\ \ \ \ \ \ @endverbatim}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00039}00039\ \textcolor{comment}{\ \ \ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00040}00040\ \textcolor{comment}{\ \ \ \ \ \ В\ вкладке\ Debug:\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00041}00041\ \textcolor{comment}{\ \ \ \ \ \ \ \ -\/\ Port\ =\ SW}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00042}00042\ \textcolor{comment}{\ \ \ \ \ \ В\ вкладке\ Trace:\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00043}00043\ \textcolor{comment}{\ \ \ \ \ \ \ \ -\/\ Указать\ Core\ Clock}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00044}00044\ \textcolor{comment}{\ \ \ \ \ \ \ \ -\/\ Выставить\ Trace\ Port\ =\ SWO}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00045}00045\ \textcolor{comment}{\ \ \ \ \ \ \ \ -\/\ ITM\ -\/\ выбрать\ нужный\ порт\ (для\ Keil\ нулевой\ порт)\ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00046}00046\ \textcolor{comment}{\ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00047}00047\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00048}00048\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00049}00049\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00050}00050\ \textcolor{comment}{\ \ *\ @def\ my\_printf(...)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00051}00051\ \textcolor{comment}{\ \ *\ @brief\ Универсальный\ макрос\ для\ вывода\ трассировки}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00052}00052\ \textcolor{comment}{\ \ *\ @details\ Варианты\ реализации:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00053}00053\ \textcolor{comment}{\ \ *\ \ -\/\ RTT\_TRACE\_ENABLE\ \ \ \ \`{}SEGGER\_RTT\_printf(0,\ ...)`}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00054}00054\ \textcolor{comment}{\ \ *\ \ -\/\ SWO\_TRACE\_ENABLE\ -\/\ \`{}printf(...)`}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00055}00055\ \textcolor{comment}{\ \ *\ \ -\/\ NO\_TRACE\ -\/\ пустой\ макрос}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00056}00056\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00057}00057\ \textcolor{comment}{\ \ *\ @def\ log\_printf(TAG,\ fmt,\ ...)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00058}00058\ \textcolor{comment}{\ \ *\ @brief\ Макрос\ логирования\ с\ поддержкой\ уровней\ LOG\_LEVEL}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00059}00059\ \textcolor{comment}{\ \ *\ @param\ TAG\ \ Тэг\ лога}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00060}00060\ \textcolor{comment}{\ \ *\ @param\ fmt,\ ...\ \ Форматируемая\ строка}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00061}00061\ \textcolor{comment}{\ \ *\ @details\ Варианты\ реализации:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00062}00062\ \textcolor{comment}{\ \ *\ \ -\/\ LOG\_LEVEL\ ==\ 0\ -\/\ логирование\ отключено\ (макрос\ пустой)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00063}00063\ \textcolor{comment}{\ \ *\ \ -\/\ LOG\_LEVEL\ ==\ 1\ -\/\ выводится\ время\ и\ TAG}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00064}00064\ \textcolor{comment}{\ \ *\ \ -\/\ LOG\_LEVEL\ >=\ 2\ -\/\ выводится\ время,\ TAG,\ имя\ файла\ и\ номер\ строки}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00065}00065\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00066}00066\ \textcolor{preprocessor}{\#ifdef\ SERIAL\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00067}00067\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00068}00068\ \textcolor{preprocessor}{\ \ \#if\ defined(RTT\_TRACE\_ENABLE)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00069}00069\ \textcolor{preprocessor}{\ \ \ \ \#undef\ SWO\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00070}00070\ \textcolor{preprocessor}{\ \ \ \ \#include\ "{}SEGGER\_RTT.h"{}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00071}\mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{00071}}\ \textcolor{preprocessor}{\ \ \ \ \#define\ my\_printf(...)\ \ \ \ \ \ \ \ SEGGER\_RTT\_printf(0,\ \_\_VA\_ARGS\_\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00072}00072\ \textcolor{preprocessor}{\ \ \#elif\ defined(SWO\_TRACE\_ENABLE)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00073}00073\ \textcolor{preprocessor}{\ \ \ \ \#undef\ RTT\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00074}00074\ \textcolor{preprocessor}{\ \ \ \ \#define\ my\_printf(...)\ \ \ \ \ \ \ \ printf(\_\_VA\_ARGS\_\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00075}00075\ \textcolor{preprocessor}{\ \ \#else\ }\textcolor{comment}{//\ NO\_TRACE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00076}00076\ \textcolor{preprocessor}{\ \ \ \ \#define\ my\_printf(...)\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00077}00077\ \textcolor{preprocessor}{\ \ \ \ \#warning\ No\ trace\ is\ selected.\ Serial\ debug\ wont\ work.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00078}00078\ \textcolor{preprocessor}{\ \ \#endif\ }\textcolor{comment}{//\ RTT\_TRACE\_ENABLE/SWO\_TRACE\_ENABLE/NO\_TRACE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00079}00079\ \textcolor{preprocessor}{\#else\ }\textcolor{comment}{//SERIAL\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00080}00080\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00081}00081\ \textcolor{preprocessor}{\ \ \#define\ my\_printf(...)\ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00082}00082\ \textcolor{preprocessor}{\ \ \#undef\ RTT\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00083}00083\ \textcolor{preprocessor}{\ \ \#undef\ SWO\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00084}00084\ \ \ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00085}00085\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//SERIAL\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00086}00086\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00087}00087\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00088}00088\ \textcolor{preprocessor}{\#ifndef\ LOG\_LEVEL}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00089}00089\ \textcolor{preprocessor}{\#define\ LOG\_LEVEL\ 1\ \ }\textcolor{comment}{///<\ @brief\ Уровень\ логирования\ (по\ умолчанию\ ==\ 1)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00090}00090\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00091}00091\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00092}00092\ \textcolor{preprocessor}{\#if\ LOG\_LEVEL\ ==\ 0\ }\textcolor{comment}{//\ лог\ отключен}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00093}00093\ \textcolor{preprocessor}{\ \ \ \ \#define\ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00094}00094\ \textcolor{preprocessor}{log\_printf(TAG,\ fmt,\ ...)\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00095}00095\ \textcolor{preprocessor}{\#elif\ LOG\_LEVEL\ ==\ 1\ }\textcolor{comment}{//\ только\ тэг}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00096}\mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26}{00096}}\ \textcolor{preprocessor}{\ \ \ \ \#define\ log\_printf(TAG,\ fmt,\ ...)\ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00097}00097\ \textcolor{preprocessor}{my\_printf("{}\(\backslash\)n[\%lu]\ [\%s]\ "{}\ fmt,\ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00098}00098\ \textcolor{preprocessor}{(unsigned\ long)uwTick,\ TAG,\ \#\#\_\_VA\_ARGS\_\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00099}00099\ \textcolor{preprocessor}{\#elif\ LOG\_LEVEL\ >=\ 2\ }\textcolor{comment}{//\ всё}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00100}00100\ \textcolor{preprocessor}{\ \ \ \ \#define\ log\_printf(TAG,\ fmt,\ ...)\ \ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00101}00101\ \textcolor{preprocessor}{my\_printf("{}\(\backslash\)n[\%lu]\ [\%s]\ (\%s:\%d)\ "{}\ fmt,\ \(\backslash\)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00102}00102\ \textcolor{preprocessor}{(unsigned\ long)uwTick,\ TAG,\ \_\_FILE\_\_,\ \_\_LINE\_\_,\ \#\#\_\_VA\_ARGS\_\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00103}00103\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00104}00104\ \ \ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00105}00105\ \textcolor{comment}{/**\ TRACE\_SERIAL}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00106}00106\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00107}00107\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00108}00108\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00109}00109\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00110}00110\ \textcolor{comment}{\ \ *\ @addtogroup\ TRACE\_GPIO\ \ \ \ GPIO\ trace\ defines}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00111}00111\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ TRACE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00112}00112\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Дефайны\ для\ работы\ с\ GPIO\ трассировкой}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00113}00113\ \textcolor{comment}{\ \ *\ @details\ \ \ \ Определяется\ дефайны\ для\ работы\ с\ GPIO\ трассировкой:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00114}00114\ \textcolor{comment}{\ \ \ \ -\/\ TRACE\_GPIO\_RESET()\ -\/\ для\ сброса\ ножки\ GPIO\ (через\ BSRR)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00115}00115\ \textcolor{comment}{\ \ \ \ -\/\ TRACE\_GPIO\_SET()\ -\/\ для\ выставления\ ножки\ GPIO\ (через\ BSRR)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00116}00116\ \textcolor{comment}{\ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00117}00117\ \textcolor{comment}{\ \ \ \ -\/\ Если\ трассировка\ @ref\ GPIO\_TRACE\_ENABLE\ отключена,\ то\ все\ дефайны\ определяются\ как\ 'ничего'\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00118}00118\ \textcolor{comment}{\ \ \ \ \ \ и\ на\ производительность\ кода\ не\ влияют}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00119}00119\ \textcolor{comment}{\ \ *\ @\{\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00120}00120\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00121}00121\ \textcolor{comment}{\ \ *\ @def\ TRACE\_GPIO\_RESET(\_gpio\_,\ \_pin\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00122}00122\ \textcolor{comment}{\ \ *\ @brief\ Сбросить\ указанную\ ножку\ GPIO}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00123}00123\ \textcolor{comment}{\ \ *\ @param\ \_gpio\_\ \ Указатель\ на\ структуру\ GPIO\ (напр.\ \ GPIOA)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00124}00124\ \textcolor{comment}{\ \ *\ @param\ \_pin\_\ \ \ Номер\ ножки\ (напр.\ GPIO\_PIN\_0)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00125}00125\ \textcolor{comment}{\ \ *\ @details\ Варианты\ реализации:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00126}00126\ \textcolor{comment}{\ \ *\ \ -\/\ GPIO\_TRACE\_ENABLE\ не\ определён\ -\/\ макрос\ пустой}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00127}00127\ \textcolor{comment}{\ \ *\ \ -\/\ GPIO\_TRACE\_ENABLE\ определён\ -\/\ устанавливает\ бит\ сброса\ через\ BSRR\ ((\_pin\_)<<16)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00128}00128\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00129}00129\ \textcolor{comment}{\ \ *\ @def\ TRACE\_GPIO\_SET(\_gpio\_,\ \_pin\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00130}00130\ \textcolor{comment}{\ \ *\ @brief\ Установить\ указанную\ ножку\ GPIO}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00131}00131\ \textcolor{comment}{\ \ *\ @param\ \_gpio\_\ \ Указатель\ на\ структуру\ GPIO\ (например\ GPIOA)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00132}00132\ \textcolor{comment}{\ \ *\ @param\ \_pin\_\ \ \ Номер\ ножки\ (напр.\ GPIO\_PIN\_0)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00133}00133\ \textcolor{comment}{\ \ *\ @details\ Варианты\ реализации:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00134}00134\ \textcolor{comment}{\ \ *\ \ -\/\ GPIO\_TRACE\_ENABLE\ не\ определён\ -\/\ макрос\ пустой}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00135}00135\ \textcolor{comment}{\ \ *\ \ -\/\ GPIO\_TRACE\_ENABLE\ определён\ -\/\ устанавливает\ бит\ установки\ через\ BSRR\ (\_pin\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00136}00136\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00137}00137\ \textcolor{preprocessor}{\#ifndef\ GPIO\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00138}00138\ \textcolor{preprocessor}{\ \ \#define\ TRACE\_GPIO\_SET(\_gpio\_,\_pin\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00139}00139\ \textcolor{preprocessor}{\ \ \#define\ TRACE\_GPIO\_RESET(\_gpio\_,\_pin\_)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00140}00140\ \textcolor{preprocessor}{\#else}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00141}\mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}{00141}}\ \textcolor{preprocessor}{\ \ \#define\ TRACE\_GPIO\_SET(\_gpio\_,\_pin\_)\ \ \ \ \ \ \ \ \ \ (\_gpio\_)-\/>BSRR\ =\ (((\_pin\_)))}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00142}\mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}{00142}}\ \textcolor{preprocessor}{\ \ \#define\ TRACE\_GPIO\_RESET(\_gpio\_,\_pin\_)\ \ \ \ \ \ \ \ (\_gpio\_)-\/>BSRR\ =\ ((\_pin\_)<<16)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00143}00143\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//GPIO\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00144}00144\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00145}00145\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00146}00146\ \textcolor{comment}{/**\ TRACE\_GPIO}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00147}00147\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00148}00148\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00149}00149\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00150}00150\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00151}00151\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00152}00152\ \textcolor{preprocessor}{\#if\ defined(HAL\_MODULE\_ENABLED)\ \&\&\ defined(RTT\_TRACE\_ENABLE)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00153}00153\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00154}00154\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00155}00155\ \textcolor{comment}{\ \ *\ @addtogroup\ TRACE\_RTT\_FLASH\ \ \ \ Flash\ RTT\ Buffer}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00156}00156\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ TRACE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00157}00157\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Макросы\ и\ функции\ для\ сохранения/чтения\ RTT\ буфера\ в\ Flash}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00158}00158\ \textcolor{comment}{\ \ *\ @details\ \ \ \ Модуль\ позволяет\ сохранять\ данные\ RTT\ буфера\ во\ Flash\ и\ читать\ их\ обратно\ по\ тегам.\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00159}00159\ \textcolor{comment}{\ \ *\ Теги\ работают\ следующим\ образом:\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00160}00160\ \textcolor{comment}{\ \ *\ \ -\/\ Базовый\ тег\ (младший\ байт\ =\ 0):\ модуль\ сам\ выбирает\ первый\ свободный\ слот\ во\ Flash;\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00161}00161\ \textcolor{comment}{\ \ *\ \ \ \ новые\ записи\ получают\ автоинкрементированный\ младший\ байт\ тега\ (от\ 0x00\ до\ 0xFF).\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00162}00162\ \textcolor{comment}{\ \ *\ \ -\/\ Конкретный\ тег\ (младший\ байт\ !=\ 0):\ запись\ или\ чтение\ происходит\ строго\ с\ указанным\ тегом;\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00163}00163\ \textcolor{comment}{\ \ *\ \ \ \ если\ слот\ с\ таким\ тегом\ уже\ занят,\ запись\ не\ выполняется.\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00164}00164\ \textcolor{comment}{\ \ *\ \ -\/\ Автоинкремент\ позволяет\ хранить\ несколько\ последовательных\ записей\ в\ пределах\ одного\ базового\ тега,\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00165}00165\ \textcolor{comment}{\ \ *\ \ \ \ без\ необходимости\ вручную\ отслеживать\ адреса\ Flash\ или\ позиции\ буферов.\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00166}00166\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00167}00167\ \textcolor{comment}{\ \ *\ Параметры:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00168}00168\ \textcolor{comment}{\ \ *\ -\/\ @ref\ RTT\_FLASH\_BUFFER\_SIZE\ \ \ \ -\/\ Размер\ буфера\ RTT\ в\ Flash}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00169}00169\ \textcolor{comment}{\ \ *\ -\/\ @ref\ RTT\_FLASH\_SECTOR\ \ \ \ \ \ \ \ \ -\/\ Сектор\ FLASH\ куда\ положится\ RTT\ буфер}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00170}00170\ \textcolor{comment}{\ \ *\ -\/\ @ref\ RTT\_FLASH\_SECTOR\_START\ \ \ -\/\ Начало\ сектора\ RTT\_FLASH\_SECTOR}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00171}00171\ \textcolor{comment}{\ \ *\ -\/\ @ref\ RTT\_FLASH\_SECTOR\_END\ \ \ \ \ -\/\ Конец\ сектора\ RTT\_FLASH\_SECTOR}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00172}00172\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00173}00173\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00174}00174\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00175}00175\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00176}00176\ \ \ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00177}00177\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00178}00178\ \textcolor{comment}{\ \ *\ @brief\ Структура\ RTT,\ которая\ будет\ положена\ в\ Flash}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00179}00179\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00180}\mbox{\hyperlink{struct_r_t_t___flash_header__t}{00180}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00181}\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{00181}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Уникальный\ идентификатор\ буфера}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00182}\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{00182}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Размер\ данных}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00183}\mbox{\hyperlink{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}{00183}}\ \ \ \textcolor{keywordtype}{char}\ \ \ \ \ data[\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}}];\ \ \textcolor{comment}{///<\ Буфер\ RTT}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00184}00184\ \}\ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}};} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00185}00185\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00186}00186\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00187}00187\ \textcolor{comment}{\ \ *\ @brief\ Подготовка\ Flash\ к\ записи}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00188}00188\ \textcolor{comment}{\ \ *\ @details\ Сбрасывает\ ошибки\ Flash\ и\ ожидает\ готовности\ перед\ записью}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00189}00189\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00190}\mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}{00190}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}{RTT\_FlashPrepare}}(\textcolor{keywordtype}{void})} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00191}00191\ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00192}00192\ \ \ HAL\_FLASH\_Unlock();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00193}00193\ \ \ \_\_HAL\_FLASH\_CLEAR\_FLAG(FLASH\_FLAG\_PGSERR\ |\ FLASH\_FLAG\_WRPERR\ |\ FLASH\_FLAG\_OPERR);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00194}00194\ \ \ \textcolor{keywordflow}{while}\ (\_\_HAL\_FLASH\_GET\_FLAG(FLASH\_FLAG\_BSY))\ \{\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00195}00195\ \ \ \_\_NOP();\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00196}00196\ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00197}00197\ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00023}00023\ \textcolor{comment}{\ \ \ \ -\/\ @ref\ RTT\_TRACE\_ENABLE\ -\/\ для\ RTT\ это\ будет\ вызов\ функции\ SEGGER\_RTT\_printf()}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00024}00024\ \textcolor{comment}{\ \ \ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00025}00025\ \textcolor{comment}{\ \ \ \ \ \ Предварительно\ надо\ подключить\ библиотеку\ SEGGER\ RTT\ (SEGGER\_RTT.h)\ и\ вызвать\ функцию\ SEGGER\_RTT\_Init()}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00026}00026\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00027}00027\ \textcolor{comment}{\ \ \ \ -\/\ @ref\ SWO\_TRACE\_ENABLE\ для\ SWO\ это\ будет\ просто\ printf()}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00028}00028\ \textcolor{comment}{\ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00029}00029\ \textcolor{comment}{\ \ \ \ \ \ Предварительно\ надо\ подключить\ библиотеку\ STDOUT\ и\ retarget\ под\ ITM:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00030}00030\ \textcolor{comment}{\ \ \ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00031}00031\ \textcolor{comment}{\ \ \ \ \ \ @verbatim}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00032}00032\ \textcolor{comment}{\ \ \ \ \ \ \ \ Manage\ Run-\/Time\ Environment\ -\/>\ Compiler\ -\/>\ I/O\ -\/>\ STDOUT\ -\/>\ ITM}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00033}00033\ \textcolor{comment}{\ \ \ \ \ \ @endverbatim}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00034}00034\ \textcolor{comment}{\ \ \ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00035}00035\ \textcolor{comment}{\ \ \ \ \ \ Для\ SWO\ также\ надо\ включить\ трассировку:\ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00036}00036\ \textcolor{comment}{\ \ \ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00037}00037\ \textcolor{comment}{\ \ \ \ \ \ @verbatim}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00038}00038\ \textcolor{comment}{\ \ \ \ \ \ \ \ Options\ For\ Target\ -\/>\ Debug\ -\/>\ Debugger\ Settings}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00039}00039\ \textcolor{comment}{\ \ \ \ \ \ @endverbatim}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00040}00040\ \textcolor{comment}{\ \ \ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00041}00041\ \textcolor{comment}{\ \ \ \ \ \ В\ вкладке\ Debug:\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00042}00042\ \textcolor{comment}{\ \ \ \ \ \ \ \ -\/\ Port\ =\ SW}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00043}00043\ \textcolor{comment}{\ \ \ \ \ \ В\ вкладке\ Trace:\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00044}00044\ \textcolor{comment}{\ \ \ \ \ \ \ \ -\/\ Указать\ Core\ Clock}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00045}00045\ \textcolor{comment}{\ \ \ \ \ \ \ \ -\/\ Выставить\ Trace\ Port\ =\ SWO}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00046}00046\ \textcolor{comment}{\ \ \ \ \ \ \ \ -\/\ ITM\ -\/\ выбрать\ нужный\ порт\ (для\ Keil\ нулевой\ порт)\ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00047}00047\ \textcolor{comment}{\ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00048}00048\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00049}00049\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00050}00050\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00051}00051\ \textcolor{comment}{\ \ *\ @def\ my\_printf(...)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00052}00052\ \textcolor{comment}{\ \ *\ @brief\ Универсальный\ макрос\ для\ вывода\ трассировки}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00053}00053\ \textcolor{comment}{\ \ *\ @details\ Варианты\ реализации:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00054}00054\ \textcolor{comment}{\ \ *\ \ -\/\ RTT\_TRACE\_ENABLE\ \ \ \ \`{}SEGGER\_RTT\_printf(0,\ ...)`}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00055}00055\ \textcolor{comment}{\ \ *\ \ -\/\ SWO\_TRACE\_ENABLE\ -\/\ \`{}printf(...)`}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00056}00056\ \textcolor{comment}{\ \ *\ \ -\/\ NO\_TRACE\ -\/\ пустой\ макрос}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00057}00057\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00058}00058\ \textcolor{comment}{\ \ *\ @def\ log\_printf(TAG,\ fmt,\ ...)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00059}00059\ \textcolor{comment}{\ \ *\ @brief\ Макрос\ логирования\ с\ поддержкой\ уровней\ @ref\ LOG\_LEVEL}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00060}00060\ \textcolor{comment}{\ \ *\ @param\ TAG\ \ Тэг\ лога}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00061}00061\ \textcolor{comment}{\ \ *\ @param\ fmt,\ ...\ \ Форматируемая\ строка}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00062}00062\ \textcolor{comment}{\ \ *\ @details\ Варианты\ реализации:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00063}00063\ \textcolor{comment}{\ \ *\ \ -\/\ @ref\ LOG\_LEVEL\ ==\ 0\ -\/\ логирование\ отключено\ (макрос\ пустой)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00064}00064\ \textcolor{comment}{\ \ *\ \ -\/\ @ref\ LOG\_LEVEL\ ==\ 1\ -\/\ выводится\ время\ @ref\ local\_time\ и\ TAG}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00065}00065\ \textcolor{comment}{\ \ *\ @code}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00066}00066\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ [123]\ [ADC]\ Measure\ Done}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00067}00067\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ [456]\ [ADC]\ Measure\ Err}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00068}00068\ \textcolor{comment}{\ \ *\ @endcode}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00069}00069\ \textcolor{comment}{\ \ *\ \ -\/\ @ref\ LOG\_LEVEL\ >=\ 2\ -\/\ выводится\ время,\ TAG,\ имя\ файла\ и\ номер\ строки}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00070}00070\ \textcolor{comment}{\ \ *\ @code}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00071}00071\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ [123]\ [ADC]\ (../Core/Src/adc.c:75)\ Measure\ Done}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00072}00072\ \textcolor{comment}{\ \ \ \ \ \ \ \ \ \ \ \ [456]\ [ADC]\ (../Core/Src/adc.c:80)\ Measure\ Err}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00073}00073\ \textcolor{comment}{\ \ *\ @endcode}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00074}00074\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00075}00075\ \textcolor{preprocessor}{\#ifdef\ SERIAL\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00076}00076\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00077}00077\ \textcolor{preprocessor}{\ \ \#if\ defined(RTT\_TRACE\_ENABLE)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00078}00078\ \textcolor{preprocessor}{\ \ \ \ \#undef\ SWO\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00079}00079\ \textcolor{preprocessor}{\ \ \ \ \#include\ "{}SEGGER\_RTT.h"{}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00080}\mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{00080}}\ \textcolor{preprocessor}{\ \ \ \ \#define\ my\_printf(...)\ \ \ \ \ \ \ \ SEGGER\_RTT\_printf(0,\ \_\_VA\_ARGS\_\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00081}00081\ \textcolor{preprocessor}{\ \ \#elif\ defined(SWO\_TRACE\_ENABLE)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00082}00082\ \textcolor{preprocessor}{\ \ \ \ \#undef\ RTT\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00083}00083\ \textcolor{preprocessor}{\ \ \ \ \#define\ my\_printf(...)\ \ \ \ \ \ \ \ printf(\_\_VA\_ARGS\_\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00084}00084\ \textcolor{preprocessor}{\ \ \#else\ }\textcolor{comment}{//\ NO\_TRACE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00085}00085\ \textcolor{preprocessor}{\ \ \ \ \#define\ my\_printf(...)\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00086}00086\ \textcolor{preprocessor}{\ \ \ \ \#warning\ No\ trace\ is\ selected.\ Serial\ debug\ wont\ work.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00087}00087\ \textcolor{preprocessor}{\ \ \#endif\ }\textcolor{comment}{//\ RTT\_TRACE\_ENABLE/SWO\_TRACE\_ENABLE/NO\_TRACE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00088}00088\ \textcolor{preprocessor}{\#else\ }\textcolor{comment}{//SERIAL\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00089}00089\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00090}00090\ \textcolor{preprocessor}{\ \ \#define\ my\_printf(...)\ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00091}00091\ \textcolor{preprocessor}{\ \ \#undef\ RTT\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00092}00092\ \textcolor{preprocessor}{\ \ \#undef\ SWO\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00093}00093\ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00094}00094\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//SERIAL\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00095}00095\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00096}00096\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00097}00097\ \textcolor{preprocessor}{\#ifndef\ local\_time}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00098}00098\ \textcolor{preprocessor}{\#define\ local\_time()\ \ HAL\_GetTick()\ }\textcolor{comment}{///<\ Локальное\ время}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00099}00099\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00100}00100\ \textcolor{preprocessor}{\#ifndef\ LOG\_LEVEL}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00101}00101\ \textcolor{preprocessor}{\#define\ LOG\_LEVEL\ 1\ \ }\textcolor{comment}{///<\ @brief\ Уровень\ логирования\ (по\ умолчанию\ ==\ 1)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00102}00102\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00103}00103\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00104}00104\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00105}00105\ \textcolor{preprocessor}{\#if\ LOG\_LEVEL\ ==\ 0\ }\textcolor{comment}{//\ лог\ отключен}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00106}00106\ \textcolor{preprocessor}{\ \ \ \ \#define\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00107}00107\ \textcolor{preprocessor}{log\_printf(TAG,\ fmt,\ ...)\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00108}00108\ \textcolor{preprocessor}{\#elif\ LOG\_LEVEL\ ==\ 1\ }\textcolor{comment}{//\ только\ тэг}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00109}\mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_ga730fb7b8d0bbb348dca73c15bd0e0b26}{00109}}\ \textcolor{preprocessor}{\ \ \ \ \#define\ log\_printf(TAG,\ fmt,\ ...)\ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00110}00110\ \textcolor{preprocessor}{my\_printf("{}\(\backslash\)n[\%lu]\ [\%s]\ "{}\ fmt,\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00111}00111\ \textcolor{preprocessor}{(unsigned\ long)local\_time(),\ TAG,\ \#\#\_\_VA\_ARGS\_\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00112}00112\ \textcolor{preprocessor}{\#elif\ LOG\_LEVEL\ >=\ 2\ }\textcolor{comment}{//\ всё}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00113}00113\ \textcolor{preprocessor}{\ \ \ \ \#define\ log\_printf(TAG,\ fmt,\ ...)\ \ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00114}00114\ \textcolor{preprocessor}{my\_printf("{}\(\backslash\)n[\%lu]\ [\%s]\ (\%s:\%d)\ "{}\ fmt,\ \(\backslash\)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00115}00115\ \textcolor{preprocessor}{(unsigned\ long)local\_time(),\ TAG,\ \_\_FILE\_\_,\ \_\_LINE\_\_,\ \#\#\_\_VA\_ARGS\_\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00116}00116\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00117}00117\ \ \ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00118}00118\ \textcolor{comment}{/**\ TRACE\_SERIAL}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00119}00119\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00120}00120\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00121}00121\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00122}00122\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00123}00123\ \textcolor{comment}{\ \ *\ @addtogroup\ TRACE\_GPIO\ \ \ \ GPIO\ trace\ defines}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00124}00124\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ TRACE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00125}00125\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Дефайны\ для\ работы\ с\ GPIO\ трассировкой}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00126}00126\ \textcolor{comment}{\ \ *\ @details\ \ \ \ Определяется\ дефайны\ для\ работы\ с\ GPIO\ трассировкой:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00127}00127\ \textcolor{comment}{\ \ \ \ -\/\ TRACE\_GPIO\_RESET()\ -\/\ для\ сброса\ ножки\ GPIO\ (через\ BSRR)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00128}00128\ \textcolor{comment}{\ \ \ \ -\/\ TRACE\_GPIO\_SET()\ -\/\ для\ выставления\ ножки\ GPIO\ (через\ BSRR)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00129}00129\ \textcolor{comment}{\ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00130}00130\ \textcolor{comment}{\ \ \ \ -\/\ Если\ трассировка\ @ref\ GPIO\_TRACE\_ENABLE\ отключена,\ то\ все\ дефайны\ определяются\ как\ 'ничего'\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00131}00131\ \textcolor{comment}{\ \ \ \ \ \ и\ на\ производительность\ кода\ не\ влияют}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00132}00132\ \textcolor{comment}{\ \ *\ @\{\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00133}00133\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00134}00134\ \textcolor{comment}{\ \ *\ @def\ TRACE\_GPIO\_RESET(\_gpio\_,\ \_pin\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00135}00135\ \textcolor{comment}{\ \ *\ @brief\ Сбросить\ указанную\ ножку\ GPIO}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00136}00136\ \textcolor{comment}{\ \ *\ @param\ \_gpio\_\ \ Указатель\ на\ структуру\ GPIO\ (напр.\ \ GPIOA)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00137}00137\ \textcolor{comment}{\ \ *\ @param\ \_pin\_\ \ \ Номер\ ножки\ (напр.\ GPIO\_PIN\_0)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00138}00138\ \textcolor{comment}{\ \ *\ @details\ Варианты\ реализации:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00139}00139\ \textcolor{comment}{\ \ *\ \ -\/\ GPIO\_TRACE\_ENABLE\ не\ определён\ -\/\ макрос\ пустой}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00140}00140\ \textcolor{comment}{\ \ *\ \ -\/\ GPIO\_TRACE\_ENABLE\ определён\ -\/\ устанавливает\ бит\ сброса\ через\ BSRR\ ((\_pin\_)<<16)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00141}00141\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00142}00142\ \textcolor{comment}{\ \ *\ @def\ TRACE\_GPIO\_SET(\_gpio\_,\ \_pin\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00143}00143\ \textcolor{comment}{\ \ *\ @brief\ Установить\ указанную\ ножку\ GPIO}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00144}00144\ \textcolor{comment}{\ \ *\ @param\ \_gpio\_\ \ Указатель\ на\ структуру\ GPIO\ (например\ GPIOA)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00145}00145\ \textcolor{comment}{\ \ *\ @param\ \_pin\_\ \ \ Номер\ ножки\ (напр.\ GPIO\_PIN\_0)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00146}00146\ \textcolor{comment}{\ \ *\ @details\ Варианты\ реализации:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00147}00147\ \textcolor{comment}{\ \ *\ \ -\/\ GPIO\_TRACE\_ENABLE\ не\ определён\ -\/\ макрос\ пустой}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00148}00148\ \textcolor{comment}{\ \ *\ \ -\/\ GPIO\_TRACE\_ENABLE\ определён\ -\/\ устанавливает\ бит\ установки\ через\ BSRR\ (\_pin\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00149}00149\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00150}00150\ \textcolor{preprocessor}{\#ifndef\ GPIO\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00151}00151\ \textcolor{preprocessor}{\ \ \#define\ TRACE\_GPIO\_SET(\_gpio\_,\_pin\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00152}00152\ \textcolor{preprocessor}{\ \ \#define\ TRACE\_GPIO\_RESET(\_gpio\_,\_pin\_)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00153}00153\ \textcolor{preprocessor}{\#else}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00154}\mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga02a6a7b273766121db8ad4a1371373eb}{00154}}\ \textcolor{preprocessor}{\ \ \#define\ TRACE\_GPIO\_SET(\_gpio\_,\_pin\_)\ \ \ \ \ \ \ \ \ \ (\_gpio\_)-\/>BSRR\ =\ (((\_pin\_)))}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00155}\mbox{\hyperlink{group___t_r_a_c_e___g_p_i_o_ga69741d88c991112e99fe7a62e025108a}{00155}}\ \textcolor{preprocessor}{\ \ \#define\ TRACE\_GPIO\_RESET(\_gpio\_,\_pin\_)\ \ \ \ \ \ \ \ (\_gpio\_)-\/>BSRR\ =\ ((\_pin\_)<<16)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00156}00156\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//GPIO\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00157}00157\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00158}00158\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00159}00159\ \textcolor{comment}{/**\ TRACE\_GPIO}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00160}00160\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00161}00161\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00162}00162\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00163}00163\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00164}00164\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00165}00165\ \textcolor{preprocessor}{\#if\ defined(HAL\_MODULE\_ENABLED)\ \&\&\ defined(RTT\_TRACE\_ENABLE)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00166}00166\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00167}00167\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00168}00168\ \textcolor{comment}{\ \ *\ @addtogroup\ TRACE\_RTT\_FLASH\ \ \ \ Flash\ RTT\ Buffer}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00169}00169\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ TRACE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00170}00170\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ Макросы\ и\ функции\ для\ сохранения/чтения\ RTT\ буфера\ в\ Flash}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00171}00171\ \textcolor{comment}{\ \ *\ @details\ \ \ \ Модуль\ позволяет\ сохранять\ данные\ RTT\ буфера\ во\ Flash\ и\ читать\ их\ обратно\ по\ тегам.\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00172}00172\ \textcolor{comment}{\ \ *\ Теги\ работают\ следующим\ образом:\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00173}00173\ \textcolor{comment}{\ \ *\ \ -\/\ Базовый\ тег\ (младший\ байт\ =\ 0):\ модуль\ сам\ выбирает\ первый\ свободный\ слот\ во\ Flash;\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00174}00174\ \textcolor{comment}{\ \ *\ \ \ \ новые\ записи\ получают\ автоинкрементированный\ младший\ байт\ тега\ (от\ 0x00\ до\ 0xFF).\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00175}00175\ \textcolor{comment}{\ \ *\ \ -\/\ Конкретный\ тег\ (младший\ байт\ !=\ 0):\ запись\ или\ чтение\ происходит\ строго\ с\ указанным\ тегом;\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00176}00176\ \textcolor{comment}{\ \ *\ \ \ \ если\ слот\ с\ таким\ тегом\ уже\ занят,\ запись\ не\ выполняется.\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00177}00177\ \textcolor{comment}{\ \ *\ \ -\/\ Автоинкремент\ позволяет\ хранить\ несколько\ последовательных\ записей\ в\ пределах\ одного\ базового\ тега,\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00178}00178\ \textcolor{comment}{\ \ *\ \ \ \ без\ необходимости\ вручную\ отслеживать\ адреса\ Flash\ или\ позиции\ буферов.\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00179}00179\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00180}00180\ \textcolor{comment}{\ \ *\ Параметры:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00181}00181\ \textcolor{comment}{\ \ *\ -\/\ @ref\ RTT\_FLASH\_BUFFER\_SIZE\ \ \ \ -\/\ Размер\ буфера\ RTT\ в\ Flash}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00182}00182\ \textcolor{comment}{\ \ *\ -\/\ @ref\ RTT\_FLASH\_SECTOR\ \ \ \ \ \ \ \ \ -\/\ Сектор\ FLASH\ куда\ положится\ RTT\ буфер}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00183}00183\ \textcolor{comment}{\ \ *\ -\/\ @ref\ RTT\_FLASH\_SECTOR\_START\ \ \ -\/\ Начало\ сектора\ RTT\_FLASH\_SECTOR}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00184}00184\ \textcolor{comment}{\ \ *\ -\/\ @ref\ RTT\_FLASH\_SECTOR\_END\ \ \ \ \ -\/\ Конец\ сектора\ RTT\_FLASH\_SECTOR}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00185}00185\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00186}00186\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00187}00187\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00188}00188\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00189}00189\ \ \ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00190}00190\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00191}00191\ \textcolor{comment}{\ \ *\ @brief\ Структура\ RTT,\ которая\ будет\ положена\ в\ Flash}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00192}00192\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00193}\mbox{\hyperlink{struct_r_t_t___flash_header__t}{00193}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00194}\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{00194}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Уникальный\ идентификатор\ буфера}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00195}\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{00195}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}};\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{comment}{///<\ Размер\ данных}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00196}\mbox{\hyperlink{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}{00196}}\ \ \ \textcolor{keywordtype}{char}\ \ \ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}{data}}[\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}}];\ \ \textcolor{comment}{///<\ Буфер\ RTT}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00197}00197\ \}\ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}};} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00198}00198\ \textcolor{comment}{}} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00199}00199\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00200}00200\ \textcolor{comment}{\ \ *\ @brief\ Сохраняет\ последние\ символы\ RTT-\/буфера\ в\ Flash\ по\ тегу}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00201}00201\ \textcolor{comment}{\ \ *\ @param\ tag\ \ \ \ \ \ \ \ Базовый\ или\ конкретный\ идентификатор\ буфера.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00202}00202\ \textcolor{comment}{\ \ *\ @param\ tail\_size\ \ Количество\ последних\ символов\ RTT\ для\ копирования}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00203}00203\ \textcolor{comment}{\ \ *\ @param\ buf\_num\ \ \ \ Указатель\ на\ переменную\ в\ которую\ запишется\ номер\ буфера\ для\ конкретного\ тега}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00204}00204\ \textcolor{comment}{\ \ *\ @return\ >=0\ —\ номер\ буфера\ (тег)\ для\ записи,\ <0\ —\ ошибка\ (нет\ места,\ тег\ уже\ занят,\ ошибка\ записи\ в\ флеш)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00205}00205\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00206}00206\ \textcolor{comment}{\ \ *\ @details\ \ Автоматически\ копирует\ последние\ tail\_size\ символов\ из\ RTT-\/буфера}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00207}00207\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ и\ записывает\ их\ во\ Flash.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00208}00208\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ Тег\ может\ быть\ базовым\ или\ конкретным:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00209}00209\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Если\ базовый\ (младший\ байт\ ==\ 0)\ —\ будет\ выбран\ первый\ свободный\ слот\ с\ автоинкрементом.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00210}00210\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Автоинкремент\ формируется\ в\ пределах\ от\ 0x1\ до\ 0xFF}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00211}00211\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Если\ конкретный\ (младший\ байт\ !=\ 0)\ —\ запись\ выполняется\ только\ с\ этим\ тегом,\ иначе\ ошибка.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00212}00212\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00213}00213\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00214}\mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63}{00214}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63}{RTT\_SaveToFlash}}(uint32\_t\ tag,\ uint32\_t\ tail\_size)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00215}00215\ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00216}00216\ \ \ \textcolor{keywordflow}{if}\ (tag\ ==\ 0xFFFFFFFF)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00217}00217\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Неверный\ тег}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00218}00218\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00219}00219\ \ \ SEGGER\_RTT\_BUFFER\_UP\ *up\ =\ \&\_SEGGER\_RTT.aUp[0];} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00220}00220\ \ \ \textcolor{keywordtype}{unsigned}\ buf\_size\ =\ up-\/>SizeOfBuffer;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00221}00221\ \ \ \textcolor{keywordtype}{unsigned}\ wr\ =\ up-\/>WrOff;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00222}00222\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00223}00223\ \ \ \textcolor{comment}{//\ Ограничиваем\ по\ размеру\ буфера\ RTT\ и\ RTT\_FLASH\_BUFFER\_SIZE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00224}00224\ \ \ \textcolor{keywordtype}{unsigned}\ n\ =\ (tail\_size\ >\ buf\_size)\ ?\ buf\_size\ :\ tail\_size;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00225}00225\ \ \ \textcolor{keywordflow}{if}\ (n\ >\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}})} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00226}00226\ \ \ \ \ n\ =\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}};} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00227}00227\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00228}00228\ \ \ uint32\_t\ addr\ =\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga8e56f75d3ab8a89ddde1404ae23c3297}{RTT\_FLASH\_SECTOR\_START}};} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00229}00229\ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *flash\_hdr\ =\ NULL;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00230}00230\ \ \ uint32\_t\ base\_tag\ =\ tag\ \&\ 0xFFFFFF00;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00231}00231\ \ \ uint32\_t\ next\_tag\ =\ (tag\ \&\ 0xFF)\ ==\ 0\ ?\ tag\ +\ 1\ :\ tag;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00232}00232\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00233}00233\ \ \ \textcolor{comment}{//\ Ищем\ первый\ свободный\ слот,\ параллельно\ автоинкрементируем\ тег}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00234}00234\ \ \ \textcolor{keywordflow}{while}\ ((addr\ +\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}))\ <=\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}{RTT\_FLASH\_SECTOR\_END}})} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00235}00235\ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00236}00236\ \ \ \ \ flash\_hdr\ =\ (\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *)addr;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00237}00237\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00238}00238\ \ \ \ \ \textcolor{keywordflow}{if}\ (flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ ==\ 0xFFFFFFFF)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00239}00239\ \ \ \ \ \ \ \textcolor{keywordflow}{break};\ \ \textcolor{comment}{//\ Нашли\ свободное\ место}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00200}00200\ \textcolor{comment}{\ \ *\ @brief\ Подготовка\ Flash\ к\ записи}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00201}00201\ \textcolor{comment}{\ \ *\ @details\ Сбрасывает\ ошибки\ Flash\ и\ ожидает\ готовности\ перед\ записью}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00202}00202\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00203}\mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}{00203}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}{RTT\_FlashPrepare}}(\textcolor{keywordtype}{void})} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00204}00204\ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00205}00205\ \ \ HAL\_FLASH\_Unlock();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00206}00206\ \ \ \_\_HAL\_FLASH\_CLEAR\_FLAG(FLASH\_FLAG\_PGSERR\ |\ FLASH\_FLAG\_WRPERR\ |\ FLASH\_FLAG\_OPERR);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00207}00207\ \ \ \textcolor{keywordflow}{while}\ (\_\_HAL\_FLASH\_GET\_FLAG(FLASH\_FLAG\_BSY))\ \{\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00208}00208\ \ \ \_\_NOP();\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00209}00209\ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00210}00210\ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00211}00211\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00212}00212\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00213}00213\ \textcolor{comment}{\ \ *\ @brief\ Сохраняет\ последние\ символы\ RTT-\/буфера\ в\ Flash\ по\ тегу}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00214}00214\ \textcolor{comment}{\ \ *\ @param\ tag\ \ \ \ \ \ \ \ Базовый\ или\ конкретный\ идентификатор\ буфера.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00215}00215\ \textcolor{comment}{\ \ *\ @param\ tail\_size\ \ Количество\ последних\ символов\ RTT\ для\ копирования}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00216}00216\ \textcolor{comment}{\ \ *\ @param\ buf\_num\ \ \ \ Указатель\ на\ переменную\ в\ которую\ запишется\ номер\ буфера\ для\ конкретного\ тега}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00217}00217\ \textcolor{comment}{\ \ *\ @return\ >=0\ —\ номер\ буфера\ (тег)\ для\ записи,\ <0\ —\ ошибка\ (нет\ места,\ тег\ уже\ занят,\ ошибка\ записи\ в\ флеш)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00218}00218\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00219}00219\ \textcolor{comment}{\ \ *\ @details\ \ Автоматически\ копирует\ последние\ tail\_size\ символов\ из\ RTT-\/буфера}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00220}00220\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ и\ записывает\ их\ во\ Flash.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00221}00221\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ Тег\ может\ быть\ базовым\ или\ конкретным:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00222}00222\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Если\ базовый\ (младший\ байт\ ==\ 0)\ —\ будет\ выбран\ первый\ свободный\ слот\ с\ автоинкрементом.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00223}00223\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Автоинкремент\ формируется\ в\ пределах\ от\ 0x1\ до\ 0xFF}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00224}00224\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Если\ конкретный\ (младший\ байт\ !=\ 0)\ —\ запись\ выполняется\ только\ с\ этим\ тегом,\ иначе\ ошибка.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00225}00225\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00226}00226\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00227}\mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63}{00227}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63}{RTT\_SaveToFlash}}(uint32\_t\ tag,\ uint32\_t\ tail\_size)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00228}00228\ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00229}00229\ \ \ \textcolor{keywordflow}{if}\ (tag\ ==\ 0xFFFFFFFF)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00230}00230\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Неверный\ тег}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00231}00231\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00232}00232\ \ \ SEGGER\_RTT\_BUFFER\_UP\ *up\ =\ \&\_SEGGER\_RTT.aUp[0];} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00233}00233\ \ \ \textcolor{keywordtype}{unsigned}\ buf\_size\ =\ up-\/>SizeOfBuffer;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00234}00234\ \ \ \textcolor{keywordtype}{unsigned}\ wr\ =\ up-\/>WrOff;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00235}00235\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00236}00236\ \ \ \textcolor{comment}{//\ Ограничиваем\ по\ размеру\ буфера\ RTT\ и\ RTT\_FLASH\_BUFFER\_SIZE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00237}00237\ \ \ \textcolor{keywordtype}{unsigned}\ n\ =\ (tail\_size\ >\ buf\_size)\ ?\ buf\_size\ :\ tail\_size;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00238}00238\ \ \ \textcolor{keywordflow}{if}\ (n\ >\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}})} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00239}00239\ \ \ \ \ n\ =\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}};} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00240}00240\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00241}00241\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00242}00242\ \ \ \ \ \textcolor{keywordflow}{if}((flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ \&\ 0xFFFFFF00)\ ==\ base\_tag)\ \textcolor{comment}{//\ выбраный\ тег}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00243}00243\ \ \ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00244}00244\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ ((tag\ \&\ 0xFF)\ ==\ 0)\ \textcolor{comment}{//\ если\ он\ базовый\ -\/\ ищем\ последний}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00245}00245\ \ \ \ \ \ \ \ \ next\_tag\ =\ flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ +\ 1;\ \ \textcolor{comment}{//\ автоинкремент}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00246}00246\ \ \ \ \ \ \ \textcolor{keywordflow}{else}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00247}00247\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}(flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ ==\ tag)\ \textcolor{comment}{//\ если\ он\ конкретный\ и\ уже\ существует\ -\/\ то\ ошибка}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00248}00248\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ конкретный\ тег\ уже\ занят}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00249}00249\ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00241}00241\ \ \ uint32\_t\ addr\ =\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga8e56f75d3ab8a89ddde1404ae23c3297}{RTT\_FLASH\_SECTOR\_START}};} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00242}00242\ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *flash\_hdr\ =\ NULL;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00243}00243\ \ \ uint32\_t\ base\_tag\ =\ tag\ \&\ 0xFFFFFF00;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00244}00244\ \ \ uint32\_t\ next\_tag\ =\ (tag\ \&\ 0xFF)\ ==\ 0\ ?\ tag\ +\ 1\ :\ tag;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00245}00245\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00246}00246\ \ \ \textcolor{comment}{//\ Ищем\ первый\ свободный\ слот,\ параллельно\ автоинкрементируем\ тег}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00247}00247\ \ \ \textcolor{keywordflow}{while}\ ((addr\ +\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}))\ <=\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}{RTT\_FLASH\_SECTOR\_END}})} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00248}00248\ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00249}00249\ \ \ \ \ flash\_hdr\ =\ (\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *)addr;} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00250}00250\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00251}00251\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00252}00252\ \ \ \ \ \textcolor{keywordflow}{if}(next\_tag\ -\/\ tag\ >\ 0xFF)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00253}00253\ \ \ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \textcolor{comment}{//\ автоинкремент\ слишком\ большой}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00251}00251\ \ \ \ \ \textcolor{keywordflow}{if}\ (flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ ==\ 0xFFFFFFFF)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00252}00252\ \ \ \ \ \ \ \textcolor{keywordflow}{break};\ \ \textcolor{comment}{//\ Нашли\ свободное\ место}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00253}00253\ } \DoxyCodeLine{\Hypertarget{trace_8h_source_l00254}00254\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00255}00255\ \ \ \ \ addr\ +=\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00256}00256\ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00257}00257\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00258}00258\ \ \ \textcolor{keywordflow}{if}\ ((addr\ +\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}))\ >\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}{RTT\_FLASH\_SECTOR\_END}})} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00259}00259\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Нет\ свободного\ места}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00260}00260\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00261}00261\ \ \ \textcolor{comment}{//\ Копируем\ последние\ n\ символов\ из\ RTT}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00262}00262\ \ \ \textcolor{keywordtype}{char}\ temp[\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}}];} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00263}00263\ \ \ \textcolor{keywordtype}{unsigned}\ valid\_count\ =\ 0;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00264}00264\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00265}00265\ \ \ \textcolor{keywordflow}{for}\ (\textcolor{keywordtype}{unsigned}\ i\ =\ 0;\ i\ <\ n;\ i++)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00266}00266\ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00267}00267\ \ \ \ \ \textcolor{keywordtype}{unsigned}\ idx\ =\ (wr\ +\ buf\_size\ -\/\ n\ +\ i)\ \%\ buf\_size;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00268}00268\ \ \ \ \ \textcolor{keywordtype}{char}\ c\ =\ up-\/>pBuffer[idx];} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00269}00269\ \ \ \ \ \textcolor{keywordflow}{if}\ (c\ !=\ 0)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00270}00270\ \ \ \ \ \ \ temp[valid\_count++]\ =\ c;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00271}00271\ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00272}00272\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00273}00273\ \ \ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}{RTT\_FlashPrepare}}();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00274}00274\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00275}00275\ \ \ \textcolor{comment}{//\ Формируем\ структуру\ в\ RAM}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00276}00276\ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ flash\_data;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00277}00277\ \ \ flash\_data.\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ \ =\ next\_tag;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00278}00278\ \ \ flash\_data.\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}}\ =\ valid\_count;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00279}00279\ \ \ memcpy(flash\_data.\mbox{\hyperlink{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}{data}},\ temp,\ valid\_count);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00280}00280\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00281}00281\ \ \ \textcolor{comment}{//\ Записываем\ структуру\ во\ Flash\ (по\ 4\ байта)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00282}00282\ \ \ \textcolor{keyword}{const}\ uint32\_t\ *p\ =\ (\textcolor{keyword}{const}\ uint32\_t\ *)\&flash\_data;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00283}00283\ \ \ \textcolor{keywordflow}{for}\ (\textcolor{keywordtype}{unsigned}\ i\ =\ 0;\ i\ <\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}})\ /\ 4;\ i++)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00284}00284\ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00285}00285\ \ \ \ \ \textcolor{keywordflow}{if}(HAL\_FLASH\_Program(FLASH\_TYPEPROGRAM\_WORD,\ addr\ +\ i\ *\ 4,\ p[i])\ !=\ HAL\_OK)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00286}00286\ \ \ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00287}00287\ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00288}00288\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00289}00289\ \ \ HAL\_FLASH\_Lock();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00290}00290\ \ \ \_\_DSB();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00291}00291\ \ \ \_\_ISB();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00292}00292\ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00255}00255\ \ \ \ \ \textcolor{keywordflow}{if}((flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ \&\ 0xFFFFFF00)\ ==\ base\_tag)\ \textcolor{comment}{//\ выбраный\ тег}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00256}00256\ \ \ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00257}00257\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ ((tag\ \&\ 0xFF)\ ==\ 0)\ \textcolor{comment}{//\ если\ он\ базовый\ -\/\ ищем\ последний}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00258}00258\ \ \ \ \ \ \ \ \ next\_tag\ =\ flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ +\ 1;\ \ \textcolor{comment}{//\ автоинкремент}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00259}00259\ \ \ \ \ \ \ \textcolor{keywordflow}{else}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00260}00260\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}(flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ ==\ tag)\ \textcolor{comment}{//\ если\ он\ конкретный\ и\ уже\ существует\ -\/\ то\ ошибка}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00261}00261\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ конкретный\ тег\ уже\ занят}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00262}00262\ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00263}00263\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00264}00264\ \ \ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00265}00265\ \ \ \ \ \textcolor{keywordflow}{if}(next\_tag\ -\/\ tag\ >\ 0xFF)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00266}00266\ \ \ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \textcolor{comment}{//\ автоинкремент\ слишком\ большой}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00267}00267\ \ \ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00268}00268\ \ \ \ \ addr\ +=\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}});} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00269}00269\ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00270}00270\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00271}00271\ \ \ \textcolor{keywordflow}{if}\ ((addr\ +\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}))\ >\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}{RTT\_FLASH\_SECTOR\_END}})} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00272}00272\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Нет\ свободного\ места}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00273}00273\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00274}00274\ \ \ \textcolor{comment}{//\ Копируем\ последние\ n\ символов\ из\ RTT}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00275}00275\ \ \ \textcolor{keywordtype}{char}\ temp[\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}}];} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00276}00276\ \ \ \textcolor{keywordtype}{unsigned}\ valid\_count\ =\ 0;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00277}00277\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00278}00278\ \ \ \textcolor{keywordflow}{for}\ (\textcolor{keywordtype}{unsigned}\ i\ =\ 0;\ i\ <\ n;\ i++)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00279}00279\ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00280}00280\ \ \ \ \ \textcolor{keywordtype}{unsigned}\ idx\ =\ (wr\ +\ buf\_size\ -\/\ n\ +\ i)\ \%\ buf\_size;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00281}00281\ \ \ \ \ \textcolor{keywordtype}{char}\ c\ =\ up-\/>pBuffer[idx];} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00282}00282\ \ \ \ \ \textcolor{keywordflow}{if}\ (c\ !=\ 0)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00283}00283\ \ \ \ \ \ \ temp[valid\_count++]\ =\ c;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00284}00284\ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00285}00285\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00286}00286\ \ \ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}{RTT\_FlashPrepare}}();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00287}00287\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00288}00288\ \ \ \textcolor{comment}{//\ Формируем\ структуру\ в\ RAM}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00289}00289\ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ flash\_data;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00290}00290\ \ \ flash\_data.\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ \ =\ next\_tag;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00291}00291\ \ \ flash\_data.\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}}\ =\ valid\_count;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00292}00292\ \ \ memcpy(flash\_data.\mbox{\hyperlink{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}{data}},\ temp,\ valid\_count);} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00293}00293\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00294}00294\ \ \ \textcolor{keywordflow}{return}\ (\textcolor{keywordtype}{int})(next\_tag\&0xFF);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00295}00295\ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00296}00296\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00297}00297\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00298}00298\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00299}00299\ \textcolor{comment}{\ \ *\ @brief\ Читает\ последние\ символы\ RTT-\/буфера\ из\ Flash\ по\ тегу}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00300}00300\ \textcolor{comment}{\ \ *\ @param\ tag\ \ \ \ \ \ \ \ Базовый\ или\ конкретный\ идентификатор\ буфера.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00301}00301\ \textcolor{comment}{\ \ *\ @param\ Buffer\ \ \ \ \ Буфер\ назначения\ для\ копирования\ данных}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00302}00302\ \textcolor{comment}{\ \ *\ @param\ tail\_size\ \ Количество\ последних\ символов,\ которые\ нужно\ прочитать}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00303}00303\ \textcolor{comment}{\ \ *\ @param\ read\_size\ \ Количество\ считанных\ символов}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00304}00304\ \textcolor{comment}{\ \ *\ @return\ >=0\ —\ номер\ буфера\ (тег)\ для\ записи,\ <0\ —\ ошибка\ (тег\ не\ найден\ или\ структура\ повреждена)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00305}00305\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00306}00306\ \textcolor{comment}{\ \ *\ @details\ \ Копирует\ последние\ tail\_size\ символов\ из\ найденной\ записи\ Flash\ в\ Buffer.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00307}00307\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ Тег\ может\ быть\ базовым\ или\ конкретным:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00308}00308\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Если\ базовый\ (младший\ байт\ ==\ 0)\ —\ будет\ прочитана\ последняя\ запись\ из\ группы.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00309}00309\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Если\ конкретный\ (младший\ байт\ !=\ 0)\ —\ прочитывается\ именно\ эта\ запись.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00310}00310\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00311}\mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146}{00311}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146}{RTT\_ReadFromFlash}}(uint32\_t\ tag,\ \textcolor{keywordtype}{char}\ *Buffer,\ uint32\_t\ tail\_size,\ uint32\_t\ *read\_size)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00312}00312\ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00313}00313\ \ \ \textcolor{keywordflow}{if}\ (!Buffer\ ||\ tail\_size\ ==\ 0)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00314}00314\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Неверные\ параметры}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00315}00315\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00316}00316\ \ \ \textcolor{keywordflow}{if}\ (tag\ ==\ 0xFFFFFFFF)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00317}00317\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Недопустимый\ тег}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00318}00318\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00319}00319\ \ \ uint32\_t\ addr\ =\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga8e56f75d3ab8a89ddde1404ae23c3297}{RTT\_FLASH\_SECTOR\_START}};} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00320}00320\ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *flash\_hdr\ =\ NULL;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00321}00321\ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *target\_hdr\ =\ NULL;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00322}00322\ \ \ uint32\_t\ base\_tag\ =\ tag\ \&\ 0xFFFFFF00;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00323}00323\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00324}00324\ \ \ \textcolor{comment}{//\ Поиск\ записи\ по\ тегу}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00325}00325\ \ \ \textcolor{keywordflow}{while}\ ((addr\ +\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}))\ <=\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}{RTT\_FLASH\_SECTOR\_END}})} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00326}00326\ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00327}00327\ \ \ \ \ flash\_hdr\ =\ (\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *)addr;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00294}00294\ \ \ \textcolor{comment}{//\ Записываем\ структуру\ во\ Flash\ (по\ 4\ байта)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00295}00295\ \ \ \textcolor{keyword}{const}\ uint32\_t\ *p\ =\ (\textcolor{keyword}{const}\ uint32\_t\ *)\&flash\_data;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00296}00296\ \ \ \textcolor{keywordflow}{for}\ (\textcolor{keywordtype}{unsigned}\ i\ =\ 0;\ i\ <\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}})\ /\ 4;\ i++)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00297}00297\ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00298}00298\ \ \ \ \ \textcolor{keywordflow}{if}(HAL\_FLASH\_Program(FLASH\_TYPEPROGRAM\_WORD,\ addr\ +\ i\ *\ 4,\ p[i])\ !=\ HAL\_OK)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00299}00299\ \ \ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00300}00300\ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00301}00301\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00302}00302\ \ \ HAL\_FLASH\_Lock();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00303}00303\ \ \ \_\_DSB();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00304}00304\ \ \ \_\_ISB();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00305}00305\ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00306}00306\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00307}00307\ \ \ \textcolor{keywordflow}{return}\ (\textcolor{keywordtype}{int})(next\_tag\&0xFF);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00308}00308\ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00309}00309\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00310}00310\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00311}00311\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00312}00312\ \textcolor{comment}{\ \ *\ @brief\ Читает\ последние\ символы\ RTT-\/буфера\ из\ Flash\ по\ тегу}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00313}00313\ \textcolor{comment}{\ \ *\ @param\ tag\ \ \ \ \ \ \ \ Базовый\ или\ конкретный\ идентификатор\ буфера.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00314}00314\ \textcolor{comment}{\ \ *\ @param\ Buffer\ \ \ \ \ Буфер\ назначения\ для\ копирования\ данных}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00315}00315\ \textcolor{comment}{\ \ *\ @param\ tail\_size\ \ Количество\ последних\ символов,\ которые\ нужно\ прочитать}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00316}00316\ \textcolor{comment}{\ \ *\ @param\ read\_size\ \ Количество\ считанных\ символов}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00317}00317\ \textcolor{comment}{\ \ *\ @return\ >=0\ —\ номер\ буфера\ (тег)\ для\ записи,\ <0\ —\ ошибка\ (тег\ не\ найден\ или\ структура\ повреждена)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00318}00318\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00319}00319\ \textcolor{comment}{\ \ *\ @details\ \ Копирует\ последние\ tail\_size\ символов\ из\ найденной\ записи\ Flash\ в\ Buffer.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00320}00320\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ Тег\ может\ быть\ базовым\ или\ конкретным:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00321}00321\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Если\ базовый\ (младший\ байт\ ==\ 0)\ —\ будет\ прочитана\ последняя\ запись\ из\ группы.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00322}00322\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Если\ конкретный\ (младший\ байт\ !=\ 0)\ —\ прочитывается\ именно\ эта\ запись.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00323}00323\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00324}\mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146}{00324}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146}{RTT\_ReadFromFlash}}(uint32\_t\ tag,\ \textcolor{keywordtype}{char}\ *Buffer,\ uint32\_t\ tail\_size,\ uint32\_t\ *read\_size)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00325}00325\ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00326}00326\ \ \ \textcolor{keywordflow}{if}\ (!Buffer\ ||\ tail\_size\ ==\ 0)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00327}00327\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Неверные\ параметры}} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00328}00328\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00329}00329\ \ \ \ \ \textcolor{keywordflow}{if}\ (flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ ==\ 0xFFFFFFFF)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00330}00330\ \ \ \ \ \ \ \textcolor{keywordflow}{break};\ \ \textcolor{comment}{//\ Достигнут\ конец\ записанных\ структур}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00329}00329\ \ \ \textcolor{keywordflow}{if}\ (tag\ ==\ 0xFFFFFFFF)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00330}00330\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Недопустимый\ тег}} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00331}00331\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00332}00332\ \ \ \ \ \textcolor{comment}{//\ выбраный\ тег}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00333}00333\ \ \ \ \ \textcolor{keywordflow}{if}((flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ \&\ 0xFFFFFF00)\ ==\ base\_tag)\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00334}00334\ \ \ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00335}00335\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ ((tag\ \&\ 0xFF)\ ==\ 0)\ \textcolor{comment}{//\ если\ он\ базовый\ -\/\ ищем\ последний\ \ \ \ \ \ \ \ \ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00336}00336\ \ \ \ \ \ \ \ \ target\_hdr\ =\ flash\_hdr;\ \ \textcolor{comment}{//\ сохраняем\ последний\ в\ группе}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00337}00337\ \ \ \ \ \ \ \textcolor{keywordflow}{else}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00338}00338\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}(flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ ==\ tag)\ \textcolor{comment}{//\ если\ он\ конкретный\ и\ найден\ -\/\ берем\ его}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00339}00339\ \ \ \ \ \ \ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00340}00340\ \ \ \ \ \ \ \ \ \ \ target\_hdr\ =\ flash\_hdr;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00341}00341\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{break};\ \ \textcolor{comment}{//\ конкретный\ тег\ найден}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00342}00342\ \ \ \ \ \ \ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00343}00343\ \ \ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00344}00344\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00345}00345\ \ \ \ \ addr\ +=\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00346}00346\ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00347}00347\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00348}00348\ \ \ \textcolor{keywordflow}{if}\ (!target\_hdr)\ \textcolor{keywordflow}{return}\ -\/1;\ \textcolor{comment}{//\ Тег\ не\ найден}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00349}00349\ \ \ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00350}00350\ \ \ \textcolor{comment}{//\ Проверка\ корректности\ размера}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00351}00351\ \ \ \textcolor{keywordflow}{if}\ (target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}}\ >\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}})} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00352}00352\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Повреждённая\ запись\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00353}00353\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00354}00354\ \ \ \textcolor{comment}{//\ Определяем\ количество\ читаемых\ символов}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00355}00355\ \ \ uint32\_t\ n\ =\ (tail\_size\ >\ target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}})\ ?\ target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}}\ :\ tail\_size;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00356}00356\ \ \ \textcolor{comment}{//\ Начальная\ позиция\ для\ чтения\ последних\ tail\_size\ символов}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00357}00357\ \ \ uint32\_t\ start\ =\ target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}}\ -\/\ n;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00358}00358\ \ \ \textcolor{comment}{//\ Копируем\ данные\ из\ Flash\ в\ RAM}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00359}00359\ \ \ memcpy(Buffer,\ \&target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}{data}}[start],\ n);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00360}00360\ \ \ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00361}00361\ \ \ \textcolor{keywordflow}{if}(read\_size\ !=\ NULL)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00362}00362\ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00363}00363\ \ \ \ \ *read\_size\ =\ n;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00364}00364\ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00365}00365\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00366}00366\ \ \ \_\_DSB();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00367}00367\ \ \ \_\_ISB();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00368}00368\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00369}00369\ \ \ \textcolor{keywordflow}{return}\ (\textcolor{keywordtype}{int})(target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ \&\ 0xFF);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00370}00370\ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00371}00371\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00372}00372\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00373}00373\ \textcolor{comment}{\ \ *\ @brief\ Стирание\ сектора\ Flash\ с\ RTT-\/буфером}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00374}00374\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00375}\mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1}{00375}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1}{RTT\_EraseFlash}}(\textcolor{keywordtype}{void})} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00376}00376\ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00377}00377\ \ \ FLASH\_EraseInitTypeDef\ eraseInit;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00378}00378\ \ \ uint32\_t\ pageError\ =\ 0;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00379}00379\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00380}00380\ \ \ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}{RTT\_FlashPrepare}}();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00332}00332\ \ \ uint32\_t\ addr\ =\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga8e56f75d3ab8a89ddde1404ae23c3297}{RTT\_FLASH\_SECTOR\_START}};} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00333}00333\ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *flash\_hdr\ =\ NULL;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00334}00334\ \ \ \mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *target\_hdr\ =\ NULL;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00335}00335\ \ \ uint32\_t\ base\_tag\ =\ tag\ \&\ 0xFFFFFF00;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00336}00336\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00337}00337\ \ \ \textcolor{comment}{//\ Поиск\ записи\ по\ тегу}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00338}00338\ \ \ \textcolor{keywordflow}{while}\ ((addr\ +\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}))\ <=\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafeca0be3688dea07ff443f894668003d}{RTT\_FLASH\_SECTOR\_END}})} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00339}00339\ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00340}00340\ \ \ \ \ flash\_hdr\ =\ (\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}}\ *)addr;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00341}00341\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00342}00342\ \ \ \ \ \textcolor{keywordflow}{if}\ (flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ ==\ 0xFFFFFFFF)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00343}00343\ \ \ \ \ \ \ \textcolor{keywordflow}{break};\ \ \textcolor{comment}{//\ Достигнут\ конец\ записанных\ структур}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00344}00344\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00345}00345\ \ \ \ \ \textcolor{comment}{//\ выбраный\ тег}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00346}00346\ \ \ \ \ \textcolor{keywordflow}{if}((flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ \&\ 0xFFFFFF00)\ ==\ base\_tag)\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00347}00347\ \ \ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00348}00348\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ ((tag\ \&\ 0xFF)\ ==\ 0)\ \textcolor{comment}{//\ если\ он\ базовый\ -\/\ ищем\ последний\ \ \ \ \ \ \ \ \ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00349}00349\ \ \ \ \ \ \ \ \ target\_hdr\ =\ flash\_hdr;\ \ \textcolor{comment}{//\ сохраняем\ последний\ в\ группе}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00350}00350\ \ \ \ \ \ \ \textcolor{keywordflow}{else}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00351}00351\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{if}(flash\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ ==\ tag)\ \textcolor{comment}{//\ если\ он\ конкретный\ и\ найден\ -\/\ берем\ его}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00352}00352\ \ \ \ \ \ \ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00353}00353\ \ \ \ \ \ \ \ \ \ \ target\_hdr\ =\ flash\_hdr;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00354}00354\ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{break};\ \ \textcolor{comment}{//\ конкретный\ тег\ найден}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00355}00355\ \ \ \ \ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00356}00356\ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00357}00357\ \ \ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00358}00358\ \ \ \ \ addr\ +=\ \textcolor{keyword}{sizeof}(\mbox{\hyperlink{struct_r_t_t___flash_header__t}{RTT\_FlashHeader\_t}});} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00359}00359\ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00360}00360\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00361}00361\ \ \ \textcolor{keywordflow}{if}\ (!target\_hdr)\ \textcolor{keywordflow}{return}\ -\/1;\ \textcolor{comment}{//\ Тег\ не\ найден}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00362}00362\ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00363}00363\ \ \ \textcolor{comment}{//\ Проверка\ корректности\ размера}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00364}00364\ \ \ \textcolor{keywordflow}{if}\ (target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}}\ >\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}})} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00365}00365\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;\ \ \textcolor{comment}{//\ Повреждённая\ запись\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00366}00366\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00367}00367\ \ \ \textcolor{comment}{//\ Определяем\ количество\ читаемых\ символов}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00368}00368\ \ \ uint32\_t\ n\ =\ (tail\_size\ >\ target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}})\ ?\ target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}}\ :\ tail\_size;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00369}00369\ \ \ \textcolor{comment}{//\ Начальная\ позиция\ для\ чтения\ последних\ tail\_size\ символов}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00370}00370\ \ \ uint32\_t\ start\ =\ target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_afd1a5c51af6f97d170c2ccbbe3e34699}{size}}\ -\/\ n;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00371}00371\ \ \ \textcolor{comment}{//\ Копируем\ данные\ из\ Flash\ в\ RAM}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00372}00372\ \ \ memcpy(Buffer,\ \&target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_ae7276198385c8d6f6508f433d042d52a}{data}}[start],\ n);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00373}00373\ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00374}00374\ \ \ \textcolor{keywordflow}{if}(read\_size\ !=\ NULL)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00375}00375\ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00376}00376\ \ \ \ \ *read\_size\ =\ n;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00377}00377\ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00378}00378\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00379}00379\ \ \ \_\_DSB();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00380}00380\ \ \ \_\_ISB();} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00381}00381\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00382}00382\ \ \ eraseInit.TypeErase\ \ \ =\ FLASH\_TYPEERASE\_SECTORS;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00383}00383\ \ \ eraseInit.Sector\ \ \ \ \ \ =\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga3bc1b76864e1d32cbdd174d4caae7724}{RTT\_FLASH\_SECTOR}};} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00384}00384\ \ \ eraseInit.NbSectors\ \ \ =\ 1;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00385}00385\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00386}00386\ \ \ \textcolor{keywordflow}{if}\ (HAL\_FLASHEx\_Erase(\&eraseInit,\ \&pageError)\ !=\ HAL\_OK)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00387}00387\ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00388}00388\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00389}00389\ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00390}00390\ \ \ \textcolor{keywordflow}{return}\ 0;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00391}00391\ \ \ HAL\_FLASH\_Lock();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00392}00392\ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00393}00393\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00394}00394\ \textcolor{comment}{/**\ TRACE\_RTT\_FLASH}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00395}00395\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00396}00396\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00397}00397\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00398}00398\ \textcolor{preprocessor}{\#else\ }\textcolor{comment}{//\ HAL\_MODULE\_ENABLED\ \&\&\ RTT\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00399}00399\ \textcolor{preprocessor}{\#define\ RTT\_FlashPrepare(...)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00400}00400\ \textcolor{preprocessor}{\#define\ RTT\_EraseFlash(...)\ \ \ \ 0}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00401}00401\ \textcolor{preprocessor}{\#define\ RTT\_SaveToFlash(...)\ \ \ 0}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00402}00402\ \textcolor{preprocessor}{\#define\ RTT\_ReadFromFlash(...)\ 0}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00403}00403\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ HAL\_MODULE\_ENABLED\ \&\&\ RTT\_TRACE\_ENABLE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00404}00404\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00405}00405\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00406}00406\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00407}00407\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00408}00408\ \textcolor{comment}{/**\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00409}00409\ \textcolor{comment}{\ \ *\ @addtogroup\ \ TRACE\_HARDFAULT\ \ \ \ Hardfault\ trace\ defines}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00410}00410\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ \ TRACE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00411}00411\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ \ Модуль\ трассировки\ HardFault\ с\ возможностью\ сохранения\ RTT\ буфера\ во\ Flash}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00412}00412\ \textcolor{comment}{\ \ *\ @details}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00413}00413\ \textcolor{comment}{\ \ *\ Этот\ модуль\ позволяет\ сохранять\ контекст\ процессора\ и\ последние\ символы\ RTT\ буфера\ при\ возникновении\ HardFault.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00414}00414\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00415}00415\ \textcolor{comment}{\ \ *\ Механизм\ работы:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00416}00416\ \textcolor{comment}{\ \ *\ \ \ -\/\ При\ срабатывании\ HardFault\ вызывается\ HF\_HandleFault(),\ который:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00417}00417\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 1.\ Получает\ указатель\ на\ стек,\ где\ произошёл\ HardFault\ (MSP\ или\ PSP).}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00418}00418\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 2.\ Выводит\ значения\ регистров\ R0-\/R3,\ R12,\ LR,\ PC,\ PSR\ и\ системных\ регистров\ SCB.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00419}00419\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 3.\ Формирует\ строку\ с\ регистрами\ и\ копирует\ последние\ символы\ RTT\ буфера.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00420}00420\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 4.\ Сохраняет\ данные\ во\ Flash\ с\ базовым\ тегом\ HF\_RTT\_TAG\_BASE.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00421}00421\ \textcolor{comment}{\ \ *\ \ \ -\/\ Для\ восстановления\ последнего\ HardFault\ используется\ HF\_CheckRecovered(),\ который:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00422}00422\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 1.\ Читает\ запись\ во\ Flash\ по\ базовому\ тегу.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00423}00423\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 2.\ Выводит\ сохранённый\ RTT\ буфер\ и\ контекст\ регистров.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00424}00424\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 3.\ Опционально\ стирает\ Flash\ после\ восстановления.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00425}00425\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00426}00426\ \textcolor{comment}{\ \ *\ Параметры:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00427}00427\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HARDFAULT\_SERIAL\_TRACE\ \ \ -\/\ Включить\ обработку\ и\ serial\ трассировку\ Hardfault}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00428}00428\ \textcolor{comment}{\ \ *\ \ \ Если\ отключена\ то\ вставляются\ заглушки,\ никак\ не\ влияющие\ на\ параметры\ и\ остальную\ программу}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00429}00429\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_RTT\_TAG\_BASE\ \ \ \ \ \ \ \ \ \ -\/\ Базовый\ тег\ RTT\ Flash\ для\ HardFault\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00430}00430\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_RTT\_TAIL\_SIZE\ \ \ \ \ \ \ \ \ -\/\ Размер\ буфера\ RTT,\ который\ сохранится\ при\ Hardfault}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00431}00431\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_STACK\_DUMP\_WORDS\ \ \ \ \ \ -\/\ Сколько\ слов\ стека\ будет\ проанализировано\ во\ время\ Hardfault}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00432}00432\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_FLASH\_ADDR\ \ \ \ \ \ \ \ \ \ \ \ -\/\ Адрес\ FLASH\ куда\ положится\ RTT\ буфер}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00433}00433\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_RAM\_END\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Конец\ RAM\ памяти\ (чтобы\ во\ время\ анализа\ стека\ не\ выйти\ за\ пределы)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00434}00434\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00435}00435\ \textcolor{comment}{\ \ @code}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00436}00436\ \textcolor{comment}{\ \ void\ Hardfault()}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00437}00437\ \textcolor{comment}{\ \ \{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00438}00438\ \textcolor{comment}{\ \ \ \ HF\_HandleFault();}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00439}00439\ \textcolor{comment}{\ \ \ \ NVIC\_SystemReset();}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00440}00440\ \textcolor{comment}{\ \ \}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00441}00441\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00442}00442\ \textcolor{comment}{\ \ int\ main()}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00443}00443\ \textcolor{comment}{\ \ \{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00444}00444\ \textcolor{comment}{\ \ \ \ if(HF\_CheckRecovered(0))}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00445}00445\ \textcolor{comment}{\ \ \ \ \{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00446}00446\ \textcolor{comment}{\ \ \ \ \ \ //set\ hardfault\ error}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00447}00447\ \textcolor{comment}{\ \ \ \ \ \ RTT\_EraseFlash();\ //\ erase\ rtt\ flash\ after\ message\ readed}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00448}00448\ \textcolor{comment}{\ \ \ \ \}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00449}00449\ \textcolor{comment}{\ \ \}\ \ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00450}00450\ \textcolor{comment}{\ \ @endcode}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00451}00451\ \textcolor{comment}{\ \ *\ @\{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00452}00452\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00453}00453\ \textcolor{preprocessor}{\#if\ defined(HAL\_MODULE\_ENABLED)\ \&\&\ defined(HARDFAULT\_SERIAL\_TRACE)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00454}00454\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00455}00455\ \textcolor{preprocessor}{\#ifndef\ HF\_RTT\_TAIL\_SIZE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00456}00456\ \textcolor{preprocessor}{\#define\ HF\_RTT\_TAIL\_SIZE\ \ RTT\_FLASH\_BUFFER\_SIZE\ }\textcolor{comment}{///<\ Размер\ буфера\ RTT,\ который\ сохранится\ при\ Hardfault}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00457}00457\ \textcolor{preprocessor}{\#endif}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00458}00458\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00459}00459\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00460}00460\ \textcolor{comment}{\ \ *\ @brief\ Контекст\ стек-\/фрейма\ процессора\ при\ HardFault}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00461}00461\ \textcolor{comment}{\ \ *\ @details\ Сохраняет\ регистры\ R0-\/R3,\ R12,\ LR,\ PC,\ PSR\ для\ последующего\ анализа.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00462}00462\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00463}\mbox{\hyperlink{struct_h_f___stack_frame__t}{00463}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00464}\mbox{\hyperlink{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413}{00464}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413}{r0}};\ \ \ \textcolor{comment}{///<\ Регистр\ R0}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00465}\mbox{\hyperlink{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea}{00465}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea}{r1}};\ \ \ \textcolor{comment}{///<\ Регистр\ R1}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00466}\mbox{\hyperlink{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b}{00466}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b}{r2}};\ \ \ \textcolor{comment}{///<\ Регистр\ R2}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00467}\mbox{\hyperlink{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3}{00467}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3}{r3}};\ \ \ \textcolor{comment}{///<\ Регистр\ R3}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00468}\mbox{\hyperlink{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b}{00468}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b}{r12}};\ \ \textcolor{comment}{///<\ Регистр\ R12}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00469}\mbox{\hyperlink{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577}{00469}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577}{lr}};\ \ \ \textcolor{comment}{///<\ Link\ Register}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00470}\mbox{\hyperlink{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732}{00470}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732}{pc}};\ \ \ \textcolor{comment}{///<\ Program\ Counter}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00471}\mbox{\hyperlink{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9}{00471}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9}{psr}};\ \ \textcolor{comment}{///<\ Program\ Status\ Register}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00472}00472\ \}\ \mbox{\hyperlink{struct_h_f___stack_frame__t}{HF\_StackFrame\_t}};} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00473}00473\ \textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00474}00474\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00475}00475\ \textcolor{comment}{\ \ *\ @brief\ Проверка\ и\ вывод\ последнего\ HardFault-\/трейса\ из\ Flash}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00476}00476\ \textcolor{comment}{\ \ *\ @details}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00477}00477\ \textcolor{comment}{\ \ *\ Функция\ ищет\ последнюю\ запись\ HardFault\ по\ базовому\ тегу\ HF\_RTT\_TAG\_BASE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00478}00478\ \textcolor{comment}{\ \ *\ и\ выводит\ её\ содержимое\ в\ консоль.\ После\ успешного\ вывода\ Flash\ можно\ опционально\ очистить.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00479}00479\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00480}00480\ \textcolor{comment}{\ \ *\ @return\ int}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00481}00481\ \textcolor{comment}{\ \ *\ \ \ -\/\ 1\ —\ данные\ HardFault\ найдены\ и\ выведены}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00482}00482\ \textcolor{comment}{\ \ *\ \ \ -\/\ 0\ —\ данные\ отсутствуют\ или\ тег\ не\ найден}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00483}00483\ \textcolor{comment}{\ \ *\ }} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00484}00484\ \textcolor{comment}{\ \ *\ @note\ Вызов\ рекомендуется\ при\ инициализации\ приложения\ для\ анализа\ предыдущего\ сбоя.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00485}00485\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00486}\mbox{\hyperlink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_ga03f8b6f3b537ee1c8e91065c60db504f}{00486}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_ga03f8b6f3b537ee1c8e91065c60db504f}{HF\_CheckRecovered}}(\textcolor{keywordtype}{int}\ erase)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00487}00487\ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00488}00488\ \ \ \textcolor{keywordtype}{char}\ buffer[\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}}];} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00489}00489\ \ \ uint32\_t\ read\_size\ =\ 0;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00490}00490\ \ \ \textcolor{keywordtype}{int}\ n\_hardfault\ =\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146}{RTT\_ReadFromFlash}}(\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gadc960255719c7eff4bdfaa850be9b313}{HF\_RTT\_TAG\_BASE}},\ buffer,\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafcc7ea03d4df8f1909e580b519a7f3ca}{HF\_RTT\_TAIL\_SIZE}},\ \&read\_size);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00491}00491\ \ \ \textcolor{keywordflow}{if}\ (n\_hardfault\ >\ 0)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00492}00492\ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00493}00493\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\(\backslash\)n-\/-\/-\/\ Recovered\ HardFault\ RTT\ buffer\ \#\%u\ -\/-\/-\/\(\backslash\)n"{}},\ n\_hardfault);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00494}00494\ \ \ \ \ \textcolor{keywordflow}{for}\ (\textcolor{keywordtype}{int}\ i\ =\ 0;\ i\ <\ read\_size;\ i++)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00495}00495\ \ \ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00496}00496\ \ \ \ \ \ \ \textcolor{keywordtype}{char}\ c\ =\ buffer[i];} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00497}00497\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (c\ ==\ 0\ ||\ c\ ==\ (\textcolor{keywordtype}{char})0xFF)\ \textcolor{keywordflow}{break};} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00498}00498\ \ \ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\%c"{}},\ c);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00499}00499\ \ \ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00500}00500\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00501}00501\ \ \ \ \ \textcolor{keywordflow}{if}(erase)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00502}00502\ \ \ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1}{RTT\_EraseFlash}}();} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00503}00503\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\(\backslash\)n-\/-\/-\/-\/-\/-\/-\/-\/-\/\ HardFault\ Dump\ End\ -\/-\/-\/-\/-\/-\/-\/-\/-\/\(\backslash\)n"{}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00504}00504\ \ \ \ \ \textcolor{keywordflow}{return}\ 1;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00505}00505\ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00506}00506\ \ \ \textcolor{keywordflow}{return}\ 0;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00507}00507\ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00508}00508\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00509}00509\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00510}00510\ \textcolor{keyword}{static}\ \mbox{\hyperlink{struct_h_f___stack_frame__t}{HF\_StackFrame\_t}}\ *stack\_frame;} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00511}00511\ \textcolor{keyword}{static}\ uint32\_t\ stack\_dump[\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gaa31234688b333a505aaa57b8ecdedf5b}{HF\_STACK\_DUMP\_WORDS}}];} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00512}00512\ \textcolor{keyword}{static}\ \textcolor{keywordtype}{void}\ *ret\_adr[10]\ =\ \{0\};\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00513}00513\ \textcolor{comment}{/**}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00514}00514\ \textcolor{comment}{\ \ *\ @brief\ Обработчик\ HardFault}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00515}00515\ \textcolor{comment}{\ \ *\ @details}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00516}00516\ \textcolor{comment}{\ \ *\ Вызывается\ из\ прерывания\ HardFault\ или\ в\ любом\ месте\ где\ понятно\ что\ ошибка\ критическая.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00517}00517\ \textcolor{comment}{\ \ *\ Последовательно\ выполняет:}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00518}00518\ \textcolor{comment}{\ \ *\ \ \ 1.\ Определяет\ активный\ стек\ (MSP\ или\ PSP)\ на\ момент\ сбоя.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00519}00519\ \textcolor{comment}{\ \ *\ \ \ 2.\ Сохраняет\ значения\ регистров\ R0-\/R3,\ R12,\ LR,\ PC,\ PSR.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00520}00520\ \textcolor{comment}{\ \ *\ \ \ 3.\ Выводит\ системные\ регистры\ CFSR,\ HFSR,\ DFSR,\ AFSR,\ MMFAR,\ BFAR.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00521}00521\ \textcolor{comment}{\ \ *\ \ \ 4.\ Формирует\ stack\ trace\ с\ 3\ уровнями\ возврата.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00522}00522\ \textcolor{comment}{\ \ *\ \ \ 5.\ Копирует\ последние\ символы\ RTT\ буфера.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00523}00523\ \textcolor{comment}{\ \ *\ \ \ 6.\ Сохраняет\ все\ данные\ во\ Flash\ через\ RTT\_SaveToFlash\ с\ базовым\ тегом\ HF\_RTT\_TAG\_BASE.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00524}00524\ \textcolor{comment}{\ \ *}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00525}00525\ \textcolor{comment}{\ \ *\ @note\ Функция\ защищена,\ так\ как\ вызывается\ в\ контексте\ сбоя\ —\ минимизирует\ использование\ вызовов\ HAL.}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00526}00526\ \textcolor{comment}{\ \ */}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00527}\mbox{\hyperlink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_gadd8e10e7ec3b0204f7f92062ecd452f7}{00527}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_gadd8e10e7ec3b0204f7f92062ecd452f7}{HF\_HandleFault}}(\textcolor{keywordtype}{void})} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00528}00528\ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00529}00529\ \ \ \ \ \textcolor{comment}{//\ Получаем\ указатель\ на\ стек,\ где\ произошёл\ HardFault}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00530}00530\ \ \ \ \ \_\_ASM\ \textcolor{keyword}{volatile}(} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00531}00531\ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}TST\ lr,\ \#4\ \ \ \ \ \ \ \(\backslash\)n"{}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00532}00532\ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}ITE\ EQ\ \ \ \ \ \ \ \ \ \ \ \(\backslash\)n"{}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00533}00533\ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}MRSEQ\ \%[ptr],\ MSP\(\backslash\)n"{}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00534}00534\ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}MRSNE\ \%[ptr],\ PSP\(\backslash\)n"{}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00535}00535\ \ \ \ \ \ \ \ \ :\ [ptr]\ \textcolor{stringliteral}{"{}=r"{}}(stack\_frame)} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00536}00536\ \ \ \ \ );} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00537}00537\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00538}00538\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\(\backslash\)n=====\ HardFault\ occurred!\ =====\(\backslash\)n"{}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00539}00539\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R0\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>\mbox{\hyperlink{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413}{r0}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00540}00540\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R1\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>\mbox{\hyperlink{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea}{r1}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00541}00541\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R2\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>\mbox{\hyperlink{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b}{r2}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00542}00542\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R3\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>\mbox{\hyperlink{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3}{r3}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00543}00543\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R12\ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>\mbox{\hyperlink{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b}{r12}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00544}00544\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}LR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>\mbox{\hyperlink{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577}{lr}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00545}00545\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}PC\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>\mbox{\hyperlink{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732}{pc}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00546}00546\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}PSR\ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>\mbox{\hyperlink{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9}{psr}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00547}00547\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00548}00548\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}CFSR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>CFSR);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00549}00549\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}HFSR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>HFSR);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00550}00550\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}DFSR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>DFSR);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00551}00551\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}AFSR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>AFSR);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00552}00552\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}MMFAR\ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>MMFAR);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00553}00553\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}BFAR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>BFAR);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00554}00554\ \ \ \ \ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00555}00555\ \ \ \ \ \textcolor{comment}{//\ -\/-\/-\/\ Stack\ trace\ -\/-\/-\/}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00556}00556\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}-\/-\/-\/\ Stack\ trace\ -\/-\/-\/\(\backslash\)n"{}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00557}00557\ \ \ \ \ ret\_adr[0]\ =\ \_\_builtin\_return\_address(0);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00558}00558\ \ \ \ \ ret\_adr[1]\ =\ \_\_builtin\_return\_address(1);} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00559}00559\ \ \ \ \ ret\_adr[2]\ =\ \_\_builtin\_return\_address(2);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00382}00382\ \ \ \textcolor{keywordflow}{return}\ (\textcolor{keywordtype}{int})(target\_hdr-\/>\mbox{\hyperlink{struct_r_t_t___flash_header__t_a844ee5470a323a749856cbb7a682dc57}{tag}}\ \&\ 0xFF);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00383}00383\ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00384}00384\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00385}00385\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00386}00386\ \textcolor{comment}{\ \ *\ @brief\ Стирание\ сектора\ Flash\ с\ RTT-\/буфером}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00387}00387\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00388}\mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1}{00388}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1}{RTT\_EraseFlash}}(\textcolor{keywordtype}{void})} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00389}00389\ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00390}00390\ \ \ FLASH\_EraseInitTypeDef\ eraseInit;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00391}00391\ \ \ uint32\_t\ pageError\ =\ 0;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00392}00392\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00393}00393\ \ \ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga21353cb4f5af666237739e62ce019cd6}{RTT\_FlashPrepare}}();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00394}00394\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00395}00395\ \ \ eraseInit.TypeErase\ \ \ =\ FLASH\_TYPEERASE\_SECTORS;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00396}00396\ \ \ eraseInit.Sector\ \ \ \ \ \ =\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga3bc1b76864e1d32cbdd174d4caae7724}{RTT\_FLASH\_SECTOR}};} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00397}00397\ \ \ eraseInit.NbSectors\ \ \ =\ 1;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00398}00398\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00399}00399\ \ \ \textcolor{keywordflow}{if}\ (HAL\_FLASHEx\_Erase(\&eraseInit,\ \&pageError)\ !=\ HAL\_OK)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00400}00400\ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00401}00401\ \ \ \ \ \textcolor{keywordflow}{return}\ -\/1;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00402}00402\ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00403}00403\ \ \ \textcolor{keywordflow}{return}\ 0;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00404}00404\ \ \ HAL\_FLASH\_Lock();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00405}00405\ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00406}00406\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00407}00407\ \textcolor{comment}{/**\ TRACE\_RTT\_FLASH}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00408}00408\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00409}00409\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00410}00410\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00411}00411\ \textcolor{preprocessor}{\#else\ }\textcolor{comment}{//\ HAL\_MODULE\_ENABLED\ \&\&\ RTT\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00412}00412\ \textcolor{preprocessor}{\#define\ RTT\_FlashPrepare(...)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00413}00413\ \textcolor{preprocessor}{\#define\ RTT\_EraseFlash(...)\ \ \ \ 0}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00414}00414\ \textcolor{preprocessor}{\#define\ RTT\_SaveToFlash(...)\ \ \ 0}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00415}00415\ \textcolor{preprocessor}{\#define\ RTT\_ReadFromFlash(...)\ 0}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00416}00416\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ HAL\_MODULE\_ENABLED\ \&\&\ RTT\_TRACE\_ENABLE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00417}00417\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00418}00418\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00419}00419\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00420}00420\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00421}00421\ \textcolor{comment}{/**\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00422}00422\ \textcolor{comment}{\ \ *\ @addtogroup\ \ TRACE\_HARDFAULT\ \ \ \ Hardfault\ trace\ defines}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00423}00423\ \textcolor{comment}{\ \ *\ @ingroup\ \ \ \ \ TRACE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00424}00424\ \textcolor{comment}{\ \ *\ @brief\ \ \ \ \ \ \ Модуль\ трассировки\ HardFault\ с\ возможностью\ сохранения\ RTT\ буфера\ во\ Flash}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00425}00425\ \textcolor{comment}{\ \ *\ @details}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00426}00426\ \textcolor{comment}{\ \ *\ Этот\ модуль\ позволяет\ сохранять\ контекст\ процессора\ и\ последние\ символы\ RTT\ буфера\ при\ возникновении\ HardFault.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00427}00427\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00428}00428\ \textcolor{comment}{\ \ *\ Механизм\ работы:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00429}00429\ \textcolor{comment}{\ \ *\ \ \ -\/\ При\ срабатывании\ HardFault\ вызывается\ HF\_HandleFault(),\ который:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00430}00430\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 1.\ Получает\ указатель\ на\ стек,\ где\ произошёл\ HardFault\ (MSP\ или\ PSP).}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00431}00431\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 2.\ Выводит\ значения\ регистров\ R0-\/R3,\ R12,\ LR,\ PC,\ PSR\ и\ системных\ регистров\ SCB.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00432}00432\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 3.\ Формирует\ строку\ с\ регистрами\ и\ копирует\ последние\ символы\ RTT\ буфера.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00433}00433\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 4.\ Сохраняет\ данные\ во\ Flash\ с\ базовым\ тегом\ HF\_RTT\_TAG\_BASE.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00434}00434\ \textcolor{comment}{\ \ *\ \ \ -\/\ Для\ восстановления\ последнего\ HardFault\ используется\ HF\_CheckRecovered(),\ который:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00435}00435\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 1.\ Читает\ запись\ во\ Flash\ по\ базовому\ тегу.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00436}00436\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 2.\ Выводит\ сохранённый\ RTT\ буфер\ и\ контекст\ регистров.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00437}00437\ \textcolor{comment}{\ \ *\ \ \ \ \ \ \ 3.\ Опционально\ стирает\ Flash\ после\ восстановления.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00438}00438\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00439}00439\ \textcolor{comment}{\ \ *\ Параметры:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00440}00440\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HARDFAULT\_SERIAL\_TRACE\ \ \ -\/\ Включить\ обработку\ и\ serial\ трассировку\ Hardfault}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00441}00441\ \textcolor{comment}{\ \ *\ \ \ Если\ отключена\ то\ вставляются\ заглушки,\ никак\ не\ влияющие\ на\ параметры\ и\ остальную\ программу}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00442}00442\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_RTT\_TAG\_BASE\ \ \ \ \ \ \ \ \ \ -\/\ Базовый\ тег\ RTT\ Flash\ для\ HardFault\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00443}00443\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_RTT\_TAIL\_SIZE\ \ \ \ \ \ \ \ \ -\/\ Размер\ буфера\ RTT,\ который\ сохранится\ при\ Hardfault}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00444}00444\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_STACK\_DUMP\_WORDS\ \ \ \ \ \ -\/\ Сколько\ слов\ стека\ будет\ проанализировано\ во\ время\ Hardfault}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00445}00445\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_FLASH\_ADDR\ \ \ \ \ \ \ \ \ \ \ \ -\/\ Адрес\ FLASH\ куда\ положится\ RTT\ буфер}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00446}00446\ \textcolor{comment}{\ \ *\ -\/\ @ref\ HF\_RAM\_END\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ -\/\ Конец\ RAM\ памяти\ (чтобы\ во\ время\ анализа\ стека\ не\ выйти\ за\ пределы)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00447}00447\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00448}00448\ \textcolor{comment}{\ \ @code}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00449}00449\ \textcolor{comment}{\ \ void\ Hardfault()}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00450}00450\ \textcolor{comment}{\ \ \{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00451}00451\ \textcolor{comment}{\ \ \ \ HF\_HandleFault();}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00452}00452\ \textcolor{comment}{\ \ \ \ NVIC\_SystemReset();}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00453}00453\ \textcolor{comment}{\ \ \}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00454}00454\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00455}00455\ \textcolor{comment}{\ \ int\ main()}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00456}00456\ \textcolor{comment}{\ \ \{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00457}00457\ \textcolor{comment}{\ \ \ \ if(HF\_CheckRecovered(0))}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00458}00458\ \textcolor{comment}{\ \ \ \ \{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00459}00459\ \textcolor{comment}{\ \ \ \ \ \ //set\ hardfault\ error}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00460}00460\ \textcolor{comment}{\ \ \ \ \ \ RTT\_EraseFlash();\ //\ erase\ rtt\ flash\ after\ message\ readed}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00461}00461\ \textcolor{comment}{\ \ \ \ \}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00462}00462\ \textcolor{comment}{\ \ \}\ \ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00463}00463\ \textcolor{comment}{\ \ @endcode}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00464}00464\ \textcolor{comment}{\ \ *\ @\{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00465}00465\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00466}00466\ \textcolor{preprocessor}{\#if\ defined(HAL\_MODULE\_ENABLED)\ \&\&\ defined(HARDFAULT\_SERIAL\_TRACE)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00467}00467\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00468}00468\ \textcolor{preprocessor}{\#ifndef\ HF\_RTT\_TAIL\_SIZE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00469}00469\ \textcolor{preprocessor}{\#define\ HF\_RTT\_TAIL\_SIZE\ \ RTT\_FLASH\_BUFFER\_SIZE\ }\textcolor{comment}{///<\ Размер\ буфера\ RTT,\ который\ сохранится\ при\ Hardfault}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00470}00470\ \textcolor{preprocessor}{\#endif}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00471}00471\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00472}00472\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00473}00473\ \textcolor{comment}{\ \ *\ @brief\ Контекст\ стек-\/фрейма\ процессора\ при\ HardFault}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00474}00474\ \textcolor{comment}{\ \ *\ @details\ Сохраняет\ регистры\ R0-\/R3,\ R12,\ LR,\ PC,\ PSR\ для\ последующего\ анализа.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00475}00475\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00476}\mbox{\hyperlink{struct_h_f___stack_frame__t}{00476}}\ \textcolor{keyword}{typedef}\ \textcolor{keyword}{struct\ }\{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00477}\mbox{\hyperlink{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413}{00477}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a4146ed28926b5f234132b7112119a413}{r0}};\ \ \ \textcolor{comment}{///<\ Регистр\ R0}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00478}\mbox{\hyperlink{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea}{00478}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a286104d19185714940645a9df814ddea}{r1}};\ \ \ \textcolor{comment}{///<\ Регистр\ R1}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00479}\mbox{\hyperlink{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b}{00479}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a5a52e5006dabcf68c0fa4cfb0e03335b}{r2}};\ \ \ \textcolor{comment}{///<\ Регистр\ R2}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00480}\mbox{\hyperlink{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3}{00480}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a453c7af42b6928a693af422e17c981d3}{r3}};\ \ \ \textcolor{comment}{///<\ Регистр\ R3}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00481}\mbox{\hyperlink{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b}{00481}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a819ee3bc518c460ece1b7c4079f8f80b}{r12}};\ \ \textcolor{comment}{///<\ Регистр\ R12}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00482}\mbox{\hyperlink{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577}{00482}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a6e51904297f7725e96d5b5fb291ef577}{lr}};\ \ \ \textcolor{comment}{///<\ Link\ Register}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00483}\mbox{\hyperlink{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732}{00483}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_a16563896004751c90e41c81ae4570732}{pc}};\ \ \ \textcolor{comment}{///<\ Program\ Counter}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00484}\mbox{\hyperlink{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9}{00484}}\ \ \ uint32\_t\ \mbox{\hyperlink{struct_h_f___stack_frame__t_ae47cb051ee3c94471bfd4fe7e49c55f9}{psr}};\ \ \textcolor{comment}{///<\ Program\ Status\ Register}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00485}00485\ \}\ \mbox{\hyperlink{struct_h_f___stack_frame__t}{HF\_StackFrame\_t}};} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00486}00486\ \textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00487}00487\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00488}00488\ \textcolor{comment}{\ \ *\ @brief\ Проверка\ и\ вывод\ последнего\ HardFault-\/трейса\ из\ Flash}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00489}00489\ \textcolor{comment}{\ \ *\ @details}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00490}00490\ \textcolor{comment}{\ \ *\ Функция\ ищет\ последнюю\ запись\ HardFault\ по\ базовому\ тегу\ HF\_RTT\_TAG\_BASE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00491}00491\ \textcolor{comment}{\ \ *\ и\ выводит\ её\ содержимое\ в\ консоль.\ После\ успешного\ вывода\ Flash\ можно\ опционально\ очистить.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00492}00492\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00493}00493\ \textcolor{comment}{\ \ *\ @return\ int}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00494}00494\ \textcolor{comment}{\ \ *\ \ \ -\/\ 1\ —\ данные\ HardFault\ найдены\ и\ выведены}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00495}00495\ \textcolor{comment}{\ \ *\ \ \ -\/\ 0\ —\ данные\ отсутствуют\ или\ тег\ не\ найден}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00496}00496\ \textcolor{comment}{\ \ *\ }} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00497}00497\ \textcolor{comment}{\ \ *\ @note\ Вызов\ рекомендуется\ при\ инициализации\ приложения\ для\ анализа\ предыдущего\ сбоя.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00498}00498\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00499}\mbox{\hyperlink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_ga03f8b6f3b537ee1c8e91065c60db504f}{00499}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{int}\ \mbox{\hyperlink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_ga03f8b6f3b537ee1c8e91065c60db504f}{HF\_CheckRecovered}}(\textcolor{keywordtype}{int}\ erase)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00500}00500\ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00501}00501\ \ \ \textcolor{keywordtype}{char}\ buffer[\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_ga501312b24e322de4dd6755ad442f0ba3}{RTT\_FLASH\_BUFFER\_SIZE}}];} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00502}00502\ \ \ uint32\_t\ read\_size\ =\ 0;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00503}00503\ \ \ \textcolor{keywordtype}{int}\ n\_hardfault\ =\ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga734b2ebbf0c77699b739013878cfd146}{RTT\_ReadFromFlash}}(\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gadc960255719c7eff4bdfaa850be9b313}{HF\_RTT\_TAG\_BASE}},\ buffer,\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafcc7ea03d4df8f1909e580b519a7f3ca}{HF\_RTT\_TAIL\_SIZE}},\ \&read\_size);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00504}00504\ \ \ \textcolor{keywordflow}{if}\ (n\_hardfault\ >\ 0)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00505}00505\ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00506}00506\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\(\backslash\)n-\/-\/-\/\ Recovered\ HardFault\ RTT\ buffer\ \#\%u\ -\/-\/-\/\(\backslash\)n"{}},\ n\_hardfault);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00507}00507\ \ \ \ \ \textcolor{keywordflow}{for}\ (\textcolor{keywordtype}{int}\ i\ =\ 0;\ i\ <\ read\_size;\ i++)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00508}00508\ \ \ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00509}00509\ \ \ \ \ \ \ \textcolor{keywordtype}{char}\ c\ =\ buffer[i];} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00510}00510\ \ \ \ \ \ \ \textcolor{keywordflow}{if}\ (c\ ==\ 0\ ||\ c\ ==\ (\textcolor{keywordtype}{char})0xFF)\ \textcolor{keywordflow}{break};} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00511}00511\ \ \ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\%c"{}},\ c);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00512}00512\ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00513}00513\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00514}00514\ \ \ \ \ \textcolor{keywordflow}{if}(erase)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00515}00515\ \ \ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga8d8c6850e32b42871faefce3352012d1}{RTT\_EraseFlash}}();} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00516}00516\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\(\backslash\)n-\/-\/-\/-\/-\/-\/-\/-\/-\/\ HardFault\ Dump\ End\ -\/-\/-\/-\/-\/-\/-\/-\/-\/\(\backslash\)n"{}});} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00517}00517\ \ \ \ \ \textcolor{keywordflow}{return}\ 1;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00518}00518\ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00519}00519\ \ \ \textcolor{keywordflow}{return}\ 0;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00520}00520\ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00521}00521\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00522}00522\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00523}00523\ \textcolor{keyword}{static}\ \mbox{\hyperlink{struct_h_f___stack_frame__t}{HF\_StackFrame\_t}}\ *stack\_frame;} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00524}00524\ \textcolor{keyword}{static}\ uint32\_t\ stack\_dump[\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gaa31234688b333a505aaa57b8ecdedf5b}{HF\_STACK\_DUMP\_WORDS}}];} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00525}00525\ \textcolor{keyword}{static}\ \textcolor{keywordtype}{void}\ *ret\_adr[10]\ =\ \{0\};\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00526}00526\ \textcolor{comment}{/**}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00527}00527\ \textcolor{comment}{\ \ *\ @brief\ Обработчик\ HardFault}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00528}00528\ \textcolor{comment}{\ \ *\ @details}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00529}00529\ \textcolor{comment}{\ \ *\ Вызывается\ из\ прерывания\ HardFault\ или\ в\ любом\ месте\ где\ понятно\ что\ ошибка\ критическая.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00530}00530\ \textcolor{comment}{\ \ *\ Последовательно\ выполняет:}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00531}00531\ \textcolor{comment}{\ \ *\ \ \ 1.\ Определяет\ активный\ стек\ (MSP\ или\ PSP)\ на\ момент\ сбоя.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00532}00532\ \textcolor{comment}{\ \ *\ \ \ 2.\ Сохраняет\ значения\ регистров\ R0-\/R3,\ R12,\ LR,\ PC,\ PSR.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00533}00533\ \textcolor{comment}{\ \ *\ \ \ 3.\ Выводит\ системные\ регистры\ CFSR,\ HFSR,\ DFSR,\ AFSR,\ MMFAR,\ BFAR.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00534}00534\ \textcolor{comment}{\ \ *\ \ \ 4.\ Формирует\ stack\ trace\ с\ 3\ уровнями\ возврата.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00535}00535\ \textcolor{comment}{\ \ *\ \ \ 5.\ Копирует\ последние\ символы\ RTT\ буфера.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00536}00536\ \textcolor{comment}{\ \ *\ \ \ 6.\ Сохраняет\ все\ данные\ во\ Flash\ через\ RTT\_SaveToFlash\ с\ базовым\ тегом\ HF\_RTT\_TAG\_BASE.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00537}00537\ \textcolor{comment}{\ \ *}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00538}00538\ \textcolor{comment}{\ \ *\ @note\ Функция\ защищена,\ так\ как\ вызывается\ в\ контексте\ сбоя\ —\ минимизирует\ использование\ вызовов\ HAL.}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00539}00539\ \textcolor{comment}{\ \ */}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00540}\mbox{\hyperlink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_gadd8e10e7ec3b0204f7f92062ecd452f7}{00540}}\ \_\_STATIC\_FORCEINLINE\ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{group___t_r_a_c_e___h_a_r_d_f_a_u_l_t_gadd8e10e7ec3b0204f7f92062ecd452f7}{HF\_HandleFault}}(\textcolor{keywordtype}{void})} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00541}00541\ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00542}00542\ \ \ \ \ \textcolor{comment}{//\ Получаем\ указатель\ на\ стек,\ где\ произошёл\ HardFault}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00543}00543\ \ \ \ \ \_\_ASM\ \textcolor{keyword}{volatile}(} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00544}00544\ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}TST\ lr,\ \#4\ \ \ \ \ \ \ \(\backslash\)n"{}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00545}00545\ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}ITE\ EQ\ \ \ \ \ \ \ \ \ \ \ \(\backslash\)n"{}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00546}00546\ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}MRSEQ\ \%[ptr],\ MSP\(\backslash\)n"{}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00547}00547\ \ \ \ \ \ \ \ \ \textcolor{stringliteral}{"{}MRSNE\ \%[ptr],\ PSP\(\backslash\)n"{}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00548}00548\ \ \ \ \ \ \ \ \ :\ [ptr]\ \textcolor{stringliteral}{"{}=r"{}}(stack\_frame)} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00549}00549\ \ \ \ \ );} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00550}00550\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00551}00551\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\(\backslash\)n=====\ HardFault\ occurred!\ =====\(\backslash\)n"{}});} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00552}00552\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R0\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>r0);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00553}00553\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R1\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>r1);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00554}00554\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R2\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>r2);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00555}00555\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R3\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>r3);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00556}00556\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}R12\ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>r12);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00557}00557\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}LR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>lr);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00558}00558\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}PC\ \ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>pc);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00559}00559\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}PSR\ =\ 0x\%08X\(\backslash\)n"{}},\ stack\_frame-\/>psr);} \DoxyCodeLine{\Hypertarget{trace_8h_source_l00560}00560\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00561}00561\ \ \ \ \ \textcolor{keywordflow}{for}\ (\textcolor{keywordtype}{int}\ i\ =\ 0;\ i\ <\ 3;\ i++)\ \ \textcolor{comment}{//\ развернуть\ n\ уровней}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00562}00562\ \ \ \ \ \{} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00563}00563\ \ \ \ \ \ \ \textcolor{keywordflow}{if}(ret\_adr[i])} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00564}00564\ \ \ \ \ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\ \ \#\%d:\ 0x\%08lX\(\backslash\)r\(\backslash\)n"{}},\ i,\ ret\_adr[i]);\ \textcolor{comment}{//\ -\/1\ для\ Thumb}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00565}00565\ \ \ \ \ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00566}00566\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63}{RTT\_SaveToFlash}}(\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gadc960255719c7eff4bdfaa850be9b313}{HF\_RTT\_TAG\_BASE}},\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafcc7ea03d4df8f1909e580b519a7f3ca}{HF\_RTT\_TAIL\_SIZE}});} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00567}00567\ \}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00568}00568\ \textcolor{preprocessor}{\#else\ }\textcolor{comment}{//\ HAL\_MODULE\_ENABLED\ \&\&\ HARDFAULT\_SERIAL\_TRACE}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00569}00569\ \textcolor{preprocessor}{\#define\ HF\_CheckRecovered(...)\ 0}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00570}00570\ \textcolor{preprocessor}{\#define\ HF\_HandleFault(...)}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00571}00571\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ HAL\_MODULE\_ENABLED\ \&\&\ HARDFAULT\_SERIAL\_TRACE}\textcolor{comment}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00572}00572\ \textcolor{comment}{/**\ TRACE\_HARDFAULT}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00573}00573\ \textcolor{comment}{\ \ *\ @\}}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00574}00574\ \textcolor{comment}{\ \ */}\textcolor{preprocessor}{}} -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00575}00575\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00576}00576\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00577}00577\ } -\DoxyCodeLine{\Hypertarget{trace_8h_source_l00578}00578\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\_\_TRACE\_H\_}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00561}00561\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}CFSR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>CFSR);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00562}00562\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}HFSR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>HFSR);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00563}00563\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}DFSR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>DFSR);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00564}00564\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}AFSR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>AFSR);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00565}00565\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}MMFAR\ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>MMFAR);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00566}00566\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}BFAR\ \ =\ 0x\%08X\(\backslash\)n"{}},\ SCB-\/>BFAR);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00567}00567\ \ \ \ \ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00568}00568\ \ \ \ \ \textcolor{comment}{//\ -\/-\/-\/\ Stack\ trace\ -\/-\/-\/}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00569}00569\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}-\/-\/-\/\ Stack\ trace\ -\/-\/-\/\(\backslash\)n"{}});} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00570}00570\ \ \ \ \ ret\_adr[0]\ =\ \_\_builtin\_return\_address(0);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00571}00571\ \ \ \ \ ret\_adr[1]\ =\ \_\_builtin\_return\_address(1);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00572}00572\ \ \ \ \ ret\_adr[2]\ =\ \_\_builtin\_return\_address(2);} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00573}00573\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00574}00574\ \ \ \ \ \textcolor{keywordflow}{for}\ (\textcolor{keywordtype}{int}\ i\ =\ 0;\ i\ <\ 3;\ i++)\ \ \textcolor{comment}{//\ развернуть\ n\ уровней}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00575}00575\ \ \ \ \ \{} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00576}00576\ \ \ \ \ \ \ \textcolor{keywordflow}{if}(ret\_adr[i])} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00577}00577\ \ \ \ \ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___s_e_r_i_a_l_gae9b9b8a611e291a2f2aa5abf99f3ebaa}{my\_printf}}(\textcolor{stringliteral}{"{}\ \ \#\%d:\ 0x\%08lX\(\backslash\)r\(\backslash\)n"{}},\ i,\ ret\_adr[i]);\ \textcolor{comment}{//\ -\/1\ для\ Thumb}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00578}00578\ \ \ \ \ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00579}00579\ \ \ \ \ \mbox{\hyperlink{group___t_r_a_c_e___r_t_t___f_l_a_s_h_ga79f222c8ab644de4d47f07528d1edd63}{RTT\_SaveToFlash}}(\mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gadc960255719c7eff4bdfaa850be9b313}{HF\_RTT\_TAG\_BASE}},\ \mbox{\hyperlink{group___t_r_a_c_e___c_o_n_f_i_g_gafcc7ea03d4df8f1909e580b519a7f3ca}{HF\_RTT\_TAIL\_SIZE}});} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00580}00580\ \}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00581}00581\ \textcolor{preprocessor}{\#else\ }\textcolor{comment}{//\ HAL\_MODULE\_ENABLED\ \&\&\ HARDFAULT\_SERIAL\_TRACE}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00582}00582\ \textcolor{preprocessor}{\#define\ HF\_CheckRecovered(...)\ 0}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00583}00583\ \textcolor{preprocessor}{\#define\ HF\_HandleFault(...)}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00584}00584\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ HAL\_MODULE\_ENABLED\ \&\&\ HARDFAULT\_SERIAL\_TRACE}\textcolor{comment}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00585}00585\ \textcolor{comment}{/**\ TRACE\_HARDFAULT}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00586}00586\ \textcolor{comment}{\ \ *\ @\}}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00587}00587\ \textcolor{comment}{\ \ */}\textcolor{preprocessor}{}} +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00588}00588\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00589}00589\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00590}00590\ } +\DoxyCodeLine{\Hypertarget{trace_8h_source_l00591}00591\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\_\_TRACE\_H\_}} \end{DoxyCode} diff --git a/Doc/latex/trackers_8h.tex b/Doc/latex/trackers_8h.tex index 1f402ed..9b09a0e 100644 --- a/Doc/latex/trackers_8h.tex +++ b/Doc/latex/trackers_8h.tex @@ -1,23 +1,25 @@ -\doxysection{F\+:/\+Work/\+Projects/\+STM/.Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/trackers.h File Reference} -\hypertarget{trackers_8h}{}\label{trackers_8h}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trackers.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trackers.h}} +\doxysection{E\+:/.WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/trackers.h File Reference} +\hypertarget{trackers_8h}{}\label{trackers_8h}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trackers.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trackers.h}} Заголочный файл для работы с трекерами \doxylink{group___t_r_a_c_k_e_r_s}{Trackers defines}. {\ttfamily \#include "{}mylibs\+\_\+defs.\+h"{}}\newline -Include dependency graph for trackers.\+h\+:\nopagebreak +Include dependency graph for trackers.\+h\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=245pt]{trackers_8h__incl} +\includegraphics[width=229pt]{trackers_8h__incl} \end{center} \end{figure} -This graph shows which files directly or indirectly include this file\+:\nopagebreak +This graph shows which files directly or indirectly include this file\+: +\nopagebreak \begin{figure}[H] \begin{center} \leavevmode -\includegraphics[width=245pt]{trackers_8h__dep__incl} +\includegraphics[width=229pt]{trackers_8h__dep__incl} \end{center} \end{figure} \doxysubsubsection*{Macros} @@ -25,43 +27,43 @@ This graph shows which files directly or indirectly include this file\+:\nopageb \item \#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga50ccb119acf302969b7fdcb58f2130e4}{Tracker\+Type\+Def}}(num\+\_\+user\+\_\+vars) \begin{DoxyCompactList}\small\item\em Структура для счетчиков отладки \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}{num\+\_\+of\+\_\+usercnts}}(\+\_\+user\+\_\+)~(sizeof(\+\_\+user\+\_\+) / sizeof(uint32\+\_\+t)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}{num\+\_\+of\+\_\+usercnts}}(\+\_\+user\+\_\+) \begin{DoxyCompactList}\small\item\em Получить количетство пользовательских переменных \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~((\+\_\+uservarnumb\+\_\+) $<$ \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga72be24629fedb8bf70e830373d151fbc}{num\+\_\+of\+\_\+usercnts}}((\+\_\+cntstruct\+\_\+).user)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Проверка существует ли указанная пользовательская переменная \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~if(\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Условие для проверки существует ли указанная пользовательская переменная \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}{tern\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~(\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gadd7fd2c6e3a4800f1d5ddab35fd4b43e}{assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)) ? \+\_\+uservarnumb\+\_\+ \+: 0 +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}{tern\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Тернарный оператор для проверки существует ли указанная пользовательская переменная \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gab880911066605602a966641682090169}{Tracker\+Get\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gab880911066605602a966641682090169}{Tracker\+Get\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Считать счетчик успешных событий \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga9dc91e6b798a081f95f2ccef2c288e5e}{Tracker\+Get\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga9dc91e6b798a081f95f2ccef2c288e5e}{Tracker\+Get\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Считать счетчик ошибок \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga47ac59a406ee74d4cd9fe0fbaf63a758}{Tracker\+Get\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga47ac59a406ee74d4cd9fe0fbaf63a758}{Tracker\+Get\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Считать счетчик предупреждений \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga4b08632669043dfdbd219dda03502bdb}{Tracker\+Get\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~(\+\_\+cntstruct\+\_\+).user\mbox{[}\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga39b6ffbc561f8caac276415e1ad32c30}{tern\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)\mbox{]} +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga4b08632669043dfdbd219dda03502bdb}{Tracker\+Get\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Считать пользовательскую переменную \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga23de0006aa08984cfeddb6aa5e512fa1}{Tracker\+Cnt\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok++ +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga23de0006aa08984cfeddb6aa5e512fa1}{Tracker\+Cnt\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Инкрементирование счетчика успешных событий \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga49af29ab3927cad105c1d2b018a767e9}{Tracker\+Cnt\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err++ +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga49af29ab3927cad105c1d2b018a767e9}{Tracker\+Cnt\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Инкрементирование счетчика ошибок \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga8017fb05a56a1b667244f1f786fa9c57}{Tracker\+Cnt\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn++ +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga8017fb05a56a1b667244f1f786fa9c57}{Tracker\+Cnt\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Инкрементирование счетчика предупреждений \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga1b7549afc4a1760b54a9b93b0f6d105e}{Tracker\+Cnt\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]}++; +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga1b7549afc4a1760b54a9b93b0f6d105e}{Tracker\+Cnt\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Инкрементирование пользовательской переменной \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad2f4062a9ac8c2ab062a364f640ebc51}{Tracker\+Write\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+, \+\_\+val\+\_\+)~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]} = (\+\_\+val\+\_\+) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad2f4062a9ac8c2ab062a364f640ebc51}{Tracker\+Write\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+, \+\_\+val\+\_\+) \begin{DoxyCompactList}\small\item\em Запись числа в пользовательскую переменную \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga704f7b9f8c65c9bcec48ce7cb77a2d3b}{Tracker\+Clear\+\_\+\+All}}(\+\_\+cntstruct\+\_\+)~memset(\&(\+\_\+cntstruct\+\_\+), 0, sizeof(\+\_\+cntstruct\+\_\+)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga704f7b9f8c65c9bcec48ce7cb77a2d3b}{Tracker\+Clear\+\_\+\+All}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка всей структуры \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga5dd8bac8c7ab5832019d55d7a68371b9}{Tracker\+Clear\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+ok = 0 +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga5dd8bac8c7ab5832019d55d7a68371b9}{Tracker\+Clear\+\_\+\+Ok}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка счетчика успешных событий \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74}{Tracker\+Clear\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+err = 0 +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gae860b6947c6e317e14d40bd7b4b8eb74}{Tracker\+Clear\+\_\+\+Err}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка счетчика ошибок \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead}{Tracker\+Clear\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+)~(\+\_\+cntstruct\+\_\+).cnt\+\_\+warn = 0 +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga365a8c60bd13b75154feda649dd21ead}{Tracker\+Clear\+\_\+\+Warn}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка счетчика предупреждений \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d}{Tracker\+Clear\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+)~\mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gad91d8ca89074270fc040c0449e57cf07}{if\+\_\+assert\+\_\+usertracker}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) (\+\_\+cntstruct\+\_\+).user\mbox{[}\+\_\+uservarnumb\+\_\+\mbox{]} = 0; +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_ga063dab1067005e1600ea32531fdf3f8d}{Tracker\+Clear\+\_\+\+User}}(\+\_\+cntstruct\+\_\+, \+\_\+uservarnumb\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка пользовательской переменной \end{DoxyCompactList}\item -\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5}{Tracker\+Clear\+\_\+\+User\+All}}(\+\_\+cntstruct\+\_\+)~memset(\&(\+\_\+cntstruct\+\_\+).user, 0, sizeof((\+\_\+cntstruct\+\_\+).user)) +\#define \mbox{\hyperlink{group___t_r_a_c_k_e_r_s_gaaec7ec19977bb26fa1919dfe920b82d5}{Tracker\+Clear\+\_\+\+User\+All}}(\+\_\+cntstruct\+\_\+) \begin{DoxyCompactList}\small\item\em Очистка всех пользовательских переменных \end{DoxyCompactList}\end{DoxyCompactItemize} diff --git a/Doc/latex/trackers_8h__dep__incl.md5 b/Doc/latex/trackers_8h__dep__incl.md5 index db42c88..1f31ff9 100644 --- a/Doc/latex/trackers_8h__dep__incl.md5 +++ b/Doc/latex/trackers_8h__dep__incl.md5 @@ -1 +1 @@ -b846d5f6f730de44071fc47243d7d99d \ No newline at end of file +72159b9328b2b9eb57fcadd1b302af03 \ No newline at end of file diff --git a/Doc/latex/trackers_8h__dep__incl.pdf b/Doc/latex/trackers_8h__dep__incl.pdf index bfb8f20..6187eda 100644 Binary files a/Doc/latex/trackers_8h__dep__incl.pdf and b/Doc/latex/trackers_8h__dep__incl.pdf differ diff --git a/Doc/latex/trackers_8h__incl.md5 b/Doc/latex/trackers_8h__incl.md5 index bc2aed8..6a7968e 100644 --- a/Doc/latex/trackers_8h__incl.md5 +++ b/Doc/latex/trackers_8h__incl.md5 @@ -1 +1 @@ -3c9f10ae297328bb7c38db39a1b594fe \ No newline at end of file +6d8304d11950bddd905c4ec0d61782f8 \ No newline at end of file diff --git a/Doc/latex/trackers_8h__incl.pdf b/Doc/latex/trackers_8h__incl.pdf index 44b27be..90db104 100644 Binary files a/Doc/latex/trackers_8h__incl.pdf and b/Doc/latex/trackers_8h__incl.pdf differ diff --git a/Doc/latex/trackers_8h_source.tex b/Doc/latex/trackers_8h_source.tex index a32d9f2..10669d6 100644 --- a/Doc/latex/trackers_8h_source.tex +++ b/Doc/latex/trackers_8h_source.tex @@ -1,5 +1,5 @@ \doxysection{trackers.\+h} -\hypertarget{trackers_8h_source}{}\label{trackers_8h_source}\index{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trackers.h@{F:/Work/Projects/STM/.Elementary/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trackers.h}} +\hypertarget{trackers_8h_source}{}\label{trackers_8h_source}\index{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trackers.h@{E:/.WORK/STM32/STM32\_ExtendedLibs/MyLibsGeneral/Inc/trackers.h}} \mbox{\hyperlink{trackers_8h}{Go to the documentation of this file.}} \begin{DoxyCode}{0} \DoxyCodeLine{\Hypertarget{trackers_8h_source_l00001}00001\ \textcolor{comment}{/**\ }} diff --git a/Doc/latex/unionuint16___bit_type_def.tex b/Doc/latex/unionuint16___bit_type_def.tex index c196c4b..c4d32f3 100644 --- a/Doc/latex/unionuint16___bit_type_def.tex +++ b/Doc/latex/unionuint16___bit_type_def.tex @@ -5,7 +5,7 @@ \item uint16\+\_\+t \mbox{\hyperlink{unionuint16___bit_type_def_ab821c8d3f0ad9b2aa405b29c1a15e955}{all}} \item -\Hypertarget{unionuint16___bit_type_def_abe6bb6d170ddf8f4320c50c377e88fbb}\label{unionuint16___bit_type_def_abe6bb6d170ddf8f4320c50c377e88fbb} +\Hypertarget{unionuint16___bit_type_def_a74615b0facc151c62611408fa64fa3a7}\label{unionuint16___bit_type_def_a74615b0facc151c62611408fa64fa3a7} \begin{tabbing} xx\=xx\=xx\=xx\=xx\=xx\=xx\=xx\=xx\=\kill struct \{\\ @@ -37,172 +37,174 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00055}{55}} of file \ +\label{doc-variable-members} +\Hypertarget{unionuint16___bit_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{unionuint16___bit_type_def_ab821c8d3f0ad9b2aa405b29c1a15e955}\label{unionuint16___bit_type_def_ab821c8d3f0ad9b2aa405b29c1a15e955} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!all@{all}} +\Hypertarget{unionuint16___bit_type_def_ab821c8d3f0ad9b2aa405b29c1a15e955}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!all@{all}} \index{all@{all}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{all}{all}} -{\footnotesize\ttfamily uint16\+\_\+t uint16\+\_\+\+Bit\+Type\+Def\+::all} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_ab821c8d3f0ad9b2aa405b29c1a15e955} +uint16\+\_\+t uint16\+\_\+\+Bit\+Type\+Def\+::all} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00057}{57}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_acf97910d744de20e4f66231ac04916f4}\label{unionuint16___bit_type_def_acf97910d744de20e4f66231ac04916f4} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit0@{bit0}} +\Hypertarget{unionuint16___bit_type_def_acf97910d744de20e4f66231ac04916f4}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit0@{bit0}} \index{bit0@{bit0}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit0}{bit0}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit0} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_acf97910d744de20e4f66231ac04916f4} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit0} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00060}{60}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_ad24e7739b7345e2e8c7b904390f38245}\label{unionuint16___bit_type_def_ad24e7739b7345e2e8c7b904390f38245} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit1@{bit1}} +\Hypertarget{unionuint16___bit_type_def_ad24e7739b7345e2e8c7b904390f38245}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit1@{bit1}} \index{bit1@{bit1}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit1}{bit1}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit1} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_ad24e7739b7345e2e8c7b904390f38245} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit1} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00061}{61}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_aeeaefb47272ce9dd0093189434e3cc16}\label{unionuint16___bit_type_def_aeeaefb47272ce9dd0093189434e3cc16} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit2@{bit2}} +\Hypertarget{unionuint16___bit_type_def_aeeaefb47272ce9dd0093189434e3cc16}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit2@{bit2}} \index{bit2@{bit2}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit2}{bit2}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit2} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_aeeaefb47272ce9dd0093189434e3cc16} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit2} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00062}{62}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a0fd35ec303d0432e0ed09498b4339825}\label{unionuint16___bit_type_def_a0fd35ec303d0432e0ed09498b4339825} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit3@{bit3}} +\Hypertarget{unionuint16___bit_type_def_a0fd35ec303d0432e0ed09498b4339825}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit3@{bit3}} \index{bit3@{bit3}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit3}{bit3}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit3} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a0fd35ec303d0432e0ed09498b4339825} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit3} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00063}{63}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_abf9ffa5ca2bf68f60e663c6a34283024}\label{unionuint16___bit_type_def_abf9ffa5ca2bf68f60e663c6a34283024} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit4@{bit4}} +\Hypertarget{unionuint16___bit_type_def_abf9ffa5ca2bf68f60e663c6a34283024}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit4@{bit4}} \index{bit4@{bit4}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit4}{bit4}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit4} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_abf9ffa5ca2bf68f60e663c6a34283024} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit4} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00064}{64}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_abdd8245ddc6468c4edc6eb7b523f2b68}\label{unionuint16___bit_type_def_abdd8245ddc6468c4edc6eb7b523f2b68} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit5@{bit5}} +\Hypertarget{unionuint16___bit_type_def_abdd8245ddc6468c4edc6eb7b523f2b68}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit5@{bit5}} \index{bit5@{bit5}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit5}{bit5}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit5} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_abdd8245ddc6468c4edc6eb7b523f2b68} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit5} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00065}{65}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a67094d80de21352fd3fdfd34ca862f08}\label{unionuint16___bit_type_def_a67094d80de21352fd3fdfd34ca862f08} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit6@{bit6}} +\Hypertarget{unionuint16___bit_type_def_a67094d80de21352fd3fdfd34ca862f08}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit6@{bit6}} \index{bit6@{bit6}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit6}{bit6}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit6} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a67094d80de21352fd3fdfd34ca862f08} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit6} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00066}{66}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a6f693fc837a1ea0f3a6fcbc64963d4e5}\label{unionuint16___bit_type_def_a6f693fc837a1ea0f3a6fcbc64963d4e5} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit7@{bit7}} +\Hypertarget{unionuint16___bit_type_def_a6f693fc837a1ea0f3a6fcbc64963d4e5}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit7@{bit7}} \index{bit7@{bit7}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit7}{bit7}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit7} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a6f693fc837a1ea0f3a6fcbc64963d4e5} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit7} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00067}{67}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a87b063401e95d432f4797abf1ef38037}\label{unionuint16___bit_type_def_a87b063401e95d432f4797abf1ef38037} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit8@{bit8}} +\Hypertarget{unionuint16___bit_type_def_a87b063401e95d432f4797abf1ef38037}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit8@{bit8}} \index{bit8@{bit8}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit8}{bit8}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit8} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a87b063401e95d432f4797abf1ef38037} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit8} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00068}{68}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a790a2de77be9b2672fec0ed8725aa3ce}\label{unionuint16___bit_type_def_a790a2de77be9b2672fec0ed8725aa3ce} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit9@{bit9}} +\Hypertarget{unionuint16___bit_type_def_a790a2de77be9b2672fec0ed8725aa3ce}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit9@{bit9}} \index{bit9@{bit9}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit9}{bit9}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit9} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a790a2de77be9b2672fec0ed8725aa3ce} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit9} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00069}{69}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a2068066f12e596957429373a9e7b370b}\label{unionuint16___bit_type_def_a2068066f12e596957429373a9e7b370b} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit10@{bit10}} +\Hypertarget{unionuint16___bit_type_def_a2068066f12e596957429373a9e7b370b}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit10@{bit10}} \index{bit10@{bit10}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit10}{bit10}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit10} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a2068066f12e596957429373a9e7b370b} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit10} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00070}{70}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a5aea5de8000bab137f45154ac4845a7a}\label{unionuint16___bit_type_def_a5aea5de8000bab137f45154ac4845a7a} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit11@{bit11}} +\Hypertarget{unionuint16___bit_type_def_a5aea5de8000bab137f45154ac4845a7a}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit11@{bit11}} \index{bit11@{bit11}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit11}{bit11}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit11} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a5aea5de8000bab137f45154ac4845a7a} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit11} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00071}{71}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_af42575933decdc768b2d47d74150b447}\label{unionuint16___bit_type_def_af42575933decdc768b2d47d74150b447} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit12@{bit12}} +\Hypertarget{unionuint16___bit_type_def_af42575933decdc768b2d47d74150b447}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit12@{bit12}} \index{bit12@{bit12}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit12}{bit12}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit12} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_af42575933decdc768b2d47d74150b447} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit12} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00072}{72}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a4cb4776e5e848a3cce73e9eca21a2977}\label{unionuint16___bit_type_def_a4cb4776e5e848a3cce73e9eca21a2977} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit13@{bit13}} +\Hypertarget{unionuint16___bit_type_def_a4cb4776e5e848a3cce73e9eca21a2977}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit13@{bit13}} \index{bit13@{bit13}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit13}{bit13}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit13} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a4cb4776e5e848a3cce73e9eca21a2977} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit13} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00073}{73}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a0c88ae0be399d9620d288f548ab4037d}\label{unionuint16___bit_type_def_a0c88ae0be399d9620d288f548ab4037d} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit14@{bit14}} +\Hypertarget{unionuint16___bit_type_def_a0c88ae0be399d9620d288f548ab4037d}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit14@{bit14}} \index{bit14@{bit14}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit14}{bit14}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit14} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a0c88ae0be399d9620d288f548ab4037d} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit14} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00074}{74}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint16___bit_type_def_a246b7b099a4fab9338abb9549339db7c}\label{unionuint16___bit_type_def_a246b7b099a4fab9338abb9549339db7c} -\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit15@{bit15}} +\Hypertarget{unionuint16___bit_type_def_a246b7b099a4fab9338abb9549339db7c}\index{uint16\_BitTypeDef@{uint16\_BitTypeDef}!bit15@{bit15}} \index{bit15@{bit15}!uint16\_BitTypeDef@{uint16\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit15}{bit15}} -{\footnotesize\ttfamily unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit15} +{\footnotesize\ttfamily \label{unionuint16___bit_type_def_a246b7b099a4fab9338abb9549339db7c} +unsigned uint16\+\_\+\+Bit\+Type\+Def\+::bit15} @@ -212,4 +214,4 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00075}{75}} of file \ The documentation for this union was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/unionuint32___bit_type_def.tex b/Doc/latex/unionuint32___bit_type_def.tex index 1567bb7..3014264 100644 --- a/Doc/latex/unionuint32___bit_type_def.tex +++ b/Doc/latex/unionuint32___bit_type_def.tex @@ -5,7 +5,7 @@ \item uint32\+\_\+t \mbox{\hyperlink{unionuint32___bit_type_def_aabd9acf3b55b909219a41737a105f31b}{all}} \item -\Hypertarget{unionuint32___bit_type_def_a76de1c3d849f17f4ee2f9d17b44ee853}\label{unionuint32___bit_type_def_a76de1c3d849f17f4ee2f9d17b44ee853} +\Hypertarget{unionuint32___bit_type_def_a49ec6ac6dfc5a5da865150c5213e3822}\label{unionuint32___bit_type_def_a49ec6ac6dfc5a5da865150c5213e3822} \begin{tabbing} xx\=xx\=xx\=xx\=xx\=xx\=xx\=xx\=xx\=\kill struct \{\\ @@ -53,332 +53,334 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00080}{80}} of file \ +\label{doc-variable-members} +\Hypertarget{unionuint32___bit_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{unionuint32___bit_type_def_aabd9acf3b55b909219a41737a105f31b}\label{unionuint32___bit_type_def_aabd9acf3b55b909219a41737a105f31b} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!all@{all}} +\Hypertarget{unionuint32___bit_type_def_aabd9acf3b55b909219a41737a105f31b}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!all@{all}} \index{all@{all}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{all}{all}} -{\footnotesize\ttfamily uint32\+\_\+t uint32\+\_\+\+Bit\+Type\+Def\+::all} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_aabd9acf3b55b909219a41737a105f31b} +uint32\+\_\+t uint32\+\_\+\+Bit\+Type\+Def\+::all} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00082}{82}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_abff6cfc25cc49ec273ed50773492e7f5}\label{unionuint32___bit_type_def_abff6cfc25cc49ec273ed50773492e7f5} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit0@{bit0}} +\Hypertarget{unionuint32___bit_type_def_abff6cfc25cc49ec273ed50773492e7f5}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit0@{bit0}} \index{bit0@{bit0}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit0}{bit0}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit0} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_abff6cfc25cc49ec273ed50773492e7f5} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit0} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00085}{85}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_abf8bdbe7ff864eed8de9099c0b587e28}\label{unionuint32___bit_type_def_abf8bdbe7ff864eed8de9099c0b587e28} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit1@{bit1}} +\Hypertarget{unionuint32___bit_type_def_abf8bdbe7ff864eed8de9099c0b587e28}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit1@{bit1}} \index{bit1@{bit1}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit1}{bit1}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit1} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_abf8bdbe7ff864eed8de9099c0b587e28} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit1} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00085}{85}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a666403b3523509859533e4d9f8b92f54}\label{unionuint32___bit_type_def_a666403b3523509859533e4d9f8b92f54} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit2@{bit2}} +\Hypertarget{unionuint32___bit_type_def_a666403b3523509859533e4d9f8b92f54}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit2@{bit2}} \index{bit2@{bit2}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit2}{bit2}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit2} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a666403b3523509859533e4d9f8b92f54} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit2} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00085}{85}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a5a2e789bb9bd79a65b1018bf45f18e20}\label{unionuint32___bit_type_def_a5a2e789bb9bd79a65b1018bf45f18e20} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit3@{bit3}} +\Hypertarget{unionuint32___bit_type_def_a5a2e789bb9bd79a65b1018bf45f18e20}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit3@{bit3}} \index{bit3@{bit3}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit3}{bit3}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit3} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a5a2e789bb9bd79a65b1018bf45f18e20} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit3} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00085}{85}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_abf47a02fa44022e310d8f5ff1a016a0b}\label{unionuint32___bit_type_def_abf47a02fa44022e310d8f5ff1a016a0b} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit4@{bit4}} +\Hypertarget{unionuint32___bit_type_def_abf47a02fa44022e310d8f5ff1a016a0b}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit4@{bit4}} \index{bit4@{bit4}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit4}{bit4}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit4} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_abf47a02fa44022e310d8f5ff1a016a0b} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit4} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00086}{86}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_ad1123a45e39fae16a0bc6ef1f9d8a029}\label{unionuint32___bit_type_def_ad1123a45e39fae16a0bc6ef1f9d8a029} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit5@{bit5}} +\Hypertarget{unionuint32___bit_type_def_ad1123a45e39fae16a0bc6ef1f9d8a029}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit5@{bit5}} \index{bit5@{bit5}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit5}{bit5}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit5} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_ad1123a45e39fae16a0bc6ef1f9d8a029} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit5} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00086}{86}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a09e0e3f37bb503bfc35c74988f7d1c38}\label{unionuint32___bit_type_def_a09e0e3f37bb503bfc35c74988f7d1c38} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit6@{bit6}} +\Hypertarget{unionuint32___bit_type_def_a09e0e3f37bb503bfc35c74988f7d1c38}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit6@{bit6}} \index{bit6@{bit6}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit6}{bit6}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit6} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a09e0e3f37bb503bfc35c74988f7d1c38} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit6} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00086}{86}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_ae0c9ae90820561cd7a65bed3ed545908}\label{unionuint32___bit_type_def_ae0c9ae90820561cd7a65bed3ed545908} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit7@{bit7}} +\Hypertarget{unionuint32___bit_type_def_ae0c9ae90820561cd7a65bed3ed545908}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit7@{bit7}} \index{bit7@{bit7}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit7}{bit7}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit7} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_ae0c9ae90820561cd7a65bed3ed545908} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit7} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00086}{86}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_aa5d94c8ca24d3987d889abf68a727469}\label{unionuint32___bit_type_def_aa5d94c8ca24d3987d889abf68a727469} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit8@{bit8}} +\Hypertarget{unionuint32___bit_type_def_aa5d94c8ca24d3987d889abf68a727469}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit8@{bit8}} \index{bit8@{bit8}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit8}{bit8}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit8} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_aa5d94c8ca24d3987d889abf68a727469} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit8} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00087}{87}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_aa7a37c3527f8cccab46b7df2fd8209f5}\label{unionuint32___bit_type_def_aa7a37c3527f8cccab46b7df2fd8209f5} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit9@{bit9}} +\Hypertarget{unionuint32___bit_type_def_aa7a37c3527f8cccab46b7df2fd8209f5}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit9@{bit9}} \index{bit9@{bit9}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit9}{bit9}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit9} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_aa7a37c3527f8cccab46b7df2fd8209f5} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit9} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00087}{87}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_ac12eaa502b6d609141ccb335f33af5e7}\label{unionuint32___bit_type_def_ac12eaa502b6d609141ccb335f33af5e7} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit10@{bit10}} +\Hypertarget{unionuint32___bit_type_def_ac12eaa502b6d609141ccb335f33af5e7}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit10@{bit10}} \index{bit10@{bit10}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit10}{bit10}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit10} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_ac12eaa502b6d609141ccb335f33af5e7} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit10} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00087}{87}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a683cce990ca4831b03265bfbe482cbb4}\label{unionuint32___bit_type_def_a683cce990ca4831b03265bfbe482cbb4} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit11@{bit11}} +\Hypertarget{unionuint32___bit_type_def_a683cce990ca4831b03265bfbe482cbb4}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit11@{bit11}} \index{bit11@{bit11}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit11}{bit11}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit11} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a683cce990ca4831b03265bfbe482cbb4} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit11} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00087}{87}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a77e18067ae4ac536b344117243c6d506}\label{unionuint32___bit_type_def_a77e18067ae4ac536b344117243c6d506} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit12@{bit12}} +\Hypertarget{unionuint32___bit_type_def_a77e18067ae4ac536b344117243c6d506}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit12@{bit12}} \index{bit12@{bit12}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit12}{bit12}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit12} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a77e18067ae4ac536b344117243c6d506} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit12} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00088}{88}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a3cd10a17f06d0074bac403ed78afd891}\label{unionuint32___bit_type_def_a3cd10a17f06d0074bac403ed78afd891} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit13@{bit13}} +\Hypertarget{unionuint32___bit_type_def_a3cd10a17f06d0074bac403ed78afd891}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit13@{bit13}} \index{bit13@{bit13}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit13}{bit13}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit13} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a3cd10a17f06d0074bac403ed78afd891} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit13} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00088}{88}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a3c1e306cf28b30566ba1336fffce194b}\label{unionuint32___bit_type_def_a3c1e306cf28b30566ba1336fffce194b} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit14@{bit14}} +\Hypertarget{unionuint32___bit_type_def_a3c1e306cf28b30566ba1336fffce194b}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit14@{bit14}} \index{bit14@{bit14}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit14}{bit14}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit14} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a3c1e306cf28b30566ba1336fffce194b} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit14} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00088}{88}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a5270b3410fb334ca5639a7ff8168e79b}\label{unionuint32___bit_type_def_a5270b3410fb334ca5639a7ff8168e79b} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit15@{bit15}} +\Hypertarget{unionuint32___bit_type_def_a5270b3410fb334ca5639a7ff8168e79b}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit15@{bit15}} \index{bit15@{bit15}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit15}{bit15}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit15} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a5270b3410fb334ca5639a7ff8168e79b} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit15} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00088}{88}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_aaafd5bb13d528e1677d257c454877608}\label{unionuint32___bit_type_def_aaafd5bb13d528e1677d257c454877608} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit16@{bit16}} +\Hypertarget{unionuint32___bit_type_def_aaafd5bb13d528e1677d257c454877608}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit16@{bit16}} \index{bit16@{bit16}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit16}{bit16}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit16} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_aaafd5bb13d528e1677d257c454877608} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit16} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00089}{89}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a1433177abbca3502a8b349c84ea00a18}\label{unionuint32___bit_type_def_a1433177abbca3502a8b349c84ea00a18} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit17@{bit17}} +\Hypertarget{unionuint32___bit_type_def_a1433177abbca3502a8b349c84ea00a18}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit17@{bit17}} \index{bit17@{bit17}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit17}{bit17}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit17} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a1433177abbca3502a8b349c84ea00a18} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit17} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00089}{89}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a4a71070cee54394b6538702985bb9bed}\label{unionuint32___bit_type_def_a4a71070cee54394b6538702985bb9bed} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit18@{bit18}} +\Hypertarget{unionuint32___bit_type_def_a4a71070cee54394b6538702985bb9bed}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit18@{bit18}} \index{bit18@{bit18}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit18}{bit18}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit18} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a4a71070cee54394b6538702985bb9bed} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit18} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00089}{89}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_aa986b0413af6a14e8bc889e40a547dec}\label{unionuint32___bit_type_def_aa986b0413af6a14e8bc889e40a547dec} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit19@{bit19}} +\Hypertarget{unionuint32___bit_type_def_aa986b0413af6a14e8bc889e40a547dec}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit19@{bit19}} \index{bit19@{bit19}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit19}{bit19}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit19} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_aa986b0413af6a14e8bc889e40a547dec} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit19} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00089}{89}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a4aa0febc01b82124e82fd183e5938a92}\label{unionuint32___bit_type_def_a4aa0febc01b82124e82fd183e5938a92} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit20@{bit20}} +\Hypertarget{unionuint32___bit_type_def_a4aa0febc01b82124e82fd183e5938a92}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit20@{bit20}} \index{bit20@{bit20}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit20}{bit20}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit20} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a4aa0febc01b82124e82fd183e5938a92} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit20} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00090}{90}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a7b0e092cf7411e9b265546cb685088d2}\label{unionuint32___bit_type_def_a7b0e092cf7411e9b265546cb685088d2} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit21@{bit21}} +\Hypertarget{unionuint32___bit_type_def_a7b0e092cf7411e9b265546cb685088d2}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit21@{bit21}} \index{bit21@{bit21}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit21}{bit21}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit21} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a7b0e092cf7411e9b265546cb685088d2} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit21} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00090}{90}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a659e845e7eb657ea25a2f99d989849f6}\label{unionuint32___bit_type_def_a659e845e7eb657ea25a2f99d989849f6} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit22@{bit22}} +\Hypertarget{unionuint32___bit_type_def_a659e845e7eb657ea25a2f99d989849f6}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit22@{bit22}} \index{bit22@{bit22}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit22}{bit22}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit22} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a659e845e7eb657ea25a2f99d989849f6} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit22} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00090}{90}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_aee65f736e7d7b6af66addf365ae47ca9}\label{unionuint32___bit_type_def_aee65f736e7d7b6af66addf365ae47ca9} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit23@{bit23}} +\Hypertarget{unionuint32___bit_type_def_aee65f736e7d7b6af66addf365ae47ca9}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit23@{bit23}} \index{bit23@{bit23}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit23}{bit23}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit23} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_aee65f736e7d7b6af66addf365ae47ca9} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit23} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00090}{90}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a760d75577810f01480ff019023d7c10e}\label{unionuint32___bit_type_def_a760d75577810f01480ff019023d7c10e} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit24@{bit24}} +\Hypertarget{unionuint32___bit_type_def_a760d75577810f01480ff019023d7c10e}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit24@{bit24}} \index{bit24@{bit24}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit24}{bit24}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit24} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a760d75577810f01480ff019023d7c10e} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit24} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00091}{91}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a5cd1e149fa9d1b0c23a6977989ee30ca}\label{unionuint32___bit_type_def_a5cd1e149fa9d1b0c23a6977989ee30ca} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit25@{bit25}} +\Hypertarget{unionuint32___bit_type_def_a5cd1e149fa9d1b0c23a6977989ee30ca}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit25@{bit25}} \index{bit25@{bit25}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit25}{bit25}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit25} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a5cd1e149fa9d1b0c23a6977989ee30ca} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit25} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00091}{91}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a3ac1b793de197ed00907d420cbaf67de}\label{unionuint32___bit_type_def_a3ac1b793de197ed00907d420cbaf67de} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit26@{bit26}} +\Hypertarget{unionuint32___bit_type_def_a3ac1b793de197ed00907d420cbaf67de}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit26@{bit26}} \index{bit26@{bit26}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit26}{bit26}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit26} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a3ac1b793de197ed00907d420cbaf67de} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit26} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00091}{91}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_aef4211a2fbabc4020b376fcda333743e}\label{unionuint32___bit_type_def_aef4211a2fbabc4020b376fcda333743e} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit27@{bit27}} +\Hypertarget{unionuint32___bit_type_def_aef4211a2fbabc4020b376fcda333743e}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit27@{bit27}} \index{bit27@{bit27}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit27}{bit27}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit27} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_aef4211a2fbabc4020b376fcda333743e} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit27} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00091}{91}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a6849e6bd6f3e263f512d24bfe9b3b5be}\label{unionuint32___bit_type_def_a6849e6bd6f3e263f512d24bfe9b3b5be} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit28@{bit28}} +\Hypertarget{unionuint32___bit_type_def_a6849e6bd6f3e263f512d24bfe9b3b5be}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit28@{bit28}} \index{bit28@{bit28}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit28}{bit28}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit28} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a6849e6bd6f3e263f512d24bfe9b3b5be} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit28} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00092}{92}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a1a12a3a22dd803e4381a6f9c7be8b043}\label{unionuint32___bit_type_def_a1a12a3a22dd803e4381a6f9c7be8b043} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit29@{bit29}} +\Hypertarget{unionuint32___bit_type_def_a1a12a3a22dd803e4381a6f9c7be8b043}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit29@{bit29}} \index{bit29@{bit29}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit29}{bit29}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit29} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a1a12a3a22dd803e4381a6f9c7be8b043} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit29} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00092}{92}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_a743186db785e1a412209b75152ade3ff}\label{unionuint32___bit_type_def_a743186db785e1a412209b75152ade3ff} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit30@{bit30}} +\Hypertarget{unionuint32___bit_type_def_a743186db785e1a412209b75152ade3ff}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit30@{bit30}} \index{bit30@{bit30}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit30}{bit30}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit30} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_a743186db785e1a412209b75152ade3ff} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit30} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00092}{92}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint32___bit_type_def_acff898f6a1d8583148b8c20537266253}\label{unionuint32___bit_type_def_acff898f6a1d8583148b8c20537266253} -\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit31@{bit31}} +\Hypertarget{unionuint32___bit_type_def_acff898f6a1d8583148b8c20537266253}\index{uint32\_BitTypeDef@{uint32\_BitTypeDef}!bit31@{bit31}} \index{bit31@{bit31}!uint32\_BitTypeDef@{uint32\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit31}{bit31}} -{\footnotesize\ttfamily unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit31} +{\footnotesize\ttfamily \label{unionuint32___bit_type_def_acff898f6a1d8583148b8c20537266253} +unsigned uint32\+\_\+\+Bit\+Type\+Def\+::bit31} @@ -388,4 +390,4 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00092}{92}} of file \ The documentation for this union was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/unionuint64___bit_type_def.tex b/Doc/latex/unionuint64___bit_type_def.tex index 9b49ea9..23030ba 100644 --- a/Doc/latex/unionuint64___bit_type_def.tex +++ b/Doc/latex/unionuint64___bit_type_def.tex @@ -5,7 +5,7 @@ \item uint64\+\_\+t \mbox{\hyperlink{unionuint64___bit_type_def_a1dd79aa84a1d13d156f1b684aaf01edd}{all}} \item -\Hypertarget{unionuint64___bit_type_def_a1cec80592b666bd54a987bfd849604ae}\label{unionuint64___bit_type_def_a1cec80592b666bd54a987bfd849604ae} +\Hypertarget{unionuint64___bit_type_def_a90521812d54cf423f4cacf6cce0022cd}\label{unionuint64___bit_type_def_a90521812d54cf423f4cacf6cce0022cd} \begin{tabbing} xx\=xx\=xx\=xx\=xx\=xx\=xx\=xx\=xx\=\kill struct \{\\ @@ -85,652 +85,654 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00097}{97}} of file \ +\label{doc-variable-members} +\Hypertarget{unionuint64___bit_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{unionuint64___bit_type_def_a1dd79aa84a1d13d156f1b684aaf01edd}\label{unionuint64___bit_type_def_a1dd79aa84a1d13d156f1b684aaf01edd} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!all@{all}} +\Hypertarget{unionuint64___bit_type_def_a1dd79aa84a1d13d156f1b684aaf01edd}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!all@{all}} \index{all@{all}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{all}{all}} -{\footnotesize\ttfamily uint64\+\_\+t uint64\+\_\+\+Bit\+Type\+Def\+::all} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a1dd79aa84a1d13d156f1b684aaf01edd} +uint64\+\_\+t uint64\+\_\+\+Bit\+Type\+Def\+::all} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00099}{99}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_aff17255dbf3ae6a53a2cb3b9ec3d4298}\label{unionuint64___bit_type_def_aff17255dbf3ae6a53a2cb3b9ec3d4298} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit0@{bit0}} +\Hypertarget{unionuint64___bit_type_def_aff17255dbf3ae6a53a2cb3b9ec3d4298}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit0@{bit0}} \index{bit0@{bit0}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit0}{bit0}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit0} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_aff17255dbf3ae6a53a2cb3b9ec3d4298} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit0} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00102}{102}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a3261a8e364bbfc3bea2099962fd391e5}\label{unionuint64___bit_type_def_a3261a8e364bbfc3bea2099962fd391e5} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit1@{bit1}} +\Hypertarget{unionuint64___bit_type_def_a3261a8e364bbfc3bea2099962fd391e5}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit1@{bit1}} \index{bit1@{bit1}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit1}{bit1}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit1} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a3261a8e364bbfc3bea2099962fd391e5} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit1} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00102}{102}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a20ae7d30b5f560cb06ec7ddf8c901b8c}\label{unionuint64___bit_type_def_a20ae7d30b5f560cb06ec7ddf8c901b8c} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit2@{bit2}} +\Hypertarget{unionuint64___bit_type_def_a20ae7d30b5f560cb06ec7ddf8c901b8c}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit2@{bit2}} \index{bit2@{bit2}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit2}{bit2}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit2} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a20ae7d30b5f560cb06ec7ddf8c901b8c} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit2} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00102}{102}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a0c4125f907098ffe900e193357e5d3ad}\label{unionuint64___bit_type_def_a0c4125f907098ffe900e193357e5d3ad} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit3@{bit3}} +\Hypertarget{unionuint64___bit_type_def_a0c4125f907098ffe900e193357e5d3ad}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit3@{bit3}} \index{bit3@{bit3}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit3}{bit3}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit3} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a0c4125f907098ffe900e193357e5d3ad} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit3} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00102}{102}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a548c073727ccb13e6e7f56472412034f}\label{unionuint64___bit_type_def_a548c073727ccb13e6e7f56472412034f} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit4@{bit4}} +\Hypertarget{unionuint64___bit_type_def_a548c073727ccb13e6e7f56472412034f}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit4@{bit4}} \index{bit4@{bit4}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit4}{bit4}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit4} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a548c073727ccb13e6e7f56472412034f} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit4} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00103}{103}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a5386a391a6ba21bdeb0296ed9043d03a}\label{unionuint64___bit_type_def_a5386a391a6ba21bdeb0296ed9043d03a} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit5@{bit5}} +\Hypertarget{unionuint64___bit_type_def_a5386a391a6ba21bdeb0296ed9043d03a}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit5@{bit5}} \index{bit5@{bit5}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit5}{bit5}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit5} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a5386a391a6ba21bdeb0296ed9043d03a} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit5} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00103}{103}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a9181ed01944b9da888afafead31931d2}\label{unionuint64___bit_type_def_a9181ed01944b9da888afafead31931d2} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit6@{bit6}} +\Hypertarget{unionuint64___bit_type_def_a9181ed01944b9da888afafead31931d2}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit6@{bit6}} \index{bit6@{bit6}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit6}{bit6}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit6} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a9181ed01944b9da888afafead31931d2} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit6} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00103}{103}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a19df4425e8bfa0de2d6920696cf7614c}\label{unionuint64___bit_type_def_a19df4425e8bfa0de2d6920696cf7614c} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit7@{bit7}} +\Hypertarget{unionuint64___bit_type_def_a19df4425e8bfa0de2d6920696cf7614c}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit7@{bit7}} \index{bit7@{bit7}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit7}{bit7}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit7} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a19df4425e8bfa0de2d6920696cf7614c} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit7} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00103}{103}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a4e721ef35fc0b10ffde85d3face0810b}\label{unionuint64___bit_type_def_a4e721ef35fc0b10ffde85d3face0810b} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit8@{bit8}} +\Hypertarget{unionuint64___bit_type_def_a4e721ef35fc0b10ffde85d3face0810b}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit8@{bit8}} \index{bit8@{bit8}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit8}{bit8}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit8} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a4e721ef35fc0b10ffde85d3face0810b} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit8} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00104}{104}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a1269f7d45f62bf763c6dbcce5d286459}\label{unionuint64___bit_type_def_a1269f7d45f62bf763c6dbcce5d286459} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit9@{bit9}} +\Hypertarget{unionuint64___bit_type_def_a1269f7d45f62bf763c6dbcce5d286459}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit9@{bit9}} \index{bit9@{bit9}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit9}{bit9}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit9} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a1269f7d45f62bf763c6dbcce5d286459} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit9} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00104}{104}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a6d2d38d7385f47a21797ff1251150b26}\label{unionuint64___bit_type_def_a6d2d38d7385f47a21797ff1251150b26} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit10@{bit10}} +\Hypertarget{unionuint64___bit_type_def_a6d2d38d7385f47a21797ff1251150b26}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit10@{bit10}} \index{bit10@{bit10}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit10}{bit10}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit10} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a6d2d38d7385f47a21797ff1251150b26} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit10} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00104}{104}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_af2680443011d9537ad667321115bd9d9}\label{unionuint64___bit_type_def_af2680443011d9537ad667321115bd9d9} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit11@{bit11}} +\Hypertarget{unionuint64___bit_type_def_af2680443011d9537ad667321115bd9d9}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit11@{bit11}} \index{bit11@{bit11}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit11}{bit11}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit11} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_af2680443011d9537ad667321115bd9d9} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit11} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00104}{104}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a1e806ef90a4a49e9acc816fbfd559b7a}\label{unionuint64___bit_type_def_a1e806ef90a4a49e9acc816fbfd559b7a} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit12@{bit12}} +\Hypertarget{unionuint64___bit_type_def_a1e806ef90a4a49e9acc816fbfd559b7a}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit12@{bit12}} \index{bit12@{bit12}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit12}{bit12}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit12} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a1e806ef90a4a49e9acc816fbfd559b7a} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit12} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00105}{105}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ad4b8ef500154da1a0dc19ef9535fd18b}\label{unionuint64___bit_type_def_ad4b8ef500154da1a0dc19ef9535fd18b} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit13@{bit13}} +\Hypertarget{unionuint64___bit_type_def_ad4b8ef500154da1a0dc19ef9535fd18b}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit13@{bit13}} \index{bit13@{bit13}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit13}{bit13}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit13} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ad4b8ef500154da1a0dc19ef9535fd18b} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit13} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00105}{105}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a1ace2a9de437ba03fffcf0003e8a9922}\label{unionuint64___bit_type_def_a1ace2a9de437ba03fffcf0003e8a9922} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit14@{bit14}} +\Hypertarget{unionuint64___bit_type_def_a1ace2a9de437ba03fffcf0003e8a9922}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit14@{bit14}} \index{bit14@{bit14}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit14}{bit14}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit14} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a1ace2a9de437ba03fffcf0003e8a9922} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit14} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00105}{105}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a6a2318362ad7fe9eb0d8115f78a2b954}\label{unionuint64___bit_type_def_a6a2318362ad7fe9eb0d8115f78a2b954} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit15@{bit15}} +\Hypertarget{unionuint64___bit_type_def_a6a2318362ad7fe9eb0d8115f78a2b954}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit15@{bit15}} \index{bit15@{bit15}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit15}{bit15}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit15} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a6a2318362ad7fe9eb0d8115f78a2b954} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit15} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00105}{105}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a843c0a233cbb56277603b2af8c49799a}\label{unionuint64___bit_type_def_a843c0a233cbb56277603b2af8c49799a} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit16@{bit16}} +\Hypertarget{unionuint64___bit_type_def_a843c0a233cbb56277603b2af8c49799a}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit16@{bit16}} \index{bit16@{bit16}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit16}{bit16}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit16} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a843c0a233cbb56277603b2af8c49799a} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit16} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00106}{106}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ac5f4985df61854a2e4a459bee5049901}\label{unionuint64___bit_type_def_ac5f4985df61854a2e4a459bee5049901} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit17@{bit17}} +\Hypertarget{unionuint64___bit_type_def_ac5f4985df61854a2e4a459bee5049901}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit17@{bit17}} \index{bit17@{bit17}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit17}{bit17}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit17} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ac5f4985df61854a2e4a459bee5049901} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit17} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00106}{106}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_aedcddf700cf22c6ffa88a3cc35d3ca45}\label{unionuint64___bit_type_def_aedcddf700cf22c6ffa88a3cc35d3ca45} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit18@{bit18}} +\Hypertarget{unionuint64___bit_type_def_aedcddf700cf22c6ffa88a3cc35d3ca45}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit18@{bit18}} \index{bit18@{bit18}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit18}{bit18}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit18} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_aedcddf700cf22c6ffa88a3cc35d3ca45} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit18} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00106}{106}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_aa54f6e0b37d9a7ee270d60ab5fa99d96}\label{unionuint64___bit_type_def_aa54f6e0b37d9a7ee270d60ab5fa99d96} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit19@{bit19}} +\Hypertarget{unionuint64___bit_type_def_aa54f6e0b37d9a7ee270d60ab5fa99d96}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit19@{bit19}} \index{bit19@{bit19}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit19}{bit19}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit19} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_aa54f6e0b37d9a7ee270d60ab5fa99d96} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit19} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00106}{106}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_aa494c40e09d657938459fe033f9b4768}\label{unionuint64___bit_type_def_aa494c40e09d657938459fe033f9b4768} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit20@{bit20}} +\Hypertarget{unionuint64___bit_type_def_aa494c40e09d657938459fe033f9b4768}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit20@{bit20}} \index{bit20@{bit20}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit20}{bit20}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit20} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_aa494c40e09d657938459fe033f9b4768} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit20} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00107}{107}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a2bb5652539ba1be890e7a8e9106b1b13}\label{unionuint64___bit_type_def_a2bb5652539ba1be890e7a8e9106b1b13} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit21@{bit21}} +\Hypertarget{unionuint64___bit_type_def_a2bb5652539ba1be890e7a8e9106b1b13}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit21@{bit21}} \index{bit21@{bit21}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit21}{bit21}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit21} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a2bb5652539ba1be890e7a8e9106b1b13} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit21} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00107}{107}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_acdfa6e465a2ab178030d6e6602aace99}\label{unionuint64___bit_type_def_acdfa6e465a2ab178030d6e6602aace99} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit22@{bit22}} +\Hypertarget{unionuint64___bit_type_def_acdfa6e465a2ab178030d6e6602aace99}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit22@{bit22}} \index{bit22@{bit22}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit22}{bit22}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit22} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_acdfa6e465a2ab178030d6e6602aace99} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit22} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00107}{107}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_afe3bd10a6deca0fe61ab0ef5e8e4a20f}\label{unionuint64___bit_type_def_afe3bd10a6deca0fe61ab0ef5e8e4a20f} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit23@{bit23}} +\Hypertarget{unionuint64___bit_type_def_afe3bd10a6deca0fe61ab0ef5e8e4a20f}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit23@{bit23}} \index{bit23@{bit23}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit23}{bit23}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit23} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_afe3bd10a6deca0fe61ab0ef5e8e4a20f} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit23} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00107}{107}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_aae3e9b8317400c2d0b727dfa173d5ad2}\label{unionuint64___bit_type_def_aae3e9b8317400c2d0b727dfa173d5ad2} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit24@{bit24}} +\Hypertarget{unionuint64___bit_type_def_aae3e9b8317400c2d0b727dfa173d5ad2}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit24@{bit24}} \index{bit24@{bit24}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit24}{bit24}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit24} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_aae3e9b8317400c2d0b727dfa173d5ad2} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit24} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00108}{108}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a81b8ac661abfed6e2b58fdb615eb252a}\label{unionuint64___bit_type_def_a81b8ac661abfed6e2b58fdb615eb252a} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit25@{bit25}} +\Hypertarget{unionuint64___bit_type_def_a81b8ac661abfed6e2b58fdb615eb252a}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit25@{bit25}} \index{bit25@{bit25}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit25}{bit25}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit25} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a81b8ac661abfed6e2b58fdb615eb252a} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit25} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00108}{108}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_af3f19ae67c1f900e23daf8deda4324ef}\label{unionuint64___bit_type_def_af3f19ae67c1f900e23daf8deda4324ef} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit26@{bit26}} +\Hypertarget{unionuint64___bit_type_def_af3f19ae67c1f900e23daf8deda4324ef}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit26@{bit26}} \index{bit26@{bit26}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit26}{bit26}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit26} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_af3f19ae67c1f900e23daf8deda4324ef} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit26} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00108}{108}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ace71c1313eb20f6157e354125e85b644}\label{unionuint64___bit_type_def_ace71c1313eb20f6157e354125e85b644} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit27@{bit27}} +\Hypertarget{unionuint64___bit_type_def_ace71c1313eb20f6157e354125e85b644}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit27@{bit27}} \index{bit27@{bit27}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit27}{bit27}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit27} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ace71c1313eb20f6157e354125e85b644} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit27} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00108}{108}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a6691a7d235dedb6f8f2a3a285a987c0b}\label{unionuint64___bit_type_def_a6691a7d235dedb6f8f2a3a285a987c0b} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit28@{bit28}} +\Hypertarget{unionuint64___bit_type_def_a6691a7d235dedb6f8f2a3a285a987c0b}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit28@{bit28}} \index{bit28@{bit28}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit28}{bit28}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit28} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a6691a7d235dedb6f8f2a3a285a987c0b} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit28} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00109}{109}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a28b75958e1c0d1132e45c08a911b1c4b}\label{unionuint64___bit_type_def_a28b75958e1c0d1132e45c08a911b1c4b} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit29@{bit29}} +\Hypertarget{unionuint64___bit_type_def_a28b75958e1c0d1132e45c08a911b1c4b}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit29@{bit29}} \index{bit29@{bit29}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit29}{bit29}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit29} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a28b75958e1c0d1132e45c08a911b1c4b} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit29} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00109}{109}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a120ee09962960ef1c39d1710070a927a}\label{unionuint64___bit_type_def_a120ee09962960ef1c39d1710070a927a} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit30@{bit30}} +\Hypertarget{unionuint64___bit_type_def_a120ee09962960ef1c39d1710070a927a}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit30@{bit30}} \index{bit30@{bit30}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit30}{bit30}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit30} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a120ee09962960ef1c39d1710070a927a} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit30} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00109}{109}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a7daaf6b99ddcead17e00cad39d58c0ba}\label{unionuint64___bit_type_def_a7daaf6b99ddcead17e00cad39d58c0ba} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit31@{bit31}} +\Hypertarget{unionuint64___bit_type_def_a7daaf6b99ddcead17e00cad39d58c0ba}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit31@{bit31}} \index{bit31@{bit31}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit31}{bit31}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit31} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a7daaf6b99ddcead17e00cad39d58c0ba} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit31} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00109}{109}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a8c273132d8a04ec96ef2b81c4acdab40}\label{unionuint64___bit_type_def_a8c273132d8a04ec96ef2b81c4acdab40} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit32@{bit32}} +\Hypertarget{unionuint64___bit_type_def_a8c273132d8a04ec96ef2b81c4acdab40}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit32@{bit32}} \index{bit32@{bit32}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit32}{bit32}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit32} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a8c273132d8a04ec96ef2b81c4acdab40} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit32} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00110}{110}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a37884146acb266d93a1046cbb32e0754}\label{unionuint64___bit_type_def_a37884146acb266d93a1046cbb32e0754} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit33@{bit33}} +\Hypertarget{unionuint64___bit_type_def_a37884146acb266d93a1046cbb32e0754}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit33@{bit33}} \index{bit33@{bit33}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit33}{bit33}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit33} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a37884146acb266d93a1046cbb32e0754} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit33} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00110}{110}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a317a774edf3fc9f8c5f0bab49ac7e3ea}\label{unionuint64___bit_type_def_a317a774edf3fc9f8c5f0bab49ac7e3ea} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit34@{bit34}} +\Hypertarget{unionuint64___bit_type_def_a317a774edf3fc9f8c5f0bab49ac7e3ea}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit34@{bit34}} \index{bit34@{bit34}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit34}{bit34}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit34} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a317a774edf3fc9f8c5f0bab49ac7e3ea} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit34} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00110}{110}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ad07bade9d4ce904b8822dbf507c7c695}\label{unionuint64___bit_type_def_ad07bade9d4ce904b8822dbf507c7c695} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit35@{bit35}} +\Hypertarget{unionuint64___bit_type_def_ad07bade9d4ce904b8822dbf507c7c695}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit35@{bit35}} \index{bit35@{bit35}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit35}{bit35}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit35} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ad07bade9d4ce904b8822dbf507c7c695} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit35} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00110}{110}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a14afca8c10e4abcbaf4740e308b8791a}\label{unionuint64___bit_type_def_a14afca8c10e4abcbaf4740e308b8791a} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit36@{bit36}} +\Hypertarget{unionuint64___bit_type_def_a14afca8c10e4abcbaf4740e308b8791a}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit36@{bit36}} \index{bit36@{bit36}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit36}{bit36}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit36} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a14afca8c10e4abcbaf4740e308b8791a} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit36} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00111}{111}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a8796b96d250307eaefb78eeea59e30ed}\label{unionuint64___bit_type_def_a8796b96d250307eaefb78eeea59e30ed} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit37@{bit37}} +\Hypertarget{unionuint64___bit_type_def_a8796b96d250307eaefb78eeea59e30ed}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit37@{bit37}} \index{bit37@{bit37}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit37}{bit37}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit37} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a8796b96d250307eaefb78eeea59e30ed} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit37} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00111}{111}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a297a35fbb4c94c193f578ac20522b589}\label{unionuint64___bit_type_def_a297a35fbb4c94c193f578ac20522b589} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit38@{bit38}} +\Hypertarget{unionuint64___bit_type_def_a297a35fbb4c94c193f578ac20522b589}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit38@{bit38}} \index{bit38@{bit38}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit38}{bit38}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit38} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a297a35fbb4c94c193f578ac20522b589} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit38} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00111}{111}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a2d85e07f1127e67e02a3fb9b17cec87f}\label{unionuint64___bit_type_def_a2d85e07f1127e67e02a3fb9b17cec87f} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit39@{bit39}} +\Hypertarget{unionuint64___bit_type_def_a2d85e07f1127e67e02a3fb9b17cec87f}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit39@{bit39}} \index{bit39@{bit39}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit39}{bit39}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit39} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a2d85e07f1127e67e02a3fb9b17cec87f} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit39} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00111}{111}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a094fd073860f380f8d1881ae313864a2}\label{unionuint64___bit_type_def_a094fd073860f380f8d1881ae313864a2} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit40@{bit40}} +\Hypertarget{unionuint64___bit_type_def_a094fd073860f380f8d1881ae313864a2}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit40@{bit40}} \index{bit40@{bit40}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit40}{bit40}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit40} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a094fd073860f380f8d1881ae313864a2} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit40} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00112}{112}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a72f0b4f624bef10dc2deb8661fb7da4b}\label{unionuint64___bit_type_def_a72f0b4f624bef10dc2deb8661fb7da4b} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit41@{bit41}} +\Hypertarget{unionuint64___bit_type_def_a72f0b4f624bef10dc2deb8661fb7da4b}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit41@{bit41}} \index{bit41@{bit41}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit41}{bit41}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit41} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a72f0b4f624bef10dc2deb8661fb7da4b} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit41} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00112}{112}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ab70b7c38e6cc4d117e5b21e63718eed9}\label{unionuint64___bit_type_def_ab70b7c38e6cc4d117e5b21e63718eed9} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit42@{bit42}} +\Hypertarget{unionuint64___bit_type_def_ab70b7c38e6cc4d117e5b21e63718eed9}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit42@{bit42}} \index{bit42@{bit42}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit42}{bit42}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit42} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ab70b7c38e6cc4d117e5b21e63718eed9} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit42} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00112}{112}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ac33764c0c04dd15ec3643343ebbf2437}\label{unionuint64___bit_type_def_ac33764c0c04dd15ec3643343ebbf2437} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit43@{bit43}} +\Hypertarget{unionuint64___bit_type_def_ac33764c0c04dd15ec3643343ebbf2437}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit43@{bit43}} \index{bit43@{bit43}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit43}{bit43}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit43} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ac33764c0c04dd15ec3643343ebbf2437} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit43} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00112}{112}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a1d3c44deb4caaf002d77c50dbc0a03e2}\label{unionuint64___bit_type_def_a1d3c44deb4caaf002d77c50dbc0a03e2} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit44@{bit44}} +\Hypertarget{unionuint64___bit_type_def_a1d3c44deb4caaf002d77c50dbc0a03e2}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit44@{bit44}} \index{bit44@{bit44}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit44}{bit44}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit44} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a1d3c44deb4caaf002d77c50dbc0a03e2} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit44} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00113}{113}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ad00ed97ae560ea4db6b8ee15b1c8ab7d}\label{unionuint64___bit_type_def_ad00ed97ae560ea4db6b8ee15b1c8ab7d} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit45@{bit45}} +\Hypertarget{unionuint64___bit_type_def_ad00ed97ae560ea4db6b8ee15b1c8ab7d}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit45@{bit45}} \index{bit45@{bit45}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit45}{bit45}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit45} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ad00ed97ae560ea4db6b8ee15b1c8ab7d} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit45} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00113}{113}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_adcfbd33fd8d3e555093f10d12e4e30bd}\label{unionuint64___bit_type_def_adcfbd33fd8d3e555093f10d12e4e30bd} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit46@{bit46}} +\Hypertarget{unionuint64___bit_type_def_adcfbd33fd8d3e555093f10d12e4e30bd}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit46@{bit46}} \index{bit46@{bit46}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit46}{bit46}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit46} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_adcfbd33fd8d3e555093f10d12e4e30bd} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit46} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00113}{113}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a31c74e216efa115cf210a28543250092}\label{unionuint64___bit_type_def_a31c74e216efa115cf210a28543250092} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit47@{bit47}} +\Hypertarget{unionuint64___bit_type_def_a31c74e216efa115cf210a28543250092}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit47@{bit47}} \index{bit47@{bit47}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit47}{bit47}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit47} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a31c74e216efa115cf210a28543250092} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit47} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00113}{113}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a5785ec5ef50cea4f9893e3b36687d8c3}\label{unionuint64___bit_type_def_a5785ec5ef50cea4f9893e3b36687d8c3} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit48@{bit48}} +\Hypertarget{unionuint64___bit_type_def_a5785ec5ef50cea4f9893e3b36687d8c3}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit48@{bit48}} \index{bit48@{bit48}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit48}{bit48}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit48} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a5785ec5ef50cea4f9893e3b36687d8c3} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit48} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00114}{114}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a7a73d551df00a67ffa9d9ce9ae5a66b2}\label{unionuint64___bit_type_def_a7a73d551df00a67ffa9d9ce9ae5a66b2} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit49@{bit49}} +\Hypertarget{unionuint64___bit_type_def_a7a73d551df00a67ffa9d9ce9ae5a66b2}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit49@{bit49}} \index{bit49@{bit49}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit49}{bit49}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit49} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a7a73d551df00a67ffa9d9ce9ae5a66b2} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit49} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00114}{114}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a38c4154dde7a42789a799283565ea259}\label{unionuint64___bit_type_def_a38c4154dde7a42789a799283565ea259} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit50@{bit50}} +\Hypertarget{unionuint64___bit_type_def_a38c4154dde7a42789a799283565ea259}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit50@{bit50}} \index{bit50@{bit50}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit50}{bit50}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit50} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a38c4154dde7a42789a799283565ea259} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit50} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00114}{114}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_aea9978fdeedb0b8653633e5c5ceda200}\label{unionuint64___bit_type_def_aea9978fdeedb0b8653633e5c5ceda200} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit51@{bit51}} +\Hypertarget{unionuint64___bit_type_def_aea9978fdeedb0b8653633e5c5ceda200}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit51@{bit51}} \index{bit51@{bit51}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit51}{bit51}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit51} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_aea9978fdeedb0b8653633e5c5ceda200} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit51} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00114}{114}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a4cef515450f79794b217673872204e74}\label{unionuint64___bit_type_def_a4cef515450f79794b217673872204e74} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit52@{bit52}} +\Hypertarget{unionuint64___bit_type_def_a4cef515450f79794b217673872204e74}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit52@{bit52}} \index{bit52@{bit52}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit52}{bit52}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit52} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a4cef515450f79794b217673872204e74} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit52} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00115}{115}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_af6b445f558b5c1e6ea2f47b7fb8d82ba}\label{unionuint64___bit_type_def_af6b445f558b5c1e6ea2f47b7fb8d82ba} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit53@{bit53}} +\Hypertarget{unionuint64___bit_type_def_af6b445f558b5c1e6ea2f47b7fb8d82ba}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit53@{bit53}} \index{bit53@{bit53}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit53}{bit53}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit53} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_af6b445f558b5c1e6ea2f47b7fb8d82ba} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit53} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00115}{115}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ae133f0a428da163fe266a4ef11f7b772}\label{unionuint64___bit_type_def_ae133f0a428da163fe266a4ef11f7b772} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit54@{bit54}} +\Hypertarget{unionuint64___bit_type_def_ae133f0a428da163fe266a4ef11f7b772}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit54@{bit54}} \index{bit54@{bit54}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit54}{bit54}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit54} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ae133f0a428da163fe266a4ef11f7b772} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit54} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00115}{115}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a7cac784c45e82916a2dc3d98728e6d51}\label{unionuint64___bit_type_def_a7cac784c45e82916a2dc3d98728e6d51} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit55@{bit55}} +\Hypertarget{unionuint64___bit_type_def_a7cac784c45e82916a2dc3d98728e6d51}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit55@{bit55}} \index{bit55@{bit55}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit55}{bit55}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit55} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a7cac784c45e82916a2dc3d98728e6d51} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit55} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00115}{115}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a0b592c9e73b61ee134b894e4c57baaa1}\label{unionuint64___bit_type_def_a0b592c9e73b61ee134b894e4c57baaa1} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit56@{bit56}} +\Hypertarget{unionuint64___bit_type_def_a0b592c9e73b61ee134b894e4c57baaa1}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit56@{bit56}} \index{bit56@{bit56}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit56}{bit56}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit56} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a0b592c9e73b61ee134b894e4c57baaa1} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit56} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00116}{116}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a7fad0ef8a3759fb94623f797dc0a28cd}\label{unionuint64___bit_type_def_a7fad0ef8a3759fb94623f797dc0a28cd} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit57@{bit57}} +\Hypertarget{unionuint64___bit_type_def_a7fad0ef8a3759fb94623f797dc0a28cd}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit57@{bit57}} \index{bit57@{bit57}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit57}{bit57}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit57} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a7fad0ef8a3759fb94623f797dc0a28cd} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit57} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00116}{116}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_adf6d53faede2611a9cfd87c96887f785}\label{unionuint64___bit_type_def_adf6d53faede2611a9cfd87c96887f785} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit58@{bit58}} +\Hypertarget{unionuint64___bit_type_def_adf6d53faede2611a9cfd87c96887f785}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit58@{bit58}} \index{bit58@{bit58}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit58}{bit58}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit58} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_adf6d53faede2611a9cfd87c96887f785} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit58} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00116}{116}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_aed5c6e4bf5e5d5062d4619165f53e21e}\label{unionuint64___bit_type_def_aed5c6e4bf5e5d5062d4619165f53e21e} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit59@{bit59}} +\Hypertarget{unionuint64___bit_type_def_aed5c6e4bf5e5d5062d4619165f53e21e}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit59@{bit59}} \index{bit59@{bit59}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit59}{bit59}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit59} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_aed5c6e4bf5e5d5062d4619165f53e21e} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit59} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00116}{116}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ac32cd60facac9c1ab19d47c29324525e}\label{unionuint64___bit_type_def_ac32cd60facac9c1ab19d47c29324525e} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit60@{bit60}} +\Hypertarget{unionuint64___bit_type_def_ac32cd60facac9c1ab19d47c29324525e}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit60@{bit60}} \index{bit60@{bit60}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit60}{bit60}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit60} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ac32cd60facac9c1ab19d47c29324525e} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit60} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00117}{117}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ace649ce26ab7885f2d988d9842c72466}\label{unionuint64___bit_type_def_ace649ce26ab7885f2d988d9842c72466} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit61@{bit61}} +\Hypertarget{unionuint64___bit_type_def_ace649ce26ab7885f2d988d9842c72466}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit61@{bit61}} \index{bit61@{bit61}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit61}{bit61}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit61} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ace649ce26ab7885f2d988d9842c72466} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit61} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00117}{117}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_a95f5a66dae374905c9e4c6779451c96e}\label{unionuint64___bit_type_def_a95f5a66dae374905c9e4c6779451c96e} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit62@{bit62}} +\Hypertarget{unionuint64___bit_type_def_a95f5a66dae374905c9e4c6779451c96e}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit62@{bit62}} \index{bit62@{bit62}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit62}{bit62}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit62} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_a95f5a66dae374905c9e4c6779451c96e} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit62} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00117}{117}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint64___bit_type_def_ad61034647ebdb14089dbcb9cc9cd0f51}\label{unionuint64___bit_type_def_ad61034647ebdb14089dbcb9cc9cd0f51} -\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit63@{bit63}} +\Hypertarget{unionuint64___bit_type_def_ad61034647ebdb14089dbcb9cc9cd0f51}\index{uint64\_BitTypeDef@{uint64\_BitTypeDef}!bit63@{bit63}} \index{bit63@{bit63}!uint64\_BitTypeDef@{uint64\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit63}{bit63}} -{\footnotesize\ttfamily unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit63} +{\footnotesize\ttfamily \label{unionuint64___bit_type_def_ad61034647ebdb14089dbcb9cc9cd0f51} +unsigned uint64\+\_\+\+Bit\+Type\+Def\+::bit63} @@ -740,4 +742,4 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00117}{117}} of file The documentation for this union was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}}\end{DoxyCompactItemize} diff --git a/Doc/latex/unionuint8___bit_type_def.tex b/Doc/latex/unionuint8___bit_type_def.tex index 34f9424..d369e58 100644 --- a/Doc/latex/unionuint8___bit_type_def.tex +++ b/Doc/latex/unionuint8___bit_type_def.tex @@ -5,7 +5,7 @@ \item uint8\+\_\+t \mbox{\hyperlink{unionuint8___bit_type_def_aacf75bef7d0b9ed458e03a4278f5fe88}{all}} \item -\Hypertarget{unionuint8___bit_type_def_a06339e6cbac8350c26b153d573e9c1df}\label{unionuint8___bit_type_def_a06339e6cbac8350c26b153d573e9c1df} +\Hypertarget{unionuint8___bit_type_def_aebe07b71261a8c24d23c63637d506f91}\label{unionuint8___bit_type_def_aebe07b71261a8c24d23c63637d506f91} \begin{tabbing} xx\=xx\=xx\=xx\=xx\=xx\=xx\=xx\=xx\=\kill struct \{\\ @@ -29,92 +29,94 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00039}{39}} of file \ +\label{doc-variable-members} +\Hypertarget{unionuint8___bit_type_def_doc-variable-members} \doxysubsection{Member Data Documentation} -\Hypertarget{unionuint8___bit_type_def_aacf75bef7d0b9ed458e03a4278f5fe88}\label{unionuint8___bit_type_def_aacf75bef7d0b9ed458e03a4278f5fe88} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!all@{all}} +\Hypertarget{unionuint8___bit_type_def_aacf75bef7d0b9ed458e03a4278f5fe88}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!all@{all}} \index{all@{all}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{all}{all}} -{\footnotesize\ttfamily uint8\+\_\+t uint8\+\_\+\+Bit\+Type\+Def\+::all} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_aacf75bef7d0b9ed458e03a4278f5fe88} +uint8\+\_\+t uint8\+\_\+\+Bit\+Type\+Def\+::all} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00041}{41}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint8___bit_type_def_a3748bf8d6ebfdce0895b1f4e704746d9}\label{unionuint8___bit_type_def_a3748bf8d6ebfdce0895b1f4e704746d9} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit0@{bit0}} +\Hypertarget{unionuint8___bit_type_def_a3748bf8d6ebfdce0895b1f4e704746d9}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit0@{bit0}} \index{bit0@{bit0}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit0}{bit0}} -{\footnotesize\ttfamily unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit0} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_a3748bf8d6ebfdce0895b1f4e704746d9} +unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit0} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00044}{44}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint8___bit_type_def_a8794ff2357a3b7d52e7afa3b5a7de99a}\label{unionuint8___bit_type_def_a8794ff2357a3b7d52e7afa3b5a7de99a} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit1@{bit1}} +\Hypertarget{unionuint8___bit_type_def_a8794ff2357a3b7d52e7afa3b5a7de99a}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit1@{bit1}} \index{bit1@{bit1}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit1}{bit1}} -{\footnotesize\ttfamily unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit1} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_a8794ff2357a3b7d52e7afa3b5a7de99a} +unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit1} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00045}{45}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint8___bit_type_def_a892712177c44aabdc16d3241dfc99db9}\label{unionuint8___bit_type_def_a892712177c44aabdc16d3241dfc99db9} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit2@{bit2}} +\Hypertarget{unionuint8___bit_type_def_a892712177c44aabdc16d3241dfc99db9}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit2@{bit2}} \index{bit2@{bit2}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit2}{bit2}} -{\footnotesize\ttfamily unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit2} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_a892712177c44aabdc16d3241dfc99db9} +unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit2} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00046}{46}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint8___bit_type_def_a3c83a9aa064121feff3b6cb97c1dc543}\label{unionuint8___bit_type_def_a3c83a9aa064121feff3b6cb97c1dc543} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit3@{bit3}} +\Hypertarget{unionuint8___bit_type_def_a3c83a9aa064121feff3b6cb97c1dc543}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit3@{bit3}} \index{bit3@{bit3}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit3}{bit3}} -{\footnotesize\ttfamily unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit3} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_a3c83a9aa064121feff3b6cb97c1dc543} +unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit3} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00047}{47}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint8___bit_type_def_af5a2b4b6c4e408d985671b2543eee037}\label{unionuint8___bit_type_def_af5a2b4b6c4e408d985671b2543eee037} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit4@{bit4}} +\Hypertarget{unionuint8___bit_type_def_af5a2b4b6c4e408d985671b2543eee037}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit4@{bit4}} \index{bit4@{bit4}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit4}{bit4}} -{\footnotesize\ttfamily unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit4} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_af5a2b4b6c4e408d985671b2543eee037} +unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit4} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00048}{48}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint8___bit_type_def_abbbf81339876997dded91b86237eba01}\label{unionuint8___bit_type_def_abbbf81339876997dded91b86237eba01} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit5@{bit5}} +\Hypertarget{unionuint8___bit_type_def_abbbf81339876997dded91b86237eba01}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit5@{bit5}} \index{bit5@{bit5}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit5}{bit5}} -{\footnotesize\ttfamily unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit5} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_abbbf81339876997dded91b86237eba01} +unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit5} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00049}{49}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint8___bit_type_def_afba4a1642a44bd86c9535a32ccf54004}\label{unionuint8___bit_type_def_afba4a1642a44bd86c9535a32ccf54004} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit6@{bit6}} +\Hypertarget{unionuint8___bit_type_def_afba4a1642a44bd86c9535a32ccf54004}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit6@{bit6}} \index{bit6@{bit6}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit6}{bit6}} -{\footnotesize\ttfamily unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit6} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_afba4a1642a44bd86c9535a32ccf54004} +unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit6} Definition at line \mbox{\hyperlink{bit__access_8h_source_l00050}{50}} of file \mbox{\hyperlink{bit__access_8h_source}{bit\+\_\+access.\+h}}. -\Hypertarget{unionuint8___bit_type_def_ad1ca71ae4b18042a6c305cd84b749810}\label{unionuint8___bit_type_def_ad1ca71ae4b18042a6c305cd84b749810} -\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit7@{bit7}} +\Hypertarget{unionuint8___bit_type_def_ad1ca71ae4b18042a6c305cd84b749810}\index{uint8\_BitTypeDef@{uint8\_BitTypeDef}!bit7@{bit7}} \index{bit7@{bit7}!uint8\_BitTypeDef@{uint8\_BitTypeDef}} \doxysubsubsection{\texorpdfstring{bit7}{bit7}} -{\footnotesize\ttfamily unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit7} +{\footnotesize\ttfamily \label{unionuint8___bit_type_def_ad1ca71ae4b18042a6c305cd84b749810} +unsigned uint8\+\_\+\+Bit\+Type\+Def\+::bit7} @@ -124,4 +126,4 @@ Definition at line \mbox{\hyperlink{bit__access_8h_source_l00051}{51}} of file \ The documentation for this union was generated from the following file\+:\begin{DoxyCompactItemize} \item -F\+:/\+Work/\+Projects/\+STM/.\+Elementary/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}}\end{DoxyCompactItemize} +E\+:/.\+WORK/\+STM32/\+STM32\+\_\+\+Extended\+Libs/\+My\+Libs\+General/\+Inc/\mbox{\hyperlink{bit__access_8h}{bit\+\_\+access.\+h}}\end{DoxyCompactItemize} diff --git a/MyLibsGeneral/Inc/__general_flash.h b/MyLibsGeneral/Inc/__general_flash.h new file mode 100644 index 0000000..9a532e5 --- /dev/null +++ b/MyLibsGeneral/Inc/__general_flash.h @@ -0,0 +1,44 @@ +/************************************************************************** +* @file general_flash.h +* @brief Заголовочны файл модуля работы с FLASH. +*************************************************************************/ +#ifndef __FLASH_GENERAL_H_ +#define __FLASH_GENERAL_H_ + +////////////////////////////////////////////////////////////////////// +/////////////////////////---USER SETTINGS---///////////////////////// + + +/////////////////////////---USER SETTINGS---///////////////////////// +#include "mylibs_defs.h" + + + +///////////////////////////////////////////////////////////////////// +////////////////////////////---DEFINES---//////////////////////////// + +////////////////////////////---DEFINES---//////////////////////////// + + +///////////////////////////////////////////////////////////////////// +///////////////////////---STRUCTURES & ENUMS---////////////////////// + +///////////////////////---STRUCTURES & ENUMS---////////////////////// + + +///////////////////////////////////////////////////////////////////// +///////////////////////////---FUNCTIONS---/////////////////////////// + +HAL_StatusTypeDef FLASH_Enable_DualBankMode(void); +HAL_StatusTypeDef FLASH_WriteProtection(uint32_t BankN, uint32_t WriteProtection); +/* functions for reading bytes/halswords/words */ +uint8_t FLASH_Read_Byte(uint32_t add); +uint16_t FLASH_Read_HalfWord(uint32_t add); +uint32_t FLASH_Read_Word(uint32_t add); +/* functions for writing bytes/halswords/words */ +HAL_StatusTypeDef FLASH_Write_Byte(uint32_t Address, uint8_t Data); +HAL_StatusTypeDef FLASH_Write_HalfWord(uint32_t Address, uint16_t Data); +HAL_StatusTypeDef FLASH_Write_Word(uint32_t Address, uint32_t Data); +///////////////////////////---FUNCTIONS---/////////////////////////// + +#endif // __FLASH_GENERAL_H_ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/bit_access.h b/MyLibsGeneral/Inc/bit_access.h new file mode 100644 index 0000000..fe824cd --- /dev/null +++ b/MyLibsGeneral/Inc/bit_access.h @@ -0,0 +1,159 @@ +/** +************************************************************************** +* @file bit_access.h +* @brief Заголочный файл для дефайнов битового доступа. +************************************************************************** +* @defgroup BIT_ACCESS_DEFINES Bit access defines +* @ingroup MYLIBS_DEFINES +* @brief Макросы и typedef'ы для работы с битами в unsigned типах. +* @details +В этом файле определены макросы для получения значения конкретного бита^ +- @ref uint8_bit +- @ref uint16_bit +- @ref uint32_bit +- @ref uint64_bit + +Особенности использования: +- Индекс бита должен быть **константой на этапе компиляции**. + Пример верного использования: + @code + uint8_t val = 0x05; + uint8_t b2 = uint8_bit(val, 2); // Получить бит 2 + uint8_bit(val, 6) = 1; // Записать бит 6 + @endcode +- Нельзя использовать переменные в качестве индекса: + @code + uint8_t i = 2; + uint8_bit(val, i); // Не сработает! + @endcode +- Макросы возвращают 0 или 1. +- Доступ реализован через приведение к `union` с битовыми полями, поэтому это + безопасный способ работы с отдельными битами без ручного сдвига и маскирования. +* @{ +*************************************************************************/ +#ifndef __BIT_ACCESS_H_ +#define __BIT_ACCESS_H_ +#include "mylibs_defs.h" + + +typedef union +{ + uint8_t all; + struct + { + unsigned bit0:1; + unsigned bit1:1; + unsigned bit2:1; + unsigned bit3:1; + unsigned bit4:1; + unsigned bit5:1; + unsigned bit6:1; + unsigned bit7:1; + }bit; +}uint8_BitTypeDef; + +typedef union +{ + uint16_t all; + struct + { + unsigned bit0:1; + unsigned bit1:1; + unsigned bit2:1; + unsigned bit3:1; + unsigned bit4:1; + unsigned bit5:1; + unsigned bit6:1; + unsigned bit7:1; + unsigned bit8:1; + unsigned bit9:1; + unsigned bit10:1; + unsigned bit11:1; + unsigned bit12:1; + unsigned bit13:1; + unsigned bit14:1; + unsigned bit15:1; + }bit; +}uint16_BitTypeDef; + + +typedef union +{ + uint32_t all; + struct + { + unsigned bit0:1; unsigned bit1:1; unsigned bit2:1; unsigned bit3:1; + unsigned bit4:1; unsigned bit5:1; unsigned bit6:1; unsigned bit7:1; + unsigned bit8:1; unsigned bit9:1; unsigned bit10:1; unsigned bit11:1; + unsigned bit12:1; unsigned bit13:1; unsigned bit14:1; unsigned bit15:1; + unsigned bit16:1; unsigned bit17:1; unsigned bit18:1; unsigned bit19:1; + unsigned bit20:1; unsigned bit21:1; unsigned bit22:1; unsigned bit23:1; + unsigned bit24:1; unsigned bit25:1; unsigned bit26:1; unsigned bit27:1; + unsigned bit28:1; unsigned bit29:1; unsigned bit30:1; unsigned bit31:1; + }bit; +}uint32_BitTypeDef; + + +typedef union +{ + uint64_t all; + struct + { + unsigned bit0:1; unsigned bit1:1; unsigned bit2:1; unsigned bit3:1; + unsigned bit4:1; unsigned bit5:1; unsigned bit6:1; unsigned bit7:1; + unsigned bit8:1; unsigned bit9:1; unsigned bit10:1; unsigned bit11:1; + unsigned bit12:1; unsigned bit13:1; unsigned bit14:1; unsigned bit15:1; + unsigned bit16:1; unsigned bit17:1; unsigned bit18:1; unsigned bit19:1; + unsigned bit20:1; unsigned bit21:1; unsigned bit22:1; unsigned bit23:1; + unsigned bit24:1; unsigned bit25:1; unsigned bit26:1; unsigned bit27:1; + unsigned bit28:1; unsigned bit29:1; unsigned bit30:1; unsigned bit31:1; + unsigned bit32:1; unsigned bit33:1; unsigned bit34:1; unsigned bit35:1; + unsigned bit36:1; unsigned bit37:1; unsigned bit38:1; unsigned bit39:1; + unsigned bit40:1; unsigned bit41:1; unsigned bit42:1; unsigned bit43:1; + unsigned bit44:1; unsigned bit45:1; unsigned bit46:1; unsigned bit47:1; + unsigned bit48:1; unsigned bit49:1; unsigned bit50:1; unsigned bit51:1; + unsigned bit52:1; unsigned bit53:1; unsigned bit54:1; unsigned bit55:1; + unsigned bit56:1; unsigned bit57:1; unsigned bit58:1; unsigned bit59:1; + unsigned bit60:1; unsigned bit61:1; unsigned bit62:1; unsigned bit63:1; + }bit; +}uint64_BitTypeDef; + + +/** + * @brief Получить n-й бит из uint8_t + * @param _uint8_ Переменная типа uint8_t + * @param _bit_ Константный номер бита (0..7) + * @return Значение выбранного бита (0 или 1) + * @note Индекс бита должен быть известен на этапе компиляции! + */ +#define uint8_bit(_uint8_, _bit_) (*(uint8_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_ +/** + * @brief Получить n-й бит из uint16_t + * @param _uint16_ Переменная типа uint16_t + * @param _bit_ Константный номер бита (0..15) + * @return Значение выбранного бита (0 или 1) + * @note Индекс бита должен быть известен на этапе компиляции! + */ +#define uint16_bit(_uint8_, _bit_) (*(uint16_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_ +/** + * @brief Получить n-й бит из uint32_t + * @param _uint32_ Переменная типа uint32_t + * @param _bit_ Константный номер бита (0..31) + * @return Значение выбранного бита (0 или 1) + * @note Индекс бита должен быть известен на этапе компиляции! + */ +#define uint32_bit(_uint8_, _bit_) (*(uint32_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_ +/** + * @brief Получить n-й бит из uint64_t + * @param _uint64_ Переменная типа uint64_t + * @param _bit_ Константный номер бита (0..63) + * @return Значение выбранного бита (0 или 1) + * @note Индекс бита должен быть известен на этапе компиляции! + */ +#define uint64_bit(_uint8_, _bit_) (*(uint64_BitTypeDef *)(&(_uint8_))).bit.bit##_bit_ + +#endif //__BIT_ACCESS_H_ + +/** BIT_ACCESS_DEFINES + * @} + */ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/evolve_optimizer.h b/MyLibsGeneral/Inc/evolve_optimizer.h new file mode 100644 index 0000000..7d4de0f --- /dev/null +++ b/MyLibsGeneral/Inc/evolve_optimizer.h @@ -0,0 +1,338 @@ +/** +****************************************************************************** +* @file evolve_optimizer.h +* @brief Заголовочный файл для адаптивного подбора параметров +****************************************************************************** +* @addtogroup EVOLVE_OPTIMIZER Evolve optimizer +* @ingroup MYLIBS_DEFINES +* @brief Библиотека для эволюционного подбора параметров +* @details +Поддерживает: +- Любое количество параметров +- Генерацию новых параметров на основе лучших кандидатов +- Мутацию для поиска оптимальных параметров +- Несколько независимых оптимизаторов в одной программе + + +Параметры для конфигурации: +- @ref ENABLE_EVOLVE_OPTIMIZATION - Включить оптимизацию параметров + Если библиотека отключена @ref ENABLE_EVOLVE_OPTIMIZATION, то вставляются + заглушки, никак не влияющие на параметры и остальную программу +- @ref EVOLVE_MAX_PARAMS - Максимальное количество параметров +- @ref EVOLVE_MAX_CANDIDATES - Максимальное количество кандидатов для обучения +- (опционально) @ref EVOLVE_MUTATION_MIN_PCT - Минимальная мутация в процентах от Loss (по умолчанию 10%) +- (опционально) @ref EVOLVE_MUTATION_MAX_PCT - Максимальная мутация в процентах от Loss (по умолчанию 100%) +- (опционально) @ref ELOVLE_N_ELITE_CANDIDATE - Количество кандидатов, которые проходят в поколение без изменений + +@par Пример использования: +@code +#include "evolve_optimizer.h" +#define N_PARAMS 4 +#define N_CANDIDATES 100 +#define N_BEST 10 +#define MUTATION 0.1f +float params[N_PARAMS]; +EvolveOptimizer_t optimizer; + +// Формирование параметров +uint16_t param_u16 = 800; +float param_f = 0.01f; +uint8_t param_u8 = 40; +int16_t param_i16 = 1600; +params[0] = PARAM_SCALE(param_u16, 0.0f, 1000.0f); +params[1] = PARAM_SCALE(param_f, 0.001f, 0.1f); +params[2] = PARAM_SCALE(param_u8, 10.0f, 100.0f); +params[3] = PARAM_SCALE(param_i16, 500.0f, 5000.0f); + +// Инициалиазция +EvolveOptimizer_Init(&optimizer, N_PARAMS, N_CANDIDATES, N_BEST, MUTATION, params); + +// Шаг эволюции +float loss = calc_loss(); // расчет эффективности параметров (от 0 до 1) +EvolveOptimizer_Step(&optimizer, params, loss); + +// Взятие следующих для эволюции параметров +param_u16 = PARAM_UNSCALE(params[0], 0.0f, 1000.0f); +param_f = PARAM_UNSCALE(params[1], 0.001f, 0.1f); +param_u8 = PARAM_UNSCALE(params[2], 10.0f, 100.0f); +param_i16 = PARAM_UNSCALE(params[3], 500.0f, 5000.0f); +@endcode +* @{ +*****************************************************************************/ +#ifndef __EVOLVE_OPTIMIZER_H_ +#define __EVOLVE_OPTIMIZER_H_ + +#include "mylibs_defs.h" +#include +#include + +#ifdef ENABLE_EVOLVE_OPTIMIZATION +/** + * @brief Линейное масштабирование x из диапазона [min_val, max_val] в диапазон [0, 1) + */ +#define PARAM_SCALE(x, min_val, max_val) \ +(((float)(x) - (float)(min_val)) / ((float)(max_val) - (float)(min_val))) + +/** + * @brief Обратное линейное масштабирование значения из [0, 1) в диапазон [min_val, max_val] + */ +#define PARAM_UNSCALE(val, min_val, max_val) \ +(((float)(val)) * ((float)(max_val) - (float)(min_val)) + (float)(min_val)) + +#ifndef local_time +#define local_time() HAL_GetTick() ///< Локальное время +#endif + + + +#ifndef EVOLVE_MUTATION_MIN_PCT +#define EVOLVE_MUTATION_MIN_PCT 10 ///< Минимальная мутация (в процентах от Loss) +#endif +#ifndef EVOLVE_MUTATION_MAX_PCT +#define EVOLVE_MUTATION_MAX_PCT 100 ///< Максимальная мутация (в процентах от Loss) +#endif +#ifndef ELOVLE_N_ELITE_CANDIDATE +#define ELOVLE_N_ELITE_CANDIDATE 2 ///< Количество кандидатов, которые проходят в поколение без изменений (по умолчанию 2) +#endif + + +/** + * @brief Структура эволюционного оптимизатора + */ +typedef struct { + float stability; ///< Коэффициент насколько стабильная популяция (0..1)(@ref n_cand) + + uint16_t n_params; ///< Количество параметров + uint16_t n_cand; ///< Количество кандидатов в популяции + uint16_t n_best; ///< Количество лучших, усредняемых + float mutation_amp; ///< Амплитуда мутации (0..1) + + uint16_t cand_index; ///< Индекс кандидата для обработки + uint16_t gen_index; ///< Индекс популяции + + //INTERNAL + float gen_mut; ///< Амплитуда мутации у текущей популяции + + float loss[EVOLVE_MAX_CANDIDATES]; ///< Loss для каждого кандидата + float candidates[EVOLVE_MAX_CANDIDATES][EVOLVE_MAX_PARAMS]; ///< Параметры кандидатов + uint16_t sorted_idx[EVOLVE_MAX_CANDIDATES]; ///< Индексы отсортированных кандидатов +} EvolveOptimizer_t; + + + +/** + * @cond EVOLVE_INTERNAL + */ + +// Вспомогательный указатель для сортировки +static EvolveOptimizer_t *g_sort_opt; // глобальный указатель на текущий оптимизатор + +// функция условия сортировки +static int cmp_idx(const void *a, const void *b) { + if (g_sort_opt->loss[*(const uint16_t*)a] < g_sort_opt->loss[*(const uint16_t*)b]) + return -1; + if (g_sort_opt->loss[*(const uint16_t*)a] > g_sort_opt->loss[*(const uint16_t*)b]) + return 1; + return 0; +} +/** @endcond */ + + + + + +/** + * @brief Инициализация эволюционного оптимизатора. + * @param opt Указатель на структуру оптимизатора + * @param n_params Количество параметров в одном кандидате + * @param n_cand Количество кандидатов + * @param n_best Количество лучших, усредняемых + * @param mutation_amp Амплитуда мутации (в диапазоне 0.0–1.0) + * @param start_params Начальные параметры (в диапазоне 0.0–1.0) + * @return 0 — если окей, + * -1 — если ошибка + */ +__STATIC_INLINE int EvolveOptimizer_Init(EvolveOptimizer_t* opt, + uint16_t n_params, + uint16_t n_cand, + uint16_t n_best, + float mutation_amp, + float* start_params) +{ + if((opt == NULL) || (start_params == NULL)) + return -1; + + if(n_params > EVOLVE_MAX_PARAMS) + return -1; + opt->n_params = n_params; + + if(n_cand > EVOLVE_MAX_CANDIDATES) + return -1; + opt->n_cand = n_cand; + + if(n_best > EVOLVE_MAX_CANDIDATES/2) + return -1; + opt->n_best = n_best; + + + if((mutation_amp > 1) || (mutation_amp < 0)) + return -1; + if(mutation_amp <= 0.001f) + mutation_amp = 0.001f; + opt->mutation_amp = mutation_amp; + + uint32_t seed = local_time(); +#ifdef ADC1 + seed += (ADC1->DR & 0xFF); +#endif + srand(seed); + + for (uint16_t i = 0; i < n_cand; i++) { + for (uint16_t j = 0; j < n_params; j++) { + // Добавляем случайную мутацию вокруг стартового параметра + float base = start_params[j]; + float inv_randmax = 1.0f / (float)RAND_MAX; + float noise = ((float)rand() * inv_randmax * 2.0f - 1.0f) * mutation_amp; + opt->candidates[i][j] = base + noise; + if (opt->candidates[i][j] < 0.0f) opt->candidates[i][j] = 0.0f; + if (opt->candidates[i][j] > 1.0f) opt->candidates[i][j] = 1.0f; + } + opt->loss[i] = 0.0f; + } + + opt->cand_index = 0; + opt->gen_index = 0; + return 0; +} + + +/** + * @brief Один шаг эволюционного оптимизатора. + * @param opt Указатель на структуру оптимизатора + * @param params Массив параметров, которые будут обновлены (на выходе — новые параметры) + * @param loss Loss текущего кандидата + * @return 0 — если окей, + * -1 — если ошибка + * @details + * Сохраняет loss текущего кандидата и формирует параметры следующего кандидата. + * Если накоплено n_cand кандидатов, генерируется новое поколение. + * Новое поколение формируется случайным выбором из n_best лучших с добавлением мутации. + * + * На выходе params содержит параметры следующего кандидата для измерений. + * @note Функция использует глобальную внутреннюю переменную для сортировки. + * Надо убедится что только один экземпляр функции запущен в момент времени + */ +__STATIC_INLINE int EvolveOptimizer_Step(EvolveOptimizer_t* opt, + float* params, + float loss) +{ + if((opt == NULL) || (params == NULL)) + return -1; + + uint16_t n_params = opt->n_params; + if(n_params > EVOLVE_MAX_PARAMS) + return -1; + + uint16_t n_cand = opt->n_cand; + if(n_cand > EVOLVE_MAX_CANDIDATES) + return -1; + + uint16_t n_best = opt->n_best; + if(n_best > EVOLVE_MAX_CANDIDATES/2) + return -1; + + float mut = opt->mutation_amp; + if((mut > 1) ||(mut < 0)) + return -1; + + // 1. Сохраняем loss текущего кандидата + opt->loss[opt->cand_index] = loss; + opt->cand_index++; + + if (opt->cand_index >= n_cand) { + // 2. Сортируем текущее поколение по loss + for(uint16_t i = 0; i < opt->n_cand; i++) + opt->sorted_idx[i] = i; + + g_sort_opt = opt; + qsort(opt->sorted_idx, opt->n_cand, sizeof(uint16_t), cmp_idx); + g_sort_opt = NULL; + + // --- Адаптивная мутация в зависимости от Loss --- + float best_loss = opt->loss[opt->sorted_idx[0]]; + float worst_loss = opt->loss[opt->sorted_idx[opt->n_cand - 1]]; + float diff = worst_loss - best_loss; + + float sum_loss = 0.0f; + for (uint16_t i = 0; i < n_cand; i++) + sum_loss += opt->loss[i]; + float avg_loss = sum_loss / (float)n_cand; + + + float loss_ratio = (diff > 0.0f) ? ((avg_loss - best_loss) / diff) : 0.5f; + if (loss_ratio < 0.0f) loss_ratio = 0.0f; + if (loss_ratio > 1.0f) loss_ratio = 1.0f; + + // Записываем стабильность популяции в структуру + if(diff < 0.0f) diff = 0.0f; + if(diff > 1.0f) diff = 1.0f; + opt->stability = (1.0f - worst_loss) * (1.0f - (worst_loss - best_loss)); + if(opt->stability < 0.0f) opt->stability = 0.0f; + if(opt->stability > 1.0f) opt->stability = 1.0f; + + float mut_pct = EVOLVE_MUTATION_MIN_PCT + + (EVOLVE_MUTATION_MAX_PCT - EVOLVE_MUTATION_MIN_PCT) * loss_ratio; + float adaptive_mut = mut * (mut_pct / 100.0f); + if (adaptive_mut < 0.0001f) adaptive_mut = 0.0001f; + opt->gen_mut = adaptive_mut; + + // 3. Генерируем новое поколение + uint16_t n_elite = ELOVLE_N_ELITE_CANDIDATE; + for (uint16_t c = 0; c < n_cand; c++) { + if (c < n_elite) { + for (uint16_t i = 0; i < n_params; i++) + opt->candidates[c][i] = opt->candidates[opt->sorted_idx[c]][i]; + opt->loss[c] = 0.0f; + } else { + for (uint16_t i = 0; i < n_params; i++) { + float inv_randmax = 1.0f / (float)RAND_MAX; + float noise = ((float)rand() * inv_randmax * 2.0f - 1.0f) * adaptive_mut; + uint16_t parent = opt->sorted_idx[rand() % opt->n_best]; + opt->candidates[c][i] = opt->candidates[parent][i] + noise; + if (opt->candidates[c][i] < 0.0f) opt->candidates[c][i] = 0.0f; + if (opt->candidates[c][i] > 1.0f) opt->candidates[c][i] = 1.0f; + } + opt->loss[c] = 0.0f; + } + } + opt->cand_index = 0; + opt->gen_index++; + } + + // 4. Возвращаем параметры следующего кандидата + for (uint16_t i = 0; i < opt->n_params; i++) + params[i] = opt->candidates[opt->cand_index][i]; + + return 0; +} +#else // ENABLE_EVOLVE_OPTIMIZATION +//заглушки +typedef struct { + uint16_t n_params; + uint16_t n_cand; + uint16_t n_best; + float mutation_amp; + float loss[0]; + float candidates[0][0]; +} EvolveOptimizer_t; +#define EvolveOptimizer_Init(opt, n_params, n_cand, n_best, mutation_amp, start_params) +#define EvolveOptimizer_Step(opt, params, LossFunc) +#define PARAM_SCALE(x, min_val, max_val) (x) +#define PARAM_UNSCALE(val, min_val, max_val) (val) +#endif // ENABLE_EVOLVE_OPTIMIZATION + +#endif // __EVOLVE_OPTIMIZER_H_ + +/** EVOLVE_OPTIMIZER + * @} + */ diff --git a/MyLibsGeneral/Inc/general_gpio.h b/MyLibsGeneral/Inc/general_gpio.h new file mode 100644 index 0000000..218a6bf --- /dev/null +++ b/MyLibsGeneral/Inc/general_gpio.h @@ -0,0 +1,237 @@ +/** +************************************************************************** +* @file general_gpio.h +* @brief Заголовочный файл для модуля инициализации портов и работы с ними. +************************************************************************** +* @defgroup MY_LIBS_GPIO GPIO Tools +* @ingroup MYLIBS_PERIPHERAL +* @brief Функции и макросы для удобной работы с GPIO. +* @details +Модуль предоставляет универсальные инструменты для работы с GPIO): + - @ref MYLIBS_GPIO_GENERAL — инициализация и общие функции работы с портами. + - @ref MYLIBS_GPIO_SWITCH — работа с GPIO как с кнопкой: чтение состояния, + фильтрация дребезга, настройка активного уровня. + - @ref MYLIBS_GPIO_LEDS — работа с GPIO как со светодиодом: включение, + выключение, моргание и плавное затухание. + +*************************************************************************/ +#ifndef __GPIO_GENERAL_H_ +#define __GPIO_GENERAL_H_ + +#include "mylibs_defs.h" + +/** + * @addtogroup GPIO_INIT Init defines + * @ingroup MYLIBS_GPIO_GENERAL + * @brief Настройка состояний кнопок и количества тиков в периоде ШИМ + * @{ + */ + +#ifndef local_time +#define local_time() HAL_GetTick() ///< Локальное время +#endif + +#ifndef LED_PWM_TICKS +#define LED_PWM_TICKS 15 ///< Количество тиков в периоде ШИМ +#endif + +#ifndef LED_ON +#define LED_ON 1 ///< Состояние пина для включения светодиода +#endif +#ifndef LED_OFF +#define LED_OFF 0 ///< Состояние пина для выключения светодиода +#endif + +#ifndef SW_ON +#define SW_ON 1 ///< Состояние пина при нажатой кнопке +#endif +#ifndef SW_OFF +#define SW_OFF 0 ///< Состояние пина при отжатой кнопке +#endif + +/** GPIO_INIT + * @} + */ + + +/** + * @brief Режимы работы светодиода + * @ingroup MYLIBS_GPIO_LEDS + */ +typedef enum +{ + LED_IS_OFF = 0, ///< Светодиод выключен + LED_IS_ON = 1, ///< Светодиод включен + LED_IS_BLINKING = 2, ///< Моргание светодиодом + LED_IS_FADING = 3, ///< Плавное моргание светодиодом +}GPIO_LEDStateTypeDef; + +/** + * @brief Структура светодиода + * @ingroup MYLIBS_GPIO_LEDS + */ +typedef struct +{ + GPIO_LEDStateTypeDef state; ///< Текущий режим работы светодиода + + GPIO_TypeDef *LED_Port; ///< GPIO порт ножки светодиода + uint32_t LED_Pin; ///< GPIO пин ножки светодиода + + uint8_t LED_ActiveLvl; ///< Активный уровень ножки (при котором светодиод горит) + uint32_t LED_Period; ///< Период моргания светодиода + + uint32_t tickprev; +}GPIO_LEDTypeDef; + +/** + * @brief Структура кнопки + * @ingroup MYLIBS_GPIO_SWITCH + */ +typedef struct +{ + GPIO_TypeDef *Sw_Port; ///< GPIO порт ножки кнопки + uint32_t Sw_Pin; ///< GPIO пин ножки кнопки + + uint8_t Sw_ActiveLvl; ///< Активный уровень ножки (при котором кнопка нажата) + uint32_t Sw_PrevState; ///< Предыдущее состояние кнопки + uint32_t Sw_FilterDelay; ///< Фильтр от дребезга (в мс) + + uint32_t tickprev; +}GPIO_SwitchTypeDef; + + +///////////////////////////////////////////////////////////////////// +///////////////////////////---FUNCTIONS---/////////////////////////// +/** + * @addtogroup MYLIBS_GPIO_GENERAL General tools + * @ingroup MY_LIBS_GPIO + * @brief Общие функции/макросы для работы с GPIO + * @par Пример использования: + @code + // Включаем тактирование порта GPIOA + GPIO_Clock_Enable(GPIOA); + @endcode + * @{ + */ + +HAL_StatusTypeDef GPIO_Clock_Enable(GPIO_TypeDef *GPIOx); + +/** MYLIBS_GPIO_GENERAL + * @} + */ + +/** + * @addtogroup MYLIBS_GPIO_SWITCH Switch tools + * @ingroup MY_LIBS_GPIO + * @brief Функции для работы с GPIO, как с кнопкой + * @par Пример использования: + @code + MX_GPIO_Init(); // инициализация пина аппаратная + + // Инициализация кнопки на порте GPIOB, пин 0, активный уровень 1 + GPIO_SwitchTypeDef sw1; + GPIO_Switch_Init(&sw1, GPIOB, GPIO_PIN_0, 1); // или дефайн SW_ON/SW_OFF + + // Считываем состояние кнопки + if(GPIO_Read_Switch(&sw1)) + { + // Кнопка нажата + LED_ON(); + } + else + { + // Кнопка отжата + LED_OFF(); + } + @endcode + * @{ + */ + +/* Инициализировать кнопку (структуру кнопки) */ +HAL_StatusTypeDef GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_On_State); +/* Считать состоянии кнопки запуска */ +int GPIO_Read_Switch(GPIO_SwitchTypeDef *swstart); + +/** MYLIBS_GPIO_SWITCH + * @} + */ + + +/** + * @addtogroup MYLIBS_GPIO_LEDS LED tools + * @ingroup MY_LIBS_GPIO + * @brief Функции для работы с GPIO, для управления светодиодом + * @par Пример использования: + @code + MX_GPIO_Init(); // инициализация пина аппаратная + + // Инициализация светодиода на порте GPIOA, пин 5, активный уровень 0 + GPIO_LEDTypeDef led; + GPIO_LED_Init(&led, GPIOA, GPIO_PIN_5, 0); // или дефайн LED_ON/LED_OFF + + // Включение светодиода + GPIO_LED_On(&led); + + // Запуск моргания + GPIO_LED_Blink_Start(&led, 500); // Период 500 мс + + // В основном цикле + while (1) { + GPIO_LED_Dynamic_Handle(&led); + } + @endcode + * @{ + */ + +/* Инициализировать светодиод (структуру светодиода) */ +HAL_StatusTypeDef GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_On_State); +/* Включить светодиод */ +HAL_StatusTypeDef GPIO_LED_On (GPIO_LEDTypeDef *led); +/* Выключить светодиод */ +HAL_StatusTypeDef GPIO_LED_Off (GPIO_LEDTypeDef *led); +/* Выставить светодиод по переменной */ +HAL_StatusTypeDef GPIO_LED_Set (GPIO_LEDTypeDef *led, uint8_t led_state); +/* Активировать моргание светодиодом */ +HAL_StatusTypeDef GPIO_LED_Blink_Start (GPIO_LEDTypeDef *led, uint32_t period); +/* Активировать моргание светодиодом */ +HAL_StatusTypeDef GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period); +/* Управление динамическими режимами свечения светодиода */ +void GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led); + +/** MYLIBS_GPIO_LEDS + * @} + */ +///////////////////////////---FUNCTIONS---/////////////////////////// + + +/** + * @cond GPIO_INTERNAL + */ + +// /** +// * @brief Маппинг альтернативной функции SPI между GPIO +// * @ingroup MYLIBS_GPIO_GENERAL +// */ +// #define SPI_Alternate_Mapping(INSTANCE) \ +// ((((INSTANCE) == TIM1) || ((INSTANCE) == TIM2))? GPIO_AF1_TIM1: \ +// (((INSTANCE) == TIM3) || ((INSTANCE) == TIM4) || ((INSTANCE) == TIM5))? GPIO_AF2_TIM3: \ +// (((INSTANCE) == TIM8) || ((INSTANCE) == TIM9) || ((INSTANCE) == TIM10) || ((INSTANCE) == TIM11))? GPIO_AF3_TIM8: \ +// (((INSTANCE) == TIM12) || ((INSTANCE) == TIM13) || ((INSTANCE) == TIM14))? GPIO_AF9_TIM12: \ +// (0)) + + +/** + * @brief Маппинг альтернативной функции TIM между GPIO + * @ingroup MYLIBS_GPIO_GENERAL + */ +#define GPIO_TIM_Alternate_Mapping(INSTANCE) \ +((((INSTANCE) == TIM1) || ((INSTANCE) == TIM2))? GPIO_AF1_TIM1: \ +(((INSTANCE) == TIM3) || ((INSTANCE) == TIM4) || ((INSTANCE) == TIM5))? GPIO_AF2_TIM3: \ +(((INSTANCE) == TIM8) || ((INSTANCE) == TIM9) || ((INSTANCE) == TIM10) || ((INSTANCE) == TIM11))? GPIO_AF3_TIM8: \ +(((INSTANCE) == TIM12) || ((INSTANCE) == TIM13) || ((INSTANCE) == TIM14))? GPIO_AF9_TIM12: \ +(0)) + + +/** @endcond */ + +#endif // __GPIO_GENERAL_H_ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/general_spi.h b/MyLibsGeneral/Inc/general_spi.h new file mode 100644 index 0000000..239db9d --- /dev/null +++ b/MyLibsGeneral/Inc/general_spi.h @@ -0,0 +1,170 @@ +/** +************************************************************************** +* @file general_spi.h +* @brief Заголовочный файл для модуля инициализации SPI. +************************************************************************** +* @defgroup MY_LIBS_SPI SPI Tools +* @ingroup MYLIBS_PERIPHERAL +* @brief Функции и макросы для удобной работы с SPI. +* @details +Модуль предоставляет функции для базовой инициализации SPI + + +@par Пример использования: +@code +// Структура настроек SPI +SPI_SettingsTypeDef spi1Settings; + +void SPI1_Init(void) +{ + // Настройка SPI1 как Master, 8 бит, полный дуплекс + spi1Settings.hspi.Instance = SPI1; + spi1Settings.hspi.Init.Mode = SPI_MODE_MASTER; + spi1Settings.hspi.Init.Direction = SPI_DIRECTION_2LINES; + spi1Settings.hspi.Init.DataSize = SPI_DATASIZE_8BIT; + spi1Settings.hspi.Init.CLKPolarity = SPI_POLARITY_LOW; + spi1Settings.hspi.Init.CLKPhase = SPI_PHASE_1EDGE; + spi1Settings.hspi.Init.NSS = SPI_NSS_SOFT; + spi1Settings.hspi.Init.BaudRatePrescaler = SPI_BAUDRATEPRESCALER_16; + spi1Settings.hspi.Init.FirstBit = SPI_FIRSTBIT_MSB; + spi1Settings.hspi.Init.TIMode = SPI_TIMODE_DISABLE; + spi1Settings.hspi.Init.CRCCalculation = SPI_CRCCALCULATION_DISABLE; + + // Настройка GPIO + spi1Settings.CLK_GPIOx = GPIOA; + spi1Settings.CLK_PIN = GPIO_PIN_5; + spi1Settings.CLK_GPIO_AlternageFunc = GPIO_AF5_SPI1; + + spi1Settings.MISO_GPIOx = GPIOA; + spi1Settings.MISO_PIN = GPIO_PIN_6; + spi1Settings.MISO_GPIO_AlternageFunc = GPIO_AF5_SPI1; + + spi1Settings.MOSI_GPIOx = GPIOA; + spi1Settings.MOSI_PIN = GPIO_PIN_7; + spi1Settings.MOSI_GPIO_AlternageFunc = GPIO_AF5_SPI1; + + // Инициализация SPI + if(SPI_Base_Init(&spi1Settings) != HAL_OK) + { + // Обработка ошибки + Error_Handler(); + } +} +@endcode + + + +* @note Требуется подключение модуля SPI в библиотеке HAL +@code +#define HAL_SPI_MODULE_ENABLED +@endcode +* @{ +*************************************************************************/ +#ifndef __SPI_GENERAL_H_ +#define __SPI_GENERAL_H_ + + +///////////////////////////////////////////////////////////////////// +/////////////////////////---USER SETTINGS---///////////////////////// +/** + * @addtogroup SPI_INIT Init defines + * @ingroup MY_LIBS_SPI + * @brief Настройка SPI + * @{ + */ +#define HAL_SPI_MODULE_ENABLED ///< Включение HAL SPI + +#define USE_SPI1 ///< Включить SPI1 в @ref SPI_MspInit +#define USE_SPI2 ///< Включить SPI2 в @ref SPI_MspInit +#define USE_SPI3 ///< Включить SPI3 в @ref SPI_MspInit +/** SPI_INIT + * @} + */ +/////////////////////////---USER SETTINGS---///////////////////////// +#include "mylibs_defs.h" + + + +///////////////////////////////////////////////////////////////////// +////////////////////////////---DEFINES---//////////////////////////// + + + +////////////////////////////---DEFINES---//////////////////////////// + + +///////////////////////////////////////////////////////////////////// +///////////////////////---STRUCTURES & ENUMS---////////////////////// +/** + * @brief Структура настроек SPI + * @details Содержит все необходимые параметры для инициализации SPI, + * включая GPIO и DMA. + */ +typedef struct +{ + SPI_HandleTypeDef hspi; ///< HAL handle SPI + + GPIO_TypeDef *CLK_GPIOx; ///< Порт CLK + uint32_t CLK_PIN; ///< Пин CLK + uint32_t CLK_GPIO_AlternageFunc; ///< Альтернативная функция для CLK + + GPIO_TypeDef *MISO_GPIOx; ///< Порт MISO + uint32_t MISO_PIN; ///< Пин MISO + uint32_t MISO_GPIO_AlternageFunc; ///< Альтернативная функция для MISO + + GPIO_TypeDef *MOSI_GPIOx; ///< Порт MOSI + uint32_t MOSI_PIN; ///< Пин MOSI + uint32_t MOSI_GPIO_AlternageFunc; ///< Альтернативная функция для MOSI + + DMA_Stream_TypeDef *DMAChannel; ///< Канал DMA (NULL если не нужен) + uint32_t DMA_CHANNEL_X; ///< Номер канала DMA (0 если не нужен) + +} SPI_SettingsTypeDef; +///////////////////////---STRUCTURES & ENUMS---////////////////////// + + +///////////////////////////////////////////////////////////////////// +///////////////////////////---FUNCTIONS---/////////////////////////// + +/* Инициализация SPI с использованием структуры настроек */ +HAL_StatusTypeDef SPI_Base_Init(SPI_SettingsTypeDef *sspi); + +/* Проверка корректности структуры настроек SPI */ +HAL_StatusTypeDef SPI_Check_Init_Struct(SPI_SettingsTypeDef *sspi); + +/* Инициализация тактирования и прерываний для выбранного SPI */ +void SPI_MspInit(SPI_HandleTypeDef *hspi); + +/* Деинициализация тактирования и прерываний для выбранного SPI */ +void SPI_MspDeInit(SPI_HandleTypeDef *hspi); + + +/** + * @cond SPI_INTERNAL + */ + +/* Настройка GPIO для SPI */ +void SPI_GPIO_Init(SPI_SettingsTypeDef *sspi); + +/* Настройка DMA для SPI */ +void SPI_DMA_Init(SPI_HandleTypeDef *hspi, DMA_HandleTypeDef *hdma_rx, DMA_Stream_TypeDef *DMAChannel, uint32_t DMA_CHANNEL_X); + +#ifndef __USER_LINKDMA +/** + * @brief Аналог HAL макроса для привязки DMA к UART. + * @note @ref __HAL_LINKDMA. + */ +#define __USER_LINKDMA(__HANDLE__, __PPP_DMA_FIELD__, __DMA_HANDLE__) \ +do{ \ +(__HANDLE__)->__PPP_DMA_FIELD__ = (__DMA_HANDLE__); \ +(__DMA_HANDLE__)->Parent = (__HANDLE__);} while(0U) +#endif + +/** @endcond */ +///////////////////////////---FUNCTIONS---/////////////////////////// + +#endif // __SPI_GENERAL_H_ + +/** MY_LIBS_SPI + * @} + */ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/general_tim.h b/MyLibsGeneral/Inc/general_tim.h new file mode 100644 index 0000000..a45493c --- /dev/null +++ b/MyLibsGeneral/Inc/general_tim.h @@ -0,0 +1,301 @@ +/** +************************************************************************** +* @file general_tim.h +* @brief Заголовочный файл для модуля инициализации таймеров и работы с ними. +************************************************************************** +* @defgroup MY_LIBS_TIM TIM Tools +* @ingroup MYLIBS_PERIPHERAL +* @brief Функции и макросы для удобной работы с TIM. +* @details +Модуль предоставляет универсальные инструменты для работы с TIM: + - @ref MYLIBS_TIM_GENERAL — базовая инициализация таймеров и прерываний. + - @ref MYLIBS_TIM_DELAY — функции задержки через таймеры (blocking и non-blocking). + - @ref MYLIBS_TIM_OC — настройка каналов Output Compare и PWM. + - @ref MYLIBS_TIM_ENCODER — работа с энкодерами, чтение положения и кнопки. + +* @note Требуется подключение модуля TIM в библиотеке HAL и GPIO (@ref MY_LIBS_GPIO) из MyLibs +@code +#define HAL_TIM_MODULE_ENABLED +@endcode +*************************************************************************/ +#ifndef __TIM_GENERAL_H_ +#define __TIM_GENERAL_H_ + +///////////////////////////////////////////////////////////////////// +/////////////////////////---USER SETTINGS---///////////////////////// +/** + * @addtogroup TIM_INIT Init defines + * @ingroup MYLIBS_TIM_GENERAL + * @brief Настройка таймеров + * @{ + */ +#define HAL_TIM_MODULE_ENABLED + +#define USE_TIM1 ///< Включить TIM1 в @ref TIM_Base_MspInit +#define USE_TIM2 ///< Включить TIM2 в @ref TIM_Base_MspInit +#define USE_TIM3 ///< Включить TIM3 в @ref TIM_Base_MspInit +#define USE_TIM4 ///< Включить TIM4 в @ref TIM_Base_MspInit +#define USE_TIM5 ///< Включить TIM5 в @ref TIM_Base_MspInit +#define USE_TIM6 ///< Включить TIM6 в @ref TIM_Base_MspInit +#define USE_TIM7 ///< Включить TIM7 в @ref TIM_Base_MspInit +#define USE_TIM8 ///< Включить TIM8 в @ref TIM_Base_MspInit +#define USE_TIM9 ///< Включить TIM9 в @ref TIM_Base_MspInit +#define USE_TIM10 ///< Включить TIM10 в @ref TIM_Base_MspInit +#define USE_TIM11 ///< Включить TIM11 в @ref TIM_Base_MspInit +#define USE_TIM12 ///< Включить TIM12 в @ref TIM_Base_MspInit +#define USE_TIM13 ///< Включить TIM13 в @ref TIM_Base_MspInit +#define USE_TIM14 ///< Включить TIM14 в @ref TIM_Base_MspInit +/** TIM_INIT + * @} + */ +/////////////////////////---USER SETTINGS---///////////////////////// +#include "mylibs_defs.h" +#include "general_gpio.h" + +///////////////////////////////////////////////////////////////////// +////////////////////////////---DEFINES---//////////////////////////// +#define TIM_IT_CONF_Pos 0 +//#define TIM_PWM_CONF_Pos 1 +//#define TIM_CLCK_SRC_CONF_Pos 2 +//#define TIM_SLAVE_CONF_Pos 3 +//#define TIM_MASTER_CONF_Pos 4 +//#define TIM_BDTR_CONF_Pos 5 + +#define TIM_IT_CONF (1<<(TIM_IT_CONF_Pos)) +//#define TIM_PWM_CONF (1<<(TIM_PWM_Pos)) + +////////////////////////////---DEFINES---////////////////////////////] + + + +///////////////////////////////////////////////////////////////////// +///////////////////////---STRUCTURES & ENUMS---////////////////////// +/** + * @brief Режим прерываний таймера + * @ingroup MYLIBS_TIM_GENERAL + */ +typedef enum +{ + TIM_DEFAULT = 0, ///< Прерываний отключены + TIM_IT_MODE = TIM_IT_CONF, ///< Прерываний включены +// TIM_PWM_MODE = TIM_PWM_ENABLE, +// TIM_PWM_IT_MODE = TIM_PWM_ENABLE | TIM_IT_CONF, +}TIM_ITModeTypeDef; + +/** + * @brief Длительность тика таймера (частота тактирования таймера) + * @ingroup MYLIBS_TIM_GENERAL + * @details enum дает базовые длительности, но можно выставить другие + * (напр 500 - 0.5 мс) + */ +typedef enum +{ + TIM_Base_Disable = 0, ///< Таймер отключен + TIM_TickBase_1US = 1, ///< Таймер тактируется с частотой 1 МГц + TIM_TickBase_10US = 10, ///< Таймер тактируется с частотой 100 кГц + TIM_TickBase_100US = 100, ///< Таймер тактируется с частотой 10 кГц + TIM_TickBase_1MS = 1000, ///< Таймер тактируется с частотой 1 кГц + TIM_TickBase_10MS = 10000, ///< Таймер тактируется с частотой 100 Гц + TIM_TickBase_100MS = 100000, ///< Таймер тактируется с частотой 10 Гц +}TIM_MHzTickBaseTypeDef; + +/** + * @brief Структура инициализации таймера + * @ingroup MYLIBS_TIM_GENERAL + * @details + * Содержит все базовые структуры, которые нужны для инициализации таймера. + * Если структуры настроек не заданы, то они заполнятся сами дефолтными параметрами + * + * Также высокоуровневые настройки частоты работы таймера. + * Если какая-либо высокоуровневая настройка не задана, то + * по возможности берется низкоуровневая настройка из структур + */ +typedef struct // struct with settings for custom function +{ + TIM_HandleTypeDef htim; ///< HAL handle таймера + TIM_ClockConfigTypeDef sClockSourceConfig; ///< Настройки тактирования таймера + TIM_SlaveConfigTypeDef sSlaveConfig; ///< Настройки слейв режима таймера + TIM_MasterConfigTypeDef sMasterConfig; ///< Настройки мастер режима таймера + TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig; ///< Настройки дедтаймов таймера + + TIM_ITModeTypeDef sTimMode; ///< Настройки прерывания таймера + TIM_MHzTickBaseTypeDef sTickBaseUS; ///< Длительность одного тика + uint8_t sTickBasePrescaler; ///< Дополнительный делитель, для удобного деления @ref sTickBaseUS + float sTimAHBFreqMHz; ///< Частота шины тактирования таймера + float sTimFreqHz; ///< Желаемая частота таймера + +}TIM_SettingsTypeDef; + + +/** + * @brief Структура инициализации енкодера + * @ingroup MYLIBS_TIM_ENCODER + * @details + * Содержит все базовые структуры, которые нужны для инициализации таймера. + * Если структуры настроек не заданы, то они заполнятся сами дефолтными параметрами + * + * Также высокоуровневые настройки частоты работы таймера. + * Если какая-либо высокоуровневая настройка не задана, то + * по возможности берется низкоуровневая настройка из структур + */ +typedef struct // struct with variables for encoder +{ + int16_t Encoder_Diff; ///< Считанная разница + uint16_t Encoder_Shdw; ///< Последние считанные тики + + TIM_HandleTypeDef *htim; ///< Указатель на HAL handle таймера + TIM_Encoder_InitTypeDef sConfig; ///< Указатель на структуру настройки энкодера + + GPIO_TypeDef *GPIOx; ///< Порт, куда подключается энкодер + uint32_t GPIO_PIN_TI1; ///< Пин, куда подключается канал TI1 + uint32_t GPIO_PIN_TI2; ///< Пин, куда подключается канал TI2 + uint32_t GPIO_PIN_SW; ///< Пин, куда кнопка энкодера (если есть) + + GPIO_SwitchTypeDef Sw; ///< Структура кнопки + +}TIM_EncoderTypeDef; +///////////////////////---STRUCTURES & ENUMS---////////////////////// + +///////////////////////////////////////////////////////////////////// +///////////////////////////---FUNCTIONS---/////////////////////////// +/** + * @addtogroup MYLIBS_TIM_GENERAL General tools + * @ingroup MY_LIBS_TIM + * @brief Функции для базовой инициализации таймеров + * @par Пример использования: + @code + TIM_SettingsTypeDef tim2Settings; + + void TIM2_Init(void) + { + // Настройка таймера TIM2 на 1 кГц с прерываниями с шагом таймера 10 мкс + tim2Settings.htim.Instance = TIM2; + tim2Settings.sTimMode = TIM_IT_MODE; + tim2Settings.sTickBaseUS = TIM_TickBase_10US; + tim2Settings.sTickBasePrescaler = 1; + tim2Settings.sTimFreqHz = 1000; // 1 кГц + tim2Settings.sTimAHBFreqMHz = 72000000; // Hz + + if(TIM_Base_Init(&tim2Settings) != HAL_OK) + { + Error_Handler(); + } + } + @endcode + * @{ + */ +/* Initialize TIM with TIM_SettingsTypeDef structure */ +HAL_StatusTypeDef TIM_Base_Init(TIM_SettingsTypeDef* stim); +/* Initialize TIMs clock and interrupt */ +void TIM_Base_MspInit(TIM_HandleTypeDef* htim, TIM_ITModeTypeDef it_mode); +/* DeInitialize TIMs clock and interrupt */ +void TIM_Base_MspDeInit(TIM_HandleTypeDef* htim); +/** MYLIBS_TIM_GENERAL + * @} + */ + +/** + * @addtogroup MYLIBS_TIM_DELAY Delay tools + * @ingroup MY_LIBS_TIM + * @brief Функции для формирования задержек с помощью таймеров + * @par Пример использования: + @code + TIM_HandleTypeDef htim2; + + // блокирующая задержка 500 тиков таймера + LED_ON(); + TIM_Delay(&htim2, 500); + LED_OFF(); + + + while(1) + { + // не блокирующая задержка 200 тиков таймера + if(TIM_Delay_NonBlocking(&htim2, 200) == HAL_OK) + { + TIM_Delay_Start(&htim2); + LED_TOOGLE(); + } + } + @endcode + * @{ + */ +/* Start delay via TIM */ +HAL_StatusTypeDef TIM_Delay_Start(TIM_HandleTypeDef *htim); +/* Delay via TIM */ +HAL_StatusTypeDef TIM_Delay(TIM_HandleTypeDef *htim, uint16_t delay); +/* Wait Delay via TIM without blocking app */ +HAL_StatusTypeDef TIM_Delay_NonBlocking(TIM_HandleTypeDef *htim, uint16_t delay); +/** MYLIBS_TIM_DELAY + * @} + */ + +/** + * @addtogroup MYLIBS_TIM_OC PWM/OC Channels tools + * @ingroup MY_LIBS_TIM + * @brief Функции для инициализации базовых функций каналов таймера + * @par Пример использования: + @code + void PWM_Channel_Init_Example(void) + { + TIM_HandleTypeDef htim3; + TIM_OC_InitTypeDef sConfigOC; + GPIO_TypeDef *GPIOx = GPIOB; + uint32_t PWM_PIN = GPIO_PIN_0; + + // Настройка таймера и канала PWM + TIM_Output_PWM_Init(&htim3, &sConfigOC, TIM_CHANNEL_1, GPIOx, PWM_PIN); + + // Настройка компаратора OC + TIM_OC_Comparator_Init(&htim3, TIM_CHANNEL_1); + } + @endcode + * @{ + */ +/* Initialize PWM Channel and GPIO for output */ +HAL_StatusTypeDef TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t PWM_PIN); +/* Initialize OC Comparator */ +HAL_StatusTypeDef TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL); +/** MYLIBS_TIM_ENCODER + * @} + */ + +/** + * @addtogroup MYLIBS_TIM_ENCODER Encoder tools + * @ingroup MY_LIBS_TIM + * @brief Функции для считывания энкодера + * @par Пример использования: + @code + TIM_EncoderTypeDef henc1; + TIM_HandleTypeDef htim4; + + // инициализация + henc1.htim = &htim4; + henc1.GPIOx = GPIOA; + henc1.GPIO_PIN_TI1 = GPIO_PIN_0; + henc1.GPIO_PIN_TI2 = GPIO_PIN_1; + TIM_Encoder_Init(&henc1, &htim4); + + // считывание энкодера и кнопки + int16_t delta = TIM_Encoder_Read(&henc1); + setpoint_tmp += delta; + if(TIM_Encoder_ReadSwitch(&henc1)) + { + setpoint = setpoint_tmp; // подтвердить новое значение + } + @endcode + * @{ + */ +/* Initialize TIM Encoder functional */ +HAL_StatusTypeDef TIM_Encoder_Init(TIM_EncoderTypeDef *henc1, TIM_HandleTypeDef *htim); +/* Считать энкодер */ +HAL_StatusTypeDef TIM_Encoder_Read(TIM_EncoderTypeDef *henc); +/* Считать кнопку энкодера */ +int TIM_Encoder_ReadSwitch(TIM_EncoderTypeDef *henc); +/** MYLIBS_TIM_ENCODER + * @} + */ +///////////////////////////---FUNCTIONS---/////////////////////////// + + +#endif // __TIM_GENERAL_H_ diff --git a/MyLibsGeneral/Inc/general_uart.h b/MyLibsGeneral/Inc/general_uart.h new file mode 100644 index 0000000..cf0660a --- /dev/null +++ b/MyLibsGeneral/Inc/general_uart.h @@ -0,0 +1,156 @@ +/** +************************************************************************** +* @file general_uart.h +* @brief Заголовочный файл для модуля инициализации UART. +************************************************************************** +* @defgroup MY_LIBS_UART UART Tools +* @ingroup MYLIBS_PERIPHERAL +* @brief Функции и макросы для удобной работы с UART. +* @details +Модуль предоставляет функции для базовой инициализации UART + + +@par Пример использования: +@code +// Структура настроек UART +UART_SettingsTypeDef uart2Settings; + +void UART2_Init(void) +{ + // Настройка UART2 с 115200 бод, 8 бит, 1 стоп-бит, без паритета + uart2Settings.huart.Instance = USART2; + uart2Settings.huart.Init.BaudRate = 115200; + uart2Settings.huart.Init.WordLength = UART_WORDLENGTH_8B; + uart2Settings.huart.Init.StopBits = UART_STOPBITS_1; + uart2Settings.huart.Init.Parity = UART_PARITY_NONE; + uart2Settings.huart.Init.Mode = UART_MODE_TX_RX; + uart2Settings.huart.Init.HwFlowCtl = UART_HWCONTROL_NONE; + uart2Settings.huart.Init.OverSampling = UART_OVERSAMPLING_16; + + // Настройка GPIO + uart2Settings.GPIOx = GPIOA; + uart2Settings.GPIO_PIN_TX = GPIO_PIN_2; + uart2Settings.GPIO_PIN_RX = GPIO_PIN_3; + + // DMA не используется в этом примере + uart2Settings.DMAChannel = NULL; + uart2Settings.DMA_CHANNEL_X = 0; + + // Инициализация UART + if(UART_Base_Init(&uart2Settings) != HAL_OK) + { + // Обработка ошибки + Error_Handler(); + } +} +@endcode + +* @note Требуется подключение модуля UART в библиотеке HAL +@code +#define HAL_UART_MODULE_ENABLED +@endcode +* @{ +*************************************************************************/ +#ifndef __UART_GENERAL_H_ +#define __UART_GENERAL_H_ + +///////////////////////////////////////////////////////////////////// +/////////////////////////---USER SETTINGS---///////////////////////// +/** + * @addtogroup UART_INIT Init defines + * @ingroup MY_LIBS_UART + * @brief Настройка UART + * @{ + */ +#define HAL_UART_MODULE_ENABLED ///< Включение HAL UART + +#define USE_USART1 ///< Включить USART1 в @ref UART_MspInit +#define USE_USART2 ///< Включить USART2 в @ref UART_MspInit +#define USE_USART3 ///< Включить USART3 в @ref UART_MspInit +#define USE_UART4 ///< Включить UART4 в @ref UART_MspInit +#define USE_UART5 ///< Включить UART5 в @ref UART_MspInit +#define USE_USART6 ///< Включить USART6 в @ref UART_MspInit +/** UART_INIT + * @} + */ +/////////////////////////---USER SETTINGS---///////////////////////// +#include "mylibs_defs.h" + + + +///////////////////////////////////////////////////////////////////// +////////////////////////////---DEFINES---//////////////////////////// + + + +////////////////////////////---DEFINES---//////////////////////////// + + +///////////////////////////////////////////////////////////////////// +///////////////////////---STRUCTURES & ENUMS---////////////////////// +/** + * @brief Структура настроек UART + * @details Содержит все необходимые параметры для инициализации UART, + * включая GPIO и DMA. + */ +typedef struct +{ + UART_HandleTypeDef huart; ///< HAL handle UART + + GPIO_TypeDef *GPIOx; ///< Порт для UART + uint16_t GPIO_PIN_RX; ///< Пин приема + uint16_t GPIO_PIN_TX; ///< Пин передачи + + DMA_Stream_TypeDef *DMAChannel; ///< Канал DMA (NULL если не нужен) + uint32_t DMA_CHANNEL_X; ///< Номер канала DMA (0 если не нужен) + +} UART_SettingsTypeDef; + +///////////////////////---STRUCTURES & ENUMS---////////////////////// + + +///////////////////////////////////////////////////////////////////// +///////////////////////////---FUNCTIONS---/////////////////////////// + +/* Инициализация UART с использованием структуры настроек */ +HAL_StatusTypeDef UART_Base_Init(UART_SettingsTypeDef *suart); + +/* Проверка корректности структуры настроек UART */ +HAL_StatusTypeDef UART_Check_Init_Struct(UART_SettingsTypeDef *suart); + +/* Инициализация тактирования и прерываний для выбранного UART */ +void UART_MspInit(UART_HandleTypeDef *huart); + +/* Деинициализация тактирования и прерываний для выбранного UART */ +void UART_MspDeInit(UART_HandleTypeDef *huart); + + +/** + * @cond UART_INTERNAL + */ + +/* Настройка GPIO для UART */ +void UART_GPIO_Init(GPIO_TypeDef *GPIOx, uint16_t GPIO_PIN_RX, uint16_t GPIO_PIN_TX); + +/* Настройка DMA для UART */ +void UART_DMA_Init(UART_HandleTypeDef *huart, DMA_HandleTypeDef *hdma_rx, DMA_Stream_TypeDef *DMAChannel, uint32_t DMA_CHANNEL_X); + +#ifndef __USER_LINKDMA +/** + * @brief Аналог HAL макроса для привязки DMA к UART. + * @note @ref __HAL_LINKDMA. + */ +#define __USER_LINKDMA(__HANDLE__, __PPP_DMA_FIELD__, __DMA_HANDLE__) \ +do{ \ +(__HANDLE__)->__PPP_DMA_FIELD__ = (__DMA_HANDLE__); \ +(__DMA_HANDLE__)->Parent = (__HANDLE__);} while(0U) +#endif + +/** @endcond */ +///////////////////////////---FUNCTIONS---/////////////////////////// + +#endif // __UART_GENERAL_H_ + +/** MY_LIBS_UART + * @} + */ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/mylibs_config.h b/MyLibsGeneral/Inc/mylibs_config.h new file mode 100644 index 0000000..68208d2 --- /dev/null +++ b/MyLibsGeneral/Inc/mylibs_config.h @@ -0,0 +1,96 @@ +/** +************************************************************************** +* @file mylibs_config.h +* @brief Конфигурации для библиотек MyLibs +************************************************************************** +* @defgroup MYLIBS_CONFIG Configs +* @ingroup MYLIBS_ALL +* @brief Конфигурации для библиотек MyLibs +* @{ +*************************************************************************/ +#ifndef __MYLIBS_CONFIG_H_ +#define __MYLIBS_CONFIG_H_ + +#include "stm32f4xx_hal.h" + +// user includes + +/** + * @addtogroup TRACE_CONFIG Trace configs + * @ingroup MYLIBS_CONFIG + * @brief Конфигурация трекеров и трассировки + * @{ + */ + +#define TRACKERS_ENABLE ///< Включить трекеры +#define SERIAL_TRACE_ENABLE ///< Включить serial трассировку +#define RTT_TRACE_ENABLE ///< Включить serial трассировку через RTT +#define SWO_TRACE_ENABLE ///< Включить serial трассировку через SWO +/** + * @brief Уровень log serial трассировки @ref log_printf + * - LOG_LEVEL == 0 - логирование отключено (макрос пустой) + * - LOG_LEVEL == 1 - выводится время и TAG + * - LOG_LEVEL >= 2 - выводится время, TAG, имя файла и номер строки + */ +#define LOG_LEVEL 1 + +#define RTT_FLASH_BUFFER_SIZE 1024 ///< Размер буфера RTT в Flash +#define RTT_FLASH_SECTOR FLASH_SECTOR_11 ///< Сектор FLASH куда положится RTT буфер +#define RTT_FLASH_SECTOR_START 0x080E0000 ///< Начало сектора RTT_FLASH_SECTOR +#define RTT_FLASH_SECTOR_END 0x080FFFFF ///< Конец сектора RTT_FLASH_SECTOR + + +#define HARDFAULT_SERIAL_TRACE ///< Включить обработку и serial трассировку Hardfault +#define HF_RTT_TAG_BASE 0xDEAD0000 ///< базовый тег для HardFault +#define HF_RTT_TAIL_SIZE RTT_FLASH_BUFFER_SIZE ///< Размер буфера RTT, который сохранится при Hardfault +#define HF_STACK_DUMP_WORDS 32 ///< Сколько слов стека будет проанализировано во время Hardfault +#define HF_FLASH_ADDR ((uint32_t)0x080FF000) ///< Адрес FLASH куда положится RTT буфер +#define HF_RAM_END 0x20030000 ///< Конец RAM памяти (чтобы во время анализа стека не выйти за пределы) + +#define GPIO_TRACE_ENABLE ///< Включить GPIO трассировку + +/** TRACE_CONFIG + * @} + */ + + +/** + * @addtogroup EVOLVE_CONFIG Evolve configs + * @ingroup MYLIBS_CONFIG + * @brief Конфигурация однослойного персептрона и алгоритма обучения + * @{ + */ + +#define ENABLE_EVOLVE_OPTIMIZATION ///< Включить оптимизацию параметров +#define EVOLVE_MAX_PARAMS 20 ///< Максимальное количество параметров +#define EVOLVE_MAX_CANDIDATES 100 ///< Максимальное количество кандидатов для обучения + +/** EVOLVE_CONFIG + * @} + */ + + +/** + * @addtogroup LIBS_CONFIG Libraries configs + * @ingroup MYLIBS_CONFIG + * @brief Подключение различных модулей библиотеки + * @{ + */ + +#define local_time() uwTick ///< Локальное время + +#define INCLUDE_EVOLVE_OPTIMIZER ///< Подключить библиотеку для оптимизации параметров +#define INCLUDE_BIT_ACCESS_LIB ///< Подключить библиотеку с typedef с битовыми полями +#define INCLUDE_TRACKERS_LIB ///< Подключить библиотеку с трекерами +#define INCLUDE_TRACE_LIB ///< Подключить библиотеку с трейсами +#define INCLUDE_GENERAL_PERIPH_LIBS ///< Подключить библиотеку с периферией +#define FREERTOS_DELAY ///< Использовать FreeRTOS задержку, вместо HAL + +/** LIBS_CONFIG + * @} + */ + +/** MYLIBS_CONFIG + * @} + */ +#endif //__MYLIBS_CONFIG_H_ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/mylibs_defs.h b/MyLibsGeneral/Inc/mylibs_defs.h new file mode 100644 index 0000000..e7e835f --- /dev/null +++ b/MyLibsGeneral/Inc/mylibs_defs.h @@ -0,0 +1,206 @@ +/** +************************************************************************** +* @file mylibs_defs.h +* @brief Заголочный файл для дефайнов библиотеки MyLibsGeneral. +************************************************************************** +* @defgroup MYLIBS_DEFINES General Tools +* @ingroup MYLIBS_ALL +* @brief Общие макросы и typedef'ы, используемые по всему проекту +* +*************************************************************************/ +#ifndef __MYLIBS_DEFINES_H_ +#define __MYLIBS_DEFINES_H_ + +#include "mylibs_config.h" + +/*************************************************************************** +******************************ERROR_HANDLER********************************/ +/** + * @addtogroup ERROR_HANDLER_DEFINES Error Handler defines + * @ingroup MYLIBS_DEFINES + * @brief Дефайны для обработки ошибок + * @{ + */ + +/* extern Error_Handler from main.h */ +extern void Error_Handler(void); + +/** + * @brief Error_Handler который будет вызыватся в библиотеке + */ +#define MyLibs_Error_Handler(params) Error_Handler(params) +/* If error handler not defined - set void */ +#ifndef MyLibs_Error_Handler +#define MyLibs_Error_Handler(...) +#endif // MyLibs_Error_Handler + +/** @brief Проверить один указатель на NULL */ +#define check_null_ptr_1(p1) (p1 == NULL) + +/** @brief Проверить два указателя на NULL */ +#define check_null_ptr_2(p1, p2) ((p1 == NULL) || (p1 != NULL && p2 == NULL)) + +/** @brief Проверить три указателя на NULL */ +#define check_null_ptr_3(p1, p2, p3) ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && p3 == NULL)))) + +/** @brief Проверить четыре указателя на NULL */ +#define check_null_ptr_4(p1, p2, p3, p4) ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && p4 == NULL)))))) + +/** @brief Проверить пять указателей на NULL */ +#define check_null_ptr_5(p1, p2, p3, p4, p5) ((p1 == NULL) || (p1 != NULL && ((p2 == NULL) || (p2 != NULL && ((p3 == NULL) || (p3 != NULL && ((p4 == NULL) || (p4 != NULL && p5 == NULL)))))))) + +/** ERROR_HANDLER_DEFINES + * @} + */ + + +/*************************************************************************** +******************************DELAYS_DEFINES*******************************/ +/** + * @addtogroup DELAYS_DEFINES Delays defines + * @ingroup MYLIBS_DEFINES + * @brief Макросы и определения для работы с задержками в миллисекундах. + * @details + * Этот блок содержит макросы для реализации задержек с использованием HAL или FreeRTOS: + * - @ref msDelay — простая задержка заданной длительности; + * - @ref msDelayStart — сохранение текущего времени начала задержки; + * - @ref msDelayWhileActive — проверка, активна ли задержка; + * - @ref msDelayWaitDone — проверка, завершена ли задержка. + * Эти макросы удобны для реализации неблокирующих задержек. + * @{ + */ + +/** + * @def msDelay(_ms_) + * @brief Блокирующая задержка на указанное количество миллисекунд. + * @param _ms_ Время задержки в миллисекундах. + * @note Использует задержку через @ref local_time или osDelay в зависимости от @ref FREERTOS_DELAY. + */ +#ifdef FREERTOS_DELAY + #define msDelay(_ms_) osDelay(_ms_) +#else + #define msDelay(_ms_) \ + do { \ + uint32_t _start_ = local_time(); \ + while (local_time() - _start_ < (_ms_)) {} \ + } while(0) +#endif + + +/** + * @brief Начать отсчет задержки. + * @param _pvar_ Указатель на переменную типа uint32_t для хранения времени старта. + * @details После вызова этого макроса переменная _pvar_ содержит текущее количество миллисекунд + * с момента запуска системы (@ref local_time). + * + * Используется для реализации неблокирующих задержек. + */ +#define msDelayStart(_pvar_) *(_pvar_) = local_time() + +/** + * @brief Проверяет, активна ли задержка. + * @param _ms_ Длительность задержки в миллисекундах. + * @param _pvar_ Указатель на переменную, в которой сохранено время начала (@ref msDelayStart). + * @retval 1 Задержка еще активна. + * @retval 0 Задержка завершена. + * @details + * Возвращает true, пока время задержки не истекло. Используется в проверках, + * когда нужно **действовать, пока задержка выполняется**. Пример: + * @code + * while(msDelayWhileActive(1000, &tick)) { + * // выполняем другие задачи, задержка не блокирует поток + * } + * @endcode + */ +#define msDelayWhileActive(_ms_, _pvar_) (local_time() - *(_pvar_) < _ms_) + +/** + * @brief Проверяет, завершилась ли задержка. + * @param _ms_ Длительность задержки в миллисекундах. + * @param _pvar_ Указатель на переменную, в которой сохранено время начала (msDelayStart). + * @retval 1 Задержка завершена. + * @retval 0 Задержка еще активна. + * @details + * Возвращает true, когда задержка уже завершена. Используется в проверках, + * когда нужно **выполнить действие только после окончания задержки**. Пример: + * @code + * if(msDelayWaitDone(1000, &tick)) { + * // выполняем действие после завершения задержки + * } + * @endcode + */ +#define msDelayWaitDone(_ms_, _pvar_) (local_time() - *(_pvar_) >= _ms_) + +/** DELAYS_DEFINES + * @} + */ + + +/*************************************************************************** +*******************************UTIL_DEFINES********************************/ +static int dummy; +/** + * @addtogroup UTILS_DEFINES Utils defines + * @ingroup MYLIBS_DEFINES + * @brief Общие вспомогательные макросы + * @{ + */ + +/** + * @brief Обнуление структуры. + * @param _struct_ Структура, которую нужно обнулить. + * @details Макрос использует memset для обнуления всей памяти структуры. + * Используется для быстрой и безопасной инициализации переменных структур до нуля. + */ +#define ClearStruct(_struct_) memset(&(_struct_), 0, sizeof(_struct_)) + +/** + * @brief Деление с округлением вверх + * @param _val_ Делимое. + * @param _div_ Делитель. + * @return Результат деления, округленный вверх. + * @details Если результат деления без остатка: он возвращается как есть + Если с остатком - округляется вверх + */ +//#define Divide_Up(_val_, _div_) (((_val_)%(_div_))? (_val_)/(_div_)+1 : (_val_)/_div_) /* через тернарный оператор */ +#define Divide_Up(_val_, _div_) ((_val_ - 1) / _div_) + 1 /* через мат выражение */ + +/** + * @brief Swap between Little Endian and Big Endian + * @param v Исходное 16-битное значение. + * @return Результат с поменяными местами старшим и младшим байтом. + * @details Переключения между двумя типами хранения слова: HI-LO байты и LO-HI байты. + */ +#define ByteSwap16(v) (((v&0xFF00) >> (8)) | ((v&0x00FF) << (8))) + +/** + * @brief Абсолютное значение числа + * @param x Число. + * @return Абсолютное значение числа x. + * @details Берет число по модулю. Хз как работает библиотечный abs в stdlib.h, мб это быстрее, но вряд ли конечно. + */ +#define ABS(x) ( ((x) > 0)? (x) : -(x)) + +/** UTILS_DEFINES + * @} + */ + + + +/** + * @cond LIBS_INTERNAL + */ + + +/** + * @brief Аналог HAL макроса для привязки DMA к UART. + * @note @ref __HAL_LINKDMA. + */ +#define __USER_LINKDMA(__HANDLE__, __PPP_DMA_FIELD__, __DMA_HANDLE__) \ +do{ \ +(__HANDLE__)->__PPP_DMA_FIELD__ = (__DMA_HANDLE__); \ +(__DMA_HANDLE__)->Parent = (__HANDLE__);} while(0U) + + +/** @endcond */ +#endif //__MYLIBS_DEFINES_H_ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/mylibs_include.h b/MyLibsGeneral/Inc/mylibs_include.h new file mode 100644 index 0000000..e9acba2 --- /dev/null +++ b/MyLibsGeneral/Inc/mylibs_include.h @@ -0,0 +1,125 @@ +/** +************************************************************************** +* @file mylibs_include.h +* @brief Заголочный файл для всех библиотек +************************************************************************** +* @details +Здесь нужно собрать библиотеки и дефайны, которые должны быть видны во всем проекте, +чтобы не подключать 100 инклюдов в каждом ".c" файле +************************************************************************** +* @defgroup MYLIBS_ALL My Libs +* @brief Все используемые MyLibs библиотеки +* @details +Для подключения библиотеки необходимо: +- Сконфигурировать mylibs_config.h: + - Подключить заголовочный файл HAL библиотеки конкретного МК (напр. stm32f4xx_hal.h) + - Подключить другие заголовочные файлы которые общие для всего проекта и должны быть видны + - +- Подключить mylibs_include.h туда, где необходим доступ к библиотекам. + +* @defgroup MYLIBS_PERIPHERAL Peripheral +* @ingroup MYLIBS_ALL +* @brief Модули для управления периферией +* +*************************************************************************/ +#ifndef __MYLIBS_INCLUDE_H_ +#define __MYLIBS_INCLUDE_H_ + +#include "mylibs_defs.h" + + +#ifdef ARM_MATH_CM4 + #include "arm_math.h" +#else + #include "math.h" +#endif + + +#ifdef INCLUDE_BIT_ACCESS_LIB +#include "bit_access.h" +#endif + +#ifdef INCLUDE_TRACKERS_LIB +#include "trackers.h" +#else + #define TrackerTypeDef(num_user_vars) void * + #define num_of_usercnts(_user_) 0 + #define assert_tracecnt(_cntstruct_, _uservarnumb_) 0 + #define if_assert_usertracker(_cntstruct_, _uservarnumb_) if(0) + #define tern_assert_usertracker(_cntstruct_, _uservarnumb_) 0 + #define TrackerGet_Ok(_cntstruct_) dummy + #define TrackerGet_Err(_cntstruct_) dummy + #define TrackerGet_Warn(_cntstruct_) dummy + #define TrackerGet_User(_cntstruct_, _uservarnumb_) dummy + #define TrackerCnt_Ok(_cntstruct_) + #define TrackerCnt_Err(_cntstruct_) + #define TrackerCnt_Warn(_cntstruct_) + #define TrackerCnt_User(_cntstruct_, _uservarnumb_) + #define TrackerWrite_User(_cntstruct_, _uservarnumb_, _val_) + #define TrackerClear_All(_cntstruct_) + #define TrackerClear_Ok(_cntstruct_) + #define TrackerClear_Err(_cntstruct_) + #define TrackerClear_Warn(_cntstruct_) + #define TrackerClear_User(_cntstruct_) + #define TrackerClear_UserAll(_cntstruct_) +#endif + +#ifdef INCLUDE_TRACE_LIB +#include "trace.h" +#else +#define my_printf(...) +#define log_printf(TAG, fmt, ...) +#define TRACE_GPIO_SET(_gpio_,_pin_) +#define TRACE_GPIO_RESET(_gpio_,_pin_) +#define RTT_FlashPrepare(...) +#define RTT_EraseFlash(...) 0 +#define RTT_SaveToFlash(...) 0 +#define RTT_ReadFromFlash(...) 0 +#define HF_CheckRecovered(...) 0 +#define HF_HandleFault(...) +#endif + +#ifdef INCLUDE_EVOLVE_OPTIMIZER +#include "evolve_optimizer.h" +#else +typedef struct { + uint16_t n_params; + uint16_t n_cand; + uint16_t n_best; + uint16_t iq_mutation; + int32_t loss[0]; + int32_t candidates[0][0]; +} EvolveOptimizer_t; +#define EvolveOptimizer_Init(opt, n_params, n_cand, n_best, iq_mutation, start_params) +#define EvolveOptimizer_Step(opt, params, LossFunc) +#define PARAM_SCALE_Q16(x, min_val, max_val) (x) +#define PARAM_UNSCALE_Q16(q16_val, min_val, max_val) (q16_val) +#endif + +#ifdef INCLUDE_GENERAL_PERIPH_LIBS + +#include "__general_flash.h" +#include "general_gpio.h" +#ifdef HAL_SPI_MODULE_ENABLED +#include "general_spi.h" +#endif +#ifdef HAL_UART_MODULE_ENABLED +#include "general_uart.h" +#endif +#ifdef HAL_TIM_MODULE_ENABLED +#include "general_tim.h" +#endif + +#endif //INCLUDE_GENERAL_PERIPH_LIBS + + + + +/////////////////////////---USER SETTINGS---///////////////////////// +// user includes + +// user settings +/////////////////////////---USER SETTINGS---///////////////////////// + + +#endif // __MYLIBS_INCLUDE_H_ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/trace.h b/MyLibsGeneral/Inc/trace.h new file mode 100644 index 0000000..d0f5c7f --- /dev/null +++ b/MyLibsGeneral/Inc/trace.h @@ -0,0 +1,591 @@ +/** +************************************************************************** +* @file trace.h +* @brief Заголочный файл для работы с трассировкой. +************************************************************************** +* @addtogroup TRACE Trace defines +* @ingroup MYLIBS_DEFINES +* @brief Дефайны для работы с трассировкой +*************************************************************************/ +#ifndef __TRACE_H_ +#define __TRACE_H_ +#include "mylibs_defs.h" + +#include +/** + * @addtogroup TRACE_SERIAL Serial trace defines + * @ingroup TRACE + * @brief Дефайны для работы с serial трассировкой (SWO, RTT) + * @details В зависимости от настроек определяется дефайн @ref my_printf() и @ref log_printf() для работы с трассировкой: + - @ref SERIAL_TRACE_ENABLE - Если трассировка отключена, то все дефайны определяются как 'ничего' + и на производительность кода не влияют + + - @ref RTT_TRACE_ENABLE - для RTT это будет вызов функции SEGGER_RTT_printf() + + Предварительно надо подключить библиотеку SEGGER RTT (SEGGER_RTT.h) и вызвать функцию SEGGER_RTT_Init() + + - @ref SWO_TRACE_ENABLE для SWO это будет просто printf() + + Предварительно надо подключить библиотеку STDOUT и retarget под ITM: + + @verbatim + Manage Run-Time Environment -> Compiler -> I/O -> STDOUT -> ITM + @endverbatim + + Для SWO также надо включить трассировку: + + @verbatim + Options For Target -> Debug -> Debugger Settings + @endverbatim + + В вкладке Debug: + - Port = SW + В вкладке Trace: + - Указать Core Clock + - Выставить Trace Port = SWO + - ITM - выбрать нужный порт (для Keil нулевой порт) + + + * @{ + * + * @def my_printf(...) + * @brief Универсальный макрос для вывода трассировки + * @details Варианты реализации: + * - RTT_TRACE_ENABLE `SEGGER_RTT_printf(0, ...)` + * - SWO_TRACE_ENABLE - `printf(...)` + * - NO_TRACE - пустой макрос + * + * @def log_printf(TAG, fmt, ...) + * @brief Макрос логирования с поддержкой уровней @ref LOG_LEVEL + * @param TAG Тэг лога + * @param fmt, ... Форматируемая строка + * @details Варианты реализации: + * - @ref LOG_LEVEL == 0 - логирование отключено (макрос пустой) + * - @ref LOG_LEVEL == 1 - выводится время @ref local_time и TAG + * @code + [123] [ADC] Measure Done + [456] [ADC] Measure Err + * @endcode + * - @ref LOG_LEVEL >= 2 - выводится время, TAG, имя файла и номер строки + * @code + [123] [ADC] (../Core/Src/adc.c:75) Measure Done + [456] [ADC] (../Core/Src/adc.c:80) Measure Err + * @endcode + */ +#ifdef SERIAL_TRACE_ENABLE + + #if defined(RTT_TRACE_ENABLE) + #undef SWO_TRACE_ENABLE + #include "SEGGER_RTT.h" + #define my_printf(...) SEGGER_RTT_printf(0, __VA_ARGS__) + #elif defined(SWO_TRACE_ENABLE) + #undef RTT_TRACE_ENABLE + #define my_printf(...) printf(__VA_ARGS__) + #else // NO_TRACE + #define my_printf(...) + #warning No trace is selected. Serial debug wont work. + #endif // RTT_TRACE_ENABLE/SWO_TRACE_ENABLE/NO_TRACE +#else //SERIAL_TRACE_ENABLE + + #define my_printf(...) + #undef RTT_TRACE_ENABLE + #undef SWO_TRACE_ENABLE + +#endif //SERIAL_TRACE_ENABLE + + +#ifndef local_time +#define local_time() HAL_GetTick() ///< Локальное время +#endif +#ifndef LOG_LEVEL +#define LOG_LEVEL 1 ///< @brief Уровень логирования (по умолчанию == 1) +#endif + + +#if LOG_LEVEL == 0 // лог отключен + #define \ +log_printf(TAG, fmt, ...) +#elif LOG_LEVEL == 1 // только тэг + #define log_printf(TAG, fmt, ...) \ +my_printf("\n[%lu] [%s] " fmt, \ +(unsigned long)local_time(), TAG, ##__VA_ARGS__) +#elif LOG_LEVEL >= 2 // всё + #define log_printf(TAG, fmt, ...) \ +my_printf("\n[%lu] [%s] (%s:%d) " fmt, \ +(unsigned long)local_time(), TAG, __FILE__, __LINE__, ##__VA_ARGS__) +#endif + +/** TRACE_SERIAL + * @} + */ + +/** + * @addtogroup TRACE_GPIO GPIO trace defines + * @ingroup TRACE + * @brief Дефайны для работы с GPIO трассировкой + * @details Определяется дефайны для работы с GPIO трассировкой: + - TRACE_GPIO_RESET() - для сброса ножки GPIO (через BSRR) + - TRACE_GPIO_SET() - для выставления ножки GPIO (через BSRR) + + - Если трассировка @ref GPIO_TRACE_ENABLE отключена, то все дефайны определяются как 'ничего' + и на производительность кода не влияют + * @{ + * + * @def TRACE_GPIO_RESET(_gpio_, _pin_) + * @brief Сбросить указанную ножку GPIO + * @param _gpio_ Указатель на структуру GPIO (напр. GPIOA) + * @param _pin_ Номер ножки (напр. GPIO_PIN_0) + * @details Варианты реализации: + * - GPIO_TRACE_ENABLE не определён - макрос пустой + * - GPIO_TRACE_ENABLE определён - устанавливает бит сброса через BSRR ((_pin_)<<16) + * + * @def TRACE_GPIO_SET(_gpio_, _pin_) + * @brief Установить указанную ножку GPIO + * @param _gpio_ Указатель на структуру GPIO (например GPIOA) + * @param _pin_ Номер ножки (напр. GPIO_PIN_0) + * @details Варианты реализации: + * - GPIO_TRACE_ENABLE не определён - макрос пустой + * - GPIO_TRACE_ENABLE определён - устанавливает бит установки через BSRR (_pin_) + */ +#ifndef GPIO_TRACE_ENABLE + #define TRACE_GPIO_SET(_gpio_,_pin_) + #define TRACE_GPIO_RESET(_gpio_,_pin_) +#else + #define TRACE_GPIO_SET(_gpio_,_pin_) (_gpio_)->BSRR = (((_pin_))) + #define TRACE_GPIO_RESET(_gpio_,_pin_) (_gpio_)->BSRR = ((_pin_)<<16) +#endif //GPIO_TRACE_ENABLE + + +/** TRACE_GPIO + * @} + */ + + + +#if defined(HAL_MODULE_ENABLED) && defined(RTT_TRACE_ENABLE) + +/** + * @addtogroup TRACE_RTT_FLASH Flash RTT Buffer + * @ingroup TRACE + * @brief Макросы и функции для сохранения/чтения RTT буфера в Flash + * @details Модуль позволяет сохранять данные RTT буфера во Flash и читать их обратно по тегам. + * Теги работают следующим образом: + * - Базовый тег (младший байт = 0): модуль сам выбирает первый свободный слот во Flash; + * новые записи получают автоинкрементированный младший байт тега (от 0x00 до 0xFF). + * - Конкретный тег (младший байт != 0): запись или чтение происходит строго с указанным тегом; + * если слот с таким тегом уже занят, запись не выполняется. + * - Автоинкремент позволяет хранить несколько последовательных записей в пределах одного базового тега, + * без необходимости вручную отслеживать адреса Flash или позиции буферов. + * + * Параметры: + * - @ref RTT_FLASH_BUFFER_SIZE - Размер буфера RTT в Flash + * - @ref RTT_FLASH_SECTOR - Сектор FLASH куда положится RTT буфер + * - @ref RTT_FLASH_SECTOR_START - Начало сектора RTT_FLASH_SECTOR + * - @ref RTT_FLASH_SECTOR_END - Конец сектора RTT_FLASH_SECTOR + * + * @{ + */ + + +/** + * @brief Структура RTT, которая будет положена в Flash + */ +typedef struct { + uint32_t tag; ///< Уникальный идентификатор буфера + uint32_t size; ///< Размер данных + char data[RTT_FLASH_BUFFER_SIZE]; ///< Буфер RTT +} RTT_FlashHeader_t; + +/** + * @brief Подготовка Flash к записи + * @details Сбрасывает ошибки Flash и ожидает готовности перед записью + */ +__STATIC_FORCEINLINE void RTT_FlashPrepare(void) +{ + HAL_FLASH_Unlock(); + __HAL_FLASH_CLEAR_FLAG(FLASH_FLAG_PGSERR | FLASH_FLAG_WRPERR | FLASH_FLAG_OPERR); + while (__HAL_FLASH_GET_FLAG(FLASH_FLAG_BSY)) { + __NOP(); + } +} + +/** + * @brief Сохраняет последние символы RTT-буфера в Flash по тегу + * @param tag Базовый или конкретный идентификатор буфера. + * @param tail_size Количество последних символов RTT для копирования + * @param buf_num Указатель на переменную в которую запишется номер буфера для конкретного тега + * @return >=0 — номер буфера (тег) для записи, <0 — ошибка (нет места, тег уже занят, ошибка записи в флеш) + * + * @details Автоматически копирует последние tail_size символов из RTT-буфера + * и записывает их во Flash. + * Тег может быть базовым или конкретным: + * - Если базовый (младший байт == 0) — будет выбран первый свободный слот с автоинкрементом. + * Автоинкремент формируется в пределах от 0x1 до 0xFF + * - Если конкретный (младший байт != 0) — запись выполняется только с этим тегом, иначе ошибка. + * + */ +__STATIC_FORCEINLINE int RTT_SaveToFlash(uint32_t tag, uint32_t tail_size) +{ + if (tag == 0xFFFFFFFF) + return -1; // Неверный тег + + SEGGER_RTT_BUFFER_UP *up = &_SEGGER_RTT.aUp[0]; + unsigned buf_size = up->SizeOfBuffer; + unsigned wr = up->WrOff; + + // Ограничиваем по размеру буфера RTT и RTT_FLASH_BUFFER_SIZE + unsigned n = (tail_size > buf_size) ? buf_size : tail_size; + if (n > RTT_FLASH_BUFFER_SIZE) + n = RTT_FLASH_BUFFER_SIZE; + + uint32_t addr = RTT_FLASH_SECTOR_START; + RTT_FlashHeader_t *flash_hdr = NULL; + uint32_t base_tag = tag & 0xFFFFFF00; + uint32_t next_tag = (tag & 0xFF) == 0 ? tag + 1 : tag; + + // Ищем первый свободный слот, параллельно автоинкрементируем тег + while ((addr + sizeof(RTT_FlashHeader_t)) <= RTT_FLASH_SECTOR_END) + { + flash_hdr = (RTT_FlashHeader_t *)addr; + + if (flash_hdr->tag == 0xFFFFFFFF) + break; // Нашли свободное место + + + if((flash_hdr->tag & 0xFFFFFF00) == base_tag) // выбраный тег + { + if ((tag & 0xFF) == 0) // если он базовый - ищем последний + next_tag = flash_hdr->tag + 1; // автоинкремент + else + if(flash_hdr->tag == tag) // если он конкретный и уже существует - то ошибка + return -1; // конкретный тег уже занят + } + + + if(next_tag - tag > 0xFF) + return -1; // автоинкремент слишком большой + + addr += sizeof(RTT_FlashHeader_t); + } + + if ((addr + sizeof(RTT_FlashHeader_t)) > RTT_FLASH_SECTOR_END) + return -1; // Нет свободного места + + // Копируем последние n символов из RTT + char temp[RTT_FLASH_BUFFER_SIZE]; + unsigned valid_count = 0; + + for (unsigned i = 0; i < n; i++) + { + unsigned idx = (wr + buf_size - n + i) % buf_size; + char c = up->pBuffer[idx]; + if (c != 0) + temp[valid_count++] = c; + } + + RTT_FlashPrepare(); + + // Формируем структуру в RAM + RTT_FlashHeader_t flash_data; + flash_data.tag = next_tag; + flash_data.size = valid_count; + memcpy(flash_data.data, temp, valid_count); + + // Записываем структуру во Flash (по 4 байта) + const uint32_t *p = (const uint32_t *)&flash_data; + for (unsigned i = 0; i < sizeof(RTT_FlashHeader_t) / 4; i++) + { + if(HAL_FLASH_Program(FLASH_TYPEPROGRAM_WORD, addr + i * 4, p[i]) != HAL_OK) + return -1; + } + + HAL_FLASH_Lock(); + __DSB(); + __ISB(); + + + return (int)(next_tag&0xFF); +} + + +/** + * @brief Читает последние символы RTT-буфера из Flash по тегу + * @param tag Базовый или конкретный идентификатор буфера. + * @param Buffer Буфер назначения для копирования данных + * @param tail_size Количество последних символов, которые нужно прочитать + * @param read_size Количество считанных символов + * @return >=0 — номер буфера (тег) для записи, <0 — ошибка (тег не найден или структура повреждена) + * + * @details Копирует последние tail_size символов из найденной записи Flash в Buffer. + * Тег может быть базовым или конкретным: + * - Если базовый (младший байт == 0) — будет прочитана последняя запись из группы. + * - Если конкретный (младший байт != 0) — прочитывается именно эта запись. + */ +__STATIC_FORCEINLINE int RTT_ReadFromFlash(uint32_t tag, char *Buffer, uint32_t tail_size, uint32_t *read_size) +{ + if (!Buffer || tail_size == 0) + return -1; // Неверные параметры + + if (tag == 0xFFFFFFFF) + return -1; // Недопустимый тег + + uint32_t addr = RTT_FLASH_SECTOR_START; + RTT_FlashHeader_t *flash_hdr = NULL; + RTT_FlashHeader_t *target_hdr = NULL; + uint32_t base_tag = tag & 0xFFFFFF00; + + // Поиск записи по тегу + while ((addr + sizeof(RTT_FlashHeader_t)) <= RTT_FLASH_SECTOR_END) + { + flash_hdr = (RTT_FlashHeader_t *)addr; + + if (flash_hdr->tag == 0xFFFFFFFF) + break; // Достигнут конец записанных структур + + // выбраный тег + if((flash_hdr->tag & 0xFFFFFF00) == base_tag) + { + if ((tag & 0xFF) == 0) // если он базовый - ищем последний + target_hdr = flash_hdr; // сохраняем последний в группе + else + if(flash_hdr->tag == tag) // если он конкретный и найден - берем его + { + target_hdr = flash_hdr; + break; // конкретный тег найден + } + } + + addr += sizeof(RTT_FlashHeader_t); + } + + if (!target_hdr) return -1; // Тег не найден + + // Проверка корректности размера + if (target_hdr->size > RTT_FLASH_BUFFER_SIZE) + return -1; // Повреждённая запись + + // Определяем количество читаемых символов + uint32_t n = (tail_size > target_hdr->size) ? target_hdr->size : tail_size; + // Начальная позиция для чтения последних tail_size символов + uint32_t start = target_hdr->size - n; + // Копируем данные из Flash в RAM + memcpy(Buffer, &target_hdr->data[start], n); + + if(read_size != NULL) + { + *read_size = n; + } + + __DSB(); + __ISB(); + + return (int)(target_hdr->tag & 0xFF); +} + +/** + * @brief Стирание сектора Flash с RTT-буфером + */ +__STATIC_FORCEINLINE int RTT_EraseFlash(void) +{ + FLASH_EraseInitTypeDef eraseInit; + uint32_t pageError = 0; + + RTT_FlashPrepare(); + + eraseInit.TypeErase = FLASH_TYPEERASE_SECTORS; + eraseInit.Sector = RTT_FLASH_SECTOR; + eraseInit.NbSectors = 1; + + if (HAL_FLASHEx_Erase(&eraseInit, &pageError) != HAL_OK) + { + return -1; + } + return 0; + HAL_FLASH_Lock(); +} + +/** TRACE_RTT_FLASH + * @} + */ + +#else // HAL_MODULE_ENABLED && RTT_TRACE_ENABLE +#define RTT_FlashPrepare(...) +#define RTT_EraseFlash(...) 0 +#define RTT_SaveToFlash(...) 0 +#define RTT_ReadFromFlash(...) 0 +#endif // HAL_MODULE_ENABLED && RTT_TRACE_ENABLE + + + + +/** + * @addtogroup TRACE_HARDFAULT Hardfault trace defines + * @ingroup TRACE + * @brief Модуль трассировки HardFault с возможностью сохранения RTT буфера во Flash + * @details + * Этот модуль позволяет сохранять контекст процессора и последние символы RTT буфера при возникновении HardFault. + * + * Механизм работы: + * - При срабатывании HardFault вызывается HF_HandleFault(), который: + * 1. Получает указатель на стек, где произошёл HardFault (MSP или PSP). + * 2. Выводит значения регистров R0-R3, R12, LR, PC, PSR и системных регистров SCB. + * 3. Формирует строку с регистрами и копирует последние символы RTT буфера. + * 4. Сохраняет данные во Flash с базовым тегом HF_RTT_TAG_BASE. + * - Для восстановления последнего HardFault используется HF_CheckRecovered(), который: + * 1. Читает запись во Flash по базовому тегу. + * 2. Выводит сохранённый RTT буфер и контекст регистров. + * 3. Опционально стирает Flash после восстановления. + * + * Параметры: + * - @ref HARDFAULT_SERIAL_TRACE - Включить обработку и serial трассировку Hardfault + * Если отключена то вставляются заглушки, никак не влияющие на параметры и остальную программу + * - @ref HF_RTT_TAG_BASE - Базовый тег RTT Flash для HardFault + * - @ref HF_RTT_TAIL_SIZE - Размер буфера RTT, который сохранится при Hardfault + * - @ref HF_STACK_DUMP_WORDS - Сколько слов стека будет проанализировано во время Hardfault + * - @ref HF_FLASH_ADDR - Адрес FLASH куда положится RTT буфер + * - @ref HF_RAM_END - Конец RAM памяти (чтобы во время анализа стека не выйти за пределы) + * + @code + void Hardfault() + { + HF_HandleFault(); + NVIC_SystemReset(); + } + + int main() + { + if(HF_CheckRecovered(0)) + { + //set hardfault error + RTT_EraseFlash(); // erase rtt flash after message readed + } + } + @endcode + * @{ + */ +#if defined(HAL_MODULE_ENABLED) && defined(HARDFAULT_SERIAL_TRACE) + +#ifndef HF_RTT_TAIL_SIZE +#define HF_RTT_TAIL_SIZE RTT_FLASH_BUFFER_SIZE ///< Размер буфера RTT, который сохранится при Hardfault +#endif + +/** + * @brief Контекст стек-фрейма процессора при HardFault + * @details Сохраняет регистры R0-R3, R12, LR, PC, PSR для последующего анализа. + */ +typedef struct { + uint32_t r0; ///< Регистр R0 + uint32_t r1; ///< Регистр R1 + uint32_t r2; ///< Регистр R2 + uint32_t r3; ///< Регистр R3 + uint32_t r12; ///< Регистр R12 + uint32_t lr; ///< Link Register + uint32_t pc; ///< Program Counter + uint32_t psr; ///< Program Status Register +} HF_StackFrame_t; + +/** + * @brief Проверка и вывод последнего HardFault-трейса из Flash + * @details + * Функция ищет последнюю запись HardFault по базовому тегу HF_RTT_TAG_BASE + * и выводит её содержимое в консоль. После успешного вывода Flash можно опционально очистить. + * + * @return int + * - 1 — данные HardFault найдены и выведены + * - 0 — данные отсутствуют или тег не найден + * + * @note Вызов рекомендуется при инициализации приложения для анализа предыдущего сбоя. + */ +__STATIC_FORCEINLINE int HF_CheckRecovered(int erase) +{ + char buffer[RTT_FLASH_BUFFER_SIZE]; + uint32_t read_size = 0; + int n_hardfault = RTT_ReadFromFlash(HF_RTT_TAG_BASE, buffer, HF_RTT_TAIL_SIZE, &read_size); + if (n_hardfault > 0) + { + my_printf("\n--- Recovered HardFault RTT buffer #%u ---\n", n_hardfault); + for (int i = 0; i < read_size; i++) + { + char c = buffer[i]; + if (c == 0 || c == (char)0xFF) break; + my_printf("%c", c); + } + + if(erase) + RTT_EraseFlash(); + my_printf("\n--------- HardFault Dump End ---------\n"); + return 1; + } + return 0; +} + + +static HF_StackFrame_t *stack_frame; +static uint32_t stack_dump[HF_STACK_DUMP_WORDS]; +static void *ret_adr[10] = {0}; +/** + * @brief Обработчик HardFault + * @details + * Вызывается из прерывания HardFault или в любом месте где понятно что ошибка критическая. + * Последовательно выполняет: + * 1. Определяет активный стек (MSP или PSP) на момент сбоя. + * 2. Сохраняет значения регистров R0-R3, R12, LR, PC, PSR. + * 3. Выводит системные регистры CFSR, HFSR, DFSR, AFSR, MMFAR, BFAR. + * 4. Формирует stack trace с 3 уровнями возврата. + * 5. Копирует последние символы RTT буфера. + * 6. Сохраняет все данные во Flash через RTT_SaveToFlash с базовым тегом HF_RTT_TAG_BASE. + * + * @note Функция защищена, так как вызывается в контексте сбоя — минимизирует использование вызовов HAL. + */ +__STATIC_FORCEINLINE void HF_HandleFault(void) +{ + // Получаем указатель на стек, где произошёл HardFault + __ASM volatile( + "TST lr, #4 \n" + "ITE EQ \n" + "MRSEQ %[ptr], MSP\n" + "MRSNE %[ptr], PSP\n" + : [ptr] "=r"(stack_frame) + ); + + my_printf("\n===== HardFault occurred! =====\n"); + my_printf("R0 = 0x%08X\n", stack_frame->r0); + my_printf("R1 = 0x%08X\n", stack_frame->r1); + my_printf("R2 = 0x%08X\n", stack_frame->r2); + my_printf("R3 = 0x%08X\n", stack_frame->r3); + my_printf("R12 = 0x%08X\n", stack_frame->r12); + my_printf("LR = 0x%08X\n", stack_frame->lr); + my_printf("PC = 0x%08X\n", stack_frame->pc); + my_printf("PSR = 0x%08X\n", stack_frame->psr); + + my_printf("CFSR = 0x%08X\n", SCB->CFSR); + my_printf("HFSR = 0x%08X\n", SCB->HFSR); + my_printf("DFSR = 0x%08X\n", SCB->DFSR); + my_printf("AFSR = 0x%08X\n", SCB->AFSR); + my_printf("MMFAR = 0x%08X\n", SCB->MMFAR); + my_printf("BFAR = 0x%08X\n", SCB->BFAR); + + // --- Stack trace --- + my_printf("--- Stack trace ---\n"); + ret_adr[0] = __builtin_return_address(0); + ret_adr[1] = __builtin_return_address(1); + ret_adr[2] = __builtin_return_address(2); + + for (int i = 0; i < 3; i++) // развернуть n уровней + { + if(ret_adr[i]) + my_printf(" #%d: 0x%08lX\r\n", i, ret_adr[i]); // -1 для Thumb + } + RTT_SaveToFlash(HF_RTT_TAG_BASE, HF_RTT_TAIL_SIZE); +} +#else // HAL_MODULE_ENABLED && HARDFAULT_SERIAL_TRACE +#define HF_CheckRecovered(...) 0 +#define HF_HandleFault(...) +#endif // HAL_MODULE_ENABLED && HARDFAULT_SERIAL_TRACE +/** TRACE_HARDFAULT + * @} + */ + + + +#endif //__TRACE_H_ \ No newline at end of file diff --git a/MyLibsGeneral/Inc/trackers.h b/MyLibsGeneral/Inc/trackers.h new file mode 100644 index 0000000..9313f39 --- /dev/null +++ b/MyLibsGeneral/Inc/trackers.h @@ -0,0 +1,163 @@ +/** +************************************************************************** +* @file trackers.h +* @brief Заголочный файл для работы с трекерами @ref TRACKERS. +************************************************************************** +* @addtogroup TRACKERS Trackers defines +* @ingroup MYLIBS_DEFINES +* @brief Дефайны для работы с трекерами +* @details +Есть дефайн для объявления структуры трекера: TrackerTypeDef(num_user_vars). +Структура состоит из следующих элементов: +- cnt_ok +- cnt_err +- cnt_warn +- user[num_user_vars] +Также есть ряд функций (дефайнов) для обращения к элементам этой структуры. + +Параметры для конфигурации: +- @ref TRACKERS_ENABLE - Включить трекеры + Если трекеры @ref TRACKERS_ENABLE отключены, то все дефайны определяются как ничего + и на производительность кода не влияют + +@par Пример: + +Определяем typedef трекера измерений Measure_TrackerTypeDef + +@verbatim + typedef TrackerTypeDef(MEASURE_USER_VARS_NUMB) Measure_TrackerTypeDef; +@endverbatim + +И через @ref Measure_TrackerTypeDef структура подключается в другие структуры + +Для работы с структурой можно использовать функции: +- Для получения значения: + - TrackerGet_Ok() + - TrackerGet_Err() + - TrackerGet_Warn() + - TrackerGet_User(n) + +- Для записи значения: + - TrackerCnt_Ok() + - TrackerCnt_Err() + - TrackerCnt_Warn() + - TrackerCnt_User() + - TrackerWrite_User(n) + +- Для очищения значения: + - TrackerClear_All() + - TrackerClear_Ok() + - TrackerClear_Err() + - TrackerClear_Warn() + - TrackerClear_User(n) + - TrackerClear_UserAll() +* @{ +*************************************************************************/ +#ifndef __TRACKERS_H_ +#define __TRACKERS_H_ +#include "mylibs_defs.h" + +#ifdef TRACKERS_ENABLE + /** + * @brief Структура для счетчиков отладки + * @param num_user_vars - количество пользовательских переменных + * @details Содержит счетчик для успешных событый (cnt_ok), + * счетчик для ошибок (cnt_err), счетчик для предупреждений (cnt_warn). + * + * Также есть возможность объявить пользовательские переменные в + * количестве штук. + */ + #define TrackerTypeDef(num_user_vars) \ + struct \ + { \ + uint32_t cnt_ok; \ + uint32_t cnt_err; \ + uint32_t cnt_warn; \ + uint32_t user[num_user_vars]; \ + } + + /** @brief Получить количетство пользовательских переменных */ + #define num_of_usercnts(_user_) (sizeof(_user_) / sizeof(uint32_t)) + /** @brief Проверка существует ли указанная пользовательская переменная */ + #define assert_usertracker(_cntstruct_, _uservarnumb_) ((_uservarnumb_) < num_of_usercnts((_cntstruct_).user)) + /** @brief Условие для проверки существует ли указанная пользовательская переменная */ + #define if_assert_usertracker(_cntstruct_, _uservarnumb_) if(assert_usertracker(_cntstruct_, _uservarnumb_)) + /** @brief Тернарный оператор для проверки существует ли указанная пользовательская переменная */ + #define tern_assert_usertracker(_cntstruct_, _uservarnumb_) (assert_usertracker(_cntstruct_, _uservarnumb_)) ? _uservarnumb_ : 0 + + + /** @brief Считать счетчик успешных событий */ + #define TrackerGet_Ok(_cntstruct_) (_cntstruct_).cnt_ok + /** @brief Считать счетчик ошибок */ + #define TrackerGet_Err(_cntstruct_) (_cntstruct_).cnt_err + /** @brief Считать счетчик предупреждений */ + #define TrackerGet_Warn(_cntstruct_) (_cntstruct_).cnt_warn + /** + * @brief Считать пользовательскую переменную + * @note Здесь нет проверки - существует ли пользовательская переменная! + * Есть возможность выйти за границы структуры!!! + * Чтобы этого избежать можно использовать дефайн #ref assert_usertracker() + @verbatim + if(assert_usertracker(struct, 0)) { + TrackerGet_User(struct, 0) + } + @endverbatim + */ + #define TrackerGet_User(_cntstruct_, _uservarnumb_) (_cntstruct_).user[tern_assert_usertracker(_cntstruct_, _uservarnumb_)] + + + + /** @brief Инкрементирование счетчика успешных событий */ + #define TrackerCnt_Ok(_cntstruct_) (_cntstruct_).cnt_ok++ + /** @brief Инкрементирование счетчика ошибок */ + #define TrackerCnt_Err(_cntstruct_) (_cntstruct_).cnt_err++ + /** @brief Инкрементирование счетчика предупреждений */ + #define TrackerCnt_Warn(_cntstruct_) (_cntstruct_).cnt_warn++ + /** @brief Инкрементирование пользовательской переменной */ + #define TrackerCnt_User(_cntstruct_, _uservarnumb_) if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_]++; + /** @brief Запись числа в пользовательскую переменную */ + #define TrackerWrite_User(_cntstruct_, _uservarnumb_, _val_) if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = (_val_) + + /** @brief Очистка всей структуры */ + #define TrackerClear_All(_cntstruct_) memset(&(_cntstruct_), 0, sizeof(_cntstruct_)) + /** @brief Очистка счетчика успешных событий */ + #define TrackerClear_Ok(_cntstruct_) (_cntstruct_).cnt_ok = 0 + /** @brief Очистка счетчика ошибок */ + #define TrackerClear_Err(_cntstruct_) (_cntstruct_).cnt_err = 0 + /** @brief Очистка счетчика предупреждений */ + #define TrackerClear_Warn(_cntstruct_) (_cntstruct_).cnt_warn = 0 + /** @brief Очистка пользовательской переменной */ + #define TrackerClear_User(_cntstruct_, _uservarnumb_) if_assert_usertracker(_cntstruct_, _uservarnumb_) (_cntstruct_).user[_uservarnumb_] = 0; + /** @brief Очистка всех пользовательских переменных */ + #define TrackerClear_UserAll(_cntstruct_) memset(&(_cntstruct_).user, 0, sizeof((_cntstruct_).user)) + +#else //TRACKERS_ENABLE + + #define TrackerTypeDef(num_user_vars) void * + + #define num_of_usercnts(_user_) 0 + #define assert_tracecnt(_cntstruct_, _uservarnumb_) 0 + #define if_assert_usertracker(_cntstruct_, _uservarnumb_) if(0) + #define tern_assert_usertracker(_cntstruct_, _uservarnumb_) 0 + + #define TrackerGet_Ok(_cntstruct_) dummy + #define TrackerGet_Err(_cntstruct_) dummy + #define TrackerGet_Warn(_cntstruct_) dummy + #define TrackerGet_User(_cntstruct_, _uservarnumb_) dummy + + #define TrackerCnt_Ok(_cntstruct_) + #define TrackerCnt_Err(_cntstruct_) + #define TrackerCnt_Warn(_cntstruct_) + #define TrackerCnt_User(_cntstruct_, _uservarnumb_) + #define TrackerWrite_User(_cntstruct_, _uservarnumb_, _val_) + + #define TrackerClear_All(_cntstruct_) + #define TrackerClear_Ok(_cntstruct_) + #define TrackerClear_Err(_cntstruct_) + #define TrackerClear_Warn(_cntstruct_) + #define TrackerClear_User(_cntstruct_) + #define TrackerClear_UserAll(_cntstruct_) + +#endif //TRACKERS_ENABLE + +#endif //__TRACKERS_H_ \ No newline at end of file diff --git a/MyLibsGeneral/Src/__general_flash.c b/MyLibsGeneral/Src/__general_flash.c new file mode 100644 index 0000000..f7c5e7c --- /dev/null +++ b/MyLibsGeneral/Src/__general_flash.c @@ -0,0 +1,192 @@ +#include "__general_flash.h" +FLASH_EraseInitTypeDef EraseInitStruct; +extern HAL_StatusTypeDef res_hal; +unsigned CRC_Update; +//uint32_t PAGE_OFFSET = ((uint32_t)((4-1) * 0x0400)); +uint32_t PAGE_NUMB = 127; + + +/* Записать в память данные, произвольного размера */ +HAL_StatusTypeDef FLASH_Write_Data(uint32_t* Address, uint8_t* Data, int Data_size) +{ + HAL_StatusTypeDef res_hal; + + int data_cnt = 0; + uint32_t adr; + uint32_t word_data; + + + res_hal = HAL_FLASH_Unlock(); + if (res_hal != HAL_OK) return res_hal; + + for (adr = *Address; adr < *Address + Data_size; adr = adr + 4) + { + + + word_data = ( + Data[data_cnt] | + Data[data_cnt + 1] << 8 | + Data[data_cnt + 2] << 16 | + Data[data_cnt + 3] << 24); + + res_hal = HAL_FLASH_Program(FLASH_TYPEPROGRAM_WORD, adr, word_data); + + if (res_hal != HAL_OK) return res_hal; + + data_cnt += 4; + } + + *Address += Data_size; + res_hal = HAL_FLASH_Lock(); + + return res_hal; +} + + + +HAL_StatusTypeDef FLASH_Enable_DualBankMode(void) +{ + HAL_StatusTypeDef res_hal; + FLASH_AdvOBProgramInitTypeDef OB_DualBank; + + + res_hal = HAL_FLASH_Unlock(); + if (res_hal != HAL_OK) + return res_hal; + + res_hal = HAL_FLASH_OB_Unlock(); + if (res_hal != HAL_OK) + return res_hal; + + + FLASH->OPTCR |= FLASH_OPTCR_DB1M; + + res_hal = HAL_FLASH_OB_Launch(); + if (res_hal != HAL_OK) + return res_hal; + + res_hal = HAL_FLASH_OB_Lock(); + if (res_hal != HAL_OK) + return res_hal; + + res_hal = HAL_FLASH_Lock(); + if (res_hal != HAL_OK) + return res_hal; + + + return res_hal; +} + + + +/* Убрать защиту */ +HAL_StatusTypeDef FLASH_WriteProtection(uint32_t BankN, uint32_t WriteProtection) +{ + HAL_StatusTypeDef res_hal; + FLASH_OBProgramInitTypeDef OBInit; + + // Очистка всех возможных ошибок + FLASH->SR |= FLASH_FLAG_WRPERR // Write Protection Error + | FLASH_FLAG_PGSERR // Programming Sequence Error + | FLASH_FLAG_PGAERR // Programming Alignment Error + | FLASH_FLAG_OPERR; // Operation Error + + res_hal = HAL_FLASH_Unlock(); + if (res_hal != HAL_OK) + return res_hal; + + res_hal = HAL_FLASH_OB_Unlock(); // Разблокировка Option Bytes + if (res_hal != HAL_OK) + return res_hal; + + // Считываем текущую конфигурацию Option Bytes + HAL_FLASHEx_OBGetConfig(&OBInit); + + // Отключаем защиту на всех секторах второго банка + OBInit.OptionType = OPTIONBYTE_WRP; + OBInit.WRPState = WriteProtection; // Снять защиту + OBInit.WRPSector = OB_WRP_SECTOR_12; // Снять защиту + OBInit.Banks = BankN; // Указываем второй банк + res_hal = HAL_FLASHEx_OBProgram(&OBInit); + if (res_hal != HAL_OK) + return res_hal; + + // Записываем изменения и перезагружаем чип + res_hal = HAL_FLASH_OB_Launch(); + if (res_hal != HAL_OK) + return res_hal; + + // Считываем текущую конфигурацию Option Bytes + HAL_FLASHEx_OBGetConfig(&OBInit); + +// Блокировка Option Bytes + res_hal = HAL_FLASH_OB_Lock(); + if (res_hal != HAL_OK) + return res_hal; + + res_hal = HAL_FLASH_Lock(); + if (res_hal != HAL_OK) + return res_hal; + + return res_hal; +} +//-----------------ELEMENTARY FUNCTIONS--------------------- +/* functions for reading bytes/halswords/words */ +uint8_t FLASH_Read_Byte(uint32_t add) +{ + return (*(__IO uint8_t*)(add)); +} +uint16_t FLASH_Read_HalfWord(uint32_t add) +{ + return (*(__IO uint16_t*)(add)); +} +uint32_t FLASH_Read_Word(uint32_t add) +{ + return (*(__IO uint32_t*)(add)); +} +/* functions for writing bytes/halswords/words */ +HAL_StatusTypeDef FLASH_Write_Byte(uint32_t Address, uint8_t Data) +{ + HAL_StatusTypeDef res_hal; + + res_hal = HAL_FLASH_Unlock(); + + if (res_hal != HAL_OK) return res_hal; + + res_hal = HAL_FLASH_Program(FLASH_TYPEPROGRAM_BYTE, Address, (uint8_t)(Data)); + + if (res_hal != HAL_OK) return res_hal; + + res_hal = HAL_FLASH_Lock(); + return res_hal; +} +HAL_StatusTypeDef FLASH_Write_HalfWord(uint32_t Address, uint16_t Data) +{ + HAL_StatusTypeDef res_hal; + + res_hal = HAL_FLASH_Unlock(); + + if (res_hal != HAL_OK) return res_hal; + + res_hal = HAL_FLASH_Program(FLASH_TYPEPROGRAM_HALFWORD, Address, (uint16_t)(Data)); + + if (res_hal != HAL_OK) return res_hal; + + res_hal = HAL_FLASH_Lock(); + return res_hal; +} +HAL_StatusTypeDef FLASH_Write_Word(uint32_t Address, uint32_t Data) +{ + HAL_StatusTypeDef res_hal; + + res_hal = HAL_FLASH_Unlock(); + if (res_hal != HAL_OK) return res_hal; + + res_hal = HAL_FLASH_Program(FLASH_TYPEPROGRAM_WORD, Address, (uint32_t)(Data)); + if (res_hal != HAL_OK) return res_hal; + + res_hal = HAL_FLASH_Lock(); + return res_hal; +} +//---------------------------------------------------------- + diff --git a/MyLibsGeneral/Src/general_gpio.c b/MyLibsGeneral/Src/general_gpio.c new file mode 100644 index 0000000..6839d51 --- /dev/null +++ b/MyLibsGeneral/Src/general_gpio.c @@ -0,0 +1,326 @@ +/** +************************************************************************** +* @file general_gpio.c +* @brief Модуль для инициализации портов и работы с ними. +************************************************************************** +* @details +Реализация функций для работы с GPIO: + - Включение тактирования портов + - Инициализация светодиодов и кнопок + - Управление светодиодами: включение, выключение, моргание, плавное затухание + - Чтение состояния кнопок с фильтром от дребезга +***************************************************************************/ +#include "general_gpio.h" + +//------------------------------------------------------------------- +//------------------------GPIO INIT FUNCTIONS------------------------ + + +/** + * @brief Включить тактирование порта GPIO + */ +HAL_StatusTypeDef GPIO_Clock_Enable(GPIO_TypeDef *GPIOx) +{ + if(check_null_ptr_1(GPIOx)) + return HAL_ERROR; + + HAL_StatusTypeDef status = HAL_OK; + // choose port for enable clock + if (GPIOx==GPIOA) + __HAL_RCC_GPIOA_CLK_ENABLE(); + else if (GPIOx==GPIOB) + __HAL_RCC_GPIOB_CLK_ENABLE(); +#ifdef GPIOC + else if (GPIOx==GPIOC) + __HAL_RCC_GPIOC_CLK_ENABLE(); +#endif +#ifdef GPIOD + else if (GPIOx==GPIOD) + __HAL_RCC_GPIOD_CLK_ENABLE(); +#endif +#ifdef GPIOE + else if (GPIOx==GPIOE) + __HAL_RCC_GPIOE_CLK_ENABLE(); +#endif +#ifdef GPIOF + else if (GPIOx==GPIOF) + __HAL_RCC_GPIOF_CLK_ENABLE(); +#endif +#ifdef GPIOH + else if (GPIOx==GPIOF) + __HAL_RCC_GPIOH_CLK_ENABLE(); +#endif + else + status = HAL_ERROR; + + return status; +} + +//------------------------GPIO INIT FUNCTIONS------------------------ +//------------------------------------------------------------------- + + +//------------------------------------------------------------------- +//------------------------GPIO LED FUNCTIONS------------------------- + +/** + * @brief Инициализировать светодиод (структуру светодиода) + * @param led Указатель на структуру светодиода + * @param GPIOx Указатель на структуру порта для светодиода + * @param GPIO_PIN_X Пин для светодиода + * @param LED_ActiveLevel Состояния пина, при котором светодиод будет включен + */ +HAL_StatusTypeDef GPIO_LED_Init(GPIO_LEDTypeDef *led, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t LED_ActiveLevel) +{ + if(check_null_ptr_3(led, GPIOx, GPIO_PIN_X)) + return HAL_ERROR; + + led->LED_Port = GPIOx; + led->LED_Pin = GPIO_PIN_X; + led->LED_ActiveLvl = LED_ActiveLevel; + + GPIO_LED_Off(led); + return HAL_OK; +} + +/** + * @brief Включить светодиод + * @param led Указатель на структуру светодиода + * @return HAL Status + */ +HAL_StatusTypeDef GPIO_LED_On(GPIO_LEDTypeDef *led) +{ + if(check_null_ptr_3(led, led->LED_Port, led->LED_Pin)) + return HAL_ERROR; + + led->state = LED_IS_ON; + HAL_GPIO_WritePin(led->LED_Port, led->LED_Pin, led->LED_ActiveLvl); + + + return HAL_OK; +} +/** + * @brief Выключить светодиод + * @param led Указатель на структуру светодиода + * @return HAL Status + */ +HAL_StatusTypeDef GPIO_LED_Off(GPIO_LEDTypeDef *led) +{ + if(check_null_ptr_3(led, led->LED_Port, led->LED_Pin)) + return HAL_ERROR; + + led->state = LED_IS_OFF; + HAL_GPIO_WritePin(led->LED_Port, led->LED_Pin, !led->LED_ActiveLvl); + + + + return HAL_OK; +} +/** + * @brief Выставить светодиод по переменной + * @param led Указатель на структуру светодиода + * @param led_state Состояние светодиода + * @return HAL Status + */ +HAL_StatusTypeDef GPIO_LED_Set(GPIO_LEDTypeDef *led, uint8_t led_state) +{ + if(check_null_ptr_3(led, led->LED_Port, led->LED_Pin)) + return HAL_ERROR; + + if(led_state) + { + return GPIO_LED_On(led); + } + else + { + return GPIO_LED_Off(led); + } +} +/** + * @brief Активировать моргание светодиодом + * @param led Указатель на структуру светодиода + * @param period Период плавного моргания светодиода + * @return HAL Status + * @details Функция ставит режим моргания, который после управляется в @ref GPIO_LED_Dynamic_Handle + */ +HAL_StatusTypeDef GPIO_LED_Blink_Start(GPIO_LEDTypeDef *led, uint32_t period) +{ + if(check_null_ptr_3(led, led->LED_Port, led->LED_Pin)) + return HAL_ERROR; + + led->state = LED_IS_BLINKING; + led->LED_Period = period; + + return HAL_OK; +} + +/** + * @brief Активировать моргание светодиодом + * @param led Указатель на структуру светодиода + * @param period Период плавного моргания светодиода + * @return HAL Status + * @details Функция ставит режим моргания, который после управляется в @ref GPIO_LED_Dynamic_Handle + */ +HAL_StatusTypeDef GPIO_LED_Fading_Start(GPIO_LEDTypeDef *led, uint32_t period) +{ + if(check_null_ptr_3(led, led->LED_Port, led->LED_Pin)) + return HAL_ERROR; + + led->state = LED_IS_FADING; + led->LED_Period = period; + + + return HAL_OK; +} + +//uint8_t LED_PWM_FADING_DUTYS[LED_PWM_TICKS] = {0 1 2 3 4 5 6 7 8 9 10 11 12 } +/** + * @brief Управление динамическими режимами свечения светодиода + * @param Указатель на структуру светодиода + * @details Функция моргает/плавно моргает светодиодом в неблокирующем режиме + * Т.е. функцию надо вызывать постоянно, чтобы она мониторила тики + * и в нужный момент переключала светодиод + */ +void GPIO_LED_Dynamic_Handle(GPIO_LEDTypeDef *led) +{ + if(check_null_ptr_3(led, led->LED_Port, led->LED_Pin)) + return; + + /* Режим моргания светодиода */ + if(led->state == LED_IS_BLINKING) + { + uint32_t tickcurrent = local_time(); + /* Ожидание истечения периода моргания */ + if((tickcurrent - led->tickprev) > led->LED_Period) + { + /* Моргание */ + HAL_GPIO_TogglePin(led->LED_Port, led->LED_Pin); + + led->tickprev = tickcurrent; + } + } + /* Режим плавного моргания светодиода */ + else if(led->state == LED_IS_FADING) + { + static unsigned direction = 0; + static int duty = 0; + uint32_t tickcurrent = local_time(); + /* Ожидание момента изменения яркости */ + /* Период ШИМ 20 мс, поэтому менять яроксть надо 40 раз за период (туда обратно) */ + if((tickcurrent - led->tickprev) > led->LED_Period/(LED_PWM_TICKS*2)) + { + /* Формирование разтухания */ + if(direction == 0) + { + if(++duty >= LED_PWM_TICKS) + { + direction = 1; + duty = LED_PWM_TICKS; + } + } + /* Формирование затухания */ + else + { + if(--duty <= 0) + { + direction = 0; + duty = 0; + } + } + led->tickprev = tickcurrent; + } + /* Формирование ШИМ для изменения яркости */ + int duty_crt = (duty*duty/LED_PWM_TICKS); + if(tickcurrent%LED_PWM_TICKS < duty_crt) + { + HAL_GPIO_WritePin(led->LED_Port, led->LED_Pin, led->LED_ActiveLvl); + } + else + { + HAL_GPIO_WritePin(led->LED_Port, led->LED_Pin, !led->LED_ActiveLvl); + } + } +} +//------------------------GPIO LED FUNCTIONS------------------------- +//------------------------------------------------------------------- + +//------------------------------------------------------------------- +//------------------------GPIO SW FUNCTIONS------------------------- + +/** +* @brief Инициализировать кнопку (структуру кнопки) + * @param sw Указатель на структуру кнопки + * @param GPIOx Указатель на структуру порта для кнопки + * @param GPIO_PIN_X Пин для кнопки + * @param SW_ActiveLevel Состояния пина, когда кнопка нажата + * @return HAL Status + */ +HAL_StatusTypeDef GPIO_Switch_Init(GPIO_SwitchTypeDef *sw, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN_X, uint8_t SW_ActiveLevel) +{ + if(check_null_ptr_3(sw, GPIOx, GPIO_PIN_X)) + return HAL_ERROR; + + sw->Sw_Port = GPIOx; + sw->Sw_Pin = GPIO_PIN_X; + sw->Sw_ActiveLvl = SW_ActiveLevel; + return HAL_OK; +} + +/** + * @brief Считать состоянии кнопки + * @param sw Указатель на структуру кнопки + * @return 1 - если кнопка нажата, + * 0 - если отжата, + * -1 - если ошибка + * @details Функция включает в себя неблокирующую проверку на дребезг + * Т.е. функцию надо вызывать постоянно, чтобы она мониторила состояние кнопки + */ +int GPIO_Read_Switch(GPIO_SwitchTypeDef *sw) +{ + if(check_null_ptr_3(sw, sw->Sw_Port, sw->Sw_Pin)) + return -1; + + if(HAL_GPIO_ReadPin(sw->Sw_Port, sw->Sw_Pin) == sw->Sw_ActiveLvl) + { + sw->Sw_PrevState = 1; + + + if(sw->Sw_FilterDelay) // если включена защита от дребезга + { + if(sw->tickprev == 0) + sw->tickprev = local_time(); + + if((local_time() - sw->tickprev) >= sw->Sw_FilterDelay) + { + if(HAL_GPIO_ReadPin(sw->Sw_Port, sw->Sw_Pin) == sw->Sw_ActiveLvl) + { + return 1; + } + else + { + sw->tickprev = 0; + return 0; + } + } + } + else // если нет защиты от дребезга + { + if(HAL_GPIO_ReadPin(sw->Sw_Port, sw->Sw_Pin) == sw->Sw_ActiveLvl) + { + return 1; + } + else + { + sw->tickprev = 0; + return 0; + } + } + } + else + { + sw->Sw_PrevState = 0; + } + return 0; +} +//------------------------GPIO SW FUNCTIONS------------------------- +//------------------------------------------------------------------- \ No newline at end of file diff --git a/MyLibsGeneral/Src/general_spi.c b/MyLibsGeneral/Src/general_spi.c new file mode 100644 index 0000000..d81ba7d --- /dev/null +++ b/MyLibsGeneral/Src/general_spi.c @@ -0,0 +1,284 @@ +/** +************************************************************************** +* @file general_spi.c +* @brief Модуль для инициализации SPI. +************************************************************************** +Реализация функций для работы с SPI: + - Инициализация SPI и его линий CLK/MISO/MOSI + - Настройка GPIO для SPI + - Настройка NVIC и тактирования SPI +**************************************************************************/ +#include "general_spi.h" +#include "general_gpio.h" + +//------------------------------------------------------------------- +//------------------------SPI INIT FUNCTIONS------------------------ +/** + * @brief Инициализация SPI с помощью структуры SPI_SettingsTypeDef. + * @param sspi Указатель на структуру с настройками SPI. + * @return HAL status. + * @details + * Инициализирует SPI и его GPIO. + * Настройка аналогична HAL_SPI_Init + * @code + * suart.hspi.Init... + * @endcode + * но дополнительно надо прописать пины CLK/MISO/MOSI @ref SPI_SettingsTypeDef + */ +HAL_StatusTypeDef SPI_Base_Init(SPI_SettingsTypeDef *sspi) +{ // function takes setting structure for init + + // check is settings are valid + if(SPI_Check_Init_Struct(sspi) != HAL_OK) + return HAL_ERROR; + + SPI_MspInit(&sspi->hspi); + + if (HAL_SPI_Init(&sspi->hspi) != HAL_OK) + { + MyLibs_Error_Handler(); + return HAL_ERROR; + } + + // init gpio from SPISettings structure + SPI_GPIO_Init(sspi); + +// // init dma from SPISettings structure if need +// if (sspi->DMAChannel != 0) +// SPI_DMA_Init(&sspi->hspi, sspi->hspi.hdmarx, sspi->DMAChannel, sspi->DMA_CHANNEL_X); + + return HAL_OK; +} + + +/** + * @brief Инициализация GPIO для SPI. + * @param sspi Указатель на структуру с настройками SPI. + */ +void SPI_GPIO_Init(SPI_SettingsTypeDef *sspi) +{ + GPIO_InitTypeDef GPIO_InitStruct = {0}; + // GPIO INIT + GPIO_Clock_Enable(sspi->CLK_GPIOx); + GPIO_Clock_Enable(sspi->MISO_GPIOx); + GPIO_Clock_Enable(sspi->MOSI_GPIOx); + // CLK PIN INIT + GPIO_InitStruct.Pin = sspi->CLK_PIN; + GPIO_InitStruct.Alternate = sspi->CLK_GPIO_AlternageFunc; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + GPIO_InitStruct.Pull = GPIO_NOPULL; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_VERY_HIGH; + HAL_GPIO_Init(sspi->CLK_GPIOx, &GPIO_InitStruct); + // MISO PIN INIT + GPIO_InitStruct.Pin = sspi->MISO_PIN; + GPIO_InitStruct.Alternate = sspi->MISO_GPIO_AlternageFunc; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + GPIO_InitStruct.Pull = GPIO_NOPULL; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_VERY_HIGH; + HAL_GPIO_Init(sspi->MISO_GPIOx, &GPIO_InitStruct); + // MOSI PIN INIT + GPIO_InitStruct.Pin = sspi->MOSI_PIN; + GPIO_InitStruct.Alternate = sspi->MOSI_GPIO_AlternageFunc; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + GPIO_InitStruct.Pull = GPIO_NOPULL; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_VERY_HIGH; + HAL_GPIO_Init(sspi->MOSI_GPIOx, &GPIO_InitStruct); +} + + +void SPI_DMA_Init(SPI_HandleTypeDef *hspi, DMA_HandleTypeDef *hdma_rx, DMA_Stream_TypeDef *DMAChannel, uint32_t DMA_CHANNEL_X) +{ // function takes spi and dma handlers and dmachannel for spi +// // for now only dma rx is supported, tx maybe later if needed +// // calc defines on boot_project_setup.h + +// /* SPI3 DMA Init */ +// /* SPI3_RX Init */ +// +// hdma_rx->Instance = DMAChannel; +//#if defined(STM32F4xx) // dma channel choose for 407 +// hdma_rx->Init.Channel = DMA_CHANNEL_X; +//#endif +// hdma_rx->Init.Direction = DMA_PERIPH_TO_MEMORY; +// hdma_rx->Init.PeriphInc = DMA_PINC_DISABLE; +// hdma_rx->Init.MemInc = DMA_MINC_ENABLE; +// hdma_rx->Init.PeriphDataAlignment = DMA_PDATAALIGN_BYTE; +// hdma_rx->Init.MemDataAlignment = DMA_MDATAALIGN_BYTE; +// hdma_rx->Init.Mode = DMA_CIRCULAR; +// hdma_rx->Init.Priority = DMA_PRIORITY_LOW; +// if (HAL_DMA_Init(hdma_rx) != HAL_OK) +// { +// MyLibs_Error_Handler(); +// } + +// __USER_LINKDMA(hspi,hdmarx,hdma_rx); +// + +// // __USER_LINKDMA is need because __HAL_LINKDMA is written for global defined hdma_rx +// // so you get error because hal uses . insted of -> +} + + +/** + * @brief Настройка тактирования и прерываний SPI. + * @param hspi Указатель на хендл SPI. + * @note Чтобы не генерировать функцию с иницилизацией неиспользуемых SPI, + дефайнами @ref SPI_INIT в @ref general_spi.h определяются используемые SPI. + */ +void SPI_MspInit(SPI_HandleTypeDef *hspi) // analog for hal function +{ + // rcc, dma and interrupt init for SPIs + // GPIO init was moved to own functions SPI_GPIO_Init + if(0); +#ifdef USE_SPI1 + else if(hspi->Instance==SPI1) + { + +// /* DMA2 clock enable */ +// __HAL_RCC_DMA2_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA2_Stream2_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA2_Stream2_IRQn); + + /* SPI1 clock enable */ + __HAL_RCC_SPI1_CLK_ENABLE(); + + /* SPI1 interrupt Init */ + HAL_NVIC_SetPriority(SPI1_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(SPI1_IRQn); + } +#endif // USE_SPI1 +#ifdef USE_SPI2 + else if(hspi->Instance==SPI2) + { +// /* DMA1 clock enable */ +// __HAL_RCC_DMA1_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA1_Stream5_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA1_Stream5_IRQn); + + /* SPI2 clock enable */ + __HAL_RCC_SPI2_CLK_ENABLE(); + + /* SPI2 interrupt Init */ + HAL_NVIC_SetPriority(SPI2_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(SPI2_IRQn); + } +#endif // USE_SPI2 +#ifdef USE_SPI3 + else if(hspi->Instance==SPI3) + { +// /* DMA1 clock enable */ +// __HAL_RCC_DMA1_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA1_Stream1_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA1_Stream1_IRQn); + + /* SPI3 clock enable */ + __HAL_RCC_SPI3_CLK_ENABLE(); + /* SPI3 interrupt Init */ + HAL_NVIC_SetPriority(SPI3_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(SPI3_IRQn); + } +#endif // USE_SPI3 +} + +/** + * @brief Деинициализация тактирования и прерываний SPI. + * @param hspi Указатель на хендл SPI. + * @note Чтобы не генерировать функцию с иницилизацией неиспользуемых SPI, + дефайнами @ref SPI_INIT в @ref general_spi.h определяются используемые SPI. + */ +void SPI_MspDeInit(SPI_HandleTypeDef *hspi) // analog for hal function +{ + // rcc, dma and interrupt init for SPIs + // GPIO init was moved to own functions SPI_GPIO_Init + if(0); +#ifdef USE_SPI1 + else if(hspi->Instance==SPI1) + { + +// /* DMA2 clock enable */ +// __HAL_RCC_DMA2_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA2_Stream2_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA2_Stream2_IRQn); + + /* SPI1 clock reset */ + __HAL_RCC_SPI1_FORCE_RESET(); + __HAL_RCC_SPI1_RELEASE_RESET(); + } +#endif // USE_SPI1 +#ifdef USE_SPI2 + else if(hspi->Instance==SPI2) + { +// /* DMA1 clock enable */ +// __HAL_RCC_DMA1_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA1_Stream5_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA1_Stream5_IRQn); + + /* SPI2 clock reset */ + __HAL_RCC_SPI2_FORCE_RESET(); + __HAL_RCC_SPI2_RELEASE_RESET(); + } +#endif // USE_SPI2 +#ifdef USE_SPI3 + else if(hspi->Instance==SPI3) + { +// /* DMA1 clock enable */ +// __HAL_RCC_DMA1_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA1_Stream1_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA1_Stream1_IRQn); + + /* SPI3 clock reset */ + __HAL_RCC_SPI3_FORCE_RESET(); + __HAL_RCC_SPI3_RELEASE_RESET(); + } +#endif // USE_SPI3 +} + +/** + * @brief Проверка корректности структуры инициализации SPI. + * @param sspi Указатель на структуру с настройками SPI. + * @return HAL status. + */ +HAL_StatusTypeDef SPI_Check_Init_Struct(SPI_SettingsTypeDef *sspi) +{ + // check is settings are valid + if (!IS_SPI_ALL_INSTANCE(sspi->hspi.Instance)) + return HAL_ERROR; + + // check init settings + if (!IS_SPI_MODE(sspi->hspi.Init.Mode)) + return HAL_ERROR; + if (!IS_SPI_DIRECTION(sspi->hspi.Init.Direction)) + return HAL_ERROR; + if (!IS_SPI_DATASIZE(sspi->hspi.Init.DataSize)) + return HAL_ERROR; + if (!IS_SPI_BAUDRATE_PRESCALER(sspi->hspi.Init.BaudRatePrescaler)) + return HAL_ERROR; + if (!IS_SPI_CPOL(sspi->hspi.Init.CLKPolarity)) + return HAL_ERROR; + if (!IS_SPI_CPHA(sspi->hspi.Init.CLKPhase)) + return HAL_ERROR; + if (!IS_SPI_NSS(sspi->hspi.Init.NSS)) + return HAL_ERROR; + if (!IS_SPI_FIRST_BIT(sspi->hspi.Init.FirstBit)) + return HAL_ERROR; + if (!IS_SPI_CRC_CALCULATION(sspi->hspi.Init.CRCCalculation)) + return HAL_ERROR; + if (!IS_SPI_CRC_POLYNOMIAL(sspi->hspi.Init.NSS) && + (sspi->hspi.Init.CRCCalculation != SPI_CRCCALCULATION_DISABLE)) + return HAL_ERROR; + if (!IS_SPI_TIMODE(sspi->hspi.Init.TIMode)) + return HAL_ERROR; + + // check gpio + if (!IS_GPIO_ALL_INSTANCE(sspi->CLK_GPIOx) || !IS_GPIO_ALL_INSTANCE(sspi->MISO_GPIOx) || !IS_GPIO_ALL_INSTANCE(sspi->MOSI_GPIOx)) + return HAL_ERROR; + if (!IS_GPIO_PIN(sspi->CLK_PIN) && !IS_GPIO_PIN(sspi->MISO_PIN) && !IS_GPIO_PIN(sspi->MOSI_PIN)) // if both pins arent set up + return HAL_ERROR; + + return HAL_OK; +} \ No newline at end of file diff --git a/MyLibsGeneral/Src/general_tim.c b/MyLibsGeneral/Src/general_tim.c new file mode 100644 index 0000000..ca3367a --- /dev/null +++ b/MyLibsGeneral/Src/general_tim.c @@ -0,0 +1,722 @@ +/** +************************************************************************** +* @file general_tim.c +* @brief Модуль для инициализации таймеров и работы с ними. +************************************************************************** +Реализация функций для работы с TIM: + - Инициализация таймера и его каналов + - Формирование задержек через таймеры + - Считывание энкодера +*************************************************************************/ +#include "general_tim.h" + +//------------------------------------------------------------------- +//-------------------------TIM INIT FUNCTIONS------------------------ +/** + * @brief Инициализация таймера. + * @param stim Указатель на структуру с настройками таймера. + * @return HAL status. + * @details + * Инициализирует таймер исходя из настроек верхнего уровня: + * - Длительность одного тика @ref TIM_MHzTickBaseTypeDef + * - Частота таймера (в Гц, float) + * - Частота тактирования таймера от шины (в Гц, float) + * + * При невозможности выставления частоты при заданой длительности тика + * длительность тика увеличивается до тех пор, пока частота не будет достигнута. + * + * При выставлении дефайна @ref UPDATE_TIM_PARAMS_AFTER_INITIALIZATION + * новая длительность тика записывается в структуру. + * + * Также остается возможность низкоуровневой настройки по структурам @ref TIM_SettingsTypeDef. + * Для этого надо высокоуровневые настройки приравнять к нулю + */ +HAL_StatusTypeDef TIM_Base_Init(TIM_SettingsTypeDef *stim) +{ // function takes structure for init + // check that htim is defined + if(check_null_ptr_2(stim, stim->htim.Instance)) + return HAL_ERROR; + + + + if(stim->sTickBaseUS) // if tickbase isnt disable + { + if(stim->sTimAHBFreqMHz == NULL) + return HAL_ERROR; + stim->htim.Init.Prescaler = (stim->sTimAHBFreqMHz*stim->sTickBaseUS) - 1; + + if ((stim->sTimFreqHz != NULL)) + stim->htim.Init.Period = ((1000000/stim->sTickBaseUS) / stim->sTimFreqHz) - 1; + else if (stim->htim.Init.Period == NULL) + stim->htim.Init.Period = 0xFFFF; + + if(stim->sTickBasePrescaler) + { + stim->htim.Init.Prescaler = (stim->htim.Init.Prescaler + 1)/stim->sTickBasePrescaler - 1; + stim->htim.Init.Period = (stim->htim.Init.Period + 1)*stim->sTickBasePrescaler - 1; + } + else + stim->sTickBasePrescaler = 1; + } + + // fix overflow of presc and period if need + for(int i = 0; (stim->htim.Init.Prescaler > 0xFFFF) || (stim->htim.Init.Period > 0xFFFF); i++) + { + if (i>10) // if it isnt fixed after 10 itteration - return HAL_ERRPOR + { + return HAL_ERROR; + } + + // if timbase is too big (prescaller too big for choosen base from MHZ) + if(stim->htim.Init.Prescaler > 0xFFFF) + { + // переносим часть пресскалера в период + stim->htim.Init.Prescaler = ((stim->htim.Init.Prescaler + 1)/2) - 1; + stim->htim.Init.Period = ((stim->htim.Init.Period + 1)*2) - 1; + // обновляем TickBase, если есть куда обновлять + if(stim->sTickBaseUS > 1) + stim->sTickBaseUS /= 2; + // обновляем sTickBasePrescaler, если sTickBaseUS - уже в минимуме + else if (stim->sTickBaseUS == 1) + stim->sTickBasePrescaler *= 2; + else // if TickBase = 0 - return error + return HAL_ERROR; + } + // if freq is too low (period too big for choosen base) + if(stim->htim.Init.Period > 0xFFFF) + { + // переносим часть периода в прескалер + stim->htim.Init.Period = ((stim->htim.Init.Period + 1)/2) - 1; + stim->htim.Init.Prescaler = ((stim->htim.Init.Prescaler + 1)*2) - 1; + // обновляем TickBase + stim->sTickBaseUS *= 2; + } + } + + //-------------TIM BASE INIT---------------- + // tim base init + TIM_Base_MspInit(&stim->htim, stim->sTimMode); + if (HAL_TIM_Base_Init(&stim->htim) != HAL_OK) + { + MyLibs_Error_Handler(); + return HAL_ERROR; + } + + //-------------CLOCK SRC INIT--------------- + // fill sClockSourceConfig if its NULL + if (stim->sClockSourceConfig.ClockSource == NULL) + stim->sClockSourceConfig.ClockSource = TIM_CLOCKSOURCE_INTERNAL; + // clock source init + if (HAL_TIM_ConfigClockSource(&stim->htim, &stim->sClockSourceConfig) != HAL_OK) + { + MyLibs_Error_Handler(); + return HAL_ERROR; + } + + //--------------SLAVE INIT------------------ + // if slave mode enables - config it + if (stim->sSlaveConfig.SlaveMode) + { + // slave mode init + if (HAL_TIM_SlaveConfigSynchro(&stim->htim, &stim->sSlaveConfig) != HAL_OK) + { + MyLibs_Error_Handler(); + return HAL_ERROR; + } + } + //--------------MASTER INIT----------------- + // master mode init + if (HAL_TIMEx_MasterConfigSynchronization(&stim->htim, &stim->sMasterConfig) != HAL_OK) + { + MyLibs_Error_Handler(); + return HAL_ERROR; + } + + //--------------BDTR INIT----------------- + if (HAL_TIMEx_ConfigBreakDeadTime(&stim->htim, &stim->sBreakDeadTimeConfig) != HAL_OK) + { + MyLibs_Error_Handler(); + return HAL_ERROR; + } + + //----------------IT CLEAR------------------- + __HAL_TIM_CLEAR_IT(&stim->htim, TIM_IT_UPDATE); + + + // обновляем TickBase + #ifdef UPDATE_TIM_PARAMS_AFTER_INITIALIZATION + stim->sTickBaseUS = (stim->htim.Instance->PSC+1)*stim->sTickBasePrescaler/(stim->sTimAHBFreqMHz); + if(stim->sTickBaseUS == 0) // if prescaler is too high + { // recalc what is prescaler irl + stim->sTickBaseUS = 1; + stim->sTickBasePrescaler = stim->sTimAHBFreqMHz/(stim->htim.Instance->PSC+1); + } + #endif + stim->htim.Instance->CNT = 0; + return HAL_OK; +} + + + +/** + * @brief Инициализация режима энкодер у таймера. + * @param henc Указатель на хендл энкодера. + * @param htim Указатель на хендл таймера. + * @return HAL status. + * @note Предварительно надо инициализировать таймер @ref TIM_Base_Init. + */ +HAL_StatusTypeDef TIM_Encoder_Init(TIM_EncoderTypeDef *henc, TIM_HandleTypeDef *htim) +{ + if(check_null_ptr_3(henc, htim, htim->Instance)) + return HAL_ERROR; + if(check_null_ptr_3(henc->GPIOx, henc->GPIO_PIN_TI1, henc->GPIO_PIN_TI2)) + return HAL_ERROR; + + GPIO_InitTypeDef GPIO_InitStruct = {0}; + HAL_StatusTypeDef RES = HAL_ERROR; + henc->htim = htim; + + // setup channel for pwm + RES = HAL_TIM_Encoder_Init(henc->htim, &henc->sConfig); + if (RES != HAL_OK) + { + MyLibs_Error_Handler(); + return RES; + } + // choose port for enable clock + RES = GPIO_Clock_Enable(henc->GPIOx); + if(RES != HAL_OK) + { + MyLibs_Error_Handler(); + return RES; + } + + GPIO_InitStruct.Pin = henc->GPIO_PIN_TI1|henc->GPIO_PIN_TI2; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + GPIO_InitStruct.Pull = GPIO_PULLUP; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW; + GPIO_InitStruct.Alternate = GPIO_TIM_Alternate_Mapping(henc->htim->Instance); + if(GPIO_InitStruct.Alternate) + HAL_GPIO_Init(henc->GPIOx, &GPIO_InitStruct); + + if(henc->GPIO_PIN_SW) + { + /*Configure switch pin */ + GPIO_InitStruct.Pin = henc->GPIO_PIN_SW; + GPIO_InitStruct.Mode = GPIO_MODE_INPUT; + GPIO_InitStruct.Pull = GPIO_PULLUP; + HAL_GPIO_Init(henc->GPIOx, &GPIO_InitStruct); + + GPIO_Switch_Init(&henc->Sw, henc->GPIOx, henc->GPIO_PIN_SW, 0); + } + + return HAL_OK; +} + +/** + * @brief Инициализация выхода ШИМ таймера. + * @param htim Указатель на хендл таймера. + * @param sConfigOC Указатель на настрйоки канала таймера. + * @param TIM_CHANNEL Канал таймера для настройки. + * @param GPIOx Порт для вывода ШИМ. + * @param GPIO_PIN Пин для вывода ШИМ. + * @return HAL status. + * @note Предварительно надо инициализировать таймер @ref TIM_Base_Init. + */ +HAL_StatusTypeDef TIM_Output_PWM_Init(TIM_HandleTypeDef *htim, TIM_OC_InitTypeDef *sConfigOC, uint32_t TIM_CHANNEL, GPIO_TypeDef *GPIOx, uint32_t GPIO_PIN) +{ + if(check_null_ptr_3(htim, htim->Instance, sConfigOC)) + return HAL_ERROR; + if(check_null_ptr_2(GPIOx, GPIO_PIN)) + return HAL_ERROR; + + GPIO_InitTypeDef GPIO_InitStruct = {0}; + HAL_StatusTypeDef RES = HAL_ERROR; + + // setup channel for pwm + RES = HAL_TIM_PWM_ConfigChannel(htim, sConfigOC, TIM_CHANNEL); + if (RES != HAL_OK) + { + MyLibs_Error_Handler(); + return RES; + } + // choose port for enable clock + RES = GPIO_Clock_Enable(GPIOx); + if(RES != HAL_OK) + { + MyLibs_Error_Handler(); + return RES; + } + + GPIO_InitStruct.Pin = GPIO_PIN; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + if(sConfigOC->OCPolarity == TIM_OCNPOLARITY_HIGH) + GPIO_InitStruct.Pull = GPIO_PULLDOWN; + else + GPIO_InitStruct.Pull = GPIO_PULLUP; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW; + GPIO_InitStruct.Alternate = GPIO_TIM_Alternate_Mapping(htim->Instance); + if(GPIO_InitStruct.Alternate) + HAL_GPIO_Init(GPIOx, &GPIO_InitStruct); + + return HAL_OK; +} + +/** + * @brief Инициализация OC компаратора таймера. + * @param htim Указатель на хендл таймера. + * @param TIM_CHANNEL Канал таймера для настройки. + * @return HAL status. + * @note Предварительно надо инициализировать таймер @ref TIM_Base_Init. + */ +HAL_StatusTypeDef TIM_OC_Comparator_Init(TIM_HandleTypeDef *htim, uint32_t TIM_CHANNEL) +{ + if(check_null_ptr_2(htim, htim->Instance)) + return HAL_ERROR; + + TIM_OC_InitTypeDef sConfigOC = {0}; + HAL_StatusTypeDef RES = HAL_ERROR; + + sConfigOC.OCMode = TIM_OCMODE_ACTIVE; + sConfigOC.Pulse = 0; + sConfigOC.OCPolarity = TIM_OCPOLARITY_HIGH; + + RES = HAL_TIM_OC_ConfigChannel(htim, &sConfigOC, TIM_CHANNEL); + if (RES != HAL_OK) + { + MyLibs_Error_Handler(); + return RES; + } + return RES; +} + + +//------------------------------------------------------------------- +//-------------------------TIM USER FUNCTIONS------------------------ +/** + * @brief Считать энкодер. + * @param henc Указатель на хендл энкодера. + * @return HAL status. + * @details Читает разницу энкодера, которую он накопил после + * предыдущего вызова этой функции. + */ +HAL_StatusTypeDef TIM_Encoder_Read(TIM_EncoderTypeDef *henc) +{ + if(check_null_ptr_3(henc, henc->htim, henc->htim->Instance)) + return HAL_ERROR; + + uint16_t cnt_now = (uint16_t)henc->htim->Instance->CNT; + int16_t diff = (int16_t)(cnt_now - henc->Encoder_Shdw); // переполнение корректно обрабатывается + henc->Encoder_Diff = diff; + henc->Encoder_Shdw = cnt_now; + + return HAL_OK; +} +/** + * @brief Считать кнопку энкодера. + * @param henc Указатель на хендл энкодера. + * @return 1 - если кнопка нажата, + * 0 - если отжата, + * -1 - если ошибка + */ +int TIM_Encoder_ReadSwitch(TIM_EncoderTypeDef *henc) +{ + if(check_null_ptr_1(henc)) + return -1; + + return GPIO_Read_Switch(&henc->Sw); +} + +/** + * @brief Задержка в тиках таймера (блокирующая). + * @param htim Указатель на хендл таймера. + * @param delay Задержка в тиках таймера. + * @return HAL status. + * @details Формирует задержку с блокировкой программы. + */ +HAL_StatusTypeDef TIM_Delay(TIM_HandleTypeDef *htim, uint16_t delay) +{ + if(check_null_ptr_2(htim, htim->Instance)) + return HAL_ERROR; + + if(delay >= htim->Instance->ARR) + { + return HAL_ERROR; + } + htim->Instance->CNT = 0; + while(1) + { + if(htim->Instance->CNT > delay) + { + return HAL_OK; + } + } +} + +/** + * @brief Начать отсчет неблокирующей задержки. + * @param htim Указатель на хендл таймера. + * @return HAL status. + * @details Сбрасывает счетчик для начала отсчета неблокирующей задержки. + * @ref TIM_Delay_NonBlocking для проверки статуса задержки + */ +HAL_StatusTypeDef TIM_Delay_Start(TIM_HandleTypeDef *htim) +{ + if(check_null_ptr_2(htim, htim->Instance)) + return HAL_ERROR; + + htim->Instance->CNT = 0; + + return HAL_OK; +} + +/** + * @brief Задержка в тиках таймера (неблокирующая). + * @param htim Указатель на хендл таймера. + * @param delay Задержка в тиках таймера. + * @return HAL status. + * @details Формирует задержку с блокировкой программы. + * Перед ожиданием задержки надо запутстить таймер @ref TIM_Delay_Start + * @note Таймер не должен использоваться на время этой задержки + */ +HAL_StatusTypeDef TIM_Delay_NonBlocking(TIM_HandleTypeDef *htim, uint16_t delay) +{ + if(check_null_ptr_2(htim, htim->Instance)) + return HAL_ERROR; + + if(delay >= htim->Instance->ARR) + { + return HAL_ERROR; + } + + if(htim->Instance->CNT <= delay) + { + return HAL_BUSY; + } + else + { + return HAL_OK; + } +} + +/** + * @brief Инициализация CLK и NVIC таймеров. + * @param htim Указатель на хендл таймера. + * @note Чтобы не генерировать функцию с иницилизацией неиспользуемых таймеров, + дефайнами @ref TIM_INIT в @ref general_tim.h определяются используемые таймеры. + */ +void TIM_Base_MspInit(TIM_HandleTypeDef* htim, TIM_ITModeTypeDef it_mode) +{ + if(check_null_ptr_2(htim, htim->Instance)) + return; + + it_mode = it_mode&TIM_IT_CONF; +#ifdef USE_TIM1 + if(htim->Instance==TIM1) + { + /* TIM2 clock enable */ + __HAL_RCC_TIM1_CLK_ENABLE(); + + /* TIM2 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM1_UP_TIM10_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM1_UP_TIM10_IRQn); + } + } +#endif +#ifdef USE_TIM2 + if(htim->Instance==TIM2) + { + /* TIM2 clock enable */ + __HAL_RCC_TIM2_CLK_ENABLE(); + + /* TIM2 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM2_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM2_IRQn); + } + } +#endif +#ifdef USE_TIM3 + if(htim->Instance==TIM3) + { + /* TIM3 clock enable */ + __HAL_RCC_TIM3_CLK_ENABLE(); + + /* TIM3 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM3_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM3_IRQn); + } + } +#endif +#ifdef USE_TIM4 + if(htim->Instance==TIM4) + { + /* TIM4 clock enable */ + __HAL_RCC_TIM4_CLK_ENABLE(); + + /* TIM4 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM4_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM4_IRQn); + } + } +#endif +#ifdef USE_TIM5 + if(htim->Instance==TIM5) + { + /* TIM5 clock enable */ + __HAL_RCC_TIM5_CLK_ENABLE(); + + /* TIM5 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM5_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM5_IRQn); + } + } +#endif +#ifdef USE_TIM6 + if(htim->Instance==TIM6) + { + /* TIM6 clock enable */ + __HAL_RCC_TIM6_CLK_ENABLE(); + + /* TIM6 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM6_DAC_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM6_DAC_IRQn); + } + } +#endif +#ifdef USE_TIM7 + if(htim->Instance==TIM7) + { + /* TIM7 clock enable */ + __HAL_RCC_TIM7_CLK_ENABLE(); + + /* TIM7 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM7_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM7_IRQn); + } + } +#endif +#ifdef USE_TIM8 + if(htim->Instance==TIM8) + { + /* TIM8 clock enable */ + __HAL_RCC_TIM8_CLK_ENABLE(); + + /* TIM8 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM8_UP_TIM13_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM8_UP_TIM13_IRQn); + } + } +#endif +#ifdef USE_TIM9 + if(htim->Instance==TIM9) + { + /* TIM9 clock enable */ + __HAL_RCC_TIM9_CLK_ENABLE(); + + /* TIM9 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM1_BRK_TIM9_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM1_BRK_TIM9_IRQn); + } + } +#endif +#ifdef USE_TIM10 + if(htim->Instance==TIM10) + { + /* TIM10 clock enable */ + __HAL_RCC_TIM10_CLK_ENABLE(); + + /* TIM10 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM1_UP_TIM10_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM1_UP_TIM10_IRQn); + } + } +#endif +#ifdef USE_TIM11 + if(htim->Instance==TIM11) + { + /* TIM11 clock enable */ + __HAL_RCC_TIM11_CLK_ENABLE(); + + /* TIM11 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM1_TRG_COM_TIM11_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM1_TRG_COM_TIM11_IRQn); + } + } +#endif +#ifdef USE_TIM12 + if(htim->Instance==TIM12) + { + /* TIM12 clock enable */ + __HAL_RCC_TIM12_CLK_ENABLE(); + + /* TIM12 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM8_BRK_TIM12_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM8_BRK_TIM12_IRQn); + } + } +#endif +#ifdef USE_TIM13 + if(htim->Instance==TIM13) + { + /* TIM13 clock enable */ + __HAL_RCC_TIM13_CLK_ENABLE(); + + /* TIM13 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM8_UP_TIM13_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM8_UP_TIM13_IRQn); + } + } +#endif +#ifdef USE_TIM14 + if(htim->Instance==TIM14) + { + /* TIM14 clock enable */ + __HAL_RCC_TIM14_CLK_ENABLE(); + + /* TIM14 interrupt Init */ + if(it_mode) + { + HAL_NVIC_SetPriority(TIM8_TRG_COM_TIM14_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(TIM8_TRG_COM_TIM14_IRQn); + } + } +#endif +} +/** + * @brief Деинициализация CLK и NVIC таймеров. + * @param htim Указатель на хендл таймера. + * @note Чтобы не генерировать функцию с деиницилизацией неиспользуемых таймеров, + дефайнами @ref TIM_INIT в @ref general_tim.h определяются используемые таймеры. + */ +void TIM_Base_MspDeInit(TIM_HandleTypeDef* htim) +{ + if(check_null_ptr_2(htim, htim->Instance)) + return; + +#ifdef USE_TIM1 + if(htim->Instance==TIM1) + { + __HAL_RCC_TIM1_FORCE_RESET(); + __HAL_RCC_TIM1_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM2 + if(htim->Instance==TIM2) + { + __HAL_RCC_TIM2_FORCE_RESET(); + __HAL_RCC_TIM2_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM3 + if(htim->Instance==TIM3) + { + __HAL_RCC_TIM3_FORCE_RESET(); + __HAL_RCC_TIM3_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM4 + if(htim->Instance==TIM4) + { + __HAL_RCC_TIM4_FORCE_RESET(); + __HAL_RCC_TIM4_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM5 + if(htim->Instance==TIM5) + { + __HAL_RCC_TIM5_FORCE_RESET(); + __HAL_RCC_TIM5_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM6 + if(htim->Instance==TIM6) + { + __HAL_RCC_TIM6_FORCE_RESET(); + __HAL_RCC_TIM6_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM7 + if(htim->Instance==TIM7) + { + __HAL_RCC_TIM7_FORCE_RESET(); + __HAL_RCC_TIM7_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM8 + if(htim->Instance==TIM8) + { + __HAL_RCC_TIM8_FORCE_RESET(); + __HAL_RCC_TIM8_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM9 + if(htim->Instance==TIM9) + { + __HAL_RCC_TIM9_FORCE_RESET(); + __HAL_RCC_TIM9_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM10 + if(htim->Instance==TIM10) + { + __HAL_RCC_TIM10_FORCE_RESET(); + __HAL_RCC_TIM10_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM11 + if(htim->Instance==TIM11) + { + __HAL_RCC_TIM11_FORCE_RESET(); + __HAL_RCC_TIM11_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM12 + if(htim->Instance==TIM12) + { + __HAL_RCC_TIM12_FORCE_RESET(); + __HAL_RCC_TIM12_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM13 + if(htim->Instance==TIM13) + { + __HAL_RCC_TIM13_FORCE_RESET(); + __HAL_RCC_TIM13_RELEASE_RESET(); + } +#endif +#ifdef USE_TIM14 + if(htim->Instance==TIM14) + { + __HAL_RCC_TIM14_FORCE_RESET(); + __HAL_RCC_TIM14_RELEASE_RESET(); + } +#endif +} +//-------------------------TIM INIT FUNCTIONS------------------------ +//------------------------------------------------------------------- diff --git a/MyLibsGeneral/Src/general_uart.c b/MyLibsGeneral/Src/general_uart.c new file mode 100644 index 0000000..a5fcc1b --- /dev/null +++ b/MyLibsGeneral/Src/general_uart.c @@ -0,0 +1,383 @@ +/** +************************************************************************** +* @file general_uart.c +* @brief Модуль для инициализации UART. +************************************************************************** +Реализация функций для работы с UART: + - Инициализация UART и его линий RX/TX + - Настройка DMA для UART + - Настройка GPIO для UART + - Настройка NVIC и тактирования UART +**************************************************************************/ +#include "general_uart.h" +#include "general_gpio.h" + +//------------------------------------------------------------------- +//------------------------UART INIT FUNCTIONS------------------------ +/** + * @brief Инициализация UART с помощью структуры UART_SettingsTypeDef. + * @param suart Указатель на структуру с настройками UART. + * @return HAL status. + * @details + * Инициализирует UART и его GPIO и при необходимости DMA. + * Настройка аналогична HAL_UART_Init + * @code + * suart.huart.Init... + * @endcode + * но дополнительно надо прописать пины RX/TX @ref UART_SettingsTypeDef + * @code + * suart->GPIOx, suart->GPIO_PIN_RX, suart->GPIO_PIN_TX + * @endcode + */ +HAL_StatusTypeDef UART_Base_Init(UART_SettingsTypeDef *suart) +{ // function takes setting structure for init + + // check is settings are valid + if(UART_Check_Init_Struct(suart) != HAL_OK) + return HAL_ERROR; + + suart->huart.Init.Mode = UART_MODE_TX_RX; + + UART_MspInit(&suart->huart); + + + if (HAL_UART_Init(&suart->huart) != HAL_OK) + { + MyLibs_Error_Handler(); + return HAL_ERROR; + } + + // init gpio from UARTSettings structure + UART_GPIO_Init(suart->GPIOx, suart->GPIO_PIN_RX, suart->GPIO_PIN_TX); + + __HAL_UART_ENABLE_IT(&suart->huart, UART_IT_IDLE); + // init dma from UARTSettings structure if need + if (suart->DMAChannel != 0) + UART_DMA_Init(&suart->huart, suart->huart.hdmarx, suart->DMAChannel, suart->DMA_CHANNEL_X); + + + return HAL_OK; +} + + +/** + * @brief Инициализация GPIO для UART. + * @param GPIOx Порт для настройки. + * @param GPIO_PIN_RX Пин для приема. + * @param GPIO_PIN_TX Пин для передачи. + */ +void UART_GPIO_Init(GPIO_TypeDef *GPIOx, uint16_t GPIO_PIN_RX, uint16_t GPIO_PIN_TX) +{ // function takes port and pins (for rx and tx) + GPIO_InitTypeDef GPIO_InitStruct = {0}; + + // choose port for enable clock + GPIO_Clock_Enable(GPIOx); + + //USART3 GPIO Configuration + //GPIO_PIN_TX ------> USART_TX + //GPIO_PIN_RX ------> USART_RX + +#if defined(STM32F4xx) // gpio init for 407 + GPIO_InitStruct.Pin = GPIO_PIN_TX|GPIO_PIN_RX; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + GPIO_InitStruct.Pull = GPIO_NOPULL; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_VERY_HIGH; + GPIO_InitStruct.Alternate = GPIO_AF7_USART3; + HAL_GPIO_Init(GPIOx, &GPIO_InitStruct); +#elif defined(STM32F1xx) // gpio init for atm403/stm103 + //GPIO_PIN_TX ------> USART_TX + GPIO_InitStruct.Pin = GPIO_PIN_TX; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_HIGH; + HAL_GPIO_Init(GPIOx, &GPIO_InitStruct); + +// GPIO_PIN_RX ------> USART_RX + GPIO_InitStruct.Pin = GPIO_PIN_RX; + GPIO_InitStruct.Mode = GPIO_MODE_INPUT; + GPIO_InitStruct.Pull = GPIO_NOPULL; + HAL_GPIO_Init(GPIOx, &GPIO_InitStruct); +#endif +} + +/** + * @brief Инициализация DMA для UART. + * @param huart Указатель на хендл UART. + * @param hdma_rx Указатель на хендл DMA для линии приема UART. + * @param DMAChannel Указатель на канал DMA/поток DMA в STM32F407. + * @param DMA_CHANNEL_X Канал DMA. + */ +void UART_DMA_Init(UART_HandleTypeDef *huart, DMA_HandleTypeDef *hdma_rx, DMA_Stream_TypeDef *DMAChannel, uint32_t DMA_CHANNEL_X) +{ // function takes uart and dma handlers and dmachannel for uart + // for now only dma rx is supported, tx maybe later if needed + // calc defines on boot_project_setup.h + + /* USART3 DMA Init */ + /* USART3_RX Init */ + + hdma_rx->Instance = DMAChannel; +#if defined(STM32F4xx) // dma channel choose for 407 + hdma_rx->Init.Channel = DMA_CHANNEL_X; +#endif + hdma_rx->Init.Direction = DMA_PERIPH_TO_MEMORY; + hdma_rx->Init.PeriphInc = DMA_PINC_DISABLE; + hdma_rx->Init.MemInc = DMA_MINC_ENABLE; + hdma_rx->Init.PeriphDataAlignment = DMA_PDATAALIGN_BYTE; + hdma_rx->Init.MemDataAlignment = DMA_MDATAALIGN_BYTE; + hdma_rx->Init.Mode = DMA_CIRCULAR; + hdma_rx->Init.Priority = DMA_PRIORITY_LOW; + if (HAL_DMA_Init(hdma_rx) != HAL_OK) + { + MyLibs_Error_Handler(); + } + + __USER_LINKDMA(huart,hdmarx,hdma_rx); + + + // __USER_LINKDMA is need because __HAL_LINKDMA is written for global defined hdma_rx + // so you get error because hal uses . insted of -> +} + +/** + * @brief Настройка тактирования и прерываний UART. + * @param huart Указатель на хендл UART. + * @note Чтобы не генерировать функцию с иницилизацией неиспользуемых UART, + дефайнами @ref UART_INIT в @ref general_uart.h определяются используемые UART. + */ +void UART_MspInit(UART_HandleTypeDef *huart) // analog for hal function +{ +// __RCC_DMA_UART_CLK_ENABLE(); +// /* DMA interrupt init */ +// /* DMA1_Stream1_IRQn interrupt configuration */ +// HAL_NVIC_SetPriority(DMA_UART_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA_UART_IRQn); + + // rcc, dma and interrupt init for USARTs + // GPIO init was moved to own functions UART_GPIO_Init + if(0); +#ifdef USE_USART1 + else if(huart->Instance==USART1) + { + + /* DMA2 clock enable */ + __HAL_RCC_DMA2_CLK_ENABLE(); + /* DMA interrupt init */ + HAL_NVIC_SetPriority(DMA2_Stream2_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(DMA2_Stream2_IRQn); + + /* USART1 clock enable */ + __HAL_RCC_USART1_CLK_ENABLE(); + + /* USART1 interrupt Init */ + HAL_NVIC_SetPriority(USART1_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(USART1_IRQn); + } +#endif // USE_USART1 +#ifdef USE_USART2 + else if(huart->Instance==USART2) + { + /* DMA1 clock enable */ + __HAL_RCC_DMA1_CLK_ENABLE(); + /* DMA interrupt init */ + HAL_NVIC_SetPriority(DMA1_Stream5_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(DMA1_Stream5_IRQn); + + /* USART2 clock enable */ + __HAL_RCC_USART2_CLK_ENABLE(); + + /* USART2 interrupt Init */ + HAL_NVIC_SetPriority(USART2_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(USART2_IRQn); + } +#endif // USE_USART2 +#ifdef USE_USART3 + else if(huart->Instance==USART3) + { + /* DMA1 clock enable */ + __HAL_RCC_DMA1_CLK_ENABLE(); + /* DMA interrupt init */ + HAL_NVIC_SetPriority(DMA1_Stream1_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(DMA1_Stream1_IRQn); + + /* USART3 clock enable */ + __HAL_RCC_USART3_CLK_ENABLE(); + /* USART3 interrupt Init */ + HAL_NVIC_SetPriority(USART3_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(USART3_IRQn); + } +#endif // USE_USART3 +#ifdef USE_UART4 + else if(huart->Instance==UART4) + { + /* DMA1 clock enable */ + __HAL_RCC_DMA1_CLK_ENABLE(); + /* DMA interrupt init */ + HAL_NVIC_SetPriority(DMA1_Stream2_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(DMA1_Stream2_IRQn); + + /* UART4 clock enable */ + __HAL_RCC_UART4_CLK_ENABLE(); + + /* UART4 interrupt Init */ + HAL_NVIC_SetPriority(UART4_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(UART4_IRQn); + } +#endif // USE_UART4 +#ifdef USE_UART5 + else if(huart->Instance==UART5) + { + /* DMA1 clock enable */ + __HAL_RCC_DMA1_CLK_ENABLE(); + /* DMA interrupt init */ + HAL_NVIC_SetPriority(DMA1_Stream0_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(DMA1_Stream0_IRQn); + + /* UART5 clock enable */ + __HAL_RCC_DMA1_CLK_ENABLE(); + + /* UART5 interrupt Init */ + HAL_NVIC_SetPriority(UART5_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(UART5_IRQn); + } +#endif // USE_UART5 +#ifdef USE_USART6 + else if(huart->Instance==USART6) + { + /* DMA2 clock enable */ + __HAL_RCC_DMA2_CLK_ENABLE(); + /* DMA interrupt init */ + HAL_NVIC_SetPriority(DMA2_Stream1_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(DMA2_Stream1_IRQn); + + /* USART6 clock enable */ + __HAL_RCC_USART6_CLK_ENABLE(); + + /* USART6 interrupt Init */ + HAL_NVIC_SetPriority(USART6_IRQn, 0, 0); + HAL_NVIC_EnableIRQ(USART6_IRQn); + } +#endif // USE_USART6 +} + +/** + * @brief Деинициализация тактирования и прерываний UART. + * @param huart Указатель на хендл UART. + * @note Чтобы не генерировать функцию с деиницилизацией неиспользуемых UART, + дефайнами @ref UART_INIT в @ref general_uart.h определяются используемые UART. + */ +void UART_MspDeInit(UART_HandleTypeDef *huart) // analog for hal function +{ + // rcc, dma and interrupt init for USARTs + // GPIO init was moved to own functions UART_GPIO_Init + if(0); +#ifdef USE_USART1 + else if(huart->Instance==USART1) + { + +// /* DMA2 clock enable */ +// __HAL_RCC_DMA2_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA2_Stream2_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA2_Stream2_IRQn); + + /* USART1 clock reset */ + __HAL_RCC_USART1_FORCE_RESET(); + __HAL_RCC_USART1_RELEASE_RESET(); + } +#endif // USE_USART1 +#ifdef USE_USART2 + else if(huart->Instance==USART2) + { +// /* DMA1 clock enable */ +// __HAL_RCC_DMA1_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA1_Stream5_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA1_Stream5_IRQn); + + /* USART2 clock reset */ + __HAL_RCC_USART2_FORCE_RESET(); + __HAL_RCC_USART2_RELEASE_RESET(); + } +#endif // USE_USART2 +#ifdef USE_USART3 + else if(huart->Instance==USART3) + { +// /* DMA1 clock enable */ +// __HAL_RCC_DMA1_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA1_Stream1_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA1_Stream1_IRQn); + + /* USART3 clock reset */ + __HAL_RCC_USART3_FORCE_RESET(); + __HAL_RCC_USART3_RELEASE_RESET(); + } +#endif // USE_USART3 +#ifdef USE_UART4 + else if(huart->Instance==UART4) + { +// /* DMA1 clock enable */ +// __HAL_RCC_DMA1_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA1_Stream2_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA1_Stream2_IRQn); + + /* UART4 clock reset */ + __HAL_RCC_UART4_FORCE_RESET(); + __HAL_RCC_UART4_RELEASE_RESET(); + } +#endif // USE_UART4 +#ifdef USE_UART5 + else if(huart->Instance==UART5) + { +// /* DMA1 clock enable */ +// __HAL_RCC_DMA1_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA1_Stream0_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA1_Stream0_IRQn); + + /* UART5 clock reset */ + __HAL_RCC_UART5_FORCE_RESET(); + __HAL_RCC_UART5_RELEASE_RESET(); + } +#endif // USE_UART5 +#ifdef USE_USART6 + else if(huart->Instance==USART6) + { +// /* DMA2 clock enable */ +// __HAL_RCC_DMA2_CLK_ENABLE(); +// /* DMA interrupt init */ +// HAL_NVIC_SetPriority(DMA2_Stream1_IRQn, 0, 0); +// HAL_NVIC_EnableIRQ(DMA2_Stream1_IRQn); + + /* USART6 clock reset */ + __HAL_RCC_USART6_FORCE_RESET(); + __HAL_RCC_USART6_RELEASE_RESET(); + } +#endif // USE_USART6 +} + +/** + * @brief Проверка корректности структуры инициализации UART. + * @param suart Указатель на структуру с настройками UART. + * @return HAL status. + */ +HAL_StatusTypeDef UART_Check_Init_Struct(UART_SettingsTypeDef *suart) +{ + // check is settings are valid + if (!IS_UART_INSTANCE(suart->huart.Instance)) + return HAL_ERROR; + + if (!IS_UART_BAUDRATE(suart->huart.Init.BaudRate) || (suart->huart.Init.BaudRate == NULL)) + return HAL_ERROR; + + if (!IS_GPIO_ALL_INSTANCE(suart->GPIOx)) + return HAL_ERROR; + + if (!IS_GPIO_PIN(suart->GPIO_PIN_RX) && !IS_GPIO_PIN(suart->GPIO_PIN_TX)) // if both pins arent set up + return HAL_ERROR; + + return HAL_OK; +} + +//------------------------UART INIT FUNCTIONS------------------------ +//------------------------------------------------------------------- diff --git a/MyLibsGeneral/mainpage.h b/MyLibsGeneral/mainpage.h new file mode 100644 index 0000000..d774781 --- /dev/null +++ b/MyLibsGeneral/mainpage.h @@ -0,0 +1,74 @@ + +/** +@mainpage + +@section overview Обзор +MyLibs - это набор библиотек для удобной работы с STM32. + +@subsection features Основные возможности + +@subsubsection utils_module Общие утилиты (@ref MYLIBS_DEFINES) +- Макросы для задержек и утилит (@ref DELAYS_DEFINES и @ref UTILS_DEFINES) +- Трекеры для статистики и отладки (@ref TRACKERS и @ref TRACE) +- Эволюционный алгоритм для оптимизации параметров (@ref EVOLVE_OPTIMIZER) +- Битовый доступ к регистрам через union (@ref BIT_ACCESS_DEFINES) + +@subsubsection trace_module Трассировка @ref TRACE +- Serial трассировка через SWO и RTT (@ref TRACE_SERIAL) +- GPIO трассировка для отладки (@ref TRACE_GPIO) +- Сохранение логов в Flash память (@ref TRACE_RTT_FLASH) +- Обработка HardFault с сохранением контекста (@ref TRACE_HARDFAULT) + +@subsubsection gpio_module Модуль GPIO @ref MY_LIBS_GPIO +- Инициализация портов и тактирования (@ref MYLIBS_GPIO_GENERAL) +- Управление светодиодами (включение/выключение, моргание, плавное затухание) (@ref MYLIBS_GPIO_LEDS) +- Работа с кнопками (чтение состояния, фильтрация дребезга) (@ref MYLIBS_GPIO_SWITCH) + +@subsubsection tim_module Модуль таймеров @ref MY_LIBS_TIM +- Базовая инициализация таймеров (@ref MYLIBS_TIM_GENERAL) +- Формирование задержек (блокирующие и неблокирующие) (@ref MYLIBS_TIM_DELAY) +- Работа с энкодерами (чтение положения, обработка кнопок) (@ref MYLIBS_TIM_ENCODER) +- Настройка ШИМ и Output Compare (@ref MYLIBS_TIM_OC) + +@subsubsection uart_module Модуль UART @ref MY_LIBS_UART +- Базовая инициализация UART и его пинов одной функцией (@ref UART_Base_Init) + +@subsubsection spi_module Модуль SPI @ref MY_LIBS_SPI +- Базовая инициализация SPI и пинов одной функцией (@ref SPI_Base_Init) + +@subsection structure Структура проекта + +@code +├── inc/ # Заголовочные файлы +│ ├── mylibs_include.h # Главный include файл +│ ├── mylibs_config.h # Конфигурация библиотек +│ ├── mylibs_defs.h # Общие определения и макросы +│ ├── bit_access.h # Битовый доступ к регистрам +│ ├── evolve_optimizer.h # Оптимизатор (генетический алгоритм) +│ ├── trackers.h # Трекеры для отладки +│ ├── trace.h # Трассировка и логирование +│ ├── general_gpio.h # Работа с GPIO + ├── general_spi.h # Работа с SPI +│ └── general_tim.h # Работа с таймерами + ├── general_uart.h # Работа с UART +└── src/ # Исходные файлы + ├── general_gpio.c # Реализация GPIO + ├── general_spi.c # Реализация SPI + └── general_tim.c # Реализация TIM + ├── general_uart.c # Реализация UART +@endcode + +@subsection usage_basic Использование + +Инструкция по подключению: + +1. Настройте конфигурацию @ref MYLIBS_CONFIG в @ref mylibs_config.h + +2. Подключите главный заголовочный файл: +@code +#include "mylibs_include.h" +@endcode + +3. Используйте нужные модули в своем коде. Примеры использования приведены в соответствующей теме + + */ \ No newline at end of file diff --git a/RTT/SEGGER_RTT.c b/RTT/SEGGER_RTT.c new file mode 100644 index 0000000..6a8bde4 --- /dev/null +++ b/RTT/SEGGER_RTT.c @@ -0,0 +1,2099 @@ +/********************************************************************* +* SEGGER Microcontroller GmbH * +* The Embedded Experts * +********************************************************************** +* * +* (c) 1995 - 2021 SEGGER Microcontroller GmbH * +* * +* www.segger.com Support: support@segger.com * +* * +********************************************************************** +* * +* SEGGER RTT * Real Time Transfer for embedded targets * +* * +********************************************************************** +* * +* All rights reserved. * +* * +* SEGGER strongly recommends to not make any changes * +* to or modify the source code of this software in order to stay * +* compatible with the RTT protocol and J-Link. * +* * +* Redistribution and use in source and binary forms, with or * +* without modification, are permitted provided that the following * +* condition is met: * +* * +* o Redistributions of source code must retain the above copyright * +* notice, this condition and the following disclaimer. * +* * +* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND * +* CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, * +* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * +* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * +* DISCLAIMED. IN NO EVENT SHALL SEGGER Microcontroller BE LIABLE FOR * +* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT * +* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; * +* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * +* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * +* USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * +* DAMAGE. * +* * +********************************************************************** +* * +* RTT version: 8.10g * +* * +********************************************************************** + +---------------------------END-OF-HEADER------------------------------ +File : SEGGER_RTT.c +Purpose : Implementation of SEGGER real-time transfer (RTT) which + allows real-time communication on targets which support + debugger memory accesses while the CPU is running. +Revision: $Rev: 29668 $ + +Additional information: + Type "int" is assumed to be 32-bits in size + H->T Host to target communication + T->H Target to host communication + + RTT channel 0 is always present and reserved for Terminal usage. + Name is fixed to "Terminal" + + Effective buffer size: SizeOfBuffer - 1 + + WrOff == RdOff: Buffer is empty + WrOff == (RdOff - 1): Buffer is full + WrOff > RdOff: Free space includes wrap-around + WrOff < RdOff: Used space includes wrap-around + (WrOff == (SizeOfBuffer - 1)) && (RdOff == 0): + Buffer full and wrap-around after next byte + + +---------------------------------------------------------------------- +*/ + +#include "SEGGER_RTT.h" + +#include // for memcpy + +/********************************************************************* +* +* Configuration, default values +* +********************************************************************** +*/ + +#if SEGGER_RTT_CPU_CACHE_LINE_SIZE + #ifdef SEGGER_RTT_CB_ALIGN + #error "Custom SEGGER_RTT_CB_ALIGN() is not supported for SEGGER_RTT_CPU_CACHE_LINE_SIZE != 0" + #endif + #ifdef SEGGER_RTT_BUFFER_ALIGN + #error "Custom SEGGER_RTT_BUFFER_ALIGN() is not supported for SEGGER_RTT_CPU_CACHE_LINE_SIZE != 0" + #endif + #ifdef SEGGER_RTT_PUT_CB_SECTION + #error "Custom SEGGER_RTT_PUT_CB_SECTION() is not supported for SEGGER_RTT_CPU_CACHE_LINE_SIZE != 0" + #endif + #ifdef SEGGER_RTT_PUT_BUFFER_SECTION + #error "Custom SEGGER_RTT_PUT_BUFFER_SECTION() is not supported for SEGGER_RTT_CPU_CACHE_LINE_SIZE != 0" + #endif + #ifdef SEGGER_RTT_BUFFER_ALIGNMENT + #error "Custom SEGGER_RTT_BUFFER_ALIGNMENT is not supported for SEGGER_RTT_CPU_CACHE_LINE_SIZE != 0" + #endif + #ifdef SEGGER_RTT_ALIGNMENT + #error "Custom SEGGER_RTT_ALIGNMENT is not supported for SEGGER_RTT_CPU_CACHE_LINE_SIZE != 0" + #endif +#endif + +#ifndef BUFFER_SIZE_UP + #define BUFFER_SIZE_UP 1024 // Size of the buffer for terminal output of target, up to host +#endif + +#ifndef BUFFER_SIZE_DOWN + #define BUFFER_SIZE_DOWN 16 // Size of the buffer for terminal input to target from host (Usually keyboard input) +#endif + +#ifndef SEGGER_RTT_MAX_NUM_UP_BUFFERS + #define SEGGER_RTT_MAX_NUM_UP_BUFFERS 2 // Number of up-buffers (T->H) available on this target +#endif + +#ifndef SEGGER_RTT_MAX_NUM_DOWN_BUFFERS + #define SEGGER_RTT_MAX_NUM_DOWN_BUFFERS 2 // Number of down-buffers (H->T) available on this target +#endif + +#ifndef SEGGER_RTT_BUFFER_SECTION + #if defined(SEGGER_RTT_SECTION) + #define SEGGER_RTT_BUFFER_SECTION SEGGER_RTT_SECTION + #endif +#endif + +#ifndef SEGGER_RTT_ALIGNMENT + #define SEGGER_RTT_ALIGNMENT SEGGER_RTT_CPU_CACHE_LINE_SIZE +#endif + +#ifndef SEGGER_RTT_BUFFER_ALIGNMENT + #define SEGGER_RTT_BUFFER_ALIGNMENT SEGGER_RTT_CPU_CACHE_LINE_SIZE +#endif + +#ifndef SEGGER_RTT_MODE_DEFAULT + #define SEGGER_RTT_MODE_DEFAULT SEGGER_RTT_MODE_NO_BLOCK_SKIP +#endif + +#ifndef SEGGER_RTT_LOCK + #define SEGGER_RTT_LOCK() +#endif + +#ifndef SEGGER_RTT_UNLOCK + #define SEGGER_RTT_UNLOCK() +#endif + +#ifndef STRLEN + #define STRLEN(a) strlen((a)) +#endif + +#ifndef STRCPY + #define STRCPY(pDest, pSrc) strcpy((pDest), (pSrc)) +#endif + +#ifndef SEGGER_RTT_MEMCPY_USE_BYTELOOP + #define SEGGER_RTT_MEMCPY_USE_BYTELOOP 0 +#endif + +#ifndef SEGGER_RTT_MEMCPY + #ifdef MEMCPY + #define SEGGER_RTT_MEMCPY(pDest, pSrc, NumBytes) MEMCPY((pDest), (pSrc), (NumBytes)) + #else + #define SEGGER_RTT_MEMCPY(pDest, pSrc, NumBytes) memcpy((pDest), (pSrc), (NumBytes)) + #endif +#endif + +#ifndef MIN + #define MIN(a, b) (((a) < (b)) ? (a) : (b)) +#endif + +#ifndef MAX + #define MAX(a, b) (((a) > (b)) ? (a) : (b)) +#endif + +/********************************************************************* +* +* Defines, fixed +* +********************************************************************** +*/ +#if (defined __ICCARM__) || (defined __ICCRX__) + #define RTT_PRAGMA(P) _Pragma(#P) +#endif + +#if SEGGER_RTT_ALIGNMENT || SEGGER_RTT_BUFFER_ALIGNMENT + #if ((defined __GNUC__) || (defined __clang__)) + #define SEGGER_RTT_ALIGN(Var, Alignment) Var __attribute__ ((aligned (Alignment))) + #elif (defined __ICCARM__) || (defined __ICCRX__) + #define PRAGMA(A) _Pragma(#A) +#define SEGGER_RTT_ALIGN(Var, Alignment) RTT_PRAGMA(data_alignment=Alignment) \ + Var + #elif (defined __CC_ARM) + #define SEGGER_RTT_ALIGN(Var, Alignment) Var __attribute__ ((aligned (Alignment))) + #else + #error "Alignment not supported for this compiler." + #endif +#else + #define SEGGER_RTT_ALIGN(Var, Alignment) Var +#endif + +#if defined(SEGGER_RTT_SECTION) || defined (SEGGER_RTT_BUFFER_SECTION) + #if ((defined __GNUC__) || (defined __clang__)) + #define SEGGER_RTT_PUT_SECTION(Var, Section) __attribute__ ((section (Section))) Var + #elif (defined __ICCARM__) || (defined __ICCRX__) +#define SEGGER_RTT_PUT_SECTION(Var, Section) RTT_PRAGMA(location=Section) \ + Var + #elif (defined __CC_ARM) + #define SEGGER_RTT_PUT_SECTION(Var, Section) __attribute__ ((section (Section), zero_init)) Var + #else + #error "Section placement not supported for this compiler." + #endif +#else + #define SEGGER_RTT_PUT_SECTION(Var, Section) Var +#endif + +#if SEGGER_RTT_ALIGNMENT + #define SEGGER_RTT_CB_ALIGN(Var) SEGGER_RTT_ALIGN(Var, SEGGER_RTT_ALIGNMENT) +#else + #define SEGGER_RTT_CB_ALIGN(Var) Var +#endif + +#if SEGGER_RTT_BUFFER_ALIGNMENT + #define SEGGER_RTT_BUFFER_ALIGN(Var) SEGGER_RTT_ALIGN(Var, SEGGER_RTT_BUFFER_ALIGNMENT) +#else + #define SEGGER_RTT_BUFFER_ALIGN(Var) Var +#endif + + +#if defined(SEGGER_RTT_SECTION) + #define SEGGER_RTT_PUT_CB_SECTION(Var) SEGGER_RTT_PUT_SECTION(Var, SEGGER_RTT_SECTION) +#else + #define SEGGER_RTT_PUT_CB_SECTION(Var) Var +#endif + +#if defined(SEGGER_RTT_BUFFER_SECTION) + #define SEGGER_RTT_PUT_BUFFER_SECTION(Var) SEGGER_RTT_PUT_SECTION(Var, SEGGER_RTT_BUFFER_SECTION) +#else + #define SEGGER_RTT_PUT_BUFFER_SECTION(Var) Var +#endif + +/********************************************************************* +* +* Static const data +* +********************************************************************** +*/ + +static const unsigned char _aTerminalId[16] = { '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' }; + +/********************************************************************* +* +* Static data +* +********************************************************************** +*/ + +// +// RTT Control Block and allocate buffers for channel 0 +// +#if SEGGER_RTT_CPU_CACHE_LINE_SIZE + #if ((defined __GNUC__) || (defined __clang__)) + SEGGER_RTT_CB _SEGGER_RTT __attribute__ ((aligned (SEGGER_RTT_CPU_CACHE_LINE_SIZE))); + static char _acUpBuffer [SEGGER_RTT__ROUND_UP_2_CACHE_LINE_SIZE(BUFFER_SIZE_UP)] __attribute__ ((aligned (SEGGER_RTT_CPU_CACHE_LINE_SIZE))); + static char _acDownBuffer[SEGGER_RTT__ROUND_UP_2_CACHE_LINE_SIZE(BUFFER_SIZE_DOWN)] __attribute__ ((aligned (SEGGER_RTT_CPU_CACHE_LINE_SIZE))); + #elif (defined __ICCARM__) + #pragma data_alignment=SEGGER_RTT_CPU_CACHE_LINE_SIZE + SEGGER_RTT_CB _SEGGER_RTT; + #pragma data_alignment=SEGGER_RTT_CPU_CACHE_LINE_SIZE + static char _acUpBuffer [SEGGER_RTT__ROUND_UP_2_CACHE_LINE_SIZE(BUFFER_SIZE_UP)]; + #pragma data_alignment=SEGGER_RTT_CPU_CACHE_LINE_SIZE + static char _acDownBuffer[SEGGER_RTT__ROUND_UP_2_CACHE_LINE_SIZE(BUFFER_SIZE_DOWN)]; + #else + #error "Don't know how to place _SEGGER_RTT, _acUpBuffer, _acDownBuffer cache-line aligned" + #endif +#else + SEGGER_RTT_PUT_CB_SECTION(SEGGER_RTT_CB_ALIGN(SEGGER_RTT_CB _SEGGER_RTT)); + SEGGER_RTT_PUT_BUFFER_SECTION(SEGGER_RTT_BUFFER_ALIGN(static char _acUpBuffer [BUFFER_SIZE_UP])); + SEGGER_RTT_PUT_BUFFER_SECTION(SEGGER_RTT_BUFFER_ALIGN(static char _acDownBuffer[BUFFER_SIZE_DOWN])); +#endif + +static unsigned char _ActiveTerminal; + +/********************************************************************* +* +* Static functions +* +********************************************************************** +*/ + +/********************************************************************* +* +* _DoInit() +* +* Function description +* Initializes the control block an buffers. +* +* Notes +* (1) May only be called via INIT() to avoid overriding settings. +* The only exception is SEGGER_RTT_Init(), to make an intentional override possible. +*/ + #define INIT() \ + do { \ + volatile SEGGER_RTT_CB* pRTTCBInit; \ + pRTTCBInit = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); \ + if (pRTTCBInit->acID[0] != 'S') { \ + _DoInit(); \ + } \ + } while (0) + +static void _DoInit(void) { + volatile SEGGER_RTT_CB* p; // Volatile to make sure that compiler cannot change the order of accesses to the control block + static const char _aInitStr[] = "\0\0\0\0\0\0TTR REGGES"; // Init complete ID string to make sure that things also work if RTT is linked to a no-init memory area + unsigned i; + // + // Initialize control block + // + p = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access control block uncached so that nothing in the cache ever becomes dirty and all changes are visible in HW directly + memset((SEGGER_RTT_CB*)p, 0, sizeof(_SEGGER_RTT)); // Make sure that the RTT CB is always zero initialized. + p->MaxNumUpBuffers = SEGGER_RTT_MAX_NUM_UP_BUFFERS; + p->MaxNumDownBuffers = SEGGER_RTT_MAX_NUM_DOWN_BUFFERS; + // + // Initialize up buffer 0 + // + p->aUp[0].sName = "Terminal"; + p->aUp[0].pBuffer = _acUpBuffer; + p->aUp[0].SizeOfBuffer = BUFFER_SIZE_UP; + p->aUp[0].RdOff = 0u; + p->aUp[0].WrOff = 0u; + p->aUp[0].Flags = SEGGER_RTT_MODE_DEFAULT; + // + // Initialize down buffer 0 + // + p->aDown[0].sName = "Terminal"; + p->aDown[0].pBuffer = _acDownBuffer; + p->aDown[0].SizeOfBuffer = BUFFER_SIZE_DOWN; + p->aDown[0].RdOff = 0u; + p->aDown[0].WrOff = 0u; + p->aDown[0].Flags = SEGGER_RTT_MODE_DEFAULT; + // + // Finish initialization of the control block. + // Copy Id string backwards to make sure that "SEGGER RTT" is not found in initializer memory (usually flash), + // as this would cause J-Link to "find" the control block at a wrong address. + // + RTT__DMB(); // Force order of memory accesses for cores that may perform out-of-order memory accesses + for (i = 0; i < sizeof(_aInitStr) - 1; ++i) { + p->acID[i] = _aInitStr[sizeof(_aInitStr) - 2 - i]; // Skip terminating \0 at the end of the array + } + RTT__DMB(); // Force order of memory accesses for cores that may perform out-of-order memory accesses +} + +/********************************************************************* +* +* _WriteBlocking() +* +* Function description +* Stores a specified number of characters in SEGGER RTT ring buffer +* and updates the associated write pointer which is periodically +* read by the host. +* The caller is responsible for managing the write chunk sizes as +* _WriteBlocking() will block until all data has been posted successfully. +* +* Parameters +* pRing Ring buffer to post to. +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* +* Return value +* >= 0 - Number of bytes written into buffer. +*/ +static unsigned _WriteBlocking(SEGGER_RTT_BUFFER_UP* pRing, const char* pBuffer, unsigned NumBytes) { + unsigned NumBytesToWrite; + unsigned NumBytesWritten; + unsigned RdOff; + unsigned WrOff; + volatile char* pDst; + // + // Write data to buffer and handle wrap-around if necessary + // + NumBytesWritten = 0u; + WrOff = pRing->WrOff; + do { + RdOff = pRing->RdOff; // May be changed by host (debug probe) in the meantime + if (RdOff > WrOff) { + NumBytesToWrite = RdOff - WrOff - 1u; + } else { + NumBytesToWrite = pRing->SizeOfBuffer - (WrOff - RdOff + 1u); + } + NumBytesToWrite = MIN(NumBytesToWrite, (pRing->SizeOfBuffer - WrOff)); // Number of bytes that can be written until buffer wrap-around + NumBytesToWrite = MIN(NumBytesToWrite, NumBytes); + pDst = (pRing->pBuffer + WrOff) + SEGGER_RTT_UNCACHED_OFF; +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + NumBytesWritten += NumBytesToWrite; + NumBytes -= NumBytesToWrite; + WrOff += NumBytesToWrite; + while (NumBytesToWrite--) { + *pDst++ = *pBuffer++; + }; +#else + SEGGER_RTT_MEMCPY((void*)pDst, pBuffer, NumBytesToWrite); + NumBytesWritten += NumBytesToWrite; + pBuffer += NumBytesToWrite; + NumBytes -= NumBytesToWrite; + WrOff += NumBytesToWrite; +#endif + if (WrOff == pRing->SizeOfBuffer) { + WrOff = 0u; + } + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = WrOff; + } while (NumBytes); + return NumBytesWritten; +} + +/********************************************************************* +* +* _WriteNoCheck() +* +* Function description +* Stores a specified number of characters in SEGGER RTT ring buffer +* and updates the associated write pointer which is periodically +* read by the host. +* It is callers responsibility to make sure data actually fits in buffer. +* +* Parameters +* pRing Ring buffer to post to. +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* +* Notes +* (1) If there might not be enough space in the "Up"-buffer, call _WriteBlocking +*/ +static void _WriteNoCheck(SEGGER_RTT_BUFFER_UP* pRing, const char* pData, unsigned NumBytes) { + unsigned NumBytesAtOnce; + unsigned WrOff; + unsigned Rem; + volatile char* pDst; + + WrOff = pRing->WrOff; + Rem = pRing->SizeOfBuffer - WrOff; + if (Rem > NumBytes) { + // + // All data fits before wrap around + // + pDst = (pRing->pBuffer + WrOff) + SEGGER_RTT_UNCACHED_OFF; +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + WrOff += NumBytes; + while (NumBytes--) { + *pDst++ = *pData++; + }; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = WrOff; +#else + SEGGER_RTT_MEMCPY((void*)pDst, pData, NumBytes); + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = WrOff + NumBytes; +#endif + } else { + // + // We reach the end of the buffer, so need to wrap around + // +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + pDst = (pRing->pBuffer + WrOff) + SEGGER_RTT_UNCACHED_OFF; + NumBytesAtOnce = Rem; + while (NumBytesAtOnce--) { + *pDst++ = *pData++; + }; + pDst = pRing->pBuffer + SEGGER_RTT_UNCACHED_OFF; + NumBytesAtOnce = NumBytes - Rem; + while (NumBytesAtOnce--) { + *pDst++ = *pData++; + }; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = NumBytes - Rem; +#else + NumBytesAtOnce = Rem; + pDst = (pRing->pBuffer + WrOff) + SEGGER_RTT_UNCACHED_OFF; + SEGGER_RTT_MEMCPY((void*)pDst, pData, NumBytesAtOnce); + NumBytesAtOnce = NumBytes - Rem; + pDst = pRing->pBuffer + SEGGER_RTT_UNCACHED_OFF; + SEGGER_RTT_MEMCPY((void*)pDst, pData + Rem, NumBytesAtOnce); + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = NumBytesAtOnce; +#endif + } +} + +/********************************************************************* +* +* _PostTerminalSwitch() +* +* Function description +* Switch terminal to the given terminal ID. It is the caller's +* responsibility to ensure the terminal ID is correct and there is +* enough space in the buffer for this to complete successfully. +* +* Parameters +* pRing Ring buffer to post to. +* TerminalId Terminal ID to switch to. +*/ +static void _PostTerminalSwitch(SEGGER_RTT_BUFFER_UP* pRing, unsigned char TerminalId) { + unsigned char ac[2]; + + ac[0] = 0xFFu; + ac[1] = _aTerminalId[TerminalId]; // Caller made already sure that TerminalId does not exceed our terminal limit + _WriteBlocking(pRing, (const char*)ac, 2u); +} + +/********************************************************************* +* +* _GetAvailWriteSpace() +* +* Function description +* Returns the number of bytes that can be written to the ring +* buffer without blocking. +* +* Parameters +* pRing Ring buffer to check. +* +* Return value +* Number of bytes that are free in the buffer. +*/ +static unsigned _GetAvailWriteSpace(SEGGER_RTT_BUFFER_UP* pRing) { + unsigned RdOff; + unsigned WrOff; + unsigned r; + // + // Avoid warnings regarding volatile access order. It's not a problem + // in this case, but dampen compiler enthusiasm. + // + RdOff = pRing->RdOff; + WrOff = pRing->WrOff; + if (RdOff <= WrOff) { + r = pRing->SizeOfBuffer - 1u - WrOff + RdOff; + } else { + r = RdOff - WrOff - 1u; + } + return r; +} + +/********************************************************************* +* +* Public code +* +********************************************************************** +*/ + +/********************************************************************* +* +* SEGGER_RTT_ReadUpBufferNoLock() +* +* Function description +* Reads characters from SEGGER real-time-terminal control block +* which have been previously stored by the application. +* Do not lock against interrupts and multiple access. +* Used to do the same operation that J-Link does, to transfer +* RTT data via other channels, such as TCP/IP or UART. +* +* Parameters +* BufferIndex Index of Up-buffer to be used. +* pBuffer Pointer to buffer provided by target application, to copy characters from RTT-up-buffer to. +* BufferSize Size of the target application buffer. +* +* Return value +* Number of bytes that have been read. +* +* Additional information +* This function must not be called when J-Link might also do RTT. +*/ +unsigned SEGGER_RTT_ReadUpBufferNoLock(unsigned BufferIndex, void* pData, unsigned BufferSize) { + unsigned NumBytesRem; + unsigned NumBytesRead; + unsigned RdOff; + unsigned WrOff; + unsigned char* pBuffer; + SEGGER_RTT_BUFFER_UP* pRing; + volatile char* pSrc; + + INIT(); + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + pBuffer = (unsigned char*)pData; + RdOff = pRing->RdOff; + WrOff = pRing->WrOff; + NumBytesRead = 0u; + // + // Read from current read position to wrap-around of buffer, first + // + if (RdOff > WrOff) { + NumBytesRem = pRing->SizeOfBuffer - RdOff; + NumBytesRem = MIN(NumBytesRem, BufferSize); + pSrc = (pRing->pBuffer + RdOff) + SEGGER_RTT_UNCACHED_OFF; +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + NumBytesRead += NumBytesRem; + BufferSize -= NumBytesRem; + RdOff += NumBytesRem; + while (NumBytesRem--) { + *pBuffer++ = *pSrc++; + }; +#else + SEGGER_RTT_MEMCPY(pBuffer, (void*)pSrc, NumBytesRem); + NumBytesRead += NumBytesRem; + pBuffer += NumBytesRem; + BufferSize -= NumBytesRem; + RdOff += NumBytesRem; +#endif + // + // Handle wrap-around of buffer + // + if (RdOff == pRing->SizeOfBuffer) { + RdOff = 0u; + } + } + // + // Read remaining items of buffer + // + NumBytesRem = WrOff - RdOff; + NumBytesRem = MIN(NumBytesRem, BufferSize); + if (NumBytesRem > 0u) { + pSrc = (pRing->pBuffer + RdOff) + SEGGER_RTT_UNCACHED_OFF; +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + NumBytesRead += NumBytesRem; + BufferSize -= NumBytesRem; + RdOff += NumBytesRem; + while (NumBytesRem--) { + *pBuffer++ = *pSrc++; + }; +#else + SEGGER_RTT_MEMCPY(pBuffer, (void*)pSrc, NumBytesRem); + NumBytesRead += NumBytesRem; + pBuffer += NumBytesRem; + BufferSize -= NumBytesRem; + RdOff += NumBytesRem; +#endif + } + // + // Update read offset of buffer + // + if (NumBytesRead) { + pRing->RdOff = RdOff; + } + // + return NumBytesRead; +} + +/********************************************************************* +* +* SEGGER_RTT_ReadNoLock() +* +* Function description +* Reads characters from SEGGER real-time-terminal control block +* which have been previously stored by the host. +* Do not lock against interrupts and multiple access. +* +* Parameters +* BufferIndex Index of Down-buffer to be used (e.g. 0 for "Terminal"). +* pBuffer Pointer to buffer provided by target application, to copy characters from RTT-down-buffer to. +* BufferSize Size of the target application buffer. +* +* Return value +* Number of bytes that have been read. +*/ +unsigned SEGGER_RTT_ReadNoLock(unsigned BufferIndex, void* pData, unsigned BufferSize) { + unsigned NumBytesRem; + unsigned NumBytesRead; + unsigned RdOff; + unsigned WrOff; + unsigned char* pBuffer; + SEGGER_RTT_BUFFER_DOWN* pRing; + volatile char* pSrc; + // + INIT(); + pRing = (SEGGER_RTT_BUFFER_DOWN*)((uintptr_t)&_SEGGER_RTT.aDown[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + pBuffer = (unsigned char*)pData; + RdOff = pRing->RdOff; + WrOff = pRing->WrOff; + NumBytesRead = 0u; + // + // Read from current read position to wrap-around of buffer, first + // + if (RdOff > WrOff) { + NumBytesRem = pRing->SizeOfBuffer - RdOff; + NumBytesRem = MIN(NumBytesRem, BufferSize); + pSrc = (pRing->pBuffer + RdOff) + SEGGER_RTT_UNCACHED_OFF; +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + NumBytesRead += NumBytesRem; + BufferSize -= NumBytesRem; + RdOff += NumBytesRem; + while (NumBytesRem--) { + *pBuffer++ = *pSrc++; + }; +#else + SEGGER_RTT_MEMCPY(pBuffer, (void*)pSrc, NumBytesRem); + NumBytesRead += NumBytesRem; + pBuffer += NumBytesRem; + BufferSize -= NumBytesRem; + RdOff += NumBytesRem; +#endif + // + // Handle wrap-around of buffer + // + if (RdOff == pRing->SizeOfBuffer) { + RdOff = 0u; + } + } + // + // Read remaining items of buffer + // + NumBytesRem = WrOff - RdOff; + NumBytesRem = MIN(NumBytesRem, BufferSize); + if (NumBytesRem > 0u) { + pSrc = (pRing->pBuffer + RdOff) + SEGGER_RTT_UNCACHED_OFF; +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + NumBytesRead += NumBytesRem; + BufferSize -= NumBytesRem; + RdOff += NumBytesRem; + while (NumBytesRem--) { + *pBuffer++ = *pSrc++; + }; +#else + SEGGER_RTT_MEMCPY(pBuffer, (void*)pSrc, NumBytesRem); + NumBytesRead += NumBytesRem; + pBuffer += NumBytesRem; + BufferSize -= NumBytesRem; + RdOff += NumBytesRem; +#endif + } + if (NumBytesRead) { + pRing->RdOff = RdOff; + } + // + return NumBytesRead; +} + +/********************************************************************* +* +* SEGGER_RTT_ReadUpBuffer +* +* Function description +* Reads characters from SEGGER real-time-terminal control block +* which have been previously stored by the application. +* Used to do the same operation that J-Link does, to transfer +* RTT data via other channels, such as TCP/IP or UART. +* +* Parameters +* BufferIndex Index of Up-buffer to be used. +* pBuffer Pointer to buffer provided by target application, to copy characters from RTT-up-buffer to. +* BufferSize Size of the target application buffer. +* +* Return value +* Number of bytes that have been read. +* +* Additional information +* This function must not be called when J-Link might also do RTT. +* This function locks against all other RTT operations. I.e. during +* the read operation, writing is also locked. +* If only one consumer reads from the up buffer, +* call sEGGER_RTT_ReadUpBufferNoLock() instead. +*/ +unsigned SEGGER_RTT_ReadUpBuffer(unsigned BufferIndex, void* pBuffer, unsigned BufferSize) { + unsigned NumBytesRead; + + SEGGER_RTT_LOCK(); + // + // Call the non-locking read function + // + NumBytesRead = SEGGER_RTT_ReadUpBufferNoLock(BufferIndex, pBuffer, BufferSize); + // + // Finish up. + // + SEGGER_RTT_UNLOCK(); + // + return NumBytesRead; +} + +/********************************************************************* +* +* SEGGER_RTT_Read +* +* Function description +* Reads characters from SEGGER real-time-terminal control block +* which have been previously stored by the host. +* +* Parameters +* BufferIndex Index of Down-buffer to be used (e.g. 0 for "Terminal"). +* pBuffer Pointer to buffer provided by target application, to copy characters from RTT-down-buffer to. +* BufferSize Size of the target application buffer. +* +* Return value +* Number of bytes that have been read. +*/ +unsigned SEGGER_RTT_Read(unsigned BufferIndex, void* pBuffer, unsigned BufferSize) { + unsigned NumBytesRead; + + SEGGER_RTT_LOCK(); + // + // Call the non-locking read function + // + NumBytesRead = SEGGER_RTT_ReadNoLock(BufferIndex, pBuffer, BufferSize); + // + // Finish up. + // + SEGGER_RTT_UNLOCK(); + // + return NumBytesRead; +} + +/********************************************************************* +* +* SEGGER_RTT_WriteWithOverwriteNoLock +* +* Function description +* Stores a specified number of characters in SEGGER RTT +* control block. +* SEGGER_RTT_WriteWithOverwriteNoLock does not lock the application +* and overwrites data if the data does not fit into the buffer. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* +* Notes +* (1) If there is not enough space in the "Up"-buffer, data is overwritten. +* (2) For performance reasons this function does not call Init() +* and may only be called after RTT has been initialized. +* Either by calling SEGGER_RTT_Init() or calling another RTT API function first. +* (3) Do not use SEGGER_RTT_WriteWithOverwriteNoLock if a J-Link +* connection reads RTT data. +*/ +void SEGGER_RTT_WriteWithOverwriteNoLock(unsigned BufferIndex, const void* pBuffer, unsigned NumBytes) { + const char* pData; + SEGGER_RTT_BUFFER_UP* pRing; + unsigned Avail; + volatile char* pDst; + // + // Get "to-host" ring buffer and copy some elements into local variables. + // + pData = (const char *)pBuffer; + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + // + // Check if we will overwrite data and need to adjust the RdOff. + // + if (pRing->WrOff == pRing->RdOff) { + Avail = pRing->SizeOfBuffer - 1u; + } else if ( pRing->WrOff < pRing->RdOff) { + Avail = pRing->RdOff - pRing->WrOff - 1u; + } else { + Avail = pRing->RdOff - pRing->WrOff - 1u + pRing->SizeOfBuffer; + } + if (NumBytes > Avail) { + pRing->RdOff += (NumBytes - Avail); + while (pRing->RdOff >= pRing->SizeOfBuffer) { + pRing->RdOff -= pRing->SizeOfBuffer; + } + } + // + // Write all data, no need to check the RdOff, but possibly handle multiple wrap-arounds + // + Avail = pRing->SizeOfBuffer - pRing->WrOff; + do { + if (Avail > NumBytes) { + // + // Last round + // + pDst = (pRing->pBuffer + pRing->WrOff) + SEGGER_RTT_UNCACHED_OFF; +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + Avail = NumBytes; + while (NumBytes--) { + *pDst++ = *pData++; + }; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff += Avail; +#else + SEGGER_RTT_MEMCPY((void*)pDst, pData, NumBytes); + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff += NumBytes; +#endif + break; + } else { + // + // Wrap-around necessary, write until wrap-around and reset WrOff + // + pDst = (pRing->pBuffer + pRing->WrOff) + SEGGER_RTT_UNCACHED_OFF; +#if SEGGER_RTT_MEMCPY_USE_BYTELOOP + NumBytes -= Avail; + while (Avail--) { + *pDst++ = *pData++; + }; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = 0; +#else + SEGGER_RTT_MEMCPY((void*)pDst, pData, Avail); + pData += Avail; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = 0; + NumBytes -= Avail; +#endif + Avail = (pRing->SizeOfBuffer - 1); + } + } while (NumBytes); +} + +/********************************************************************* +* +* SEGGER_RTT_WriteSkipNoLock +* +* Function description +* Stores a specified number of characters in SEGGER RTT +* control block which is then read by the host. +* SEGGER_RTT_WriteSkipNoLock does not lock the application and +* skips all data, if the data does not fit into the buffer. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* MUST be > 0!!! +* This is done for performance reasons, so no initial check has do be done. +* +* Return value +* 1: Data has been copied +* 0: No space, data has not been copied +* +* Notes +* (1) If there is not enough space in the "Up"-buffer, all data is dropped. +* (2) For performance reasons this function does not call Init() +* and may only be called after RTT has been initialized. +* Either by calling SEGGER_RTT_Init() or calling another RTT API function first. +*/ +#if (RTT_USE_ASM == 0) +unsigned SEGGER_RTT_WriteSkipNoLock(unsigned BufferIndex, const void* pBuffer, unsigned NumBytes) { + const char* pData; + SEGGER_RTT_BUFFER_UP* pRing; + unsigned Avail; + unsigned RdOff; + unsigned WrOff; + unsigned Rem; + volatile char* pDst; + // + // Cases: + // 1) RdOff <= WrOff => Space until wrap-around is sufficient + // 2) RdOff <= WrOff => Space after wrap-around needed (copy in 2 chunks) + // 3) RdOff < WrOff => No space in buf + // 4) RdOff > WrOff => Space is sufficient + // 5) RdOff > WrOff => No space in buf + // + // 1) is the most common case for large buffers and assuming that J-Link reads the data fast enough + // + pData = (const char *)pBuffer; + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + RdOff = pRing->RdOff; + WrOff = pRing->WrOff; + pDst = (pRing->pBuffer + WrOff) + SEGGER_RTT_UNCACHED_OFF; + if (RdOff <= WrOff) { // Case 1), 2) or 3) + Avail = pRing->SizeOfBuffer - WrOff - 1u; // Space until wrap-around (assume 1 byte not usable for case that RdOff == 0) + if (Avail >= NumBytes) { // Case 1)? + memcpy((void*)pDst, pData, NumBytes); + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = WrOff + NumBytes; + return 1; + } + Avail += RdOff; // Space incl. wrap-around + if (Avail >= NumBytes) { // Case 2? => If not, we have case 3) (does not fit) + Rem = pRing->SizeOfBuffer - WrOff; // Space until end of buffer + memcpy((void*)pDst, pData, Rem); // Copy 1st chunk + NumBytes -= Rem; + // + // Special case: First check that assumed RdOff == 0 calculated that last element before wrap-around could not be used + // But 2nd check (considering space until wrap-around and until RdOff) revealed that RdOff is not 0, so we can use the last element + // In this case, we may use a copy straight until buffer end anyway without needing to copy 2 chunks + // Therefore, check if 2nd memcpy is necessary at all + // + if (NumBytes) { + pDst = pRing->pBuffer + SEGGER_RTT_UNCACHED_OFF; + memcpy((void*)pDst, pData + Rem, NumBytes); + } + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = NumBytes; + return 1; + } + } else { // Potential case 4) + Avail = RdOff - WrOff - 1u; + if (Avail >= NumBytes) { // Case 4)? => If not, we have case 5) (does not fit) + memcpy((void*)pDst, pData, NumBytes); + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = WrOff + NumBytes; + return 1; + } + } + return 0; // No space in buffer +} +#endif + +/********************************************************************* +* +* SEGGER_RTT_WriteDownBufferNoLock +* +* Function description +* Stores a specified number of characters in SEGGER RTT +* control block inside a buffer. +* SEGGER_RTT_WriteDownBufferNoLock does not lock the application. +* Used to do the same operation that J-Link does, to transfer +* RTT data from other channels, such as TCP/IP or UART. +* +* Parameters +* BufferIndex Index of "Down"-buffer to be used. +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* +* Return value +* Number of bytes which have been stored in the "Down"-buffer. +* +* Notes +* (1) Data is stored according to buffer flags. +* (2) For performance reasons this function does not call Init() +* and may only be called after RTT has been initialized. +* Either by calling SEGGER_RTT_Init() or calling another RTT API function first. +* +* Additional information +* This function must not be called when J-Link might also do RTT. +*/ +unsigned SEGGER_RTT_WriteDownBufferNoLock(unsigned BufferIndex, const void* pBuffer, unsigned NumBytes) { + unsigned Status; + unsigned Avail; + const char* pData; + SEGGER_RTT_BUFFER_UP* pRing; + // + // Get "to-target" ring buffer. + // It is save to cast that to a "to-host" buffer. Up and Down buffer differ in volatility of offsets that might be modified by J-Link. + // + pData = (const char *)pBuffer; + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aDown[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + // + // How we output depends upon the mode... + // + switch (pRing->Flags) { + case SEGGER_RTT_MODE_NO_BLOCK_SKIP: + // + // If we are in skip mode and there is no space for the whole + // of this output, don't bother. + // + Avail = _GetAvailWriteSpace(pRing); + if (Avail < NumBytes) { + Status = 0u; + } else { + Status = NumBytes; + _WriteNoCheck(pRing, pData, NumBytes); + } + break; + case SEGGER_RTT_MODE_NO_BLOCK_TRIM: + // + // If we are in trim mode, trim to what we can output without blocking. + // + Avail = _GetAvailWriteSpace(pRing); + Status = Avail < NumBytes ? Avail : NumBytes; + _WriteNoCheck(pRing, pData, Status); + break; + case SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL: + // + // If we are in blocking mode, output everything. + // + Status = _WriteBlocking(pRing, pData, NumBytes); + break; + default: + Status = 0u; + break; + } + // + // Finish up. + // + return Status; +} + +/********************************************************************* +* +* SEGGER_RTT_WriteNoLock +* +* Function description +* Stores a specified number of characters in SEGGER RTT +* control block which is then read by the host. +* SEGGER_RTT_WriteNoLock does not lock the application. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* +* Return value +* Number of bytes which have been stored in the "Up"-buffer. +* +* Notes +* (1) Data is stored according to buffer flags. +* (2) For performance reasons this function does not call Init() +* and may only be called after RTT has been initialized. +* Either by calling SEGGER_RTT_Init() or calling another RTT API function first. +*/ +unsigned SEGGER_RTT_WriteNoLock(unsigned BufferIndex, const void* pBuffer, unsigned NumBytes) { + unsigned Status; + unsigned Avail; + const char* pData; + SEGGER_RTT_BUFFER_UP* pRing; + // + // Get "to-host" ring buffer. + // + pData = (const char *)pBuffer; + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + // + // How we output depends upon the mode... + // + switch (pRing->Flags) { + case SEGGER_RTT_MODE_NO_BLOCK_SKIP: + // + // If we are in skip mode and there is no space for the whole + // of this output, don't bother. + // + Avail = _GetAvailWriteSpace(pRing); + if (Avail < NumBytes) { + Status = 0u; + } else { + Status = NumBytes; + _WriteNoCheck(pRing, pData, NumBytes); + } + break; + case SEGGER_RTT_MODE_NO_BLOCK_TRIM: + // + // If we are in trim mode, trim to what we can output without blocking. + // + Avail = _GetAvailWriteSpace(pRing); + Status = Avail < NumBytes ? Avail : NumBytes; + _WriteNoCheck(pRing, pData, Status); + break; + case SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL: + // + // If we are in blocking mode, output everything. + // + Status = _WriteBlocking(pRing, pData, NumBytes); + break; + default: + Status = 0u; + break; + } + // + // Finish up. + // + return Status; +} + +/********************************************************************* +* +* SEGGER_RTT_WriteDownBuffer +* +* Function description +* Stores a specified number of characters in SEGGER RTT control block in a buffer. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* +* Return value +* Number of bytes which have been stored in the "Down"-buffer. +* +* Notes +* (1) Data is stored according to buffer flags. +* +* Additional information +* This function must not be called when J-Link might also do RTT. +* This function locks against all other RTT operations. I.e. during +* the write operation, writing from the application is also locked. +* If only one consumer writes to the down buffer, +* call SEGGER_RTT_WriteDownBufferNoLock() instead. +*/ +unsigned SEGGER_RTT_WriteDownBuffer(unsigned BufferIndex, const void* pBuffer, unsigned NumBytes) { + unsigned Status; + + INIT(); + SEGGER_RTT_LOCK(); + Status = SEGGER_RTT_WriteDownBufferNoLock(BufferIndex, pBuffer, NumBytes); // Call the non-locking write function + SEGGER_RTT_UNLOCK(); + return Status; +} + +/********************************************************************* +* +* SEGGER_RTT_Write +* +* Function description +* Stores a specified number of characters in SEGGER RTT +* control block which is then read by the host. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* +* Return value +* Number of bytes which have been stored in the "Up"-buffer. +* +* Notes +* (1) Data is stored according to buffer flags. +*/ +unsigned SEGGER_RTT_Write(unsigned BufferIndex, const void* pBuffer, unsigned NumBytes) { + unsigned Status; + + INIT(); + SEGGER_RTT_LOCK(); + Status = SEGGER_RTT_WriteNoLock(BufferIndex, pBuffer, NumBytes); // Call the non-locking write function + SEGGER_RTT_UNLOCK(); + return Status; +} + +/********************************************************************* +* +* SEGGER_RTT_WriteString +* +* Function description +* Stores string in SEGGER RTT control block. +* This data is read by the host. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* s Pointer to string. +* +* Return value +* Number of bytes which have been stored in the "Up"-buffer. +* +* Notes +* (1) Data is stored according to buffer flags. +* (2) String passed to this function has to be \0 terminated +* (3) \0 termination character is *not* stored in RTT buffer +*/ +unsigned SEGGER_RTT_WriteString(unsigned BufferIndex, const char* s) { + unsigned Len; + + Len = STRLEN(s); + return SEGGER_RTT_Write(BufferIndex, s, Len); +} + +/********************************************************************* +* +* SEGGER_RTT_PutCharSkipNoLock +* +* Function description +* Stores a single character/byte in SEGGER RTT buffer. +* SEGGER_RTT_PutCharSkipNoLock does not lock the application and +* skips the byte, if it does not fit into the buffer. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* c Byte to be stored. +* +* Return value +* Number of bytes which have been stored in the "Up"-buffer. +* +* Notes +* (1) If there is not enough space in the "Up"-buffer, the character is dropped. +* (2) For performance reasons this function does not call Init() +* and may only be called after RTT has been initialized. +* Either by calling SEGGER_RTT_Init() or calling another RTT API function first. +*/ + +unsigned SEGGER_RTT_PutCharSkipNoLock(unsigned BufferIndex, char c) { + SEGGER_RTT_BUFFER_UP* pRing; + unsigned WrOff; + unsigned Status; + volatile char* pDst; + // + // Get "to-host" ring buffer. + // + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + // + // Get write position and handle wrap-around if necessary + // + WrOff = pRing->WrOff + 1; + if (WrOff == pRing->SizeOfBuffer) { + WrOff = 0; + } + // + // Output byte if free space is available + // + if (WrOff != pRing->RdOff) { + pDst = (pRing->pBuffer + pRing->WrOff) + SEGGER_RTT_UNCACHED_OFF; + *pDst = c; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = WrOff; + Status = 1; + } else { + Status = 0; + } + // + return Status; +} + +/********************************************************************* +* +* SEGGER_RTT_PutCharSkip +* +* Function description +* Stores a single character/byte in SEGGER RTT buffer. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* c Byte to be stored. +* +* Return value +* Number of bytes which have been stored in the "Up"-buffer. +* +* Notes +* (1) If there is not enough space in the "Up"-buffer, the character is dropped. +*/ + +unsigned SEGGER_RTT_PutCharSkip(unsigned BufferIndex, char c) { + SEGGER_RTT_BUFFER_UP* pRing; + unsigned WrOff; + unsigned Status; + volatile char* pDst; + // + // Prepare + // + INIT(); + SEGGER_RTT_LOCK(); + // + // Get "to-host" ring buffer. + // + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + // + // Get write position and handle wrap-around if necessary + // + WrOff = pRing->WrOff + 1; + if (WrOff == pRing->SizeOfBuffer) { + WrOff = 0; + } + // + // Output byte if free space is available + // + if (WrOff != pRing->RdOff) { + pDst = (pRing->pBuffer + pRing->WrOff) + SEGGER_RTT_UNCACHED_OFF; + *pDst = c; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = WrOff; + Status = 1; + } else { + Status = 0; + } + // + // Finish up. + // + SEGGER_RTT_UNLOCK(); + // + return Status; +} + + /********************************************************************* +* +* SEGGER_RTT_PutChar +* +* Function description +* Stores a single character/byte in SEGGER RTT buffer. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* c Byte to be stored. +* +* Return value +* Number of bytes which have been stored in the "Up"-buffer. +* +* Notes +* (1) Data is stored according to buffer flags. +*/ + +unsigned SEGGER_RTT_PutChar(unsigned BufferIndex, char c) { + SEGGER_RTT_BUFFER_UP* pRing; + unsigned WrOff; + unsigned Status; + volatile char* pDst; + // + // Prepare + // + INIT(); + SEGGER_RTT_LOCK(); + // + // Get "to-host" ring buffer. + // + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + // + // Get write position and handle wrap-around if necessary + // + WrOff = pRing->WrOff + 1; + if (WrOff == pRing->SizeOfBuffer) { + WrOff = 0; + } + // + // Wait for free space if mode is set to blocking + // + if (pRing->Flags == SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL) { + while (WrOff == pRing->RdOff) { + ; + } + } + // + // Output byte if free space is available + // + if (WrOff != pRing->RdOff) { + pDst = (pRing->pBuffer + pRing->WrOff) + SEGGER_RTT_UNCACHED_OFF; + *pDst = c; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + pRing->WrOff = WrOff; + Status = 1; + } else { + Status = 0; + } + // + // Finish up. + // + SEGGER_RTT_UNLOCK(); + return Status; +} + +/********************************************************************* +* +* SEGGER_RTT_GetKey +* +* Function description +* Reads one character from the SEGGER RTT buffer. +* Host has previously stored data there. +* +* Return value +* < 0 - No character available (buffer empty). +* >= 0 - Character which has been read. (Possible values: 0 - 255) +* +* Notes +* (1) This function is only specified for accesses to RTT buffer 0. +*/ +int SEGGER_RTT_GetKey(void) { + char c; + int r; + + r = (int)SEGGER_RTT_Read(0u, &c, 1u); + if (r == 1) { + r = (int)(unsigned char)c; + } else { + r = -1; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_WaitKey +* +* Function description +* Waits until at least one character is avaible in the SEGGER RTT buffer. +* Once a character is available, it is read and this function returns. +* +* Return value +* >=0 - Character which has been read. +* +* Notes +* (1) This function is only specified for accesses to RTT buffer 0 +* (2) This function is blocking if no character is present in RTT buffer +*/ +int SEGGER_RTT_WaitKey(void) { + int r; + + do { + r = SEGGER_RTT_GetKey(); + } while (r < 0); + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_HasKey +* +* Function description +* Checks if at least one character for reading is available in the SEGGER RTT buffer. +* +* Return value +* == 0 - No characters are available to read. +* == 1 - At least one character is available. +* +* Notes +* (1) This function is only specified for accesses to RTT buffer 0 +*/ +int SEGGER_RTT_HasKey(void) { + SEGGER_RTT_BUFFER_DOWN* pRing; + unsigned RdOff; + int r; + + INIT(); + pRing = (SEGGER_RTT_BUFFER_DOWN*)((uintptr_t)&_SEGGER_RTT.aDown[0] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + RdOff = pRing->RdOff; + if (RdOff != pRing->WrOff) { + r = 1; + } else { + r = 0; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_HasData +* +* Function description +* Check if there is data from the host in the given buffer. +* +* Return value: +* ==0: No data +* !=0: Data in buffer +* +*/ +unsigned SEGGER_RTT_HasData(unsigned BufferIndex) { + SEGGER_RTT_BUFFER_DOWN* pRing; + unsigned v; + + pRing = (SEGGER_RTT_BUFFER_DOWN*)((uintptr_t)&_SEGGER_RTT.aDown[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + v = pRing->WrOff; + return v - pRing->RdOff; +} + +/********************************************************************* +* +* SEGGER_RTT_HasDataUp +* +* Function description +* Check if there is data remaining to be sent in the given buffer. +* +* Return value: +* ==0: No data +* !=0: Data in buffer +* +*/ +unsigned SEGGER_RTT_HasDataUp(unsigned BufferIndex) { + SEGGER_RTT_BUFFER_UP* pRing; + unsigned v; + + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + v = pRing->RdOff; + return pRing->WrOff - v; +} + +/********************************************************************* +* +* SEGGER_RTT_AllocDownBuffer +* +* Function description +* Run-time configuration of the next down-buffer (H->T). +* The next buffer, which is not used yet is configured. +* This includes: Buffer address, size, name, flags, ... +* +* Parameters +* sName Pointer to a constant name string. +* pBuffer Pointer to a buffer to be used. +* BufferSize Size of the buffer. +* Flags Operating modes. Define behavior if buffer is full (not enough space for entire message). +* Flags[31:24] are used for validity check and must be zero. Flags[23:2] are reserved for future use. Flags[1:0] = RTT operating mode. +* +* Return value +* >= 0 - O.K. Buffer Index +* < 0 - Error +*/ +int SEGGER_RTT_AllocDownBuffer(const char* sName, void* pBuffer, unsigned BufferSize, unsigned Flags) { + int BufferIndex; + volatile SEGGER_RTT_CB* pRTTCB; + + INIT(); + SEGGER_RTT_LOCK(); + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + BufferIndex = 0; + do { + if (pRTTCB->aDown[BufferIndex].pBuffer == NULL) { + break; + } + BufferIndex++; + } while (BufferIndex < pRTTCB->MaxNumDownBuffers); + if (BufferIndex < pRTTCB->MaxNumDownBuffers) { + pRTTCB->aDown[BufferIndex].sName = sName; + pRTTCB->aDown[BufferIndex].pBuffer = (char*)pBuffer; + pRTTCB->aDown[BufferIndex].SizeOfBuffer = BufferSize; + pRTTCB->aDown[BufferIndex].RdOff = 0u; + pRTTCB->aDown[BufferIndex].WrOff = 0u; + pRTTCB->aDown[BufferIndex].Flags = Flags; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + } else { + BufferIndex = -1; + } + SEGGER_RTT_UNLOCK(); + return BufferIndex; +} + +/********************************************************************* +* +* SEGGER_RTT_AllocUpBuffer +* +* Function description +* Run-time configuration of the next up-buffer (T->H). +* The next buffer, which is not used yet is configured. +* This includes: Buffer address, size, name, flags, ... +* +* Parameters +* sName Pointer to a constant name string. +* pBuffer Pointer to a buffer to be used. +* BufferSize Size of the buffer. +* Flags Operating modes. Define behavior if buffer is full (not enough space for entire message). +* Flags[31:24] are used for validity check and must be zero. Flags[23:2] are reserved for future use. Flags[1:0] = RTT operating mode. +* +* Return value +* >= 0 - O.K. Buffer Index +* < 0 - Error +*/ +int SEGGER_RTT_AllocUpBuffer(const char* sName, void* pBuffer, unsigned BufferSize, unsigned Flags) { + int BufferIndex; + volatile SEGGER_RTT_CB* pRTTCB; + + INIT(); + SEGGER_RTT_LOCK(); + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + BufferIndex = 0; + do { + if (pRTTCB->aUp[BufferIndex].pBuffer == NULL) { + break; + } + BufferIndex++; + } while (BufferIndex < pRTTCB->MaxNumUpBuffers); + if (BufferIndex < pRTTCB->MaxNumUpBuffers) { + pRTTCB->aUp[BufferIndex].sName = sName; + pRTTCB->aUp[BufferIndex].pBuffer = (char*)pBuffer; + pRTTCB->aUp[BufferIndex].SizeOfBuffer = BufferSize; + pRTTCB->aUp[BufferIndex].RdOff = 0u; + pRTTCB->aUp[BufferIndex].WrOff = 0u; + pRTTCB->aUp[BufferIndex].Flags = Flags; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + } else { + BufferIndex = -1; + } + SEGGER_RTT_UNLOCK(); + return BufferIndex; +} + +/********************************************************************* +* +* SEGGER_RTT_ConfigUpBuffer +* +* Function description +* Run-time configuration of a specific up-buffer (T->H). +* Buffer to be configured is specified by index. +* This includes: Buffer address, size, name, flags, ... +* +* Parameters +* BufferIndex Index of the buffer to configure. +* sName Pointer to a constant name string. +* pBuffer Pointer to a buffer to be used. +* BufferSize Size of the buffer. +* Flags Operating modes. Define behavior if buffer is full (not enough space for entire message). +* Flags[31:24] are used for validity check and must be zero. Flags[23:2] are reserved for future use. Flags[1:0] = RTT operating mode. +* +* Return value +* >= 0 - O.K. +* < 0 - Error +* +* Additional information +* Buffer 0 is configured on compile-time. +* May only be called once per buffer. +* Buffer name and flags can be reconfigured using the appropriate functions. +*/ +int SEGGER_RTT_ConfigUpBuffer(unsigned BufferIndex, const char* sName, void* pBuffer, unsigned BufferSize, unsigned Flags) { + int r; + volatile SEGGER_RTT_CB* pRTTCB; + volatile SEGGER_RTT_BUFFER_UP* pUp; + + INIT(); + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + if (BufferIndex < SEGGER_RTT_MAX_NUM_UP_BUFFERS) { + SEGGER_RTT_LOCK(); + pUp = &pRTTCB->aUp[BufferIndex]; + if (BufferIndex) { + pUp->sName = sName; + pUp->pBuffer = (char*)pBuffer; + pUp->SizeOfBuffer = BufferSize; + pUp->RdOff = 0u; + pUp->WrOff = 0u; + } + pUp->Flags = Flags; + SEGGER_RTT_UNLOCK(); + r = 0; + } else { + r = -1; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_ConfigDownBuffer +* +* Function description +* Run-time configuration of a specific down-buffer (H->T). +* Buffer to be configured is specified by index. +* This includes: Buffer address, size, name, flags, ... +* +* Parameters +* BufferIndex Index of the buffer to configure. +* sName Pointer to a constant name string. +* pBuffer Pointer to a buffer to be used. +* BufferSize Size of the buffer. +* Flags Operating modes. Define behavior if buffer is full (not enough space for entire message). +* Flags[31:24] are used for validity check and must be zero. Flags[23:2] are reserved for future use. Flags[1:0] = RTT operating mode. +* +* Return value +* >= 0 O.K. +* < 0 Error +* +* Additional information +* Buffer 0 is configured on compile-time. +* May only be called once per buffer. +* Buffer name and flags can be reconfigured using the appropriate functions. +*/ +int SEGGER_RTT_ConfigDownBuffer(unsigned BufferIndex, const char* sName, void* pBuffer, unsigned BufferSize, unsigned Flags) { + int r; + volatile SEGGER_RTT_CB* pRTTCB; + volatile SEGGER_RTT_BUFFER_DOWN* pDown; + + INIT(); + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + if (BufferIndex < SEGGER_RTT_MAX_NUM_DOWN_BUFFERS) { + SEGGER_RTT_LOCK(); + pDown = &pRTTCB->aDown[BufferIndex]; + if (BufferIndex) { + pDown->sName = sName; + pDown->pBuffer = (char*)pBuffer; + pDown->SizeOfBuffer = BufferSize; + pDown->RdOff = 0u; + pDown->WrOff = 0u; + } + pDown->Flags = Flags; + RTT__DMB(); // Force data write to be complete before writing the , in case CPU is allowed to change the order of memory accesses + SEGGER_RTT_UNLOCK(); + r = 0; + } else { + r = -1; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_SetNameUpBuffer +* +* Function description +* Run-time configuration of a specific up-buffer name (T->H). +* Buffer to be configured is specified by index. +* +* Parameters +* BufferIndex Index of the buffer to renamed. +* sName Pointer to a constant name string. +* +* Return value +* >= 0 O.K. +* < 0 Error +*/ +int SEGGER_RTT_SetNameUpBuffer(unsigned BufferIndex, const char* sName) { + int r; + volatile SEGGER_RTT_CB* pRTTCB; + volatile SEGGER_RTT_BUFFER_UP* pUp; + + INIT(); + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + if (BufferIndex < SEGGER_RTT_MAX_NUM_UP_BUFFERS) { + SEGGER_RTT_LOCK(); + pUp = &pRTTCB->aUp[BufferIndex]; + pUp->sName = sName; + SEGGER_RTT_UNLOCK(); + r = 0; + } else { + r = -1; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_SetNameDownBuffer +* +* Function description +* Run-time configuration of a specific Down-buffer name (T->H). +* Buffer to be configured is specified by index. +* +* Parameters +* BufferIndex Index of the buffer to renamed. +* sName Pointer to a constant name string. +* +* Return value +* >= 0 O.K. +* < 0 Error +*/ +int SEGGER_RTT_SetNameDownBuffer(unsigned BufferIndex, const char* sName) { + int r; + volatile SEGGER_RTT_CB* pRTTCB; + volatile SEGGER_RTT_BUFFER_DOWN* pDown; + + INIT(); + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + if (BufferIndex < SEGGER_RTT_MAX_NUM_DOWN_BUFFERS) { + SEGGER_RTT_LOCK(); + pDown = &pRTTCB->aDown[BufferIndex]; + pDown->sName = sName; + SEGGER_RTT_UNLOCK(); + r = 0; + } else { + r = -1; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_SetFlagsUpBuffer +* +* Function description +* Run-time configuration of specific up-buffer flags (T->H). +* Buffer to be configured is specified by index. +* +* Parameters +* BufferIndex Index of the buffer. +* Flags Flags to set for the buffer. +* Flags[31:24] are used for validity check and must be zero. Flags[23:2] are reserved for future use. Flags[1:0] = RTT operating mode. +* +* Return value +* >= 0 O.K. +* < 0 Error +*/ +int SEGGER_RTT_SetFlagsUpBuffer(unsigned BufferIndex, unsigned Flags) { + int r; + volatile SEGGER_RTT_CB* pRTTCB; + volatile SEGGER_RTT_BUFFER_UP* pUp; + + INIT(); + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + if (BufferIndex < SEGGER_RTT_MAX_NUM_UP_BUFFERS) { + SEGGER_RTT_LOCK(); + pUp = &pRTTCB->aUp[BufferIndex]; + pUp->Flags = Flags; + SEGGER_RTT_UNLOCK(); + r = 0; + } else { + r = -1; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_SetFlagsDownBuffer +* +* Function description +* Run-time configuration of specific Down-buffer flags (T->H). +* Buffer to be configured is specified by index. +* +* Parameters +* BufferIndex Index of the buffer to renamed. +* Flags Flags to set for the buffer. +* Flags[31:24] are used for validity check and must be zero. Flags[23:2] are reserved for future use. Flags[1:0] = RTT operating mode. +* +* Return value +* >= 0 O.K. +* < 0 Error +*/ +int SEGGER_RTT_SetFlagsDownBuffer(unsigned BufferIndex, unsigned Flags) { + int r; + volatile SEGGER_RTT_CB* pRTTCB; + volatile SEGGER_RTT_BUFFER_DOWN* pDown; + + INIT(); + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + if (BufferIndex < SEGGER_RTT_MAX_NUM_DOWN_BUFFERS) { + SEGGER_RTT_LOCK(); + pDown = &pRTTCB->aDown[BufferIndex]; + pDown->Flags = Flags; + SEGGER_RTT_UNLOCK(); + r = 0; + } else { + r = -1; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_Init +* +* Function description +* Initializes the RTT Control Block. +* Should be used in RAM targets, at start of the application. +* +*/ +void SEGGER_RTT_Init (void) { + _DoInit(); +} + +/********************************************************************* +* +* SEGGER_RTT_SetTerminal +* +* Function description +* Sets the terminal to be used for output on channel 0. +* +* Parameters +* TerminalId Index of the terminal. +* +* Return value +* >= 0 O.K. +* < 0 Error (e.g. if RTT is configured for non-blocking mode and there was no space in the buffer to set the new terminal Id) +* +* Notes +* (1) Buffer 0 is always reserved for terminal I/O, so we can use index 0 here, fixed +*/ +int SEGGER_RTT_SetTerminal (unsigned char TerminalId) { + unsigned char ac[2]; + SEGGER_RTT_BUFFER_UP* pRing; + unsigned Avail; + int r; + + INIT(); + r = 0; + ac[0] = 0xFFu; + if (TerminalId < sizeof(_aTerminalId)) { // We only support a certain number of channels + ac[1] = _aTerminalId[TerminalId]; + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[0] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + SEGGER_RTT_LOCK(); // Lock to make sure that no other task is writing into buffer, while we are and number of free bytes in buffer does not change downwards after checking and before writing + if ((pRing->Flags & SEGGER_RTT_MODE_MASK) == SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL) { + _ActiveTerminal = TerminalId; + _WriteBlocking(pRing, (const char*)ac, 2u); + } else { // Skipping mode or trim mode? => We cannot trim this command so handling is the same for both modes + Avail = _GetAvailWriteSpace(pRing); + if (Avail >= 2) { + _ActiveTerminal = TerminalId; // Only change active terminal in case of success + _WriteNoCheck(pRing, (const char*)ac, 2u); + } else { + r = -1; + } + } + SEGGER_RTT_UNLOCK(); + } else { + r = -1; + } + return r; +} + +/********************************************************************* +* +* SEGGER_RTT_TerminalOut +* +* Function description +* Writes a string to the given terminal +* without changing the terminal for channel 0. +* +* Parameters +* TerminalId Index of the terminal. +* s String to be printed on the terminal. +* +* Return value +* >= 0 - Number of bytes written. +* < 0 - Error. +* +*/ +int SEGGER_RTT_TerminalOut (unsigned char TerminalId, const char* s) { + int Status; + unsigned FragLen; + unsigned Avail; + SEGGER_RTT_BUFFER_UP* pRing; + // + INIT(); + // + // Validate terminal ID. + // + if (TerminalId < (char)sizeof(_aTerminalId)) { // We only support a certain number of channels + // + // Get "to-host" ring buffer. + // + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[0] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + // + // Need to be able to change terminal, write data, change back. + // Compute the fixed and variable sizes. + // + FragLen = STRLEN(s); + // + // How we output depends upon the mode... + // + SEGGER_RTT_LOCK(); + Avail = _GetAvailWriteSpace(pRing); + switch (pRing->Flags & SEGGER_RTT_MODE_MASK) { + case SEGGER_RTT_MODE_NO_BLOCK_SKIP: + // + // If we are in skip mode and there is no space for the whole + // of this output, don't bother switching terminals at all. + // + if (Avail < (FragLen + 4u)) { + Status = 0; + } else { + _PostTerminalSwitch(pRing, TerminalId); + Status = (int)_WriteBlocking(pRing, s, FragLen); + _PostTerminalSwitch(pRing, _ActiveTerminal); + } + break; + case SEGGER_RTT_MODE_NO_BLOCK_TRIM: + // + // If we are in trim mode and there is not enough space for everything, + // trim the output but always include the terminal switch. If no room + // for terminal switch, skip that totally. + // + if (Avail < 4u) { + Status = -1; + } else { + _PostTerminalSwitch(pRing, TerminalId); + Status = (int)_WriteBlocking(pRing, s, (FragLen < (Avail - 4u)) ? FragLen : (Avail - 4u)); + _PostTerminalSwitch(pRing, _ActiveTerminal); + } + break; + case SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL: + // + // If we are in blocking mode, output everything. + // + _PostTerminalSwitch(pRing, TerminalId); + Status = (int)_WriteBlocking(pRing, s, FragLen); + _PostTerminalSwitch(pRing, _ActiveTerminal); + break; + default: + Status = -1; + break; + } + // + // Finish up. + // + SEGGER_RTT_UNLOCK(); + } else { + Status = -1; + } + return Status; +} + +/********************************************************************* +* +* SEGGER_RTT_GetAvailWriteSpace +* +* Function description +* Returns the number of bytes available in the ring buffer. +* +* Parameters +* BufferIndex Index of the up buffer. +* +* Return value +* Number of bytes that are free in the selected up buffer. +*/ +unsigned SEGGER_RTT_GetAvailWriteSpace (unsigned BufferIndex) { + SEGGER_RTT_BUFFER_UP* pRing; + + pRing = (SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[BufferIndex] + SEGGER_RTT_UNCACHED_OFF); // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + return _GetAvailWriteSpace(pRing); +} + + +/********************************************************************* +* +* SEGGER_RTT_GetBytesInBuffer() +* +* Function description +* Returns the number of bytes currently used in the up buffer. +* +* Parameters +* BufferIndex Index of the up buffer. +* +* Return value +* Number of bytes that are used in the buffer. +*/ +unsigned SEGGER_RTT_GetBytesInBuffer(unsigned BufferIndex) { + unsigned RdOff; + unsigned WrOff; + unsigned r; + volatile SEGGER_RTT_CB* pRTTCB; + // + // Avoid warnings regarding volatile access order. It's not a problem + // in this case, but dampen compiler enthusiasm. + // + pRTTCB = (volatile SEGGER_RTT_CB*)((uintptr_t)&_SEGGER_RTT + SEGGER_RTT_UNCACHED_OFF); // Access RTTCB uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + RdOff = pRTTCB->aUp[BufferIndex].RdOff; + WrOff = pRTTCB->aUp[BufferIndex].WrOff; + if (RdOff <= WrOff) { + r = WrOff - RdOff; + } else { + r = pRTTCB->aUp[BufferIndex].SizeOfBuffer - (WrOff - RdOff); + } + return r; +} + +/*************************** End of file ****************************/ diff --git a/RTT/SEGGER_RTT.h b/RTT/SEGGER_RTT.h new file mode 100644 index 0000000..33e3c6c --- /dev/null +++ b/RTT/SEGGER_RTT.h @@ -0,0 +1,513 @@ +/********************************************************************* +* SEGGER Microcontroller GmbH * +* The Embedded Experts * +********************************************************************** +* * +* (c) 1995 - 2021 SEGGER Microcontroller GmbH * +* * +* www.segger.com Support: support@segger.com * +* * +********************************************************************** +* * +* SEGGER RTT * Real Time Transfer for embedded targets * +* * +********************************************************************** +* * +* All rights reserved. * +* * +* SEGGER strongly recommends to not make any changes * +* to or modify the source code of this software in order to stay * +* compatible with the RTT protocol and J-Link. * +* * +* Redistribution and use in source and binary forms, with or * +* without modification, are permitted provided that the following * +* condition is met: * +* * +* o Redistributions of source code must retain the above copyright * +* notice, this condition and the following disclaimer. * +* * +* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND * +* CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, * +* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * +* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * +* DISCLAIMED. IN NO EVENT SHALL SEGGER Microcontroller BE LIABLE FOR * +* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT * +* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; * +* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * +* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * +* USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * +* DAMAGE. * +* * +********************************************************************** +* * +* RTT version: 8.10g * +* * +********************************************************************** + +---------------------------END-OF-HEADER------------------------------ +File : SEGGER_RTT.h +Purpose : Implementation of SEGGER real-time transfer which allows + real-time communication on targets which support debugger + memory accesses while the CPU is running. +Revision: $Rev: 25842 $ +---------------------------------------------------------------------- +*/ + +#ifndef SEGGER_RTT_H +#define SEGGER_RTT_H + +#include "SEGGER_RTT_Conf.h" + +/********************************************************************* +* +* Defines, defaults +* +********************************************************************** +*/ + +#ifndef RTT_USE_ASM + // + // Some cores support out-of-order memory accesses (reordering of memory accesses in the core) + // For such cores, we need to define a memory barrier to guarantee the order of certain accesses to the RTT ring buffers. + // Needed for: + // Cortex-M7 (ARMv7-M) + // Cortex-M23 (ARM-v8M) + // Cortex-M33 (ARM-v8M) + // Cortex-A/R (ARM-v7A/R) + // + // We do not explicitly check for "Embedded Studio" as the compiler in use determines what we support. + // You can use an external toolchain like IAR inside ES. So there is no point in checking for "Embedded Studio" + // + #if (defined __CROSSWORKS_ARM) // Rowley Crossworks + #define _CC_HAS_RTT_ASM_SUPPORT 1 + #if (defined __ARM_ARCH_7M__) // Cortex-M3 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #elif (defined __ARM_ARCH_7EM__) // Cortex-M4/M7 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined __ARM_ARCH_8M_BASE__) // Cortex-M23 + #define _CORE_HAS_RTT_ASM_SUPPORT 0 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined __ARM_ARCH_8M_MAIN__) // Cortex-M33 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined(__ARM_ARCH_8_1M_MAIN__)) // Cortex-M85 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #else + #define _CORE_HAS_RTT_ASM_SUPPORT 0 + #endif + #elif (defined __ARMCC_VERSION) + // + // ARM compiler + // ARM compiler V6.0 and later is clang based. + // Our ASM part is compatible to clang. + // + #if (__ARMCC_VERSION >= 6000000) + #define _CC_HAS_RTT_ASM_SUPPORT 1 + #else + #define _CC_HAS_RTT_ASM_SUPPORT 0 + #endif + #if (defined __ARM_ARCH_6M__) // Cortex-M0 / M1 + #define _CORE_HAS_RTT_ASM_SUPPORT 0 // No ASM support for this architecture + #elif (defined __ARM_ARCH_7M__) // Cortex-M3 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #elif (defined __ARM_ARCH_7EM__) // Cortex-M4/M7 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined __ARM_ARCH_8M_BASE__) // Cortex-M23 + #define _CORE_HAS_RTT_ASM_SUPPORT 0 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined __ARM_ARCH_8M_MAIN__) // Cortex-M33 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined __ARM_ARCH_8_1M_MAIN__) // Cortex-M85 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif ((defined __ARM_ARCH_7A__) || (defined __ARM_ARCH_7R__)) // Cortex-A/R 32-bit ARMv7-A/R + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #else + #define _CORE_HAS_RTT_ASM_SUPPORT 0 + #endif + #elif ((defined __GNUC__) || (defined __clang__)) + // + // GCC / Clang + // + #define _CC_HAS_RTT_ASM_SUPPORT 1 + // ARM 7/9: __ARM_ARCH_5__ / __ARM_ARCH_5E__ / __ARM_ARCH_5T__ / __ARM_ARCH_5T__ / __ARM_ARCH_5TE__ + #if (defined __ARM_ARCH_7M__) // Cortex-M3 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #elif (defined __ARM_ARCH_7EM__) // Cortex-M4/M7 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 // Only Cortex-M7 needs a DMB but we cannot distinguish M4 and M7 here... + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined __ARM_ARCH_8M_BASE__) // Cortex-M23 + #define _CORE_HAS_RTT_ASM_SUPPORT 0 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined __ARM_ARCH_8M_MAIN__) // Cortex-M33 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif (defined __ARM_ARCH_8_1M_MAIN__) // Cortex-M85 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #elif ((defined __ARM_ARCH_7A__) || (defined __ARM_ARCH_7R__)) // Cortex-A/R 32-bit ARMv7-A/R + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() __asm volatile ("dmb\n" : : :); + #else + #define _CORE_HAS_RTT_ASM_SUPPORT 0 + #endif + #elif ((defined __IASMARM__) || (defined __ICCARM__)) + // + // IAR assembler/compiler + // + #define _CC_HAS_RTT_ASM_SUPPORT 1 + #if (__VER__ < 6300000) + #define VOLATILE + #else + #define VOLATILE volatile + #endif + #if (defined __ARM7M__) // Needed for old versions that do not know the define yet + #if (__CORE__ == __ARM7M__) // Cortex-M3 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #endif + #endif + #if (defined __ARM7EM__) + #if (__CORE__ == __ARM7EM__) // Cortex-M4/M7 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() asm VOLATILE ("DMB"); + #endif + #endif + #if (defined __ARM8M_BASELINE__) + #if (__CORE__ == __ARM8M_BASELINE__) // Cortex-M23 + #define _CORE_HAS_RTT_ASM_SUPPORT 0 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() asm VOLATILE ("DMB"); + #endif + #endif + #if (defined __ARM8M_MAINLINE__) + #if (__CORE__ == __ARM8M_MAINLINE__) // Cortex-M33 + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() asm VOLATILE ("DMB"); + #endif + #endif + #if (defined __ARM8EM_MAINLINE__) + #if (__CORE__ == __ARM8EM_MAINLINE__) // Cortex-??? + #define _CORE_HAS_RTT_ASM_SUPPORT 1 + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() asm VOLATILE ("DMB"); + #endif + #endif + #if (defined __ARM7A__) + #if (__CORE__ == __ARM7A__) // Cortex-A 32-bit ARMv7-A + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() asm VOLATILE ("DMB"); + #endif + #endif + #if (defined __ARM7R__) + #if (__CORE__ == __ARM7R__) // Cortex-R 32-bit ARMv7-R + #define _CORE_NEEDS_DMB 1 + #define RTT__DMB() asm VOLATILE ("DMB"); + #endif + #endif +// TBD: __ARM8A__ => Cortex-A 64-bit ARMv8-A +// TBD: __ARM8R__ => Cortex-R 64-bit ARMv8-R + #else + // + // Other compilers + // + #define _CC_HAS_RTT_ASM_SUPPORT 0 + #define _CORE_HAS_RTT_ASM_SUPPORT 0 + #endif + // + // If IDE and core support the ASM version, enable ASM version by default + // + #ifndef _CORE_HAS_RTT_ASM_SUPPORT + #define _CORE_HAS_RTT_ASM_SUPPORT 0 // Default for unknown cores + #endif + #if (_CC_HAS_RTT_ASM_SUPPORT && _CORE_HAS_RTT_ASM_SUPPORT) + #define RTT_USE_ASM (1) + #else + #define RTT_USE_ASM (0) + #endif +#endif + +#ifndef _CORE_NEEDS_DMB + #define _CORE_NEEDS_DMB 0 +#endif + +#ifndef RTT__DMB + #if _CORE_NEEDS_DMB + #error "Don't know how to place inline assembly for DMB" + #else + #define RTT__DMB() + #endif +#endif + +#ifndef SEGGER_RTT_CPU_CACHE_LINE_SIZE + #define SEGGER_RTT_CPU_CACHE_LINE_SIZE (0) // On most target systems where RTT is used, we do not have a CPU cache, therefore 0 is a good default here +#endif + +#ifndef SEGGER_RTT_UNCACHED_OFF + #if SEGGER_RTT_CPU_CACHE_LINE_SIZE + #error "SEGGER_RTT_UNCACHED_OFF must be defined when setting SEGGER_RTT_CPU_CACHE_LINE_SIZE != 0" + #else + #define SEGGER_RTT_UNCACHED_OFF (0) + #endif +#endif +#if RTT_USE_ASM + #if SEGGER_RTT_CPU_CACHE_LINE_SIZE + #error "RTT_USE_ASM is not available if SEGGER_RTT_CPU_CACHE_LINE_SIZE != 0" + #endif +#endif + +#ifndef SEGGER_RTT_ASM // defined when SEGGER_RTT.h is included from assembly file +#include +#include +#include + +/********************************************************************* +* +* Defines, fixed +* +********************************************************************** +*/ + +// +// Determine how much we must pad the control block to make it a multiple of a cache line in size +// Assuming: U8 = 1B +// U16 = 2B +// U32 = 4B +// U8/U16/U32* = 4B +// +#if SEGGER_RTT_CPU_CACHE_LINE_SIZE // Avoid division by zero in case we do not have any cache + #define SEGGER_RTT__ROUND_UP_2_CACHE_LINE_SIZE(NumBytes) (((NumBytes + SEGGER_RTT_CPU_CACHE_LINE_SIZE - 1) / SEGGER_RTT_CPU_CACHE_LINE_SIZE) * SEGGER_RTT_CPU_CACHE_LINE_SIZE) +#else + #define SEGGER_RTT__ROUND_UP_2_CACHE_LINE_SIZE(NumBytes) (NumBytes) +#endif +#define SEGGER_RTT__CB_SIZE (16 + 4 + 4 + (SEGGER_RTT_MAX_NUM_UP_BUFFERS * 24) + (SEGGER_RTT_MAX_NUM_DOWN_BUFFERS * 24)) +#define SEGGER_RTT__CB_PADDING (SEGGER_RTT__ROUND_UP_2_CACHE_LINE_SIZE(SEGGER_RTT__CB_SIZE) - SEGGER_RTT__CB_SIZE) + +/********************************************************************* +* +* Types +* +********************************************************************** +*/ + +// +// Description for a circular buffer (also called "ring buffer") +// which is used as up-buffer (T->H) +// +typedef struct { + const char* sName; // Optional name. Standard names so far are: "Terminal", "SysView", "J-Scope_t4i4" + char* pBuffer; // Pointer to start of buffer + unsigned SizeOfBuffer; // Buffer size in bytes. Note that one byte is lost, as this implementation does not fill up the buffer in order to avoid the problem of being unable to distinguish between full and empty. + unsigned WrOff; // Position of next item to be written by either target. + volatile unsigned RdOff; // Position of next item to be read by host. Must be volatile since it may be modified by host. + unsigned Flags; // Contains configuration flags. Flags[31:24] are used for validity check and must be zero. Flags[23:2] are reserved for future use. Flags[1:0] = RTT operating mode. +} SEGGER_RTT_BUFFER_UP; + +// +// Description for a circular buffer (also called "ring buffer") +// which is used as down-buffer (H->T) +// +typedef struct { + const char* sName; // Optional name. Standard names so far are: "Terminal", "SysView", "J-Scope_t4i4" + char* pBuffer; // Pointer to start of buffer + unsigned SizeOfBuffer; // Buffer size in bytes. Note that one byte is lost, as this implementation does not fill up the buffer in order to avoid the problem of being unable to distinguish between full and empty. + volatile unsigned WrOff; // Position of next item to be written by host. Must be volatile since it may be modified by host. + unsigned RdOff; // Position of next item to be read by target (down-buffer). + unsigned Flags; // Contains configuration flags. Flags[31:24] are used for validity check and must be zero. Flags[23:2] are reserved for future use. Flags[1:0] = RTT operating mode. +} SEGGER_RTT_BUFFER_DOWN; + +// +// RTT control block which describes the number of buffers available +// as well as the configuration for each buffer +// +// +typedef struct { + char acID[16]; // Initialized to "SEGGER RTT" + int MaxNumUpBuffers; // Initialized to SEGGER_RTT_MAX_NUM_UP_BUFFERS (type. 2) + int MaxNumDownBuffers; // Initialized to SEGGER_RTT_MAX_NUM_DOWN_BUFFERS (type. 2) + SEGGER_RTT_BUFFER_UP aUp[SEGGER_RTT_MAX_NUM_UP_BUFFERS]; // Up buffers, transferring information up from target via debug probe to host + SEGGER_RTT_BUFFER_DOWN aDown[SEGGER_RTT_MAX_NUM_DOWN_BUFFERS]; // Down buffers, transferring information down from host via debug probe to target +#if SEGGER_RTT__CB_PADDING + unsigned char aDummy[SEGGER_RTT__CB_PADDING]; +#endif +} SEGGER_RTT_CB; + +/********************************************************************* +* +* Global data +* +********************************************************************** +*/ +extern SEGGER_RTT_CB _SEGGER_RTT; + +/********************************************************************* +* +* RTT API functions +* +********************************************************************** +*/ +#ifdef __cplusplus + extern "C" { +#endif +int SEGGER_RTT_AllocDownBuffer (const char* sName, void* pBuffer, unsigned BufferSize, unsigned Flags); +int SEGGER_RTT_AllocUpBuffer (const char* sName, void* pBuffer, unsigned BufferSize, unsigned Flags); +int SEGGER_RTT_ConfigUpBuffer (unsigned BufferIndex, const char* sName, void* pBuffer, unsigned BufferSize, unsigned Flags); +int SEGGER_RTT_ConfigDownBuffer (unsigned BufferIndex, const char* sName, void* pBuffer, unsigned BufferSize, unsigned Flags); +int SEGGER_RTT_GetKey (void); +unsigned SEGGER_RTT_HasData (unsigned BufferIndex); +int SEGGER_RTT_HasKey (void); +unsigned SEGGER_RTT_HasDataUp (unsigned BufferIndex); +void SEGGER_RTT_Init (void); +unsigned SEGGER_RTT_Read (unsigned BufferIndex, void* pBuffer, unsigned BufferSize); +unsigned SEGGER_RTT_ReadNoLock (unsigned BufferIndex, void* pData, unsigned BufferSize); +int SEGGER_RTT_SetNameDownBuffer (unsigned BufferIndex, const char* sName); +int SEGGER_RTT_SetNameUpBuffer (unsigned BufferIndex, const char* sName); +int SEGGER_RTT_SetFlagsDownBuffer (unsigned BufferIndex, unsigned Flags); +int SEGGER_RTT_SetFlagsUpBuffer (unsigned BufferIndex, unsigned Flags); +int SEGGER_RTT_WaitKey (void); +unsigned SEGGER_RTT_Write (unsigned BufferIndex, const void* pBuffer, unsigned NumBytes); +unsigned SEGGER_RTT_WriteNoLock (unsigned BufferIndex, const void* pBuffer, unsigned NumBytes); +unsigned SEGGER_RTT_WriteSkipNoLock (unsigned BufferIndex, const void* pBuffer, unsigned NumBytes); +unsigned SEGGER_RTT_ASM_WriteSkipNoLock (unsigned BufferIndex, const void* pBuffer, unsigned NumBytes); +unsigned SEGGER_RTT_WriteString (unsigned BufferIndex, const char* s); +void SEGGER_RTT_WriteWithOverwriteNoLock(unsigned BufferIndex, const void* pBuffer, unsigned NumBytes); +unsigned SEGGER_RTT_PutChar (unsigned BufferIndex, char c); +unsigned SEGGER_RTT_PutCharSkip (unsigned BufferIndex, char c); +unsigned SEGGER_RTT_PutCharSkipNoLock (unsigned BufferIndex, char c); +unsigned SEGGER_RTT_GetAvailWriteSpace (unsigned BufferIndex); +unsigned SEGGER_RTT_GetBytesInBuffer (unsigned BufferIndex); +// +// Function macro for performance optimization +// +#define SEGGER_RTT_HASDATA(n) (((SEGGER_RTT_BUFFER_DOWN*)((uintptr_t)&_SEGGER_RTT.aDown[n] + SEGGER_RTT_UNCACHED_OFF))->WrOff - ((SEGGER_RTT_BUFFER_DOWN*)((uintptr_t)&_SEGGER_RTT.aDown[n] + SEGGER_RTT_UNCACHED_OFF))->RdOff) + +#if RTT_USE_ASM + #define SEGGER_RTT_WriteSkipNoLock SEGGER_RTT_ASM_WriteSkipNoLock +#endif + +/********************************************************************* +* +* RTT transfer functions to send RTT data via other channels. +* +********************************************************************** +*/ +unsigned SEGGER_RTT_ReadUpBuffer (unsigned BufferIndex, void* pBuffer, unsigned BufferSize); +unsigned SEGGER_RTT_ReadUpBufferNoLock (unsigned BufferIndex, void* pData, unsigned BufferSize); +unsigned SEGGER_RTT_WriteDownBuffer (unsigned BufferIndex, const void* pBuffer, unsigned NumBytes); +unsigned SEGGER_RTT_WriteDownBufferNoLock (unsigned BufferIndex, const void* pBuffer, unsigned NumBytes); + +#define SEGGER_RTT_HASDATA_UP(n) (((SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[n] + SEGGER_RTT_UNCACHED_OFF))->WrOff - ((SEGGER_RTT_BUFFER_UP*)((uintptr_t)&_SEGGER_RTT.aUp[n] + SEGGER_RTT_UNCACHED_OFF))->RdOff) // Access uncached to make sure we see changes made by the J-Link side and all of our changes go into HW directly + +/********************************************************************* +* +* RTT "Terminal" API functions +* +********************************************************************** +*/ +int SEGGER_RTT_SetTerminal (unsigned char TerminalId); +int SEGGER_RTT_TerminalOut (unsigned char TerminalId, const char* s); + +/********************************************************************* +* +* RTT printf functions (require SEGGER_RTT_printf.c) +* +********************************************************************** +*/ +int SEGGER_RTT_printf(unsigned BufferIndex, const char * sFormat, ...); +int SEGGER_RTT_vprintf(unsigned BufferIndex, const char * sFormat, va_list * pParamList); + +#ifdef __cplusplus + } +#endif + +#endif // ifndef(SEGGER_RTT_ASM) + +// +// For some environments, NULL may not be defined until certain headers are included +// +#ifndef NULL + #define NULL ((void*)0) +#endif + +/********************************************************************* +* +* Defines +* +********************************************************************** +*/ + +// +// Operating modes. Define behavior if buffer is full (not enough space for entire message) +// +#define SEGGER_RTT_MODE_NO_BLOCK_SKIP (0) // Skip. Do not block, output nothing. (Default) +#define SEGGER_RTT_MODE_NO_BLOCK_TRIM (1) // Trim: Do not block, output as much as fits. +#define SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL (2) // Block: Wait until there is space in the buffer. +#define SEGGER_RTT_MODE_MASK (3) + +// +// Control sequences, based on ANSI. +// Can be used to control color, and clear the screen +// +#define RTT_CTRL_RESET "\x1B[0m" // Reset to default colors +#define RTT_CTRL_CLEAR "\x1B[2J" // Clear screen, reposition cursor to top left + +#define RTT_CTRL_TEXT_BLACK "\x1B[2;30m" +#define RTT_CTRL_TEXT_RED "\x1B[2;31m" +#define RTT_CTRL_TEXT_GREEN "\x1B[2;32m" +#define RTT_CTRL_TEXT_YELLOW "\x1B[2;33m" +#define RTT_CTRL_TEXT_BLUE "\x1B[2;34m" +#define RTT_CTRL_TEXT_MAGENTA "\x1B[2;35m" +#define RTT_CTRL_TEXT_CYAN "\x1B[2;36m" +#define RTT_CTRL_TEXT_WHITE "\x1B[2;37m" + +#define RTT_CTRL_TEXT_BRIGHT_BLACK "\x1B[1;30m" +#define RTT_CTRL_TEXT_BRIGHT_RED "\x1B[1;31m" +#define RTT_CTRL_TEXT_BRIGHT_GREEN "\x1B[1;32m" +#define RTT_CTRL_TEXT_BRIGHT_YELLOW "\x1B[1;33m" +#define RTT_CTRL_TEXT_BRIGHT_BLUE "\x1B[1;34m" +#define RTT_CTRL_TEXT_BRIGHT_MAGENTA "\x1B[1;35m" +#define RTT_CTRL_TEXT_BRIGHT_CYAN "\x1B[1;36m" +#define RTT_CTRL_TEXT_BRIGHT_WHITE "\x1B[1;37m" + +#define RTT_CTRL_BG_BLACK "\x1B[24;40m" +#define RTT_CTRL_BG_RED "\x1B[24;41m" +#define RTT_CTRL_BG_GREEN "\x1B[24;42m" +#define RTT_CTRL_BG_YELLOW "\x1B[24;43m" +#define RTT_CTRL_BG_BLUE "\x1B[24;44m" +#define RTT_CTRL_BG_MAGENTA "\x1B[24;45m" +#define RTT_CTRL_BG_CYAN "\x1B[24;46m" +#define RTT_CTRL_BG_WHITE "\x1B[24;47m" + +#define RTT_CTRL_BG_BRIGHT_BLACK "\x1B[4;40m" +#define RTT_CTRL_BG_BRIGHT_RED "\x1B[4;41m" +#define RTT_CTRL_BG_BRIGHT_GREEN "\x1B[4;42m" +#define RTT_CTRL_BG_BRIGHT_YELLOW "\x1B[4;43m" +#define RTT_CTRL_BG_BRIGHT_BLUE "\x1B[4;44m" +#define RTT_CTRL_BG_BRIGHT_MAGENTA "\x1B[4;45m" +#define RTT_CTRL_BG_BRIGHT_CYAN "\x1B[4;46m" +#define RTT_CTRL_BG_BRIGHT_WHITE "\x1B[4;47m" + + +#endif + +/*************************** End of file ****************************/ diff --git a/RTT/SEGGER_RTT_ASM_ARMv7M.S b/RTT/SEGGER_RTT_ASM_ARMv7M.S new file mode 100644 index 0000000..cbbc52f --- /dev/null +++ b/RTT/SEGGER_RTT_ASM_ARMv7M.S @@ -0,0 +1,242 @@ +/********************************************************************* +* (c) SEGGER Microcontroller GmbH * +* The Embedded Experts * +* www.segger.com * +********************************************************************** + +-------------------------- END-OF-HEADER ----------------------------- + +File : SEGGER_RTT_ASM_ARMv7M.S +Purpose : Assembler implementation of RTT functions for ARMv7M + +Additional information: + This module is written to be assembler-independent and works with + GCC and clang (Embedded Studio) and IAR. +*/ + +#define SEGGER_RTT_ASM // Used to control processed input from header file +#include "SEGGER_RTT.h" + +/********************************************************************* +* +* Defines, fixed +* +********************************************************************** +*/ + +#define _CCIAR 0 +#define _CCCLANG 1 + +#if (defined __SES_ARM) || (defined __GNUC__) || (defined __clang__) + #define _CC_TYPE _CCCLANG + #define _PUB_SYM .global + #define _EXT_SYM .extern + #define _END .end + #define _WEAK .weak + #define _THUMB_FUNC .thumb_func + #define _THUMB_CODE .code 16 + #define _WORD .word + #define _SECTION(Sect, Type, AlignExp) .section Sect ##, "ax" + #define _ALIGN(Exp) .align Exp + #define _PLACE_LITS .ltorg + #define _DATA_SECT_START + #define _C_STARTUP _start + #define _STACK_END __stack_end__ + #define _RAMFUNC + // + // .text => Link to flash + // .fast => Link to RAM + // OtherSect => Usually link to RAM + // Alignment is 2^x + // +#elif defined (__IASMARM__) + #define _CC_TYPE _CCIAR + #define _PUB_SYM PUBLIC + #define _EXT_SYM EXTERN + #define _END END + #define _WEAK _WEAK + #define _THUMB_FUNC + #define _THUMB_CODE THUMB + #define _WORD DCD + #define _SECTION(Sect, Type, AlignExp) SECTION Sect ## : ## Type ## :REORDER:NOROOT ## (AlignExp) + #define _ALIGN(Exp) alignrom Exp + #define _PLACE_LITS + #define _DATA_SECT_START DATA + #define _C_STARTUP __iar_program_start + #define _STACK_END sfe(CSTACK) + #define _RAMFUNC SECTION_TYPE SHT_PROGBITS, SHF_WRITE | SHF_EXECINSTR + // + // .text => Link to flash + // .textrw => Link to RAM + // OtherSect => Usually link to RAM + // NOROOT => Allows linker to throw away the function, if not referenced + // Alignment is 2^x + // +#endif + +#if (_CC_TYPE == _CCIAR) + NAME SEGGER_RTT_ASM_ARMv7M +#else + .syntax unified +#endif + +#if defined (RTT_USE_ASM) && (RTT_USE_ASM == 1) + #define SHT_PROGBITS 0x1 + +/********************************************************************* +* +* Public / external symbols +* +********************************************************************** +*/ + + _EXT_SYM __aeabi_memcpy + _EXT_SYM __aeabi_memcpy4 + _EXT_SYM _SEGGER_RTT + + _PUB_SYM SEGGER_RTT_ASM_WriteSkipNoLock + +/********************************************************************* +* +* SEGGER_RTT_WriteSkipNoLock +* +* Function description +* Stores a specified number of characters in SEGGER RTT +* control block which is then read by the host. +* SEGGER_RTT_WriteSkipNoLock does not lock the application and +* skips all data, if the data does not fit into the buffer. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used (e.g. 0 for "Terminal"). +* pBuffer Pointer to character array. Does not need to point to a \0 terminated string. +* NumBytes Number of bytes to be stored in the SEGGER RTT control block. +* MUST be > 0!!! +* This is done for performance reasons, so no initial check has do be done. +* +* Return value +* 1: Data has been copied +* 0: No space, data has not been copied +* +* Notes +* (1) If there is not enough space in the "Up"-buffer, all data is dropped. +* (2) For performance reasons this function does not call Init() +* and may only be called after RTT has been initialized. +* Either by calling SEGGER_RTT_Init() or calling another RTT API function first. +*/ + _SECTION(.text, CODE, 2) + _ALIGN(2) + _THUMB_FUNC +SEGGER_RTT_ASM_WriteSkipNoLock: // unsigned SEGGER_RTT_WriteSkipNoLock(unsigned BufferIndex, const void* pData, unsigned NumBytes) { + // + // Cases: + // 1) RdOff <= WrOff => Space until wrap-around is sufficient + // 2) RdOff <= WrOff => Space after wrap-around needed (copy in 2 chunks) + // 3) RdOff < WrOff => No space in buf + // 4) RdOff > WrOff => Space is sufficient + // 5) RdOff > WrOff => No space in buf + // + // 1) is the most common case for large buffers and assuming that J-Link reads the data fast enough + // + // Register usage: + // R0 Temporary needed as RdOff, register later on + // R1 pData + // R2 + // R3 register. Hold free for subroutine calls + // R4 + // R5 pRing->pBuffer + // R6 pRing (Points to active struct SEGGER_RTT_BUFFER_DOWN) + // R7 WrOff + // + PUSH {R4-R7} + ADD R3,R0,R0, LSL #+1 + LDR.W R0,=_SEGGER_RTT // pRing = &_SEGGER_RTT.aUp[BufferIndex]; + ADD R0,R0,R3, LSL #+3 + ADD R6,R0,#+24 + LDR R0,[R6, #+16] // RdOff = pRing->RdOff; + LDR R7,[R6, #+12] // WrOff = pRing->WrOff; + LDR R5,[R6, #+4] // pRing->pBuffer + CMP R7,R0 + BCC.N _CheckCase4 // if (RdOff <= WrOff) { => Case 1), 2) or 3) + // + // Handling for case 1, later on identical to case 4 + // + LDR R3,[R6, #+8] // Avail = pRing->SizeOfBuffer - WrOff - 1u; => Space until wrap-around (assume 1 byte not usable for case that RdOff == 0) + SUBS R4,R3,R7 // (Used in case we jump into case 2 afterwards) + SUBS R3,R4,#+1 // + CMP R3,R2 + BCC.N _CheckCase2 // if (Avail >= NumBytes) { => Case 1)? +_Case4: + ADDS R5,R7,R5 // pBuffer += WrOff + ADDS R0,R2,R7 // v = WrOff + NumBytes + // + // 2x unrolling for the copy loop that is used most of the time + // This is a special optimization for small SystemView packets and makes them even faster + // + _ALIGN(2) +_LoopCopyStraight: // memcpy(pRing->pBuffer + WrOff, pData, NumBytes); + LDRB R3,[R1], #+1 + STRB R3,[R5], #+1 // *pDest++ = *pSrc++ + SUBS R2,R2,#+1 + BEQ _CSDone + LDRB R3,[R1], #+1 + STRB R3,[R5], #+1 // *pDest++ = *pSrc++ + SUBS R2,R2,#+1 + BNE _LoopCopyStraight +_CSDone: +#if _CORE_NEEDS_DMB // Do not slow down cores that do not need a DMB instruction here + DMB // Cortex-M7 may delay memory writes and also change the order in which the writes happen. Therefore, make sure that all buffer writes are finished, before updating the in the struct +#endif + STR R0,[R6, #+12] // pRing->WrOff = WrOff + NumBytes; + MOVS R0,#+1 + POP {R4-R7} + BX LR // Return 1 +_CheckCase2: + ADDS R0,R0,R3 // Avail += RdOff; => Space incl. wrap-around + CMP R0,R2 + BCC.N _Case3 // if (Avail >= NumBytes) { => Case 2? => If not, we have case 3) (does not fit) + // + // Handling for case 2 + // + ADDS R0,R7,R5 // v = pRing->pBuffer + WrOff => Do not change pRing->pBuffer here because 2nd chunk needs org. value + SUBS R2,R2,R4 // NumBytes -= Rem; (Rem = pRing->SizeOfBuffer - WrOff; => Space until end of buffer) +_LoopCopyBeforeWrapAround: // memcpy(pRing->pBuffer + WrOff, pData, Rem); => Copy 1st chunk + LDRB R3,[R1], #+1 + STRB R3,[R0], #+1 // *pDest++ = *pSrc++ + SUBS R4,R4,#+1 + BNE _LoopCopyBeforeWrapAround + // + // Special case: First check that assumed RdOff == 0 calculated that last element before wrap-around could not be used + // But 2nd check (considering space until wrap-around and until RdOff) revealed that RdOff is not 0, so we can use the last element + // In this case, we may use a copy straight until buffer end anyway without needing to copy 2 chunks + // Therefore, check if 2nd memcpy is necessary at all + // + ADDS R4,R2,#+0 // Save (needed as counter in loop but must be written to after the loop). Also use this inst to update the flags to skip 2nd loop if possible + BEQ.N _No2ChunkNeeded // if (NumBytes) { +_LoopCopyAfterWrapAround: // memcpy(pRing->pBuffer, pData + Rem, NumBytes); + LDRB R3,[R1], #+1 // pData already points to the next src byte due to copy loop increment before this loop + STRB R3,[R5], #+1 // *pDest++ = *pSrc++ + SUBS R2,R2,#+1 + BNE _LoopCopyAfterWrapAround +_No2ChunkNeeded: +#if _CORE_NEEDS_DMB // Do not slow down cores that do not need a DMB instruction here + DMB // Cortex-M7 may delay memory writes and also change the order in which the writes happen. Therefore, make sure that all buffer writes are finished, before updating the in the struct +#endif + STR R4,[R6, #+12] // pRing->WrOff = NumBytes; => Must be written after copying data because J-Link may read control block asynchronously while writing into buffer + MOVS R0,#+1 + POP {R4-R7} + BX LR // Return 1 +_CheckCase4: + SUBS R0,R0,R7 + SUBS R0,R0,#+1 // Avail = RdOff - WrOff - 1u; + CMP R0,R2 + BCS.N _Case4 // if (Avail >= NumBytes) { => Case 4) == 1) ? => If not, we have case 5) == 3) (does not fit) +_Case3: + MOVS R0,#+0 + POP {R4-R7} + BX LR // Return 0 + _PLACE_LITS + +#endif // defined (RTT_USE_ASM) && (RTT_USE_ASM == 1) + _END + +/*************************** End of file ****************************/ diff --git a/RTT/SEGGER_RTT_Conf.h b/RTT/SEGGER_RTT_Conf.h new file mode 100644 index 0000000..e386e8b --- /dev/null +++ b/RTT/SEGGER_RTT_Conf.h @@ -0,0 +1,429 @@ +/********************************************************************* +* SEGGER Microcontroller GmbH * +* The Embedded Experts * +********************************************************************** +* * +* (c) 1995 - 2021 SEGGER Microcontroller GmbH * +* * +* www.segger.com Support: support@segger.com * +* * +********************************************************************** +* * +* SEGGER RTT * Real Time Transfer for embedded targets * +* * +********************************************************************** +* * +* All rights reserved. * +* * +* SEGGER strongly recommends to not make any changes * +* to or modify the source code of this software in order to stay * +* compatible with the RTT protocol and J-Link. * +* * +* Redistribution and use in source and binary forms, with or * +* without modification, are permitted provided that the following * +* condition is met: * +* * +* o Redistributions of source code must retain the above copyright * +* notice, this condition and the following disclaimer. * +* * +* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND * +* CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, * +* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * +* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * +* DISCLAIMED. IN NO EVENT SHALL SEGGER Microcontroller BE LIABLE FOR * +* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT * +* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; * +* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * +* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * +* USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * +* DAMAGE. * +* * +********************************************************************** +* * +* RTT version: 8.10g * +* * +********************************************************************** + +---------------------------END-OF-HEADER------------------------------ +File : SEGGER_RTT_Conf.h +Purpose : Implementation of SEGGER real-time transfer (RTT) which + allows real-time communication on targets which support + debugger memory accesses while the CPU is running. +Revision: $Rev: 24316 $ + +*/ + +#ifndef SEGGER_RTT_CONF_H +#define SEGGER_RTT_CONF_H + +#ifdef __IAR_SYSTEMS_ICC__ + #include +#endif + +/********************************************************************* +* +* Defines, configurable +* +********************************************************************** +*/ + +// +// Take in and set to correct values for Cortex-A systems with CPU cache +// +//#define SEGGER_RTT_CPU_CACHE_LINE_SIZE (32) // Largest cache line size (in bytes) in the current system +//#define SEGGER_RTT_UNCACHED_OFF (0xFB000000) // Address alias where RTT CB and buffers can be accessed uncached +// +// Most common case: +// Up-channel 0: RTT +// Up-channel 1: SystemView +// +#ifndef SEGGER_RTT_MAX_NUM_UP_BUFFERS + #define SEGGER_RTT_MAX_NUM_UP_BUFFERS (3) // Max. number of up-buffers (T->H) available on this target (Default: 3) +#endif +// +// Most common case: +// Down-channel 0: RTT +// Down-channel 1: SystemView +// +#ifndef SEGGER_RTT_MAX_NUM_DOWN_BUFFERS + #define SEGGER_RTT_MAX_NUM_DOWN_BUFFERS (3) // Max. number of down-buffers (H->T) available on this target (Default: 3) +#endif + +#ifndef BUFFER_SIZE_UP + #define BUFFER_SIZE_UP (4096) // Size of the buffer for terminal output of target, up to host (Default: 1k) +#endif + +#ifndef BUFFER_SIZE_DOWN + #define BUFFER_SIZE_DOWN (16) // Size of the buffer for terminal input to target from host (Usually keyboard input) (Default: 16) +#endif + +#ifndef SEGGER_RTT_PRINTF_BUFFER_SIZE + #define SEGGER_RTT_PRINTF_BUFFER_SIZE (64u) // Size of buffer for RTT printf to bulk-send chars via RTT (Default: 64) +#endif + +#ifndef SEGGER_RTT_MODE_DEFAULT + #define SEGGER_RTT_MODE_DEFAULT SEGGER_RTT_MODE_NO_BLOCK_TRIM // Mode for pre-initialized terminal channel (buffer 0) +#endif + +/********************************************************************* +* +* RTT memcpy configuration +* +* memcpy() is good for large amounts of data, +* but the overhead is big for small amounts, which are usually stored via RTT. +* With SEGGER_RTT_MEMCPY_USE_BYTELOOP a simple byte loop can be used instead. +* +* SEGGER_RTT_MEMCPY() can be used to replace standard memcpy() in RTT functions. +* This is may be required with memory access restrictions, +* such as on Cortex-A devices with MMU. +*/ +#ifndef SEGGER_RTT_MEMCPY_USE_BYTELOOP + #define SEGGER_RTT_MEMCPY_USE_BYTELOOP 0 // 0: Use memcpy/SEGGER_RTT_MEMCPY, 1: Use a simple byte-loop +#endif +// +// Example definition of SEGGER_RTT_MEMCPY to external memcpy with GCC toolchains and Cortex-A targets +// +//#if ((defined __SES_ARM) || (defined __CROSSWORKS_ARM) || (defined __GNUC__)) && (defined (__ARM_ARCH_7A__)) +// #define SEGGER_RTT_MEMCPY(pDest, pSrc, NumBytes) SEGGER_memcpy((pDest), (pSrc), (NumBytes)) +//#endif + +// +// Target is not allowed to perform other RTT operations while string still has not been stored completely. +// Otherwise we would probably end up with a mixed string in the buffer. +// If using RTT from within interrupts, multiple tasks or multi processors, define the SEGGER_RTT_LOCK() and SEGGER_RTT_UNLOCK() function here. +// +// SEGGER_RTT_MAX_INTERRUPT_PRIORITY can be used in the sample lock routines on Cortex-M3/4. +// Make sure to mask all interrupts which can send RTT data, i.e. generate SystemView events, or cause task switches. +// When high-priority interrupts must not be masked while sending RTT data, SEGGER_RTT_MAX_INTERRUPT_PRIORITY needs to be adjusted accordingly. +// (Higher priority = lower priority number) +// Default value for embOS: 128u +// Default configuration in FreeRTOS: configMAX_SYSCALL_INTERRUPT_PRIORITY: ( configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY << (8 - configPRIO_BITS) ) +// In case of doubt mask all interrupts: 1 << (8 - BASEPRI_PRIO_BITS) i.e. 1 << 5 when 3 bits are implemented in NVIC +// or define SEGGER_RTT_LOCK() to completely disable interrupts. +// +#ifndef SEGGER_RTT_MAX_INTERRUPT_PRIORITY + #define SEGGER_RTT_MAX_INTERRUPT_PRIORITY (0x20) // Interrupt priority to lock on SEGGER_RTT_LOCK on Cortex-M3/4 (Default: 0x20) +#endif + +/********************************************************************* +* +* RTT lock configuration for SEGGER Embedded Studio, +* Rowley CrossStudio and GCC +*/ +#if ((defined(__SES_ARM) || defined(__SES_RISCV) || defined(__CROSSWORKS_ARM) || defined(__GNUC__) || defined(__clang__)) && !defined (__CC_ARM) && !defined(WIN32)) + #if (defined(__ARM_ARCH_6M__) || defined(__ARM_ARCH_8M_BASE__)) + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + __asm volatile ("mrs %0, primask \n\t" \ + "movs r1, #1 \n\t" \ + "msr primask, r1 \n\t" \ + : "=r" (_SEGGER_RTT__LockState) \ + : \ + : "r1", "cc" \ + ); + + #define SEGGER_RTT_UNLOCK() __asm volatile ("msr primask, %0 \n\t" \ + : \ + : "r" (_SEGGER_RTT__LockState) \ + : \ + ); \ + } + #elif (defined(__ARM_ARCH_7M__) || defined(__ARM_ARCH_7EM__) || defined(__ARM_ARCH_8M_MAIN__) || defined(__ARM_ARCH_8_1M_MAIN__)) + #ifndef SEGGER_RTT_MAX_INTERRUPT_PRIORITY + #define SEGGER_RTT_MAX_INTERRUPT_PRIORITY (0x20) + #endif + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + __asm volatile ("mrs %0, basepri \n\t" \ + "mov r1, %1 \n\t" \ + "msr basepri, r1 \n\t" \ + : "=r" (_SEGGER_RTT__LockState) \ + : "i"(SEGGER_RTT_MAX_INTERRUPT_PRIORITY) \ + : "r1", "cc" \ + ); + + #define SEGGER_RTT_UNLOCK() __asm volatile ("msr basepri, %0 \n\t" \ + : \ + : "r" (_SEGGER_RTT__LockState) \ + : \ + ); \ + } + + #elif (defined(__ARM_ARCH_7A__) || defined(__ARM_ARCH_7R__)) + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + __asm volatile ("mrs r1, CPSR \n\t" \ + "mov %0, r1 \n\t" \ + "orr r1, r1, #0xC0 \n\t" \ + "msr CPSR_c, r1 \n\t" \ + : "=r" (_SEGGER_RTT__LockState) \ + : \ + : "r1", "cc" \ + ); + + #define SEGGER_RTT_UNLOCK() __asm volatile ("mov r0, %0 \n\t" \ + "mrs r1, CPSR \n\t" \ + "bic r1, r1, #0xC0 \n\t" \ + "and r0, r0, #0xC0 \n\t" \ + "orr r1, r1, r0 \n\t" \ + "msr CPSR_c, r1 \n\t" \ + : \ + : "r" (_SEGGER_RTT__LockState) \ + : "r0", "r1", "cc" \ + ); \ + } + #elif defined(__riscv) || defined(__riscv_xlen) + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + __asm volatile ("csrr %0, mstatus \n\t" \ + "csrci mstatus, 8 \n\t" \ + "andi %0, %0, 8 \n\t" \ + : "=r" (_SEGGER_RTT__LockState) \ + : \ + : \ + ); + + #define SEGGER_RTT_UNLOCK() __asm volatile ("csrr a1, mstatus \n\t" \ + "or %0, %0, a1 \n\t" \ + "csrs mstatus, %0 \n\t" \ + : \ + : "r" (_SEGGER_RTT__LockState) \ + : "a1" \ + ); \ + } + #else + #define SEGGER_RTT_LOCK() + #define SEGGER_RTT_UNLOCK() + #endif +#endif + +/********************************************************************* +* +* RTT lock configuration for IAR EWARM +*/ +#ifdef __ICCARM__ + #if (defined (__ARM6M__) && (__CORE__ == __ARM6M__)) || \ + (defined (__ARM8M_BASELINE__) && (__CORE__ == __ARM8M_BASELINE__)) + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + _SEGGER_RTT__LockState = __get_PRIMASK(); \ + __set_PRIMASK(1); + + #define SEGGER_RTT_UNLOCK() __set_PRIMASK(_SEGGER_RTT__LockState); \ + } + #elif (defined (__ARM7EM__) && (__CORE__ == __ARM7EM__)) || \ + (defined (__ARM7M__) && (__CORE__ == __ARM7M__)) || \ + (defined (__ARM8M_MAINLINE__) && (__CORE__ == __ARM8M_MAINLINE__)) || \ + (defined (__ARM8M_MAINLINE__) && (__CORE__ == __ARM8M_MAINLINE__)) + #ifndef SEGGER_RTT_MAX_INTERRUPT_PRIORITY + #define SEGGER_RTT_MAX_INTERRUPT_PRIORITY (0x20) + #endif + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + _SEGGER_RTT__LockState = __get_BASEPRI(); \ + __set_BASEPRI(SEGGER_RTT_MAX_INTERRUPT_PRIORITY); + + #define SEGGER_RTT_UNLOCK() __set_BASEPRI(_SEGGER_RTT__LockState); \ + } + #elif (defined (__ARM7A__) && (__CORE__ == __ARM7A__)) || \ + (defined (__ARM7R__) && (__CORE__ == __ARM7R__)) + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + __asm volatile ("mrs r1, CPSR \n\t" \ + "mov %0, r1 \n\t" \ + "orr r1, r1, #0xC0 \n\t" \ + "msr CPSR_c, r1 \n\t" \ + : "=r" (_SEGGER_RTT__LockState) \ + : \ + : "r1", "cc" \ + ); + + #define SEGGER_RTT_UNLOCK() __asm volatile ("mov r0, %0 \n\t" \ + "mrs r1, CPSR \n\t" \ + "bic r1, r1, #0xC0 \n\t" \ + "and r0, r0, #0xC0 \n\t" \ + "orr r1, r1, r0 \n\t" \ + "msr CPSR_c, r1 \n\t" \ + : \ + : "r" (_SEGGER_RTT__LockState) \ + : "r0", "r1", "cc" \ + ); \ + } + #endif +#endif + +/********************************************************************* +* +* RTT lock configuration for IAR RX +*/ +#ifdef __ICCRX__ + #define SEGGER_RTT_LOCK() { \ + unsigned long _SEGGER_RTT__LockState; \ + _SEGGER_RTT__LockState = __get_interrupt_state(); \ + __disable_interrupt(); + + #define SEGGER_RTT_UNLOCK() __set_interrupt_state(_SEGGER_RTT__LockState); \ + } +#endif + +/********************************************************************* +* +* RTT lock configuration for IAR RL78 +*/ +#ifdef __ICCRL78__ + #define SEGGER_RTT_LOCK() { \ + __istate_t _SEGGER_RTT__LockState; \ + _SEGGER_RTT__LockState = __get_interrupt_state(); \ + __disable_interrupt(); + + #define SEGGER_RTT_UNLOCK() __set_interrupt_state(_SEGGER_RTT__LockState); \ + } +#endif + +/********************************************************************* +* +* RTT lock configuration for KEIL ARM +*/ +#ifdef __CC_ARM + #if (defined __TARGET_ARCH_6S_M) + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + register unsigned char _SEGGER_RTT__PRIMASK __asm( "primask"); \ + _SEGGER_RTT__LockState = _SEGGER_RTT__PRIMASK; \ + _SEGGER_RTT__PRIMASK = 1u; \ + __schedule_barrier(); + + #define SEGGER_RTT_UNLOCK() _SEGGER_RTT__PRIMASK = _SEGGER_RTT__LockState; \ + __schedule_barrier(); \ + } + #elif (defined(__TARGET_ARCH_7_M) || defined(__TARGET_ARCH_7E_M)) + #ifndef SEGGER_RTT_MAX_INTERRUPT_PRIORITY + #define SEGGER_RTT_MAX_INTERRUPT_PRIORITY (0x20) + #endif + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + register unsigned char BASEPRI __asm( "basepri"); \ + _SEGGER_RTT__LockState = BASEPRI; \ + BASEPRI = SEGGER_RTT_MAX_INTERRUPT_PRIORITY; \ + __schedule_barrier(); + + #define SEGGER_RTT_UNLOCK() BASEPRI = _SEGGER_RTT__LockState; \ + __schedule_barrier(); \ + } + #endif +#endif + +/********************************************************************* +* +* RTT lock configuration for TI ARM +*/ +#ifdef __TI_ARM__ + #if defined (__TI_ARM_V6M0__) + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + _SEGGER_RTT__LockState = __get_PRIMASK(); \ + __set_PRIMASK(1); + + #define SEGGER_RTT_UNLOCK() __set_PRIMASK(_SEGGER_RTT__LockState); \ + } + #elif (defined (__TI_ARM_V7M3__) || defined (__TI_ARM_V7M4__)) + #ifndef SEGGER_RTT_MAX_INTERRUPT_PRIORITY + #define SEGGER_RTT_MAX_INTERRUPT_PRIORITY (0x20) + #endif + #define SEGGER_RTT_LOCK() { \ + unsigned int _SEGGER_RTT__LockState; \ + _SEGGER_RTT__LockState = _set_interrupt_priority(SEGGER_RTT_MAX_INTERRUPT_PRIORITY); + + #define SEGGER_RTT_UNLOCK() _set_interrupt_priority(_SEGGER_RTT__LockState); \ + } + #endif +#endif + +/********************************************************************* +* +* RTT lock configuration for CCRX +*/ +#ifdef __RX + #include + #define SEGGER_RTT_LOCK() { \ + unsigned long _SEGGER_RTT__LockState; \ + _SEGGER_RTT__LockState = get_psw() & 0x010000; \ + clrpsw_i(); + + #define SEGGER_RTT_UNLOCK() set_psw(get_psw() | _SEGGER_RTT__LockState); \ + } +#endif + +/********************************************************************* +* +* RTT lock configuration for embOS Simulation on Windows +* (Can also be used for generic RTT locking with embOS) +*/ +#if defined(WIN32) || defined(SEGGER_RTT_LOCK_EMBOS) + +void OS_SIM_EnterCriticalSection(void); +void OS_SIM_LeaveCriticalSection(void); + +#define SEGGER_RTT_LOCK() { \ + OS_SIM_EnterCriticalSection(); + +#define SEGGER_RTT_UNLOCK() OS_SIM_LeaveCriticalSection(); \ + } +#endif + +/********************************************************************* +* +* RTT lock configuration fallback +*/ +#ifndef SEGGER_RTT_LOCK + #define SEGGER_RTT_LOCK() // Lock RTT (nestable) (i.e. disable interrupts) +#endif + +#ifndef SEGGER_RTT_UNLOCK + #define SEGGER_RTT_UNLOCK() // Unlock RTT (nestable) (i.e. enable previous interrupt lock state) +#endif + +#endif +/*************************** End of file ****************************/ diff --git a/RTT/SEGGER_RTT_Syscalls_KEIL.c b/RTT/SEGGER_RTT_Syscalls_KEIL.c new file mode 100644 index 0000000..0ad5840 --- /dev/null +++ b/RTT/SEGGER_RTT_Syscalls_KEIL.c @@ -0,0 +1,394 @@ +/********************************************************************* +* SEGGER Microcontroller GmbH * +* The Embedded Experts * +********************************************************************** +* * +* (c) 1995 - 2021 SEGGER Microcontroller GmbH * +* * +* www.segger.com Support: support@segger.com * +* * +********************************************************************** +* * +* SEGGER RTT * Real Time Transfer for embedded targets * +* * +********************************************************************** +* * +* All rights reserved. * +* * +* SEGGER strongly recommends to not make any changes * +* to or modify the source code of this software in order to stay * +* compatible with the RTT protocol and J-Link. * +* * +* Redistribution and use in source and binary forms, with or * +* without modification, are permitted provided that the following * +* condition is met: * +* * +* o Redistributions of source code must retain the above copyright * +* notice, this condition and the following disclaimer. * +* * +* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND * +* CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, * +* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * +* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * +* DISCLAIMED. IN NO EVENT SHALL SEGGER Microcontroller BE LIABLE FOR * +* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT * +* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; * +* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * +* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * +* USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * +* DAMAGE. * +* * +********************************************************************** +* * +* RTT version: 7.54 * +* * +********************************************************************** + +---------------------------END-OF-HEADER------------------------------ +File : RTT_Syscalls_KEIL.c +Purpose : Retargeting module for KEIL MDK-CM3. + Low-level functions for using printf() via RTT +Revision: $Rev: 24316 $ +Notes : (1) https://wiki.segger.com/Keil_MDK-ARM#RTT_in_uVision +---------------------------------------------------------------------- +*/ +#if (defined __CC_ARM) || (defined __ARMCC_VERSION) + +#include +#include +#include +#include +#include + +#include "SEGGER_RTT.h" +/********************************************************************* +* +* #pragmas +* +********************************************************************** +*/ +#if __ARMCC_VERSION < 6000000 +#pragma import(__use_no_semihosting) +#endif + +#ifdef _MICROLIB + #pragma import(__use_full_stdio) +#endif + +/********************************************************************* +* +* Defines non-configurable +* +********************************************************************** +*/ + +/* Standard IO device handles - arbitrary, but any real file system handles must be + less than 0x8000. */ +#define STDIN 0x8001 // Standard Input Stream +#define STDOUT 0x8002 // Standard Output Stream +#define STDERR 0x8003 // Standard Error Stream + +/********************************************************************* +* +* Public const +* +********************************************************************** +*/ +#if __ARMCC_VERSION < 5000000 +//const char __stdin_name[] = "STDIN"; +const char __stdout_name[] = "STDOUT"; +const char __stderr_name[] = "STDERR"; +#endif + +/********************************************************************* +* +* Public code +* +********************************************************************** +*/ + +/********************************************************************* +* +* _ttywrch +* +* Function description: +* Outputs a character to the console +* +* Parameters: +* c - character to output +* +*/ +void _ttywrch(int c) { + fputc(c, stdout); // stdout + fflush(stdout); +} + +/********************************************************************* +* +* _sys_open +* +* Function description: +* Opens the device/file in order to do read/write operations +* +* Parameters: +* sName - sName of the device/file to open +* OpenMode - This parameter is currently ignored +* +* Return value: +* != 0 - Handle to the object to open, otherwise +* == 0 -"device" is not handled by this module +* +*/ +FILEHANDLE _sys_open(const char * sName, int OpenMode) { + (void)OpenMode; + // Register standard Input Output devices. + if (strcmp(sName, __stdout_name) == 0) { + return (STDOUT); + } else if (strcmp(sName, __stderr_name) == 0) { + return (STDERR); + } else + return (0); // Not implemented +} + +/********************************************************************* +* +* _sys_close +* +* Function description: +* Closes the handle to the open device/file +* +* Parameters: +* hFile - Handle to a file opened via _sys_open +* +* Return value: +* 0 - device/file closed +* +*/ +int _sys_close(FILEHANDLE hFile) { + (void)hFile; + return 0; // Not implemented +} + +/********************************************************************* +* +* _sys_write +* +* Function description: +* Writes the data to an open handle. +* Currently this function only outputs data to the console +* +* Parameters: +* hFile - Handle to a file opened via _sys_open +* pBuffer - Pointer to the data that shall be written +* NumBytes - Number of bytes to write +* Mode - The Mode that shall be used +* +* Return value: +* Number of bytes *not* written to the file/device +* +*/ +int _sys_write(FILEHANDLE hFile, const unsigned char * pBuffer, unsigned NumBytes, int Mode) { + int r = 0; + + (void)Mode; + if (hFile == STDOUT) { + SEGGER_RTT_Write(0, (const char*)pBuffer, NumBytes); + return 0; + } + return r; +} + +/********************************************************************* +* +* _sys_read +* +* Function description: +* Reads data from an open handle. +* Currently this modules does nothing. +* +* Parameters: +* hFile - Handle to a file opened via _sys_open +* pBuffer - Pointer to buffer to store the read data +* NumBytes - Number of bytes to read +* Mode - The Mode that shall be used +* +* Return value: +* Number of bytes read from the file/device +* +*/ +int _sys_read(FILEHANDLE hFile, unsigned char * pBuffer, unsigned NumBytes, int Mode) { + (void)hFile; + (void)pBuffer; + (void)NumBytes; + (void)Mode; + return (0); // Not implemented +} + +/********************************************************************* +* +* _sys_istty +* +* Function description: +* This function shall return whether the opened file +* is a console device or not. +* +* Parameters: +* hFile - Handle to a file opened via _sys_open +* +* Return value: +* 1 - Device is a console +* 0 - Device is not a console +* +*/ +int _sys_istty(FILEHANDLE hFile) { + if (hFile > 0x8000) { + return (1); + } + return (0); // Not implemented +} + +/********************************************************************* +* +* _sys_seek +* +* Function description: +* Seeks via the file to a specific position +* +* Parameters: +* hFile - Handle to a file opened via _sys_open +* Pos - +* +* Return value: +* int - +* +*/ +int _sys_seek(FILEHANDLE hFile, long Pos) { + (void)hFile; + (void)Pos; + return (0); // Not implemented +} + +/********************************************************************* +* +* _sys_ensure +* +* Function description: +* +* +* Parameters: +* hFile - Handle to a file opened via _sys_open +* +* Return value: +* int - +* +*/ +int _sys_ensure(FILEHANDLE hFile) { + (void)hFile; + return (-1); // Not implemented +} + +/********************************************************************* +* +* _sys_flen +* +* Function description: +* Returns the length of the opened file handle +* +* Parameters: +* hFile - Handle to a file opened via _sys_open +* +* Return value: +* Length of the file +* +*/ +long _sys_flen(FILEHANDLE hFile) { + (void)hFile; + return (0); // Not implemented +} + +/********************************************************************* +* +* _sys_tmpnam +* +* Function description: +* This function converts the file number fileno for a temporary +* file to a unique filename, for example, tmp0001. +* +* Parameters: +* pBuffer - Pointer to a buffer to store the name +* FileNum - file number to convert +* MaxLen - Size of the buffer +* +* Return value: +* 1 - Error +* 0 - Success +* +*/ +int _sys_tmpnam2(char * pBuffer, int FileNum, unsigned MaxLen) { + (void)pBuffer; + (void)FileNum; + (void)MaxLen; + return (1); // Not implemented +} + +/********************************************************************* +* +* _sys_command_string +* +* Function description: +* This function shall execute a system command. +* +* Parameters: +* cmd - Pointer to the command string +* len - Length of the string +* +* Return value: +* == NULL - Command was not successfully executed +* == sCmd - Command was passed successfully +* +*/ +char * _sys_command_string(char * cmd, int len) { + (void)len; + return cmd; // Not implemented +} + +/********************************************************************* +* +* _sys_exit +* +* Function description: +* This function is called when the application returns from main +* +* Parameters: +* ReturnCode - Return code from the main function +* +* +*/ +void _sys_exit(int ReturnCode) { + (void)ReturnCode; + while (1); // Not implemented +} + +#if __ARMCC_VERSION >= 5000000 +/********************************************************************* +* +* stdout_putchar +* +* Function description: +* Put a character to the stdout +* +* Parameters: +* ch - Character to output +* +* +*/ +int stdout_putchar(int ch) { + (void)ch; + return ch; // Not implemented +} +#endif + +#endif +/*************************** End of file ****************************/ \ No newline at end of file diff --git a/RTT/SEGGER_RTT_printf.c b/RTT/SEGGER_RTT_printf.c new file mode 100644 index 0000000..12533ff --- /dev/null +++ b/RTT/SEGGER_RTT_printf.c @@ -0,0 +1,508 @@ +/********************************************************************* +* SEGGER Microcontroller GmbH * +* The Embedded Experts * +********************************************************************** +* * +* (c) 1995 - 2021 SEGGER Microcontroller GmbH * +* * +* www.segger.com Support: support@segger.com * +* * +********************************************************************** +* * +* SEGGER RTT * Real Time Transfer for embedded targets * +* * +********************************************************************** +* * +* All rights reserved. * +* * +* SEGGER strongly recommends to not make any changes * +* to or modify the source code of this software in order to stay * +* compatible with the RTT protocol and J-Link. * +* * +* Redistribution and use in source and binary forms, with or * +* without modification, are permitted provided that the following * +* condition is met: * +* * +* o Redistributions of source code must retain the above copyright * +* notice, this condition and the following disclaimer. * +* * +* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND * +* CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, * +* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * +* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * +* DISCLAIMED. IN NO EVENT SHALL SEGGER Microcontroller BE LIABLE FOR * +* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT * +* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; * +* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * +* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * +* USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * +* DAMAGE. * +* * +********************************************************************** +* * +* RTT version: 8.10g * +* * +********************************************************************** + +---------------------------END-OF-HEADER------------------------------ +File : SEGGER_RTT_printf.c +Purpose : Replacement for printf to write formatted data via RTT +Revision: $Rev: 17697 $ +---------------------------------------------------------------------- +*/ +#include "SEGGER_RTT.h" +#include "SEGGER_RTT_Conf.h" + +/********************************************************************* +* +* Defines, configurable +* +********************************************************************** +*/ + +#ifndef SEGGER_RTT_PRINTF_BUFFER_SIZE + #define SEGGER_RTT_PRINTF_BUFFER_SIZE (64) +#endif + +#include +#include + + +#define FORMAT_FLAG_LEFT_JUSTIFY (1u << 0) +#define FORMAT_FLAG_PAD_ZERO (1u << 1) +#define FORMAT_FLAG_PRINT_SIGN (1u << 2) +#define FORMAT_FLAG_ALTERNATE (1u << 3) + +/********************************************************************* +* +* Types +* +********************************************************************** +*/ + +typedef struct { + char* pBuffer; + unsigned BufferSize; + unsigned Cnt; + + int ReturnValue; + + unsigned RTTBufferIndex; +} SEGGER_RTT_PRINTF_DESC; + +/********************************************************************* +* +* Function prototypes +* +********************************************************************** +*/ + +/********************************************************************* +* +* Static code +* +********************************************************************** +*/ +/********************************************************************* +* +* _StoreChar +*/ +static void _StoreChar(SEGGER_RTT_PRINTF_DESC * p, char c) { + unsigned Cnt; + + Cnt = p->Cnt; + if ((Cnt + 1u) <= p->BufferSize) { + *(p->pBuffer + Cnt) = c; + p->Cnt = Cnt + 1u; + p->ReturnValue++; + } + // + // Write part of string, when the buffer is full + // + if (p->Cnt == p->BufferSize) { + if (SEGGER_RTT_Write(p->RTTBufferIndex, p->pBuffer, p->Cnt) != p->Cnt) { + p->ReturnValue = -1; + } else { + p->Cnt = 0u; + } + } +} + +/********************************************************************* +* +* _PrintUnsigned +*/ +static void _PrintUnsigned(SEGGER_RTT_PRINTF_DESC * pBufferDesc, unsigned v, unsigned Base, unsigned NumDigits, unsigned FieldWidth, unsigned FormatFlags) { + static const char _aV2C[16] = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' }; + unsigned Div; + unsigned Digit; + unsigned Number; + unsigned Width; + char c; + + Number = v; + Digit = 1u; + // + // Get actual field width + // + Width = 1u; + while (Number >= Base) { + Number = (Number / Base); + Width++; + } + if (NumDigits > Width) { + Width = NumDigits; + } + // + // Print leading chars if necessary + // + if ((FormatFlags & FORMAT_FLAG_LEFT_JUSTIFY) == 0u) { + if (FieldWidth != 0u) { + if (((FormatFlags & FORMAT_FLAG_PAD_ZERO) == FORMAT_FLAG_PAD_ZERO) && (NumDigits == 0u)) { + c = '0'; + } else { + c = ' '; + } + while ((FieldWidth != 0u) && (Width < FieldWidth)) { + FieldWidth--; + _StoreChar(pBufferDesc, c); + if (pBufferDesc->ReturnValue < 0) { + break; + } + } + } + } + if (pBufferDesc->ReturnValue >= 0) { + // + // Compute Digit. + // Loop until Digit has the value of the highest digit required. + // Example: If the output is 345 (Base 10), loop 2 times until Digit is 100. + // + while (1) { + if (NumDigits > 1u) { // User specified a min number of digits to print? => Make sure we loop at least that often, before checking anything else (> 1 check avoids problems with NumDigits being signed / unsigned) + NumDigits--; + } else { + Div = v / Digit; + if (Div < Base) { // Is our divider big enough to extract the highest digit from value? => Done + break; + } + } + Digit *= Base; + } + // + // Output digits + // + do { + Div = v / Digit; + v -= Div * Digit; + _StoreChar(pBufferDesc, _aV2C[Div]); + if (pBufferDesc->ReturnValue < 0) { + break; + } + Digit /= Base; + } while (Digit); + // + // Print trailing spaces if necessary + // + if ((FormatFlags & FORMAT_FLAG_LEFT_JUSTIFY) == FORMAT_FLAG_LEFT_JUSTIFY) { + if (FieldWidth != 0u) { + while ((FieldWidth != 0u) && (Width < FieldWidth)) { + FieldWidth--; + _StoreChar(pBufferDesc, ' '); + if (pBufferDesc->ReturnValue < 0) { + break; + } + } + } + } + } +} + +/********************************************************************* +* +* _PrintInt +*/ +static void _PrintInt(SEGGER_RTT_PRINTF_DESC * pBufferDesc, int v, unsigned Base, unsigned NumDigits, unsigned FieldWidth, unsigned FormatFlags) { + unsigned Width; + int Number; + + Number = (v < 0) ? -v : v; + + // + // Get actual field width + // + Width = 1u; + while (Number >= (int)Base) { + Number = (Number / (int)Base); + Width++; + } + if (NumDigits > Width) { + Width = NumDigits; + } + if ((FieldWidth > 0u) && ((v < 0) || ((FormatFlags & FORMAT_FLAG_PRINT_SIGN) == FORMAT_FLAG_PRINT_SIGN))) { + FieldWidth--; + } + + // + // Print leading spaces if necessary + // + if ((((FormatFlags & FORMAT_FLAG_PAD_ZERO) == 0u) || (NumDigits != 0u)) && ((FormatFlags & FORMAT_FLAG_LEFT_JUSTIFY) == 0u)) { + if (FieldWidth != 0u) { + while ((FieldWidth != 0u) && (Width < FieldWidth)) { + FieldWidth--; + _StoreChar(pBufferDesc, ' '); + if (pBufferDesc->ReturnValue < 0) { + break; + } + } + } + } + // + // Print sign if necessary + // + if (pBufferDesc->ReturnValue >= 0) { + if (v < 0) { + v = -v; + _StoreChar(pBufferDesc, '-'); + } else if ((FormatFlags & FORMAT_FLAG_PRINT_SIGN) == FORMAT_FLAG_PRINT_SIGN) { + _StoreChar(pBufferDesc, '+'); + } else { + + } + if (pBufferDesc->ReturnValue >= 0) { + // + // Print leading zeros if necessary + // + if (((FormatFlags & FORMAT_FLAG_PAD_ZERO) == FORMAT_FLAG_PAD_ZERO) && ((FormatFlags & FORMAT_FLAG_LEFT_JUSTIFY) == 0u) && (NumDigits == 0u)) { + if (FieldWidth != 0u) { + while ((FieldWidth != 0u) && (Width < FieldWidth)) { + FieldWidth--; + _StoreChar(pBufferDesc, '0'); + if (pBufferDesc->ReturnValue < 0) { + break; + } + } + } + } + if (pBufferDesc->ReturnValue >= 0) { + // + // Print number without sign + // + _PrintUnsigned(pBufferDesc, (unsigned)v, Base, NumDigits, FieldWidth, FormatFlags); + } + } + } +} + +/********************************************************************* +* +* Public code +* +********************************************************************** +*/ +/********************************************************************* +* +* SEGGER_RTT_vprintf +* +* Function description +* Stores a formatted string in SEGGER RTT control block. +* This data is read by the host. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used. (e.g. 0 for "Terminal") +* sFormat Pointer to format string +* pParamList Pointer to the list of arguments for the format string +* +* Return values +* >= 0: Number of bytes which have been stored in the "Up"-buffer. +* < 0: Error +*/ +int SEGGER_RTT_vprintf(unsigned BufferIndex, const char * sFormat, va_list * pParamList) { + char c; + SEGGER_RTT_PRINTF_DESC BufferDesc; + int v; + unsigned NumDigits; + unsigned FormatFlags; + unsigned FieldWidth; + char acBuffer[SEGGER_RTT_PRINTF_BUFFER_SIZE]; + + BufferDesc.pBuffer = acBuffer; + BufferDesc.BufferSize = SEGGER_RTT_PRINTF_BUFFER_SIZE; + BufferDesc.Cnt = 0u; + BufferDesc.RTTBufferIndex = BufferIndex; + BufferDesc.ReturnValue = 0; + + do { + c = *sFormat; + sFormat++; + if (c == 0u) { + break; + } + if (c == '%') { + // + // Filter out flags + // + FormatFlags = 0u; + v = 1; + do { + c = *sFormat; + switch (c) { + case '-': FormatFlags |= FORMAT_FLAG_LEFT_JUSTIFY; sFormat++; break; + case '0': FormatFlags |= FORMAT_FLAG_PAD_ZERO; sFormat++; break; + case '+': FormatFlags |= FORMAT_FLAG_PRINT_SIGN; sFormat++; break; + case '#': FormatFlags |= FORMAT_FLAG_ALTERNATE; sFormat++; break; + default: v = 0; break; + } + } while (v); + // + // filter out field with + // + FieldWidth = 0u; + do { + c = *sFormat; + if ((c < '0') || (c > '9')) { + break; + } + sFormat++; + FieldWidth = (FieldWidth * 10u) + ((unsigned)c - '0'); + } while (1); + + // + // Filter out precision (number of digits to display) + // + NumDigits = 0u; + c = *sFormat; + if (c == '.') { + sFormat++; + do { + c = *sFormat; + if ((c < '0') || (c > '9')) { + break; + } + sFormat++; + NumDigits = NumDigits * 10u + ((unsigned)c - '0'); + } while (1); + } + // + // Filter out length modifier + // + c = *sFormat; + do { + if ((c == 'l') || (c == 'h')) { + sFormat++; + c = *sFormat; + } else { + break; + } + } while (1); + // + // Handle specifiers + // + switch (c) { + case 'c': { + char c0; + v = va_arg(*pParamList, int); + c0 = (char)v; + _StoreChar(&BufferDesc, c0); + break; + } + case 'd': + v = va_arg(*pParamList, int); + _PrintInt(&BufferDesc, v, 10u, NumDigits, FieldWidth, FormatFlags); + break; + case 'u': + v = va_arg(*pParamList, int); + _PrintUnsigned(&BufferDesc, (unsigned)v, 10u, NumDigits, FieldWidth, FormatFlags); + break; + case 'x': + case 'X': + v = va_arg(*pParamList, int); + _PrintUnsigned(&BufferDesc, (unsigned)v, 16u, NumDigits, FieldWidth, FormatFlags); + break; + case 's': + { + const char * s = va_arg(*pParamList, const char *); + if (s == NULL) { + s = "(NULL)"; // Print (NULL) instead of crashing or breaking, as it is more informative to the user. + } + do { + c = *s; + s++; + if (c == '\0') { + break; + } + _StoreChar(&BufferDesc, c); + } while (BufferDesc.ReturnValue >= 0); + } + break; + case 'p': + v = va_arg(*pParamList, int); + _PrintUnsigned(&BufferDesc, (unsigned)v, 16u, 8u, 8u, 0u); + break; + case '%': + _StoreChar(&BufferDesc, '%'); + break; + default: + break; + } + sFormat++; + } else { + _StoreChar(&BufferDesc, c); + } + } while (BufferDesc.ReturnValue >= 0); + + if (BufferDesc.ReturnValue > 0) { + // + // Write remaining data, if any + // + if (BufferDesc.Cnt != 0u) { + SEGGER_RTT_Write(BufferIndex, acBuffer, BufferDesc.Cnt); + } + BufferDesc.ReturnValue += (int)BufferDesc.Cnt; + } + return BufferDesc.ReturnValue; +} + +/********************************************************************* +* +* SEGGER_RTT_printf +* +* Function description +* Stores a formatted string in SEGGER RTT control block. +* This data is read by the host. +* +* Parameters +* BufferIndex Index of "Up"-buffer to be used. (e.g. 0 for "Terminal") +* sFormat Pointer to format string, followed by the arguments for conversion +* +* Return values +* >= 0: Number of bytes which have been stored in the "Up"-buffer. +* < 0: Error +* +* Notes +* (1) Conversion specifications have following syntax: +* %[flags][FieldWidth][.Precision]ConversionSpecifier +* (2) Supported flags: +* -: Left justify within the field width +* +: Always print sign extension for signed conversions +* 0: Pad with 0 instead of spaces. Ignored when using '-'-flag or precision +* Supported conversion specifiers: +* c: Print the argument as one char +* d: Print the argument as a signed integer +* u: Print the argument as an unsigned integer +* x: Print the argument as an hexadecimal integer +* s: Print the string pointed to by the argument +* p: Print the argument as an 8-digit hexadecimal integer. (Argument shall be a pointer to void.) +*/ +int SEGGER_RTT_printf(unsigned BufferIndex, const char * sFormat, ...) { + int r; + va_list ParamList; + + va_start(ParamList, sFormat); + r = SEGGER_RTT_vprintf(BufferIndex, sFormat, &ParamList); + va_end(ParamList); + return r; +} +/*************************** End of file ****************************/