0

I am using Emqx V3.1.1. And I am integrating LwM2M plugins.

For testing the same I installed Wakaama client in the same server and created build using cmake. I loaded the plugin now plugin is running.

Which I tried to run the below command

./lwm2mclient -n ep1 -h localhost -p 5783 -4
Trying to bind LWM2M Client to port 56830
LWM2M Client "ep1" started on port 56830
> Opening connection to server at localhost:5783
 -> State: STATE_REGISTERING
 -> State: STATE_REGISTERING
 -> State: STATE_REGISTERING
 -> State: STATE_REGISTERING
 -> State: STATE_REGISTERING
 -> State: STATE_REGISTERING
 -> State: STATE_BOOTSTRAP_REQUIRED
lwm2m_step() failed: 0xA3

I have followed the below link

https://github.com/emqx/emqx-lwm2m

Roberto Caboni
  • 7,252
  • 10
  • 25
  • 39
pujara
  • 21
  • 1
  • 8

2 Answers2

1
  1. Change the port to 5683, which is the default port of lwm2m.

  2. Make sure allow_anonymous = true in the emqx.conf

Shawn
  • 21
  • 2
0

You need a bootstrap server, take a look at examples/bootstrap_server/ on eclipse/wakaama git repo.

JuanDeLosMuertos
  • 4,532
  • 15
  • 55
  • 87
  • I have Bootstrap server also in wakaama. below is the path /etc/wakaama-1.0/examples/bootstrap_server/ – pujara Jun 19 '19 at 12:30
  • Dumb question: is it running? – JuanDeLosMuertos Jun 19 '19 at 12:31
  • you mean The plugin port What i have configured with emqx right ? – pujara Jun 19 '19 at 12:44
  • lwm2m plugin port is 5683 is running – pujara Jun 19 '19 at 12:45
  • Nope, I mean the bootstrap_server. You need it and lwm2mserver to be up and running, otherwise your client cannot be configured and you get the STATE_BOOTSTRAP_REQUIRED error. – JuanDeLosMuertos Jun 19 '19 at 12:47
  • your correct I tried below command ./lwm2mclient -n ep1 -h leshan.eclipseprojects.io -p 5683 -4 it is working But when i give localhost only it is not working. Here my doubt is how can i start bootstarap server – pujara Jun 19 '19 at 12:54
  • Now I am able to connect to my localhost. I am trying to test with different Msg types likes read discover write execute and delete. read and discover are working . for write and remaining msg types I need below parameters. (Value type, period min,period max,step,greaterThan, lessThan,Arguments). – pujara Jun 20 '19 at 09:28
  • Well, you can ask another question about that (it is no longer related to this question). Remember to upvote useful answers and mark the questions as resolved. Thank you. – JuanDeLosMuertos Jun 20 '19 at 09:32
  • Bootstrap server is not mandatory in case you start in factory bootstrapped mode. – Roberto Caboni Nov 06 '19 at 15:38