Skip to content

Commit

Permalink
examples/lte_lwm2mstub: Add a config switch of RAT change
Browse files Browse the repository at this point in the history
  • Loading branch information
SPRESENSE committed Dec 1, 2022
2 parents 239c9f7 + 3129099 commit b4d13d6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
6 changes: 6 additions & 0 deletions examples/lte_lwm2mstub/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ config EXAMPLES_LTE_LWM2MSTUB

if EXAMPLES_LTE_LWM2MSTUB

config EXAMPLES_LTE_LWM2MSTUB_SUPPORT_RATCHANGE
bool "Support RAT change to use lte_set_rat_sync()"
default n
---help---
Support RAT change by using lte_set_rat_sync() in this sample.

config EXAMPLES_LTE_LWM2MSTUB_PROGNAME
string "Program name"
default "lte_lwm2mstub"
Expand Down
2 changes: 2 additions & 0 deletions examples/lte_lwm2mstub/app_lte_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,9 @@ int connect_to_ltenetwork(struct app_parameter_s *param)

lte_set_report_localtime(localtime_cb);

#ifdef CONFIG_EXAMPLES_LTE_LWM2MSTUB_SUPPORT_RATCHANGE
lte_set_rat_sync(param->rat, LTE_DISABLE);
#endif

apnsetting.apn = param->apn_name;
apnsetting.apn_type = LTE_APN_TYPE_DEFAULT | LTE_APN_TYPE_IA;
Expand Down

0 comments on commit b4d13d6

Please sign in to comment.