2023-12-25 22:20:15 -04:00
|
|
|
/*
|
|
|
|
variant of SocketAPM using native sockets (not via lwip)
|
|
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <AP_HAL/AP_HAL.h>
|
|
|
|
|
|
|
|
#if CONFIG_HAL_BOARD == HAL_BOARD_SITL || CONFIG_HAL_BOARD == HAL_BOARD_LINUX
|
|
|
|
#define AP_SOCKET_NATIVE_ENABLED 1
|
|
|
|
#define SOCKET_CLASS_NAME SocketAPM_native
|
|
|
|
#ifndef AP_NETWORKING_SOCKETS_ENABLED
|
|
|
|
#define AP_NETWORKING_SOCKETS_ENABLED 1
|
|
|
|
#endif
|
|
|
|
#include "Socket.hpp"
|
2024-01-06 22:00:37 -04:00
|
|
|
#elif !AP_SIM_ENABLED
|
2023-12-25 22:20:15 -04:00
|
|
|
#error "attempt to use Socket_native.h without native sockets"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#undef SOCKET_CLASS_NAME
|
|
|
|
|
|
|
|
|
|
|
|
|