diff --git a/pincfg.h b/pincfg.h new file mode 100644 index 0000000..7779f64 --- /dev/null +++ b/pincfg.h @@ -0,0 +1,36 @@ +#ifndef __PINCFG_H__ +#define __PINCFG_H__ + +typedef enum: uint8_t { + PIN_MODE_DIG_IN, + PIN_MODE_ANA_IN, + PIN_MODE_DIG_OUT, + PIN_MODE_ANA_OUT +} PIN_MODES; + +typedef enum: uint8_t { + PULLUP_OFF, + PULLUP_ON +} PULLUP_MODES; + +struct PinCfg { + PIN_MODES Mode; + union { + struct { + PULLUP_MODES Pullup; + } CfgDigIn; + struct { + uint8_t todo; + } CfgAnaIn; + struct { + uint8_t todo; + } CfgDigOut; + struct { + uint8_t todo; + } CfgAnaOut; + }; +}; + + + +#endif