#include "ydef.h"
Go to the source code of this file.
Classes | |
struct | yAbsUrl |
union | YHashSlot |
struct | yWhitePageEntry |
struct | yYellowPageArray |
struct | yYellowPageCateg |
struct | yYellowPageEntry |
Macros | |
#define | HASH_BUF_POW 5 /* HASH_BUF_POW = log_2(HASH_BUF_SIZE+2+2) */ |
#define | HASH_BUF_SIZE 28 |
#define | NB_MAX_DEVICES 256 |
#define | NB_MAX_HASH_ENTRIES 8192 |
#define | WORD_TEXT_OG 0x474f |
#define | WORD_TEXT_PR 0x5250 |
#define | wpAllowUnregister() wpAllowUnregisterEx() |
#define | wpPreventUnregister() wpPreventUnregisterEx() |
#define | YBLKID_WPENTRY 0xf0 |
#define | YBLKID_YPARRAY 0xf2 |
#define | YBLKID_YPCATEG 0xf1 |
#define | YBLKID_YPENTRY 0xf3 |
#define | YBLKID_YPENTRYEND (YBLKID_YPENTRY+YOCTO_N_BASECLASSES-1) |
#define | YMAX_HUB_URL_DEEP 8 |
#define | YOCTO_HOSTNAME_NAME (HASH_BUF_SIZE*2+2) |
#define | YSTRREF_EMPTY_STRING 0x00ff /* yStrRef value for the empty string */ |
#define | YSTRREF_HUBPORT_STRING 0x00d6 /* yStrRef value for the string 'HubPort' */ |
#define | YSTRREF_MODULE_STRING 0x0020 /* yStrRef value for the string 'Module' */ |
#define | YSTRREF_mODULE_STRING 0x00a3 /* yStrRef value for the string 'module' */ |
#define | YSTRREF_SENSOR_STRING 0x0001 /* yStrRef value for the string 'Sensor' */ |
#define | YWP_BEACON_ON 0x01 |
#define | YWP_MARK_FOR_UNREGISTER 0x02 |
Enumerations | |
enum | yAsbUrlProto { PROTO_AUTO = 0, PROTO_HTTP, PROTO_WEBSOCKET } |
enum | yAsbUrlType { USB_URL, IP_URL, NAME_URL } |
enum | yWPAttribute { Y_WP_SERIALNUMBER, Y_WP_LOGICALNAME, Y_WP_PRODUCTNAME, Y_WP_PRODUCTID, Y_WP_NETWORKURL, Y_WP_BEACON, Y_WP_INDEX } |
Functions | |
int | decodeNetFuncValV2 (const u8 *p, Notification_funydx *funInfo, char *funcVal) |
void | wpAllowUnregisterEx (void) |
u16 | wpEntryCount (void) |
int | wpGetAllDevUsingHubUrl (yUrlRef hubUrl, yStrRef *buffer, int sizeInStrRef) |
yStrRef | wpGetAttribute (yBlkHdl hdl, yWPAttribute attridx) |
int | wpGetDeviceInfo (YAPI_DEVICE devdesc, u16 *deviceid, char *productname, char *serial, char *logicalname, u8 *beacon) |
int | wpGetDeviceUrl (YAPI_DEVICE devdesc, char *roothubserial, char *request, int requestsize, int *neededsize) |
yUrlRef | wpGetDeviceUrlRef (YAPI_DEVICE devdesc) |
int | wpGetDevYdx (yStrRef serial) |
void | wpGetLogicalName (yBlkHdl hdl, char *logicalName) |
void | wpGetSerial (yBlkHdl hdl, char *serial) |
int | wpMarkForUnregister (yStrRef serial) |
void | wpPreventUnregisterEx (void) |
int | wpRegister (int devYdx, yStrRef serial, yStrRef logicalName, yStrRef productName, u16 productId, yUrlRef devUrl, s8 beacon) |
YAPI_DEVICE | wpSearch (const char *device_str) |
YAPI_DEVICE | wpSearchByNameHash (yStrRef strref) |
YAPI_DEVICE | wpSearchByUrl (const char *host, const char *rootUrl) |
YAPI_DEVICE | wpSearchEx (yStrRef strref) |
u16 | yBlkListLength (yBlkHdl hdl) |
yBlkHdl | yBlkListSeek (yBlkHdl hdl, u16 pos) |
void | yHashFree (void) |
void | yHashGetBuf (yHash yhash, u8 *destbuf, u16 bufsize) |
void | yHashGetStr (yHash yhash, char *destbuf, u16 bufsize) |
u16 | yHashGetStrLen (yHash yhash) |
char * | yHashGetStrPtr (yHash yhash) |
yAsbUrlType | yHashGetUrlPort (yUrlRef urlref, char *url, u16 *port, yAsbUrlProto *proto, yStrRef *user, yStrRef *password) |
void | yHashInit (void) |
yHash | yHashPutBuf (const u8 *buf, u16 len) |
yHash | yHashPutStr (const char *str) |
int | yHashSameHub (yUrlRef url_a, yUrlRef url_b) |
yHash | yHashTestBuf (const u8 *buf, u16 len) |
yHash | yHashTestStr (const char *str) |
yUrlRef | yHashUrl (const char *host, const char *rootUrl, u8 testonly, char *errmsg) |
yUrlRef | yHashUrlAPI (void) |
yUrlRef | yHashUrlFromRef (yUrlRef urlref, const char *rootUrl) |
yUrlRef | yHashUrlUSB (yHash serial) |
s16 | ypFindBootloaders (yStrRef *serials, u16 maxSerials) |
int | ypGetAttributes (yBlkHdl hdl, yStrRef *serial, yStrRef *funcId, yStrRef *funcName, Notification_funydx *funcInfo, char *funcVal) |
int | ypGetAttributesByYdx (u8 devYdx, u8 funYdx, yStrRef *serial, yStrRef *logicalName, yStrRef *funcId, yStrRef *funcName, Notification_funydx *funcInfo, char *funcVal) |
int | ypGetBootDevHdl (const char *serial) |
void | ypGetCategory (yBlkHdl hdl, char *name, yBlkHdl *entries) |
int | ypGetFunctionInfo (YAPI_FUNCTION fundesc, char *serial, char *funcId, char *baseType, char *funcName, char *funcVal) |
int | ypGetFunctions (const char *class_str, YAPI_DEVICE devdesc, YAPI_FUNCTION prevfundesc, YAPI_FUNCTION *buffer, int maxsize, int *neededsize) |
int | ypGetFunctionsEx (yStrRef categref, YAPI_DEVICE devdesc, YAPI_FUNCTION prevfundesc, YAPI_FUNCTION *buffer, int maxsize, int *neededsize) |
int | ypGetType (yBlkHdl hdl) |
int | ypRegister (yStrRef categ, yStrRef serial, yStrRef funcId, yStrRef funcName, int funClass, int funYdx, const char *funcVal) |
int | ypRegisterByYdx (u8 devYdx, Notification_funydx funInfo, const char *funcVal, YAPI_FUNCTION *fundesc) |
YAPI_FUNCTION | ypSearch (const char *class_str, const char *func_str) |
Variables | |
char | SerialNumberStr [YOCTO_SERIAL_LEN] |
yStrRef | SerialRef |
yBlkHdl | yWpListHead |
yBlkHdl | yYpListHead |
#define HASH_BUF_POW 5 /* HASH_BUF_POW = log_2(HASH_BUF_SIZE+2+2) */ |
#define wpAllowUnregister | ( | ) | wpAllowUnregisterEx() |
#define wpPreventUnregister | ( | ) | wpPreventUnregisterEx() |
#define YBLKID_YPENTRYEND (YBLKID_YPENTRY+YOCTO_N_BASECLASSES-1) |
#define YOCTO_HOSTNAME_NAME (HASH_BUF_SIZE*2+2) |
#define YSTRREF_EMPTY_STRING 0x00ff /* yStrRef value for the empty string */ |
#define YSTRREF_HUBPORT_STRING 0x00d6 /* yStrRef value for the string 'HubPort' */ |
#define YSTRREF_MODULE_STRING 0x0020 /* yStrRef value for the string 'Module' */ |
#define YSTRREF_mODULE_STRING 0x00a3 /* yStrRef value for the string 'module' */ |
#define YSTRREF_SENSOR_STRING 0x0001 /* yStrRef value for the string 'Sensor' */ |
enum yAsbUrlProto |
enum yAsbUrlType |
enum yWPAttribute |
int decodeNetFuncValV2 | ( | const u8 * | p, |
Notification_funydx * | funInfo, | ||
char * | funcVal | ||
) |
yStrRef wpGetAttribute | ( | yBlkHdl | hdl, |
yWPAttribute | attridx | ||
) |
int wpGetDeviceInfo | ( | YAPI_DEVICE | devdesc, |
u16 * | deviceid, | ||
char * | productname, | ||
char * | serial, | ||
char * | logicalname, | ||
u8 * | beacon | ||
) |
int wpGetDeviceUrl | ( | YAPI_DEVICE | devdesc, |
char * | roothubserial, | ||
char * | request, | ||
int | requestsize, | ||
int * | neededsize | ||
) |
yUrlRef wpGetDeviceUrlRef | ( | YAPI_DEVICE | devdesc | ) |
YAPI_DEVICE wpSearch | ( | const char * | device_str | ) |
YAPI_DEVICE wpSearchByNameHash | ( | yStrRef | strref | ) |
YAPI_DEVICE wpSearchByUrl | ( | const char * | host, |
const char * | rootUrl | ||
) |
YAPI_DEVICE wpSearchEx | ( | yStrRef | strref | ) |
void yHashGetStr | ( | yHash | yhash, |
char * | destbuf, | ||
u16 | bufsize | ||
) |
yAsbUrlType yHashGetUrlPort | ( | yUrlRef | urlref, |
char * | url, | ||
u16 * | port, | ||
yAsbUrlProto * | proto, | ||
yStrRef * | user, | ||
yStrRef * | password | ||
) |
yUrlRef yHashUrl | ( | const char * | url, |
const char * | rootUrl, | ||
u8 | testonly, | ||
char * | errmsg | ||
) |
s16 ypFindBootloaders | ( | yStrRef * | serials, |
u16 | maxSerials | ||
) |
int ypGetAttributes | ( | yBlkHdl | hdl, |
yStrRef * | serial, | ||
yStrRef * | funcId, | ||
yStrRef * | funcName, | ||
Notification_funydx * | funcInfo, | ||
char * | funcVal | ||
) |
int ypGetAttributesByYdx | ( | u8 | devYdx, |
u8 | funYdx, | ||
yStrRef * | serial, | ||
yStrRef * | logicalName, | ||
yStrRef * | funcId, | ||
yStrRef * | funcName, | ||
Notification_funydx * | funcInfo, | ||
char * | funcVal | ||
) |
int ypGetBootDevHdl | ( | const char * | serial | ) |
int ypGetFunctionInfo | ( | YAPI_FUNCTION | fundesc, |
char * | serial, | ||
char * | funcId, | ||
char * | baseType, | ||
char * | funcName, | ||
char * | funcVal | ||
) |
int ypGetFunctions | ( | const char * | class_str, |
YAPI_DEVICE | devdesc, | ||
YAPI_FUNCTION | prevfundesc, | ||
YAPI_FUNCTION * | buffer, | ||
int | maxsize, | ||
int * | neededsize | ||
) |
int ypGetFunctionsEx | ( | yStrRef | categref, |
YAPI_DEVICE | devdesc, | ||
YAPI_FUNCTION | prevfundesc, | ||
YAPI_FUNCTION * | buffer, | ||
int | maxsize, | ||
int * | neededsize | ||
) |
int ypRegisterByYdx | ( | u8 | devYdx, |
Notification_funydx | funInfo, | ||
const char * | funcVal, | ||
YAPI_FUNCTION * | fundesc | ||
) |
YAPI_FUNCTION ypSearch | ( | const char * | class_str, |
const char * | func_str | ||
) |
char SerialNumberStr[YOCTO_SERIAL_LEN] |