41 #ifndef YOCTO_PROXIMITY_H 42 #define YOCTO_PROXIMITY_H 57 #ifndef _Y_ISPRESENT_ENUM 58 #define _Y_ISPRESENT_ENUM 65 #ifndef _Y_PROXIMITYREPORTMODE_ENUM 66 #define _Y_PROXIMITYREPORTMODE_ENUM 74 #define Y_SIGNALVALUE_INVALID (YAPI_INVALID_DOUBLE) 75 #define Y_DETECTIONTHRESHOLD_INVALID (YAPI_INVALID_UINT) 76 #define Y_LASTTIMEAPPROACHED_INVALID (YAPI_INVALID_LONG) 77 #define Y_LASTTIMEREMOVED_INVALID (YAPI_INVALID_LONG) 78 #define Y_PULSECOUNTER_INVALID (YAPI_INVALID_LONG) 79 #define Y_PULSETIMER_INVALID (YAPI_INVALID_LONG) 94 #pragma option push -w-8022 146 double get_signalValue(
void);
149 {
return this->get_signalValue(); }
161 int get_detectionThreshold(
void);
164 {
return this->get_detectionThreshold(); }
178 int set_detectionThreshold(
int newval);
180 {
return this->set_detectionThreshold(newval); }
194 {
return this->get_isPresent(); }
206 s64 get_lastTimeApproached(
void);
209 {
return this->get_lastTimeApproached(); }
221 s64 get_lastTimeRemoved(
void);
224 {
return this->get_lastTimeRemoved(); }
235 s64 get_pulseCounter(
void);
238 {
return this->get_pulseCounter(); }
240 int set_pulseCounter(s64 newval);
242 {
return this->set_pulseCounter(newval); }
251 s64 get_pulseTimer(
void);
254 {
return this->get_pulseTimer(); }
269 {
return this->get_proximityReportMode(); }
287 {
return this->set_proximityReportMode(newval); }
316 static YProximity* FindProximity(
string func);
357 virtual int resetCounter(
void);
372 {
return this->nextProximity();}
s64 lastTimeRemoved(void)
Y_PROXIMITYREPORTMODE_enum proximityReportMode(void)
int setProximityReportMode(Y_PROXIMITYREPORTMODE_enum newval)
YProximityValueCallback _valueCallbackProximity
YProximityTimedReportCallback _timedReportCallbackProximity
static YProximity * First(void)
int setPulseCounter(s64 newval)
#define YAPI_INVALID_LONG
static YProximity * FirstProximity(void)
int detectionThreshold(void)
#define YAPI_INVALID_UINT
Y_ISPRESENT_enum _isPresent
YProximity * yFirstProximity(void)
static const double SIGNALVALUE_INVALID
Y_PROXIMITYREPORTMODE_enum
s64 lastTimeApproached(void)
virtual int registerTimedReportCallback(YSensorTimedReportCallback callback)
int setDetectionThreshold(int newval)
virtual int _invokeTimedReportCallback(YMeasure value)
virtual int _invokeValueCallback(string value)
virtual int _parseAttr(YJSONObject *json_val)
virtual int registerValueCallback(YSensorValueCallback callback)
#define YOCTO_CLASS_EXPORT
YProximity * yFindProximity(const string &func)
static YProximity * FindProximity(string func)
Y_ISPRESENT_enum isPresent(void)
static YProximity * Find(string func)
Y_PROXIMITYREPORTMODE_enum _proximityReportMode
void(* YProximityTimedReportCallback)(YProximity *func, YMeasure measure)
void(* YProximityValueCallback)(YProximity *func, const string &functionValue)