HT-Hawk飞控源代码技术资料.zip
立即下载
资源介绍:
HT-Hawk飞控源代码技术资料.zip
; generated by Component: ARM Compiler 5.06 update 6 (build 750) Tool: ArmCC [4d3637]
; commandline ArmCC [--c99 --list --split_sections --debug -c --asm --interleave -o.\flash\obj\stm32f10x_tim.o --asm_dir=.\Flash\List\ --list_dir=.\Flash\List\ --depend=.\flash\obj\stm32f10x_tim.d --cpu=Cortex-M3 --apcs=interwork -O0 --diag_suppress=9931 -I..\..\Libraries\CMSIS\CM3\CoreSupport -I..\..\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x -I..\..\Libraries\STM32F10x_StdPeriph_Driver\inc -I..\..\Libraries\STM32_USB-FS-Device_Driver\inc -I..\..\User\usb_virture_com -I..\..\User -I..\..\User\bsp -I..\..\User\Driver\IIC -I..\..\User\Driver\LED -I..\..\User\Driver\TIM -I..\..\User\Driver\SPI -I..\..\User\Driver\ADC -I..\..\User\Driver\Delay -I..\..\User\Driver\UART -I..\..\User\Driver\MOTOR -I..\..\User\Driver\PWM_IN -I..\..\User\Driver\EEPROM -I..\..\User\Modules\Modules_mpu6050 -I..\..\User\Modules\Modules_nrf24L01 -I..\..\User\Modules\Modules_hmc5883 -I..\..\User\Algorithm\Algorithm_filter -I..\..\User\Algorithm\Algorithm_math -I..\..\User\Algorithm\Algorithm_sqLite -I..\..\User\Algorithm\Algorithm_quaternion -I..\..\User\Function\MultiRotor_rc -I..\..\User\Function\MultiRotor_app -I..\..\User\Function\MultiRotor_ahrs -I..\..\User\Function\MultiRotor_radio -I..\..\User\Function\MultiRotor_control -I..\..\User\Modules\Modules_oled -I..\..\User\Driver\STMFLASH -I.\RTE\_Flash -IC:\Keil_v5\ARM\CMSIS\5.7.0\CMSIS\Core\Include -IC:\Keil_v5\Keil\STM32F1xx_DFP\2.1.0\Device\Include -D__MICROLIB -D__UVISION_VERSION=530 -D_RTE_ -DSTM32F10X_HD -D_RTE_ -DSTM32F10X_HD -DUSE_STDPERIPH_DRIVER --omf_browse=.\flash\obj\stm32f10x_tim.crf ..\..\Libraries\STM32F10x_StdPeriph_Driver\src\stm32f10x_tim.c]
THUMB
AREA ||i.TI1_Config||, CODE, READONLY, ALIGN=2
TI1_Config PROC
;;;2700 */
;;;2701 static void TI1_Config(TIM_TypeDef* TIMx, uint16_t TIM_ICPolarity, uint16_t TIM_ICSelection,
000000 b5f0 PUSH {r4-r7,lr}
;;;2702 uint16_t TIM_ICFilter)
;;;2703 {
000002 460c MOV r4,r1
000004 4615 MOV r5,r2
;;;2704 uint16_t tmpccmr1 = 0, tmpccer = 0;
000006 2200 MOVS r2,#0
000008 2100 MOVS r1,#0
;;;2705 /* Disable the Channel 1: Reset the CC1E Bit */
;;;2706 TIMx->CCER &= (uint16_t)~((uint16_t)TIM_CCER_CC1E);
00000a 8c06 LDRH r6,[r0,#0x20]
00000c f64f77fe MOV r7,#0xfffe
000010 403e ANDS r6,r6,r7
000012 8406 STRH r6,[r0,#0x20]
;;;2707 tmpccmr1 = TIMx->CCMR1;
000014 8b02 LDRH r2,[r0,#0x18]
;;;2708 tmpccer = TIMx->CCER;
000016 8c01 LDRH r1,[r0,#0x20]
;;;2709 /* Select the Input and set the filter */
;;;2710 tmpccmr1 &= (uint16_t)(((uint16_t)~((uint16_t)TIM_CCMR1_CC1S)) & ((uint16_t)~((uint16_t)TIM_CCMR1_IC1F)));
000018 f64f760c MOV r6,#0xff0c
00001c 4032 ANDS r2,r2,r6
;;;2711 tmpccmr1 |= (uint16_t)(TIM_ICSelection | (uint16_t)(TIM_ICFilter << (uint16_t)4));
00001e 1c7e ADDS r6,r7,#1
000020 ea061603 AND r6,r6,r3,LSL #4
000024 432e ORRS r6,r6,r5
000026 4332 ORRS r2,r2,r6
;;;2712
;;;2713 if((TIMx == TIM1) || (TIMx == TIM8) || (TIMx == TIM2) || (TIMx == TIM3) ||
000028 4e10 LDR r6,|L1.108|
00002a 42b0 CMP r0,r6
00002c d00e BEQ |L1.76|
00002e 4e10 LDR r6,|L1.112|
000030 42b0 CMP r0,r6
000032 d00b BEQ |L1.76|
000034 f1b04f80 CMP r0,#0x40000000
000038 d008 BEQ |L1.76|
00003a 4e0e LDR r6,|L1.116|
00003c 42b0 CMP r0,r6
00003e d005 BEQ |L1.76|
;;;2714 (TIMx == TIM4) ||(TIMx == TIM5))
000040 4e0d LDR r6,|L1.120|
000042 42b0 CMP r0,r6
000044 d002 BEQ |L1.76|
000046 4e0d LDR r6,|L1.124|
000048 42b0 CMP r0,r6
00004a d106 BNE |L1.90|
|L1.76|
;;;2715 {
;;;2716 /* Select the Polarity and set the CC1E Bit */
;;;2717 tmpccer &= (uint16_t)~((uint16_t)(TIM_CCER_CC1P));
00004c f64f76fd MOV r6,#0xfffd
000050 4031 ANDS r1,r1,r6
;;;2718 tmpccer |= (uint16_t)(TIM_ICPolarity | (uint16_t)TIM_CCER_CC1E);
000052 f0440601 ORR r6,r4,#1
000056 4331 ORRS r1,r1,r6
000058 e005 B |L1.102|
|L1.90|
;;;2719 }
;;;2720 else
;;;2721 {
;;;2722 /* Select the Polarity and set the CC1E Bit */
;;;2723 tmpccer &= (uint16_t)~((uint16_t)(TIM_CCER_CC1P | TIM_CCER_CC1NP));
00005a f64f76f5 MOV r6,#0xfff5
00005e 4031 ANDS r1,r1,r6
;;;2724 tmpccer |= (uint16_t)(TIM_ICPolarity | (uint16_t)TIM_CCER_CC1E);
000060 f0440601 ORR r6,r4,#1
000064 4331 ORRS r1,r1,r6
|L1.102|
;;;2725 }
;;;2726
;;;2727 /* Write to TIMx CCMR1 and CCER registers */
;;;2728 TIMx->CCMR1 = tmpccmr1;
000066 8302 STRH r2,[r0,#0x18]
;;;2729 TIMx->CCER = tmpccer;
000068 8401 STRH r1,[r0,#0x20]
;;;2730 }
00006a bdf0 POP {r4-r7,pc}
;;;2731
ENDP
|L1.108|
DCD 0x40012c00
|L1.112|
DCD 0x40013400
|L1.116|
DCD 0x40000400
|L1.120|
DCD 0x40000800
|L1.124|
DCD 0x40000c00
AREA ||i.TI2_Config||, CODE, READONLY, ALIGN=2
TI2_Config PROC
;;;2747 */
;;;2748 static void TI2_Config(TIM_TypeDef* TIMx, uint16_t TIM_ICPolarity, uint16_t TIM_ICSelection,
000000 b5f0 PUSH {r4-r7,lr}
;;;2749 uint16_t TIM_ICFilter)
;;;2750 {
000002 460c MOV r4,r1
000004 4615 MOV r5,r2
;;;2751 uint16_t tmpccmr1 = 0, tmpccer = 0, tmp = 0;
000006 2200 MOVS r2,#0
000008 2100 MOVS r1,#0
00000a 2600 MOVS r6,#0
;;;2752 /* Disable the Channel 2: Reset the CC2E Bit */
;;;2753 TIMx->CCER &= (uint16_t)~((uint16_t)TIM_CCER_CC2E);
00000c 8c07 LDRH r7,[r0,#0x20]
00000e f64f7cef MOV r12,#0xffef
000012 ea07070c AND r7,r7,r12
000016 8407 STRH r7,[r0,#0x20]
;;;2754 tmpccmr1 = TIMx->CCMR1;
000018 8b02 LDRH r2,[r0,#0x18]
;;;2755 tmpccer = TIMx->CCER;
00001a 8c01 LDRH r1,[r0,#0x20]
;;;2756 tmp = (uint16_t)(TIM_ICPolarity << 4);
00001c f64f77ff MOV r7,#0xffff
000020 ea071604 AND r6,r7,r4,LSL #4
;;;2757 /* Select the Input and set the filter */
;;;2758 tmpccmr1 &= (uint16_t)(((uint16_t)~((uint16_t)TIM_CCMR1_CC2S)) & ((uint16_t)~((uint16_t)TIM_CCMR1_IC2F)));
000024 f64047ff MOV r7,#0xcff
000028 403a ANDS r2,r2,r7
;;;2759 tmpccmr1 |= (uint16_t)(TIM_ICFilter << 12);
00002a f64f77ff MOV r7,#0xffff
00002e ea073703 AND r7,r7,r3,LSL #12
000032 433a ORRS r2,r2,r7
;;;2760 tmpccmr1 |= (uint16_t)(TIM_ICSelection << 8);
000034 f64f77ff MOV r7,#0xffff
000038 ea072705 AND r7,r7,r5,LSL #8
00003c 433a ORRS r2,r2,r7
;;;2761
;;;2762 if((TIMx == TIM1) || (TIMx == TIM8) || (TIMx == TIM2) || (TIMx == TIM3) ||
00003e 4f11 LDR r7,|L2.132|
000040 42b8 CMP r0,r7
000042 d00e BEQ |L
资源文件列表:
![](/template/images/zip.png)
HT-Hawk飞控源代码技术资料.zip 大约有579个文件