JeVois  1.21
JeVois Smart Embedded Machine Vision Toolkit
Share this page:
Loading...
Searching...
No Matches
Gadget.C File Reference
#include <jevois/Core/Gadget.H>
#include <jevois/Debug/Log.H>
#include <jevois/Core/VideoInput.H>
#include <jevois/Util/Utils.H>
#include <jevois/Util/Async.H>
#include <jevois/Core/VideoBuffers.H>
#include <jevois/Core/Engine.H>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <unistd.h>
#include <sys/time.h>
Include dependency graph for Gadget.C:

Go to the source code of this file.

Macros

#define success()   { itsErrorCode = 0; }
 
#define failure(code)   { resp.length = -EL2HLT; itsErrorCode = code; }
 
#define byteresponse(val)   { resp.data[0] = val; resp.length = 1; itsErrorCode = 0; }
 
#define wordresponse(val)
 
#define intresponse(val)
 
#define arrayblankresponse(len)   { memset(resp.data, 0, len); resp.length = len; itsErrorCode = 0; }
 

Macro Definition Documentation

◆ arrayblankresponse

#define arrayblankresponse (   len)    { memset(resp.data, 0, len); resp.length = len; itsErrorCode = 0; }

◆ byteresponse

#define byteresponse (   val)    { resp.data[0] = val; resp.length = 1; itsErrorCode = 0; }

◆ failure

#define failure (   code)    { resp.length = -EL2HLT; itsErrorCode = code; }

◆ intresponse

#define intresponse (   val)
Value:
{ resp.data[0] = val & 0xff; resp.data[1] = (val >> 8) & 0xff; \
resp.data[2] = (val >> 16) & 0xff; resp.data[3] = (val >> 24) & 0xff; \
resp.length = 4; itsErrorCode = 0; }

◆ success

#define success ( )    { itsErrorCode = 0; }

◆ wordresponse

#define wordresponse (   val)
Value:
{ resp.data[0] = val & 0xff; resp.data[1] = (val >> 8) & 0xff; \
resp.length = 2; itsErrorCode = 0; }