Celia 2 years ago
parent
commit
351efc6537

+ 0
- 12
timer_act2/Includes/Driver_GPIO.c View File

@@ -43,18 +43,6 @@ void MyGPIO_Init(MyGPIO_Struct_TypeDef * GPIOStructPtr) {
43 43
 			GPIOStructPtr->GPIO->CRL |= (GPIOStructPtr->GPIO_Conf << (GPIOStructPtr->GPIO_Pin * 4));
44 44
 		}
45 45
 	}
46
-
47
-	GPIOStructPtr->GPIO->CRL &= ~(0xF << (GPIOStructPtr->GPIO_Pin*4));
48
-	
49
-	//on met la bonne conf
50
-	if (GPIOStructPtr->GPIO_Conf == In_PullUp) {
51
-		//on est en pull up -> on met ŕ 1 par défaut
52
-		GPIOStructPtr->GPIO->CRL |= (In_PullDown << (GPIOStructPtr->GPIO_Pin*4));
53
-		MyGPIO_Set(GPIOStructPtr->GPIO, GPIOStructPtr->GPIO_Pin);
54
-	}
55
-	else {
56
-		GPIOStructPtr->GPIO->CRL |= (GPIOStructPtr->GPIO_Conf << (GPIOStructPtr->GPIO_Pin * 4));
57
-	}
58 46
 	
59 47
 }
60 48
 

+ 3
- 3
timer_act2/Includes/Driver_TIMER.c View File

@@ -105,19 +105,19 @@ void MyTimer_PWM(TIM_TypeDef * Timer, char Channel) {
105 105
 		case 2 : 
106 106
 			Timer->CCMR1 &= ~TIM_CCMR1_OC2M_0;
107 107
 			Timer->CCMR1 |= TIM_CCMR1_OC2M_1| TIM_CCMR1_OC2M_2;
108
-			Timer->CCMR1 |= TIM_CCMR1_OC1PE ;
108
+			Timer->CCMR1 |= TIM_CCMR1_OC2PE ;
109 109
 			Timer->CCER |= TIM_CCER_CC2E;
110 110
 			break ;
111 111
 		case 3 : 
112 112
 			Timer->CCMR2 &= ~TIM_CCMR2_OC3M_0;
113 113
 			Timer->CCMR2 |= TIM_CCMR2_OC3M_1| TIM_CCMR2_OC3M_2;
114
-			Timer->CCMR2 |= TIM_CCMR1_OC1PE ;
114
+			Timer->CCMR2 |= TIM_CCMR2_OC3PE ;
115 115
 			Timer->CCER |= TIM_CCER_CC3E;
116 116
 			break ;
117 117
 		case 4 : 
118 118
 			Timer->CCMR2 &= ~TIM_CCMR2_OC4M_0;
119 119
 			Timer->CCMR2 |= TIM_CCMR2_OC4M_1| TIM_CCMR2_OC4M_2;			
120
-			Timer->CCMR2 |= TIM_CCMR1_OC1PE ;
120
+			Timer->CCMR2 |= TIM_CCMR2_OC4PE ;
121 121
 			Timer->CCER |= TIM_CCER_CC4E;
122 122
 			break ;
123 123
 	}

+ 7
- 7
timer_act2/Listings/startup_stm32f10x_md.lst View File

@@ -465,13 +465,13 @@ ARM Macro Assembler    Page 8
465 465
               00000000 
466 466
 Command Line: --debug --xref --diag_suppress=9931 --cpu=Cortex-M3 --apcs=interw
467 467
 ork --depend=.\objects\startup_stm32f10x_md.d -o.\objects\startup_stm32f10x_md.
468
-o -I.\RTE\Device\STM32F103RB -I.\RTE\_Simulation -IC:\Users\chauz\AppData\Local
469
-\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include -IC:\Users\chauz\AppData\Local\Ar
470
-m\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include --predefine="__EVAL SETA 1" --p
471
-redefine="__MICROLIB SETA 1" --predefine="__UVISION_VERSION SETA 533" --predefi
472
-ne="_RTE_ SETA 1" --predefine="STM32F10X_MD SETA 1" --predefine="_RTE_ SETA 1" 
473
---list=.\listings\startup_stm32f10x_md.lst RTE\Device\STM32F103RB\startup_stm32
474
-f10x_md.s
468
+o -I.\RTE\Device\STM32F103RB -I.\RTE\_carteSTM -IC:\Users\chauz\AppData\Local\A
469
+rm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include -IC:\Users\chauz\AppData\Local\Arm\
470
+Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include --predefine="__EVAL SETA 1" --pre
471
+define="__MICROLIB SETA 1" --predefine="__UVISION_VERSION SETA 533" --predefine
472
+="_RTE_ SETA 1" --predefine="STM32F10X_MD SETA 1" --predefine="_RTE_ SETA 1" --
473
+list=.\listings\startup_stm32f10x_md.lst RTE\Device\STM32F103RB\startup_stm32f1
474
+0x_md.s
475 475
 
476 476
 
477 477
 

+ 69
- 69
timer_act2/Listings/timer_act2.map View File

@@ -10,6 +10,7 @@ Section Cross References
10 10
     principal.o(i.main) refers to driver_gpio.o(i.MyGPIO_Activate) for MyGPIO_Activate
11 11
     principal.o(i.main) refers to driver_timer.o(i.MyTimer_Base_Init) for MyTimer_Base_Init
12 12
     principal.o(i.main) refers to driver_gpio.o(i.MyGPIO_Init) for MyGPIO_Init
13
+    principal.o(i.main) refers to driver_gpio.o(i.MyGPIO_Set) for MyGPIO_Set
13 14
     principal.o(i.main) refers to driver_timer.o(i.MyTimer_PWM) for MyTimer_PWM
14 15
     principal.o(i.main) refers to driver_timer.o(i.MyTimer_PWM_set_cycle) for MyTimer_PWM_set_cycle
15 16
     principal.o(i.main) refers to principal.o(.data) for MonTimer
@@ -150,23 +151,23 @@ Image Symbol Table
150 151
     i.Activate_TIM                           0x0800025c   Section        0  driver_timer.o(i.Activate_TIM)
151 152
     i.MyGPIO_Activate                        0x08000284   Section        0  driver_gpio.o(i.MyGPIO_Activate)
152 153
     i.MyGPIO_Init                            0x0800029c   Section        0  driver_gpio.o(i.MyGPIO_Init)
