Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [wakaama-dev] lwm2m watcher list

Hi,

I made the attached diagram a while ago. It may help to get a clearer picture.

Regards,
David Navarro

-----Original Message-----
From: wakaama-dev-bounces@xxxxxxxxxxx [mailto:wakaama-dev-bounces@xxxxxxxxxxx] On Behalf Of Frank Gerlach
Sent: Wednesday, 11 May, 2016 09:57
To: wakaama-dev@xxxxxxxxxxx
Subject: Re: [wakaama-dev] lwm2m watcher list

Good Morning Rajesh,
the structure you cite is "being pointed at" by another structure, which has the URI:


typedef struct _lwm2m_observed_
{
    struct _lwm2m_observed_ * next;

    lwm2m_uri_t uri;
    lwm2m_watcher_t * watcherList;
} lwm2m_observed_t;

Also have a look at all functions operating on the data structures you want to understand. E.g.

prv_findObserved()

prv_findWatcher()

In general, it takes some time to get accustomed to liblwm2m internals...

Maybe you better ask the list what your "high level objectives" are. Maybe there is a better solution to your goals than looking at the internals in the way you currently do :-)

Kind regards

Frank Gerlach


If you want to understand the data structures I suggest you draw up a diagram by pencil or using some sort of visualization tool.

Also, have a look at the 

Message: 4
Date: Tue, 10 May 2016 17:12:15 +0530
From: "RAJESH KUMAR S.R" <rajuuu1992@xxxxxxxxx>
To: wakaama-dev@xxxxxxxxxxx
Subject: [wakaama-dev] lwm2m watcher list
Message-ID:
	<CAC-BHbV-sHuMBoENu3Y0Dfmsn4+XZWRrRCbURqkEVzg4_1LJag@xxxxxxxxxxxxxx>
Content-Type: text/plain; charset="utf-8"

Hi,

I need a small clarification in wakaama code.

LWM2M observed resources are maintained by lwm2m_watcher_t structure.


typedef struct _lwm2m_watcher_
{
    struct _lwm2m_watcher_ * next;

    bool active;
    bool update;
    lwm2m_server_t * server;
    lwm2m_attributes_t * parameters;
    uint8_t token[8];
    size_t tokenLen;
    time_t lastTime;
    uint32_t counter;
    uint16_t lastMid;
    union
    {
        int64_t asInteger;
        double  asFloat;
    } lastValue;
} lwm2m_watcher_t;

There is no member denoting the URI of resource which is to be observed.
And also, can you help me understand why "parameters" member used for.
Is it like a rule engine. For eg:  if the value is "greaterThan" a threshold, notify the server.

Thanks,
Rajesh kumar S R
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://dev.eclipse.org/mailman/private/wakaama-dev/attachments/20160510/6126c244/attachment.html>

------------------------------

_______________________________________________
wakaama-dev mailing list
wakaama-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/wakaama-dev

End of wakaama-dev Digest, Vol 22, Issue 2
******************************************
_______________________________________________
wakaama-dev mailing list
wakaama-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/wakaama-dev
---------------------------------------------------------------------
Intel Corporation SAS (French simplified joint stock company)
Registered headquarters: "Les Montalets"- 2, rue de Paris, 
92196 Meudon Cedex, France
Registration Number:  302 456 199 R.C.S. NANTERRE
Capital: 4,572,000 Euros

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.

Attachment: wakaama_internals_clt.jpg
Description: wakaama_internals_clt.jpg


Back to the top