Commit Graph

335 Commits

Author SHA1 Message Date
Yakun Xu dd1e0f4695 [cli] add legacy stub in cli (#3729)
This commit adds stubs for legacy APIs.
2019-04-02 09:11:46 -07:00
Jonathan Hui 49c4b63491 [style] make parameter names consistent across decls and defs (#3705) 2019-03-22 08:12:26 -07:00
Jonathan Hui e00114b3f1 [style] mark single-arg constructors as explicit (#3705)
Avoids unintentional implicit conversions.
2019-03-22 08:12:26 -07:00
Jonathan Hui 2ab9b49042 [style] use C++-style casts (#3705) 2019-03-22 08:12:26 -07:00
Zhanglong Xia 96725a985e [phy] add support for OQPSK modulation in 915MHz band (#3378) 2019-03-08 08:09:55 -08:00
Łukasz Duda 9297f3559d [cli] allow to define ping interval in milliseconds (#3607) 2019-02-19 12:04:23 -08:00
Łukasz Duda 8c13df5a51 [cli] add command to retrieve mle counters (#3605) 2019-02-19 11:37:45 -08:00
Jonathan Hui 404d946150 [cli] validate ping interval is positive to avoid Timer::Start() assert (#3548) 2019-02-04 10:51:45 -08:00
Jonathan Hui 1c2e7033bf [cli] fix ping interval bounds check to avoid Timer::Start() assert (#3531) 2019-01-29 11:54:38 -08:00
Yakun Xu 504331eadd [mac] remove mDidTx from otRadioFrame (#3520)
mDidTx indicates whether a frame is received or transmitted, which is
only useful for capturing packets. This commit removes this field, and makes
this flag an argument to the pcap callback.
2019-01-28 12:31:15 -08:00
Jonathan Hui 251207d725 [cli] add lower bounds check to channel selection (#3523) 2019-01-28 08:39:18 -08:00
Jonathan Hui 249bc59874 [cli] add length check for "service add" (#3508) 2019-01-25 08:36:06 -08:00
Jonathan Hui 993f537a03 [cli] add ping interval bounds check to avoid Timer::Start() assert (#3507) 2019-01-25 08:35:44 -08:00
Yakun Xu 5777e017ac [cli] refine CLI APIs (#3501) 2019-01-24 18:19:50 -08:00
Jonathan Hui ce3c712fe6 [cli] validate prefix add/remove argument count (#3505) 2019-01-24 09:04:38 -08:00
Jonathan Hui aa5673cd48 [cli] add bounds check on channel selection (#3499) 2019-01-23 21:50:38 -08:00
Yakun Xu 3fabc4660c [slaac] handle slaac internally (#3484) 2019-01-22 23:34:26 -08:00
Robert Lubos 9cb48245e5 [cli] fix GetOwner function for console cli backend (#3486)
Current implementation of GetOwner function for single-instance CLI
assumed that `cli_uart` backend is used. This caused application
crash when different backend was used and `cli_uart` was not
initialized (and in result sUartServer static pointer was not set).

This commit fixes the issue by moving static CLI Server pointer and
the mInterpreter field to the to the base Server class and providing
getter method to obtain the Interpreter instance. With this approach,
any backend derived from the Server class will be able to initialize
the static pointer and will provide a valid reference to the
Interpreter class instance.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2019-01-22 16:07:46 -08:00
Yakun Xu f40f49ff32 [dhcp] remove dhcp server api (#3476) 2019-01-18 11:34:40 -08:00
Yakun Xu 820d231067 [cli] cleanup dataset implementation (#3474) 2019-01-18 11:32:36 -08:00
Yakun Xu eb8c6d90bd [diag] quick fix to support long output (#3436)
`Cli::Uart::OutputFormat()` current only supports output
`OPENTHREAD_CONFIG_CLI_MAX_LINE_LENGTH` bytes, which isn't enough
for command *diag* by default. This PR removes that restriction
by using `Cli::Uart::Output`.

I think this is just a quick fix, an overall enhancement of Cli is
needed so that we can use small stack size but also get better
performance.
2019-01-09 09:43:14 -08:00
rongli 328239878d [data-poll-manager] check user-specified poll period (#3401) 2018-12-27 22:35:57 -08:00
Jing eca3e81fd3 [thci] update pollperiod command to accept ms resolution configuration (#3361) 2018-12-27 15:39:46 -08:00
Yakun Xu de63012c9e [dhcp6-client] remove dhcp6 client api (#3287) 2018-12-12 09:58:15 -08:00
Zhanglong Xia 71753b3cb6 [cli] add channel monitor and channel manager commands (#3286) 2018-11-26 10:28:59 -08:00
Jonathan Hui e14d763e2e [style] relocate OT_UNUSED_VARIABLE (#3299) 2018-11-17 12:04:41 -08:00
Joseph Newman a5f1ed263d [cli] fix network time format specifier (#3278) 2018-11-07 11:35:18 -08:00
Zhanglong Xia f8909593a9 [api] update message API to create message with priority (#3199) 2018-11-05 12:48:39 -08:00
Łukasz Duda 4a89cc63b6 [sntp] initial implementation of sntp client (#3237) 2018-11-03 08:11:05 -07:00
Łukasz Duda 597a81fd0a [dns] simplify defines name and clean up (#3209) 2018-10-25 12:58:29 -07:00
Jonathan Hui 5a489836cd [naming] rename FFD to FTD (#3102) 2018-09-27 09:33:03 -07:00
Christian Stauffer 2ce47a8e9c [coaps] CoAP Secure Client/Server accessible through OT API (#2716) 2018-09-24 11:22:08 -10:00
Shu Chen 9a9da5124f [cli] support energy scan command (#3036) 2018-09-06 07:30:55 -10:00
Shu Chen 3174c590c3 [utils] implement a common method for command line parsing (#3001) 2018-09-05 00:40:02 -07:00
Shu Chen 026badad96 [diags] use temporary buffer for diag output (#2992) 2018-08-28 09:24:23 -07:00
Yakun Xu 0cea4bc738 [cli] return number of bytes in ping reply (#2973) 2018-08-17 11:53:54 -07:00
Jonathan Hui 920197398b [api] change type from uint8_t* to otExtendedPanId (#2960) 2018-08-15 10:12:49 -07:00
Jonathan Hui 9d585edc46 [types] move types into specific headers (#2946) 2018-08-08 11:19:41 -07:00
Jonathan Hui 7be61df6ec [message-info] remove unnecessary memset initialization (#2937) 2018-07-31 14:10:02 -05:00
Jonathan Hui 1075e35327 [code-style] remove multiple return statements per free function or method (#2891)
There should be one return statement per free function or method at the end
of the free function or method.
2018-07-19 20:09:07 -05:00
Shu Chen e69019f962 [time-sync] network-wide time synchronization service (#2618)
OpenThread network-wide time synchronization service is an experimental feature, not part of the standard Thread protocol.

Feature Overview:
 * All the nodes in the same Thread partition sync to the same Thread network-wide time;
 * Microsecond level time synchronization precision;
 * Flexible time accuracy and time sync period configuration;
 * APIs for application layer use case, support both CLI and NCP version.

The feature is wrapped by OPENTHREAD_CONFIG_ENABLE_TIME_SYNC, there's no change to current Thread 1.1
implementation if OPENTHREAD_CONFIG_ENABLE_TIME_SYNC is not enabled.

If OPENTHREAD_CONFIG_ENABLE_TIME_SYNC is enabled, the node could:
 * Attach to a time sync enabled network, otherwise
 * Attach to a standard Thread 1.1 network, otherwise
 * Form a new time sync enabled network

In addition, if OPENTHREAD_CONFIG_TIME_SYNC_REQUIRED is also enable, the node could only:
 * Attach to a time sync enabled network, otherwise
 * Form a new time sync enabled network

Note:
Currently, the feature is only supported on nRF52840 and posix platforms. And the network time
is only synced among Routers and REEDs, the SEDs will be supported later as an optional feature.
2018-06-26 13:46:32 -05:00
Yakun Xu 1b14a36a35 [posix] radio only host side driver (#2690) 2018-06-25 16:32:32 -07:00
Abtin Keshavarzian 9ce38e0161 [notifier] always signal changed state/config for the first time (#2818)
This commit adds new logic in `Notifier` class (and how it is used) to
ensure when state/configuration is changed, each of the OT_CHANGED_*
events (e.g., channel, network name) is signaled for the first time
(even in case new set value is same as before).

This change addresses an issue where if user sets a parameter (using
OpenThread public APIs) before starting Thread operation the event
indicating the change would not be emitted.

This commit also defines `otChangedFlags` and `Notifier::Flags`
types, and updates the logging in `Notifier` to use `String` class.
2018-06-22 15:09:18 -07:00
Łukasz Duda 90b66eb6de [cli] align autostart command (#2755) 2018-05-30 09:00:49 -07:00
Jonathan Hui 64fed1ed4d [cli] fix router table command (#2747) 2018-05-29 16:30:43 -07:00
Abtin Keshavarzian 2abd7a2822 [code-utils] adding helper macro OT_ARRAY_LENGTH() (#2743)
This commit adds helper macro `OT_ARRAY_LENGTH()` to get the number
of elements in an array.
2018-05-29 15:53:53 -07:00
Jonathan Hui aabd06ab51 [cli] fix child table command (#2749) 2018-05-29 10:01:16 -07:00
Shu Chen 449d3e7f11 [cli] return error if the command's argument is not supported (#2620) 2018-03-20 15:54:38 +00:00
Shu Chen 59e9aab082 [cli] get external route list in the local Network Data (#2619) 2018-03-16 18:41:39 +00:00
Jonathan Hui 12237d07dc [code-style] fix initializers in constructors 2018-02-09 21:43:42 +00:00