153
-    i.MyGPIO_Set                             0x08000388   Section        0  driver_gpio.o(i.MyGPIO_Set)
154
-    i.MyTimer_Base_Init                      0x08000390   Section        0  driver_timer.o(i.MyTimer_Base_Init)
155
-    i.MyTimer_PWM                            0x080003a4   Section        0  driver_timer.o(i.MyTimer_PWM)
156
-    i.MyTimer_PWM_set_cycle                  0x08000464   Section        0  driver_timer.o(i.MyTimer_PWM_set_cycle)
157
-    i.SetSysClock                            0x080004e8   Section        0  system_stm32f10x.o(i.SetSysClock)
158
-    SetSysClock                              0x080004e9   Thumb Code     8  system_stm32f10x.o(i.SetSysClock)
159
-    i.SetSysClockTo72                        0x080004f0   Section        0  system_stm32f10x.o(i.SetSysClockTo72)
160
-    SetSysClockTo72                          0x080004f1   Thumb Code   214  system_stm32f10x.o(i.SetSysClockTo72)
161
-    i.SystemInit                             0x080005d0   Section        0  system_stm32f10x.o(i.SystemInit)
162
-    i.TIM1_TRG_COM_IRQHandler                0x08000630   Section        0  driver_timer.o(i.TIM1_TRG_COM_IRQHandler)
163
-    i.TIM2_IRQHandler                        0x08000654   Section        0  driver_timer.o(i.TIM2_IRQHandler)
164
-    i.TIM3_IRQHandler                        0x08000678   Section        0  driver_timer.o(i.TIM3_IRQHandler)
165
-    i.TIM4_IRQHandler                        0x0800069c   Section        0  driver_timer.o(i.TIM4_IRQHandler)
166
-    i.__scatterload_copy                     0x080006c0   Section       14  handlers.o(i.__scatterload_copy)
167
-    i.__scatterload_null                     0x080006ce   Section        2  handlers.o(i.__scatterload_null)
168
-    i.__scatterload_zeroinit                 0x080006d0   Section       14  handlers.o(i.__scatterload_zeroinit)
169
-    i.main                                   0x080006e0   Section        0  principal.o(i.main)
154
+    i.MyGPIO_Set                             0x08000342   Section        0  driver_gpio.o(i.MyGPIO_Set)
155
+    i.MyTimer_Base_Init                      0x0800034a   Section        0  driver_timer.o(i.MyTimer_Base_Init)
156
+    i.MyTimer_PWM                            0x0800035c   Section        0  driver_timer.o(i.MyTimer_PWM)
157
+    i.MyTimer_PWM_set_cycle                  0x0800041c   Section        0  driver_timer.o(i.MyTimer_PWM_set_cycle)
158
+    i.SetSysClock                            0x080004a0   Section        0  system_stm32f10x.o(i.SetSysClock)
159
+    SetSysClock                              0x080004a1   Thumb Code     8  system_stm32f10x.o(i.SetSysClock)
160
+    i.SetSysClockTo72                        0x080004a8   Section        0  system_stm32f10x.o(i.SetSysClockTo72)
161
+    SetSysClockTo72                          0x080004a9   Thumb Code   214  system_stm32f10x.o(i.SetSysClockTo72)
162
+    i.SystemInit                             0x08000588   Section        0  system_stm32f10x.o(i.SystemInit)
163
+    i.TIM1_TRG_COM_IRQHandler                0x080005e8   Section        0  driver_timer.o(i.TIM1_TRG_COM_IRQHandler)
164
+    i.TIM2_IRQHandler                        0x0800060c   Section        0  driver_timer.o(i.TIM2_IRQHandler)
165
+    i.TIM3_IRQHandler                        0x08000630   Section        0  driver_timer.o(i.TIM3_IRQHandler)
166
+    i.TIM4_IRQHandler                        0x08000654   Section        0  driver_timer.o(i.TIM4_IRQHandler)
167
+    i.__scatterload_copy                     0x08000678   Section       14  handlers.o(i.__scatterload_copy)
168
+    i.__scatterload_null                     0x08000686   Section        2  handlers.o(i.__scatterload_null)
169
+    i.__scatterload_zeroinit                 0x08000688   Section       14  handlers.o(i.__scatterload_zeroinit)
170
+    i.main                                   0x08000698   Section        0  principal.o(i.main)
170 171
     .data                                    0x20000000   Section       24  principal.o(.data)
171 172
     .data                                    0x20000018   Section       16  driver_timer.o(.data)
172 173
     STACK                                    0x20000028   Section     1024  startup_stm32f10x_md.o(STACK)
@@ -255,22 +256,22 @@ Image Symbol Table
255 256
     __scatterload_rt2                        0x08000239   Thumb Code     0  init.o(.text)
256 257
     Activate_TIM                             0x0800025d   Thumb Code    36  driver_timer.o(i.Activate_TIM)
257 258
     MyGPIO_Activate                          0x08000285   Thumb Code    18  driver_gpio.o(i.MyGPIO_Activate)
258
-    MyGPIO_Init                              0x0800029d   Thumb Code   236  driver_gpio.o(i.MyGPIO_Init)
259
-    MyGPIO_Set                               0x08000389   Thumb Code     8  driver_gpio.o(i.MyGPIO_Set)
260
-    MyTimer_Base_Init                        0x08000391   Thumb Code    18  driver_timer.o(i.MyTimer_Base_Init)
261
-    MyTimer_PWM                              0x080003a5   Thumb Code   188  driver_timer.o(i.MyTimer_PWM)
262
-    MyTimer_PWM_set_cycle                    0x08000465   Thumb Code   132  driver_timer.o(i.MyTimer_PWM_set_cycle)
263
-    SystemInit                               0x080005d1   Thumb Code    78  system_stm32f10x.o(i.SystemInit)
264
-    TIM1_TRG_COM_IRQHandler                  0x08000631   Thumb Code    28  driver_timer.o(i.TIM1_TRG_COM_IRQHandler)
265
-    TIM2_IRQHandler                          0x08000655   Thumb Code    32  driver_timer.o(i.TIM2_IRQHandler)
266
-    TIM3_IRQHandler                          0x08000679   Thumb Code    28  driver_timer.o(i.TIM3_IRQHandler)
267
-    TIM4_IRQHandler                          0x0800069d   Thumb Code    28  driver_timer.o(i.TIM4_IRQHandler)
268
-    __scatterload_copy                       0x080006c1   Thumb Code    14  handlers.o(i.__scatterload_copy)
269
-    __scatterload_null                       0x080006cf   Thumb Code     2  handlers.o(i.__scatterload_null)
270
-    __scatterload_zeroinit                   0x080006d1   Thumb Code    14  handlers.o(i.__scatterload_zeroinit)
271
-    main                                     0x080006e1   Thumb Code    98  principal.o(i.main)
272
-    Region$$Table$$Base                      0x08000754   Number         0  anon$$obj.o(Region$$Table)
273
-    Region$$Table$$Limit                     0x08000774   Number         0  anon$$obj.o(Region$$Table)
259
+    MyGPIO_Init                              0x0800029d   Thumb Code   166  driver_gpio.o(i.MyGPIO_Init)
260
+    MyGPIO_Set                               0x08000343   Thumb Code     8  driver_gpio.o(i.MyGPIO_Set)
261
+    MyTimer_Base_Init                        0x0800034b   Thumb Code    18  driver_timer.o(i.MyTimer_Base_Init)
262
+    MyTimer_PWM                              0x0800035d   Thumb Code   188  driver_timer.o(i.MyTimer_PWM)
263
+    MyTimer_PWM_set_cycle                    0x0800041d   Thumb Code   132  driver_timer.o(i.MyTimer_PWM_set_cycle)
264
+    SystemInit                               0x08000589   Thumb Code    78  system_stm32f10x.o(i.SystemInit)
265
+    TIM1_TRG_COM_IRQHandler                  0x080005e9   Thumb Code    28  driver_timer.o(i.TIM1_TRG_COM_IRQHandler)
266
+    TIM2_IRQHandler                          0x0800060d   Thumb Code    32  driver_timer.o(i.TIM2_IRQHandler)
267
+    TIM3_IRQHandler                          0x08000631   Thumb Code    28  driver_timer.o(i.TIM3_IRQHandler)
268
+    TIM4_IRQHandler                          0x08000655   Thumb Code    28  driver_timer.o(i.TIM4_IRQHandler)
269
+    __scatterload_copy                       0x08000679   Thumb Code    14  handlers.o(i.__scatterload_copy)
270
+    __scatterload_null                       0x08000687   Thumb Code     2  handlers.o(i.__scatterload_null)
271
+    __scatterload_zeroinit                   0x08000689   Thumb Code    14  handlers.o(i.__scatterload_zeroinit)
272
+    main                                     0x08000699   Thumb Code   124  principal.o(i.main)
273
+    Region$$Table$$Base                      0x0800072c   Number         0  anon$$obj.o(Region$$Table)
274
+    Region$$Table$$Limit                     0x0800074c   Number         0  anon$$obj.o(Region$$Table)
274 275
     MonTimer                                 0x20000000   Data           8  principal.o(.data)
