C client for GEX. bare-bones, low level access
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gex-client-c/gex/gex_internal.h

29 lines
934 B

//
// Created by MightyPork on 2017/12/15.
//
#ifndef GEX_CLIENT_GEX_CLIENT_INTERNAL_H
#define GEX_CLIENT_GEX_CLIENT_INTERNAL_H
7 years ago
#include <stdint.h>
#include <stdbool.h>
#include "gex_client.h"
7 years ago
struct gex_client {
TinyFrame *tf; //!< TinyFrame instance
7 years ago
const char *acm_device; //!< Comport device name, might be used to reconnect (?)
int acm_fd; //!< Open comport file descriptor
bool connected; //!< Flag that we're currently connected to the comport
7 years ago
// synchronous query "hacks"
bool sync_query_ok; //!< flag that the query response was received
7 years ago
GexMsg sync_query_response; //!< response message, copied here
7 years ago
uint8_t sync_query_buffer[TF_MAX_PAYLOAD_RX]; //!< buffer for the rx payload to be copied here
7 years ago
GexEventListener fallback_report_handler;
7 years ago
struct gex_unit *ulu_head; //!< Units look-up linked list
};
#endif //GEX_CLIENT_GEX_CLIENT_INTERNAL_H