EasyCwmp - easycwmp
View Issue Details
0000005easycwmp[All Projects] Helppublic2014-08-05 08:272014-08-05 16:13
dengwork 
mohamed.kallel 
normalminorN/A
resolvedfixed 
0000005: where is the file of data model ?
i can run the process, but i can not find the data model, who can tell me ? thanks !
No tags attached.
Issue History
2014-08-05 08:27dengworkNew Issue
2014-08-05 09:26mohamed.kallelNote Added: 0000024
2014-08-05 09:26mohamed.kallelNote Edited: 0000024bug_revision_view_page.php?bugnote_id=24#r27
2014-08-05 09:26mohamed.kallelNote Edited: 0000024bug_revision_view_page.php?bugnote_id=24#r28
2014-08-05 09:28mohamed.kallelNote Edited: 0000024bug_revision_view_page.php?bugnote_id=24#r29
2014-08-05 09:29mohamed.kallelNote Edited: 0000024bug_revision_view_page.php?bugnote_id=24#r30
2014-08-05 09:29mohamed.kallelNote Edited: 0000024bug_revision_view_page.php?bugnote_id=24#r31
2014-08-05 10:08dengworkNote Added: 0000025
2014-08-05 10:09dengworkNote Added: 0000026
2014-08-05 11:27mohamed.kallelNote Added: 0000027
2014-08-05 11:30dengworkNote Added: 0000028
2014-08-05 11:32mohamed.kallelAssigned To => mohamed.kallel
2014-08-05 11:32mohamed.kallelStatusnew => assigned
2014-08-05 11:32mohamed.kallelStatusassigned => resolved
2014-08-05 11:32mohamed.kallelResolutionopen => fixed
2014-08-05 16:13mohamed.kallelNote Edited: 0000027bug_revision_view_page.php?bugnote_id=27#r35

Notes
(0000024)
mohamed.kallel   
2014-08-05 09:26   
(edited on: 2014-08-05 09:29)
- In the source code, the data model scripts are under ext/openwrt/scripts
- In your device, the data model scripts are installed under:
   * /usr/share/easycwmp/functions
   * /usr/sbin/easycwmp

to check if your data model script is running well, execute the following command under your equipment:

sudo easycwmp --json get name "" 0


you should get an output like this:

{ "parameter": "InternetGatewayDevice.DeviceInfo.Manufacturer", "fault_code": "", "value": "easycwmp", "type": "xsd:string" }
{ "parameter": "InternetGatewayDevice.DeviceInfo.ManufacturerOUI", "fault_code": "", "value": "FFFFFF", "type": "xsd:string" }
{ "parameter": "InternetGatewayDevice.DeviceInfo.ProductClass", "fault_code": "", "value": "easycwmp", "type": "xsd:string" }
{ "parameter": "InternetGatewayDevice.DeviceInfo.SerialNumber", "fault_code": "", "value": "FFFFFF123456", "type": "xsd:string" }
{ "parameter": "InternetGatewayDevice.DeviceInfo.HardwareVersion", "fault_code": "", "value": "ex_hw_version", "type": "xsd:string" }
{ "parameter": "InternetGatewayDevice.DeviceInfo.SoftwareVersion", "fault_code": "", "value": "ex_sw_version", "type": "xsd:string" }
{ "parameter": "InternetGatewayDevice.DeviceInfo.UpTime", "fault_code": "", "value": "429120", "type": "xsd:string" }
...

(0000025)
dengwork   
2014-08-05 10:08   
yes , i can get it .you mean there is no xml data model ?
(0000026)
dengwork   
2014-08-05 10:09   
so ,how to edit data model ?
(0000027)
mohamed.kallel   
2014-08-05 11:27   
(edited on: 2014-08-05 16:13)
NO, there is no xml data model.

You can get all the data model parameters with the command

sudo easycwmp --json get name "" 0

The data model will be displayed as json messages.

To add a new parameters, you have to edit the data model scripts. you can follow the example of the already implmented parameters. You have to read the scripts carefully and then add your parameters by following the same way of the already implmented parameters.

(0000028)
dengwork   
2014-08-05 11:30   
ok. i see, thanks