This was left accidentally after refactoring.
It wasn't giving correct states after refactoring.
CellularContext::get_connection_status should be used instead.
Fix syncing back to at mode after ppp disconnect.
Fix AT_CellularContext flags and states to allow new connect after disconnect.
Fix that state machine is not reseted in disconnect is it's running (might be
running because of another context or new connect already started).
There are two EventQueue.h in mbed-os codebase:
events/EventQueue.h
features/FEATURE_BLE/ble/pal/EventQueue.h
By accident, `mbed compile` generates includes.txt with the correct
order of include search paths. This is not the case for the CMake
exporter: targets with FEATURE_BLE enables fail to compile with errors:
mbed-os/features/cellular/framework/AT/ATHandler.h:99:60: error:
'events' has not been declared
Update all places to always include either "events/EventQueue.h"
or "ble/pal/EventQueue.h": to always find the correct header.
Added Multihoming feature to LWIP (ability to use more than one network interfaces) for increasing networking reliability.
This involves:
LWIP interface
LWIP IP routing
DNS storage
Sockets (bind to interface name possibility)
possibility to add non default network interface
cellular middleware modifications if cellular connection is used
Information removed from the cellular subsystem trace log:
* SIM pin
* APN username and password
Added get_debug() to ATHandler.h to get the current trace state in order
to support suspend/resume of trace output.
Allow more than one callback to be register to NetworkInterfaces.
This introduces new APIs:
void NetworkInterface::add_event_listener(...);
void NetworkInterface::remove_event_listener(...);
Which internally calls interfaces attach() functions.
Change usage of AT_CellularContext::stack_type_supported to
AT_CellularBase::get_property. This way we can rid of
targets overriding stack_type_supported and delete
unnecessary classes and simplify new targets.
-added an API for checking network eps ciot optimization support
-renamed the API for getting the UE parameters
-the API for setting the UE parameters includes now a callback, which
will be called once network support for eps ciot optimization is known
Moved methods to classes CellularDevice and CellularInformation.
SIM interface was removed to simplify cellular usage and
methods better suite new classes.
Updated greentea and unit tests.
Add atomic load and store functions, and add barriers to the existing atomic
functions.
File currently has no explicit barriers - we don't support SMP, so don't
need CPU barriers.
But we do need to worry about compiler barriers - particularly if link time
optimisation is activated so that the compiler can see inside these
functions. The assembler or intrinsics that access PRIMASK for
enter/exit critical act as barriers, but LDREX, STREX and simple
volatile pointer loads and stores do not.
Unittest stubs needed to be updated for the API change.
Although this API is private and internal to LoRaPHY, somehow it
appeared in the LoRaPHYStub. Updating it for consistency.
This also includes their Datagram counterparts: DTLSSocket and DTLSSocketWrapper.
Coverage missing for timer-related functionality, but this would require more advanced stub development.
The extra (d)tls_test_config.h is necessary for successful compilation without HW support for the mbedtls features in unittests.
I reused the mbedtls stub found in features/nanostack/coap-service/test/coap-service/unittest/stub/mbedtls_stub.c and amended it slightly with a few missing functions.
This is equivalent of POSIX getpeername() function. It allows to
get remote address associated with the socket.
For example:
socket *s = server.accept();
SocketAddress remote;
s->getpeername(&remote);
Static Thread methods and signal methods have been deprecated. Remove
all references in the main code, and most of the tests. Some tests of
the deprecated APIs themselves remain.
Improved the stubs for event queue and nsapi_dns, to allow checking if callback are handled correctly. This involves some memory allocation and deallocation.
The NetworkStackWrapper is not covered as it seems to be deprecated code.
Add functional and line coverage for UDPSocket and TCPSocket. The EventFlagsstub and NetworkStackstub classes are allowed to store multiple return values to allow running internal loops multiple times.