From 44deedff4b9ed32a05b84b88f57552c43c05016f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=B4=E6=96=87=E5=B3=B0?= Date: Fri, 5 Nov 2021 00:26:34 +0800 Subject: [PATCH] =?UTF-8?q?ADC=E9=80=9A=E9=81=93=E5=A5=BD=E5=83=8F?= =?UTF-8?q?=E6=9C=89=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Core/Src/main.c | 2 +- Debug/Motor_Controller2.bin | Bin 16028 -> 16380 bytes Debug/Motor_Controller2.list | 2634 ++++++++++++++++++---------------- Debug/Motor_Controller2.map | 164 +-- Debug/my_software/my_code.su | 2 +- Motor_Controller2.ioc | 2 + my_software/my_code.c | 42 +- my_software/my_code.h | 3 +- 8 files changed, 1536 insertions(+), 1313 deletions(-) diff --git a/Core/Src/main.c b/Core/Src/main.c index 014ef6f..327bdfd 100644 --- a/Core/Src/main.c +++ b/Core/Src/main.c @@ -174,7 +174,7 @@ static void MX_ADC_Init(void) hadc.Init.EOCSelection = ADC_EOC_SINGLE_CONV; hadc.Init.LowPowerAutoWait = DISABLE; hadc.Init.LowPowerAutoPowerOff = DISABLE; - hadc.Init.ContinuousConvMode = DISABLE; + hadc.Init.ContinuousConvMode = ENABLE; hadc.Init.DiscontinuousConvMode = DISABLE; hadc.Init.ExternalTrigConv = ADC_SOFTWARE_START; hadc.Init.ExternalTrigConvEdge = ADC_EXTERNALTRIGCONVEDGE_NONE; diff --git a/Debug/Motor_Controller2.bin b/Debug/Motor_Controller2.bin index d10e1813d0c93fbe97081b5f9e87a358d0c5b43f..8bdfdaaae1fdede119a327a2df6ddfbd4d33ccae 100755 GIT binary patch delta 1979 zcmZuyeQZ-z6uWD7?s@&&^6_22@S<<`Z*}lZ8aTVo)USGx1({p|LJr-?UX?WIckxfCWJq7naU`ez zmHRq*t>Pb!JCnRP>3NR(o6MVR=0|+Vz~s;G<$h197PFB*>?2i!e{@{n zd6$|zG=1L`{)CS#YRKqz4ZK6FjkDqxupIK*kW=WDYw5S3e2_yUJM-USx}dBp=;{oqX|9|Fc8G(_lCBJ}>Y=BI4`gL*L8@ZU4+c)QpTPG) zNUCx)ud7qi0}S!09O|jHHpY_eeQ4OCZxF(;jP0--YwJVj=sMI>E5v$gxq5o2HO9Gr zxO|9hZ6`MxUDn&G4hg6qXF`48KrkfXzHq(6g7V5O;_ys08{Fu!=Z1uK<6(<6d?27I z9i+{Jr*Stn<0BB-t5}G2VL|M|!B_+b$q|oZ5)HIr>^d3tEam;h zoC|HZt}1)RcqFeU{+jPq*#d!a?yn%sDgB3*_khY0uCU z3DF^3=?q4{p-G6Ig?T1=23y0(U760=C~KAJ)0hMA#ufLdu1=Sx@o*5&m&~dnRqd25 zCoNS8;JNn;!Zo`d`;_t-tpdF@!Mo9=Pp-){(Y=R2pNSs4rYh$~Cpb7eszaR(@|u2Z z?ctz2B?snqmuFi%h?__p5#uu#yIDuAhTse~~CG5jIP1saO7lrG7Bbxv% z1=d=|opELmhSp#JPxT-?2m)D)GvR%%J|y`ouCCD@)iPC|U5ycYU~Os;3+qc3LCs;%Ci$J|6~M|0U`X=Urk6o?{n=fevRon0c}?*El!OquJG%tNV8od9 z!ze}c*~PR}BGj41z=`#EbORUpg)MsoreP?vHTq`7G+SK8HQ`}wr@0_w#Y4-1f{c@LBP`d6Elo!Ve z$^np%bAtg|EOS9<@z7$q1mh@3C(IE@sbiK3s&@b#)59NQT6rOwc0!zUb*&>&_{OnIF)~x~gC%|e}x($pm{r=;L~w-EMXf&AqJ3!64V7?{N>eKsv@TXky9IM;u-f=SV$22ZUe+_i0@3(zX3m`N z%*^@DH}}RvA0O*m5Sa8Ug!C@ z;*qnv2DkGbCvld?3_T;g#9Xl_^gWh63H6+YmhNd27}+G>ci3plLs^!DdVS?8HV4l; z4ATj*^6%&<=@p#E+}#v;huUhnsg3n z1?FI+c?jJQg>uPDS0}{_O+ywmMFSqKKniLFT$u!inuDBU=Jr{(^#D;T>^xc{`IX|H zzjOnV&>)r$577HPv>J0zaG={)?}kx7z9E{uXWY8_8hND>=e~cp6Q76r-o#R{1Go6V zf_@w(-&9)DD7%IgANjpJt79Cka>Q zXUsxbH!)|61!l;V>fDAX6(H~v-ezkF{75MVegHofn8Ic+au`_qIVf?Gty7{qZL&Bf zX7@thdcGx&8vFiH*wqrqhPb(xcc5EOEyz@`o{JEV1?qv8vb;qrwroIcr~gHFbQArEq5X{R0HgcWCiWh~P6E#p_~jsS@X>cc z2Bc)!jzjDn#{C2-s?BY98<-c|=U*JhW&t8XSQ zZoUq_$_kdZB|4nI-rl0NAATm>`y_jJpLe9t?qrIOZL+523ItWqt?dpo}$jN*9z&jF^8-&%#o1`+7?LyfK+F zrki1N4MG+Rhb#xc{s5n3)`_7~Sd=Gsf1;PcCt3z|gk84j5~!mD4}qUQy%*+R9Xq4q z+`Qv~XwKX$yq`M`A)2KWgFcc!Q`rr3i{Gf&VGjER#Y%Pa)0zuF$*|8%HTOv{w!kQL zN$mHu7E)XFT-?$nt}oR?x(SE7a+0fqKquB^O0J&KfhJs*K@ah#!x;7(VT}0`>O)#W zMXL$bwdz_Nci#eb%V2Flj: 80000e8: 4b04 ldr r3, [pc, #16] ; (80000fc ) @@ -80,7 +80,7 @@ Disassembly of section .text: 80000fa: 46c0 nop ; (mov r8, r8) 80000fc: 00000000 .word 0x00000000 8000100: 20000010 .word 0x20000010 - 8000104: 08003e18 .word 0x08003e18 + 8000104: 08003f70 .word 0x08003f70 08000108 <__udivsi3>: 8000108: 2200 movs r2, #0 @@ -526,14 +526,14 @@ void SystemClock_Config(void) 800041e: 2330 movs r3, #48 ; 0x30 8000420: 001a movs r2, r3 8000422: 2100 movs r1, #0 - 8000424: f003 fcf0 bl 8003e08 + 8000424: f003 fd9c bl 8003f60 RCC_ClkInitTypeDef RCC_ClkInitStruct = {0}; 8000428: 003b movs r3, r7 800042a: 0018 movs r0, r3 800042c: 2310 movs r3, #16 800042e: 001a movs r2, r3 8000430: 2100 movs r1, #0 - 8000432: f003 fce9 bl 8003e08 + 8000432: f003 fd95 bl 8003f60 /** Initializes the RCC Oscillators according to the specified parameters * in the RCC_OscInitTypeDef structure. @@ -645,7 +645,7 @@ static void MX_ADC_Init(void) 80004be: 230c movs r3, #12 80004c0: 001a movs r2, r3 80004c2: 2100 movs r1, #0 - 80004c4: f003 fca0 bl 8003e08 + 80004c4: f003 fd4c bl 8003f60 /* USER CODE BEGIN ADC_Init 1 */ /* USER CODE END ADC_Init 1 */ @@ -683,9 +683,9 @@ static void MX_ADC_Init(void) 80004f2: 4b22 ldr r3, [pc, #136] ; (800057c ) 80004f4: 2200 movs r2, #0 80004f6: 765a strb r2, [r3, #25] - hadc.Init.ContinuousConvMode = DISABLE; + hadc.Init.ContinuousConvMode = ENABLE; 80004f8: 4b20 ldr r3, [pc, #128] ; (800057c ) - 80004fa: 2200 movs r2, #0 + 80004fa: 2201 movs r2, #1 80004fc: 769a strb r2, [r3, #26] hadc.Init.DiscontinuousConvMode = DISABLE; 80004fe: 4b1f ldr r3, [pc, #124] ; (800057c ) @@ -854,7 +854,7 @@ static void MX_GPIO_Init(void) 80005d8: 2314 movs r3, #20 80005da: 001a movs r2, r3 80005dc: 2100 movs r1, #0 - 80005de: f003 fc13 bl 8003e08 + 80005de: f003 fcbf bl 8003f60 /* GPIO Ports Clock Enable */ __HAL_RCC_GPIOF_CLK_ENABLE(); @@ -1201,7 +1201,7 @@ void HAL_ADC_MspInit(ADC_HandleTypeDef* hadc) 80007ce: 2314 movs r3, #20 80007d0: 001a movs r2, r3 80007d2: 2100 movs r1, #0 - 80007d4: f003 fb18 bl 8003e08 + 80007d4: f003 fbc4 bl 8003f60 if(hadc->Instance==ADC1) 80007d8: 687b ldr r3, [r7, #4] 80007da: 681b ldr r3, [r3, #0] @@ -1576,7 +1576,7 @@ LoopFillZerobss: 800092a: f7ff ffe3 bl 80008f4 /* Call static constructors */ bl __libc_init_array - 800092e: f003 fa47 bl 8003dc0 <__libc_init_array> + 800092e: f003 faf3 bl 8003f18 <__libc_init_array> /* Call the application's entry point.*/ bl main 8000932: f7ff fd5f bl 80003f4
@@ -1593,7 +1593,7 @@ LoopForever: ldr r1, =_edata 8000940: 2000000c .word 0x2000000c ldr r2, =_sidata - 8000944: 08003e90 .word 0x08003e90 + 8000944: 08003ff0 .word 0x08003ff0 ldr r2, =_sbss 8000948: 2000000c .word 0x2000000c ldr r4, =_ebss @@ -4602,7 +4602,7 @@ void HAL_GPIO_EXTI_IRQHandler(uint16_t GPIO_Pin) 80018f4: 1dbb adds r3, r7, #6 80018f6: 881b ldrh r3, [r3, #0] 80018f8: 0018 movs r0, r3 - 80018fa: f002 fa3b bl 8003d74 + 80018fa: f002 fae7 bl 8003ecc } } 80018fe: 46c0 nop ; (mov r8, r8) @@ -6134,7 +6134,7 @@ HAL_StatusTypeDef HAL_RCC_ClockConfig(RCC_ClkInitTypeDef *RCC_ClkInitStruct, ui 8002104: 40021000 .word 0x40021000 8002108: 00001388 .word 0x00001388 800210c: fffff8ff .word 0xfffff8ff - 8002110: 08003e50 .word 0x08003e50 + 8002110: 08003fa8 .word 0x08003fa8 8002114: 20000000 .word 0x20000000 08002118 : @@ -6282,8 +6282,8 @@ uint32_t HAL_RCC_GetSysClockFreq(void) 80021ca: b00f add sp, #60 ; 0x3c 80021cc: bd90 pop {r4, r7, pc} 80021ce: 46c0 nop ; (mov r8, r8) - 80021d0: 08003e30 .word 0x08003e30 - 80021d4: 08003e40 .word 0x08003e40 + 80021d0: 08003f88 .word 0x08003f88 + 80021d4: 08003f98 .word 0x08003f98 80021d8: 40021000 .word 0x40021000 80021dc: 007a1200 .word 0x007a1200 @@ -6838,7 +6838,7 @@ void HAL_TIM_IRQHandler(TIM_HandleTypeDef *htim) HAL_TIM_PeriodElapsedCallback(htim); 800249e: 687b ldr r3, [r7, #4] 80024a0: 0018 movs r0, r3 - 80024a2: f001 fc77 bl 8003d94 + 80024a2: f001 fd23 bl 8003eec #endif /* USE_HAL_TIM_REGISTER_CALLBACKS */ } } @@ -9328,7 +9328,7 @@ void HT1621_Display_GetButton(void) 8003334: b004 add sp, #16 8003336: bd80 pop {r7, pc} 8003338: 20000038 .word 0x20000038 - 800333c: 08003e60 .word 0x08003e60 + 800333c: 08003fb8 .word 0x08003fb8 08003340 : @@ -9462,8 +9462,8 @@ char check_need_reset() void my_code() { - 8003418: b580 push {r7, lr} - 800341a: b088 sub sp, #32 + 8003418: b590 push {r4, r7, lr} + 800341a: b089 sub sp, #36 ; 0x24 800341c: af00 add r7, sp, #0 uint32_t runtime=0,move=0; 800341e: 2300 movs r3, #0 @@ -9491,1617 +9491,1805 @@ void my_code() 8003440: 009b lsls r3, r3, #2 8003442: 60fb str r3, [r7, #12] long countdown_set=15000; - 8003444: 4bc9 ldr r3, [pc, #804] ; (800376c ) + 8003444: 4bce ldr r3, [pc, #824] ; (8003780 ) 8003446: 60bb str r3, [r7, #8] + char moto_in1,moto_in2; + uint16_t moto_in1_pp=0,moto_in2_pp=0; + 8003448: 1d3b adds r3, r7, #4 + 800344a: 2200 movs r2, #0 + 800344c: 801a strh r2, [r3, #0] + 800344e: 1cbb adds r3, r7, #2 + 8003450: 2200 movs r2, #0 + 8003452: 801a strh r2, [r3, #0] HT1621_Init(); - 8003448: f7ff fba7 bl 8002b9a + 8003454: f7ff fba1 bl 8002b9a r480_init(); - 800344c: f000 fbe6 bl 8003c1c + 8003458: f000 fc8c bl 8003d74 config.begin=0; - 8003450: 4bc7 ldr r3, [pc, #796] ; (8003770 ) - 8003452: 2200 movs r2, #0 - 8003454: 701a strb r2, [r3, #0] - AT24CXX_Read(16,(char *)&config,sizeof(config_setting)); - 8003456: 4bc6 ldr r3, [pc, #792] ; (8003770 ) - 8003458: 2208 movs r2, #8 - 800345a: 0019 movs r1, r3 - 800345c: 2010 movs r0, #16 - 800345e: f7ff f9ce bl 80027fe + 800345c: 4bc9 ldr r3, [pc, #804] ; (8003784 ) + 800345e: 2200 movs r2, #0 + 8003460: 709a strb r2, [r3, #2] + AT24CXX_Read(32,(char *)&config,sizeof(config_setting)); + 8003462: 4bc8 ldr r3, [pc, #800] ; (8003784 ) + 8003464: 2208 movs r2, #8 + 8003466: 0019 movs r1, r3 + 8003468: 2020 movs r0, #32 + 800346a: f7ff f9c8 bl 80027fe if(config.begin!=0xab||check_need_reset()) - 8003462: 4bc3 ldr r3, [pc, #780] ; (8003770 ) - 8003464: 781b ldrb r3, [r3, #0] - 8003466: 2bab cmp r3, #171 ; 0xab - 8003468: d103 bne.n 8003472 - 800346a: f7ff ff69 bl 8003340 - 800346e: 1e03 subs r3, r0, #0 - 8003470: d006 beq.n 8003480 + 800346e: 4bc5 ldr r3, [pc, #788] ; (8003784 ) + 8003470: 789b ldrb r3, [r3, #2] + 8003472: 2bab cmp r3, #171 ; 0xab + 8003474: d103 bne.n 800347e + 8003476: f7ff ff63 bl 8003340 + 800347a: 1e03 subs r3, r0, #0 + 800347c: d006 beq.n 800348c { mode=0; - 8003472: 2317 movs r3, #23 - 8003474: 18fb adds r3, r7, r3 - 8003476: 2200 movs r2, #0 - 8003478: 701a strb r2, [r3, #0] + 800347e: 2317 movs r3, #23 + 8003480: 18fb adds r3, r7, r3 + 8003482: 2200 movs r2, #0 + 8003484: 701a strb r2, [r3, #0] r480.key=0; - 800347a: 4bbe ldr r3, [pc, #760] ; (8003774 ) - 800347c: 2200 movs r2, #0 - 800347e: 709a strb r2, [r3, #2] + 8003486: 4bc0 ldr r3, [pc, #768] ; (8003788 ) + 8003488: 2200 movs r2, #0 + 800348a: 709a strb r2, [r3, #2] + } + mode=6; + 800348c: 2317 movs r3, #23 + 800348e: 18fb adds r3, r7, r3 + 8003490: 2206 movs r2, #6 + 8003492: 701a strb r2, [r3, #0] while(1) { //get ADC for(char a=0;a<2;a++) - 8003480: 1dfb adds r3, r7, #7 - 8003482: 2200 movs r2, #0 - 8003484: 701a strb r2, [r3, #0] - 8003486: e025 b.n 80034d4 + 8003494: 1c7b adds r3, r7, #1 + 8003496: 2200 movs r2, #0 + 8003498: 701a strb r2, [r3, #0] + 800349a: e025 b.n 80034e8 { HAL_ADC_Start(&hadc); - 8003488: 4bbb ldr r3, [pc, #748] ; (8003778 ) - 800348a: 0018 movs r0, r3 - 800348c: f7fd fc2a bl 8000ce4 + 800349c: 4bbb ldr r3, [pc, #748] ; (800378c ) + 800349e: 0018 movs r0, r3 + 80034a0: f7fd fc20 bl 8000ce4 while(HAL_ADC_PollForConversion(&hadc,0xffff)!=HAL_OK); - 8003490: 46c0 nop ; (mov r8, r8) - 8003492: 4aba ldr r2, [pc, #744] ; (800377c ) - 8003494: 4bb8 ldr r3, [pc, #736] ; (8003778 ) - 8003496: 0011 movs r1, r2 - 8003498: 0018 movs r0, r3 - 800349a: f7fd fcb7 bl 8000e0c - 800349e: 1e03 subs r3, r0, #0 - 80034a0: d1f7 bne.n 8003492 + 80034a4: 46c0 nop ; (mov r8, r8) + 80034a6: 4aba ldr r2, [pc, #744] ; (8003790 ) + 80034a8: 4bb8 ldr r3, [pc, #736] ; (800378c ) + 80034aa: 0011 movs r1, r2 + 80034ac: 0018 movs r0, r3 + 80034ae: f7fd fcad bl 8000e0c + 80034b2: 1e03 subs r3, r0, #0 + 80034b4: d1f7 bne.n 80034a6 ADCC.adc_filtering[a]+=HAL_ADC_GetValue(&hadc); - 80034a2: 4bb5 ldr r3, [pc, #724] ; (8003778 ) - 80034a4: 0018 movs r0, r3 - 80034a6: f7fd fd49 bl 8000f3c - 80034aa: 0001 movs r1, r0 - 80034ac: 1dfb adds r3, r7, #7 - 80034ae: 781b ldrb r3, [r3, #0] - 80034b0: 4ab3 ldr r2, [pc, #716] ; (8003780 ) - 80034b2: 009b lsls r3, r3, #2 - 80034b4: 18d3 adds r3, r2, r3 - 80034b6: 3304 adds r3, #4 - 80034b8: 681a ldr r2, [r3, #0] - 80034ba: 1dfb adds r3, r7, #7 - 80034bc: 781b ldrb r3, [r3, #0] - 80034be: 188a adds r2, r1, r2 - 80034c0: 49af ldr r1, [pc, #700] ; (8003780 ) - 80034c2: 009b lsls r3, r3, #2 - 80034c4: 18cb adds r3, r1, r3 - 80034c6: 3304 adds r3, #4 - 80034c8: 601a str r2, [r3, #0] + 80034b6: 4bb5 ldr r3, [pc, #724] ; (800378c ) + 80034b8: 0018 movs r0, r3 + 80034ba: f7fd fd3f bl 8000f3c + 80034be: 0001 movs r1, r0 + 80034c0: 1c7b adds r3, r7, #1 + 80034c2: 781b ldrb r3, [r3, #0] + 80034c4: 4ab3 ldr r2, [pc, #716] ; (8003794 ) + 80034c6: 009b lsls r3, r3, #2 + 80034c8: 18d3 adds r3, r2, r3 + 80034ca: 3304 adds r3, #4 + 80034cc: 681a ldr r2, [r3, #0] + 80034ce: 1c7b adds r3, r7, #1 + 80034d0: 781b ldrb r3, [r3, #0] + 80034d2: 188a adds r2, r1, r2 + 80034d4: 49af ldr r1, [pc, #700] ; (8003794 ) + 80034d6: 009b lsls r3, r3, #2 + 80034d8: 18cb adds r3, r1, r3 + 80034da: 3304 adds r3, #4 + 80034dc: 601a str r2, [r3, #0] for(char a=0;a<2;a++) - 80034ca: 1dfb adds r3, r7, #7 - 80034cc: 781a ldrb r2, [r3, #0] - 80034ce: 1dfb adds r3, r7, #7 - 80034d0: 3201 adds r2, #1 - 80034d2: 701a strb r2, [r3, #0] - 80034d4: 1dfb adds r3, r7, #7 - 80034d6: 781b ldrb r3, [r3, #0] - 80034d8: 2b01 cmp r3, #1 - 80034da: d9d5 bls.n 8003488 + 80034de: 1c7b adds r3, r7, #1 + 80034e0: 781a ldrb r2, [r3, #0] + 80034e2: 1c7b adds r3, r7, #1 + 80034e4: 3201 adds r2, #1 + 80034e6: 701a strb r2, [r3, #0] + 80034e8: 1c7b adds r3, r7, #1 + 80034ea: 781b ldrb r3, [r3, #0] + 80034ec: 2b01 cmp r3, #1 + 80034ee: d9d5 bls.n 800349c } HAL_ADC_Stop(&hadc); - 80034dc: 4ba6 ldr r3, [pc, #664] ; (8003778 ) - 80034de: 0018 movs r0, r3 - 80034e0: f7fd fc54 bl 8000d8c + 80034f0: 4ba6 ldr r3, [pc, #664] ; (800378c ) + 80034f2: 0018 movs r0, r3 + 80034f4: f7fd fc4a bl 8000d8c ADCC.filtering_times+=1; - 80034e4: 4ba6 ldr r3, [pc, #664] ; (8003780 ) - 80034e6: 681b ldr r3, [r3, #0] - 80034e8: 1c5a adds r2, r3, #1 - 80034ea: 4ba5 ldr r3, [pc, #660] ; (8003780 ) - 80034ec: 601a str r2, [r3, #0] + 80034f8: 4ba6 ldr r3, [pc, #664] ; (8003794 ) + 80034fa: 681b ldr r3, [r3, #0] + 80034fc: 1c5a adds r2, r3, #1 + 80034fe: 4ba5 ldr r3, [pc, #660] ; (8003794 ) + 8003500: 601a str r2, [r3, #0] if(ADCC.filtering_times==set_filtering_times) - 80034ee: 4ba4 ldr r3, [pc, #656] ; (8003780 ) - 80034f0: 681b ldr r3, [r3, #0] - 80034f2: 2b32 cmp r3, #50 ; 0x32 - 80034f4: d11c bne.n 8003530 + 8003502: 4ba4 ldr r3, [pc, #656] ; (8003794 ) + 8003504: 681b ldr r3, [r3, #0] + 8003506: 2b32 cmp r3, #50 ; 0x32 + 8003508: d11c bne.n 8003544 { ADCC.filtering_times=0; - 80034f6: 4ba2 ldr r3, [pc, #648] ; (8003780 ) - 80034f8: 2200 movs r2, #0 - 80034fa: 601a str r2, [r3, #0] + 800350a: 4ba2 ldr r3, [pc, #648] ; (8003794 ) + 800350c: 2200 movs r2, #0 + 800350e: 601a str r2, [r3, #0] ADCC.adc_value[0]=ADCC.adc_filtering[0]/set_filtering_times; - 80034fc: 4ba0 ldr r3, [pc, #640] ; (8003780 ) - 80034fe: 685b ldr r3, [r3, #4] - 8003500: 2132 movs r1, #50 ; 0x32 - 8003502: 0018 movs r0, r3 - 8003504: f7fc fe00 bl 8000108 <__udivsi3> - 8003508: 0003 movs r3, r0 - 800350a: 001a movs r2, r3 - 800350c: 4b9c ldr r3, [pc, #624] ; (8003780 ) - 800350e: 60da str r2, [r3, #12] + 8003510: 4ba0 ldr r3, [pc, #640] ; (8003794 ) + 8003512: 685b ldr r3, [r3, #4] + 8003514: 2132 movs r1, #50 ; 0x32 + 8003516: 0018 movs r0, r3 + 8003518: f7fc fdf6 bl 8000108 <__udivsi3> + 800351c: 0003 movs r3, r0 + 800351e: 001a movs r2, r3 + 8003520: 4b9c ldr r3, [pc, #624] ; (8003794 ) + 8003522: 60da str r2, [r3, #12] ADCC.adc_filtering[0]=0; - 8003510: 4b9b ldr r3, [pc, #620] ; (8003780 ) - 8003512: 2200 movs r2, #0 - 8003514: 605a str r2, [r3, #4] + 8003524: 4b9b ldr r3, [pc, #620] ; (8003794 ) + 8003526: 2200 movs r2, #0 + 8003528: 605a str r2, [r3, #4] ADCC.adc_value[1]=ADCC.adc_filtering[1]/set_filtering_times; - 8003516: 4b9a ldr r3, [pc, #616] ; (8003780 ) - 8003518: 689b ldr r3, [r3, #8] - 800351a: 2132 movs r1, #50 ; 0x32 - 800351c: 0018 movs r0, r3 - 800351e: f7fc fdf3 bl 8000108 <__udivsi3> - 8003522: 0003 movs r3, r0 - 8003524: 001a movs r2, r3 - 8003526: 4b96 ldr r3, [pc, #600] ; (8003780 ) - 8003528: 611a str r2, [r3, #16] + 800352a: 4b9a ldr r3, [pc, #616] ; (8003794 ) + 800352c: 689b ldr r3, [r3, #8] + 800352e: 2132 movs r1, #50 ; 0x32 + 8003530: 0018 movs r0, r3 + 8003532: f7fc fde9 bl 8000108 <__udivsi3> + 8003536: 0003 movs r3, r0 + 8003538: 001a movs r2, r3 + 800353a: 4b96 ldr r3, [pc, #600] ; (8003794 ) + 800353c: 611a str r2, [r3, #16] ADCC.adc_filtering[1]=0; - 800352a: 4b95 ldr r3, [pc, #596] ; (8003780 ) - 800352c: 2200 movs r2, #0 - 800352e: 609a str r2, [r3, #8] + 800353e: 4b95 ldr r3, [pc, #596] ; (8003794 ) + 8003540: 2200 movs r2, #0 + 8003542: 609a str r2, [r3, #8] } switch(mode) - 8003530: 2317 movs r3, #23 - 8003532: 18fb adds r3, r7, r3 - 8003534: 781b ldrb r3, [r3, #0] - 8003536: 2b04 cmp r3, #4 - 8003538: d900 bls.n 800353c - 800353a: e2c3 b.n 8003ac4 - 800353c: 009a lsls r2, r3, #2 - 800353e: 4b91 ldr r3, [pc, #580] ; (8003784 ) - 8003540: 18d3 adds r3, r2, r3 - 8003542: 681b ldr r3, [r3, #0] - 8003544: 469f mov pc, r3 + 8003544: 2317 movs r3, #23 + 8003546: 18fb adds r3, r7, r3 + 8003548: 781b ldrb r3, [r3, #0] + 800354a: 2b06 cmp r3, #6 + 800354c: d900 bls.n 8003550 + 800354e: e335 b.n 8003bbc + 8003550: 009a lsls r2, r3, #2 + 8003552: 4b91 ldr r3, [pc, #580] ; (8003798 ) + 8003554: 18d3 adds r3, r2, r3 + 8003556: 681b ldr r3, [r3, #0] + 8003558: 469f mov pc, r3 { case 0: //Startup if(HAL_GetTick()>runtime) - 8003546: f7fd fa5f bl 8000a08 - 800354a: 0002 movs r2, r0 - 800354c: 69fb ldr r3, [r7, #28] - 800354e: 4293 cmp r3, r2 - 8003550: d21c bcs.n 800358c + 800355a: f7fd fa55 bl 8000a08 + 800355e: 0002 movs r2, r0 + 8003560: 69fb ldr r3, [r7, #28] + 8003562: 4293 cmp r3, r2 + 8003564: d21c bcs.n 80035a0 { runtime+=1000; - 8003552: 69fb ldr r3, [r7, #28] - 8003554: 22fa movs r2, #250 ; 0xfa - 8003556: 0092 lsls r2, r2, #2 - 8003558: 4694 mov ip, r2 - 800355a: 4463 add r3, ip - 800355c: 61fb str r3, [r7, #28] + 8003566: 69fb ldr r3, [r7, #28] + 8003568: 22fa movs r2, #250 ; 0xfa + 800356a: 0092 lsls r2, r2, #2 + 800356c: 4694 mov ip, r2 + 800356e: 4463 add r3, ip + 8003570: 61fb str r3, [r7, #28] if(dis_buff.led_run==1) - 800355e: 4b8a ldr r3, [pc, #552] ; (8003788 ) - 8003560: 7b1b ldrb r3, [r3, #12] - 8003562: 2b01 cmp r3, #1 - 8003564: d109 bne.n 800357a + 8003572: 4b8a ldr r3, [pc, #552] ; (800379c ) + 8003574: 7b1b ldrb r3, [r3, #12] + 8003576: 2b01 cmp r3, #1 + 8003578: d109 bne.n 800358e { dis_buff.led_run=0; - 8003566: 4b88 ldr r3, [pc, #544] ; (8003788 ) - 8003568: 2200 movs r2, #0 - 800356a: 731a strb r2, [r3, #12] + 800357a: 4b88 ldr r3, [pc, #544] ; (800379c ) + 800357c: 2200 movs r2, #0 + 800357e: 731a strb r2, [r3, #12] dis_buff.dot4=1; - 800356c: 4b86 ldr r3, [pc, #536] ; (8003788 ) - 800356e: 2201 movs r2, #1 - 8003570: 72da strb r2, [r3, #11] + 8003580: 4b86 ldr r3, [pc, #536] ; (800379c ) + 8003582: 2201 movs r2, #1 + 8003584: 72da strb r2, [r3, #11] dis_buff.d_num[0]=16; - 8003572: 4b85 ldr r3, [pc, #532] ; (8003788 ) - 8003574: 2210 movs r2, #16 - 8003576: 701a strb r2, [r3, #0] - 8003578: e008 b.n 800358c + 8003586: 4b85 ldr r3, [pc, #532] ; (800379c ) + 8003588: 2210 movs r2, #16 + 800358a: 701a strb r2, [r3, #0] + 800358c: e008 b.n 80035a0 }else { dis_buff.led_run=1; - 800357a: 4b83 ldr r3, [pc, #524] ; (8003788 ) - 800357c: 2201 movs r2, #1 - 800357e: 731a strb r2, [r3, #12] + 800358e: 4b83 ldr r3, [pc, #524] ; (800379c ) + 8003590: 2201 movs r2, #1 + 8003592: 731a strb r2, [r3, #12] dis_buff.dot4=0; - 8003580: 4b81 ldr r3, [pc, #516] ; (8003788 ) - 8003582: 2200 movs r2, #0 - 8003584: 72da strb r2, [r3, #11] + 8003594: 4b81 ldr r3, [pc, #516] ; (800379c ) + 8003596: 2200 movs r2, #0 + 8003598: 72da strb r2, [r3, #11] dis_buff.d_num[0]=10; - 8003586: 4b80 ldr r3, [pc, #512] ; (8003788 ) - 8003588: 220a movs r2, #10 - 800358a: 701a strb r2, [r3, #0] + 800359a: 4b80 ldr r3, [pc, #512] ; (800379c ) + 800359c: 220a movs r2, #10 + 800359e: 701a strb r2, [r3, #0] } } if(r480.key==0xd7) - 800358c: 4b79 ldr r3, [pc, #484] ; (8003774 ) - 800358e: 789b ldrb r3, [r3, #2] - 8003590: 2bd7 cmp r3, #215 ; 0xd7 - 8003592: d000 beq.n 8003596 - 8003594: e28f b.n 8003ab6 + 80035a0: 4b79 ldr r3, [pc, #484] ; (8003788 ) + 80035a2: 789b ldrb r3, [r3, #2] + 80035a4: 2bd7 cmp r3, #215 ; 0xd7 + 80035a6: d000 beq.n 80035aa + 80035a8: e301 b.n 8003bae { config.begin=0xab; - 8003596: 4b76 ldr r3, [pc, #472] ; (8003770 ) - 8003598: 22ab movs r2, #171 ; 0xab - 800359a: 701a strb r2, [r3, #0] + 80035aa: 4b76 ldr r3, [pc, #472] ; (8003784 ) + 80035ac: 22ab movs r2, #171 ; 0xab + 80035ae: 709a strb r2, [r3, #2] config.key_code[0]=r480.add[0]; - 800359c: 4b75 ldr r3, [pc, #468] ; (8003774 ) - 800359e: 781a ldrb r2, [r3, #0] - 80035a0: 4b73 ldr r3, [pc, #460] ; (8003770 ) - 80035a2: 705a strb r2, [r3, #1] - config.key_code[1]=r480.add[1]; - 80035a4: 4b73 ldr r3, [pc, #460] ; (8003774 ) - 80035a6: 785a ldrb r2, [r3, #1] - 80035a8: 4b71 ldr r3, [pc, #452] ; (8003770 ) - 80035aa: 709a strb r2, [r3, #2] - r480.key=0; - 80035ac: 4b71 ldr r3, [pc, #452] ; (8003774 ) - 80035ae: 2200 movs r2, #0 - 80035b0: 709a strb r2, [r3, #2] - r480.add[0]=0; - 80035b2: 4b70 ldr r3, [pc, #448] ; (8003774 ) - 80035b4: 2200 movs r2, #0 + 80035b0: 4b75 ldr r3, [pc, #468] ; (8003788 ) + 80035b2: 781a ldrb r2, [r3, #0] + 80035b4: 4b73 ldr r3, [pc, #460] ; (8003784 ) 80035b6: 701a strb r2, [r3, #0] + config.key_code[1]=r480.add[1]; + 80035b8: 4b73 ldr r3, [pc, #460] ; (8003788 ) + 80035ba: 785a ldrb r2, [r3, #1] + 80035bc: 4b71 ldr r3, [pc, #452] ; (8003784 ) + 80035be: 705a strb r2, [r3, #1] + r480.key=0; + 80035c0: 4b71 ldr r3, [pc, #452] ; (8003788 ) + 80035c2: 2200 movs r2, #0 + 80035c4: 709a strb r2, [r3, #2] + r480.add[0]=0; + 80035c6: 4b70 ldr r3, [pc, #448] ; (8003788 ) + 80035c8: 2200 movs r2, #0 + 80035ca: 701a strb r2, [r3, #0] r480.add[1]=0; - 80035b8: 4b6e ldr r3, [pc, #440] ; (8003774 ) - 80035ba: 2200 movs r2, #0 - 80035bc: 705a strb r2, [r3, #1] + 80035cc: 4b6e ldr r3, [pc, #440] ; (8003788 ) + 80035ce: 2200 movs r2, #0 + 80035d0: 705a strb r2, [r3, #1] mode=1; - 80035be: 2317 movs r3, #23 - 80035c0: 18fb adds r3, r7, r3 - 80035c2: 2201 movs r2, #1 - 80035c4: 701a strb r2, [r3, #0] - AT24CXX_Write(16,(char *)&config,sizeof(config_setting)); - 80035c6: 4b6a ldr r3, [pc, #424] ; (8003770 ) - 80035c8: 2208 movs r2, #8 - 80035ca: 0019 movs r1, r3 - 80035cc: 2010 movs r0, #16 - 80035ce: f7ff f93d bl 800284c + 80035d2: 2317 movs r3, #23 + 80035d4: 18fb adds r3, r7, r3 + 80035d6: 2201 movs r2, #1 + 80035d8: 701a strb r2, [r3, #0] + AT24CXX_Write(32,(char *)&config,sizeof(config_setting)); + 80035da: 4b6a ldr r3, [pc, #424] ; (8003784 ) + 80035dc: 2208 movs r2, #8 + 80035de: 0019 movs r1, r3 + 80035e0: 2020 movs r0, #32 + 80035e2: f7ff f933 bl 800284c } break; - 80035d2: e270 b.n 8003ab6 + 80035e6: e2e2 b.n 8003bae case 1: //standby moto.moto1a=0; - 80035d4: 4b6d ldr r3, [pc, #436] ; (800378c ) - 80035d6: 2200 movs r2, #0 - 80035d8: 721a strb r2, [r3, #8] + 80035e8: 4b6d ldr r3, [pc, #436] ; (80037a0 ) + 80035ea: 2200 movs r2, #0 + 80035ec: 721a strb r2, [r3, #8] moto.moto1b=0; - 80035da: 4b6c ldr r3, [pc, #432] ; (800378c ) - 80035dc: 2200 movs r2, #0 - 80035de: 725a strb r2, [r3, #9] + 80035ee: 4b6c ldr r3, [pc, #432] ; (80037a0 ) + 80035f0: 2200 movs r2, #0 + 80035f2: 725a strb r2, [r3, #9] moto.moto2a=0; - 80035e0: 4b6a ldr r3, [pc, #424] ; (800378c ) - 80035e2: 2200 movs r2, #0 - 80035e4: 729a strb r2, [r3, #10] + 80035f4: 4b6a ldr r3, [pc, #424] ; (80037a0 ) + 80035f6: 2200 movs r2, #0 + 80035f8: 729a strb r2, [r3, #10] moto.moto2b=0; - 80035e6: 4b69 ldr r3, [pc, #420] ; (800378c ) - 80035e8: 2200 movs r2, #0 - 80035ea: 72da strb r2, [r3, #11] + 80035fa: 4b69 ldr r3, [pc, #420] ; (80037a0 ) + 80035fc: 2200 movs r2, #0 + 80035fe: 72da strb r2, [r3, #11] dis_buff.d_num[0]=16; - 80035ec: 4b66 ldr r3, [pc, #408] ; (8003788 ) - 80035ee: 2210 movs r2, #16 - 80035f0: 701a strb r2, [r3, #0] + 8003600: 4b66 ldr r3, [pc, #408] ; (800379c ) + 8003602: 2210 movs r2, #16 + 8003604: 701a strb r2, [r3, #0] dis_buff.d_num[1]=16; - 80035f2: 4b65 ldr r3, [pc, #404] ; (8003788 ) - 80035f4: 2210 movs r2, #16 - 80035f6: 705a strb r2, [r3, #1] + 8003606: 4b65 ldr r3, [pc, #404] ; (800379c ) + 8003608: 2210 movs r2, #16 + 800360a: 705a strb r2, [r3, #1] dis_buff.d_num[2]=16; - 80035f8: 4b63 ldr r3, [pc, #396] ; (8003788 ) - 80035fa: 2210 movs r2, #16 - 80035fc: 709a strb r2, [r3, #2] + 800360c: 4b63 ldr r3, [pc, #396] ; (800379c ) + 800360e: 2210 movs r2, #16 + 8003610: 709a strb r2, [r3, #2] dis_buff.d_num[3]=16; - 80035fe: 4b62 ldr r3, [pc, #392] ; (8003788 ) - 8003600: 2210 movs r2, #16 - 8003602: 70da strb r2, [r3, #3] + 8003612: 4b62 ldr r3, [pc, #392] ; (800379c ) + 8003614: 2210 movs r2, #16 + 8003616: 70da strb r2, [r3, #3] dis_buff.dot1=0; - 8003604: 4b60 ldr r3, [pc, #384] ; (8003788 ) - 8003606: 2200 movs r2, #0 - 8003608: 721a strb r2, [r3, #8] + 8003618: 4b60 ldr r3, [pc, #384] ; (800379c ) + 800361a: 2200 movs r2, #0 + 800361c: 721a strb r2, [r3, #8] dis_buff.dot2=0; - 800360a: 4b5f ldr r3, [pc, #380] ; (8003788 ) - 800360c: 2200 movs r2, #0 - 800360e: 725a strb r2, [r3, #9] + 800361e: 4b5f ldr r3, [pc, #380] ; (800379c ) + 8003620: 2200 movs r2, #0 + 8003622: 725a strb r2, [r3, #9] dis_buff.dot3=0; - 8003610: 4b5d ldr r3, [pc, #372] ; (8003788 ) - 8003612: 2200 movs r2, #0 - 8003614: 729a strb r2, [r3, #10] + 8003624: 4b5d ldr r3, [pc, #372] ; (800379c ) + 8003626: 2200 movs r2, #0 + 8003628: 729a strb r2, [r3, #10] if(HAL_GetTick()>runtime) - 8003616: f7fd f9f7 bl 8000a08 - 800361a: 0002 movs r2, r0 - 800361c: 69fb ldr r3, [r7, #28] - 800361e: 4293 cmp r3, r2 - 8003620: d216 bcs.n 8003650 + 800362a: f7fd f9ed bl 8000a08 + 800362e: 0002 movs r2, r0 + 8003630: 69fb ldr r3, [r7, #28] + 8003632: 4293 cmp r3, r2 + 8003634: d216 bcs.n 8003664 { runtime+=1000; - 8003622: 69fb ldr r3, [r7, #28] - 8003624: 22fa movs r2, #250 ; 0xfa - 8003626: 0092 lsls r2, r2, #2 - 8003628: 4694 mov ip, r2 - 800362a: 4463 add r3, ip - 800362c: 61fb str r3, [r7, #28] + 8003636: 69fb ldr r3, [r7, #28] + 8003638: 22fa movs r2, #250 ; 0xfa + 800363a: 0092 lsls r2, r2, #2 + 800363c: 4694 mov ip, r2 + 800363e: 4463 add r3, ip + 8003640: 61fb str r3, [r7, #28] if(dis_buff.led_run==1) - 800362e: 4b56 ldr r3, [pc, #344] ; (8003788 ) - 8003630: 7b1b ldrb r3, [r3, #12] - 8003632: 2b01 cmp r3, #1 - 8003634: d106 bne.n 8003644 + 8003642: 4b56 ldr r3, [pc, #344] ; (800379c ) + 8003644: 7b1b ldrb r3, [r3, #12] + 8003646: 2b01 cmp r3, #1 + 8003648: d106 bne.n 8003658 { dis_buff.led_run=0; - 8003636: 4b54 ldr r3, [pc, #336] ; (8003788 ) - 8003638: 2200 movs r2, #0 - 800363a: 731a strb r2, [r3, #12] + 800364a: 4b54 ldr r3, [pc, #336] ; (800379c ) + 800364c: 2200 movs r2, #0 + 800364e: 731a strb r2, [r3, #12] dis_buff.dot4=1; - 800363c: 4b52 ldr r3, [pc, #328] ; (8003788 ) - 800363e: 2201 movs r2, #1 - 8003640: 72da strb r2, [r3, #11] - 8003642: e005 b.n 8003650 + 8003650: 4b52 ldr r3, [pc, #328] ; (800379c ) + 8003652: 2201 movs r2, #1 + 8003654: 72da strb r2, [r3, #11] + 8003656: e005 b.n 8003664 }else { dis_buff.led_run=1; - 8003644: 4b50 ldr r3, [pc, #320] ; (8003788 ) - 8003646: 2201 movs r2, #1 - 8003648: 731a strb r2, [r3, #12] + 8003658: 4b50 ldr r3, [pc, #320] ; (800379c ) + 800365a: 2201 movs r2, #1 + 800365c: 731a strb r2, [r3, #12] dis_buff.dot4=0; - 800364a: 4b4f ldr r3, [pc, #316] ; (8003788 ) - 800364c: 2200 movs r2, #0 - 800364e: 72da strb r2, [r3, #11] + 800365e: 4b4f ldr r3, [pc, #316] ; (800379c ) + 8003660: 2200 movs r2, #0 + 8003662: 72da strb r2, [r3, #11] } } overload_times=0; - 8003650: 2314 movs r3, #20 - 8003652: 18fb adds r3, r7, r3 - 8003654: 2200 movs r2, #0 - 8003656: 801a strh r2, [r3, #0] + 8003664: 2314 movs r3, #20 + 8003666: 18fb adds r3, r7, r3 + 8003668: 2200 movs r2, #0 + 800366a: 801a strh r2, [r3, #0] if(key2.code!=0) - 8003658: 4b4d ldr r3, [pc, #308] ; (8003790 ) - 800365a: 681b ldr r3, [r3, #0] - 800365c: 2b00 cmp r3, #0 - 800365e: d011 beq.n 8003684 + 800366c: 4b4d ldr r3, [pc, #308] ; (80037a4 ) + 800366e: 681b ldr r3, [r3, #0] + 8003670: 2b00 cmp r3, #0 + 8003672: d011 beq.n 8003698 { mode=2; - 8003660: 2317 movs r3, #23 - 8003662: 18fb adds r3, r7, r3 - 8003664: 2202 movs r2, #2 - 8003666: 701a strb r2, [r3, #0] + 8003674: 2317 movs r3, #23 + 8003676: 18fb adds r3, r7, r3 + 8003678: 2202 movs r2, #2 + 800367a: 701a strb r2, [r3, #0] countdown=countdown_set; - 8003668: 68bb ldr r3, [r7, #8] - 800366a: 60fb str r3, [r7, #12] + 800367c: 68bb ldr r3, [r7, #8] + 800367e: 60fb str r3, [r7, #12] moto.moto1a=10; - 800366c: 4b47 ldr r3, [pc, #284] ; (800378c ) - 800366e: 220a movs r2, #10 - 8003670: 721a strb r2, [r3, #8] + 8003680: 4b47 ldr r3, [pc, #284] ; (80037a0 ) + 8003682: 220a movs r2, #10 + 8003684: 721a strb r2, [r3, #8] moto.moto1b=0; - 8003672: 4b46 ldr r3, [pc, #280] ; (800378c ) - 8003674: 2200 movs r2, #0 - 8003676: 725a strb r2, [r3, #9] + 8003686: 4b46 ldr r3, [pc, #280] ; (80037a0 ) + 8003688: 2200 movs r2, #0 + 800368a: 725a strb r2, [r3, #9] moto.moto2a=10; - 8003678: 4b44 ldr r3, [pc, #272] ; (800378c ) - 800367a: 220a movs r2, #10 - 800367c: 729a strb r2, [r3, #10] + 800368c: 4b44 ldr r3, [pc, #272] ; (80037a0 ) + 800368e: 220a movs r2, #10 + 8003690: 729a strb r2, [r3, #10] moto.moto2b=0; - 800367e: 4b43 ldr r3, [pc, #268] ; (800378c ) - 8003680: 2200 movs r2, #0 - 8003682: 72da strb r2, [r3, #11] + 8003692: 4b43 ldr r3, [pc, #268] ; (80037a0 ) + 8003694: 2200 movs r2, #0 + 8003696: 72da strb r2, [r3, #11] } if(key3.code!=0) - 8003684: 4b43 ldr r3, [pc, #268] ; (8003794 ) - 8003686: 681b ldr r3, [r3, #0] - 8003688: 2b00 cmp r3, #0 - 800368a: d011 beq.n 80036b0 + 8003698: 4b43 ldr r3, [pc, #268] ; (80037a8 ) + 800369a: 681b ldr r3, [r3, #0] + 800369c: 2b00 cmp r3, #0 + 800369e: d011 beq.n 80036c4 { moto.moto1a=0; - 800368c: 4b3f ldr r3, [pc, #252] ; (800378c ) - 800368e: 2200 movs r2, #0 - 8003690: 721a strb r2, [r3, #8] + 80036a0: 4b3f ldr r3, [pc, #252] ; (80037a0 ) + 80036a2: 2200 movs r2, #0 + 80036a4: 721a strb r2, [r3, #8] moto.moto1b=10; - 8003692: 4b3e ldr r3, [pc, #248] ; (800378c ) - 8003694: 220a movs r2, #10 - 8003696: 725a strb r2, [r3, #9] + 80036a6: 4b3e ldr r3, [pc, #248] ; (80037a0 ) + 80036a8: 220a movs r2, #10 + 80036aa: 725a strb r2, [r3, #9] moto.moto2a=0; - 8003698: 4b3c ldr r3, [pc, #240] ; (800378c ) - 800369a: 2200 movs r2, #0 - 800369c: 729a strb r2, [r3, #10] + 80036ac: 4b3c ldr r3, [pc, #240] ; (80037a0 ) + 80036ae: 2200 movs r2, #0 + 80036b0: 729a strb r2, [r3, #10] moto.moto2b=10; - 800369e: 4b3b ldr r3, [pc, #236] ; (800378c ) - 80036a0: 220a movs r2, #10 - 80036a2: 72da strb r2, [r3, #11] + 80036b2: 4b3b ldr r3, [pc, #236] ; (80037a0 ) + 80036b4: 220a movs r2, #10 + 80036b6: 72da strb r2, [r3, #11] mode=3; - 80036a4: 2317 movs r3, #23 - 80036a6: 18fb adds r3, r7, r3 - 80036a8: 2203 movs r2, #3 - 80036aa: 701a strb r2, [r3, #0] + 80036b8: 2317 movs r3, #23 + 80036ba: 18fb adds r3, r7, r3 + 80036bc: 2203 movs r2, #3 + 80036be: 701a strb r2, [r3, #0] countdown=countdown_set; - 80036ac: 68bb ldr r3, [r7, #8] - 80036ae: 60fb str r3, [r7, #12] + 80036c0: 68bb ldr r3, [r7, #8] + 80036c2: 60fb str r3, [r7, #12] } if(key1.code!=0) - 80036b0: 4b39 ldr r3, [pc, #228] ; (8003798 ) - 80036b2: 681b ldr r3, [r3, #0] - 80036b4: 2b00 cmp r3, #0 - 80036b6: d100 bne.n 80036ba - 80036b8: e1ff b.n 8003aba + 80036c4: 4b39 ldr r3, [pc, #228] ; (80037ac ) + 80036c6: 681b ldr r3, [r3, #0] + 80036c8: 2b00 cmp r3, #0 + 80036ca: d100 bne.n 80036ce + 80036cc: e271 b.n 8003bb2 { mode=4; - 80036ba: 2317 movs r3, #23 - 80036bc: 18fb adds r3, r7, r3 - 80036be: 2204 movs r2, #4 - 80036c0: 701a strb r2, [r3, #0] + 80036ce: 2317 movs r3, #23 + 80036d0: 18fb adds r3, r7, r3 + 80036d2: 2204 movs r2, #4 + 80036d4: 701a strb r2, [r3, #0] countdown=10000; - 80036c2: 4b36 ldr r3, [pc, #216] ; (800379c ) - 80036c4: 60fb str r3, [r7, #12] + 80036d6: 4b36 ldr r3, [pc, #216] ; (80037b0 ) + 80036d8: 60fb str r3, [r7, #12] } break; - 80036c6: e1f8 b.n 8003aba + 80036da: e26a b.n 8003bb2 case 2: if(HAL_GetTick()>move) - 80036c8: f7fd f99e bl 8000a08 - 80036cc: 0002 movs r2, r0 - 80036ce: 69bb ldr r3, [r7, #24] - 80036d0: 4293 cmp r3, r2 - 80036d2: d219 bcs.n 8003708 + 80036dc: f7fd f994 bl 8000a08 + 80036e0: 0002 movs r2, r0 + 80036e2: 69bb ldr r3, [r7, #24] + 80036e4: 4293 cmp r3, r2 + 80036e6: d219 bcs.n 800371c { move=HAL_GetTick()+100; - 80036d4: f7fd f998 bl 8000a08 - 80036d8: 0003 movs r3, r0 - 80036da: 3364 adds r3, #100 ; 0x64 - 80036dc: 61bb str r3, [r7, #24] + 80036e8: f7fd f98e bl 8000a08 + 80036ec: 0003 movs r3, r0 + 80036ee: 3364 adds r3, #100 ; 0x64 + 80036f0: 61bb str r3, [r7, #24] if(dis_buff.led_run==1) - 80036de: 4b2a ldr r3, [pc, #168] ; (8003788 ) - 80036e0: 7b1b ldrb r3, [r3, #12] - 80036e2: 2b01 cmp r3, #1 - 80036e4: d103 bne.n 80036ee + 80036f2: 4b2a ldr r3, [pc, #168] ; (800379c ) + 80036f4: 7b1b ldrb r3, [r3, #12] + 80036f6: 2b01 cmp r3, #1 + 80036f8: d103 bne.n 8003702 { dis_buff.led_run=0; - 80036e6: 4b28 ldr r3, [pc, #160] ; (8003788 ) - 80036e8: 2200 movs r2, #0 - 80036ea: 731a strb r2, [r3, #12] - 80036ec: e002 b.n 80036f4 + 80036fa: 4b28 ldr r3, [pc, #160] ; (800379c ) + 80036fc: 2200 movs r2, #0 + 80036fe: 731a strb r2, [r3, #12] + 8003700: e002 b.n 8003708 }else { dis_buff.led_run=1; - 80036ee: 4b26 ldr r3, [pc, #152] ; (8003788 ) - 80036f0: 2201 movs r2, #1 - 80036f2: 731a strb r2, [r3, #12] + 8003702: 4b26 ldr r3, [pc, #152] ; (800379c ) + 8003704: 2201 movs r2, #1 + 8003706: 731a strb r2, [r3, #12] } countdown-=100; - 80036f4: 68fb ldr r3, [r7, #12] - 80036f6: 3b64 subs r3, #100 ; 0x64 - 80036f8: 60fb str r3, [r7, #12] + 8003708: 68fb ldr r3, [r7, #12] + 800370a: 3b64 subs r3, #100 ; 0x64 + 800370c: 60fb str r3, [r7, #12] if(countdown<0) - 80036fa: 68fb ldr r3, [r7, #12] - 80036fc: 2b00 cmp r3, #0 - 80036fe: da03 bge.n 8003708 + 800370e: 68fb ldr r3, [r7, #12] + 8003710: 2b00 cmp r3, #0 + 8003712: da03 bge.n 800371c { mode=1; - 8003700: 2317 movs r3, #23 - 8003702: 18fb adds r3, r7, r3 - 8003704: 2201 movs r2, #1 - 8003706: 701a strb r2, [r3, #0] + 8003714: 2317 movs r3, #23 + 8003716: 18fb adds r3, r7, r3 + 8003718: 2201 movs r2, #1 + 800371a: 701a strb r2, [r3, #0] } } dis_buff.d_num[3]=(countdown/100)%10; - 8003708: 68fb ldr r3, [r7, #12] - 800370a: 2164 movs r1, #100 ; 0x64 - 800370c: 0018 movs r0, r3 - 800370e: f7fc fd85 bl 800021c <__divsi3> - 8003712: 0003 movs r3, r0 - 8003714: 210a movs r1, #10 - 8003716: 0018 movs r0, r3 - 8003718: f7fc fe66 bl 80003e8 <__aeabi_idivmod> - 800371c: 000b movs r3, r1 - 800371e: b2da uxtb r2, r3 - 8003720: 4b19 ldr r3, [pc, #100] ; (8003788 ) - 8003722: 70da strb r2, [r3, #3] - dis_buff.d_num[2]=(countdown/1000)%10; - 8003724: 68fb ldr r3, [r7, #12] - 8003726: 22fa movs r2, #250 ; 0xfa - 8003728: 0091 lsls r1, r2, #2 + 800371c: 68fb ldr r3, [r7, #12] + 800371e: 2164 movs r1, #100 ; 0x64 + 8003720: 0018 movs r0, r3 + 8003722: f7fc fd7b bl 800021c <__divsi3> + 8003726: 0003 movs r3, r0 + 8003728: 210a movs r1, #10 800372a: 0018 movs r0, r3 - 800372c: f7fc fd76 bl 800021c <__divsi3> - 8003730: 0003 movs r3, r0 - 8003732: 210a movs r1, #10 - 8003734: 0018 movs r0, r3 - 8003736: f7fc fe57 bl 80003e8 <__aeabi_idivmod> - 800373a: 000b movs r3, r1 - 800373c: b2da uxtb r2, r3 - 800373e: 4b12 ldr r3, [pc, #72] ; (8003788 ) - 8003740: 709a strb r2, [r3, #2] + 800372c: f7fc fe5c bl 80003e8 <__aeabi_idivmod> + 8003730: 000b movs r3, r1 + 8003732: b2da uxtb r2, r3 + 8003734: 4b19 ldr r3, [pc, #100] ; (800379c ) + 8003736: 70da strb r2, [r3, #3] + dis_buff.d_num[2]=(countdown/1000)%10; + 8003738: 68fb ldr r3, [r7, #12] + 800373a: 22fa movs r2, #250 ; 0xfa + 800373c: 0091 lsls r1, r2, #2 + 800373e: 0018 movs r0, r3 + 8003740: f7fc fd6c bl 800021c <__divsi3> + 8003744: 0003 movs r3, r0 + 8003746: 210a movs r1, #10 + 8003748: 0018 movs r0, r3 + 800374a: f7fc fe4d bl 80003e8 <__aeabi_idivmod> + 800374e: 000b movs r3, r1 + 8003750: b2da uxtb r2, r3 + 8003752: 4b12 ldr r3, [pc, #72] ; (800379c ) + 8003754: 709a strb r2, [r3, #2] dis_buff.d_num[1]=((countdown/10000)%10); - 8003742: 68fb ldr r3, [r7, #12] - 8003744: 4915 ldr r1, [pc, #84] ; (800379c ) - 8003746: 0018 movs r0, r3 - 8003748: f7fc fd68 bl 800021c <__divsi3> - 800374c: 0003 movs r3, r0 - 800374e: 210a movs r1, #10 - 8003750: 0018 movs r0, r3 - 8003752: f7fc fe49 bl 80003e8 <__aeabi_idivmod> - 8003756: 000b movs r3, r1 - 8003758: b2da uxtb r2, r3 - 800375a: 4b0b ldr r3, [pc, #44] ; (8003788 ) - 800375c: 705a strb r2, [r3, #1] + 8003756: 68fb ldr r3, [r7, #12] + 8003758: 4915 ldr r1, [pc, #84] ; (80037b0 ) + 800375a: 0018 movs r0, r3 + 800375c: f7fc fd5e bl 800021c <__divsi3> + 8003760: 0003 movs r3, r0 + 8003762: 210a movs r1, #10 + 8003764: 0018 movs r0, r3 + 8003766: f7fc fe3f bl 80003e8 <__aeabi_idivmod> + 800376a: 000b movs r3, r1 + 800376c: b2da uxtb r2, r3 + 800376e: 4b0b ldr r3, [pc, #44] ; (800379c ) + 8003770: 705a strb r2, [r3, #1] dis_buff.d_num[1]=dis_buff.d_num[1]==0?16:dis_buff.d_num[1]; - 800375e: 4b0a ldr r3, [pc, #40] ; (8003788 ) - 8003760: 785b ldrb r3, [r3, #1] - 8003762: 2b00 cmp r3, #0 - 8003764: d01c beq.n 80037a0 - 8003766: 4b08 ldr r3, [pc, #32] ; (8003788 ) - 8003768: 785a ldrb r2, [r3, #1] - 800376a: e01a b.n 80037a2 - 800376c: 00003a98 .word 0x00003a98 - 8003770: 20000164 .word 0x20000164 - 8003774: 200000f8 .word 0x200000f8 - 8003778: 20000094 .word 0x20000094 - 800377c: 0000ffff .word 0x0000ffff - 8003780: 20000130 .word 0x20000130 - 8003784: 08003e74 .word 0x08003e74 - 8003788: 20000038 .word 0x20000038 - 800378c: 20000154 .word 0x20000154 - 8003790: 20000144 .word 0x20000144 - 8003794: 20000120 .word 0x20000120 - 8003798: 20000100 .word 0x20000100 - 800379c: 00002710 .word 0x00002710 - 80037a0: 2210 movs r2, #16 - 80037a2: 4bd7 ldr r3, [pc, #860] ; (8003b00 ) - 80037a4: 705a strb r2, [r3, #1] + 8003772: 4b0a ldr r3, [pc, #40] ; (800379c ) + 8003774: 785b ldrb r3, [r3, #1] + 8003776: 2b00 cmp r3, #0 + 8003778: d01c beq.n 80037b4 + 800377a: 4b08 ldr r3, [pc, #32] ; (800379c ) + 800377c: 785a ldrb r2, [r3, #1] + 800377e: e01a b.n 80037b6 + 8003780: 00003a98 .word 0x00003a98 + 8003784: 20000164 .word 0x20000164 + 8003788: 200000f8 .word 0x200000f8 + 800378c: 20000094 .word 0x20000094 + 8003790: 0000ffff .word 0x0000ffff + 8003794: 20000130 .word 0x20000130 + 8003798: 08003fcc .word 0x08003fcc + 800379c: 20000038 .word 0x20000038 + 80037a0: 20000154 .word 0x20000154 + 80037a4: 20000144 .word 0x20000144 + 80037a8: 20000120 .word 0x20000120 + 80037ac: 20000100 .word 0x20000100 + 80037b0: 00002710 .word 0x00002710 + 80037b4: 2210 movs r2, #16 + 80037b6: 4bd0 ldr r3, [pc, #832] ; (8003af8 ) + 80037b8: 705a strb r2, [r3, #1] dis_buff.dot4=1; - 80037a6: 4bd6 ldr r3, [pc, #856] ; (8003b00 ) - 80037a8: 2201 movs r2, #1 - 80037aa: 72da strb r2, [r3, #11] + 80037ba: 4bcf ldr r3, [pc, #828] ; (8003af8 ) + 80037bc: 2201 movs r2, #1 + 80037be: 72da strb r2, [r3, #11] if(key3.code!=0) - 80037ac: 4bd5 ldr r3, [pc, #852] ; (8003b04 ) - 80037ae: 681b ldr r3, [r3, #0] - 80037b0: 2b00 cmp r3, #0 - 80037b2: d013 beq.n 80037dc + 80037c0: 4bce ldr r3, [pc, #824] ; (8003afc ) + 80037c2: 681b ldr r3, [r3, #0] + 80037c4: 2b00 cmp r3, #0 + 80037c6: d013 beq.n 80037f0 { mode=3; - 80037b4: 2317 movs r3, #23 - 80037b6: 18fb adds r3, r7, r3 - 80037b8: 2203 movs r2, #3 - 80037ba: 701a strb r2, [r3, #0] + 80037c8: 2317 movs r3, #23 + 80037ca: 18fb adds r3, r7, r3 + 80037cc: 2203 movs r2, #3 + 80037ce: 701a strb r2, [r3, #0] countdown=countdown_set-countdown; - 80037bc: 68ba ldr r2, [r7, #8] - 80037be: 68fb ldr r3, [r7, #12] - 80037c0: 1ad3 subs r3, r2, r3 - 80037c2: 60fb str r3, [r7, #12] + 80037d0: 68ba ldr r2, [r7, #8] + 80037d2: 68fb ldr r3, [r7, #12] + 80037d4: 1ad3 subs r3, r2, r3 + 80037d6: 60fb str r3, [r7, #12] moto.moto1a=0; - 80037c4: 4bd0 ldr r3, [pc, #832] ; (8003b08 ) - 80037c6: 2200 movs r2, #0 - 80037c8: 721a strb r2, [r3, #8] + 80037d8: 4bc9 ldr r3, [pc, #804] ; (8003b00 ) + 80037da: 2200 movs r2, #0 + 80037dc: 721a strb r2, [r3, #8] moto.moto1b=10; - 80037ca: 4bcf ldr r3, [pc, #828] ; (8003b08 ) - 80037cc: 220a movs r2, #10 - 80037ce: 725a strb r2, [r3, #9] + 80037de: 4bc8 ldr r3, [pc, #800] ; (8003b00 ) + 80037e0: 220a movs r2, #10 + 80037e2: 725a strb r2, [r3, #9] moto.moto2a=0; - 80037d0: 4bcd ldr r3, [pc, #820] ; (8003b08 ) - 80037d2: 2200 movs r2, #0 - 80037d4: 729a strb r2, [r3, #10] + 80037e4: 4bc6 ldr r3, [pc, #792] ; (8003b00 ) + 80037e6: 2200 movs r2, #0 + 80037e8: 729a strb r2, [r3, #10] moto.moto2b=10; - 80037d6: 4bcc ldr r3, [pc, #816] ; (8003b08 ) - 80037d8: 220a movs r2, #10 - 80037da: 72da strb r2, [r3, #11] + 80037ea: 4bc5 ldr r3, [pc, #788] ; (8003b00 ) + 80037ec: 220a movs r2, #10 + 80037ee: 72da strb r2, [r3, #11] } - if(key4.code!=0) - 80037dc: 4bcb ldr r3, [pc, #812] ; (8003b0c ) - 80037de: 681b ldr r3, [r3, #0] - 80037e0: 2b00 cmp r3, #0 - 80037e2: d003 beq.n 80037ec + if(key4.code!=0||(moto_in1==1&&READ_MOT_IN1==0)) + 80037f0: 4bc4 ldr r3, [pc, #784] ; (8003b04 ) + 80037f2: 681b ldr r3, [r3, #0] + 80037f4: 2b00 cmp r3, #0 + 80037f6: d10a bne.n 800380e + 80037f8: 1dfb adds r3, r7, #7 + 80037fa: 781b ldrb r3, [r3, #0] + 80037fc: 2b01 cmp r3, #1 + 80037fe: d10a bne.n 8003816 + 8003800: 4bc1 ldr r3, [pc, #772] ; (8003b08 ) + 8003802: 2101 movs r1, #1 + 8003804: 0018 movs r0, r3 + 8003806: f7fe f82b bl 8001860 + 800380a: 1e03 subs r3, r0, #0 + 800380c: d103 bne.n 8003816 { mode=1; - 80037e4: 2317 movs r3, #23 - 80037e6: 18fb adds r3, r7, r3 - 80037e8: 2201 movs r2, #1 - 80037ea: 701a strb r2, [r3, #0] + 800380e: 2317 movs r3, #23 + 8003810: 18fb adds r3, r7, r3 + 8003812: 2201 movs r2, #1 + 8003814: 701a strb r2, [r3, #0] } if(overload.code!=0) - 80037ec: 4bc8 ldr r3, [pc, #800] ; (8003b10 ) - 80037ee: 681b ldr r3, [r3, #0] - 80037f0: 2b00 cmp r3, #0 - 80037f2: d005 beq.n 8003800 + 8003816: 4bbd ldr r3, [pc, #756] ; (8003b0c ) + 8003818: 681b ldr r3, [r3, #0] + 800381a: 2b00 cmp r3, #0 + 800381c: d005 beq.n 800382a { overload_times+=1; - 80037f4: 2214 movs r2, #20 - 80037f6: 18bb adds r3, r7, r2 - 80037f8: 18ba adds r2, r7, r2 - 80037fa: 8812 ldrh r2, [r2, #0] - 80037fc: 3201 adds r2, #1 - 80037fe: 801a strh r2, [r3, #0] + 800381e: 2214 movs r2, #20 + 8003820: 18bb adds r3, r7, r2 + 8003822: 18ba adds r2, r7, r2 + 8003824: 8812 ldrh r2, [r2, #0] + 8003826: 3201 adds r2, #1 + 8003828: 801a strh r2, [r3, #0] } if(overload2.code!=0) - 8003800: 4bc4 ldr r3, [pc, #784] ; (8003b14 ) - 8003802: 681b ldr r3, [r3, #0] - 8003804: 2b00 cmp r3, #0 - 8003806: d005 beq.n 8003814 + 800382a: 4bb9 ldr r3, [pc, #740] ; (8003b10 ) + 800382c: 681b ldr r3, [r3, #0] + 800382e: 2b00 cmp r3, #0 + 8003830: d005 beq.n 800383e { overload_times2+=1; - 8003808: 2212 movs r2, #18 - 800380a: 18bb adds r3, r7, r2 - 800380c: 18ba adds r2, r7, r2 - 800380e: 8812 ldrh r2, [r2, #0] - 8003810: 3201 adds r2, #1 - 8003812: 801a strh r2, [r3, #0] + 8003832: 2212 movs r2, #18 + 8003834: 18bb adds r3, r7, r2 + 8003836: 18ba adds r2, r7, r2 + 8003838: 8812 ldrh r2, [r2, #0] + 800383a: 3201 adds r2, #1 + 800383c: 801a strh r2, [r3, #0] } if(overload_times>2) - 8003814: 2214 movs r2, #20 - 8003816: 18bb adds r3, r7, r2 - 8003818: 881b ldrh r3, [r3, #0] - 800381a: 2b02 cmp r3, #2 - 800381c: d905 bls.n 800382a + 800383e: 2214 movs r2, #20 + 8003840: 18bb adds r3, r7, r2 + 8003842: 881b ldrh r3, [r3, #0] + 8003844: 2b02 cmp r3, #2 + 8003846: d905 bls.n 8003854 { overload_times=0; - 800381e: 18bb adds r3, r7, r2 - 8003820: 2200 movs r2, #0 - 8003822: 801a strh r2, [r3, #0] + 8003848: 18bb adds r3, r7, r2 + 800384a: 2200 movs r2, #0 + 800384c: 801a strh r2, [r3, #0] moto.moto1b=0; - 8003824: 4bb8 ldr r3, [pc, #736] ; (8003b08 ) - 8003826: 2200 movs r2, #0 - 8003828: 725a strb r2, [r3, #9] + 800384e: 4bac ldr r3, [pc, #688] ; (8003b00 ) + 8003850: 2200 movs r2, #0 + 8003852: 725a strb r2, [r3, #9] } if(overload_times2>2) - 800382a: 2212 movs r2, #18 - 800382c: 18bb adds r3, r7, r2 - 800382e: 881b ldrh r3, [r3, #0] - 8003830: 2b02 cmp r3, #2 - 8003832: d800 bhi.n 8003836 - 8003834: e143 b.n 8003abe + 8003854: 2212 movs r2, #18 + 8003856: 18bb adds r3, r7, r2 + 8003858: 881b ldrh r3, [r3, #0] + 800385a: 2b02 cmp r3, #2 + 800385c: d800 bhi.n 8003860 + 800385e: e1aa b.n 8003bb6 { overload_times2=0; - 8003836: 18bb adds r3, r7, r2 - 8003838: 2200 movs r2, #0 - 800383a: 801a strh r2, [r3, #0] + 8003860: 18bb adds r3, r7, r2 + 8003862: 2200 movs r2, #0 + 8003864: 801a strh r2, [r3, #0] moto.moto2b=0; - 800383c: 4bb2 ldr r3, [pc, #712] ; (8003b08 ) - 800383e: 2200 movs r2, #0 - 8003840: 72da strb r2, [r3, #11] + 8003866: 4ba6 ldr r3, [pc, #664] ; (8003b00 ) + 8003868: 2200 movs r2, #0 + 800386a: 72da strb r2, [r3, #11] } break; - 8003842: e13c b.n 8003abe + 800386c: e1a3 b.n 8003bb6 case 3: if(HAL_GetTick()>move) - 8003844: f7fd f8e0 bl 8000a08 - 8003848: 0002 movs r2, r0 - 800384a: 69bb ldr r3, [r7, #24] - 800384c: 4293 cmp r3, r2 - 800384e: d219 bcs.n 8003884 + 800386e: f7fd f8cb bl 8000a08 + 8003872: 0002 movs r2, r0 + 8003874: 69bb ldr r3, [r7, #24] + 8003876: 4293 cmp r3, r2 + 8003878: d219 bcs.n 80038ae { move=HAL_GetTick()+100; - 8003850: f7fd f8da bl 8000a08 - 8003854: 0003 movs r3, r0 - 8003856: 3364 adds r3, #100 ; 0x64 - 8003858: 61bb str r3, [r7, #24] + 800387a: f7fd f8c5 bl 8000a08 + 800387e: 0003 movs r3, r0 + 8003880: 3364 adds r3, #100 ; 0x64 + 8003882: 61bb str r3, [r7, #24] if(dis_buff.led_run==1) - 800385a: 4ba9 ldr r3, [pc, #676] ; (8003b00 ) - 800385c: 7b1b ldrb r3, [r3, #12] - 800385e: 2b01 cmp r3, #1 - 8003860: d103 bne.n 800386a + 8003884: 4b9c ldr r3, [pc, #624] ; (8003af8 ) + 8003886: 7b1b ldrb r3, [r3, #12] + 8003888: 2b01 cmp r3, #1 + 800388a: d103 bne.n 8003894 { dis_buff.led_run=0; - 8003862: 4ba7 ldr r3, [pc, #668] ; (8003b00 ) - 8003864: 2200 movs r2, #0 - 8003866: 731a strb r2, [r3, #12] - 8003868: e002 b.n 8003870 + 800388c: 4b9a ldr r3, [pc, #616] ; (8003af8 ) + 800388e: 2200 movs r2, #0 + 8003890: 731a strb r2, [r3, #12] + 8003892: e002 b.n 800389a }else { dis_buff.led_run=1; - 800386a: 4ba5 ldr r3, [pc, #660] ; (8003b00 ) - 800386c: 2201 movs r2, #1 - 800386e: 731a strb r2, [r3, #12] + 8003894: 4b98 ldr r3, [pc, #608] ; (8003af8 ) + 8003896: 2201 movs r2, #1 + 8003898: 731a strb r2, [r3, #12] } countdown-=100; - 8003870: 68fb ldr r3, [r7, #12] - 8003872: 3b64 subs r3, #100 ; 0x64 - 8003874: 60fb str r3, [r7, #12] + 800389a: 68fb ldr r3, [r7, #12] + 800389c: 3b64 subs r3, #100 ; 0x64 + 800389e: 60fb str r3, [r7, #12] if(countdown<0) - 8003876: 68fb ldr r3, [r7, #12] - 8003878: 2b00 cmp r3, #0 - 800387a: da03 bge.n 8003884 + 80038a0: 68fb ldr r3, [r7, #12] + 80038a2: 2b00 cmp r3, #0 + 80038a4: da03 bge.n 80038ae { mode=1; - 800387c: 2317 movs r3, #23 - 800387e: 18fb adds r3, r7, r3 - 8003880: 2201 movs r2, #1 - 8003882: 701a strb r2, [r3, #0] + 80038a6: 2317 movs r3, #23 + 80038a8: 18fb adds r3, r7, r3 + 80038aa: 2201 movs r2, #1 + 80038ac: 701a strb r2, [r3, #0] } } dis_buff.d_num[3]=(countdown/100)%10; - 8003884: 68fb ldr r3, [r7, #12] - 8003886: 2164 movs r1, #100 ; 0x64 - 8003888: 0018 movs r0, r3 - 800388a: f7fc fcc7 bl 800021c <__divsi3> - 800388e: 0003 movs r3, r0 - 8003890: 210a movs r1, #10 - 8003892: 0018 movs r0, r3 - 8003894: f7fc fda8 bl 80003e8 <__aeabi_idivmod> - 8003898: 000b movs r3, r1 - 800389a: b2da uxtb r2, r3 - 800389c: 4b98 ldr r3, [pc, #608] ; (8003b00 ) - 800389e: 70da strb r2, [r3, #3] + 80038ae: 68fb ldr r3, [r7, #12] + 80038b0: 2164 movs r1, #100 ; 0x64 + 80038b2: 0018 movs r0, r3 + 80038b4: f7fc fcb2 bl 800021c <__divsi3> + 80038b8: 0003 movs r3, r0 + 80038ba: 210a movs r1, #10 + 80038bc: 0018 movs r0, r3 + 80038be: f7fc fd93 bl 80003e8 <__aeabi_idivmod> + 80038c2: 000b movs r3, r1 + 80038c4: b2da uxtb r2, r3 + 80038c6: 4b8c ldr r3, [pc, #560] ; (8003af8 ) + 80038c8: 70da strb r2, [r3, #3] dis_buff.d_num[2]=(countdown/1000)%10; - 80038a0: 68fb ldr r3, [r7, #12] - 80038a2: 22fa movs r2, #250 ; 0xfa - 80038a4: 0091 lsls r1, r2, #2 - 80038a6: 0018 movs r0, r3 - 80038a8: f7fc fcb8 bl 800021c <__divsi3> - 80038ac: 0003 movs r3, r0 - 80038ae: 210a movs r1, #10 - 80038b0: 0018 movs r0, r3 - 80038b2: f7fc fd99 bl 80003e8 <__aeabi_idivmod> - 80038b6: 000b movs r3, r1 - 80038b8: b2da uxtb r2, r3 - 80038ba: 4b91 ldr r3, [pc, #580] ; (8003b00 ) - 80038bc: 709a strb r2, [r3, #2] + 80038ca: 68fb ldr r3, [r7, #12] + 80038cc: 22fa movs r2, #250 ; 0xfa + 80038ce: 0091 lsls r1, r2, #2 + 80038d0: 0018 movs r0, r3 + 80038d2: f7fc fca3 bl 800021c <__divsi3> + 80038d6: 0003 movs r3, r0 + 80038d8: 210a movs r1, #10 + 80038da: 0018 movs r0, r3 + 80038dc: f7fc fd84 bl 80003e8 <__aeabi_idivmod> + 80038e0: 000b movs r3, r1 + 80038e2: b2da uxtb r2, r3 + 80038e4: 4b84 ldr r3, [pc, #528] ; (8003af8 ) + 80038e6: 709a strb r2, [r3, #2] dis_buff.d_num[1]=((countdown/10000)%10); - 80038be: 68fb ldr r3, [r7, #12] - 80038c0: 4995 ldr r1, [pc, #596] ; (8003b18 ) - 80038c2: 0018 movs r0, r3 - 80038c4: f7fc fcaa bl 800021c <__divsi3> - 80038c8: 0003 movs r3, r0 - 80038ca: 210a movs r1, #10 - 80038cc: 0018 movs r0, r3 - 80038ce: f7fc fd8b bl 80003e8 <__aeabi_idivmod> - 80038d2: 000b movs r3, r1 - 80038d4: b2da uxtb r2, r3 - 80038d6: 4b8a ldr r3, [pc, #552] ; (8003b00 ) - 80038d8: 705a strb r2, [r3, #1] + 80038e8: 68fb ldr r3, [r7, #12] + 80038ea: 498a ldr r1, [pc, #552] ; (8003b14 ) + 80038ec: 0018 movs r0, r3 + 80038ee: f7fc fc95 bl 800021c <__divsi3> + 80038f2: 0003 movs r3, r0 + 80038f4: 210a movs r1, #10 + 80038f6: 0018 movs r0, r3 + 80038f8: f7fc fd76 bl 80003e8 <__aeabi_idivmod> + 80038fc: 000b movs r3, r1 + 80038fe: b2da uxtb r2, r3 + 8003900: 4b7d ldr r3, [pc, #500] ; (8003af8 ) + 8003902: 705a strb r2, [r3, #1] dis_buff.d_num[1]=dis_buff.d_num[1]==0?16:dis_buff.d_num[1]; - 80038da: 4b89 ldr r3, [pc, #548] ; (8003b00 ) - 80038dc: 785b ldrb r3, [r3, #1] - 80038de: 2b00 cmp r3, #0 - 80038e0: d002 beq.n 80038e8 - 80038e2: 4b87 ldr r3, [pc, #540] ; (8003b00 ) - 80038e4: 785a ldrb r2, [r3, #1] - 80038e6: e000 b.n 80038ea - 80038e8: 2210 movs r2, #16 - 80038ea: 4b85 ldr r3, [pc, #532] ; (8003b00 ) - 80038ec: 705a strb r2, [r3, #1] + 8003904: 4b7c ldr r3, [pc, #496] ; (8003af8 ) + 8003906: 785b ldrb r3, [r3, #1] + 8003908: 2b00 cmp r3, #0 + 800390a: d002 beq.n 8003912 + 800390c: 4b7a ldr r3, [pc, #488] ; (8003af8 ) + 800390e: 785a ldrb r2, [r3, #1] + 8003910: e000 b.n 8003914 + 8003912: 2210 movs r2, #16 + 8003914: 4b78 ldr r3, [pc, #480] ; (8003af8 ) + 8003916: 705a strb r2, [r3, #1] dis_buff.dot4=1; - 80038ee: 4b84 ldr r3, [pc, #528] ; (8003b00 ) - 80038f0: 2201 movs r2, #1 - 80038f2: 72da strb r2, [r3, #11] + 8003918: 4b77 ldr r3, [pc, #476] ; (8003af8 ) + 800391a: 2201 movs r2, #1 + 800391c: 72da strb r2, [r3, #11] if(key2.code!=0) - 80038f4: 4b89 ldr r3, [pc, #548] ; (8003b1c ) - 80038f6: 681b ldr r3, [r3, #0] - 80038f8: 2b00 cmp r3, #0 - 80038fa: d013 beq.n 8003924 + 800391e: 4b7e ldr r3, [pc, #504] ; (8003b18 ) + 8003920: 681b ldr r3, [r3, #0] + 8003922: 2b00 cmp r3, #0 + 8003924: d013 beq.n 800394e { mode=2; - 80038fc: 2317 movs r3, #23 - 80038fe: 18fb adds r3, r7, r3 - 8003900: 2202 movs r2, #2 - 8003902: 701a strb r2, [r3, #0] + 8003926: 2317 movs r3, #23 + 8003928: 18fb adds r3, r7, r3 + 800392a: 2202 movs r2, #2 + 800392c: 701a strb r2, [r3, #0] countdown=countdown_set-countdown; - 8003904: 68ba ldr r2, [r7, #8] - 8003906: 68fb ldr r3, [r7, #12] - 8003908: 1ad3 subs r3, r2, r3 - 800390a: 60fb str r3, [r7, #12] + 800392e: 68ba ldr r2, [r7, #8] + 8003930: 68fb ldr r3, [r7, #12] + 8003932: 1ad3 subs r3, r2, r3 + 8003934: 60fb str r3, [r7, #12] moto.moto1a=10; - 800390c: 4b7e ldr r3, [pc, #504] ; (8003b08 ) - 800390e: 220a movs r2, #10 - 8003910: 721a strb r2, [r3, #8] + 8003936: 4b72 ldr r3, [pc, #456] ; (8003b00 ) + 8003938: 220a movs r2, #10 + 800393a: 721a strb r2, [r3, #8] moto.moto1b=0; - 8003912: 4b7d ldr r3, [pc, #500] ; (8003b08 ) - 8003914: 2200 movs r2, #0 - 8003916: 725a strb r2, [r3, #9] + 800393c: 4b70 ldr r3, [pc, #448] ; (8003b00 ) + 800393e: 2200 movs r2, #0 + 8003940: 725a strb r2, [r3, #9] moto.moto2a=10; - 8003918: 4b7b ldr r3, [pc, #492] ; (8003b08 ) - 800391a: 220a movs r2, #10 - 800391c: 729a strb r2, [r3, #10] + 8003942: 4b6f ldr r3, [pc, #444] ; (8003b00 ) + 8003944: 220a movs r2, #10 + 8003946: 729a strb r2, [r3, #10] moto.moto2b=0; - 800391e: 4b7a ldr r3, [pc, #488] ; (8003b08 ) - 8003920: 2200 movs r2, #0 - 8003922: 72da strb r2, [r3, #11] + 8003948: 4b6d ldr r3, [pc, #436] ; (8003b00 ) + 800394a: 2200 movs r2, #0 + 800394c: 72da strb r2, [r3, #11] } - if(key4.code!=0) - 8003924: 4b79 ldr r3, [pc, #484] ; (8003b0c ) - 8003926: 681b ldr r3, [r3, #0] - 8003928: 2b00 cmp r3, #0 - 800392a: d003 beq.n 8003934 + if(key4.code!=0||(moto_in2==1&&READ_MOT_IN2==0)) + 800394e: 4b6d ldr r3, [pc, #436] ; (8003b04 ) + 8003950: 681b ldr r3, [r3, #0] + 8003952: 2b00 cmp r3, #0 + 8003954: d10a bne.n 800396c + 8003956: 1dbb adds r3, r7, #6 + 8003958: 781b ldrb r3, [r3, #0] + 800395a: 2b01 cmp r3, #1 + 800395c: d10a bne.n 8003974 + 800395e: 4b6a ldr r3, [pc, #424] ; (8003b08 ) + 8003960: 2102 movs r1, #2 + 8003962: 0018 movs r0, r3 + 8003964: f7fd ff7c bl 8001860 + 8003968: 1e03 subs r3, r0, #0 + 800396a: d103 bne.n 8003974 { mode=1; - 800392c: 2317 movs r3, #23 - 800392e: 18fb adds r3, r7, r3 - 8003930: 2201 movs r2, #1 - 8003932: 701a strb r2, [r3, #0] + 800396c: 2317 movs r3, #23 + 800396e: 18fb adds r3, r7, r3 + 8003970: 2201 movs r2, #1 + 8003972: 701a strb r2, [r3, #0] } if(overload.code!=0) - 8003934: 4b76 ldr r3, [pc, #472] ; (8003b10 ) - 8003936: 681b ldr r3, [r3, #0] - 8003938: 2b00 cmp r3, #0 - 800393a: d005 beq.n 8003948 + 8003974: 4b65 ldr r3, [pc, #404] ; (8003b0c ) + 8003976: 681b ldr r3, [r3, #0] + 8003978: 2b00 cmp r3, #0 + 800397a: d005 beq.n 8003988 { overload_times+=1; - 800393c: 2214 movs r2, #20 - 800393e: 18bb adds r3, r7, r2 - 8003940: 18ba adds r2, r7, r2 - 8003942: 8812 ldrh r2, [r2, #0] - 8003944: 3201 adds r2, #1 - 8003946: 801a strh r2, [r3, #0] + 800397c: 2214 movs r2, #20 + 800397e: 18bb adds r3, r7, r2 + 8003980: 18ba adds r2, r7, r2 + 8003982: 8812 ldrh r2, [r2, #0] + 8003984: 3201 adds r2, #1 + 8003986: 801a strh r2, [r3, #0] } if(overload2.code!=0) - 8003948: 4b72 ldr r3, [pc, #456] ; (8003b14 ) - 800394a: 681b ldr r3, [r3, #0] - 800394c: 2b00 cmp r3, #0 - 800394e: d005 beq.n 800395c + 8003988: 4b61 ldr r3, [pc, #388] ; (8003b10 ) + 800398a: 681b ldr r3, [r3, #0] + 800398c: 2b00 cmp r3, #0 + 800398e: d005 beq.n 800399c { overload_times2+=1; - 8003950: 2212 movs r2, #18 - 8003952: 18bb adds r3, r7, r2 - 8003954: 18ba adds r2, r7, r2 - 8003956: 8812 ldrh r2, [r2, #0] - 8003958: 3201 adds r2, #1 - 800395a: 801a strh r2, [r3, #0] + 8003990: 2212 movs r2, #18 + 8003992: 18bb adds r3, r7, r2 + 8003994: 18ba adds r2, r7, r2 + 8003996: 8812 ldrh r2, [r2, #0] + 8003998: 3201 adds r2, #1 + 800399a: 801a strh r2, [r3, #0] } if(overload_times>2) - 800395c: 2214 movs r2, #20 - 800395e: 18bb adds r3, r7, r2 - 8003960: 881b ldrh r3, [r3, #0] - 8003962: 2b02 cmp r3, #2 - 8003964: d905 bls.n 8003972 + 800399c: 2214 movs r2, #20 + 800399e: 18bb adds r3, r7, r2 + 80039a0: 881b ldrh r3, [r3, #0] + 80039a2: 2b02 cmp r3, #2 + 80039a4: d905 bls.n 80039b2 { overload_times=0; - 8003966: 18bb adds r3, r7, r2 - 8003968: 2200 movs r2, #0 - 800396a: 801a strh r2, [r3, #0] + 80039a6: 18bb adds r3, r7, r2 + 80039a8: 2200 movs r2, #0 + 80039aa: 801a strh r2, [r3, #0] moto.moto1b=0; - 800396c: 4b66 ldr r3, [pc, #408] ; (8003b08 ) - 800396e: 2200 movs r2, #0 - 8003970: 725a strb r2, [r3, #9] + 80039ac: 4b54 ldr r3, [pc, #336] ; (8003b00 ) + 80039ae: 2200 movs r2, #0 + 80039b0: 725a strb r2, [r3, #9] } if(overload_times2>2) - 8003972: 2212 movs r2, #18 - 8003974: 18bb adds r3, r7, r2 - 8003976: 881b ldrh r3, [r3, #0] - 8003978: 2b02 cmp r3, #2 - 800397a: d800 bhi.n 800397e - 800397c: e0a1 b.n 8003ac2 + 80039b2: 2212 movs r2, #18 + 80039b4: 18bb adds r3, r7, r2 + 80039b6: 881b ldrh r3, [r3, #0] + 80039b8: 2b02 cmp r3, #2 + 80039ba: d800 bhi.n 80039be + 80039bc: e0fd b.n 8003bba { overload_times2=0; - 800397e: 18bb adds r3, r7, r2 - 8003980: 2200 movs r2, #0 - 8003982: 801a strh r2, [r3, #0] + 80039be: 18bb adds r3, r7, r2 + 80039c0: 2200 movs r2, #0 + 80039c2: 801a strh r2, [r3, #0] moto.moto2b=0; - 8003984: 4b60 ldr r3, [pc, #384] ; (8003b08 ) - 8003986: 2200 movs r2, #0 - 8003988: 72da strb r2, [r3, #11] + 80039c4: 4b4e ldr r3, [pc, #312] ; (8003b00 ) + 80039c6: 2200 movs r2, #0 + 80039c8: 72da strb r2, [r3, #11] } break; - 800398a: e09a b.n 8003ac2 + 80039ca: e0f6 b.n 8003bba case 4: //setting mode dis_buff.led_run=0; - 800398c: 4b5c ldr r3, [pc, #368] ; (8003b00 ) - 800398e: 2200 movs r2, #0 - 8003990: 731a strb r2, [r3, #12] + 80039cc: 4b4a ldr r3, [pc, #296] ; (8003af8 ) + 80039ce: 2200 movs r2, #0 + 80039d0: 731a strb r2, [r3, #12] if(HAL_GetTick()>move) - 8003992: f7fd f839 bl 8000a08 - 8003996: 0002 movs r2, r0 - 8003998: 69bb ldr r3, [r7, #24] - 800399a: 4293 cmp r3, r2 - 800399c: d230 bcs.n 8003a00 + 80039d2: f7fd f819 bl 8000a08 + 80039d6: 0002 movs r2, r0 + 80039d8: 69bb ldr r3, [r7, #24] + 80039da: 4293 cmp r3, r2 + 80039dc: d230 bcs.n 8003a40 { move=HAL_GetTick()+100; - 800399e: f7fd f833 bl 8000a08 - 80039a2: 0003 movs r3, r0 - 80039a4: 3364 adds r3, #100 ; 0x64 - 80039a6: 61bb str r3, [r7, #24] + 80039de: f7fd f813 bl 8000a08 + 80039e2: 0003 movs r3, r0 + 80039e4: 3364 adds r3, #100 ; 0x64 + 80039e6: 61bb str r3, [r7, #24] if(dis_buff.dot4==1) - 80039a8: 4b55 ldr r3, [pc, #340] ; (8003b00 ) - 80039aa: 7adb ldrb r3, [r3, #11] - 80039ac: 2b01 cmp r3, #1 - 80039ae: d103 bne.n 80039b8 + 80039e8: 4b43 ldr r3, [pc, #268] ; (8003af8 ) + 80039ea: 7adb ldrb r3, [r3, #11] + 80039ec: 2b01 cmp r3, #1 + 80039ee: d103 bne.n 80039f8 { dis_buff.dot4=0; - 80039b0: 4b53 ldr r3, [pc, #332] ; (8003b00 ) - 80039b2: 2200 movs r2, #0 - 80039b4: 72da strb r2, [r3, #11] - 80039b6: e002 b.n 80039be + 80039f0: 4b41 ldr r3, [pc, #260] ; (8003af8 ) + 80039f2: 2200 movs r2, #0 + 80039f4: 72da strb r2, [r3, #11] + 80039f6: e002 b.n 80039fe }else { dis_buff.dot4=1; - 80039b8: 4b51 ldr r3, [pc, #324] ; (8003b00 ) - 80039ba: 2201 movs r2, #1 - 80039bc: 72da strb r2, [r3, #11] + 80039f8: 4b3f ldr r3, [pc, #252] ; (8003af8 ) + 80039fa: 2201 movs r2, #1 + 80039fc: 72da strb r2, [r3, #11] } countdown-=100; - 80039be: 68fb ldr r3, [r7, #12] - 80039c0: 3b64 subs r3, #100 ; 0x64 - 80039c2: 60fb str r3, [r7, #12] + 80039fe: 68fb ldr r3, [r7, #12] + 8003a00: 3b64 subs r3, #100 ; 0x64 + 8003a02: 60fb str r3, [r7, #12] if(countdown<0) - 80039c4: 68fb ldr r3, [r7, #12] - 80039c6: 2b00 cmp r3, #0 - 80039c8: da03 bge.n 80039d2 + 8003a04: 68fb ldr r3, [r7, #12] + 8003a06: 2b00 cmp r3, #0 + 8003a08: da03 bge.n 8003a12 { mode=1; - 80039ca: 2317 movs r3, #23 - 80039cc: 18fb adds r3, r7, r3 - 80039ce: 2201 movs r2, #1 - 80039d0: 701a strb r2, [r3, #0] + 8003a0a: 2317 movs r3, #23 + 8003a0c: 18fb adds r3, r7, r3 + 8003a0e: 2201 movs r2, #1 + 8003a10: 701a strb r2, [r3, #0] } if(key2.code<0){countdown_set+=1000;countdown=10000;} - 80039d2: 4b52 ldr r3, [pc, #328] ; (8003b1c ) - 80039d4: 681b ldr r3, [r3, #0] - 80039d6: 2b00 cmp r3, #0 - 80039d8: da07 bge.n 80039ea - 80039da: 68bb ldr r3, [r7, #8] - 80039dc: 22fa movs r2, #250 ; 0xfa - 80039de: 0092 lsls r2, r2, #2 - 80039e0: 4694 mov ip, r2 - 80039e2: 4463 add r3, ip - 80039e4: 60bb str r3, [r7, #8] - 80039e6: 4b4c ldr r3, [pc, #304] ; (8003b18 ) - 80039e8: 60fb str r3, [r7, #12] + 8003a12: 4b41 ldr r3, [pc, #260] ; (8003b18 ) + 8003a14: 681b ldr r3, [r3, #0] + 8003a16: 2b00 cmp r3, #0 + 8003a18: da07 bge.n 8003a2a + 8003a1a: 68bb ldr r3, [r7, #8] + 8003a1c: 22fa movs r2, #250 ; 0xfa + 8003a1e: 0092 lsls r2, r2, #2 + 8003a20: 4694 mov ip, r2 + 8003a22: 4463 add r3, ip + 8003a24: 60bb str r3, [r7, #8] + 8003a26: 4b3b ldr r3, [pc, #236] ; (8003b14 ) + 8003a28: 60fb str r3, [r7, #12] if(key3.code<0){countdown_set-=1000;countdown=10000;} - 80039ea: 4b46 ldr r3, [pc, #280] ; (8003b04 ) - 80039ec: 681b ldr r3, [r3, #0] - 80039ee: 2b00 cmp r3, #0 - 80039f0: da06 bge.n 8003a00 - 80039f2: 68bb ldr r3, [r7, #8] - 80039f4: 4a4a ldr r2, [pc, #296] ; (8003b20 ) - 80039f6: 4694 mov ip, r2 - 80039f8: 4463 add r3, ip - 80039fa: 60bb str r3, [r7, #8] - 80039fc: 4b46 ldr r3, [pc, #280] ; (8003b18 ) - 80039fe: 60fb str r3, [r7, #12] + 8003a2a: 4b34 ldr r3, [pc, #208] ; (8003afc ) + 8003a2c: 681b ldr r3, [r3, #0] + 8003a2e: 2b00 cmp r3, #0 + 8003a30: da06 bge.n 8003a40 + 8003a32: 68bb ldr r3, [r7, #8] + 8003a34: 4a39 ldr r2, [pc, #228] ; (8003b1c ) + 8003a36: 4694 mov ip, r2 + 8003a38: 4463 add r3, ip + 8003a3a: 60bb str r3, [r7, #8] + 8003a3c: 4b35 ldr r3, [pc, #212] ; (8003b14 ) + 8003a3e: 60fb str r3, [r7, #12] } if(key2.code>0){countdown_set+=100;countdown=10000;} - 8003a00: 4b46 ldr r3, [pc, #280] ; (8003b1c ) - 8003a02: 681b ldr r3, [r3, #0] - 8003a04: 2b00 cmp r3, #0 - 8003a06: dd04 ble.n 8003a12 - 8003a08: 68bb ldr r3, [r7, #8] - 8003a0a: 3364 adds r3, #100 ; 0x64 - 8003a0c: 60bb str r3, [r7, #8] - 8003a0e: 4b42 ldr r3, [pc, #264] ; (8003b18 ) - 8003a10: 60fb str r3, [r7, #12] + 8003a40: 4b35 ldr r3, [pc, #212] ; (8003b18 ) + 8003a42: 681b ldr r3, [r3, #0] + 8003a44: 2b00 cmp r3, #0 + 8003a46: dd04 ble.n 8003a52 + 8003a48: 68bb ldr r3, [r7, #8] + 8003a4a: 3364 adds r3, #100 ; 0x64 + 8003a4c: 60bb str r3, [r7, #8] + 8003a4e: 4b31 ldr r3, [pc, #196] ; (8003b14 ) + 8003a50: 60fb str r3, [r7, #12] if(key3.code>0){countdown_set-=100;countdown=10000;} - 8003a12: 4b3c ldr r3, [pc, #240] ; (8003b04 ) - 8003a14: 681b ldr r3, [r3, #0] - 8003a16: 2b00 cmp r3, #0 - 8003a18: dd04 ble.n 8003a24 - 8003a1a: 68bb ldr r3, [r7, #8] - 8003a1c: 3b64 subs r3, #100 ; 0x64 - 8003a1e: 60bb str r3, [r7, #8] - 8003a20: 4b3d ldr r3, [pc, #244] ; (8003b18 ) - 8003a22: 60fb str r3, [r7, #12] + 8003a52: 4b2a ldr r3, [pc, #168] ; (8003afc ) + 8003a54: 681b ldr r3, [r3, #0] + 8003a56: 2b00 cmp r3, #0 + 8003a58: dd04 ble.n 8003a64 + 8003a5a: 68bb ldr r3, [r7, #8] + 8003a5c: 3b64 subs r3, #100 ; 0x64 + 8003a5e: 60bb str r3, [r7, #8] + 8003a60: 4b2c ldr r3, [pc, #176] ; (8003b14 ) + 8003a62: 60fb str r3, [r7, #12] if(countdown_set<100){countdown_set=100;} - 8003a24: 68bb ldr r3, [r7, #8] - 8003a26: 2b63 cmp r3, #99 ; 0x63 - 8003a28: dc01 bgt.n 8003a2e - 8003a2a: 2364 movs r3, #100 ; 0x64 - 8003a2c: 60bb str r3, [r7, #8] + 8003a64: 68bb ldr r3, [r7, #8] + 8003a66: 2b63 cmp r3, #99 ; 0x63 + 8003a68: dc01 bgt.n 8003a6e + 8003a6a: 2364 movs r3, #100 ; 0x64 + 8003a6c: 60bb str r3, [r7, #8] if(countdown_set>60000){countdown_set=60000;} - 8003a2e: 68bb ldr r3, [r7, #8] - 8003a30: 4a3c ldr r2, [pc, #240] ; (8003b24 ) - 8003a32: 4293 cmp r3, r2 - 8003a34: dd01 ble.n 8003a3a - 8003a36: 4b3b ldr r3, [pc, #236] ; (8003b24 ) - 8003a38: 60bb str r3, [r7, #8] + 8003a6e: 68bb ldr r3, [r7, #8] + 8003a70: 4a2b ldr r2, [pc, #172] ; (8003b20 ) + 8003a72: 4293 cmp r3, r2 + 8003a74: dd01 ble.n 8003a7a + 8003a76: 4b2a ldr r3, [pc, #168] ; (8003b20 ) + 8003a78: 60bb str r3, [r7, #8] if(key4.code!=0){mode=1;} - 8003a3a: 4b34 ldr r3, [pc, #208] ; (8003b0c ) - 8003a3c: 681b ldr r3, [r3, #0] - 8003a3e: 2b00 cmp r3, #0 - 8003a40: d003 beq.n 8003a4a - 8003a42: 2317 movs r3, #23 - 8003a44: 18fb adds r3, r7, r3 - 8003a46: 2201 movs r2, #1 - 8003a48: 701a strb r2, [r3, #0] + 8003a7a: 4b22 ldr r3, [pc, #136] ; (8003b04 ) + 8003a7c: 681b ldr r3, [r3, #0] + 8003a7e: 2b00 cmp r3, #0 + 8003a80: d003 beq.n 8003a8a + 8003a82: 2317 movs r3, #23 + 8003a84: 18fb adds r3, r7, r3 + 8003a86: 2201 movs r2, #1 + 8003a88: 701a strb r2, [r3, #0] dis_buff.d_num[3]=(countdown_set/100)%10; - 8003a4a: 68bb ldr r3, [r7, #8] - 8003a4c: 2164 movs r1, #100 ; 0x64 - 8003a4e: 0018 movs r0, r3 - 8003a50: f7fc fbe4 bl 800021c <__divsi3> - 8003a54: 0003 movs r3, r0 - 8003a56: 210a movs r1, #10 - 8003a58: 0018 movs r0, r3 - 8003a5a: f7fc fcc5 bl 80003e8 <__aeabi_idivmod> - 8003a5e: 000b movs r3, r1 - 8003a60: b2da uxtb r2, r3 - 8003a62: 4b27 ldr r3, [pc, #156] ; (8003b00 ) - 8003a64: 70da strb r2, [r3, #3] + 8003a8a: 68bb ldr r3, [r7, #8] + 8003a8c: 2164 movs r1, #100 ; 0x64 + 8003a8e: 0018 movs r0, r3 + 8003a90: f7fc fbc4 bl 800021c <__divsi3> + 8003a94: 0003 movs r3, r0 + 8003a96: 210a movs r1, #10 + 8003a98: 0018 movs r0, r3 + 8003a9a: f7fc fca5 bl 80003e8 <__aeabi_idivmod> + 8003a9e: 000b movs r3, r1 + 8003aa0: b2da uxtb r2, r3 + 8003aa2: 4b15 ldr r3, [pc, #84] ; (8003af8 ) + 8003aa4: 70da strb r2, [r3, #3] dis_buff.d_num[2]=(countdown_set/1000)%10; - 8003a66: 68bb ldr r3, [r7, #8] - 8003a68: 22fa movs r2, #250 ; 0xfa - 8003a6a: 0091 lsls r1, r2, #2 - 8003a6c: 0018 movs r0, r3 - 8003a6e: f7fc fbd5 bl 800021c <__divsi3> - 8003a72: 0003 movs r3, r0 - 8003a74: 210a movs r1, #10 - 8003a76: 0018 movs r0, r3 - 8003a78: f7fc fcb6 bl 80003e8 <__aeabi_idivmod> - 8003a7c: 000b movs r3, r1 - 8003a7e: b2da uxtb r2, r3 - 8003a80: 4b1f ldr r3, [pc, #124] ; (8003b00 ) - 8003a82: 709a strb r2, [r3, #2] + 8003aa6: 68bb ldr r3, [r7, #8] + 8003aa8: 22fa movs r2, #250 ; 0xfa + 8003aaa: 0091 lsls r1, r2, #2 + 8003aac: 0018 movs r0, r3 + 8003aae: f7fc fbb5 bl 800021c <__divsi3> + 8003ab2: 0003 movs r3, r0 + 8003ab4: 210a movs r1, #10 + 8003ab6: 0018 movs r0, r3 + 8003ab8: f7fc fc96 bl 80003e8 <__aeabi_idivmod> + 8003abc: 000b movs r3, r1 + 8003abe: b2da uxtb r2, r3 + 8003ac0: 4b0d ldr r3, [pc, #52] ; (8003af8 ) + 8003ac2: 709a strb r2, [r3, #2] dis_buff.d_num[1]=((countdown_set/10000)%10); - 8003a84: 68bb ldr r3, [r7, #8] - 8003a86: 4924 ldr r1, [pc, #144] ; (8003b18 ) - 8003a88: 0018 movs r0, r3 - 8003a8a: f7fc fbc7 bl 800021c <__divsi3> - 8003a8e: 0003 movs r3, r0 - 8003a90: 210a movs r1, #10 - 8003a92: 0018 movs r0, r3 - 8003a94: f7fc fca8 bl 80003e8 <__aeabi_idivmod> - 8003a98: 000b movs r3, r1 - 8003a9a: b2da uxtb r2, r3 - 8003a9c: 4b18 ldr r3, [pc, #96] ; (8003b00 ) - 8003a9e: 705a strb r2, [r3, #1] + 8003ac4: 68bb ldr r3, [r7, #8] + 8003ac6: 4913 ldr r1, [pc, #76] ; (8003b14 ) + 8003ac8: 0018 movs r0, r3 + 8003aca: f7fc fba7 bl 800021c <__divsi3> + 8003ace: 0003 movs r3, r0 + 8003ad0: 210a movs r1, #10 + 8003ad2: 0018 movs r0, r3 + 8003ad4: f7fc fc88 bl 80003e8 <__aeabi_idivmod> + 8003ad8: 000b movs r3, r1 + 8003ada: b2da uxtb r2, r3 + 8003adc: 4b06 ldr r3, [pc, #24] ; (8003af8 ) + 8003ade: 705a strb r2, [r3, #1] dis_buff.d_num[1]=dis_buff.d_num[1]==0?16:dis_buff.d_num[1]; - 8003aa0: 4b17 ldr r3, [pc, #92] ; (8003b00 ) - 8003aa2: 785b ldrb r3, [r3, #1] - 8003aa4: 2b00 cmp r3, #0 - 8003aa6: d002 beq.n 8003aae - 8003aa8: 4b15 ldr r3, [pc, #84] ; (8003b00 ) - 8003aaa: 785a ldrb r2, [r3, #1] - 8003aac: e000 b.n 8003ab0 - 8003aae: 2210 movs r2, #16 - 8003ab0: 4b13 ldr r3, [pc, #76] ; (8003b00 ) - 8003ab2: 705a strb r2, [r3, #1] + 8003ae0: 4b05 ldr r3, [pc, #20] ; (8003af8 ) + 8003ae2: 785b ldrb r3, [r3, #1] + 8003ae4: 2b00 cmp r3, #0 + 8003ae6: d002 beq.n 8003aee + 8003ae8: 4b03 ldr r3, [pc, #12] ; (8003af8 ) + 8003aea: 785a ldrb r2, [r3, #1] + 8003aec: e000 b.n 8003af0 + 8003aee: 2210 movs r2, #16 + 8003af0: 4b01 ldr r3, [pc, #4] ; (8003af8 ) + 8003af2: 705a strb r2, [r3, #1] break; - 8003ab4: e006 b.n 8003ac4 + 8003af4: e062 b.n 8003bbc + 8003af6: 46c0 nop ; (mov r8, r8) + 8003af8: 20000038 .word 0x20000038 + 8003afc: 20000120 .word 0x20000120 + 8003b00: 20000154 .word 0x20000154 + 8003b04: 200000e8 .word 0x200000e8 + 8003b08: 48001400 .word 0x48001400 + 8003b0c: 20000110 .word 0x20000110 + 8003b10: 200000d8 .word 0x200000d8 + 8003b14: 00002710 .word 0x00002710 + 8003b18: 20000144 .word 0x20000144 + 8003b1c: fffffc18 .word 0xfffffc18 + 8003b20: 0000ea60 .word 0x0000ea60 + + case 6: + moto.moto1a=10; + 8003b24: 4b87 ldr r3, [pc, #540] ; (8003d44 ) + 8003b26: 220a movs r2, #10 + 8003b28: 721a strb r2, [r3, #8] + moto.moto1b=0; + 8003b2a: 4b86 ldr r3, [pc, #536] ; (8003d44 ) + 8003b2c: 2200 movs r2, #0 + 8003b2e: 725a strb r2, [r3, #9] + moto.moto2a=10; + 8003b30: 4b84 ldr r3, [pc, #528] ; (8003d44 ) + 8003b32: 220a movs r2, #10 + 8003b34: 729a strb r2, [r3, #10] + moto.moto2b=0; + 8003b36: 4b83 ldr r3, [pc, #524] ; (8003d44 ) + 8003b38: 2200 movs r2, #0 + 8003b3a: 72da strb r2, [r3, #11] + dis_buff.d_num[3]=(ADCC.adc_value[1])%10; + 8003b3c: 4b82 ldr r3, [pc, #520] ; (8003d48 ) + 8003b3e: 691b ldr r3, [r3, #16] + 8003b40: 210a movs r1, #10 + 8003b42: 0018 movs r0, r3 + 8003b44: f7fc fc50 bl 80003e8 <__aeabi_idivmod> + 8003b48: 000b movs r3, r1 + 8003b4a: b2da uxtb r2, r3 + 8003b4c: 4b7f ldr r3, [pc, #508] ; (8003d4c ) + 8003b4e: 70da strb r2, [r3, #3] + dis_buff.d_num[2]=(ADCC.adc_value[1]/10)%10; + 8003b50: 4b7d ldr r3, [pc, #500] ; (8003d48 ) + 8003b52: 691b ldr r3, [r3, #16] + 8003b54: 210a movs r1, #10 + 8003b56: 0018 movs r0, r3 + 8003b58: f7fc fb60 bl 800021c <__divsi3> + 8003b5c: 0003 movs r3, r0 + 8003b5e: 210a movs r1, #10 + 8003b60: 0018 movs r0, r3 + 8003b62: f7fc fc41 bl 80003e8 <__aeabi_idivmod> + 8003b66: 000b movs r3, r1 + 8003b68: b2da uxtb r2, r3 + 8003b6a: 4b78 ldr r3, [pc, #480] ; (8003d4c ) + 8003b6c: 709a strb r2, [r3, #2] + dis_buff.d_num[1]=((ADCC.adc_value[1]/100)%10); + 8003b6e: 4b76 ldr r3, [pc, #472] ; (8003d48 ) + 8003b70: 691b ldr r3, [r3, #16] + 8003b72: 2164 movs r1, #100 ; 0x64 + 8003b74: 0018 movs r0, r3 + 8003b76: f7fc fb51 bl 800021c <__divsi3> + 8003b7a: 0003 movs r3, r0 + 8003b7c: 210a movs r1, #10 + 8003b7e: 0018 movs r0, r3 + 8003b80: f7fc fc32 bl 80003e8 <__aeabi_idivmod> + 8003b84: 000b movs r3, r1 + 8003b86: b2da uxtb r2, r3 + 8003b88: 4b70 ldr r3, [pc, #448] ; (8003d4c ) + 8003b8a: 705a strb r2, [r3, #1] + dis_buff.d_num[0]=((ADCC.adc_value[1]/1000)%10); + 8003b8c: 4b6e ldr r3, [pc, #440] ; (8003d48 ) + 8003b8e: 691b ldr r3, [r3, #16] + 8003b90: 22fa movs r2, #250 ; 0xfa + 8003b92: 0091 lsls r1, r2, #2 + 8003b94: 0018 movs r0, r3 + 8003b96: f7fc fb41 bl 800021c <__divsi3> + 8003b9a: 0003 movs r3, r0 + 8003b9c: 210a movs r1, #10 + 8003b9e: 0018 movs r0, r3 + 8003ba0: f7fc fc22 bl 80003e8 <__aeabi_idivmod> + 8003ba4: 000b movs r3, r1 + 8003ba6: b2da uxtb r2, r3 + 8003ba8: 4b68 ldr r3, [pc, #416] ; (8003d4c ) + 8003baa: 701a strb r2, [r3, #0] break; - 8003ab6: 46c0 nop ; (mov r8, r8) - 8003ab8: e004 b.n 8003ac4 + 8003bac: e006 b.n 8003bbc break; - 8003aba: 46c0 nop ; (mov r8, r8) - 8003abc: e002 b.n 8003ac4 + 8003bae: 46c0 nop ; (mov r8, r8) + 8003bb0: e004 b.n 8003bbc break; - 8003abe: 46c0 nop ; (mov r8, r8) - 8003ac0: e000 b.n 8003ac4 + 8003bb2: 46c0 nop ; (mov r8, r8) + 8003bb4: e002 b.n 8003bbc break; - 8003ac2: 46c0 nop ; (mov r8, r8) + 8003bb6: 46c0 nop ; (mov r8, r8) + 8003bb8: e000 b.n 8003bbc + break; + 8003bba: 46c0 nop ; (mov r8, r8) // // break; } if(ADCC.adc_value[0]>600) - 8003ac4: 4b18 ldr r3, [pc, #96] ; (8003b28 ) - 8003ac6: 68da ldr r2, [r3, #12] - 8003ac8: 2396 movs r3, #150 ; 0x96 - 8003aca: 009b lsls r3, r3, #2 - 8003acc: 429a cmp r2, r3 - 8003ace: dd05 ble.n 8003adc + 8003bbc: 4b62 ldr r3, [pc, #392] ; (8003d48 ) + 8003bbe: 68da ldr r2, [r3, #12] + 8003bc0: 2396 movs r3, #150 ; 0x96 + 8003bc2: 009b lsls r3, r3, #2 + 8003bc4: 429a cmp r2, r3 + 8003bc6: dd05 ble.n 8003bd4 { GEI_BUTTON_CODE(&overload,1); - 8003ad0: 4b0f ldr r3, [pc, #60] ; (8003b10 ) - 8003ad2: 2101 movs r1, #1 - 8003ad4: 0018 movs r0, r3 - 8003ad6: f7fe fdcb bl 8002670 - 8003ada: e004 b.n 8003ae6 + 8003bc8: 4b61 ldr r3, [pc, #388] ; (8003d50 ) + 8003bca: 2101 movs r1, #1 + 8003bcc: 0018 movs r0, r3 + 8003bce: f7fe fd4f bl 8002670 + 8003bd2: e004 b.n 8003bde }else { GEI_BUTTON_CODE(&overload,0); - 8003adc: 4b0c ldr r3, [pc, #48] ; (8003b10 ) - 8003ade: 2100 movs r1, #0 - 8003ae0: 0018 movs r0, r3 - 8003ae2: f7fe fdc5 bl 8002670 + 8003bd4: 4b5e ldr r3, [pc, #376] ; (8003d50 ) + 8003bd6: 2100 movs r1, #0 + 8003bd8: 0018 movs r0, r3 + 8003bda: f7fe fd49 bl 8002670 } if(ADCC.adc_value[1]>600) - 8003ae6: 4b10 ldr r3, [pc, #64] ; (8003b28 ) - 8003ae8: 691a ldr r2, [r3, #16] - 8003aea: 2396 movs r3, #150 ; 0x96 - 8003aec: 009b lsls r3, r3, #2 - 8003aee: 429a cmp r2, r3 - 8003af0: dd1c ble.n 8003b2c + 8003bde: 4b5a ldr r3, [pc, #360] ; (8003d48 ) + 8003be0: 691a ldr r2, [r3, #16] + 8003be2: 2396 movs r3, #150 ; 0x96 + 8003be4: 009b lsls r3, r3, #2 + 8003be6: 429a cmp r2, r3 + 8003be8: dd05 ble.n 8003bf6 { GEI_BUTTON_CODE(&overload2,1); - 8003af2: 4b08 ldr r3, [pc, #32] ; (8003b14 ) - 8003af4: 2101 movs r1, #1 - 8003af6: 0018 movs r0, r3 - 8003af8: f7fe fdba bl 8002670 - 8003afc: e01b b.n 8003b36 - 8003afe: 46c0 nop ; (mov r8, r8) - 8003b00: 20000038 .word 0x20000038 - 8003b04: 20000120 .word 0x20000120 - 8003b08: 20000154 .word 0x20000154 - 8003b0c: 200000e8 .word 0x200000e8 - 8003b10: 20000110 .word 0x20000110 - 8003b14: 200000d8 .word 0x200000d8 - 8003b18: 00002710 .word 0x00002710 - 8003b1c: 20000144 .word 0x20000144 - 8003b20: fffffc18 .word 0xfffffc18 - 8003b24: 0000ea60 .word 0x0000ea60 - 8003b28: 20000130 .word 0x20000130 + 8003bea: 4b5a ldr r3, [pc, #360] ; (8003d54 ) + 8003bec: 2101 movs r1, #1 + 8003bee: 0018 movs r0, r3 + 8003bf0: f7fe fd3e bl 8002670 + 8003bf4: e004 b.n 8003c00 }else { GEI_BUTTON_CODE(&overload2,0); - 8003b2c: 4b33 ldr r3, [pc, #204] ; (8003bfc ) - 8003b2e: 2100 movs r1, #0 - 8003b30: 0018 movs r0, r3 - 8003b32: f7fe fd9d bl 8002670 + 8003bf6: 4b57 ldr r3, [pc, #348] ; (8003d54 ) + 8003bf8: 2100 movs r1, #0 + 8003bfa: 0018 movs r0, r3 + 8003bfc: f7fe fd38 bl 8002670 } if(r480.add[0]==config.key_code[0]&&r480.add[1]==config.key_code[1]) - 8003b36: 4b32 ldr r3, [pc, #200] ; (8003c00 ) - 8003b38: 781a ldrb r2, [r3, #0] - 8003b3a: 4b32 ldr r3, [pc, #200] ; (8003c04 ) - 8003b3c: 785b ldrb r3, [r3, #1] - 8003b3e: 429a cmp r2, r3 - 8003b40: d122 bne.n 8003b88 - 8003b42: 4b2f ldr r3, [pc, #188] ; (8003c00 ) - 8003b44: 785a ldrb r2, [r3, #1] - 8003b46: 4b2f ldr r3, [pc, #188] ; (8003c04 ) - 8003b48: 789b ldrb r3, [r3, #2] - 8003b4a: 429a cmp r2, r3 - 8003b4c: d11c bne.n 8003b88 + 8003c00: 4b55 ldr r3, [pc, #340] ; (8003d58 ) + 8003c02: 781a ldrb r2, [r3, #0] + 8003c04: 4b55 ldr r3, [pc, #340] ; (8003d5c ) + 8003c06: 781b ldrb r3, [r3, #0] + 8003c08: 429a cmp r2, r3 + 8003c0a: d122 bne.n 8003c52 + 8003c0c: 4b52 ldr r3, [pc, #328] ; (8003d58 ) + 8003c0e: 785a ldrb r2, [r3, #1] + 8003c10: 4b52 ldr r3, [pc, #328] ; (8003d5c ) + 8003c12: 785b ldrb r3, [r3, #1] + 8003c14: 429a cmp r2, r3 + 8003c16: d11c bne.n 8003c52 { switch(r480.key) - 8003b4e: 4b2c ldr r3, [pc, #176] ; (8003c00 ) - 8003b50: 789b ldrb r3, [r3, #2] - 8003b52: 2bde cmp r3, #222 ; 0xde - 8003b54: d014 beq.n 8003b80 - 8003b56: dc18 bgt.n 8003b8a - 8003b58: 2bdd cmp r3, #221 ; 0xdd - 8003b5a: d00d beq.n 8003b78 - 8003b5c: dc15 bgt.n 8003b8a - 8003b5e: 2bd7 cmp r3, #215 ; 0xd7 - 8003b60: d002 beq.n 8003b68 - 8003b62: 2bdb cmp r3, #219 ; 0xdb - 8003b64: d004 beq.n 8003b70 - 8003b66: e010 b.n 8003b8a + 8003c18: 4b4f ldr r3, [pc, #316] ; (8003d58 ) + 8003c1a: 789b ldrb r3, [r3, #2] + 8003c1c: 2bde cmp r3, #222 ; 0xde + 8003c1e: d014 beq.n 8003c4a + 8003c20: dc18 bgt.n 8003c54 + 8003c22: 2bdd cmp r3, #221 ; 0xdd + 8003c24: d00d beq.n 8003c42 + 8003c26: dc15 bgt.n 8003c54 + 8003c28: 2bd7 cmp r3, #215 ; 0xd7 + 8003c2a: d002 beq.n 8003c32 + 8003c2c: 2bdb cmp r3, #219 ; 0xdb + 8003c2e: d004 beq.n 8003c3a + 8003c30: e010 b.n 8003c54 { case 0xd7: dis_buff.button_flag[0]=1; - 8003b68: 4b27 ldr r3, [pc, #156] ; (8003c08 ) - 8003b6a: 2201 movs r2, #1 - 8003b6c: 711a strb r2, [r3, #4] + 8003c32: 4b46 ldr r3, [pc, #280] ; (8003d4c ) + 8003c34: 2201 movs r2, #1 + 8003c36: 711a strb r2, [r3, #4] break; - 8003b6e: e00c b.n 8003b8a + 8003c38: e00c b.n 8003c54 case 0xdb: dis_buff.button_flag[1]=1; - 8003b70: 4b25 ldr r3, [pc, #148] ; (8003c08 ) - 8003b72: 2201 movs r2, #1 - 8003b74: 715a strb r2, [r3, #5] + 8003c3a: 4b44 ldr r3, [pc, #272] ; (8003d4c ) + 8003c3c: 2201 movs r2, #1 + 8003c3e: 715a strb r2, [r3, #5] break; - 8003b76: e008 b.n 8003b8a + 8003c40: e008 b.n 8003c54 case 0xdd: dis_buff.button_flag[2]=1; - 8003b78: 4b23 ldr r3, [pc, #140] ; (8003c08 ) - 8003b7a: 2201 movs r2, #1 - 8003b7c: 719a strb r2, [r3, #6] + 8003c42: 4b42 ldr r3, [pc, #264] ; (8003d4c ) + 8003c44: 2201 movs r2, #1 + 8003c46: 719a strb r2, [r3, #6] break; - 8003b7e: e004 b.n 8003b8a + 8003c48: e004 b.n 8003c54 case 0xde: dis_buff.button_flag[3]=1; - 8003b80: 4b21 ldr r3, [pc, #132] ; (8003c08 ) - 8003b82: 2201 movs r2, #1 - 8003b84: 71da strb r2, [r3, #7] + 8003c4a: 4b40 ldr r3, [pc, #256] ; (8003d4c ) + 8003c4c: 2201 movs r2, #1 + 8003c4e: 71da strb r2, [r3, #7] break; - 8003b86: e000 b.n 8003b8a + 8003c50: e000 b.n 8003c54 } } - 8003b88: 46c0 nop ; (mov r8, r8) + 8003c52: 46c0 nop ; (mov r8, r8) r480.key=0; - 8003b8a: 4b1d ldr r3, [pc, #116] ; (8003c00 ) - 8003b8c: 2200 movs r2, #0 - 8003b8e: 709a strb r2, [r3, #2] + 8003c54: 4b40 ldr r3, [pc, #256] ; (8003d58 ) + 8003c56: 2200 movs r2, #0 + 8003c58: 709a strb r2, [r3, #2] r480.add[0]=0; - 8003b90: 4b1b ldr r3, [pc, #108] ; (8003c00 ) - 8003b92: 2200 movs r2, #0 - 8003b94: 701a strb r2, [r3, #0] + 8003c5a: 4b3f ldr r3, [pc, #252] ; (8003d58 ) + 8003c5c: 2200 movs r2, #0 + 8003c5e: 701a strb r2, [r3, #0] r480.add[1]=0; - 8003b96: 4b1a ldr r3, [pc, #104] ; (8003c00 ) - 8003b98: 2200 movs r2, #0 - 8003b9a: 705a strb r2, [r3, #1] + 8003c60: 4b3d ldr r3, [pc, #244] ; (8003d58 ) + 8003c62: 2200 movs r2, #0 + 8003c64: 705a strb r2, [r3, #1] GEI_BUTTON_CODE(&key1,dis_buff.button_flag[0]); - 8003b9c: 4b1a ldr r3, [pc, #104] ; (8003c08 ) - 8003b9e: 791a ldrb r2, [r3, #4] - 8003ba0: 4b1a ldr r3, [pc, #104] ; (8003c0c ) - 8003ba2: 0011 movs r1, r2 - 8003ba4: 0018 movs r0, r3 - 8003ba6: f7fe fd63 bl 8002670 + 8003c66: 4b39 ldr r3, [pc, #228] ; (8003d4c ) + 8003c68: 791a ldrb r2, [r3, #4] + 8003c6a: 4b3d ldr r3, [pc, #244] ; (8003d60 ) + 8003c6c: 0011 movs r1, r2 + 8003c6e: 0018 movs r0, r3 + 8003c70: f7fe fcfe bl 8002670 GEI_BUTTON_CODE(&key2,dis_buff.button_flag[1]); - 8003baa: 4b17 ldr r3, [pc, #92] ; (8003c08 ) - 8003bac: 795a ldrb r2, [r3, #5] - 8003bae: 4b18 ldr r3, [pc, #96] ; (8003c10 ) - 8003bb0: 0011 movs r1, r2 - 8003bb2: 0018 movs r0, r3 - 8003bb4: f7fe fd5c bl 8002670 + 8003c74: 4b35 ldr r3, [pc, #212] ; (8003d4c ) + 8003c76: 795a ldrb r2, [r3, #5] + 8003c78: 4b3a ldr r3, [pc, #232] ; (8003d64 ) + 8003c7a: 0011 movs r1, r2 + 8003c7c: 0018 movs r0, r3 + 8003c7e: f7fe fcf7 bl 8002670 GEI_BUTTON_CODE(&key3,dis_buff.button_flag[2]); - 8003bb8: 4b13 ldr r3, [pc, #76] ; (8003c08 ) - 8003bba: 799a ldrb r2, [r3, #6] - 8003bbc: 4b15 ldr r3, [pc, #84] ; (8003c14 ) - 8003bbe: 0011 movs r1, r2 - 8003bc0: 0018 movs r0, r3 - 8003bc2: f7fe fd55 bl 8002670 + 8003c82: 4b32 ldr r3, [pc, #200] ; (8003d4c ) + 8003c84: 799a ldrb r2, [r3, #6] + 8003c86: 4b38 ldr r3, [pc, #224] ; (8003d68 ) + 8003c88: 0011 movs r1, r2 + 8003c8a: 0018 movs r0, r3 + 8003c8c: f7fe fcf0 bl 8002670 GEI_BUTTON_CODE(&key4,dis_buff.button_flag[3]); - 8003bc6: 4b10 ldr r3, [pc, #64] ; (8003c08 ) - 8003bc8: 79da ldrb r2, [r3, #7] - 8003bca: 4b13 ldr r3, [pc, #76] ; (8003c18 ) - 8003bcc: 0011 movs r1, r2 - 8003bce: 0018 movs r0, r3 - 8003bd0: f7fe fd4e bl 8002670 + 8003c90: 4b2e ldr r3, [pc, #184] ; (8003d4c ) + 8003c92: 79da ldrb r2, [r3, #7] + 8003c94: 4b35 ldr r3, [pc, #212] ; (8003d6c ) + 8003c96: 0011 movs r1, r2 + 8003c98: 0018 movs r0, r3 + 8003c9a: f7fe fce9 bl 8002670 dis_buff.button_flag[0]=0; - 8003bd4: 4b0c ldr r3, [pc, #48] ; (8003c08 ) - 8003bd6: 2200 movs r2, #0 - 8003bd8: 711a strb r2, [r3, #4] + 8003c9e: 4b2b ldr r3, [pc, #172] ; (8003d4c ) + 8003ca0: 2200 movs r2, #0 + 8003ca2: 711a strb r2, [r3, #4] dis_buff.button_flag[1]=0; - 8003bda: 4b0b ldr r3, [pc, #44] ; (8003c08 ) - 8003bdc: 2200 movs r2, #0 - 8003bde: 715a strb r2, [r3, #5] + 8003ca4: 4b29 ldr r3, [pc, #164] ; (8003d4c ) + 8003ca6: 2200 movs r2, #0 + 8003ca8: 715a strb r2, [r3, #5] dis_buff.button_flag[2]=0; - 8003be0: 4b09 ldr r3, [pc, #36] ; (8003c08 ) - 8003be2: 2200 movs r2, #0 - 8003be4: 719a strb r2, [r3, #6] + 8003caa: 4b28 ldr r3, [pc, #160] ; (8003d4c ) + 8003cac: 2200 movs r2, #0 + 8003cae: 719a strb r2, [r3, #6] dis_buff.button_flag[3]=0; - 8003be6: 4b08 ldr r3, [pc, #32] ; (8003c08 ) - 8003be8: 2200 movs r2, #0 - 8003bea: 71da strb r2, [r3, #7] + 8003cb0: 4b26 ldr r3, [pc, #152] ; (8003d4c ) + 8003cb2: 2200 movs r2, #0 + 8003cb4: 71da strb r2, [r3, #7] + if(moto_in1!=READ_MOT_IN1) + 8003cb6: 4b2e ldr r3, [pc, #184] ; (8003d70 ) + 8003cb8: 2101 movs r1, #1 + 8003cba: 0018 movs r0, r3 + 8003cbc: f7fd fdd0 bl 8001860 + 8003cc0: 0003 movs r3, r0 + 8003cc2: 001a movs r2, r3 + 8003cc4: 1dfb adds r3, r7, #7 + 8003cc6: 781b ldrb r3, [r3, #0] + 8003cc8: 4293 cmp r3, r2 + 8003cca: d013 beq.n 8003cf4 + { + moto_in1_pp++; + 8003ccc: 1d3b adds r3, r7, #4 + 8003cce: 881a ldrh r2, [r3, #0] + 8003cd0: 1d3b adds r3, r7, #4 + 8003cd2: 3201 adds r2, #1 + 8003cd4: 801a strh r2, [r3, #0] + if(moto_in1_pp==100) + 8003cd6: 1d3b adds r3, r7, #4 + 8003cd8: 881b ldrh r3, [r3, #0] + 8003cda: 2b64 cmp r3, #100 ; 0x64 + 8003cdc: d10a bne.n 8003cf4 + { + moto_in1_pp=0; + 8003cde: 1d3b adds r3, r7, #4 + 8003ce0: 2200 movs r2, #0 + 8003ce2: 801a strh r2, [r3, #0] + moto_in1=READ_MOT_IN1; + 8003ce4: 1dfc adds r4, r7, #7 + 8003ce6: 4b22 ldr r3, [pc, #136] ; (8003d70 ) + 8003ce8: 2101 movs r1, #1 + 8003cea: 0018 movs r0, r3 + 8003cec: f7fd fdb8 bl 8001860 + 8003cf0: 0003 movs r3, r0 + 8003cf2: 7023 strb r3, [r4, #0] + } + } + + if(moto_in2!=READ_MOT_IN2) + 8003cf4: 4b1e ldr r3, [pc, #120] ; (8003d70 ) + 8003cf6: 2102 movs r1, #2 + 8003cf8: 0018 movs r0, r3 + 8003cfa: f7fd fdb1 bl 8001860 + 8003cfe: 0003 movs r3, r0 + 8003d00: 001a movs r2, r3 + 8003d02: 1dbb adds r3, r7, #6 + 8003d04: 781b ldrb r3, [r3, #0] + 8003d06: 4293 cmp r3, r2 + 8003d08: d013 beq.n 8003d32 + { + moto_in2_pp++; + 8003d0a: 1cbb adds r3, r7, #2 + 8003d0c: 881a ldrh r2, [r3, #0] + 8003d0e: 1cbb adds r3, r7, #2 + 8003d10: 3201 adds r2, #1 + 8003d12: 801a strh r2, [r3, #0] + if(moto_in2_pp==100) + 8003d14: 1cbb adds r3, r7, #2 + 8003d16: 881b ldrh r3, [r3, #0] + 8003d18: 2b64 cmp r3, #100 ; 0x64 + 8003d1a: d10a bne.n 8003d32 + { + moto_in2_pp=0; + 8003d1c: 1cbb adds r3, r7, #2 + 8003d1e: 2200 movs r2, #0 + 8003d20: 801a strh r2, [r3, #0] + moto_in2=READ_MOT_IN2; + 8003d22: 1dbc adds r4, r7, #6 + 8003d24: 4b12 ldr r3, [pc, #72] ; (8003d70 ) + 8003d26: 2102 movs r1, #2 + 8003d28: 0018 movs r0, r3 + 8003d2a: f7fd fd99 bl 8001860 + 8003d2e: 0003 movs r3, r0 + 8003d30: 7023 strb r3, [r4, #0] + } + } HT1621_Display_GetButton(); - 8003bec: f7ff fb16 bl 800321c + 8003d32: f7ff fa73 bl 800321c hc2_sever(); - 8003bf0: f7ff fa00 bl 8002ff4 + 8003d36: f7ff f95d bl 8002ff4 moto_server(); - 8003bf4: f7ff fa42 bl 800307c + 8003d3a: f7ff f99f bl 800307c for(char a=0;a<2;a++) - 8003bf8: e442 b.n 8003480 - 8003bfa: 46c0 nop ; (mov r8, r8) - 8003bfc: 200000d8 .word 0x200000d8 - 8003c00: 200000f8 .word 0x200000f8 - 8003c04: 20000164 .word 0x20000164 - 8003c08: 20000038 .word 0x20000038 - 8003c0c: 20000100 .word 0x20000100 - 8003c10: 20000144 .word 0x20000144 - 8003c14: 20000120 .word 0x20000120 - 8003c18: 200000e8 .word 0x200000e8 + 8003d3e: f7ff fba9 bl 8003494 + 8003d42: 46c0 nop ; (mov r8, r8) + 8003d44: 20000154 .word 0x20000154 + 8003d48: 20000130 .word 0x20000130 + 8003d4c: 20000038 .word 0x20000038 + 8003d50: 20000110 .word 0x20000110 + 8003d54: 200000d8 .word 0x200000d8 + 8003d58: 200000f8 .word 0x200000f8 + 8003d5c: 20000164 .word 0x20000164 + 8003d60: 20000100 .word 0x20000100 + 8003d64: 20000144 .word 0x20000144 + 8003d68: 20000120 .word 0x20000120 + 8003d6c: 200000e8 .word 0x200000e8 + 8003d70: 48001400 .word 0x48001400 -08003c1c : +08003d74 : int read_char_flag=0; char read_data_buffer[3]; char read_begin=0; void r480_init() { - 8003c1c: b580 push {r7, lr} - 8003c1e: af00 add r7, sp, #0 + 8003d74: b580 push {r7, lr} + 8003d76: af00 add r7, sp, #0 HAL_TIM_Base_Start_IT(&htim14); - 8003c20: 4b04 ldr r3, [pc, #16] ; (8003c34 ) - 8003c22: 0018 movs r0, r3 - 8003c24: f7fe fb2c bl 8002280 + 8003d78: 4b04 ldr r3, [pc, #16] ; (8003d8c ) + 8003d7a: 0018 movs r0, r3 + 8003d7c: f7fe fa80 bl 8002280 r480.times=0; - 8003c28: 4b03 ldr r3, [pc, #12] ; (8003c38 ) - 8003c2a: 2200 movs r2, #0 - 8003c2c: 809a strh r2, [r3, #4] + 8003d80: 4b03 ldr r3, [pc, #12] ; (8003d90 ) + 8003d82: 2200 movs r2, #0 + 8003d84: 809a strh r2, [r3, #4] } - 8003c2e: 46c0 nop ; (mov r8, r8) - 8003c30: 46bd mov sp, r7 - 8003c32: bd80 pop {r7, pc} - 8003c34: 2000004c .word 0x2000004c - 8003c38: 200000f8 .word 0x200000f8 + 8003d86: 46c0 nop ; (mov r8, r8) + 8003d88: 46bd mov sp, r7 + 8003d8a: bd80 pop {r7, pc} + 8003d8c: 2000004c .word 0x2000004c + 8003d90: 200000f8 .word 0x200000f8 -08003c3c : +08003d94 : void read_433_exit() { - 8003c3c: b590 push {r4, r7, lr} - 8003c3e: b083 sub sp, #12 - 8003c40: af00 add r7, sp, #0 + 8003d94: b590 push {r4, r7, lr} + 8003d96: b083 sub sp, #12 + 8003d98: af00 add r7, sp, #0 char a=read_infrared; - 8003c42: 1dfc adds r4, r7, #7 - 8003c44: 2390 movs r3, #144 ; 0x90 - 8003c46: 05db lsls r3, r3, #23 - 8003c48: 2108 movs r1, #8 - 8003c4a: 0018 movs r0, r3 - 8003c4c: f7fd fe08 bl 8001860 - 8003c50: 0003 movs r3, r0 - 8003c52: 7023 strb r3, [r4, #0] + 8003d9a: 1dfc adds r4, r7, #7 + 8003d9c: 2390 movs r3, #144 ; 0x90 + 8003d9e: 05db lsls r3, r3, #23 + 8003da0: 2108 movs r1, #8 + 8003da2: 0018 movs r0, r3 + 8003da4: f7fd fd5c bl 8001860 + 8003da8: 0003 movs r3, r0 + 8003daa: 7023 strb r3, [r4, #0] int b; if(read_begin==0) - 8003c54: 4b41 ldr r3, [pc, #260] ; (8003d5c ) - 8003c56: 781b ldrb r3, [r3, #0] - 8003c58: 2b00 cmp r3, #0 - 8003c5a: d123 bne.n 8003ca4 + 8003dac: 4b41 ldr r3, [pc, #260] ; (8003eb4 ) + 8003dae: 781b ldrb r3, [r3, #0] + 8003db0: 2b00 cmp r3, #0 + 8003db2: d123 bne.n 8003dfc { if(a==0) - 8003c5c: 1dfb adds r3, r7, #7 - 8003c5e: 781b ldrb r3, [r3, #0] - 8003c60: 2b00 cmp r3, #0 - 8003c62: d103 bne.n 8003c6c + 8003db4: 1dfb adds r3, r7, #7 + 8003db6: 781b ldrb r3, [r3, #0] + 8003db8: 2b00 cmp r3, #0 + 8003dba: d103 bne.n 8003dc4 { timer_100us_tick=0; - 8003c64: 4b3e ldr r3, [pc, #248] ; (8003d60 ) - 8003c66: 2200 movs r2, #0 - 8003c68: 801a strh r2, [r3, #0] + 8003dbc: 4b3e ldr r3, [pc, #248] ; (8003eb8 ) + 8003dbe: 2200 movs r2, #0 + 8003dc0: 801a strh r2, [r3, #0] return ; - 8003c6a: e073 b.n 8003d54 + 8003dc2: e073 b.n 8003eac }else { if(timer_100us_tick>70&&timer_100us_tick<100) - 8003c6c: 4b3c ldr r3, [pc, #240] ; (8003d60 ) - 8003c6e: 881b ldrh r3, [r3, #0] - 8003c70: 2b46 cmp r3, #70 ; 0x46 - 8003c72: d800 bhi.n 8003c76 - 8003c74: e06e b.n 8003d54 - 8003c76: 4b3a ldr r3, [pc, #232] ; (8003d60 ) - 8003c78: 881b ldrh r3, [r3, #0] - 8003c7a: 2b63 cmp r3, #99 ; 0x63 - 8003c7c: d86a bhi.n 8003d54 + 8003dc4: 4b3c ldr r3, [pc, #240] ; (8003eb8 ) + 8003dc6: 881b ldrh r3, [r3, #0] + 8003dc8: 2b46 cmp r3, #70 ; 0x46 + 8003dca: d800 bhi.n 8003dce + 8003dcc: e06e b.n 8003eac + 8003dce: 4b3a ldr r3, [pc, #232] ; (8003eb8 ) + 8003dd0: 881b ldrh r3, [r3, #0] + 8003dd2: 2b63 cmp r3, #99 ; 0x63 + 8003dd4: d86a bhi.n 8003eac { read_begin=1; - 8003c7e: 4b37 ldr r3, [pc, #220] ; (8003d5c ) - 8003c80: 2201 movs r2, #1 - 8003c82: 701a strb r2, [r3, #0] + 8003dd6: 4b37 ldr r3, [pc, #220] ; (8003eb4 ) + 8003dd8: 2201 movs r2, #1 + 8003dda: 701a strb r2, [r3, #0] r480.times++; - 8003c84: 4b37 ldr r3, [pc, #220] ; (8003d64 ) - 8003c86: 889b ldrh r3, [r3, #4] - 8003c88: 3301 adds r3, #1 - 8003c8a: b29a uxth r2, r3 - 8003c8c: 4b35 ldr r3, [pc, #212] ; (8003d64 ) - 8003c8e: 809a strh r2, [r3, #4] + 8003ddc: 4b37 ldr r3, [pc, #220] ; (8003ebc ) + 8003dde: 889b ldrh r3, [r3, #4] + 8003de0: 3301 adds r3, #1 + 8003de2: b29a uxth r2, r3 + 8003de4: 4b35 ldr r3, [pc, #212] ; (8003ebc ) + 8003de6: 809a strh r2, [r3, #4] read_bit_flag=0; - 8003c90: 4b35 ldr r3, [pc, #212] ; (8003d68 ) - 8003c92: 2200 movs r2, #0 - 8003c94: 601a str r2, [r3, #0] + 8003de8: 4b35 ldr r3, [pc, #212] ; (8003ec0 ) + 8003dea: 2200 movs r2, #0 + 8003dec: 601a str r2, [r3, #0] read_char_flag=0; - 8003c96: 4b35 ldr r3, [pc, #212] ; (8003d6c ) - 8003c98: 2200 movs r2, #0 - 8003c9a: 601a str r2, [r3, #0] + 8003dee: 4b35 ldr r3, [pc, #212] ; (8003ec4 ) + 8003df0: 2200 movs r2, #0 + 8003df2: 601a str r2, [r3, #0] timer_100us_tick=0; - 8003c9c: 4b30 ldr r3, [pc, #192] ; (8003d60 ) - 8003c9e: 2200 movs r2, #0 - 8003ca0: 801a strh r2, [r3, #0] + 8003df4: 4b30 ldr r3, [pc, #192] ; (8003eb8 ) + 8003df6: 2200 movs r2, #0 + 8003df8: 801a strh r2, [r3, #0] return ; - 8003ca2: e057 b.n 8003d54 + 8003dfa: e057 b.n 8003eac } } }else { if(timer_100us_tick<5) - 8003ca4: 4b2e ldr r3, [pc, #184] ; (8003d60 ) - 8003ca6: 881b ldrh r3, [r3, #0] - 8003ca8: 2b04 cmp r3, #4 - 8003caa: d803 bhi.n 8003cb4 + 8003dfc: 4b2e ldr r3, [pc, #184] ; (8003eb8 ) + 8003dfe: 881b ldrh r3, [r3, #0] + 8003e00: 2b04 cmp r3, #4 + 8003e02: d803 bhi.n 8003e0c { timer_100us_tick=0; - 8003cac: 4b2c ldr r3, [pc, #176] ; (8003d60 ) - 8003cae: 2200 movs r2, #0 - 8003cb0: 801a strh r2, [r3, #0] + 8003e04: 4b2c ldr r3, [pc, #176] ; (8003eb8 ) + 8003e06: 2200 movs r2, #0 + 8003e08: 801a strh r2, [r3, #0] return ; - 8003cb2: e04f b.n 8003d54 + 8003e0a: e04f b.n 8003eac }else if(timer_100us_tick<12) - 8003cb4: 4b2a ldr r3, [pc, #168] ; (8003d60 ) - 8003cb6: 881b ldrh r3, [r3, #0] - 8003cb8: 2b0b cmp r3, #11 - 8003cba: d844 bhi.n 8003d46 + 8003e0c: 4b2a ldr r3, [pc, #168] ; (8003eb8 ) + 8003e0e: 881b ldrh r3, [r3, #0] + 8003e10: 2b0b cmp r3, #11 + 8003e12: d844 bhi.n 8003e9e { read_data_buffer[read_char_flag]<<=1; - 8003cbc: 4b2b ldr r3, [pc, #172] ; (8003d6c ) - 8003cbe: 681b ldr r3, [r3, #0] - 8003cc0: 4a2b ldr r2, [pc, #172] ; (8003d70 ) - 8003cc2: 5cd1 ldrb r1, [r2, r3] - 8003cc4: 4b29 ldr r3, [pc, #164] ; (8003d6c ) - 8003cc6: 681a ldr r2, [r3, #0] - 8003cc8: 1c0b adds r3, r1, #0 - 8003cca: 18db adds r3, r3, r3 - 8003ccc: b2d9 uxtb r1, r3 - 8003cce: 4b28 ldr r3, [pc, #160] ; (8003d70 ) - 8003cd0: 5499 strb r1, [r3, r2] + 8003e14: 4b2b ldr r3, [pc, #172] ; (8003ec4 ) + 8003e16: 681b ldr r3, [r3, #0] + 8003e18: 4a2b ldr r2, [pc, #172] ; (8003ec8 ) + 8003e1a: 5cd1 ldrb r1, [r2, r3] + 8003e1c: 4b29 ldr r3, [pc, #164] ; (8003ec4 ) + 8003e1e: 681a ldr r2, [r3, #0] + 8003e20: 1c0b adds r3, r1, #0 + 8003e22: 18db adds r3, r3, r3 + 8003e24: b2d9 uxtb r1, r3 + 8003e26: 4b28 ldr r3, [pc, #160] ; (8003ec8 ) + 8003e28: 5499 strb r1, [r3, r2] if(a==1) - 8003cd2: 1dfb adds r3, r7, #7 - 8003cd4: 781b ldrb r3, [r3, #0] - 8003cd6: 2b01 cmp r3, #1 - 8003cd8: d10a bne.n 8003cf0 + 8003e2a: 1dfb adds r3, r7, #7 + 8003e2c: 781b ldrb r3, [r3, #0] + 8003e2e: 2b01 cmp r3, #1 + 8003e30: d10a bne.n 8003e48 { read_data_buffer[read_char_flag]|=0x01; - 8003cda: 4b24 ldr r3, [pc, #144] ; (8003d6c ) - 8003cdc: 681b ldr r3, [r3, #0] - 8003cde: 4a24 ldr r2, [pc, #144] ; (8003d70 ) - 8003ce0: 5cd2 ldrb r2, [r2, r3] - 8003ce2: 4b22 ldr r3, [pc, #136] ; (8003d6c ) - 8003ce4: 681b ldr r3, [r3, #0] - 8003ce6: 2101 movs r1, #1 - 8003ce8: 430a orrs r2, r1 - 8003cea: b2d1 uxtb r1, r2 - 8003cec: 4a20 ldr r2, [pc, #128] ; (8003d70 ) - 8003cee: 54d1 strb r1, [r2, r3] + 8003e32: 4b24 ldr r3, [pc, #144] ; (8003ec4 ) + 8003e34: 681b ldr r3, [r3, #0] + 8003e36: 4a24 ldr r2, [pc, #144] ; (8003ec8 ) + 8003e38: 5cd2 ldrb r2, [r2, r3] + 8003e3a: 4b22 ldr r3, [pc, #136] ; (8003ec4 ) + 8003e3c: 681b ldr r3, [r3, #0] + 8003e3e: 2101 movs r1, #1 + 8003e40: 430a orrs r2, r1 + 8003e42: b2d1 uxtb r1, r2 + 8003e44: 4a20 ldr r2, [pc, #128] ; (8003ec8 ) + 8003e46: 54d1 strb r1, [r2, r3] } read_bit_flag++; - 8003cf0: 4b1d ldr r3, [pc, #116] ; (8003d68 ) - 8003cf2: 681b ldr r3, [r3, #0] - 8003cf4: 1c5a adds r2, r3, #1 - 8003cf6: 4b1c ldr r3, [pc, #112] ; (8003d68 ) - 8003cf8: 601a str r2, [r3, #0] + 8003e48: 4b1d ldr r3, [pc, #116] ; (8003ec0 ) + 8003e4a: 681b ldr r3, [r3, #0] + 8003e4c: 1c5a adds r2, r3, #1 + 8003e4e: 4b1c ldr r3, [pc, #112] ; (8003ec0 ) + 8003e50: 601a str r2, [r3, #0] if(read_bit_flag==8) - 8003cfa: 4b1b ldr r3, [pc, #108] ; (8003d68 ) - 8003cfc: 681b ldr r3, [r3, #0] - 8003cfe: 2b08 cmp r3, #8 - 8003d00: d11d bne.n 8003d3e + 8003e52: 4b1b ldr r3, [pc, #108] ; (8003ec0 ) + 8003e54: 681b ldr r3, [r3, #0] + 8003e56: 2b08 cmp r3, #8 + 8003e58: d11d bne.n 8003e96 { read_bit_flag=0; - 8003d02: 4b19 ldr r3, [pc, #100] ; (8003d68 ) - 8003d04: 2200 movs r2, #0 - 8003d06: 601a str r2, [r3, #0] + 8003e5a: 4b19 ldr r3, [pc, #100] ; (8003ec0 ) + 8003e5c: 2200 movs r2, #0 + 8003e5e: 601a str r2, [r3, #0] read_char_flag++; - 8003d08: 4b18 ldr r3, [pc, #96] ; (8003d6c ) - 8003d0a: 681b ldr r3, [r3, #0] - 8003d0c: 1c5a adds r2, r3, #1 - 8003d0e: 4b17 ldr r3, [pc, #92] ; (8003d6c ) - 8003d10: 601a str r2, [r3, #0] + 8003e60: 4b18 ldr r3, [pc, #96] ; (8003ec4 ) + 8003e62: 681b ldr r3, [r3, #0] + 8003e64: 1c5a adds r2, r3, #1 + 8003e66: 4b17 ldr r3, [pc, #92] ; (8003ec4 ) + 8003e68: 601a str r2, [r3, #0] if(read_char_flag==3) - 8003d12: 4b16 ldr r3, [pc, #88] ; (8003d6c ) - 8003d14: 681b ldr r3, [r3, #0] - 8003d16: 2b03 cmp r3, #3 - 8003d18: d111 bne.n 8003d3e + 8003e6a: 4b16 ldr r3, [pc, #88] ; (8003ec4 ) + 8003e6c: 681b ldr r3, [r3, #0] + 8003e6e: 2b03 cmp r3, #3 + 8003e70: d111 bne.n 8003e96 { //got data read_char_flag=0; - 8003d1a: 4b14 ldr r3, [pc, #80] ; (8003d6c ) - 8003d1c: 2200 movs r2, #0 - 8003d1e: 601a str r2, [r3, #0] + 8003e72: 4b14 ldr r3, [pc, #80] ; (8003ec4 ) + 8003e74: 2200 movs r2, #0 + 8003e76: 601a str r2, [r3, #0] timer_100us_tick=0; - 8003d20: 4b0f ldr r3, [pc, #60] ; (8003d60 ) - 8003d22: 2200 movs r2, #0 - 8003d24: 801a strh r2, [r3, #0] + 8003e78: 4b0f ldr r3, [pc, #60] ; (8003eb8 ) + 8003e7a: 2200 movs r2, #0 + 8003e7c: 801a strh r2, [r3, #0] r480.add[0]=read_data_buffer[0]; - 8003d26: 4b12 ldr r3, [pc, #72] ; (8003d70 ) - 8003d28: 781a ldrb r2, [r3, #0] - 8003d2a: 4b0e ldr r3, [pc, #56] ; (8003d64 ) - 8003d2c: 701a strb r2, [r3, #0] + 8003e7e: 4b12 ldr r3, [pc, #72] ; (8003ec8 ) + 8003e80: 781a ldrb r2, [r3, #0] + 8003e82: 4b0e ldr r3, [pc, #56] ; (8003ebc ) + 8003e84: 701a strb r2, [r3, #0] r480.add[1]=read_data_buffer[1]; - 8003d2e: 4b10 ldr r3, [pc, #64] ; (8003d70 ) - 8003d30: 785a ldrb r2, [r3, #1] - 8003d32: 4b0c ldr r3, [pc, #48] ; (8003d64 ) - 8003d34: 705a strb r2, [r3, #1] + 8003e86: 4b10 ldr r3, [pc, #64] ; (8003ec8 ) + 8003e88: 785a ldrb r2, [r3, #1] + 8003e8a: 4b0c ldr r3, [pc, #48] ; (8003ebc ) + 8003e8c: 705a strb r2, [r3, #1] r480.key=read_data_buffer[2]; - 8003d36: 4b0e ldr r3, [pc, #56] ; (8003d70 ) - 8003d38: 789a ldrb r2, [r3, #2] - 8003d3a: 4b0a ldr r3, [pc, #40] ; (8003d64 ) - 8003d3c: 709a strb r2, [r3, #2] + 8003e8e: 4b0e ldr r3, [pc, #56] ; (8003ec8 ) + 8003e90: 789a ldrb r2, [r3, #2] + 8003e92: 4b0a ldr r3, [pc, #40] ; (8003ebc ) + 8003e94: 709a strb r2, [r3, #2] } } timer_100us_tick=0; - 8003d3e: 4b08 ldr r3, [pc, #32] ; (8003d60 ) - 8003d40: 2200 movs r2, #0 - 8003d42: 801a strh r2, [r3, #0] + 8003e96: 4b08 ldr r3, [pc, #32] ; (8003eb8 ) + 8003e98: 2200 movs r2, #0 + 8003e9a: 801a strh r2, [r3, #0] return ; - 8003d44: e006 b.n 8003d54 + 8003e9c: e006 b.n 8003eac }else//time out { read_begin=0; - 8003d46: 4b05 ldr r3, [pc, #20] ; (8003d5c ) - 8003d48: 2200 movs r2, #0 - 8003d4a: 701a strb r2, [r3, #0] + 8003e9e: 4b05 ldr r3, [pc, #20] ; (8003eb4 ) + 8003ea0: 2200 movs r2, #0 + 8003ea2: 701a strb r2, [r3, #0] timer_100us_tick=0; - 8003d4c: 4b04 ldr r3, [pc, #16] ; (8003d60 ) - 8003d4e: 2200 movs r2, #0 - 8003d50: 801a strh r2, [r3, #0] + 8003ea4: 4b04 ldr r3, [pc, #16] ; (8003eb8 ) + 8003ea6: 2200 movs r2, #0 + 8003ea8: 801a strh r2, [r3, #0] return ; - 8003d52: 46c0 nop ; (mov r8, r8) + 8003eaa: 46c0 nop ; (mov r8, r8) } } } - 8003d54: 46bd mov sp, r7 - 8003d56: b003 add sp, #12 - 8003d58: bd90 pop {r4, r7, pc} - 8003d5a: 46c0 nop ; (mov r8, r8) - 8003d5c: 20000034 .word 0x20000034 - 8003d60: 20000028 .word 0x20000028 - 8003d64: 200000f8 .word 0x200000f8 - 8003d68: 2000002c .word 0x2000002c - 8003d6c: 20000030 .word 0x20000030 - 8003d70: 2000016c .word 0x2000016c + 8003eac: 46bd mov sp, r7 + 8003eae: b003 add sp, #12 + 8003eb0: bd90 pop {r4, r7, pc} + 8003eb2: 46c0 nop ; (mov r8, r8) + 8003eb4: 20000034 .word 0x20000034 + 8003eb8: 20000028 .word 0x20000028 + 8003ebc: 200000f8 .word 0x200000f8 + 8003ec0: 2000002c .word 0x2000002c + 8003ec4: 20000030 .word 0x20000030 + 8003ec8: 2000016c .word 0x2000016c -08003d74 : +08003ecc : void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin) { - 8003d74: b580 push {r7, lr} - 8003d76: b082 sub sp, #8 - 8003d78: af00 add r7, sp, #0 - 8003d7a: 0002 movs r2, r0 - 8003d7c: 1dbb adds r3, r7, #6 - 8003d7e: 801a strh r2, [r3, #0] + 8003ecc: b580 push {r7, lr} + 8003ece: b082 sub sp, #8 + 8003ed0: af00 add r7, sp, #0 + 8003ed2: 0002 movs r2, r0 + 8003ed4: 1dbb adds r3, r7, #6 + 8003ed6: 801a strh r2, [r3, #0] switch(GPIO_Pin) - 8003d80: 1dbb adds r3, r7, #6 - 8003d82: 881b ldrh r3, [r3, #0] - 8003d84: 2b08 cmp r3, #8 - 8003d86: d102 bne.n 8003d8e + 8003ed8: 1dbb adds r3, r7, #6 + 8003eda: 881b ldrh r3, [r3, #0] + 8003edc: 2b08 cmp r3, #8 + 8003ede: d102 bne.n 8003ee6 { case infeaed_Pin: read_433_exit(); - 8003d88: f7ff ff58 bl 8003c3c + 8003ee0: f7ff ff58 bl 8003d94 return ; - 8003d8c: 46c0 nop ; (mov r8, r8) + 8003ee4: 46c0 nop ; (mov r8, r8) break; } } - 8003d8e: 46bd mov sp, r7 - 8003d90: b002 add sp, #8 - 8003d92: bd80 pop {r7, pc} + 8003ee6: 46bd mov sp, r7 + 8003ee8: b002 add sp, #8 + 8003eea: bd80 pop {r7, pc} -08003d94 : +08003eec : void HAL_TIM_PeriodElapsedCallback(TIM_HandleTypeDef *htim)//100us { - 8003d94: b580 push {r7, lr} - 8003d96: b082 sub sp, #8 - 8003d98: af00 add r7, sp, #0 - 8003d9a: 6078 str r0, [r7, #4] + 8003eec: b580 push {r7, lr} + 8003eee: b082 sub sp, #8 + 8003ef0: af00 add r7, sp, #0 + 8003ef2: 6078 str r0, [r7, #4] if (htim == (&htim14)) - 8003d9c: 687a ldr r2, [r7, #4] - 8003d9e: 4b06 ldr r3, [pc, #24] ; (8003db8 ) - 8003da0: 429a cmp r2, r3 - 8003da2: d105 bne.n 8003db0 + 8003ef4: 687a ldr r2, [r7, #4] + 8003ef6: 4b06 ldr r3, [pc, #24] ; (8003f10 ) + 8003ef8: 429a cmp r2, r3 + 8003efa: d105 bne.n 8003f08 { timer_100us_tick++; - 8003da4: 4b05 ldr r3, [pc, #20] ; (8003dbc ) - 8003da6: 881b ldrh r3, [r3, #0] - 8003da8: 3301 adds r3, #1 - 8003daa: b29a uxth r2, r3 - 8003dac: 4b03 ldr r3, [pc, #12] ; (8003dbc ) - 8003dae: 801a strh r2, [r3, #0] + 8003efc: 4b05 ldr r3, [pc, #20] ; (8003f14 ) + 8003efe: 881b ldrh r3, [r3, #0] + 8003f00: 3301 adds r3, #1 + 8003f02: b29a uxth r2, r3 + 8003f04: 4b03 ldr r3, [pc, #12] ; (8003f14 ) + 8003f06: 801a strh r2, [r3, #0] } } - 8003db0: 46c0 nop ; (mov r8, r8) - 8003db2: 46bd mov sp, r7 - 8003db4: b002 add sp, #8 - 8003db6: bd80 pop {r7, pc} - 8003db8: 2000004c .word 0x2000004c - 8003dbc: 20000028 .word 0x20000028 + 8003f08: 46c0 nop ; (mov r8, r8) + 8003f0a: 46bd mov sp, r7 + 8003f0c: b002 add sp, #8 + 8003f0e: bd80 pop {r7, pc} + 8003f10: 2000004c .word 0x2000004c + 8003f14: 20000028 .word 0x20000028 -08003dc0 <__libc_init_array>: - 8003dc0: b570 push {r4, r5, r6, lr} - 8003dc2: 2600 movs r6, #0 - 8003dc4: 4d0c ldr r5, [pc, #48] ; (8003df8 <__libc_init_array+0x38>) - 8003dc6: 4c0d ldr r4, [pc, #52] ; (8003dfc <__libc_init_array+0x3c>) - 8003dc8: 1b64 subs r4, r4, r5 - 8003dca: 10a4 asrs r4, r4, #2 - 8003dcc: 42a6 cmp r6, r4 - 8003dce: d109 bne.n 8003de4 <__libc_init_array+0x24> - 8003dd0: 2600 movs r6, #0 - 8003dd2: f000 f821 bl 8003e18 <_init> - 8003dd6: 4d0a ldr r5, [pc, #40] ; (8003e00 <__libc_init_array+0x40>) - 8003dd8: 4c0a ldr r4, [pc, #40] ; (8003e04 <__libc_init_array+0x44>) - 8003dda: 1b64 subs r4, r4, r5 - 8003ddc: 10a4 asrs r4, r4, #2 - 8003dde: 42a6 cmp r6, r4 - 8003de0: d105 bne.n 8003dee <__libc_init_array+0x2e> - 8003de2: bd70 pop {r4, r5, r6, pc} - 8003de4: 00b3 lsls r3, r6, #2 - 8003de6: 58eb ldr r3, [r5, r3] - 8003de8: 4798 blx r3 - 8003dea: 3601 adds r6, #1 - 8003dec: e7ee b.n 8003dcc <__libc_init_array+0xc> - 8003dee: 00b3 lsls r3, r6, #2 - 8003df0: 58eb ldr r3, [r5, r3] - 8003df2: 4798 blx r3 - 8003df4: 3601 adds r6, #1 - 8003df6: e7f2 b.n 8003dde <__libc_init_array+0x1e> - 8003df8: 08003e88 .word 0x08003e88 - 8003dfc: 08003e88 .word 0x08003e88 - 8003e00: 08003e88 .word 0x08003e88 - 8003e04: 08003e8c .word 0x08003e8c +08003f18 <__libc_init_array>: + 8003f18: b570 push {r4, r5, r6, lr} + 8003f1a: 2600 movs r6, #0 + 8003f1c: 4d0c ldr r5, [pc, #48] ; (8003f50 <__libc_init_array+0x38>) + 8003f1e: 4c0d ldr r4, [pc, #52] ; (8003f54 <__libc_init_array+0x3c>) + 8003f20: 1b64 subs r4, r4, r5 + 8003f22: 10a4 asrs r4, r4, #2 + 8003f24: 42a6 cmp r6, r4 + 8003f26: d109 bne.n 8003f3c <__libc_init_array+0x24> + 8003f28: 2600 movs r6, #0 + 8003f2a: f000 f821 bl 8003f70 <_init> + 8003f2e: 4d0a ldr r5, [pc, #40] ; (8003f58 <__libc_init_array+0x40>) + 8003f30: 4c0a ldr r4, [pc, #40] ; (8003f5c <__libc_init_array+0x44>) + 8003f32: 1b64 subs r4, r4, r5 + 8003f34: 10a4 asrs r4, r4, #2 + 8003f36: 42a6 cmp r6, r4 + 8003f38: d105 bne.n 8003f46 <__libc_init_array+0x2e> + 8003f3a: bd70 pop {r4, r5, r6, pc} + 8003f3c: 00b3 lsls r3, r6, #2 + 8003f3e: 58eb ldr r3, [r5, r3] + 8003f40: 4798 blx r3 + 8003f42: 3601 adds r6, #1 + 8003f44: e7ee b.n 8003f24 <__libc_init_array+0xc> + 8003f46: 00b3 lsls r3, r6, #2 + 8003f48: 58eb ldr r3, [r5, r3] + 8003f4a: 4798 blx r3 + 8003f4c: 3601 adds r6, #1 + 8003f4e: e7f2 b.n 8003f36 <__libc_init_array+0x1e> + 8003f50: 08003fe8 .word 0x08003fe8 + 8003f54: 08003fe8 .word 0x08003fe8 + 8003f58: 08003fe8 .word 0x08003fe8 + 8003f5c: 08003fec .word 0x08003fec -08003e08 : - 8003e08: 0003 movs r3, r0 - 8003e0a: 1882 adds r2, r0, r2 - 8003e0c: 4293 cmp r3, r2 - 8003e0e: d100 bne.n 8003e12 - 8003e10: 4770 bx lr - 8003e12: 7019 strb r1, [r3, #0] - 8003e14: 3301 adds r3, #1 - 8003e16: e7f9 b.n 8003e0c +08003f60 : + 8003f60: 0003 movs r3, r0 + 8003f62: 1882 adds r2, r0, r2 + 8003f64: 4293 cmp r3, r2 + 8003f66: d100 bne.n 8003f6a + 8003f68: 4770 bx lr + 8003f6a: 7019 strb r1, [r3, #0] + 8003f6c: 3301 adds r3, #1 + 8003f6e: e7f9 b.n 8003f64 -08003e18 <_init>: - 8003e18: b5f8 push {r3, r4, r5, r6, r7, lr} - 8003e1a: 46c0 nop ; (mov r8, r8) - 8003e1c: bcf8 pop {r3, r4, r5, r6, r7} - 8003e1e: bc08 pop {r3} - 8003e20: 469e mov lr, r3 - 8003e22: 4770 bx lr +08003f70 <_init>: + 8003f70: b5f8 push {r3, r4, r5, r6, r7, lr} + 8003f72: 46c0 nop ; (mov r8, r8) + 8003f74: bcf8 pop {r3, r4, r5, r6, r7} + 8003f76: bc08 pop {r3} + 8003f78: 469e mov lr, r3 + 8003f7a: 4770 bx lr -08003e24 <_fini>: - 8003e24: b5f8 push {r3, r4, r5, r6, r7, lr} - 8003e26: 46c0 nop ; (mov r8, r8) - 8003e28: bcf8 pop {r3, r4, r5, r6, r7} - 8003e2a: bc08 pop {r3} - 8003e2c: 469e mov lr, r3 - 8003e2e: 4770 bx lr +08003f7c <_fini>: + 8003f7c: b5f8 push {r3, r4, r5, r6, r7, lr} + 8003f7e: 46c0 nop ; (mov r8, r8) + 8003f80: bcf8 pop {r3, r4, r5, r6, r7} + 8003f82: bc08 pop {r3} + 8003f84: 469e mov lr, r3 + 8003f86: 4770 bx lr diff --git a/Debug/Motor_Controller2.map b/Debug/Motor_Controller2.map index 96bd965..6f380ae 100644 --- a/Debug/Motor_Controller2.map +++ b/Debug/Motor_Controller2.map @@ -3534,7 +3534,7 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id 0x0000000008000000 g_pfnVectors 0x00000000080000c0 . = ALIGN (0x4) -.text 0x00000000080000c0 0x3d70 +.text 0x00000000080000c0 0x3ec8 0x00000000080000c0 . = ALIGN (0x4) *(.text) .text 0x00000000080000c0 0x48 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o @@ -3801,109 +3801,109 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id .text.check_need_reset 0x0000000008003340 0xd8 ./my_software/my_code.o 0x0000000008003340 check_need_reset - .text.my_code 0x0000000008003418 0x804 ./my_software/my_code.o + .text.my_code 0x0000000008003418 0x95c ./my_software/my_code.o 0x0000000008003418 my_code .text.r480_init - 0x0000000008003c1c 0x20 ./my_software/r480r.o - 0x0000000008003c1c r480_init - .text.read_433_exit - 0x0000000008003c3c 0x138 ./my_software/r480r.o - 0x0000000008003c3c read_433_exit - .text.HAL_GPIO_EXTI_Callback 0x0000000008003d74 0x20 ./my_software/r480r.o - 0x0000000008003d74 HAL_GPIO_EXTI_Callback + 0x0000000008003d74 r480_init + .text.read_433_exit + 0x0000000008003d94 0x138 ./my_software/r480r.o + 0x0000000008003d94 read_433_exit + .text.HAL_GPIO_EXTI_Callback + 0x0000000008003ecc 0x20 ./my_software/r480r.o + 0x0000000008003ecc HAL_GPIO_EXTI_Callback .text.HAL_TIM_PeriodElapsedCallback - 0x0000000008003d94 0x2c ./my_software/r480r.o - 0x0000000008003d94 HAL_TIM_PeriodElapsedCallback + 0x0000000008003eec 0x2c ./my_software/r480r.o + 0x0000000008003eec HAL_TIM_PeriodElapsedCallback .text.__libc_init_array - 0x0000000008003dc0 0x48 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/../../../../arm-none-eabi/lib/thumb/v6-m/nofp/libc_nano.a(lib_a-init.o) - 0x0000000008003dc0 __libc_init_array - .text.memset 0x0000000008003e08 0x10 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/../../../../arm-none-eabi/lib/thumb/v6-m/nofp/libc_nano.a(lib_a-memset.o) - 0x0000000008003e08 memset + 0x0000000008003f18 0x48 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/../../../../arm-none-eabi/lib/thumb/v6-m/nofp/libc_nano.a(lib_a-init.o) + 0x0000000008003f18 __libc_init_array + .text.memset 0x0000000008003f60 0x10 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/../../../../arm-none-eabi/lib/thumb/v6-m/nofp/libc_nano.a(lib_a-memset.o) + 0x0000000008003f60 memset *(.glue_7) - .glue_7 0x0000000008003e18 0x0 linker stubs + .glue_7 0x0000000008003f70 0x0 linker stubs *(.glue_7t) - .glue_7t 0x0000000008003e18 0x0 linker stubs + .glue_7t 0x0000000008003f70 0x0 linker stubs *(.eh_frame) - .eh_frame 0x0000000008003e18 0x0 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o + .eh_frame 0x0000000008003f70 0x0 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o *(.init) - .init 0x0000000008003e18 0x4 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crti.o - 0x0000000008003e18 _init - .init 0x0000000008003e1c 0x8 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtn.o + .init 0x0000000008003f70 0x4 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crti.o + 0x0000000008003f70 _init + .init 0x0000000008003f74 0x8 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtn.o *(.fini) - .fini 0x0000000008003e24 0x4 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crti.o - 0x0000000008003e24 _fini - .fini 0x0000000008003e28 0x8 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtn.o - 0x0000000008003e30 . = ALIGN (0x4) - 0x0000000008003e30 _etext = . + .fini 0x0000000008003f7c 0x4 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crti.o + 0x0000000008003f7c _fini + .fini 0x0000000008003f80 0x8 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtn.o + 0x0000000008003f88 . = ALIGN (0x4) + 0x0000000008003f88 _etext = . -.vfp11_veneer 0x0000000008003e30 0x0 - .vfp11_veneer 0x0000000008003e30 0x0 linker stubs +.vfp11_veneer 0x0000000008003f88 0x0 + .vfp11_veneer 0x0000000008003f88 0x0 linker stubs -.v4_bx 0x0000000008003e30 0x0 - .v4_bx 0x0000000008003e30 0x0 linker stubs +.v4_bx 0x0000000008003f88 0x0 + .v4_bx 0x0000000008003f88 0x0 linker stubs -.iplt 0x0000000008003e30 0x0 - .iplt 0x0000000008003e30 0x0 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o +.iplt 0x0000000008003f88 0x0 + .iplt 0x0000000008003f88 0x0 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o -.rodata 0x0000000008003e30 0x58 - 0x0000000008003e30 . = ALIGN (0x4) +.rodata 0x0000000008003f88 0x60 + 0x0000000008003f88 . = ALIGN (0x4) *(.rodata) - .rodata 0x0000000008003e30 0x20 ./Drivers/STM32F0xx_HAL_Driver/Src/stm32f0xx_hal_rcc.o + .rodata 0x0000000008003f88 0x20 ./Drivers/STM32F0xx_HAL_Driver/Src/stm32f0xx_hal_rcc.o *(.rodata*) .rodata.AHBPrescTable - 0x0000000008003e50 0x10 ./Core/Src/system_stm32f0xx.o - 0x0000000008003e50 AHBPrescTable + 0x0000000008003fa8 0x10 ./Core/Src/system_stm32f0xx.o + 0x0000000008003fa8 AHBPrescTable .rodata.LED_Tab - 0x0000000008003e60 0x12 ./my_software/my_code.o - 0x0000000008003e60 LED_Tab - *fill* 0x0000000008003e72 0x2 + 0x0000000008003fb8 0x12 ./my_software/my_code.o + 0x0000000008003fb8 LED_Tab + *fill* 0x0000000008003fca 0x2 .rodata.my_code - 0x0000000008003e74 0x14 ./my_software/my_code.o - 0x0000000008003e88 . = ALIGN (0x4) + 0x0000000008003fcc 0x1c ./my_software/my_code.o + 0x0000000008003fe8 . = ALIGN (0x4) -.rel.dyn 0x0000000008003e88 0x0 - .rel.iplt 0x0000000008003e88 0x0 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o +.rel.dyn 0x0000000008003fe8 0x0 + .rel.iplt 0x0000000008003fe8 0x0 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o -.ARM.extab 0x0000000008003e88 0x0 - 0x0000000008003e88 . = ALIGN (0x4) +.ARM.extab 0x0000000008003fe8 0x0 + 0x0000000008003fe8 . = ALIGN (0x4) *(.ARM.extab* .gnu.linkonce.armextab.*) - 0x0000000008003e88 . = ALIGN (0x4) + 0x0000000008003fe8 . = ALIGN (0x4) -.ARM 0x0000000008003e88 0x0 - 0x0000000008003e88 . = ALIGN (0x4) - 0x0000000008003e88 __exidx_start = . +.ARM 0x0000000008003fe8 0x0 + 0x0000000008003fe8 . = ALIGN (0x4) + 0x0000000008003fe8 __exidx_start = . *(.ARM.exidx*) - 0x0000000008003e88 __exidx_end = . - 0x0000000008003e88 . = ALIGN (0x4) + 0x0000000008003fe8 __exidx_end = . + 0x0000000008003fe8 . = ALIGN (0x4) -.preinit_array 0x0000000008003e88 0x0 - 0x0000000008003e88 . = ALIGN (0x4) - 0x0000000008003e88 PROVIDE (__preinit_array_start = .) +.preinit_array 0x0000000008003fe8 0x0 + 0x0000000008003fe8 . = ALIGN (0x4) + 0x0000000008003fe8 PROVIDE (__preinit_array_start = .) *(.preinit_array*) - 0x0000000008003e88 PROVIDE (__preinit_array_end = .) - 0x0000000008003e88 . = ALIGN (0x4) + 0x0000000008003fe8 PROVIDE (__preinit_array_end = .) + 0x0000000008003fe8 . = ALIGN (0x4) -.init_array 0x0000000008003e88 0x4 - 0x0000000008003e88 . = ALIGN (0x4) - 0x0000000008003e88 PROVIDE (__init_array_start = .) +.init_array 0x0000000008003fe8 0x4 + 0x0000000008003fe8 . = ALIGN (0x4) + 0x0000000008003fe8 PROVIDE (__init_array_start = .) *(SORT_BY_NAME(.init_array.*)) *(.init_array*) - .init_array 0x0000000008003e88 0x4 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o - 0x0000000008003e8c PROVIDE (__init_array_end = .) - 0x0000000008003e8c . = ALIGN (0x4) + .init_array 0x0000000008003fe8 0x4 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o + 0x0000000008003fec PROVIDE (__init_array_end = .) + 0x0000000008003fec . = ALIGN (0x4) -.fini_array 0x0000000008003e8c 0x4 - 0x0000000008003e8c . = ALIGN (0x4) +.fini_array 0x0000000008003fec 0x4 + 0x0000000008003fec . = ALIGN (0x4) [!provide] PROVIDE (__fini_array_start = .) *(SORT_BY_NAME(.fini_array.*)) *(.fini_array*) - .fini_array 0x0000000008003e8c 0x4 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o + .fini_array 0x0000000008003fec 0x4 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o [!provide] PROVIDE (__fini_array_end = .) - 0x0000000008003e90 . = ALIGN (0x4) - 0x0000000008003e90 _sidata = LOADADDR (.data) + 0x0000000008003ff0 . = ALIGN (0x4) + 0x0000000008003ff0 _sidata = LOADADDR (.data) -.data 0x0000000020000000 0xc load address 0x0000000008003e90 +.data 0x0000000020000000 0xc load address 0x0000000008003ff0 0x0000000020000000 . = ALIGN (0x4) 0x0000000020000000 _sdata = . *(.data) @@ -3923,11 +3923,11 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id *fill* 0x0000000020000009 0x3 0x000000002000000c _edata = . -.igot.plt 0x000000002000000c 0x0 load address 0x0000000008003e9c +.igot.plt 0x000000002000000c 0x0 load address 0x0000000008003ffc .igot.plt 0x000000002000000c 0x0 /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/crtbegin.o 0x000000002000000c . = ALIGN (0x4) -.bss 0x000000002000000c 0x164 load address 0x0000000008003e9c +.bss 0x000000002000000c 0x164 load address 0x0000000008003ffc 0x000000002000000c _sbss = . 0x000000002000000c __bss_start__ = _sbss *(.bss) @@ -3973,7 +3973,7 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id 0x0000000020000170 __bss_end__ = _ebss ._user_heap_stack - 0x0000000020000170 0x600 load address 0x0000000008003e9c + 0x0000000020000170 0x600 load address 0x0000000008003ffc 0x0000000020000170 . = ALIGN (0x8) [!provide] PROVIDE (end = .) 0x0000000020000170 PROVIDE (_end = .) @@ -4053,7 +4053,7 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/../../../../arm-none-eabi/lib/thumb/v6-m/nofp/libm.a LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.9-2020-q2-update.macos64_2.0.0.202105311346/tools/bin/../lib/gcc/arm-none-eabi/9.3.1/thumb/v6-m/nofp/libgcc.a -.debug_info 0x0000000000000000 0xbe72 +.debug_info 0x0000000000000000 0xbeb2 .debug_info 0x0000000000000000 0xf4c ./Core/Src/main.o .debug_info 0x0000000000000f4c 0xcdc ./Core/Src/stm32f0xx_hal_msp.o .debug_info 0x0000000000001c28 0x76a ./Core/Src/stm32f0xx_it.o @@ -4072,8 +4072,8 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id .debug_info 0x0000000000009f93 0x2d3 ./my_software/gpio.o .debug_info 0x000000000000a266 0x3cc ./my_software/ht1621.o .debug_info 0x000000000000a632 0x3ea ./my_software/iic.o - .debug_info 0x000000000000aa1c 0xb67 ./my_software/my_code.o - .debug_info 0x000000000000b583 0x8ef ./my_software/r480r.o + .debug_info 0x000000000000aa1c 0xba7 ./my_software/my_code.o + .debug_info 0x000000000000b5c3 0x8ef ./my_software/r480r.o .debug_abbrev 0x0000000000000000 0x22ae .debug_abbrev 0x0000000000000000 0x23c ./Core/Src/main.o @@ -4229,7 +4229,7 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id .debug_macro 0x0000000000010216 0x4c ./my_software/my_code.o .debug_macro 0x0000000000010262 0x1e0 ./my_software/r480r.o -.debug_line 0x0000000000000000 0xf1bf +.debug_line 0x0000000000000000 0xf24c .debug_line 0x0000000000000000 0x8df ./Core/Src/main.o .debug_line 0x00000000000008df 0x793 ./Core/Src/stm32f0xx_hal_msp.o .debug_line 0x0000000000001072 0x7a5 ./Core/Src/stm32f0xx_it.o @@ -4248,10 +4248,10 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id .debug_line 0x000000000000c3c8 0x725 ./my_software/gpio.o .debug_line 0x000000000000caed 0x835 ./my_software/ht1621.o .debug_line 0x000000000000d322 0x923 ./my_software/iic.o - .debug_line 0x000000000000dc45 0xd89 ./my_software/my_code.o - .debug_line 0x000000000000e9ce 0x7f1 ./my_software/r480r.o + .debug_line 0x000000000000dc45 0xe16 ./my_software/my_code.o + .debug_line 0x000000000000ea5b 0x7f1 ./my_software/r480r.o -.debug_str 0x0000000000000000 0x5f5cc +.debug_str 0x0000000000000000 0x5f5f6 .debug_str 0x0000000000000000 0x5c9bc ./Core/Src/main.o 0x5cd69 (size before relaxing) .debug_str 0x000000000005c9bc 0x84 ./Core/Src/stm32f0xx_hal_msp.o @@ -4288,9 +4288,9 @@ LOAD /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.id 0x5c4ba (size before relaxing) .debug_str 0x000000000005f0e7 0x256 ./my_software/iic.o 0x5c2f3 (size before relaxing) - .debug_str 0x000000000005f33d 0x1d8 ./my_software/my_code.o - 0x5ca75 (size before relaxing) - .debug_str 0x000000000005f515 0xb7 ./my_software/r480r.o + .debug_str 0x000000000005f33d 0x202 ./my_software/my_code.o + 0x5ca9f (size before relaxing) + .debug_str 0x000000000005f53f 0xb7 ./my_software/r480r.o 0x5c64b (size before relaxing) .comment 0x0000000000000000 0x53 diff --git a/Debug/my_software/my_code.su b/Debug/my_software/my_code.su index d6ccde4..e9c12ad 100644 --- a/Debug/my_software/my_code.su +++ b/Debug/my_software/my_code.su @@ -3,4 +3,4 @@ my_code.c:77:6:hc2_sever 16 static my_code.c:104:6:moto_server 8 static my_code.c:210:6:HT1621_Display_GetButton 24 static my_code.c:255:6:check_need_reset 16 static -my_code.c:288:6:my_code 40 static +my_code.c:288:6:my_code 48 static diff --git a/Motor_Controller2.ioc b/Motor_Controller2.ioc index d91c582..e3b3f03 100644 --- a/Motor_Controller2.ioc +++ b/Motor_Controller2.ioc @@ -1,4 +1,6 @@ #MicroXplorer Configuration settings - do not modify +ADC.ContinuousConvMode=ENABLE +ADC.IPParameters=ContinuousConvMode File.Version=6 GPIO.groupedBy=Group By Peripherals KeepUserPlacement=false diff --git a/my_software/my_code.c b/my_software/my_code.c index 6cb9123..fc6db25 100644 --- a/my_software/my_code.c +++ b/my_software/my_code.c @@ -295,19 +295,21 @@ void my_code() long countdown=1000; long countdown_set=15000; + char moto_in1,moto_in2; + uint16_t moto_in1_pp=0,moto_in2_pp=0; HT1621_Init(); r480_init(); config.begin=0; - AT24CXX_Read(16,(char *)&config,sizeof(config_setting)); + AT24CXX_Read(32,(char *)&config,sizeof(config_setting)); if(config.begin!=0xab||check_need_reset()) { mode=0; r480.key=0; } - + mode=6; while(1) { @@ -359,7 +361,7 @@ void my_code() r480.add[0]=0; r480.add[1]=0; mode=1; - AT24CXX_Write(16,(char *)&config,sizeof(config_setting)); + AT24CXX_Write(32,(char *)&config,sizeof(config_setting)); } break; @@ -450,7 +452,7 @@ void my_code() moto.moto2a=0; moto.moto2b=10; } - if(key4.code!=0) + if(key4.code!=0||(moto_in1==1&&READ_MOT_IN1==0)) { mode=1; } @@ -505,7 +507,7 @@ void my_code() moto.moto2a=10; moto.moto2b=0; } - if(key4.code!=0) + if(key4.code!=0||(moto_in2==1&&READ_MOT_IN2==0)) { mode=1; } @@ -564,6 +566,17 @@ void my_code() dis_buff.d_num[1]=dis_buff.d_num[1]==0?16:dis_buff.d_num[1]; + break; + + case 6: + moto.moto1a=10; + moto.moto1b=0; + moto.moto2a=10; + moto.moto2b=0; + dis_buff.d_num[3]=(ADCC.adc_value[1])%10; + dis_buff.d_num[2]=(ADCC.adc_value[1]/10)%10; + dis_buff.d_num[1]=((ADCC.adc_value[1]/100)%10); + dis_buff.d_num[0]=((ADCC.adc_value[1]/1000)%10); break; // case 5: // //overload @@ -658,6 +671,25 @@ void my_code() dis_buff.button_flag[2]=0; dis_buff.button_flag[3]=0; + if(moto_in1!=READ_MOT_IN1) + { + moto_in1_pp++; + if(moto_in1_pp==100) + { + moto_in1_pp=0; + moto_in1=READ_MOT_IN1; + } + } + + if(moto_in2!=READ_MOT_IN2) + { + moto_in2_pp++; + if(moto_in2_pp==100) + { + moto_in2_pp=0; + moto_in2=READ_MOT_IN2; + } + } HT1621_Display_GetButton(); hc2_sever(); diff --git a/my_software/my_code.h b/my_software/my_code.h index 1feff2d..5bca142 100644 --- a/my_software/my_code.h +++ b/my_software/my_code.h @@ -27,8 +27,9 @@ void my_code(); typedef struct { - char begin; + char key_code[2]; + char begin; int time; }config_setting;