Skip to content

Release candidate for mbed-os-5.8.1 #6461

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 118 commits into from
Mar 27, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
118 commits
Select commit Hold shift + click to select a range
4b3412c
Call i2c_init() before i2c_frequency() (since i2c_frequency() require…
RobMeades Mar 1, 2018
99a250e
Rework us_ticker and lp_ticker with one H/W timer
ccli8 Feb 22, 2018
6ddb135
Correct mbed export with multiple --source params
theotherjimmy Feb 20, 2018
bf40cb5
Specify --build in mbed export: consistency with compile
theotherjimmy Feb 20, 2018
2279c8b
Correct gcc m33 floating point handling
theotherjimmy Feb 16, 2018
87b9035
Modified underflow error text to print overflow instead. End users ar…
cmonr Mar 5, 2018
ef8dc12
Cellular tests: nsapi_socket_t errors fixed in unittests
Mar 5, 2018
3ca392c
Fix missing serial object for interrupts
Feb 2, 2018
7c6321b
Improve SPI block write
Feb 2, 2018
39d589d
Improve us ticker performance
Feb 2, 2018
dce8d29
Enable ADC scaling and enable internal channels
Feb 2, 2018
eca06e1
Remove automatic I2C stop after each read
Feb 2, 2018
b471d97
Replace enable/disable irq with critical section enter/exit
Feb 26, 2018
e30b81a
Add support for STEVAL-3DP001V1 board, which has an STM32F401VE chip.…
daid Feb 14, 2018
c80ff8a
mcu_lpc546xx: move "release_versions" to children
Feb 28, 2018
21256b1
lpc546xx and lpc54114: fix clock
Feb 28, 2018
ef58ece
Clarify intention between comparison to zero and the shift operation
Mar 4, 2018
379b71f
Flip order of comparison
Mar 5, 2018
42d46f9
Small typo fixes in readme.md files
jdewinkel Mar 6, 2018
98b6f9a
fixes a typo in README.md
jiangkun1994 Mar 6, 2018
3ce040a
fixes some typos in README.md
jiangkun1994 Mar 6, 2018
4c67a9f
fixes a typo in README.md
jiangkun1994 Mar 6, 2018
bedf76c
Allow build profiles to omit language entries
Mar 2, 2018
f8d0c27
mbed-os_ci-test-fixed_rtl8195am
M-ichae-l Feb 27, 2018
46e7fa8
Adding Laird BL652 as new target
Feb 22, 2018
dc0beb7
Incorporating review comments
Mar 6, 2018
4aa652f
Fix linefeed issues in crash dump output
SenRamakri Mar 5, 2018
997a69c
Add mode and privilege info to crash dump
SenRamakri Mar 5, 2018
c279da6
Fixed Cellular unit tests by adding one missing stub after changes in…
Mar 7, 2018
aa05e88
MCUXpresso_MCUS: Apply K64F us_ticker fix across all MCU's
mmahadevan108 Mar 6, 2018
2a3d6d4
Make gpio interrupts faster by offloading expected state check to user
amq Mar 9, 2018
5f848b1
Cellular: ATHandler write improvements.
Mar 9, 2018
9235410
mts_mdot_f411re: Fix for Multi-Tech mDot IAR linker script
hosse005 Mar 8, 2018
28f5d8e
K82F: Fix I2C test failures seen with ci-test shield
mmahadevan108 Mar 9, 2018
4cd58fe
MCUXpresso: Enable I2C SDA & SCL pins internal pullup resistors
mmahadevan108 Mar 9, 2018
29ab0cd
MCUXpresso: Update the I2C implmentation for byte read and write
mmahadevan108 Mar 9, 2018
7c7d897
Align `ATCmdParser::process_oob()` to `ATCmdParser::vrecv()`'s newlin…
betzw Mar 8, 2018
a8915ba
Fix initialization of phy_params.payloads_with_repeater.size
Mar 8, 2018
92f4b98
Fix verification of RX2 datarate
Mar 8, 2018
b2e31fb
Fix macro definition of iodefine_typedef for RZ_A1H
TomoYamanaka Mar 7, 2018
2e9a0eb
events: Added note about immediate firing of periodic events
geky Mar 5, 2018
d6dcebe
Flash support: Add flash support for LPC54114 & LPC546XX
mmahadevan108 Feb 23, 2018
f94dd8d
typos
bmcdonnell-ionx Jan 16, 2018
43db7b3
a few grammar corrections
bmcdonnell-ionx Feb 21, 2018
c59380d
revert typos in external sources
bmcdonnell-ionx Feb 22, 2018
1d97921
revert accidentally-included change from 7094e13891cde91b0ddccda56263…
bmcdonnell-ionx Mar 8, 2018
f003b98
Tests: Drivers: Timeout: Update unit tests
fkjagodzinski Sep 12, 2017
d63f07b
mbed-mesh-api: add JSON help
kjbracey Feb 14, 2018
2df1f47
mbed-mesh-api: revise some Thread JSON help
kjbracey Mar 6, 2018
3508c20
rtl8195am - improve credentials handling
juhaylinen Mar 7, 2018
20cefbf
Cellular: Fixed sms unit tests.
Mar 13, 2018
2af9b5c
callback API added
Mar 12, 2018
90da5a5
Convert option list to unicode
theotherjimmy Mar 14, 2018
1525bc0
NVStore: add comments in header file for Doxygen formatting sake.
Mar 14, 2018
abb9c74
STM32L486: fix two ram region define for GCC ARM
0xc0170 Mar 13, 2018
4b31413
WISE_1570: use hex as output
0xc0170 Mar 13, 2018
322fe96
STM32 RTC init
jeromecoutant Mar 14, 2018
941dcca
Enable iar export option for MTB_ADV_WISE_1510
chuanga Mar 14, 2018
c2b61e5
Removed mbed 2 builds from Travis
geky Feb 15, 2018
8b557f2
rtl8195am : fix gpio toggle slow
M-ichae-l Mar 12, 2018
e97939e
fix mbed-ci build error L6216E
M-ichae-l Mar 15, 2018
dbaa387
Added deprecation notes to old cellular interfaces.
Feb 27, 2018
5155878
Moved APN_db.h under new cellular.
Mar 5, 2018
6dd0a79
MBED_DEPRECATED_SINCE taken into use
Mar 12, 2018
08d681a
PR review findings, updated deprecated comments.
Mar 13, 2018
b7526ed
Fixed correct includes so that compile log is not polluted.
Mar 13, 2018
b4ac1a5
DISCO_L496AG: add PeripheralPins.c
bcostm Mar 5, 2018
615ac58
DISCO_L496AG: remove QSPI2
bcostm Mar 5, 2018
1bbcd08
DISCO_L496AG: add other pins related files
bcostm Mar 5, 2018
e9a2373
DISCO_L496AG: add platform in targets.json file
bcostm Mar 5, 2018
ed63943
DISCO_L496AG: add system clock file (same as Nucleo)
bcostm Mar 5, 2018
b33c524
DISCO_L496AG: add entry in mbed_rtx.h
bcostm Mar 6, 2018
42e3be8
DISCO_L496AG: remove morpho connector in targets.json
bcostm Mar 6, 2018
5e2977f
Fix doxygen for ITM HAL
bulislaw Mar 15, 2018
84c1aee
Fix on chip flash minimal programmable unit size
Mar 15, 2018
2df7de2
Correct Realtek post-build script to work in the online compiler
theotherjimmy Feb 26, 2018
40d9b3e
Correct syntax for mbed export in Py3
theotherjimmy Feb 23, 2018
4611bb6
Correct type issue in export arg parsing
theotherjimmy Mar 16, 2018
cd8f583
Add ASM flags virtual path for make export
hug-dev Mar 13, 2018
f2dcff5
Add ASM include flags in uvision export
hug-dev Mar 13, 2018
95ca5de
Disabled flash clock and cache test for NRF52 MCUs. This is meant to …
cmonr Mar 19, 2018
5cb29a7
Own SIM state retrieval for Quectel BC95
Mar 8, 2018
a708296
Release AT handler if network not created
Mar 8, 2018
79fa577
Fix wrong header define name
Mar 8, 2018
b620a35
Use of APN lookup decision logic fixed
Mar 8, 2018
3cbfd3f
Quectel BC95 echo test fixes
Mar 8, 2018
f2db21f
STM32 LPTICKER : optimize RTC wake up timer init
jeromecoutant Mar 15, 2018
aad97a6
dir seek fixed - dptr was not updated before checking
Mar 14, 2018
6d4e280
Cellular: update attach test
Mar 13, 2018
a8cde30
Removed strncmp
Mar 15, 2018
4c93aa2
littlefs: Fixed issue updating dir struct when extended dir chain
geky Mar 12, 2018
9d59086
Corrected lwip adaptation TCP flagging
Mar 12, 2018
c5650d8
NUCLEO_L433RC_P: fix LEDs pin assignment
bcostm Mar 12, 2018
5db8a42
Enabled os5 support for VK_RZ_A1H & synced with rest Renesas targets !
mbedNoobNinja Mar 1, 2018
0d8874c
Remove unnecessary UART INT in UART DMA transfer
ccli8 Mar 19, 2018
3445a3a
armcc - remove fromelf output before regenerating
tung7970 Mar 13, 2018
9502d6b
CM3DS: switch to larger memories for code and data
hug-dev Jan 8, 2018
1b58173
Copy edit README.md
Mar 1, 2018
5cf249a
Copy edit README.md
Mar 10, 2018
1a2b41c
equeue: Added profiling reports to Travis
geky Mar 15, 2018
b744111
Remove unnecessary casts
kjbracey Nov 28, 2017
c6ab7de
Add volatile qualifiers to atomic functions
kjbracey Nov 28, 2017
3fdce9b
PR template: fix task
0xc0170 Mar 13, 2018
aca6620
PR template: only one should be checked
0xc0170 Mar 13, 2018
d07086c
PR template: do not use task list
0xc0170 Mar 20, 2018
c9a727e
STM32L4 ADC Internal Channel : correct sampling time
jeromecoutant Mar 20, 2018
0b866b7
STM32L4 ADC correct internal channel management
jeromecoutant Mar 21, 2018
1965c11
Replace runtime strip_path function with compiler intrinsic equivalents
Mar 15, 2018
87029c6
Refactor sleep tracing driver identifier to be pointer to the driver …
Mar 15, 2018
6c04d9e
Remove superfluous compiler check in macro
Mar 16, 2018
4ff6dd2
Remove IAR compiler flag change from PR
Mar 19, 2018
43e646d
Fix issues with __FILENAME__ macro
Mar 20, 2018
7138038
Correct get_config imports
theotherjimmy Mar 21, 2018
038ede3
Fix page size in flash IAP
ccli8 Mar 22, 2018
c4aed9d
Modified apt-get retry logic with Travis CI retry feature
cmonr Mar 22, 2018
20d9b4a
Update Mbed version block for patch release
adbridge Mar 26, 2018
3ba208a
Update mbed-coap to version 4.3.0
Feb 22, 2018
a48b62d
Update mbed-coap to version 4.4.0
Mar 14, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 12 additions & 6 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,17 @@

<!--
Required
Please tick one of the following types
Please tick only one of the following types. Do not tick more or change the layout.

[X] Fix
[ ] Refactor
[ ] New target
[ ] Feature
[ ] Breaking change
-->

- [ ] Fix
- [ ] Refactor
- [ ] New target
- [ ] Feature
- [ ] Breaking change
[ ] Fix
[ ] Refactor
[ ] New target
[ ] Feature
[ ] Breaking change
54 changes: 19 additions & 35 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ before_install:
# Setup ppa to make sure arm-none-eabi-gcc is correct version
- sudo add-apt-repository -y ppa:team-gcc-arm-embedded/ppa
# Loop until update succeeds (timeouts can occur)
- while [ -n "$(sudo apt-get update 2>&1 |grep Failed)" ]; do :; done
- travis_retry $(! sudo apt-get update 2>&1 |grep Failed)

after_success:
- bash -c "$STATUS" success "Local $NAME testing has passed"
Expand Down Expand Up @@ -115,6 +115,24 @@ matrix:
- python tools/make.py -t GCC_ARM -m DISCO_F401VC --source=. --build=BUILD/DISCO_F401VC/GCC_ARM -j0
# Run local equeue tests
- make -C $EVENTS/equeue test
# Run profiling tests
- make -C $EVENTS/equeue prof | tee prof
after_success:
# update status if we succeeded, compare with master if possible
- |
CURR=$(grep -o '[0-9]\+ cycles' prof | awk '{sum += $1} END {print sum}')
PREV=$(curl https://api.github.com/repos/$TRAVIS_REPO_SLUG/status/master \
| jq -re "select(.sha != \"$TRAVIS_COMMIT\")
| .statuses[] | select(.context == \"travis-ci/$NAME\").description
| capture(\"runtime is (?<runtime>[0-9]+)\").runtime" \
|| echo 0)

STATUSM="Passed, runtime is ${CURR} cycles"
if [ "$PREV" -ne 0 ]
then
STATUSM="$STATUSM ($(python -c "print '%+d' % ($CURR-$PREV)") cycles)"
fi
- bash -c "$STATUS" success "$STATUSM"

- env:
- NAME=littlefs
Expand Down Expand Up @@ -187,37 +205,3 @@ matrix:
STATUSM="$STATUSM ($(python -c "print '%+.2f' % (100*($CURR-$PREV)/$PREV.0)")%)"
fi
- bash -c "$STATUS" success "$STATUSM"

- &mbed-2
env: NAME=mbed2-NXP
install:
# Install dependencies
- export GCC_DIR=$HOME/gcc-arm-none-eabi-6-2017-q2-update
- export GCC_ARCHIVE=$HOME/gcc-arm-none-eabi-6-2017-q2-update-linux.tar.bz2
- export GCC_URL=https://developer.arm.com/-/media/Files/downloads/gnu-rm/6-2017q2/gcc-arm-none-eabi-6-2017-q2-update-linux.tar.bz2?revision=2cc92fb5-3e0e-402d-9197-bdfc8224d8a5?product=GNU%20Arm%20Embedded%20Toolchain,64-bit,,Linux,6-2017-q2-update
- if [ ! -e $GCC_DIR/bin/arm-none-eabi-gcc ]; then wget $GCC_URL -O $GCC_ARCHIVE; tar xfj $GCC_ARCHIVE -C $HOME; fi
- export PATH=$PATH:$GCC_DIR/bin
- pip install -r requirements.txt
# Print versions we use
- arm-none-eabi-gcc --version
- python --version
before_script:
# Create BUILD directory for tests
- mkdir BUILD
script:
# Run local mbed 2 testing
- python -u tools/build_travis.py --vendor "${NAME#mbed2-}"
- <<: *mbed-2
env: NAME=mbed2-STM
- <<: *mbed-2
env: NAME=mbed2-NORDIC
- <<: *mbed-2
env: NAME=mbed2-SILICON_LABS
- <<: *mbed-2
env: NAME=mbed2-MAXIM
- <<: *mbed-2
env: NAME=mbed2-ATMEL
- <<: *mbed-2
env: NAME=mbed2-NUVOTON
- <<: *mbed-2
env: NAME=mbed2-RENESAS
155 changes: 48 additions & 107 deletions TESTS/mbed_drivers/lp_timeout/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,138 +15,79 @@
*/

#if !DEVICE_LOWPOWERTIMER
#error [NOT_SUPPORTED] Low power timer not supported for this target
#error [NOT_SUPPORTED] Low power timer not supported for this target
#endif

#include "mbed.h"
#include "greentea-client/test_env.h"
#include "utest/utest.h"
#include "unity/unity.h"
#include "greentea-client/test_env.h"

#include "mbed.h"
#include "../timeout/timeout_tests.h"

using namespace utest::v1;

volatile static bool complete;
static LowPowerTimeout lpt;

/* Timeouts are quite arbitrary due to large number of boards with varying level of accuracy */
#define LONG_TIMEOUT (100000)
#define SHORT_TIMEOUT (600)

void cb_done() {
complete = true;
}

#if DEVICE_SLEEP
void lp_timeout_1s_deepsleep(void)
utest::v1::status_t greentea_failure_handler(const Case * const source, const failure_t reason)
{
complete = false;
LowPowerTimer timer;

/*
* Since deepsleep() may shut down the UART peripheral, we wait for 10ms
* to allow for hardware serial buffers to completely flush.

* This should be replaced with a better function that checks if the
* hardware buffers are empty. However, such an API does not exist now,
* so we'll use the wait_ms() function for now.
*/
wait_ms(10);

/*
* We use here the low power timer instead of microsecond timer for start and
* end because the microseconds timer might be disable during deepsleep.
*/
timer.start();
lpt.attach(&cb_done, 1);
/* Make sure deepsleep is allowed, to go to deepsleep */
bool deep_sleep_allowed = sleep_manager_can_deep_sleep();
TEST_ASSERT_TRUE_MESSAGE(deep_sleep_allowed, "Deep sleep should be allowed");
sleep();
while (!complete);

/* It takes longer to wake up from deep sleep */
TEST_ASSERT_UINT32_WITHIN(LONG_TIMEOUT, 1000000, timer.read_us());
TEST_ASSERT_TRUE(complete);
greentea_case_failure_abort_handler(source, reason);
return STATUS_CONTINUE;
}

void lp_timeout_1s_sleep(void)
{
complete = false;
Timer timer;
timer.start();

sleep_manager_lock_deep_sleep();
lpt.attach(&cb_done, 1);
bool deep_sleep_allowed = sleep_manager_can_deep_sleep();
TEST_ASSERT_FALSE_MESSAGE(deep_sleep_allowed, "Deep sleep should be disallowed");
sleep();
while (!complete);
sleep_manager_unlock_deep_sleep();

TEST_ASSERT_UINT32_WITHIN(LONG_TIMEOUT, 1000000, timer.read_us());
TEST_ASSERT_TRUE(complete);
}
#endif /* DEVICE_SLEEP */
Case cases[] = {
Case("Callback called once (attach)", test_single_call<AttachTester<LowPowerTimeout> >),
Case("Callback called once (attach_us)", test_single_call<AttachUSTester<LowPowerTimeout> >),

void lp_timeout_us(uint32_t delay_us, uint32_t tolerance)
{
complete = false;
Timer timer;
timer.start();
Case("Callback not called when cancelled (attach)", test_cancel<AttachTester<LowPowerTimeout> >),
Case("Callback not called when cancelled (attach_us)", test_cancel<AttachUSTester<LowPowerTimeout> >),

lpt.attach_us(&cb_done, delay_us);
while (!complete);
Case("Callback override (attach)", test_override<AttachTester<LowPowerTimeout> >),
Case("Callback override (attach_us)", test_override<AttachUSTester<LowPowerTimeout> >),

/* Using RTC which is less accurate */
TEST_ASSERT_UINT32_WITHIN(tolerance, delay_us, timer.read_us());
TEST_ASSERT_TRUE(complete);
}
Case("Multiple timeouts running in parallel (attach)", test_multiple<AttachTester<LowPowerTimeout> >),
Case("Multiple timeouts running in parallel (attach_us)", test_multiple<AttachUSTester<LowPowerTimeout> >),

void lp_timeout_5s(void)
{
lp_timeout_us(5000000, LONG_TIMEOUT);
}
Case("Zero delay (attach)", test_no_wait<AttachTester<LowPowerTimeout> >),
Case("Zero delay (attach_us)", test_no_wait<AttachUSTester<LowPowerTimeout> >),

void lp_timeout_1s(void)
{
lp_timeout_us(1000000, LONG_TIMEOUT);
}
Case("10 ms delay accuracy (attach)", test_delay_accuracy<AttachTester<LowPowerTimeout>, 10000, SHORT_DELTA_US>,
greentea_failure_handler),
Case("10 ms delay accuracy (attach_us)", test_delay_accuracy<AttachUSTester<LowPowerTimeout>, 10000, SHORT_DELTA_US>,
greentea_failure_handler),

void lp_timeout_1ms(void)
{
lp_timeout_us(1000, SHORT_TIMEOUT);
}
Case("1 s delay accuracy (attach)", test_delay_accuracy<AttachTester<LowPowerTimeout>, 1000000, LONG_DELTA_US>,
greentea_failure_handler),
Case("1 s delay accuracy (attach_us)", test_delay_accuracy<AttachUSTester<LowPowerTimeout>, 1000000, LONG_DELTA_US>,
greentea_failure_handler),

void lp_timeout_500us(void)
{
lp_timeout_us(500, SHORT_TIMEOUT);

}
Case("5 s delay accuracy (attach)", test_delay_accuracy<AttachTester<LowPowerTimeout>, 5000000, LONG_DELTA_US>,
greentea_failure_handler),
Case("5 s delay accuracy (attach_us)", test_delay_accuracy<AttachUSTester<LowPowerTimeout>, 5000000, LONG_DELTA_US>,
greentea_failure_handler),

utest::v1::status_t greentea_failure_handler(const Case *const source, const failure_t reason) {
greentea_case_failure_abort_handler(source, reason);
return STATUS_CONTINUE;
}

Case cases[] = {
Case("500us LowPowerTimeout", lp_timeout_500us, greentea_failure_handler),
Case("1ms LowPowerTimeout", lp_timeout_1ms, greentea_failure_handler),
Case("1sec LowPowerTimeout", lp_timeout_1s, greentea_failure_handler),
Case("5sec LowPowerTimeout", lp_timeout_5s, greentea_failure_handler),
#if DEVICE_SLEEP
Case("1sec LowPowerTimeout from sleep", lp_timeout_1s_sleep, greentea_failure_handler),
Case("1sec LowPowerTimeout from deepsleep", lp_timeout_1s_deepsleep, greentea_failure_handler),
#endif /* DEVICE_SLEEP */
Case("1 s delay during sleep (attach)", test_sleep<AttachTester<LowPowerTimeout>, 1000000, LONG_DELTA_US>,
greentea_failure_handler),
Case("1 s delay during sleep (attach_us)", test_sleep<AttachUSTester<LowPowerTimeout>, 1000000, LONG_DELTA_US>,
greentea_failure_handler),

Case("1 s delay during deepsleep (attach)", test_deepsleep<AttachTester<LowPowerTimeout>, 1000000, LONG_DELTA_US>,
greentea_failure_handler),
Case("1 s delay during deepsleep (attach_us)", test_deepsleep<AttachUSTester<LowPowerTimeout>, 1000000, LONG_DELTA_US>,
greentea_failure_handler),
#endif

Case("Timing drift (attach)", test_drift<AttachTester<LowPowerTimeout> >),
Case("Timing drift (attach_us)", test_drift<AttachUSTester<LowPowerTimeout> >),
};

utest::v1::status_t greentea_test_setup(const size_t number_of_cases) {
GREENTEA_SETUP(20, "default_auto");
utest::v1::status_t greentea_test_setup(const size_t number_of_cases)
{
GREENTEA_SETUP(240, "timing_drift_auto");
return greentea_test_setup_handler(number_of_cases);
}

Specification specification(greentea_test_setup, cases, greentea_test_teardown_handler);

int main() {
int main()
{
Harness::run(specification);
}
Loading