FOR TIPS, gUIDES & TUTORIALS

subscribe to our Youtube

GO TO YOUTUBE

14455 questions

17168 answers

28195 comments

0 members

We are migrating to our new platform at https://community.teltonika.lt. Moving forward, you can continue discussions on this new platform. This current platform will be temporarily maintained for reference purposes.
0 votes
106 views 0 comments
by anonymous

Hi,

when i use this command "ubus call ioman.dwi.dwi1 status" I get



{

"state": "dry",

"value": "0",

"invert_input": true

}

what if I just want to read the "value" parameter only, how to do it in script or code, something like "ubus call ioman.dwi.dwi1 status[1]" or "status/value" for example.

thanks,

1 Answer

0 votes
by anonymous

Hello,

Install jq: 

opkg update; opkg install jq
ubus call ioman.dwi.dwi1 status | jq .value

Regards,