#ifndef __SPIPROT_H__
#define __SPIPROT_H__

#define SPIPROT_SYNC_CHAR         (0xAA)
#define SPIPROT_TERMINATOR        (0x00)


// returns: -1 if type invalid, 
//           0 if type valid but no param Count
//           1 if valid and indeterminite param len

#define SPIPROT_FRAME_TYPE_INVALID (-1)
#define SPIPROT_FRAME_TYPE_VALID_NO_PARAM_COUNT (0)
#define SPIPROT_FRAME_TYPE_VALID (1)

typedef int (*spiprotFrameValidatorType)(char); // validates the frame type
typedef int (*spiprotSizeofParam)(char); // takes a parameter tag and returns the number of bytes to expect

#endif /* __SPIPROT_H__ */
