18#ifndef TELIT_ME310_CELLULARSTACK_H_
19#define TELIT_ME310_CELLULARSTACK_H_
21#include "AT_CellularStack.h"
22#include "mbed_trace.h"
23#include "drivers/Timer.h"
28#define ME310_SOCKET_MAX 6
29#define ME310_CONTEXT_MAX 6
30#define ME310_CREATE_SOCKET_TIMEOUT 150000
31#define ME310_CLOSE_SOCKET_TIMEOUT 20000
32#define ME310_MAX_RECV_SIZE 1000
33#define ME310_MAX_SEND_SIZE 1023
34#define ME310_SOCKET_BIND_FAIL 556
35#define ME310_IPEASY_ACTIVATED_CONTEXT 1
36#define ME310_IPEASY_DEACTIVATED_CONTEXT 0
54#if defined(MBED_CONF_NSAPI_OFFLOAD_TLSSOCKET) && (MBED_CONF_NSAPI_OFFLOAD_TLSSOCKET)
56 int optname,
const void *optval,
unsigned optlen);
61 virtual int get_max_socket_count();
63 virtual bool is_protocol_supported(nsapi_protocol_t protocol);
79 bool is_ipeasy_context_activated(
int context_id);
83 uint8_t _tls_sec_level;
virtual nsapi_error_t setsockopt(nsapi_socket_t handle, int level, int optname, const void *optval, unsigned optlen)
Set stack-specific socket options.
Class for sending AT commands and parsing AT responses.
virtual nsapi_error_t create_socket_impl(CellularSocket *socket)
Implements modem specific AT command set for creating socket.
virtual nsapi_error_t socket_connect(nsapi_socket_t handle, const SocketAddress &address)
Connects TCP socket to a remote host.
virtual nsapi_error_t socket_listen(nsapi_socket_t handle, int backlog)
Listen for connections on a TCP socket.
virtual nsapi_error_t socket_accept(nsapi_socket_t server, nsapi_socket_t *handle, SocketAddress *address=0)
Accepts a connection on a TCP socket.
virtual nsapi_size_or_error_t socket_recvfrom_impl(CellularSocket *socket, SocketAddress *address, void *buffer, nsapi_size_t size)
Implements modem specific AT command set for receiving data.
virtual nsapi_error_t socket_close_impl(int sock_id)
Implements modem specific AT command set for socket closing.
virtual nsapi_size_or_error_t socket_sendto_impl(CellularSocket *socket, const SocketAddress &address, const void *data, nsapi_size_t size)
Implements modem specific AT command set for sending data.
signed int nsapi_size_or_error_t
Type used to represent either a size or error passed through sockets.
signed int nsapi_error_t
Type used to represent error codes.
void * nsapi_socket_t
Opaque handle for network sockets.
unsigned int nsapi_size_t
Type used to represent the size of data passed through sockets.