Sentinel
Loading...
Searching...
No Matches
Network Class Reference

Network class for managing WiFi and LTE connections. More...

#include <network.h>

Public Member Functions

void begin ()
 Initializes the network hardware.
 
bool enableModem () const
 Enables the LTE modem.
 
bool disableModem () const
 
bool connectWiFi (const char *ssid, const char *password)
 Connects to WiFi network.
 
bool connectLTE (const char *apn)
 Connects to LTE network using the specified APN.
 
bool isWiFiConnected () const
 Checks if the device is connected to WiFi.
 
bool isLTEConnected ()
 Checks if the device is connected to LTE network.
 
bool isConnected ()
 Checks if the device is connected to either WiFi or LTE network.
 
void disconnectWiFi ()
 Disconnects from the WiFi network.
 
void disconnectLTE ()
 Disconnects from the LTE network.
 
void maintainConnection (const char *ssid, const char *password, const char *apn)
 Maintains the network connection by checking WiFi and LTE status.
 

Detailed Description

Network class for managing WiFi and LTE connections.

This class provides methods to manage network connections, including enabling/disabling the modem, connecting to WiFi and LTE, checking connection status, and maintaining connections.

Member Function Documentation

◆ connectLTE()

bool Network::connectLTE ( const char * apn)

Connects to LTE network using the specified APN.

Parameters
apn
Returns
true
false

◆ connectWiFi()

bool Network::connectWiFi ( const char * ssid,
const char * password )

Connects to WiFi network.

Parameters
ssid
password
Returns
true
false

◆ enableModem()

bool Network::enableModem ( ) const

Enables the LTE modem.

Returns
true
false

◆ isConnected()

bool Network::isConnected ( )

Checks if the device is connected to either WiFi or LTE network.

Returns
true
false

◆ isLTEConnected()

bool Network::isLTEConnected ( )

Checks if the device is connected to LTE network.

Returns
true
false

◆ maintainConnection()

void Network::maintainConnection ( const char * ssid,
const char * password,
const char * apn )

Maintains the network connection by checking WiFi and LTE status.

Parameters
ssid
password
apn

The documentation for this class was generated from the following files: