MKE06 read pin

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 
394件の閲覧回数
gangliu
Contributor II

Hello, Thank you for seeing my problem,.I use the MKE06Z.I would like to know how to read the level of a pin.  Please show me how it works.Thank you!999.png

So this is my way of reading the pin level with '|' and I feel like this is going to be a lot of trouble, every time.

Best Regards!

GANG LIU

0 件の賞賛
1 解決策
329件の閲覧回数
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi GANG,

Please refer the code shown below:

if((GPIO_Read(GPIOB) & 0x2000000)==0x2000000)

 

Best Regards,

Robin

 

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
----------------------------------------------------------------------------------------------------------------------

元の投稿で解決策を見る

0 件の賞賛
1 返信
330件の閲覧回数
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi GANG,

Please refer the code shown below:

if((GPIO_Read(GPIOB) & 0x2000000)==0x2000000)

 

Best Regards,

Robin

 

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
----------------------------------------------------------------------------------------------------------------------

0 件の賞賛