net/asymcute : Add 'CONFIG_ASYMCUTE_DEFAULT_PORT'
examples/asymcute : Update macro definition Update macro definition for UDP port. Kconfig/asymcute : Add 'ASYMCUTE_DEFAULT_PORT'
This commit is contained in:
parent
2c7dfac7d1
commit
8f36c817eb
@ -257,7 +257,7 @@ static int _cmd_connect(int argc, char **argv)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
if (ep.port == 0) {
|
if (ep.port == 0) {
|
||||||
ep.port = MQTTSN_DEFAULT_PORT;
|
ep.port = CONFIG_ASYMCUTE_DEFAULT_PORT;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* get request context */
|
/* get request context */
|
||||||
|
|||||||
@ -63,6 +63,13 @@ extern "C" {
|
|||||||
* @ingroup config
|
* @ingroup config
|
||||||
* @{
|
* @{
|
||||||
*/
|
*/
|
||||||
|
/**
|
||||||
|
* @brief Default UDP port to listen on
|
||||||
|
*/
|
||||||
|
#ifndef CONFIG_ASYMCUTE_DEFAULT_PORT
|
||||||
|
#define CONFIG_ASYMCUTE_DEFAULT_PORT (1883U)
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Default buffer size for Asymcute client (as exponent of 2^n)
|
* @brief Default buffer size for Asymcute client (as exponent of 2^n)
|
||||||
*
|
*
|
||||||
|
|||||||
@ -16,6 +16,14 @@ menuconfig KCONFIG_USEMODULE_ASYMCUTE
|
|||||||
|
|
||||||
if KCONFIG_USEMODULE_ASYMCUTE
|
if KCONFIG_USEMODULE_ASYMCUTE
|
||||||
|
|
||||||
|
config ASYMCUTE_DEFAULT_PORT
|
||||||
|
int "Default UDP port to listen on"
|
||||||
|
default 1883
|
||||||
|
help
|
||||||
|
Default UDP port to listen on (also used as SRC port). This will write
|
||||||
|
to macro 'CONFIG_ASYMCUTE_DEFAULT_PORT'. Usage can be found in
|
||||||
|
examples/asymcute_mqttsn
|
||||||
|
|
||||||
config ASYMCUTE_BUFSIZE_EXP
|
config ASYMCUTE_BUFSIZE_EXP
|
||||||
int "Exponent for the buffer size (resulting in the buffer size 2^n)"
|
int "Exponent for the buffer size (resulting in the buffer size 2^n)"
|
||||||
default 7
|
default 7
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user