Commit Graph

18838 Commits (1aa1682d8c059211ab5ee25ecbf2deb7576a58bf)

Author SHA1 Message Date
Amir Cohen 1aa1682d8c Fix lisence and style 2018-10-08 15:18:50 +01:00
Amir Cohen f8f67e29fc Add TRNG API test 2018-10-08 15:18:50 +01:00
Seppo Takalo 3664339c39 Use SocketAddr that actually has IP bytes in UDP test 2018-10-08 15:18:50 +01:00
Seppo Takalo 5b659c898b Fix TCPSocket::accept() unittest.
accept() is not anymore returning NULL pointer. It was a bug.
2018-10-08 15:18:50 +01:00
Michal Paszta 6c012fc476 unittests: Add tests for NetworkStack class.
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.
2018-10-08 15:18:50 +01:00
Michal Paszta 43ca738436 unittests: Add TCPServer unit tests
TCPServer class only really implements attach method.
2018-10-08 15:18:50 +01:00
Michal Paszta 54ee25cf1e unittests: Added NetworkInterface unit tests
Most functions are empty or simply return "UNSUPPORTED", but it is still worth covering this functions with unit tests to have better control of unwanted changes.
2018-10-08 15:18:50 +01:00
Michal Paszta 77fc6a0347 unittests: InternetSocket class coverage improved.
Added more tests, improved the existing ones. setblocking tests were not checking anything, so they were removed and these functions are called in TCPSocket tests instead.
2018-10-08 15:18:50 +01:00
Michal Paszta 46b529a1ea unittests: Check NULL pointer scenario in TCPSocket::recvfrom 2018-10-08 15:18:50 +01:00
Michal Paszta 2bbf033fe2 unittests: improved coverage for UDPSocket and TCPSocket
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.
2018-10-08 15:18:50 +01:00
Lari-Matias Orjala cb80c49f3a Unit tests: improve argument checking in coverage.py 2018-10-08 15:18:50 +01:00
Lari-Matias Orjala 605a72cead add coverage filtering 2018-10-08 15:18:50 +01:00
ccli8 31236f11e3 Fix pin mode mapping between input pull mode/direction and I/O mode
1. Modify PinMode enum to fully support GPIO I/O modes.
2. Translate input pull mode/direction to I/O mode, where H/W doesn't support
   separate configuration for input pull mode/direction.
3. Allow for configuring I/O mode in addition to input pull mode.
2018-10-08 15:18:50 +01:00
Mirela Chirica 82ba6314dc Cellular: Fix cellular util unit test 2018-10-08 15:18:50 +01:00
Mirela Chirica 523edf0561 Cellular: Fix cellular network unit test 2018-10-08 15:18:50 +01:00
jeromecoutant 7fcf9cc45c SM32F3 correct analogin_read 2018-10-08 15:18:50 +01:00
Edd Inglis 366ad09e67 Changed the reported SNR from unsigned to signed. Internally and logically it is a signed value. 2018-10-08 15:18:50 +01:00
mattbrown015 2ca243d69d STM32: Disabling of IRQs shared by multiple events
Discern if an IRQ is being shared by multiple events and only disable the IRQ if no events are using it.
2018-10-08 15:18:50 +01:00
Mahesh Mahadevan 42e309e2c9 LPC1768: Enable RTC
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2018-10-08 15:18:50 +01:00
Przemyslaw Stekiel f9c91c1fd5 Fix for issue #8155 (NRF52832: time stops after 35 minutes)
Low power Timer is used as RTC for platforms that don't have HW RTC capabilities (like NRF52832).
`_rtc_lpticker_read(void)` function currently uses `Timer::read()` function to trace elapsed time.
`Timer::read()` returns seconds represented as `float` value, but this value is calculated from `int` since `Timer::read_us()` returns `int`.
This limits time tracing to ~35 min.
To fix this problem we will use `timer::read_high_resolution_us()` (which returns unsigned 64 bit value) instead of `Timer::read()`.
2018-10-08 15:18:50 +01:00
Steven e02872f4ea Apply @kjbracey-arm's comments 2018-10-08 15:18:50 +01:00
Steven cdadf637dc Word-sized input to GPCRC is only valid for 32-bit polynomial 2018-10-08 15:18:50 +01:00
paul-szczepanek-arm 38b0df0f79 fix whitelist generation (set correct address type) 2018-10-08 15:18:50 +01:00
ccli8 ad248ca8ac Fix STDIO_UART error 2018-10-08 15:18:50 +01:00
Lari-Matias Orjala f681e54690 update UNITTESTS/README.md 2018-10-08 15:18:50 +01:00
David Saada 8f806f834e Handle NVStore tests in a low memory environment 2018-10-08 15:18:50 +01:00
Amanda Butler 665c98f522 Add GH link to README.md
Add link for contributing to docs, as well.
2018-10-08 15:18:50 +01:00
Amanda Butler 9919ca6e24 Add link to README.md
Add link to published documentation.
2018-10-08 15:18:50 +01:00
Tero Jääskö 353c4fd9b3 platform: error: fix bogus usage of memset()
Code had mixed up order of 'c' and 'n' arguments to memset().
Fix this.

Spotted-by: kjbracey-arm & a GCC profile without "-fno-builtin"

