GPIOA.c 651 B

1234567891011121314151617181920212223242526
  1. #include "stm32f10x.h" // Device header
  2. #include "CONFIG.h"
  3. #include "AT.h"
  4. void GPIOA_Init(void)
  5. {
  6. RCC_APB2PeriphClockCmd(WAKE_GPIO_RCC, ENABLE);
  7. GPIO_InitTypeDef GPIO_InitStructure;
  8. GPIO_InitStructure.GPIO_Mode = GPIO_Mode_Out_PP;
  9. GPIO_InitStructure.GPIO_Pin = WAKE_GPIO_Pin;
  10. GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz;
  11. GPIO_Init(WAKE_GPIO, &GPIO_InitStructure);
  12. // //GPIO_SetBits(WAKE_GPIO, WAKE_GPIO_Pin); // 4gÀ­¸ß
  13. #if NBFLAG
  14. GPIO_ResetBits(WAKE_GPIO, WAKE_GPIO_Pin); // nbÀ­µÍ
  15. #else
  16. GPIO_SetBits(WAKE_GPIO, WAKE_GPIO_Pin); // 4gÀ­¸ß
  17. #endif
  18. // GPIO_ResetBits(WAKE_GPIO, WAKE_GPIO_Pin); // nbÀ­µÍ
  19. }