275 276
     greenLed                                 0x20000008   Data           8  principal.o(.data)
276 277
     sortiePWM                                0x20000010   Data           8  principal.o(.data)
@@ -288,9 +289,9 @@ Memory Map of the image
288 289
 
289 290
   Image Entry point : 0x08000105
290 291
 
291
-  Load Region LR_1 (Base: 0x08000000, Size: 0x0000079c, Max: 0xffffffff, ABSOLUTE)
292
+  Load Region LR_1 (Base: 0x08000000, Size: 0x00000774, Max: 0xffffffff, ABSOLUTE)
292 293
 
293
-    Execution Region ER_RO (Exec base: 0x08000000, Load base: 0x08000000, Size: 0x00000774, Max: 0xffffffff, ABSOLUTE)
294
+    Execution Region ER_RO (Exec base: 0x08000000, Load base: 0x08000000, Size: 0x0000074c, Max: 0xffffffff, ABSOLUTE)
294 295
 
295 296
     Exec Addr    Load Addr    Size         Type   Attr      Idx    E Section Name        Object
296 297
 
@@ -315,36 +316,35 @@ Memory Map of the image
315 316
     0x08000238   0x08000238   0x00000024   Code   RO          299    .text               mc_w.l(init.o)
316 317
     0x0800025c   0x0800025c   0x00000028   Code   RO          129    i.Activate_TIM      driver_timer.o
317 318
     0x08000284   0x08000284   0x00000018   Code   RO           72    i.MyGPIO_Activate   driver_gpio.o
318
-    0x0800029c   0x0800029c   0x000000ec   Code   RO           73    i.MyGPIO_Init       driver_gpio.o
319
-    0x08000388   0x08000388   0x00000008   Code   RO           76    i.MyGPIO_Set        driver_gpio.o
320
-    0x08000390   0x08000390   0x00000012   Code   RO          131    i.MyTimer_Base_Init  driver_timer.o
321
-    0x080003a2   0x080003a2   0x00000002   PAD
322
-    0x080003a4   0x080003a4   0x000000c0   Code   RO          132    i.MyTimer_PWM       driver_timer.o
323
-    0x08000464   0x08000464   0x00000084   Code   RO          133    i.MyTimer_PWM_set_cycle  driver_timer.o
324
-    0x080004e8   0x080004e8   0x00000008   Code   RO          228    i.SetSysClock       system_stm32f10x.o
325
-    0x080004f0   0x080004f0   0x000000e0   Code   RO          229    i.SetSysClockTo72   system_stm32f10x.o
326
-    0x080005d0   0x080005d0   0x00000060   Code   RO          231    i.SystemInit        system_stm32f10x.o
327
-    0x08000630   0x08000630   0x00000024   Code   RO          134    i.TIM1_TRG_COM_IRQHandler  driver_timer.o
328
-    0x08000654   0x08000654   0x00000024   Code   RO          135    i.TIM2_IRQHandler   driver_timer.o
329
-    0x08000678   0x08000678   0x00000024   Code   RO          136    i.TIM3_IRQHandler   driver_timer.o
330
-    0x0800069c   0x0800069c   0x00000024   Code   RO          137    i.TIM4_IRQHandler   driver_timer.o
331
-    0x080006c0   0x080006c0   0x0000000e   Code   RO          303    i.__scatterload_copy  mc_w.l(handlers.o)
332
-    0x080006ce   0x080006ce   0x00000002   Code   RO          304    i.__scatterload_null  mc_w.l(handlers.o)
333
-    0x080006d0   0x080006d0   0x0000000e   Code   RO          305    i.__scatterload_zeroinit  mc_w.l(handlers.o)
334
-    0x080006de   0x080006de   0x00000002   PAD
335
-    0x080006e0   0x080006e0   0x00000074   Code   RO            5    i.main              principal.o
336
-    0x08000754   0x08000754   0x00000020   Data   RO          301    Region$$Table       anon$$obj.o
337
-
338
-
339
-    Execution Region ER_RW (Exec base: 0x20000000, Load base: 0x08000774, Size: 0x00000028, Max: 0xffffffff, ABSOLUTE)
319
+    0x0800029c   0x0800029c   0x000000a6   Code   RO           73    i.MyGPIO_Init       driver_gpio.o
320
+    0x08000342   0x08000342   0x00000008   Code   RO           76    i.MyGPIO_Set        driver_gpio.o
321
+    0x0800034a   0x0800034a   0x00000012   Code   RO          131    i.MyTimer_Base_Init  driver_timer.o
322
+    0x0800035c   0x0800035c   0x000000c0   Code   RO          132    i.MyTimer_PWM       driver_timer.o
323
+    0x0800041c   0x0800041c   0x00000084   Code   RO          133    i.MyTimer_PWM_set_cycle  driver_timer.o
324
+    0x080004a0   0x080004a0   0x00000008   Code   RO          228    i.SetSysClock       system_stm32f10x.o
325
+    0x080004a8   0x080004a8   0x000000e0   Code   RO          229    i.SetSysClockTo72   system_stm32f10x.o
326
+    0x08000588   0x08000588   0x00000060   Code   RO          231    i.SystemInit        system_stm32f10x.o
327
+    0x080005e8   0x080005e8   0x00000024   Code   RO          134    i.TIM1_TRG_COM_IRQHandler  driver_timer.o
328
+    0x0800060c   0x0800060c   0x00000024   Code   RO          135    i.TIM2_IRQHandler   driver_timer.o
329
+    0x08000630   0x08000630   0x00000024   Code   RO          136    i.TIM3_IRQHandler   driver_timer.o
330
+    0x08000654   0x08000654   0x00000024   Code   RO          137    i.TIM4_IRQHandler   driver_timer.o
331
+    0x08000678   0x08000678   0x0000000e   Code   RO          303    i.__scatterload_copy  mc_w.l(handlers.o)
332
+    0x08000686   0x08000686   0x00000002   Code   RO          304    i.__scatterload_null  mc_w.l(handlers.o)
333
+    0x08000688   0x08000688   0x0000000e   Code   RO          305    i.__scatterload_zeroinit  mc_w.l(handlers.o)
334
+    0x08000696   0x08000696   0x00000002   PAD
335
+    0x08000698   0x08000698   0x00000094   Code   RO            5    i.main              principal.o
336
+    0x0800072c   0x0800072c   0x00000020   Data   RO          301    Region$$Table       anon$$obj.o
337
+
338
+
339
+    Execution Region ER_RW (Exec base: 0x20000000, Load base: 0x0800074c, Size: 0x00000028, Max: 0xffffffff, ABSOLUTE)
340 340
 
