Class BaseSocket

Inheritance Relationships

Derived Types

Class Documentation

class BaseSocket

Abstract class inhereted by the other socket classes.

Subclassed by CommandSocket, StateSocket, VideoSocket

Public Functions

BaseSocket(asio::io_service &io_service, const std::string &drone_ip, const std::string &drone_port, const std::string &local_port)

Constructor of base socket.

Return
no return
Parameters
  • io_service: io_service object used to handle all socket communication
  • drone_ip: ip address of drone
  • drone_port: port number on the drone
  • local_port: port on the local machine used to communicate with the drone port mentioned above

virtual ~BaseSocket()

Protected Attributes

std::string local_port_
std::string drone_ip_
std::string drone_port_
asio::io_service &io_service_
asio::ip::udp::socket socket_
asio::ip::udp::endpoint endpoint_
std::thread io_thread