Reading and Writing GPIO pin

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

cross mob
D_Sd_3235936
Level 4
Level 4
25 sign-ins 50 questions asked 25 replies posted

Hi,

Is there a general function to read and write pin according to a number?

There are psoc functions generated to each pin individualy, but i am looking for a general function to do it.

Thanks

0 Likes
1 Solution
odissey1
Level 9
Level 9
First comment on KBA 1000 replies posted 750 replies posted

Bragadeesh,

Please check this thread for possible solutions

Macros for bit band access?

/odissey1

View solution in original post

0 Likes
3 Replies
BragadeeshV
Moderator
Moderator
Moderator
First question asked 1000 replies posted 750 replies posted

Could you please elaborate your question?

Regards,

Bragadeesh

Regards,
Bragadeesh
0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

To have something like Mypin[4]_Write(1); in your program you will need an array of pointers to functions. See here.

Bob

0 Likes
odissey1
Level 9
Level 9
First comment on KBA 1000 replies posted 750 replies posted

Bragadeesh,

Please check this thread for possible solutions

Macros for bit band access?

/odissey1

0 Likes