Picproje Elektronik Sitesi

MİKRODENETLEYİCİLER => ARM => Konuyu başlatan: Yuunus - 28 Şubat 2017, 23:13:52

Başlık: TIM_TimeBaseStructure hangi header in icinde
Gönderen: Yuunus - 28 Şubat 2017, 23:13:52
stm32f10x_tim.h bunun icinde aradim yok hal library indirdim onun icinde de bulamadim, yerinin bilen varsa ilgili header in linkini verebilir mi?
Başlık: Ynt: TIM_TimeBaseStructure hangi header in icinde
Gönderen: baran123 - 28 Şubat 2017, 23:55:02
TIM_TimeBaseInitTypeDef structure'ı stm32f10x_tim.h içinde tanımlı.
Dikkatli bakın.
Başlık: Ynt: TIM_TimeBaseStructure hangi header in icinde
Gönderen: Yuunus - 01 Mart 2017, 00:10:42
@baran123 yapinin prescaler ine erismek istiyorum
TIM_TimeBaseStructure.TIM_Prescaler = 0; gibi
ama benim header da yapi asagidaki gibi tanimli


typedef struct
{
  uint16_t TIM_Prescaler;         /*!< Specifies the prescaler value used to divide the TIM clock.
                                       This parameter can be a number between 0x0000 and 0xFFFF */

  uint16_t TIM_CounterMode;       /*!< Specifies the counter mode.
                                       This parameter can be a value of @ref TIM_Counter_Mode */

  uint16_t TIM_Period;            /*!< Specifies the period value to be loaded into the active
                                       Auto-Reload Register at the next update event.
                                       This parameter must be a number between 0x0000 and 0xFFFF.  */

  uint16_t TIM_ClockDivision;     /*!< Specifies the clock division.
                                      This parameter can be a value of @ref TIM_Clock_Division_CKD */

  uint8_t TIM_RepetitionCounter;  /*!< Specifies the repetition counter value. Each time the RCR downcounter
                                       reaches zero, an update event is generated and counting restarts
                                       from the RCR value (N).
                                       This means in PWM mode that (N+1) corresponds to:
                                          - the number of PWM periods in edge-aligned mode
                                          - the number of half PWM period in center-aligned mode
                                       This parameter must be a number between 0x00 and 0xFF.
                                       @note This parameter is valid only for TIM1 and TIM8. */
} TIM_TimeBaseInitTypeDef;

yani benim aradigim yapi elemani bunun icin de yok
Başlık: Ynt: TIM_TimeBaseStructure hangi header in icinde
Gönderen: skara1214 - 01 Mart 2017, 00:17:20
direk TIMx->PSC diye erişşen olmuyormu?
Başlık: Ynt: TIM_TimeBaseStructure hangi header in icinde
Gönderen: Yuunus - 01 Mart 2017, 00:27:06
olur niye olmasin da yorucu oluyor, bir o degilki bir alay kod var hem adamlar registera yapi ile erisilir hale getirmisler kastirmanin alemi yok diye dusundum, hem surekli hangi registera hangi degerin atanacagini akilda tutmak zor oluyor, kritik durumlarda registera gidiyorum.


Hallettim arkadaslar sagolun;