你的浏览器版本过低,可能导致网站不能正常访问!
为了你能正常使用网站功能,请使用这些浏览器。

define 问题

[复制链接]
jxchen 提问时间:2019-1-19 12:20 /

我手头有一片nucelo STM32F411RE板子,是透过有源振荡器,osc in ,osc out (空接),然后这个振荡器是由 through STLINK MCO pin of STM32F103 microcontroller. The frequencycannot be changed and is fixed at 8 MHz.

我找不到这两个宏定义STM32F411xE,#define USE_HSE_BYPASS,这个在那边可以找的到


#if defined(STM32F411xE)    /*!< Uncomment the following line if you need to clock the STM32F411xE by HSE Bypass
     through STLINK MCO pin of STM32F103 microcontroller. The frequency cannot be changed
     and is fixed at 8 MHz.
     Hardware configuration needed for Nucleo Board:
     ?SB54, SB55 OFF
     ?R35 removed
     ?SB16, SB50 ON */
/* #define USE_HSE_BYPASS */     //这叙述为何被屏蔽掉

#if defined(USE_HSE_BYPASS)     
#define HSE_BYPASS_INPUT_FREQUENCY   8000000
#endif /* USE_HSE_BYPASS */   
#endif /* STM32F411xE */
收藏 评论2 发布时间:2019-1-19 12:20

举报

2个回答
子曰好人 回答时间:2019-1-19 13:10:27
注释里不是说过吗,叫你需要HSE Baypass就把那个注释取消掉呀,就是你中文注释那一行,对于NUCLEO硬件需要把SB54,SB55这两个地方断开,把R35移除,把SB16,SB50闭合

评分

参与人数 1蝴蝶豆 +2 收起 理由
STMCU + 2

查看全部评分

jxchen 回答时间:2019-1-21 22:28:57
感謝你的幫忙,另外一個問題如下:
• MCO from ST-LINK: MCO output of ST-LINK MCU is used as input clock. This
frequency cannot be changed, it is fixed at 8 MHz and connected to PF0/PD0/PH0-
OSC_IN of STM32 microcontroller.

我手头有片Nucleo STM32F411RE BOARD,外部晶振8MZ,固定不能改,我在Keil C/C++ 页面定义:USE_STDPERIPH_DRIVER,STM32F411xE,我移值标准固件库,
SYSTEM_STMF32F4XX.H,下列判断STM32F411xE关键词有效,就会执行这句 #define HSE_VALUE    ((uint32_t)25000000) /*!< Value of the External oscillator in Hz
就跟原厂定义8MHZ不同,我需要调整为: HSE_VALUE    ((uint32_t)8000000) /*!< Value of the External oscillator in Hz  8MHZ,还是不用理它!!!!


#if defined(STM32F40_41xxx) || defined(STM32F427_437xx)  || defined(STM32F429_439xx) || defined(STM32F401xx)  || defined(STM32F411xE)
#if !defined  (HSE_VALUE)
  #define HSE_VALUE    ((uint32_t)25000000) /*!< Value of the External oscillator in Hz

#endif /* HSE_VALUE */
#elif defined(STM32F446xx)
#if !defined  (HSE_VALUE)
  #define HSE_VALUE    ((uint32_t)8000000) /*!< Value of the External oscillator in Hz */
#endif /* HSE_VALUE */
#endif /* STM32F40_41xxx || STM32F427_437xx || STM32F429_439xx || STM32F401xx || STM32F411xE */
/**


所属标签

相似问题

关于意法半导体
我们是谁
投资者关系
意法半导体可持续发展举措
创新和工艺
招聘信息
联系我们
联系ST分支机构
寻找销售人员和分销渠道
社区
媒体中心
活动与培训
隐私策略
隐私策略
Cookies管理
行使您的权利
关注我们
st-img 微信公众号
st-img 手机版