Related GCC warnings:
---8<---8<----
[Warning] mbed_error.c@123,5: 'memset' used with constant zero length parameter; this could be due to transposed parameters [-Wmemset-transposed-args]
[Warning] mbed_error.c@282,5: 'memset' used with constant zero length parameter; this could be due to transposed parameters [-Wmemset-transposed-args]
2018-10-08 15:18:50 +01:00
Lari-Matias Orjala 119246d132 add UNITTESTS folder to exclude patterns in doxygen_options.json 2018-10-08 15:18:50 +01:00
Russ Butler ddceb6597a Replace macros with config options
Add a config option for the following values:
MBED_SYS_STATS_ENABLED
MBED_STACK_STATS_ENABLED
MBED_CPU_STATS_ENABLED
MBED_HEAP_STATS_ENABLED
MBED_THREAD_STATS_ENABLED
MBED_CONF_APP_MAIN_STACK_SIZE
MBED_CONF_APP_TIMER_THREAD_STACK_SIZE
MBED_CONF_APP_IDLE_THREAD_STACK_SIZE
MBED_CONF_APP_THREAD_STACK_SIZE

To maintain backwards compatibility inside the RTOS both
APP and RTOS config values can be used.
2018-10-08 15:18:50 +01:00
Jarno Lamsa 38550771ef Add documentation about icetea testcases 2018-10-08 15:18:50 +01:00
Ari Parkkila 85a6a075eb Cellular: Disable AT+CGAUTH on HE910 and BC95 2018-10-08 15:18:50 +01:00
Ari Parkkila fe385baa88 Cellular: Implement APN authentication for BG96 2018-10-08 15:18:50 +01:00
Ari Parkkila a060089a7a Cellular: Fix APN authentication before context activation 2018-10-08 15:18:50 +01:00
ccli8 8e37c213e4 Create MCU_M480 for inheritance by M487 targets
In targets.json, create MCU_M480 for inheritance by NUMAKER_PFM_M487/NUMAKER_IOT_M487.
2018-10-08 15:18:50 +01:00
ccli8 c59d20f12f Add missing mbedtls_device.h for NUMAKER_IOT_M487 2018-10-08 15:18:50 +01:00
ccli8 38c7abfe7f Support Nuvoton's NuMaker-IoT-M487 board 2018-10-08 15:18:50 +01:00
Lari-Matias Orjala 2bd1f64531 replace missing types 2018-10-08 15:18:50 +01:00
Lari-Matias Orjala 814ff08789 fix athandler unit tests and declaration conflict 2018-10-08 15:18:50 +01:00
Kevin Bracey 62a55a6423 Remove IAR assembler macros containing quotes
IAR assembler 7.80 has some problems handling difficult macros, leading
to immediate exit with return value -11.

In particular, a URL string has been causing problems, presumably due to
the "//" resembling a comment.

A previous escaping workaround in 0d97803 seemed to work, but the crash
has still been seen with a particular target.

Previous creation of the extended command line file for the IAR
assembler was stripping quotes from macros. This rendered the resulting
definitions for string-containing macros incorrect, which means that we
can assume no assembler code is currently relying on them.

Therefore, as a precautionary measure to avoid the crash, simply remove
all macros containing strings when creating them for IAR. This
apparently clears the crashes seen during testing of
https://github.com/ARMmbed/mbed-os/pull/8023
2018-10-08 15:18:50 +01:00
Steven a518ff9e8e Supply default test config for TB_SENSE_1 as well 2018-10-08 15:18:50 +01:00
Steven 92cb4fe6b7 Hotfix for PR #7778
TB_SENSE_12 would have been left behind by the changes in #7778. This commit implements the changes in mbed to allow targets to provide a default network interface for Silicon Labs targets.
2018-10-08 15:18:50 +01:00
ccli8 203e87ba61 Fix Greentea test common_tickers failed
1. Disable ticker interrupt which would interfere with fire_interrupt speed test
2. Enlarge test period to avoid timeout error
2018-10-08 15:18:50 +01:00
ccli8 78cbc0db97 Synchronize us_ticker to lp_ticker
This is to make implementations of us_ticker/lp_ticker consistent.
2018-10-08 15:18:50 +01:00
ccli8 e884ce9032 Fix lp_ticker_free cannot pass speed test 2018-10-08 15:18:50 +01:00
ccli8 a0c2518761 Fix spurious us_ticker/lp_ticker interrupts
If us_ticker/lp_ticker is scheduled and then the interrupt is disabled, the originally scheduled
interrupt may still become pending. If this occurs, then an interrupt will fire twice on the next
call to us_ticker_set_interrupt/lp_ticker_set_interrupt - once immediately and then a second time
at the appropriate time.

This patch prevents the first interrupt by clearing interrupts in
us_ticker_set_interrupt/lp_ticker_set_interrupt before calling NVIC_EnableIRQ.
2018-10-08 15:18:50 +01:00
bcostm 413ee535da STM32: fix wrong LSE config in serial_baud function 2018-10-08 15:18:50 +01:00
studavekar e1b57ef24e specify mbed-cli version requirement 2018-10-08 15:18:50 +01:00
Kimmo Vaisanen e7d7b0ded6 Lora: Fix sticky MAC command retransmission
This commit fixes the bug where sticky MAC commands were duplicated in
send buffer everytime send() was called.
2018-10-08 15:18:50 +01:00