X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=firmware%2Finclude%2Fgfports.h;h=90214fa2e62fba966d8fe01ec4bd7c23b2c67928;hb=052771a83e020314b718e82d0b1b2a645a7c3d4f;hp=8cc10122f52b6d9c50bcab32c5f5a198f4bf4de2;hpb=35881308523d692dc4ff36cfac9fbf321515194e;p=goodfet diff --git a/firmware/include/gfports.h b/firmware/include/gfports.h index 8cc1012..90214fa 100644 --- a/firmware/include/gfports.h +++ b/firmware/include/gfports.h @@ -6,10 +6,13 @@ #ifndef GFPORTS #define GFPORTS +#ifdef MSP430 #include +#endif // N.B., only asm-clean CPP definitions allowed. + //Use P3 instead of P5 for target I/O on chips without P5. #ifndef __MSP430_HAS_PORT5__ #ifndef __MSP430_HAS_PORT5_R__ @@ -18,10 +21,10 @@ #define P5DIR P3DIR #define P5REN P3REN #define P5IN P3IN - #endif #endif + //Use false P5REN for 1612. #ifdef __MSP430_HAS_PORT5__ #ifndef __MSP430_HAS_PORT5_R__ @@ -30,5 +33,15 @@ #endif #endif +/* +//Use these instead of the explicit names. +#ifdef MSP430 +#define gfout P5OUT +#define gfin P5IN +#define gfdir P5DIR +#define gfren P5REN +#endif +*/ + #endif //GFPORTS