Browse Source

捕获中断捕获数据成功

dev
tianjialong 2 years ago
parent
commit
f223bfdbff
  1. 31
      MDK-ARM/LWIP.uvguix.29643
  2. 52
      MDK-ARM/LWIP.uvoptx
  3. 1088
      MDK-ARM/LWIP.uvprojx
  4. 2
      usersrc/encoder.c
  5. 35
      usersrc/usermain.c

31
MDK-ARM/LWIP.uvguix.29643
File diff suppressed because it is too large
View File

52
MDK-ARM/LWIP.uvoptx

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<ProjectOpt xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="project_optx.xsd">
<SchemaVersion>1.0</SchemaVersion>
@ -45,7 +45,7 @@
<PageWidth>79</PageWidth>
<PageLength>66</PageLength>
<TabStop>8</TabStop>
<ListingPath />
<ListingPath></ListingPath>
</OPTLEX>
<ListingPage>
<CreateCListing>1</CreateCListing>
@ -104,16 +104,16 @@
<bSchkAxf>0</bSchkAxf>
<bTchkAxf>0</bTchkAxf>
<nTsel>3</nTsel>
<sDll />
<sDllPa />
<sDlgDll />
<sDlgPa />
<sIfile />
<tDll />
<tDllPa />
<tDlgDll />
<tDlgPa />
<tIfile />
<sDll></sDll>
<sDllPa></sDllPa>
<sDlgDll></sDlgDll>
<sDlgPa></sDlgPa>
<sIfile></sIfile>
<tDll></tDll>
<tDllPa></tDllPa>
<tDlgDll></tDlgDll>
<tDlgPa></tDlgPa>
<tIfile></tIfile>
<pMon>BIN\CMSIS_AGDI.dll</pMon>
</DebugOpt>
<TargetDriverDllRegistry>
@ -130,12 +130,12 @@
<SetRegEntry>
<Number>0</Number>
<Key>ARMDBGFLAGS</Key>
<Name />
<Name></Name>
</SetRegEntry>
<SetRegEntry>
<Number>0</Number>
<Key>DLGUARM</Key>
<Name />
<Name></Name>
</SetRegEntry>
<SetRegEntry>
<Number>0</Number>
@ -167,7 +167,7 @@
<BreakByAccess>0</BreakByAccess>
<BreakIfRCount>1</BreakIfRCount>
<Filename>..\usersrc\atcmd.c</Filename>
<ExecCommand />
<ExecCommand></ExecCommand>
<Expression>\\LWIP\../usersrc/atcmd.c\132</Expression>
</Bp>
<Bp>
@ -183,7 +183,7 @@
<BreakByAccess>0</BreakByAccess>
<BreakIfRCount>1</BreakIfRCount>
<Filename>../Src/ethernetif.c</Filename>
<ExecCommand />
<ExecCommand></ExecCommand>
<Expression>\\LWIP\../Src/ethernetif.c\198</Expression>
</Bp>
</Breakpoint>
@ -228,19 +228,19 @@
<newCpu>0</newCpu>
<uProt>0</uProt>
</DebugFlag>
<LintExecutable />
<LintConfigFile />
<LintExecutable></LintExecutable>
<LintConfigFile></LintConfigFile>
<bLintAuto>0</bLintAuto>
<bAutoGenD>0</bAutoGenD>
<LntExFlags>0</LntExFlags>
<pMisraName />
<pszMrule />
<pSingCmds />
<pMultCmds />
<pMisraNamep />
<pszMrulep />
<pSingCmdsp />
<pMultCmdsp />
<pMisraName></pMisraName>
<pszMrule></pszMrule>
<pSingCmds></pSingCmds>
<pMultCmds></pMultCmds>
<pMisraNamep></pMisraNamep>
<pszMrulep></pszMrulep>
<pSingCmdsp></pSingCmdsp>
<pMultCmdsp></pMultCmdsp>
<DebugDescription>
<Enable>1</Enable>
<EnableFlashSeq>0</EnableFlashSeq>

1088
MDK-ARM/LWIP.uvprojx
File diff suppressed because it is too large
View File

2
usersrc/encoder.c

@ -11,7 +11,7 @@ static uint32_t driven_encoder_gear_lastprocess = 0;
static encoder_t m_uarts[] = {
{&camera_encoder, TIM_CHANNEL_1 | TIM_CHANNEL_2}, //
{&driven_encoder_gear, TIM_CHANNEL_1 | TIM_CHANNEL_2} //
// {&driven_encoder_gear, TIM_CHANNEL_1 | TIM_CHANNEL_2} //
};
void encoder_all_start(void)

35
usersrc/usermain.c

@ -98,24 +98,39 @@ void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin)
}
}
void HAL_TIM_IC_CaptureCallback(TIM_HandleTypeDef *htim)
{
if (htim->Channel == HAL_TIM_ACTIVE_CHANNEL_1)
{
printf("channel 1\r\n");
}
else if (htim->Channel == HAL_TIM_ACTIVE_CHANNEL_2)
{
printf("channel 2\r\n");
}
}
void user_main()
{
printf("==============ethernet_sound_acquisition_card=============\r\n");
printf("version %d.%d", VERSION_MAIN_ID, VERSION_SUB_ID);
encoder_all_start();
udp_client_init();
zkey_init(&s_key_module);
port_uart_start_all_uart_receive();
HAL_TIM_IC_Start_IT(&htim4, TIM_CHANNEL_1); //
HAL_TIM_IC_Start_IT(&htim4, TIM_CHANNEL_2); //
// encoder_all_start();
// udp_client_init();
// zkey_init(&s_key_module);
// port_uart_start_all_uart_receive();
while (1)
{
udp_client_genlock_and_esync_active();
udp_client_active();
zkey_schedule();
udp_client_recv();
at_cmd_processer_try_process_data();
encoder_light_schedule();
// udp_client_genlock_and_esync_active();
// udp_client_active();
// zkey_schedule();
// udp_client_recv();
// at_cmd_processer_try_process_data();
// encoder_light_schedule();
port_do_debug_light_state();
osDelay(1);
}

Loading…
Cancel
Save