341 341
     Exec Addr    Load Addr    Size         Type   Attr      Idx    E Section Name        Object
342 342
 
343
-    0x20000000   0x08000774   0x00000018   Data   RW            6    .data               principal.o
344
-    0x20000018   0x0800078c   0x00000010   Data   RW          140    .data               driver_timer.o
343
+    0x20000000   0x0800074c   0x00000018   Data   RW            6    .data               principal.o
344
+    0x20000018   0x08000764   0x00000010   Data   RW          140    .data               driver_timer.o
345 345
 
346 346
 
347
-    Execution Region ER_ZI (Exec base: 0x20000028, Load base: 0x0800079c, Size: 0x00000400, Max: 0xffffffff, ABSOLUTE)
347
+    Execution Region ER_ZI (Exec base: 0x20000028, Load base: 0x08000774, Size: 0x00000400, Max: 0xffffffff, ABSOLUTE)
348 348
 
349 349
     Exec Addr    Load Addr    Size         Type   Attr      Idx    E Section Name        Object
350 350
 
@@ -358,16 +358,16 @@ Image component sizes
358 358
 
359 359
       Code (inc. data)   RO Data    RW Data    ZI Data      Debug   Object Name
360 360
 
361
-       268          6          0          0          0       2517   driver_gpio.o
361
+       198          6          0          0          0       2489   driver_gpio.o
362 362
        526         36          0         16          0       5511   driver_timer.o
363
-       116         18          0         24          0     208365   principal.o
363
+       148         24          0         24          0     208381   principal.o
364 364
         36          8        236          0       1024        840   startup_stm32f10x_md.o
365 365
        328         28          0          0          0       2101   system_stm32f10x.o
366 366
 
367 367
     ----------------------------------------------------------------------
368
-      1276         96        268         40       1024     219334   Object Totals
368
+      1236        102        268         40       1024     219322   Object Totals
369 369
          0          0         32          0          0          0   (incl. Generated)
370
-         2          0          0          0          0          0   (incl. Padding)
370
+         0          0          0          0          0          0   (incl. Padding)
371 371
 
372 372
     ----------------------------------------------------------------------
373 373
 
@@ -411,15 +411,15 @@ Image component sizes
411 411
 
412 412
       Code (inc. data)   RO Data    RW Data    ZI Data      Debug   
413 413
 
414
-      1640        112        268         40       1024     219154   Grand Totals
415
-      1640        112        268         40       1024     219154   ELF Image Totals
416
-      1640        112        268         40          0          0   ROM Totals
414
+      1600        118        268         40       1024     219142   Grand Totals
415
+      1600        118        268         40       1024     219142   ELF Image Totals
416
+      1600        118        268         40          0          0   ROM Totals
417 417
 
418 418
 ==============================================================================
419 419
 
420
-    Total RO  Size (Code + RO Data)                 1908 (   1.86kB)
420
+    Total RO  Size (Code + RO Data)                 1868 (   1.82kB)
421 421
     Total RW  Size (RW Data + ZI Data)              1064 (   1.04kB)
422
-    Total ROM Size (Code + RO Data + RW Data)       1948 (   1.90kB)
422
+    Total ROM Size (Code + RO Data + RW Data)       1908 (   1.86kB)
423 423
 
424 424
 ==============================================================================
425 425
 

BIN
timer_act2/Objects/driver_gpio.crf View File


+ 1
- 1
timer_act2/Objects/driver_gpio.d View File

@@ -1,7 +1,7 @@
1 1
 .\objects\driver_gpio.o: Includes\Driver_GPIO.c
2 2
 .\objects\driver_gpio.o: Includes\Driver_GPIO.h
3 3
 .\objects\driver_gpio.o: C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\stm32f10x.h
4
-.\objects\driver_gpio.o: .\RTE\_Simulation\RTE_Components.h
4
+.\objects\driver_gpio.o: .\RTE\_carteSTM\RTE_Components.h
5 5
 .\objects\driver_gpio.o: C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\core_cm3.h
6 6
 .\objects\driver_gpio.o: C:\Keil_v5\ARM\ARMCC\Bin\..\include\stdint.h
7 7
 .\objects\driver_gpio.o: C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cmsis_version.h

BIN
timer_act2/Objects/driver_gpio.o View File


BIN
timer_act2/Objects/driver_timer.crf View File


+ 1
- 1
timer_act2/Objects/driver_timer.d View File

@@ -1,7 +1,7 @@
1 1
 .\objects\driver_timer.o: Includes\Driver_TIMER.c
2 2
 .\objects\driver_timer.o: Includes\Driver_TIMER.h
3 3
 .\objects\driver_timer.o: C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\stm32f10x.h
4
-.\objects\driver_timer.o: .\RTE\_Simulation\RTE_Components.h
4
+.\objects\driver_timer.o: .\RTE\_carteSTM\RTE_Components.h
5 5
 .\objects\driver_timer.o: C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\core_cm3.h
6 6
 .\objects\driver_timer.o: C:\Keil_v5\ARM\ARMCC\Bin\..\include\stdint.h
7 7
 .\objects\driver_timer.o: C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cmsis_version.h

BIN
timer_act2/Objects/driver_timer.o View File


BIN
timer_act2/Objects/principal.crf View File


+ 1
- 1
timer_act2/Objects/principal.d View File

@@ -1,6 +1,6 @@
1 1
 .\objects\principal.o: Source\principal.c
2 2
 .\objects\principal.o: C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\stm32f10x.h
3
-.\objects\principal.o: .\RTE\_Simulation\RTE_Components.h
3
+.\objects\principal.o: .\RTE\_carteSTM\RTE_Components.h
4 4
 .\objects\principal.o: C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\core_cm3.h
5 5
 .\objects\principal.o: C:\Keil_v5\ARM\ARMCC\Bin\..\include\stdint.h
6 6
 .\objects\principal.o: C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cmsis_version.h

BIN
timer_act2/Objects/principal.o View File


BIN
timer_act2/Objects/startup_stm32f10x_md.o View File


BIN
timer_act2/Objects/system_stm32f10x.crf View File


+ 1
- 1
timer_act2/Objects/system_stm32f10x.d View File

@@ -1,6 +1,6 @@
1 1
 .\objects\system_stm32f10x.o: RTE\Device\STM32F103RB\system_stm32f10x.c
2 2
 .\objects\system_stm32f10x.o: C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\stm32f10x.h
3
-.\objects\system_stm32f10x.o: .\RTE\_Simulation\RTE_Components.h
3
+.\objects\system_stm32f10x.o: .\RTE\_carteSTM\RTE_Components.h
4 4
 .\objects\system_stm32f10x.o: C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\core_cm3.h
