[joiner] check Thread state on start (#5173)

This commit is contained in:
Yakun Xu
2020-07-04 00:24:52 +08:00
committed by GitHub
parent 2a05a4c5f2
commit 74fd255465
4 changed files with 9 additions and 3 deletions
+1 -1
View File
@@ -53,7 +53,7 @@ extern "C" {
* @note This number versions both OpenThread platform and user APIs.
*
*/
#define OPENTHREAD_API_VERSION (11)
#define OPENTHREAD_API_VERSION (12)
/**
* @addtogroup api-instance
+3 -1
View File
@@ -106,8 +106,10 @@ typedef void (*otJoinerCallback)(otError aError, void *aContext);
* @param[in] aCallback A pointer to a function that is called when the join operation completes.
* @param[in] aContext A pointer to application-specific context.
*
* @retval OT_ERROR_NONE Successfully started the Commissioner role.
* @retval OT_ERROR_NONE Successfully started the Joiner role.
* @retval OT_ERROR_BUSY The previous attempt is still on-going.
* @retval OT_ERROR_INVALID_ARGS @p aPskd or @p aProvisioningUrl is invalid.
* @retval OT_ERROR_INVALID_STATE The IPv6 stack is not enabled or Thread stack is fully enabled.
*
*/
otError otJoinerStart(otInstance * aInstance,