diff options
author | Jonathan McCrohan <jmccrohan@gmail.com> | 2012-04-14 12:56:48 +0100 |
---|---|---|
committer | Jonathan McCrohan <jmccrohan@gmail.com> | 2012-04-14 12:56:48 +0100 |
commit | 0b624384cd52be20e61284551d832b499d7b7707 (patch) | |
tree | 6f95a4bbef47abc9720b96c0722e8f632aef228a /cphidgetgeneric.h | |
download | libphidget21-0b624384cd52be20e61284551d832b499d7b7707.tar.gz |
Imported Upstream version 2.1.8.20120216upstream/2.1.8.20120216
Diffstat (limited to '')
-rw-r--r-- | cphidgetgeneric.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/cphidgetgeneric.h b/cphidgetgeneric.h new file mode 100644 index 0000000..55fab44 --- /dev/null +++ b/cphidgetgeneric.h @@ -0,0 +1,35 @@ +#ifndef __CPHIDGETGENERIC
+#define __CPHIDGETGENERIC
+#include "cphidget.h"
+
+DPHANDLE(Generic)
+CHDRSTANDARD(Generic)
+
+CHDRGET(Generic,INPacketLength,int *length)
+CHDRGET(Generic,OUTPacketLength,int *length)
+
+CHDRGET(Generic,LastPacket,const unsigned char **packet, int *length)
+CHDRSET(Generic,Packet,unsigned char *packet, int length)
+CHDREVENT(Generic,Packet,const unsigned char *packet, int length)
+
+#ifndef EXTERNALPROTO
+struct _CPhidgetGeneric {
+ CPhidget phid;
+
+ int (CCONV *fptrPacket)(CPhidgetGenericHandle, void *, const unsigned char *, int);
+ void *fptrPacketptr;
+
+ unsigned char lastPacket[MAX_IN_PACKET_SIZE];
+
+ unsigned char buffer[MAX_OUT_PACKET_SIZE];
+
+ int in, out;
+
+ unsigned char outputPacket[MAX_OUT_PACKET_SIZE];
+ unsigned int outputPacketLen;
+} typedef CPhidgetGenericInfo;
+#endif
+
+/** @} */
+
+#endif
|