5 5
 .\objects\system_stm32f10x.o: C:\Keil_v5\ARM\ARMCC\Bin\..\include\stdint.h
6 6
 .\objects\system_stm32f10x.o: C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cmsis_version.h

BIN
timer_act2/Objects/system_stm32f10x.o View File


BIN
timer_act2/Objects/timer_act2.axf View File


+ 7
- 7
timer_act2/Objects/timer_act2.build_log.htm View File

@@ -17,7 +17,7 @@ Library Manager: ArmAr.exe V5.06 update 7 (build 960)
17 17
 Hex Converter:   FromElf.exe V5.06 update 7 (build 960)
18 18
 CPU DLL:         SARMCM3.DLL V5.33.0.0
19 19
 Dialog DLL:      DARMSTM.DLL V1.68.0.0
20
-Target DLL:      UL2CM3.DLL V1.163.9.0
20
+Target DLL:      STLink\ST-LINKIII-KEIL_SWO.dll V3.0.8.0
21 21
 Dialog DLL:      TARMSTM.DLL V1.66.0.0
22 22
  
23 23
 <h2>Project:</h2>
@@ -26,14 +26,14 @@ Project File Date:  09/20/2021
26 26
 
27 27
 <h2>Output:</h2>
28 28
 *** Using Compiler 'V5.06 update 7 (build 960)', folder: 'C:\Keil_v5\ARM\ARMCC\Bin'
29
-Rebuild target 'Simulation'
29
+Rebuild target 'carteSTM'
30 30
 assembling startup_stm32f10x_md.s...
31
+compiling system_stm32f10x.c...
32
+compiling Driver_GPIO.c...
31 33
 compiling principal.c...
32 34
 compiling Driver_TIMER.c...
33
-compiling Driver_GPIO.c...
34
-compiling system_stm32f10x.c...
35 35
 linking...
36
-Program Size: Code=1640 RO-data=268 RW-data=40 ZI-data=1024  
36
+Program Size: Code=1600 RO-data=268 RW-data=40 ZI-data=1024  
37 37
 ".\Objects\timer_act2.axf" - 0 Error(s), 0 Warning(s).
38 38
 
39 39
 <h2>Software Packages used:</h2>
@@ -52,7 +52,7 @@ Package Vendor: Keil
52 52
 
53 53
 <h2>Collection of Component include folders:</h2>
54 54
   .\RTE\Device\STM32F103RB
55
-  .\RTE\_Simulation
55
+  .\RTE\_carteSTM
56 56
   C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include
57 57
   C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include
58 58
 
@@ -65,7 +65,7 @@ Package Vendor: Keil
65 65
       Source file:   Device\Source\system_stm32f10x.c
66 66
       Include file:  RTE_Driver\Config\RTE_Device.h
67 67
       Source file:   Device\Source\ARM\STM32F1xx_OPT.s
68
-Build Time Elapsed:  00:00:01
68
+Build Time Elapsed:  00:00:00
69 69
 </pre>
70 70
 </body>
71 71
 </html>

+ 5
- 3
timer_act2/Objects/timer_act2.htm View File

@@ -3,7 +3,7 @@
3 3
 <title>Static Call Graph - [.\Objects\timer_act2.axf]</title></head>
4 4
 <body><HR>
5 5
 <H1>Static Call Graph for image .\Objects\timer_act2.axf</H1><HR>
6
-<BR><P>#&#060CALLGRAPH&#062# ARM Linker, 5060960: Last Updated: Thu Sep 30 17:00:44 2021
6
+<BR><P>#&#060CALLGRAPH&#062# ARM Linker, 5060960: Last Updated: Mon Oct 04 17:14:18 2021
7 7
 <BR><P>
8 8
 <H3>Maximum Stack Usage =         32 bytes + Unknown(Cycles, Untraceable Function Pointers)</H3><H3>
9 9
 Call chain for Maximum Stack Depth:</H3>
@@ -342,7 +342,7 @@ Global Symbols
342 342
 <BR><BR>[Called By]<UL><LI><a href="#[35]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;main
343 343
 </UL>
344 344
 
345
-<P><STRONG><a name="[3e]"></a>MyGPIO_Init</STRONG> (Thumb, 236 bytes, Stack size 4 bytes, driver_gpio.o(i.MyGPIO_Init))
345
+<P><STRONG><a name="[3e]"></a>MyGPIO_Init</STRONG> (Thumb, 166 bytes, Stack size 4 bytes, driver_gpio.o(i.MyGPIO_Init))
346 346
 <BR><BR>[Stack]<UL><LI>Max Depth = 4<LI>Call Chain = MyGPIO_Init
347 347
 </UL>
348 348
 <BR>[Calls]<UL><LI><a href="#[3f]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;MyGPIO_Set
@@ -352,6 +352,7 @@ Global Symbols
352 352
 
353 353
 <P><STRONG><a name="[3f]"></a>MyGPIO_Set</STRONG> (Thumb, 8 bytes, Stack size 0 bytes, driver_gpio.o(i.MyGPIO_Set))
354 354
 <BR><BR>[Called By]<UL><LI><a href="#[3e]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;MyGPIO_Init
355
+<LI><a href="#[35]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;main
355 356
 </UL>
356 357
 
357 358
 <P><STRONG><a name="[47]"></a>MyTimer_Base_Init</STRONG> (Thumb, 18 bytes, Stack size 0 bytes, driver_timer.o(i.MyTimer_Base_Init))
@@ -405,12 +406,13 @@ Global Symbols
405 406
 
406 407
 <P><STRONG><a name="[55]"></a>__scatterload_zeroinit</STRONG> (Thumb, 14 bytes, Stack size unknown bytes, handlers.o(i.__scatterload_zeroinit), UNUSED)
407 408
 
408
-<P><STRONG><a name="[35]"></a>main</STRONG> (Thumb, 98 bytes, Stack size 0 bytes, principal.o(i.main))
409
+<P><STRONG><a name="[35]"></a>main</STRONG> (Thumb, 124 bytes, Stack size 0 bytes, principal.o(i.main))
409 410
 <BR><BR>[Stack]<UL><LI>Max Depth = 32<LI>Call Chain = main &rArr; MyTimer_PWM_set_cycle &rArr; __aeabi_fmul
410 411
 </UL>
411 412
 <BR>[Calls]<UL><LI><a href="#[40]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;MyTimer_PWM_set_cycle
412 413
 <LI><a href="#[48]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;MyTimer_PWM
413 414
 <LI><a href="#[47]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;MyTimer_Base_Init
415
+<LI><a href="#[3f]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;MyGPIO_Set
414 416
 <LI><a href="#[3e]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;MyGPIO_Init
415 417
 <LI><a href="#[46]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;MyGPIO_Activate
416 418
 <LI><a href="#[45]">&gt;&gt;</a>&nbsp;&nbsp;&nbsp;Activate_TIM

+ 6
- 6
timer_act2/Objects/timer_act2_Simulation.dep View File

@@ -1,6 +1,6 @@
1 1
 Dependencies for Project 'timer_act2', Target 'Simulation': (DO NOT MODIFY !)
2 2
 CompilerVersion: 5060960::V5.06 update 7 (build 960)::.\ARMCC
