feat: vendor libltkc
This commit is contained in:
3
vendor/libltkc/examples/CMakeLists.txt
vendored
Normal file
3
vendor/libltkc/examples/CMakeLists.txt
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
cmake_minimum_required(VERSION 3.9)
|
||||
project(docsamples)
|
||||
add_subdirectory(docsample1)
|
||||
49
vendor/libltkc/examples/README.md
vendored
Normal file
49
vendor/libltkc/examples/README.md
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
# Impinj Example Application
|
||||
|
||||
## Overview
|
||||
|
||||
This example illustrates using CMake to build an Impinj Reader application for
|
||||
host (i.e. x86\_64) and Impinj Reader CPU architectures. The example
|
||||
application uses Impinj LTK libraries that are found inside the ETK. The
|
||||
'build.sh' script is intended to be run from within the Impinj ETK.
|
||||
|
||||
The ETK contains:
|
||||
* a cross compilation toolchain that targets an Impinj Reader architecture
|
||||
* libraries built for an Impinj Reader architecture
|
||||
* host architecture versions of libraries to allow host builds for faster
|
||||
development and debugging)
|
||||
|
||||
## Building
|
||||
|
||||
To build the project, call the build script from the command line:
|
||||
|
||||
```bash
|
||||
[user@machine]$ ./build.sh
|
||||
```
|
||||
|
||||
The script accepts overrides for certain variables. See 'build.sh' for more
|
||||
information.
|
||||
|
||||
## Running
|
||||
|
||||
To run on the host machine, simply run the exectuable:
|
||||
|
||||
```bash
|
||||
[user@machine]$ output/host/docsample1/docsample1 ${READER_HOSTNAME}
|
||||
```
|
||||
|
||||
To run on an Impinj Reader, e.g. an R700, copy the binary to the Reader and
|
||||
execute it:
|
||||
|
||||
```bash
|
||||
[user@machine]$ ssh root@r700
|
||||
Password: ********
|
||||
>
|
||||
|
||||
# drop in to osshell
|
||||
> osshell <code>
|
||||
|
||||
# copy the binary and execute it
|
||||
root@r700:~# scp user@machine:/path/to/output/target/docsample1/docsample1 /tmp
|
||||
root@r700:~# /tmp/docsample1 localhost
|
||||
```
|
||||
49
vendor/libltkc/examples/build.sh
vendored
Executable file
49
vendor/libltkc/examples/build.sh
vendored
Executable file
@@ -0,0 +1,49 @@
|
||||
#!/bin/bash -eu
|
||||
|
||||
#
|
||||
# Example build script for use with Impinj ETK
|
||||
#
|
||||
# The target libraries are contained inside the sysroot at
|
||||
# "$ETK_ROOT/arm-buildroot-linux-gnueabihf/sysroot/lib". The host libraries
|
||||
# are contained in "$ETK_ROOT/lib".
|
||||
#
|
||||
# For a host build, CMake must be configured to correctly search for host
|
||||
# headers and libraries in the correct location inside the ETK.
|
||||
#
|
||||
# For a target build, CMake must be configured to use the correct cross
|
||||
# compiler and informed about the sysroot location in the ETK.
|
||||
#
|
||||
# The script allows overriding some variables when building, e.g.:
|
||||
#
|
||||
# [user@machine]$ BUILD_TYPE=Release VERBOSE=ON ./build.sh
|
||||
#
|
||||
|
||||
SCRIPT_PATH=$(dirname $(realpath $0))
|
||||
OUTPUT_PATH=${SCRIPT_PATH}/output
|
||||
|
||||
# defaults when building with ETK; override on command line for custom setup
|
||||
ETK_PATH=${ETK_PATH:-$(realpath ${SCRIPT_PATH}/../../arm-toolchain)}
|
||||
BUILD_TYPE=${BUILD_TYPE:-Debug}
|
||||
VERBOSE=${VERBOSE:-OFF}
|
||||
|
||||
# host build; override on command line for custom setup
|
||||
INC=${INC:-${ETK_PATH}/include}
|
||||
LIB=${LIB:-${ETK_PATH}/lib}
|
||||
cmake ${SCRIPT_PATH} -B"${OUTPUT_PATH}/host" \
|
||||
-DCMAKE_VERBOSE_MAKEFILE:BOOL=${VERBOSE} \
|
||||
-DCMAKE_BUILD_TYPE=${BUILD_TYPE} \
|
||||
-DCMAKE_C_FLAGS="-isystem ${INC}" \
|
||||
-DCMAKE_LIBRARY_PATH=${LIB}
|
||||
cmake --build "${OUTPUT_PATH}/host"
|
||||
|
||||
# target build
|
||||
CC=$(find ${ETK_PATH}/bin -name arm-*-linux-*-gcc)
|
||||
CC=${CC%gcc}
|
||||
SYSROOT_PATH="$(${CC}gcc -print-sysroot)"
|
||||
cmake ${SCRIPT_PATH} -B"${OUTPUT_PATH}/target" \
|
||||
-DCMAKE_VERBOSE_MAKEFILE:BOOL=${VERBOSE} \
|
||||
-DCMAKE_BUILD_TYPE=${BUILD_TYPE} \
|
||||
-DCMAKE_C_COMPILER=${CC}gcc \
|
||||
-DCMAKE_CXX_COMPILER=${CC}g++ \
|
||||
-DCMAKE_FIND_ROOT_PATH=${SYSROOT_PATH}
|
||||
cmake --build "${OUTPUT_PATH}/target"
|
||||
28
vendor/libltkc/examples/docsample1/CMakeLists.txt
vendored
Normal file
28
vendor/libltkc/examples/docsample1/CMakeLists.txt
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
#
|
||||
# This example statically links when possible. While not required, it is meant
|
||||
# to illustrate how to handle both static and dynamic linking. Note that
|
||||
# producing a fully statically linked application (i.e. linking with '-static')
|
||||
# will raise a _lot_ of issues, if it works at all, and is not recommended.
|
||||
#
|
||||
|
||||
cmake_minimum_required(VERSION 3.9)
|
||||
project(docsample1)
|
||||
|
||||
find_library(LIBLTKC libltkc.a REQUIRED)
|
||||
find_library(LIBLTKC_IMPINJ libltkcimpinj.a REQUIRED)
|
||||
# it is not recommended to statically link for ssl and crypto libraries
|
||||
find_library(LIBSSL ssl REQUIRED)
|
||||
find_library(LIBCRYPTO crypto REQUIRED)
|
||||
# The ETK does not contain a host static library for xml2. Add the generic
|
||||
# name 'xml2' to link against the dynmaic library when compiling for host.
|
||||
find_library(LIBXML2 NAMES libxml2.a xml2 REQUIRED)
|
||||
set(LIBS
|
||||
${LIBLTKC}
|
||||
${LIBLTKC_IMPINJ}
|
||||
${LIBXML2}
|
||||
${LIBCRYPTO}
|
||||
${LIBSSL}
|
||||
)
|
||||
|
||||
add_executable(${PROJECT_NAME} ${PROJECT_NAME}.c)
|
||||
target_link_libraries(${PROJECT_NAME} PRIVATE ${LIBS})
|
||||
1921
vendor/libltkc/examples/docsample1/docsample1.c
vendored
Executable file
1921
vendor/libltkc/examples/docsample1/docsample1.c
vendored
Executable file
File diff suppressed because it is too large
Load Diff
23
vendor/libltkc/impinj_ltkc.h
vendored
Normal file
23
vendor/libltkc/impinj_ltkc.h
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
|
||||
/*
|
||||
*****************************************************************************
|
||||
* *
|
||||
* IMPINJ CONFIDENTIAL AND PROPRIETARY *
|
||||
* *
|
||||
* This source code is the sole property of Impinj, Inc. Reproduction or *
|
||||
* utilization of this source code in whole or in part is forbidden without *
|
||||
* the prior written consent of Impinj, Inc. *
|
||||
* *
|
||||
* (c) Copyright Impinj, Inc. 2007,2008. All rights reserved. *
|
||||
* *
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef _IMPINJ_LTKC_H
|
||||
#define _IMPINJ_LTKC_H
|
||||
|
||||
#include "ltkc.h"
|
||||
|
||||
#include "out_impinj_ltkc.h"
|
||||
|
||||
#endif /* !_IMPINJ_LTKC_H */
|
||||
|
||||
BIN
vendor/libltkc/libcrypto_armv7l.a
vendored
Normal file
BIN
vendor/libltkc/libcrypto_armv7l.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libcrypto_atmel.a
vendored
Normal file
BIN
vendor/libltkc/libcrypto_atmel.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libdl_armv7l.a
vendored
Normal file
BIN
vendor/libltkc/libdl_armv7l.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libdl_atmel.a
vendored
Normal file
BIN
vendor/libltkc/libdl_atmel.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkc_armv7l.a
vendored
Normal file
BIN
vendor/libltkc/libltkc_armv7l.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkc_armv7l.so
vendored
Executable file
BIN
vendor/libltkc/libltkc_armv7l.so
vendored
Executable file
Binary file not shown.
BIN
vendor/libltkc/libltkc_atmel.a
vendored
Normal file
BIN
vendor/libltkc/libltkc_atmel.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkc_atmel.so
vendored
Executable file
BIN
vendor/libltkc/libltkc_atmel.so
vendored
Executable file
Binary file not shown.
BIN
vendor/libltkc/libltkc_x86.a
vendored
Normal file
BIN
vendor/libltkc/libltkc_x86.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkc_x86.so
vendored
Executable file
BIN
vendor/libltkc/libltkc_x86.so
vendored
Executable file
Binary file not shown.
BIN
vendor/libltkc/libltkc_x86_64.a
vendored
Normal file
BIN
vendor/libltkc/libltkc_x86_64.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkc_x86_64.so
vendored
Executable file
BIN
vendor/libltkc/libltkc_x86_64.so
vendored
Executable file
Binary file not shown.
BIN
vendor/libltkc/libltkcimpinj_armv7l.a
vendored
Normal file
BIN
vendor/libltkc/libltkcimpinj_armv7l.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkcimpinj_armv7l.so
vendored
Executable file
BIN
vendor/libltkc/libltkcimpinj_armv7l.so
vendored
Executable file
Binary file not shown.
BIN
vendor/libltkc/libltkcimpinj_atmel.a
vendored
Normal file
BIN
vendor/libltkc/libltkcimpinj_atmel.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkcimpinj_atmel.so
vendored
Executable file
BIN
vendor/libltkc/libltkcimpinj_atmel.so
vendored
Executable file
Binary file not shown.
BIN
vendor/libltkc/libltkcimpinj_x86.a
vendored
Normal file
BIN
vendor/libltkc/libltkcimpinj_x86.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkcimpinj_x86.so
vendored
Executable file
BIN
vendor/libltkc/libltkcimpinj_x86.so
vendored
Executable file
Binary file not shown.
BIN
vendor/libltkc/libltkcimpinj_x86_64.a
vendored
Normal file
BIN
vendor/libltkc/libltkcimpinj_x86_64.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libltkcimpinj_x86_64.so
vendored
Executable file
BIN
vendor/libltkc/libltkcimpinj_x86_64.so
vendored
Executable file
Binary file not shown.
BIN
vendor/libltkc/libssl_armv7l.a
vendored
Normal file
BIN
vendor/libltkc/libssl_armv7l.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libssl_atmel.a
vendored
Normal file
BIN
vendor/libltkc/libssl_atmel.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libxml2_armv7l.a
vendored
Normal file
BIN
vendor/libltkc/libxml2_armv7l.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libxml2_atmel.a
vendored
Normal file
BIN
vendor/libltkc/libxml2_atmel.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libxml2_x86.a
vendored
Normal file
BIN
vendor/libltkc/libxml2_x86.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/libxml2_x86_64.a
vendored
Normal file
BIN
vendor/libltkc/libxml2_x86_64.a
vendored
Normal file
Binary file not shown.
BIN
vendor/libltkc/llrp2xml
vendored
Executable file
BIN
vendor/libltkc/llrp2xml
vendored
Executable file
Binary file not shown.
39
vendor/libltkc/ltkc.h
vendored
Executable file
39
vendor/libltkc/ltkc.h
vendored
Executable file
@@ -0,0 +1,39 @@
|
||||
|
||||
/*
|
||||
*****************************************************************************
|
||||
* *
|
||||
* IMPINJ CONFIDENTIAL AND PROPRIETARY *
|
||||
* *
|
||||
* This source code is the sole property of Impinj, Inc. Reproduction or *
|
||||
* utilization of this source code in whole or in part is forbidden without *
|
||||
* the prior written consent of Impinj, Inc. *
|
||||
* *
|
||||
* (c) Copyright Impinj, Inc. 2007,2008. All rights reserved. *
|
||||
* *
|
||||
*****************************************************************************/
|
||||
|
||||
#ifndef _LTKC_H
|
||||
#define _LTKC_H
|
||||
|
||||
#include "ltkc_platform.h"
|
||||
#include "ltkc_base.h"
|
||||
|
||||
#include "ltkc_frame.h"
|
||||
#include "ltkc_xmltext.h"
|
||||
#include "ltkc_connection.h"
|
||||
|
||||
#include "out_ltkc.h"
|
||||
|
||||
/* for passing version information as a define */
|
||||
#define STRINGIFY(x) XSTRINGIFY(x)
|
||||
#define XSTRINGIFY(x) #x
|
||||
|
||||
#include "version.inc"
|
||||
|
||||
|
||||
extern LLRP_tSTypeRegistry *
|
||||
LLRP_getTheTypeRegistry (void);
|
||||
|
||||
|
||||
#endif /* !_LTKC_H */
|
||||
|
||||
1216
vendor/libltkc/ltkc_base.h
vendored
Executable file
1216
vendor/libltkc/ltkc_base.h
vendored
Executable file
File diff suppressed because it is too large
Load Diff
190
vendor/libltkc/ltkc_connection.h
vendored
Executable file
190
vendor/libltkc/ltkc_connection.h
vendored
Executable file
@@ -0,0 +1,190 @@
|
||||
|
||||
/*
|
||||
*****************************************************************************
|
||||
* *
|
||||
* IMPINJ CONFIDENTIAL AND PROPRIETARY *
|
||||
* *
|
||||
* This source code is the sole property of Impinj, Inc. Reproduction or *
|
||||
* utilization of this source code in whole or in part is forbidden without *
|
||||
* the prior written consent of Impinj, Inc. *
|
||||
* *
|
||||
* (c) Copyright Impinj, Inc. 2007,2008. All rights reserved. *
|
||||
* *
|
||||
*****************************************************************************/
|
||||
|
||||
/**
|
||||
*****************************************************************************
|
||||
**
|
||||
** @file ltkc_connection.h
|
||||
**
|
||||
** @brief Types and function prototypes for handling
|
||||
** two-way LLRP message traffic
|
||||
**
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
/* Forward type declarations */
|
||||
struct LLRP_SConnection;
|
||||
typedef struct LLRP_SConnection LLRP_tSConnection;
|
||||
struct bio_st;
|
||||
|
||||
/**
|
||||
*****************************************************************************
|
||||
**
|
||||
** @brief Structure of an LLRP connection instance
|
||||
**
|
||||
** An LLRP connection consists of:
|
||||
** - A file descriptor (fd) likely, but not necessarily, a socket
|
||||
** - An input queue of messages already received. Used to hold
|
||||
** asynchronous messages while awaiting a response.
|
||||
** - Receiver state.
|
||||
** - The receive buffer and count
|
||||
** - Whether a frame is valid. Valid means that the receive
|
||||
** buffer holds a frame and the MessageLength, MessageType,
|
||||
** ProtocolVersion, and MessageID are valid (usable).
|
||||
** Not valid with a nBuffer greater than 0 means that a frame
|
||||
** is being received. Sometimes we want to look at the frame
|
||||
** after it has been (or attempted to be) decoded.
|
||||
** - Top-level frame variables: tSFrameExtract
|
||||
** - Details of the last receiver error, including I/O errors,
|
||||
** end-of-file (EOF), timeout, or decode errors.
|
||||
** - Send state
|
||||
** - The send buffer and count
|
||||
** - Details of the last send error, including I/O errors,
|
||||
** or encode errors.
|
||||
**
|
||||
*****************************************************************************/
|
||||
|
||||
struct LLRP_SConnection
|
||||
{
|
||||
/** The OpenSSL provided socket abstraction */
|
||||
struct bio_st * pBio;
|
||||
|
||||
/** Error message if openConnectionToReader() or close...() fail */
|
||||
const char * pConnectErrorStr;
|
||||
|
||||
/** The registry to consult for message/parameter types during decode. */
|
||||
const LLRP_tSTypeRegistry * pTypeRegistry;
|
||||
|
||||
/** Head of queue of messages already received. Probably events.
|
||||
** the queue is a one-way, NULL terminated linked list. */
|
||||
LLRP_tSMessage * pInputQueue;
|
||||
|
||||
/** Size of the send/recv buffers, below, specified at construct() time */
|
||||
unsigned int nBufferSize;
|
||||
|
||||
/** Receive state */
|
||||
struct
|
||||
{
|
||||
/** The buffer. Contains incomming frame. */
|
||||
unsigned char * pBuffer;
|
||||
|
||||
/** Count of bytes currently in buffer */
|
||||
unsigned int nBuffer;
|
||||
|
||||
/** Valid boolean. TRUE means the buffer and frame summary
|
||||
** variables are valid (usable). This is always
|
||||
** FALSE mid receive */
|
||||
int bFrameValid;
|
||||
|
||||
/** Frame summary variables. Derived by LLRP_FrameExtract() */
|
||||
LLRP_tSFrameExtract FrameExtract;
|
||||
|
||||
/** Details of last I/O or decoder error. */
|
||||
LLRP_tSErrorDetails ErrorDetails;
|
||||
} Recv;
|
||||
|
||||
/** Send state */
|
||||
struct
|
||||
{
|
||||
/** The buffer. Contains outgoing frame. */
|
||||
unsigned char * pBuffer;
|
||||
|
||||
/** Count of bytes currently in buffer (from last send) */
|
||||
unsigned int nBuffer;
|
||||
|
||||
/** Details of last I/O or encoder error. */
|
||||
LLRP_tSErrorDetails ErrorDetails;
|
||||
} Send;
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* ltkc_connection.c
|
||||
*/
|
||||
extern LLRP_tSConnection *
|
||||
LLRP_Conn_construct (
|
||||
const LLRP_tSTypeRegistry * pTypeRegistry,
|
||||
unsigned int nBufferSize);
|
||||
|
||||
extern void
|
||||
LLRP_Conn_destruct (
|
||||
LLRP_tSConnection * pConn);
|
||||
|
||||
extern int
|
||||
LLRP_Conn_openConnectionToReader (
|
||||
LLRP_tSConnection * pConn,
|
||||
const char * pReaderHostName);
|
||||
|
||||
extern int
|
||||
LLRP_Conn_openSecureConnectionToReader (
|
||||
LLRP_tSConnection * pConn,
|
||||
const char * pReaderHostName);
|
||||
|
||||
extern int
|
||||
LLRP_Conn_openConnectionToReaderWithPort (
|
||||
LLRP_tSConnection * pConn,
|
||||
const char * pReaderHostName,
|
||||
const char * pPort);
|
||||
|
||||
extern int
|
||||
LLRP_Conn_openSecureConnectionToReaderWithPort (
|
||||
LLRP_tSConnection * pConn,
|
||||
const char * pReaderHostName,
|
||||
const char * pPort);
|
||||
|
||||
extern int
|
||||
LLRP_Conn_closeConnectionToReader (
|
||||
LLRP_tSConnection * pConn);
|
||||
|
||||
extern const char *
|
||||
LLRP_Conn_getConnectError (
|
||||
LLRP_tSConnection * pConn);
|
||||
|
||||
extern LLRP_tSMessage *
|
||||
LLRP_Conn_transact (
|
||||
LLRP_tSConnection * pConn,
|
||||
LLRP_tSMessage * pSendMessage,
|
||||
int nMaxMS);
|
||||
|
||||
extern const LLRP_tSErrorDetails *
|
||||
LLRP_Conn_getTransactError (
|
||||
LLRP_tSConnection * pConn);
|
||||
|
||||
extern LLRP_tResultCode
|
||||
LLRP_Conn_sendMessage (
|
||||
LLRP_tSConnection * pConn,
|
||||
LLRP_tSMessage * pMessage);
|
||||
|
||||
extern const LLRP_tSErrorDetails *
|
||||
LLRP_Conn_getSendError (
|
||||
LLRP_tSConnection * pConn);
|
||||
|
||||
extern LLRP_tSMessage *
|
||||
LLRP_Conn_recvMessage (
|
||||
LLRP_tSConnection * pConn,
|
||||
int nMaxMS);
|
||||
|
||||
extern LLRP_tSMessage *
|
||||
LLRP_Conn_recvResponse (
|
||||
LLRP_tSConnection * pConn,
|
||||
int nMaxMS,
|
||||
const LLRP_tSTypeDescriptor * pResponseType,
|
||||
llrp_u32_t ResponseMessageID);
|
||||
|
||||
extern const LLRP_tSErrorDetails *
|
||||
LLRP_Conn_getRecvError (
|
||||
LLRP_tSConnection * pConn);
|
||||
|
||||
108
vendor/libltkc/ltkc_frame.h
vendored
Executable file
108
vendor/libltkc/ltkc_frame.h
vendored
Executable file
@@ -0,0 +1,108 @@
|
||||
|
||||
/*
|
||||
*****************************************************************************
|
||||
* *
|
||||
* IMPINJ CONFIDENTIAL AND PROPRIETARY *
|
||||
* *
|
||||
* This source code is the sole property of Impinj, Inc. Reproduction or *
|
||||
* utilization of this source code in whole or in part is forbidden without *
|
||||
* the prior written consent of Impinj, Inc. *
|
||||
* *
|
||||
* (c) Copyright Impinj, Inc. 2007,2008. All rights reserved. *
|
||||
* *
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
|
||||
|
||||
struct LLRP_SFrameExtract;
|
||||
struct LLRP_SFrameDecoder;
|
||||
struct LLRP_SFrameDecoderStream;
|
||||
struct LLRP_SFrameEncoder;
|
||||
struct LLRP_SFrameEncoderStream;
|
||||
|
||||
typedef struct LLRP_SFrameExtract LLRP_tSFrameExtract;
|
||||
typedef struct LLRP_SFrameDecoder LLRP_tSFrameDecoder;
|
||||
typedef struct LLRP_SFrameDecoderStream LLRP_tSFrameDecoderStream;
|
||||
typedef struct LLRP_SFrameEncoder LLRP_tSFrameEncoder;
|
||||
typedef struct LLRP_SFrameEncoderStream LLRP_tSFrameEncoderStream;
|
||||
|
||||
|
||||
struct LLRP_SFrameExtract
|
||||
{
|
||||
enum {
|
||||
LLRP_FRAME_UNKNOWN,
|
||||
LLRP_FRAME_READY,
|
||||
LLRP_FRAME_ERROR,
|
||||
LLRP_FRAME_NEED_MORE
|
||||
} eStatus;
|
||||
|
||||
llrp_u32_t MessageLength;
|
||||
llrp_u16_t MessageType;
|
||||
llrp_u8_t ProtocolVersion;
|
||||
llrp_u32_t MessageID;
|
||||
|
||||
unsigned int nBytesNeeded;
|
||||
};
|
||||
|
||||
struct LLRP_SFrameDecoder
|
||||
{
|
||||
LLRP_tSDecoder decoderHdr;
|
||||
|
||||
unsigned char * pBuffer;
|
||||
unsigned int nBuffer;
|
||||
|
||||
unsigned int iNext;
|
||||
unsigned int BitFieldBuffer;
|
||||
unsigned int nBitFieldResid;
|
||||
};
|
||||
|
||||
extern LLRP_tSFrameExtract
|
||||
LLRP_FrameExtract (
|
||||
const unsigned char * pBuffer,
|
||||
unsigned int nBuffer);
|
||||
|
||||
struct LLRP_SFrameDecoderStream
|
||||
{
|
||||
LLRP_tSDecoderStream decoderStreamHdr;
|
||||
|
||||
LLRP_tSFrameDecoder * pDecoder;
|
||||
LLRP_tSFrameDecoderStream * pEnclosingDecoderStream;
|
||||
const LLRP_tSTypeDescriptor *pRefType;
|
||||
unsigned int iBegin;
|
||||
unsigned int iLimit;
|
||||
};
|
||||
|
||||
extern LLRP_tSFrameDecoder *
|
||||
LLRP_FrameDecoder_construct (
|
||||
const LLRP_tSTypeRegistry * pTypeRegistry,
|
||||
unsigned char * pBuffer,
|
||||
unsigned int nBuffer);
|
||||
|
||||
|
||||
struct LLRP_SFrameEncoder
|
||||
{
|
||||
LLRP_tSEncoder encoderHdr;
|
||||
|
||||
unsigned char * pBuffer;
|
||||
unsigned int nBuffer;
|
||||
|
||||
unsigned int iNext;
|
||||
unsigned int BitFieldBuffer;
|
||||
unsigned int nBitFieldResid;
|
||||
};
|
||||
|
||||
struct LLRP_SFrameEncoderStream
|
||||
{
|
||||
LLRP_tSEncoderStream encoderStreamHdr;
|
||||
|
||||
LLRP_tSFrameEncoder * pEncoder;
|
||||
LLRP_tSFrameEncoderStream * pEnclosingEncoderStream;
|
||||
const LLRP_tSTypeDescriptor *pRefType;
|
||||
unsigned int iBegin;
|
||||
};
|
||||
|
||||
extern LLRP_tSFrameEncoder *
|
||||
LLRP_FrameEncoder_construct (
|
||||
unsigned char * pBuffer,
|
||||
unsigned int nBuffer);
|
||||
41
vendor/libltkc/ltkc_genoutmac.h
vendored
Normal file
41
vendor/libltkc/ltkc_genoutmac.h
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
|
||||
/*
|
||||
*****************************************************************************
|
||||
* *
|
||||
* IMPINJ CONFIDENTIAL AND PROPRIETARY *
|
||||
* *
|
||||
* This source code is the sole property of Impinj, Inc. Reproduction or *
|
||||
* utilization of this source code in whole or in part is forbidden without *
|
||||
* the prior written consent of Impinj, Inc. *
|
||||
* *
|
||||
* (c) Copyright Impinj, Inc. 2007,2008. All rights reserved. *
|
||||
* *
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
#define SUBPARAM_SET(MEMBER,VALUE) \
|
||||
LLRP_Element_setSubParameterPtr( \
|
||||
(LLRP_tSElement *)pThis, \
|
||||
(LLRP_tSParameter**)&pThis->MEMBER, \
|
||||
(LLRP_tSParameter*)(VALUE))
|
||||
|
||||
#define SUBPARAM_ADD(MEMBER,VALUE) \
|
||||
LLRP_Element_addToSubParameterList( \
|
||||
(LLRP_tSElement *)pThis, \
|
||||
(LLRP_tSParameter**)&pThis->MEMBER, \
|
||||
(LLRP_tSParameter*)(VALUE))
|
||||
|
||||
#define SUBPARAM_ATTACH(MEMBER,VALUE) \
|
||||
LLRP_Element_attachToSubParameterList( \
|
||||
(LLRP_tSParameter**)&pThis->MEMBER, \
|
||||
(LLRP_tSParameter*)(VALUE))
|
||||
|
||||
#define SUBPARAM_CLEAR(MEMBER) \
|
||||
LLRP_Element_clearSubParameterList( \
|
||||
(LLRP_tSElement *)pThis, \
|
||||
(LLRP_tSParameter**)&pThis->MEMBER)
|
||||
|
||||
#define SUBPARAM_COUNT(MEMBER) \
|
||||
LLRP_Element_countSubParameterList( \
|
||||
(LLRP_tSElement *)pThis, \
|
||||
(LLRP_tSParameter**)&pThis->MEMBER)
|
||||
52
vendor/libltkc/ltkc_platform.h
vendored
Executable file
52
vendor/libltkc/ltkc_platform.h
vendored
Executable file
@@ -0,0 +1,52 @@
|
||||
|
||||
/*
|
||||
*****************************************************************************
|
||||
* *
|
||||
* IMPINJ CONFIDENTIAL AND PROPRIETARY *
|
||||
* *
|
||||
* This source code is the sole property of Impinj, Inc. Reproduction or *
|
||||
* utilization of this source code in whole or in part is forbidden without *
|
||||
* the prior written consent of Impinj, Inc. *
|
||||
* *
|
||||
* (c) Copyright Impinj, Inc. 2007,2008. All rights reserved. *
|
||||
* *
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
/*
|
||||
* Include file to establish context
|
||||
* for the LLRP Tool Kit (LTK) C++ platform.
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdlib.h> /* malloc() */
|
||||
#include <string.h> /* memcpy() */
|
||||
|
||||
#define FALSE 0
|
||||
#define TRUE 1
|
||||
|
||||
/*
|
||||
* Typedefs of simple types.
|
||||
* The LTK/C++ uses these types extensively.
|
||||
* To retarget to another C++ platform change
|
||||
* these typedefs. Everything else should be
|
||||
* good to go.
|
||||
*/
|
||||
|
||||
#ifdef _STDINT_H
|
||||
|
||||
typedef uint8_t llrp_u8_t;
|
||||
typedef int8_t llrp_s8_t;
|
||||
typedef uint16_t llrp_u16_t;
|
||||
typedef int16_t llrp_s16_t;
|
||||
typedef uint32_t llrp_u32_t;
|
||||
typedef int32_t llrp_s32_t;
|
||||
typedef uint64_t llrp_u64_t;
|
||||
typedef int64_t llrp_s64_t;
|
||||
typedef uint8_t llrp_u1_t;
|
||||
typedef uint8_t llrp_u2_t;
|
||||
typedef uint8_t llrp_utf8_t;
|
||||
typedef int llrp_bool_t;
|
||||
typedef uint8_t llrp_byte_t;
|
||||
|
||||
#endif /* _STDINT_H */
|
||||
87
vendor/libltkc/ltkc_xmltext.h
vendored
Normal file
87
vendor/libltkc/ltkc_xmltext.h
vendored
Normal file
@@ -0,0 +1,87 @@
|
||||
|
||||
/*
|
||||
*****************************************************************************
|
||||
* *
|
||||
* IMPINJ CONFIDENTIAL AND PROPRIETARY *
|
||||
* *
|
||||
* This source code is the sole property of Impinj, Inc. Reproduction or *
|
||||
* utilization of this source code in whole or in part is forbidden without *
|
||||
* the prior written consent of Impinj, Inc. *
|
||||
* *
|
||||
* (c) Copyright Impinj, Inc. 2007,2010. All rights reserved. *
|
||||
* *
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
struct LLRP_SLibXMLTextDecoder;
|
||||
struct LLRP_SLibXMLTextDecoderStream;
|
||||
struct LLRP_SXMLTextEncoder;
|
||||
struct LLRP_SXMLTextEncoderStream;
|
||||
|
||||
typedef struct LLRP_SLibXMLTextDecoder LLRP_tSLibXMLTextDecoder;
|
||||
typedef struct LLRP_SLibXMLTextDecoderStream LLRP_tSLibXMLTextDecoderStream;
|
||||
typedef struct LLRP_SXMLTextEncoder LLRP_tSXMLTextEncoder;
|
||||
typedef struct LLRP_SXMLTextEncoderStream LLRP_tSXMLTextEncoderStream;
|
||||
|
||||
struct LLRP_SLibXMLTextDecoder
|
||||
{
|
||||
LLRP_tSDecoder decoderHdr;
|
||||
struct _xmlDoc * doc;
|
||||
struct _xmlNode * pxmlNodeTree;
|
||||
};
|
||||
|
||||
struct LLRP_SLibXMLTextDecoderStream
|
||||
{
|
||||
LLRP_tSDecoderStream decoderStreamHdr;
|
||||
|
||||
LLRP_tSLibXMLTextDecoder * pDecoder;
|
||||
LLRP_tSLibXMLTextDecoderStream * pEnclosingDecoderStream;
|
||||
struct _xmlNode * pTargetNode;
|
||||
struct _xmlNode * pCurrentChildNode;
|
||||
struct _xmlNode * pLastFieldNode;
|
||||
const LLRP_tSTypeDescriptor * pRefType;
|
||||
};
|
||||
|
||||
extern LLRP_tSLibXMLTextDecoder *
|
||||
LLRP_LibXMLTextDecoder_construct (
|
||||
const LLRP_tSTypeRegistry * pTypeRegistry,
|
||||
unsigned char * pBuffer,
|
||||
unsigned int nBuffer);
|
||||
|
||||
|
||||
struct LLRP_SXMLTextEncoder
|
||||
{
|
||||
LLRP_tSEncoder encoderHdr;
|
||||
|
||||
unsigned char * pBuffer;
|
||||
unsigned int nBuffer;
|
||||
|
||||
unsigned int iNext;
|
||||
|
||||
int bOverflow;
|
||||
};
|
||||
|
||||
struct LLRP_SXMLTextEncoderStream
|
||||
{
|
||||
LLRP_tSEncoderStream encoderStreamHdr;
|
||||
|
||||
LLRP_tSXMLTextEncoder * pEncoder;
|
||||
LLRP_tSXMLTextEncoderStream * pEnclosingEncoderStream;
|
||||
const LLRP_tSTypeDescriptor *pRefType;
|
||||
unsigned int nDepth;
|
||||
};
|
||||
|
||||
extern LLRP_tSXMLTextEncoder *
|
||||
LLRP_XMLTextEncoder_construct (
|
||||
unsigned char * pBuffer,
|
||||
unsigned int nBuffer);
|
||||
|
||||
LLRP_tSLibXMLTextDecoder *
|
||||
LLRP_LibXMLTextDecoder_construct_file (
|
||||
const LLRP_tSTypeRegistry * pTypeRegistry,
|
||||
char * fname);
|
||||
|
||||
LLRP_tSLibXMLTextDecoder *
|
||||
LLRP_LibXMLTextDecoder_construct_nodetree (
|
||||
const LLRP_tSTypeRegistry * pTypeRegistry,
|
||||
struct _xmlNode * pNodeTree);
|
||||
11415
vendor/libltkc/out_impinj_ltkc.h
vendored
Normal file
11415
vendor/libltkc/out_impinj_ltkc.h
vendored
Normal file
File diff suppressed because it is too large
Load Diff
13843
vendor/libltkc/out_ltkc.h
vendored
Normal file
13843
vendor/libltkc/out_ltkc.h
vendored
Normal file
File diff suppressed because it is too large
Load Diff
1
vendor/libltkc/version.inc
vendored
Normal file
1
vendor/libltkc/version.inc
vendored
Normal file
@@ -0,0 +1 @@
|
||||
#define VERSION_STR 12.2.0.0
|
||||
BIN
vendor/libltkc/xml2llrp
vendored
Executable file
BIN
vendor/libltkc/xml2llrp
vendored
Executable file
Binary file not shown.
Reference in New Issue
Block a user