Can I assign the function components in the code

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
chwa_1570756
Level 4
Level 4
25 sign-ins 25 replies posted 10 replies posted

Hello,

   

Can I assign those function components in the code dynamically?

   

e.g.,sometime I want to take P3.0,P3.1 as UART,sometime take as I2C in the one C code file,is it available?

   

Thanks.

   

Chris

0 Likes
2 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

The SCB based components can be used uninitialized. With the help of  different structs you can assign at run-time what the component shall do. Look in datasheet for initializing the SCB.

   

 

   

Bob

0 Likes

Thanks Bob,it is really helpful.

0 Likes