3
-F (.\Source\principal.c)(0x6155BFA1)(-c --cpu Cortex-M3 -D__EVAL -D__MICROLIB -g -O0 --apcs=interwork --split_sections -I .\Includes

-I.\RTE\Device\STM32F103RB

-I.\RTE\_Simulation

-IC:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include

-IC:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include

-D__UVISION_VERSION="533" -D_RTE_ -DSTM32F10X_MD -D_RTE_

-o .\objects\principal.o --omf_browse .\objects\principal.crf --depend .\objects\principal.d)
3
+F (.\Source\principal.c)(0x615B1920)(-c --cpu Cortex-M3 -D__EVAL -D__MICROLIB -g -O0 --apcs=interwork --split_sections -I .\Includes

-I.\RTE\Device\STM32F103RB

-I.\RTE\_Simulation

-IC:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include

-IC:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include

-D__UVISION_VERSION="533" -D_RTE_ -DSTM32F10X_MD -D_RTE_

-o .\objects\principal.o --omf_browse .\objects\principal.crf --depend .\objects\principal.d)
4 4
 I (C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\stm32f10x.h)(0x58259ADC)
5 5
 I (.\RTE\_Simulation\RTE_Components.h)(0x6155BC26)
6 6
 I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\core_cm3.h)(0x5E8F3392)
@@ -10,8 +10,8 @@ I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cms
10 10
 I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cmsis_armcc.h)(0x5E8F3392)
11 11
 I (C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\system_stm32f10x.h)(0x58259ADC)
12 12
 I (.\Includes\Driver_GPIO.h)(0x6155C0E0)
13
-I (.\Includes\Driver_TIMER.h)(0x6155D118)
14
-F (.\Includes\Driver_GPIO.c)(0x614DFC28)(-c --cpu Cortex-M3 -D__EVAL -D__MICROLIB -g -O0 --apcs=interwork --split_sections -I .\Includes

-I.\RTE\Device\STM32F103RB

-I.\RTE\_Simulation

-IC:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include

-IC:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include

-D__UVISION_VERSION="533" -D_RTE_ -DSTM32F10X_MD -D_RTE_

-o .\objects\driver_gpio.o --omf_browse .\objects\driver_gpio.crf --depend .\objects\driver_gpio.d)
13
+I (.\Includes\Driver_TIMER.h)(0x6155D187)
14
+F (.\Includes\Driver_GPIO.c)(0x615B16FD)(-c --cpu Cortex-M3 -D__EVAL -D__MICROLIB -g -O0 --apcs=interwork --split_sections -I .\Includes

-I.\RTE\Device\STM32F103RB

-I.\RTE\_Simulation

-IC:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include

-IC:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include

-D__UVISION_VERSION="533" -D_RTE_ -DSTM32F10X_MD -D_RTE_

-o .\objects\driver_gpio.o --omf_browse .\objects\driver_gpio.crf --depend .\objects\driver_gpio.d)
15 15
 I (Includes\Driver_GPIO.h)(0x6155C0E0)
16 16
 I (C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\stm32f10x.h)(0x58259ADC)
17 17
 I (.\RTE\_Simulation\RTE_Components.h)(0x6155BC26)
@@ -22,8 +22,8 @@ I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cms
22 22
 I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cmsis_armcc.h)(0x5E8F3392)
23 23
 I (C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\system_stm32f10x.h)(0x58259ADC)
24 24
 F (.\Includes\Driver_GPIO.h)(0x6155C0E0)()
25
-F (.\Includes\Driver_TIMER.c)(0x6155D111)(-c --cpu Cortex-M3 -D__EVAL -D__MICROLIB -g -O0 --apcs=interwork --split_sections -I .\Includes

-I.\RTE\Device\STM32F103RB

-I.\RTE\_Simulation

-IC:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include

-IC:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include

-D__UVISION_VERSION="533" -D_RTE_ -DSTM32F10X_MD -D_RTE_

-o .\objects\driver_timer.o --omf_browse .\objects\driver_timer.crf --depend .\objects\driver_timer.d)
26
-I (Includes\Driver_TIMER.h)(0x6155D118)
25
+F (.\Includes\Driver_TIMER.c)(0x615B1738)(-c --cpu Cortex-M3 -D__EVAL -D__MICROLIB -g -O0 --apcs=interwork --split_sections -I .\Includes

-I.\RTE\Device\STM32F103RB

-I.\RTE\_Simulation

-IC:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include

-IC:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include

-D__UVISION_VERSION="533" -D_RTE_ -DSTM32F10X_MD -D_RTE_

-o .\objects\driver_timer.o --omf_browse .\objects\driver_timer.crf --depend .\objects\driver_timer.d)
26
+I (Includes\Driver_TIMER.h)(0x6155D187)
27 27
 I (C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\stm32f10x.h)(0x58259ADC)
28 28
 I (.\RTE\_Simulation\RTE_Components.h)(0x6155BC26)
29 29
 I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\core_cm3.h)(0x5E8F3392)
@@ -32,7 +32,7 @@ I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cms
32 32
 I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cmsis_compiler.h)(0x5E836932)
33 33
 I (C:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include\cmsis_armcc.h)(0x5E8F3392)
34 34
 I (C:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include\system_stm32f10x.h)(0x58259ADC)
35
-F (.\Includes\Driver_TIMER.h)(0x6155D118)()
35
+F (.\Includes\Driver_TIMER.h)(0x6155D187)()
36 36
 F (RTE\Device\STM32F103RB\RTE_Device.h)(0x59284216)()
37 37
 F (RTE\Device\STM32F103RB\startup_stm32f10x_md.s)(0x58259ADC)(--cpu Cortex-M3 --pd "__EVAL SETA 1" -g --apcs=interwork --pd "__MICROLIB SETA 1"

-I.\RTE\Device\STM32F103RB

-I.\RTE\_Simulation

-IC:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include

-IC:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include

--pd "__UVISION_VERSION SETA 533" --pd "_RTE_ SETA 1" --pd "STM32F10X_MD SETA 1" --pd "_RTE_ SETA 1"

--list .\listings\startup_stm32f10x_md.lst --xref -o .\objects\startup_stm32f10x_md.o --depend .\objects\startup_stm32f10x_md.d)
38 38
 F (RTE\Device\STM32F103RB\system_stm32f10x.c)(0x58259ADC)(-c --cpu Cortex-M3 -D__EVAL -D__MICROLIB -g -O0 --apcs=interwork --split_sections -I .\Includes

-I.\RTE\Device\STM32F103RB

-I.\RTE\_Simulation

-IC:\Users\chauz\AppData\Local\Arm\Packs\ARM\CMSIS\5.7.0\CMSIS\Core\Include

-IC:\Users\chauz\AppData\Local\Arm\Packs\Keil\STM32F1xx_DFP\2.3.0\Device\Include

-D__UVISION_VERSION="533" -D_RTE_ -DSTM32F10X_MD -D_RTE_

-o .\objects\system_stm32f10x.o --omf_browse .\objects\system_stm32f10x.crf --depend .\objects\system_stm32f10x.d)

+ 21
- 0
timer_act2/RTE/_carteSTM/RTE_Components.h View File

@@ -0,0 +1,21 @@
1
+

