Commit Graph

295 Commits (5262cf1f87236920a7fc4fd795e740d843dbcba0)

Author SHA1 Message Date
Martin Kojtal 6add979210
Merge pull request #10750 from jarvte/eventqueue_cancel_return
Changed EventQueue::cancel to return boolean value
2019-08-27 20:50:03 +02:00
Martin Kojtal a1540c5f77
Merge pull request #11245 from dextero/8bit-sms
AT_CellularSMS: allow configuring SMS encoding (7-bit/8-bit) at initialization
2019-08-23 13:51:59 +02:00
Martin Kojtal 5c09ff12ac
Merge pull request #11220 from jarvte/fix_cellular_dns_test
Fix cellular dns test with IAR compiled binary
2019-08-22 10:57:22 +02:00
Teppo Järvelin 719117e12c Fix EventQueue::cancel to return value 2019-08-20 15:56:41 +03:00
Martin Kojtal 181f4f7e93
Merge pull request #11067 from Tharazi97/equeue_tests
Add Unittest equeue tests
2019-08-20 10:28:23 +02:00
Martin Kojtal 0b49952b9e
Merge pull request #11249 from dextero/get-sms-zero
Make AT_CellularSMS::list_messages support index 0 in SMS inbox
2019-08-20 10:27:57 +02:00
Martin Kojtal b849bc1e3d
Merge pull request #11201 from mirelachirica/bug_virtual_in_constructor
Cellular: Fixed improper AT handler setup through virtual calls in co…
2019-08-20 09:52:28 +02:00
Martin Kojtal 64fb49e4ec
Merge pull request #11169 from dmaziec1/TLSSocketWrapper_recvfrom_modified
TLSSocketWrapper::recvfrom sets SocketAddress output variable
2019-08-20 09:41:39 +02:00
Martin Kojtal a5a2036c65
Merge pull request #11224 from AnttiKauppila/Coverity_fixes
Coverity issues fixed
2019-08-20 09:40:20 +02:00
Marcin Radomski ce0bb7f568 Update test_AT_CellularSMS_get_sms
0 is now a valid value
2019-08-16 14:25:29 +02:00
Marcin Radomski cd7e6c9708 Adjust AT_CellularSMS_stub API 2019-08-16 12:33:48 +02:00
Mirela Chirica 75c823c1a3 Cellular: Fixed improper AT handler setup through virtual calls in constructor
Added AT handler setup method to be used for initialisation routines
that are virtual and therefore cannot be called from constructor.
2019-08-16 10:57:37 +03:00
Anna Bridge 2af2b1b18b
Merge pull request #11190 from jarvte/fix_wise1570_netsocket_tests
Cellular: failure when deleting created context is not considered error
2019-08-15 12:58:32 +01:00
Antti Kauppila 84063bf222 Coverity issues fixed 2019-08-14 16:22:05 +03:00
Teppo Järvelin 6a17d74b55 Cellular: notify global up after we have IP address
CellularContext now tries to get an IP address after connect and before
sending NSAPI_STATUS_GLOBAL_UP. Even if we don't the IP address from
the modem we will send NSAPI_STATUS_GLOBAL_UP and return success.
Modem has an ip address but for some reason some modems don't
give it to us.
2019-08-14 12:54:13 +03:00
Teppo Järvelin 3c1bf0a9e2 Cellular: moved string_to_pdp_type from AT_CellularContext to CellularUtil
string_to_pdp_type is a common method for AT and other layers.
Without moving there will be duplicate methods.
2019-08-12 10:27:57 +03:00
Szymon Kwiatkowski c06b11b386 Add Unittest equeue tests 2019-08-09 12:45:29 +02:00
Teppo Järvelin 10251ab3b2 Cellular: failure when deleting created context is not considered as an error
If delete fails there is nothing we or application can do. There is no point
returning an error for this. This affects to AT_CellularContext::disconnect
not returning an error if context delete fails.
2019-08-09 12:27:25 +03:00
Seppo Takalo 7d7416558a
Merge pull request #11073 from ARMmbed/feature-public-headers
Feature public headers
2019-08-07 16:04:45 +03:00
Dominika Maziec e9059c214c TLSSocketWrapper::recvfrom sets SocketAddress output variable
UNITTEST added. TLSSocketWrapper unittest does not use stoip4_stub anymore.
2019-08-06 15:07:39 +02:00
Ari Parkkila e1124668db Cellular: Add DNS servers from PDP contexts to nsapi_dns 2019-08-05 21:53:24 -07:00
George Psimenos 3b23edb78c Fix CI for branch feature-public-headers (#11093)
* Fix rtos include path in NRFCordioHCIDriver
* Flatten USB driver directory structure
* Add missing include for us_ticker
* Add more missing includes for us_ticker
* Fix mbed_hal_fpga_ci_test_shield/uart test
* Fix bare-metal build
* Fix Watchdog UNITTEST
* Fix Mbed OS 2 build for Public/Internal headers relocating
2019-08-02 12:32:40 +01:00
Hugues Kamba 20f81e19be Change Doxygen groups structure, splitting first by Public/Internal (#11105)
* Change Doxygen groups structure, splitting first by Public/Internal

This commit also does the following:
* groups the documentation of related API
* moves `events/internal/equeue.h` to `events/equeue.h`
* merges `events/source/README.md` to `events/README.md`
2019-08-02 12:23:47 +01:00
Hugues Kamba bfa1b4dd84 Drivers/Events/RTOS Public and internal APIs cleanup (#10955)
Separate drivers, events, and rtos internal APIs from public APIs.

* Move source files to source subdirs
* Move internal headers to internal subdirs
* Add Doxygen comments for documenting internal and public APIs
* Remove source code from header files in order to remove include pre-processor directives
that included header files not directly used by said header files
* Explicitly include header files instead of implicit inclusions via third-party header files.

Release Notes

This will break user code that was using an internal API as the internal header files have been moved.
This will only break if the user was including the header file using a namespace (i.e #include "foo/bar.h" instead of #include "bar.h"
2019-08-02 12:23:47 +01:00
Kimmo Vaisanen 882c21bf0b Fix MBED_ASSERT for UTs
For UTs mbed_assert_internal should not be declared as MBED_NORETURN
as UT stub for mbed_assert_internal only prints out the assert trace
and returns back to original code.
2019-07-31 15:06:28 +03:00
Kevin Bracey 852a626399 Add mstd_xxx headers to unit tests
Stripped down headers that route through to `std` forms more - eg
no local implementation of `atomic` or `mutex`.
2019-07-18 20:02:07 +03:00
Kevin Bracey fc8e8f67c6 Deprecate wait/wait_ms APIs 2019-07-15 10:13:50 +03:00
Kevin Bracey 83b329cb71 RTOS API for bare metal
Provide partial RTOS API for bare metal builds - things that
can be done in a single threaded environment.

Allows more code to work in both RTOS and bare metal builds without
change, and in particular gives easy access to the ability to
efficiently wait for something occurring in interrupt.

Available in bare-metal:
* ThisThread
* osThreadFlagsSet to set flags on main thread (can be set from IRQ)
* EventFlags (can be set from IRQ)
* Semaphores (can be released from IRQ)
* Mutex (dummy implementation)

Not useful:
* ConditionVariable (could only be signalled from 2nd thread)
* RtosTimer (calls in a second thread context)
* Thread

Unimplemented:
* Mail, Queue, MemoryPool

Possible future work:
* ConditionVariableCS to act as IRQ signalled ConditionVariable
2019-07-15 10:13:50 +03:00
Kevin Bracey 607856ee9a Set unit tests to C++14
Adjust some non-C++11-compatible code that failed as a result.
2019-07-09 19:08:57 +03:00
Martin Kojtal 7059221817
Merge pull request #10925 from AnttiKauppila/buff_size_fix
Doubled ATHandler's BUFF_SIZE
2019-07-03 11:48:02 +01:00
Martin Kojtal ccb63d771e
Merge pull request #10857 from ARMmbed/feature-watchdog
Add Watchdog and ResetReason
2019-07-03 11:43:52 +01:00
Martin Kojtal 25fbd3956b Watchdog: remove VirtualWatchdog
We will provide documentation how to create your own VirtualWatchdog. It's simple,
create timeout and watchdog objects.

This class brought lot of discussion and questions. After our refactor we made this class
just a linked list of objects - something tickers can do as well (they already have linked list) and handling hw should be
done via Watchdog due to the limitations (timeout can be set only once per app!).
2019-07-02 12:46:23 +01:00
Filip Jagodzinski 968e270b0b Watchdog: Fix unittests
Compare get_timeout against the last timeout successfully set.
Merge most of the test cases into one. Do not rely on the tests
execution order.
Fix the watchdog_api_stub to keep timeout value set by init function.
2019-07-02 12:46:23 +01:00
Martin Kojtal fd445a57cb Watchdog: remove config value for timeout, set it dynamically
Use start method to set timeout
2019-07-02 12:46:23 +01:00
Martin Kojtal 89c0ab793e VirtualWatchdog: process fail test expects 0 as reset - no ticker running 2019-07-02 12:46:23 +01:00
Filip Jagodzinski cc7a3dd677 Fix more unittest errors 2019-07-02 12:46:23 +01:00
Filip Jagodzinski 1c12f9b2b0 Fix unittest errors 2019-07-02 12:46:23 +01:00
Martin Kojtal 529f4a2a7e unittest: add virtualwatchdog stub 2019-07-02 12:46:23 +01:00
Martin Kojtal 33f8b35917 watchdog unittest: fix naming after refactor 2019-07-02 12:46:23 +01:00
Martin Kojtal 8231efc41c unittest: remove platform watchdog (moved to drivers) 2019-07-02 12:46:23 +01:00
Martin Kojtal 4549a22566 unittest: move watchdog files to drivers
Test VirtualWatchdog and Watchdog
2019-07-02 12:46:23 +01:00
Martin Kojtal 8bbba26842 unittest: rename watchdog to VirtualWatchdog 2019-07-02 12:46:23 +01:00
Martin Kojtal 2d77fccb09 Watchdog: update unittests 2019-07-02 12:46:23 +01:00
Antti Kauppila 369e2d53ff Fixed unittests 2019-07-02 10:17:06 +03:00
Martin Kojtal e40a76575f watchdog: fix copyright 2019-06-26 09:43:21 +01:00
Anna Bridge 15b5b5da23
Merge pull request #10694 from jarvte/set_authentication_type
Cellular: add method to set authentication type to CellularContext
2019-06-21 12:19:04 +01:00
Anna Bridge 6000724de6
Merge pull request #10703 from AnttiKauppila/optimisation
Cellular: Removed boilerplate code
2019-06-19 12:06:10 +01:00
Antti Kauppila 1ed338ef28 Valgrind & unittest fixes 2019-06-13 15:15:53 +03:00
Rajkumar Kanagaraj c41d80330e Fixed the unittest case failure 2019-06-03 16:32:14 +02:00
Rajkumar Kanagaraj dfe4b533c3 Update Watchdog
- Changed the process into static method
 - used the singletonptr for creating the low power ticker instance
 - Added the mbed stub into cmake build for cellularnonipsocket,loramacrypto
2019-06-03 15:31:20 +02:00