Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
V
VC66_7C
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
ISUZU
VC66_7C
Commits
d4097832
Commit
d4097832
authored
Oct 04, 2022
by
hu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
用于声音频率的测试功能
parent
d3cc359f
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
59 additions
and
5 deletions
+59
-5
Popups.c
source/Application/Alarm/Popups.c
+5
-1
CAN_Communication_Matrix.c
...Application/CAN_APP_NM/CAN_App/CAN_Communication_Matrix.c
+29
-0
CAN_Communication_Matrix.h
...Application/CAN_APP_NM/CAN_App/CAN_Communication_Matrix.h
+8
-0
RTE_CAN.c
source/Application/RTE/RTE_CAN.c
+4
-0
Buzzer.c
source/Driver/Buzzer/Buzzer.c
+8
-3
RSCAN_Table.c
source/Driver/CAN/RSCAN_Table.c
+2
-0
RSCAN_Table.h
source/Driver/CAN/RSCAN_Table.h
+1
-1
tasks.c
source/System/tasks.c
+2
-0
No files found.
source/Application/Alarm/Popups.c
View file @
d4097832
...
...
@@ -1191,7 +1191,7 @@ void Popups_Sound_Playing(uint8_t PopupSnd)
* Return : None
* onther : None
--------------------------------------------------------------------------*/
//
uint16_t Sound_test = 0;
uint16_t
Sound_test
=
0
;
void
Popup_Alone_Sound_Server
(
void
)
{
COMMON_PowerStatus_t
u8IG_st
;
...
...
@@ -1227,6 +1227,7 @@ void Popup_Alone_Sound_Server(void)
{
if
(
u8IG_st
==
COMMON_POWER_ON
)
{
#if 0
/*00 忘拔钥匙*/
Sound_Delete(SND_Key_Notremoved);
...
...
@@ -1504,6 +1505,9 @@ void Popup_Alone_Sound_Server(void)
{
Sound_Delete(SND_Fuel_Saving);
}
#endif
Sound_test
=
Get_ID_111_Sig_DATA1
();
if
(
Sound_test
)
Sound_Request
(
SND_Key_Notremoved
,
1
);
else
Sound_Delete
(
SND_Key_Notremoved
);
/*音源测试程序*/
//if (Sound_test & 0x001) Sound_Request ( SND_Key_Notremoved, 1 ); else Sound_Delete( SND_Key_Notremoved );
...
...
source/Application/CAN_APP_NM/CAN_App/CAN_Communication_Matrix.c
View file @
d4097832
...
...
@@ -616,6 +616,16 @@ const st_CANMsgAttribute CAN_MSG_CONST_ARRAY[ID_TOTAL_MAX] =
((
void
*
)
0
),
((
void
*
)
0
),
},
{
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
{
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
,
0x00u
},
5000ul
,
0x111ul
,
((
void
*
)
0
),
((
void
*
)
0
),
((
void
*
)
0
),
},
};
uint8_t
Get_ID_18FF5510_Sig_Intarder_Pilot_Lamp_State
(
void
)
...
...
@@ -1512,6 +1522,22 @@ uint8_t Get_ID_18EBFFE8_Sig_DATA(uint8_t Data_Buff)
return
((
uint8_t
)((
uint8_t
)
CAN_MSG_Read
(
ID_CanMsg18EBFFE8_Msg_Count
,
Data_Buff
)
>>
0u
)
&
0xFFu
);
}
uint8_t
Get_ID_111_Sig_DATA1
(
void
)
{
return
((
uint8_t
)((
uint8_t
)
CAN_MSG_Read
(
ID_CanMsg111_Msg_Count
,
0
)
>>
0u
)
&
0xFFu
);
}
uint16_t
Get_ID_111_Sig_DATA2
(
void
)
{
return
(((
uint16_t
)((
uint16_t
)((
uint16_t
)
CAN_MSG_Read
(
ID_CanMsg111_Msg_Count
,
2u
)
>>
0u
)
&
0xFFu
)
<<
8u
)
+
\
((
uint16_t
)((
uint16_t
)
CAN_MSG_Read
(
ID_CanMsg111_Msg_Count
,
1u
)
>>
0u
)
&
0xFFu
));
}
uint16_t
Get_ID_111_Sig_DATA3
(
void
)
{
return
(((
uint16_t
)((
uint16_t
)((
uint16_t
)
CAN_MSG_Read
(
ID_CanMsg111_Msg_Count
,
4u
)
>>
0u
)
&
0xFFu
)
<<
8u
)
+
\
((
uint16_t
)((
uint16_t
)
CAN_MSG_Read
(
ID_CanMsg111_Msg_Count
,
3u
)
>>
0u
)
&
0xFFu
));
}
uint8_t
Co_Can_ConvertSubID
(
uint32_t
MsgID
)
{
uint8_t
u8Result
=
ID_TOTAL_MAX
;
...
...
@@ -1697,6 +1723,9 @@ uint8_t Co_Can_ConvertSubID(uint32_t MsgID)
u8Result
=
ID_CanMsg18EBFFE8_Msg_Count
;
break
;
case
ID_CanMsg111_Msg
:
u8Result
=
ID_CanMsg111_Msg_Count
;
break
;
default
:
u8Result
=
ID_TOTAL_MAX
;
break
;
...
...
source/Application/CAN_APP_NM/CAN_App/CAN_Communication_Matrix.h
View file @
d4097832
...
...
@@ -67,6 +67,8 @@ typedef enum
ID_CanMsg18ECFFE8_Msg_Count
,
ID_CanMsg18EBFFE8_Msg_Count
,
ID_CanMsg111_Msg_Count
,
ID_TOTAL_MAX
,
}
CAN_MSG_ID_t
;
...
...
@@ -156,6 +158,8 @@ extern const st_CAN_SendAttribute st_CANSendAttr[ID_SEND_TOTAL] ;
#define ID_CanMsg18ECFFE8_Msg 0x18ECFFE8u
#define ID_CanMsg18EBFFE8_Msg 0x18EBFFE8u
#define ID_CanMsg111_Msg 0x111
extern
uint8_t
Get_ID_18FF5510_Sig_Intarder_Pilot_Lamp_State
(
void
);
extern
uint8_t
Get_ID_18FF2300_Sig_EXH_System
(
void
);
extern
uint8_t
Get_ID_18FF2300_Sig_Engine_Derate
(
void
);
...
...
@@ -336,6 +340,10 @@ extern uint16_t Get_ID_18ECFFE8_Sig_PGN(void);
extern
uint8_t
Get_ID_18ECFFE8_Sig_SA
(
void
);
extern
uint8_t
Get_ID_18EBFFE8_Sig_DATA
(
uint8_t
Data_Buff
);
extern
uint8_t
Get_ID_111_Sig_DATA1
(
void
);
extern
uint16_t
Get_ID_111_Sig_DATA2
(
void
);
extern
uint16_t
Get_ID_111_Sig_DATA3
(
void
);
extern
uint8_t
Co_Can_ConvertSubID
(
uint32_t
MsgID
);
#endif
source/Application/RTE/RTE_CAN.c
View file @
d4097832
...
...
@@ -172,6 +172,10 @@ void Can_Read_Msg2(uint32_t m_id, uint8_t m_dlc, uint8_t m_Msg[])
{
DoCAN_L_Data_Indication
(
m_id
,
m_dlc
,
m_Msg
);
}
if
(
m_id
==
0x111
)
{
Co_Can_Buff_Set
(
Co_Can_ConvertSubID
(
m_id
),
m_dlc
,
m_Msg
);
}
}
void
Can_Confirm
(
uint32_t
Identifier
,
uint8_t
TransferStatus
)
...
...
source/Driver/Buzzer/Buzzer.c
View file @
d4097832
...
...
@@ -11,9 +11,11 @@
#include "TimerB.h"
#include "Sound_Tracks.h"
#include "CAN_Communication_Matrix.h"
#include "TYW_stdint.h"
#define BUZZER_PWM_CHANNEL TIMERB_0_CH11
uint32_t
Sound_Freq
;
uint32_t
Sound_Duty
;
BuzzerPlayCtrlStruct
BuzzerPlayCtrl
;
/******************************************************************************
...
...
@@ -148,8 +150,11 @@ void Buzzer_Play_ISR(void)
if
(
SndTracks
[
BuzzerPlayCtrl
.
Track
].
Note
[
BuzzerPlayCtrl
.
Note
].
Freq
)
{
TimerB_PWM_Channel_Fre_Set
(
BUZZER_PWM_CHANNEL
,
SndTracks
[
BuzzerPlayCtrl
.
Track
].
Note
[
BuzzerPlayCtrl
.
Note
].
Freq
,
SndTracks
[
BuzzerPlayCtrl
.
Track
].
Note
[
BuzzerPlayCtrl
.
Note
].
Duty
);
//
TimerB_PWM_Channel_Fre_Set(BUZZER_PWM_CHANNEL, SndTracks[BuzzerPlayCtrl.Track].Note[BuzzerPlayCtrl.Note].Freq, SndTracks[BuzzerPlayCtrl.Track].Note[BuzzerPlayCtrl.Note].Duty);
// TimerB_PWM_Channel_Duty_Set(BUZZER_PWM_CHANNEL, SndTracks[BuzzerPlayCtrl.Track].Note[BuzzerPlayCtrl.Note].Duty);
Sound_Freq
=
Get_ID_111_Sig_DATA2
();
Sound_Duty
=
Get_ID_111_Sig_DATA3
();
TimerB_PWM_Channel_Fre_Set
(
BUZZER_PWM_CHANNEL
,
(
uint16_t
)
Sound_Freq
,
(
uint16_t
)
Sound_Duty
);
TimerB_PWM_Channel_Start
(
BUZZER_PWM_CHANNEL
);
}
else
...
...
source/Driver/CAN/RSCAN_Table.c
View file @
d4097832
...
...
@@ -44,4 +44,6 @@ const RSCANFD_Filter_st_t CANFD_RX_RULE_TABLE_LIST[CANFD0_RX_RULE_SIZE] =
{
0x000007F0ul
,
0xDFFFFFFFUL
,
0x80000000ul
,
CANFD0_CH2_RX_SELECT
},
/* 2*/
{
0x000007F1ul
,
0xDFFFFFFFUL
,
0x80000000ul
,
CANFD0_CH2_RX_SELECT
},
/* 3*/
{
0x00000111ul
,
0xDFFFFFFFUL
,
0x80000000ul
,
CANFD0_CH2_RX_SELECT
},
/* 4*/
};
\ No newline at end of file
source/Driver/CAN/RSCAN_Table.h
View file @
d4097832
...
...
@@ -13,7 +13,7 @@ typedef struct
#define CANFD0_CH0_RX_RULE_SIZE 24u
#define CANFD0_CH1_RX_RULE_SIZE 0U
#define CANFD0_CH2_RX_RULE_SIZE
3
U
#define CANFD0_CH2_RX_RULE_SIZE
4
U
#define CANFD0_RX_RULE_SIZE (CANFD0_CH0_RX_RULE_SIZE + \
...
...
source/System/tasks.c
View file @
d4097832
...
...
@@ -300,6 +300,7 @@ void Sys_Sleep_Mode_Tasks(void)
/*==============================================================================
精确的50us计时任务 禁止添加修改列表中的任务
------------------------------------------------------------------------------*/
void
Sys_Exact_50us_Tasks
(
void
)
{
static
uint16_t
PerCounter
=
0u
;
...
...
@@ -315,6 +316,7 @@ void Sys_Exact_50us_Tasks(void)
PerCounter
=
0u
;
SEG_LCD_Window_Control_Service
();
}
Buzzer_Play_ISR
();
Drive_Info_Speed1_Plus_Conversion_ISR
();
...
...
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