2
+/*

3
+ * Auto generated Run-Time-Environment Configuration File

4
+ *      *** Do not modify ! ***

5
+ *

6
+ * Project: 'timer_act2' 

7
+ * Target:  'carteSTM' 

8
+ */

9
+

10
+#ifndef RTE_COMPONENTS_H

11
+#define RTE_COMPONENTS_H

12
+

13
+

14
+/*

15
+ * Define the Device Header File: 

16
+ */

17
+#define CMSIS_device_header "stm32f10x.h"

18
+

19
+

20
+

21
+#endif /* RTE_COMPONENTS_H */


+ 11
- 9
timer_act2/Source/principal.c View File

@@ -12,11 +12,11 @@ void callback_TIM2(void) {
12 12
 
13 13
 int main(void) {
14 14
 	//activation du timer 2 et du GPIO A
15
-	Activate_TIM(2);
15
+	Activate_TIM(1);
16 16
 	MyGPIO_Activate(1);
17 17
 
18 18
 	//Configuration du timer 2
19
-	MonTimer.Timer = TIM2 ;
19
+	MonTimer.Timer = TIM1 ;
20 20
 
21 21
 	//méthode PGCD
22 22
 	//MonTimer.ARR = 65454;
@@ -29,24 +29,26 @@ int main(void) {
29 29
 	MonTimer.PSC = 0 ;
30 30
 	MyTimer_Base_Init(&MonTimer);
31 31
 
32
-	//Configuration de la sortie PWM timer 2 channel 3 sur pin PA2
32
+	//Configuration de la sortie PWM timer 2 channel 4 sur pin PA2
33 33
 	sortiePWM.GPIO = GPIOA;
34
-	sortiePWM.GPIO_Pin = 2 ;
34
+	sortiePWM.GPIO_Pin = 8 ;
35 35
 	sortiePWM.GPIO_Conf = AltOut_Ppull ;
36 36
 	MyGPIO_Init(&sortiePWM);
37
+	MyGPIO_Set(GPIOA, 8) ;
37 38
 
38
-	/*greenLed.GPIO = GPIOA;
39
+	//Configuration de la diode
40
+	greenLed.GPIO = GPIOA;
39 41
 	greenLed.GPIO_Pin = 5 ;
40 42
 	greenLed.GPIO_Conf = Out_Ppull ;
41
-	 
42
-	MyGPIO_Init(&greenLed);	*/
43
+	MyGPIO_Init(&greenLed);	
44
+
43 45
 
44 46
 	/*MyGPIO_Set(greenLed.GPIO,greenLed.GPIO_Pin);
45 47
 
46 48
 	MyTimer_Active_IT(TIM2, 1, callback_TIM2);*/
47 49
 	MyTimer_Base_Start(MonTimer.Timer);
48
-	MyTimer_PWM(MonTimer.Timer, 3);
49
-	MyTimer_PWM_set_cycle(MonTimer.Timer, 0.20, 3);
50
+	MyTimer_PWM(MonTimer.Timer, 1);
51
+	MyTimer_PWM_set_cycle(MonTimer.Timer, 0.2, 1);
50 52
 
51 53
 	while(1) {}
52 54
 

+ 95
- 95
timer_act2/timer_act2.uvguix.chauz
File diff suppressed because it is too large
View File


+ 22
- 7
timer_act2/timer_act2.uvoptx View File

@@ -125,7 +125,7 @@
125 125
         <SetRegEntry>
126 126
           <Number>0</Number>
127 127
           <Key>DLGDARM</Key>
128
-          <Name>(1010=75,104,451,661,0)(1007=-1,-1,-1,-1,0)(1008=-1,-1,-1,-1,0)(1009=-1,-1,-1,-1,0)(100=-1,-1,-1,-1,0)(110=60,88,280,548,0)(111=91,141,311,601,0)(1011=-1,-1,-1,-1,0)(180=-1,-1,-1,-1,0)(120=672,91,1093,518,0)(121=75,104,496,531,0)(122=-1,-1,-1,-1,0)(123=-1,-1,-1,-1,0)(140=-1,-1,-1,-1,0)(240=-1,-1,-1,-1,0)(190=-1,-1,-1,-1,0)(200=-1,-1,-1,-1,0)(170=-1,-1,-1,-1,0)(130=791,113,1385,864,0)(131=530,21,1124,772,0)(132=-1,-1,-1,-1,0)(133=-1,-1,-1,-1,0)(160=-1,-1,-1,-1,0)(161=-1,-1,-1,-1,0)(162=-1,-1,-1,-1,0)(210=-1,-1,-1,-1,0)(211=-1,-1,-1,-1,0)(220=-1,-1,-1,-1,0)(221=-1,-1,-1,-1,0)(230=-1,-1,-1,-1,0)(234=-1,-1,-1,-1,0)(231=-1,-1,-1,-1,0)(232=-1,-1,-1,-1,0)(233=-1,-1,-1,-1,0)(150=-1,-1,-1,-1,0)(151=-1,-1,-1,-1,0)</Name>
128
+          <Name>(1010=75,104,451,661,0)(1007=-1,-1,-1,-1,0)(1008=-1,-1,-1,-1,0)(1009=-1,-1,-1,-1,0)(100=-1,-1,-1,-1,0)(110=60,88,280,548,0)(111=91,141,311,601,0)(1011=-1,-1,-1,-1,0)(180=-1,-1,-1,-1,0)(120=1070,34,1491,461,0)(121=75,104,496,531,0)(122=-1,-1,-1,-1,0)(123=-1,-1,-1,-1,0)(140=-1,-1,-1,-1,0)(240=-1,-1,-1,-1,0)(190=-1,-1,-1,-1,0)(200=-1,-1,-1,-1,0)(170=-1,-1,-1,-1,0)(130=791,113,1385,864,0)(131=823,113,1417,864,0)(132=-1,-1,-1,-1,0)(133=-1,-1,-1,-1,0)(160=-1,-1,-1,-1,0)(161=-1,-1,-1,-1,0)(162=-1,-1,-1,-1,0)(210=-1,-1,-1,-1,0)(211=-1,-1,-1,-1,0)(220=-1,-1,-1,-1,0)(221=-1,-1,-1,-1,0)(230=-1,-1,-1,-1,0)(234=-1,-1,-1,-1,0)(231=-1,-1,-1,-1,0)(232=-1,-1,-1,-1,0)(233=-1,-1,-1,-1,0)(150=-1,-1,-1,-1,0)(151=-1,-1,-1,-1,0)</Name>
129 129
         </SetRegEntry>
130 130
         <SetRegEntry>
131 131
           <Number>0</Number>
@@ -184,13 +184,28 @@
184 184
       <LogicAnalyzers>
185 185
         <Wi>
186 186
           <IntNumber>0</IntNumber>
187
-          <FirstString>((PORTA &amp; 0x00000004) &gt;&gt; 2 &amp; 0x4) &gt;&gt; 2</FirstString>
188
-          <SecondString>000080000000000000000000000000000000F03F0000000000000000000000000000000028504F5254412026203078303030303030303429203E3E2032000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000001000000000000000000E03F19000000000000000000000000000000000000002C050008</SecondString>
187
+          <FirstString>`TIM2_CNT</FirstString>
188
+          <SecondString>00000000000000000000000000000000007086400000000000000000000000000000000054494D325F434E5400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000010000009A9999999999C93F17000000000000000000000000000000000000006E050008</SecondString>
189 189
         </Wi>
190 190
         <Wi>
191 191
           <IntNumber>1</IntNumber>
192
-          <FirstString>`TIM2_CNT</FirstString>
193
-          <SecondString>00000000000000000000000000000000007086400000000000000000000000000000000054494D325F434E540000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000002000000000000000000E03F19000000000000000000000000000000000000006E050008</SecondString>
192
+          <FirstString>((porta &amp; 0x00000004) &gt;&gt; 2 &amp; 0x4) &gt;&gt; 2</FirstString>
193
+          <SecondString>000080000000000000000000000000000000F03F0000000000000000000000000000000028706F7274612026203078303030303030303429203E3E20320000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000020000009A9999999999C93F1700000000000000000000000000000000000000E0060008</SecondString>
194
+        </Wi>
195
+        <Wi>
196
+          <IntNumber>2</IntNumber>
197
+          <FirstString>((porta &amp; 0x00000008) &gt;&gt; 3 &amp; 0x8) &gt;&gt; 3</FirstString>
198
+          <SecondString>000080000000000000000000000000000000F03F0000000000000000000000000000000028706F7274612026203078303030303030303829203E3E20330000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000030000009A9999999999C93F1700000000000000000000000000000000000000E0060008</SecondString>
199
+        </Wi>
200
+        <Wi>
201
+          <IntNumber>3</IntNumber>
202
+          <FirstString>((porta &amp; 0x00000100) &gt;&gt; 8 &amp; 0x100) &gt;&gt; 8</FirstString>
203
+          <SecondString>000000000000000000000000000000000000F03F0000000000000000000000000000000028706F7274612026203078303030303031303029203E3E20380000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000040000009A9999999999C93F170000000000000000000000000000000000000098060008</SecondString>
204
+        </Wi>
205
+        <Wi>
206
+          <IntNumber>4</IntNumber>
207
+          <FirstString>`TIM1_CNT</FirstString>
208
+          <SecondString>FF000000000000000000000000000000007086400000000000000000000000000000000054494D315F434E5400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000050000009A9999999999C93F170000000000000000000000000000000000000014070008</SecondString>
194 209
         </Wi>
195 210
       </LogicAnalyzers>
196 211
       <DebugDescription>
@@ -307,7 +322,7 @@
307 322
         <SetRegEntry>
308 323
           <Number>0</Number>
309 324
           <Key>DLGTARM</Key>
310
-          <Name>(1010=75,104,451,661,0)(1007=-1,-1,-1,-1,0)(1008=-1,-1,-1,-1,0)(1009=-1,-1,-1,-1,0)(100=-1,-1,-1,-1,0)(110=-1,-1,-1,-1,0)(111=-1,-1,-1,-1,0)(1011=-1,-1,-1,-1,0)(180=-1,-1,-1,-1,0)(120=-1,-1,-1,-1,0)(121=-1,-1,-1,-1,0)(122=-1,-1,-1,-1,0)(123=-1,-1,-1,-1,0)(140=-1,-1,-1,-1,0)(240=-1,-1,-1,-1,0)(190=-1,-1,-1,-1,0)(200=-1,-1,-1,-1,0)(170=-1,-1,-1,-1,0)(130=150,126,744,820,0)(131=150,126,744,820,0)(132=-1,-1,-1,-1,0)(133=-1,-1,-1,-1,0)(160=-1,-1,-1,-1,0)(161=-1,-1,-1,-1,0)(162=-1,-1,-1,-1,0)(210=-1,-1,-1,-1,0)(211=-1,-1,-1,-1,0)(220=-1,-1,-1,-1,0)(221=-1,-1,-1,-1,0)(230=-1,-1,-1,-1,0)(231=-1,-1,-1,-1,0)(232=-1,-1,-1,-1,0)(233=-1,-1,-1,-1,0)(150=-1,-1,-1,-1,0)(151=-1,-1,-1,-1,0)</Name>
325
+          <Name>(1010=75,104,451,661,0)(1007=-1,-1,-1,-1,0)(1008=-1,-1,-1,-1,0)(1009=120,153,364,701,0)(100=15,39,661,712,0)(110=374,60,594,520,0)(111=361,92,581,552,0)(1011=-1,-1,-1,-1,0)(180=-1,-1,-1,-1,0)(120=426,114,847,519,0)(121=-1,-1,-1,-1,0)(122=-1,-1,-1,-1,0)(123=-1,-1,-1,-1,0)(140=-1,-1,-1,-1,0)(240=-1,-1,-1,-1,0)(190=-1,-1,-1,-1,0)(200=-1,-1,-1,-1,0)(170=-1,-1,-1,-1,0)(130=150,126,744,820,0)(131=307,45,901,739,0)(132=-1,-1,-1,-1,0)(133=-1,-1,-1,-1,0)(160=-1,-1,-1,-1,0)(161=-1,-1,-1,-1,0)(162=-1,-1,-1,-1,0)(210=-1,-1,-1,-1,0)(211=-1,-1,-1,-1,0)(220=-1,-1,-1,-1,0)(221=-1,-1,-1,-1,0)(230=-1,-1,-1,-1,0)(231=-1,-1,-1,-1,0)(232=-1,-1,-1,-1,0)(233=-1,-1,-1,-1,0)(150=-1,-1,-1,-1,0)(151=-1,-1,-1,-1,0)</Name>
311 326
         </SetRegEntry>
312 327
         <SetRegEntry>
313 328
           <Number>0</Number>
@@ -317,7 +332,7 @@
317 332
         <SetRegEntry>
318 333
           <Number>0</Number>
319 334
           <Key>ST-LINKIII-KEIL_SWO</Key>
320
-          <Name>-U-O206 -O206 -SF10000 -C0 -A0 -I0 -HNlocalhost -HP7184 -P1 -N00("ARM CoreSight SW-DP (ARM Core") -D00(1BA01477) -L00(0) -TO131090 -TC10000000 -TT10000000 -TP21 -TDS8007 -TDT0 -TDC1F -TIEFFFFFFFF -TIP8 -FO7 -FD20000000 -FC1000 -FN1 -FF0STM32F10x_128.FLM -FS08000000 -FL020000 -FP0($$Device:STM32F103RB$Flash\STM32F10x_128.FLM)</Name>
335
+          <Name>-U0672FF524951775087241345 -O206 -SF10000 -C0 -A0 -I0 -HNlocalhost -HP7184 -P1 -N00("ARM CoreSight SW-DP (ARM Core") -D00(1BA01477) -L00(0) -TO131090 -TC10000000 -TT10000000 -TP21 -TDS8007 -TDT0 -TDC1F -TIEFFFFFFFF -TIP8 -FO7 -FD20000000 -FC1000 -FN1 -FF0STM32F10x_128.FLM -FS08000000 -FL020000 -FP0($$Device:STM32F103RB$Flash\STM32F10x_128.FLM)</Name>
321 336
         </SetRegEntry>
322 337
         <SetRegEntry>
323 338
           <Number>0</Number>

Loading…
Cancel
Save