Allow operations using only TCP

This commit is contained in:
Patrick Nicolas
2024-05-16 15:19:56 +02:00
parent f092a3fac0
commit 111afd4737
7 changed files with 114 additions and 51 deletions
+3
View File
@@ -111,6 +111,7 @@ struct headset_info_packet
struct handshake
{
// Sending this on TCP means connection will be TCP only
};
struct tracking
@@ -223,6 +224,8 @@ namespace to_headset
struct handshake
{
// -1 if stream socket should not be used
int stream_port;
};
struct audio_stream_description
+5
View File
@@ -68,6 +68,11 @@ xrt::drivers::wivrn::UDP::UDP()
throw std::system_error{errno, std::generic_category()};
}
xrt::drivers::wivrn::UDP::UDP(int fd)
{
this->fd = fd;
}
void xrt::drivers::wivrn::UDP::bind(int port)
{
sockaddr_in6 bind_addr{};
+1
View File
@@ -102,6 +102,7 @@ class UDP : public fd_base
{
public:
UDP();
explicit UDP(int fd);
deserialization_packet receive_raw();
std::pair<xrt::drivers::wivrn::deserialization_packet, sockaddr_in6> receive_from_raw();