Do we still need to code GPIO_ID_PIN()?

User avatar
kolban
Posts: 131
Joined: Tue Jun 16, 2015 1:09 pm
Location: Fort Worth, Texas, USA

Do we still need to code GPIO_ID_PIN()?

Postby kolban » Wed Jul 15, 2015 9:29 am

There is a macro called GPIO_ID_PIN() which, when called with a logical pin number (eg. 14 for GPIO14) is supposed to return a value we can pass into the SDK APIs. However, examining the header file, I find that GPIO_ID_PIN(x) == x ... so effectively, this macro returns its own numeric parameter. This then begs the question ... is GPIO_ID_PIN() needed? Are we "future proofing" ourselves from some dramatic architecture change in the future? What is the thinking behind asking us to use this macro?

Neil

Who is online

Users browsing this forum: No registered users and 86 guests