Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
TianYing_ty100
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
TY
TianYing_ty100
Commits
3fa0fa7f
Commit
3fa0fa7f
authored
Jun 25, 2024
by
李俭双
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
🐞
fix:48025 【天鹰TY200】【欠压保护】欠压保护,电压检测时长不固定,更换电源管理库
parent
13a51f36
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
7 deletions
+22
-7
System_Monitor.lib
Firmware/Source/Component/System_Monitor/System_Monitor.lib
+0
-0
System_Monitor_User.c
...are/Source/Component/System_Monitor/System_Monitor_User.c
+22
-7
No files found.
Firmware/Source/Component/System_Monitor/System_Monitor.lib
deleted
100644 → 0
View file @
13a51f36
File deleted
Firmware/Source/Component/System_Monitor/System_Monitor_User.c
View file @
3fa0fa7f
...
@@ -5,8 +5,8 @@
...
@@ -5,8 +5,8 @@
#include "wdt.h"
#include "wdt.h"
#define u16Base_Vol 0u
#define u16Base_Vol 0u
#define u16ENTER_LOW_N_RANGE
65
00U
#define u16ENTER_LOW_N_RANGE
70
00U
#define u16EXIT_LOW_N_RANGE 7
0
00U
#define u16EXIT_LOW_N_RANGE 7
5
00U
#define u16ENTER_LOW_Y_RANGE 9000U
#define u16ENTER_LOW_Y_RANGE 9000U
#define u16EXIT_LOW_Y_RANGE 10000U
#define u16EXIT_LOW_Y_RANGE 10000U
...
@@ -20,7 +20,7 @@
...
@@ -20,7 +20,7 @@
void
Delay_ms
(
uint32_t
u32Ms
);
void
Delay_ms
(
uint32_t
u32Ms
);
// #pragma alignvar(8)
// #pragma alignvar(8)
static
const
monitorlib_uint16_t
SysFun_Range
[
2
4
u
]
=
{
static
const
monitorlib_uint16_t
SysFun_Range
[
2
6
u
]
=
{
u16Base_Vol
,
u16Base_Vol
,
u16ENTER_LOW_N_RANGE
,
u16ENTER_LOW_N_RANGE
,
...
@@ -36,7 +36,7 @@ static const monitorlib_uint16_t SysFun_Range[24u] = {
...
@@ -36,7 +36,7 @@ static const monitorlib_uint16_t SysFun_Range[24u] = {
u16ENTER_HIGH_N_RANGE
,
u16ENTER_HIGH_N_RANGE
,
u16Top_Vol
,
u16Top_Vol
,
500
,
/* 进入异常电压时间 1
S */
2500
,
/* 进入异常电压时间 5
S */
50u
,
/* KL15消抖时间 100ms*/
50u
,
/* KL15消抖时间 100ms*/
u16Base_Vol
,
u16Base_Vol
,
...
@@ -55,6 +55,9 @@ static const monitorlib_uint16_t SysFun_Range[24u] = {
...
@@ -55,6 +55,9 @@ static const monitorlib_uint16_t SysFun_Range[24u] = {
u16Top_Vol
,
u16Top_Vol
,
2u
,
2u
,
2u
,
2u
,
2u
,
0u
,
};
};
monitorlib_uint16_t
Sys_Read_KL30_Voltage_F
(
void
)
monitorlib_uint16_t
Sys_Read_KL30_Voltage_F
(
void
)
...
@@ -103,15 +106,27 @@ monitorlib_uint8_t System_LINE_KL15(void)
...
@@ -103,15 +106,27 @@ monitorlib_uint8_t System_LINE_KL15(void)
{
{
monitorlib_uint8_t
u8KL15
=
0
;
monitorlib_uint8_t
u8KL15
=
0
;
if
(
RTE_GPIO_Get_Level
(
WAKEUP_KL15_In
)
==
1u
)
//if (RTE_GPIO_Get_Level(WAKEUP_KL15_In) == 1u )
//{
// u8KL15 = 1u;
//}
//else
//{
// u8KL15 = 0;
//}
if
((
Sys_Read_KL15_Voltage
()
>=
5500u
)
&&
(
RTE_GPIO_Get_Level
(
WAKEUP_KL15_In
)
==
1u
))
{
{
u8KL15
=
1u
;
u8KL15
=
1u
;
}
}
else
if
((
Sys_Read_KL15_Voltage
()
>=
5000u
)
&&
(
Sys_Read_KL15_Voltage
()
<
5500u
))
{
;
}
else
else
{
{
u8KL15
=
0
;
u8KL15
=
0
;
}
}
return
u8KL15
;
return
u8KL15
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment