16 #ifndef API_ROVER_HONO_CLOUD_HPP_ 17 #define API_ROVER_HONO_CLOUD_HPP_ 65 explicit RoverHonoCloud(
char * host_name,
const int port,
const int registration_port,
char * tenant_name);
91 void setHono (
char * host_name,
const int port,
char * tenant);
132 int sendTelemetry (
char * device_id,
char * user,
char * password,
char * field,
double value);
138 int sendEvent (
char * device_id,
char * user,
char * password,
char * field,
double value);
144 int getHonoStatus (
char * device_id,
char * user,
char * password);
int attributeErrorCheck(void) const
Checks private attributes and gives an error message and returns 0 if they're invalid.
Definition: rover_honocloud.cpp:45
int PORT
Port used for connecting to the Eclipse Hono using REST API.
Definition: rover_honocloud.hpp:37
int sendTelemetry(char *device_id, char *user, char *password, char *field, double value)
Constructs curl command to send telemetry data to Eclipse Hono using REST API.
Definition: rover_honocloud.cpp:76
int getHonoStatus(char *device_id, char *user, char *password)
Retrieves Hono cloud status by constructing a dummy REST API telemetry sending command to Eclipse Hon...
Definition: rover_honocloud.cpp:157
int registerDevice(char *device_id)
Constructs curl command to register a device to Hono instance given device ID using REST API...
Definition: rover_honocloud.cpp:58
void setHono(char *host_name, const int port, char *tenant)
Sets up a hono connection using host name, port, and tenant name.
Definition: rover_honocloud.cpp:110
RoverHonoCloud()
(default) Constructor for the RoverHonoCloud
Definition: rover_honocloud.cpp:24
rover Namespace contains classes to manage Rover sensors, gpio, buzzer, buttons, driving, utilities, and cloud.
Definition: rover_api.hpp:293
Contains the member functions to connect and send data to Eclipse Hono instance using several paramet...
Definition: rover_honocloud.hpp:27
int sendEvent(char *device_id, char *user, char *password, char *field, double value)
Constructs curl command to send event data to Eclipse Hono using REST API.
Definition: rover_honocloud.cpp:93
char * getTenantName(void) const
Retrieves private attribute TENANT_NAME.
Definition: rover_honocloud.cpp:152
char * HOST_NAME
Host name used for connecting to the Eclipse Hono using REST API.
Definition: rover_honocloud.hpp:33
int getPort(void) const
Retrieves private attribute PORT.
Definition: rover_honocloud.cpp:147
RoverCloud defines the interfaces that can be used for classes that connect to a remote cloud server...
Definition: rover_cloud.hpp:25
void setTenantName(char *tenant) const
Sets private attribute TENANT_NAME.
Definition: rover_honocloud.cpp:137
char * TENANT_NAME
Tenant name used for connecting to the Eclipse Hono using REST API.
Definition: rover_honocloud.hpp:45
int getRegistrationPort(void) const
Retrieves private attribute REGISTRATION_PORT.
Definition: rover_honocloud.cpp:132
void setPort(const int port)
Sets private attribute PORT.
Definition: rover_honocloud.cpp:122
void setRegistrationPort(const int port) const
Sets the default REGISTRATION_PORT variable.
Definition: rover_honocloud.cpp:127
char * getHostName(void) const
Retrieves private attribute HOST_NAME.
Definition: rover_honocloud.cpp:142
int REGISTRATION_PORT
Port used for registering a device to the Eclipse Hono using REST API.
Definition: rover_honocloud.hpp:41
void setHostName(char *host_name)
Sets private attribute HOST_NAME.
Definition: rover_honocloud.cpp:117