X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=server%2Fpin_test.c;h=bcdf92e9824edd1bbfd66a324f2960f22b0d2881;hb=6fb169f93cfef6479fd9572aa478270568957f4f;hp=ca857ecd4452af72a3b1ec42fb1d4e4c8b55a8b0;hpb=1faf2ef76c719ed79e13b359591082854e739fa3;p=matches%2FMCTX3420.git diff --git a/server/pin_test.c b/server/pin_test.c index ca857ec..bcdf92e 100644 --- a/server/pin_test.c +++ b/server/pin_test.c @@ -12,8 +12,8 @@ */ void Pin_Init() { - for (int i = 0; i < 128; ++i) - GPIO_Export(i); + for (int i = 0; i < GPIO_NUM_PINS; ++i) + GPIO_Export(g_index_to_gpio[i]); for (int i = 0; i < ADC_NUM_PINS; ++i) ADC_Export(); @@ -28,7 +28,7 @@ void Pin_Init() void Pin_Close() { for (int i = 0; i < GPIO_NUM_PINS; ++i) - GPIO_Unexport(i); + GPIO_Unexport(g_index_to_gpio[i]); for (int i = 0; i < ADC_NUM_PINS; ++i) ADC_Unexport(i);