Rainforest Eagle 200

Posted on
Thu Aug 27, 2020 12:25 pm
pasosteve offline
Posts: 11
Joined: Aug 04, 2016

Rainforest Eagle 200

I have an eagle200 that communicates to my power meter giving me real time updates. The only information I am interested in is the line that has <Value> then the number

They have a local API, when I post with json the only message I get back is: GhostXML Debug ReturnCode: 0

Any ideas? I use ghost xml for another api and it works as expected.

Thanks, Steve

When I use curl I get the below:

<Device>
<DeviceDetails>
<Name>Power Meter</Name>
<HardwareAddress>0x00135001014f2ede</HardwareAddress>
<NetworkInterface>0xd8d5b9000000fdaa</NetworkInterface>
<Protocol>Zigbee</Protocol>
<NetworkAddress>0x0000</NetworkAddress>
<Manufacturer>Generic</Manufacturer>
<ModelId>electric_meter</ModelId>
<LastContact>0x5f473831</LastContact>
<ConnectionStatus>Connected</ConnectionStatus>
</DeviceDetails>
<Components>
<Component>
<FixedId>0</FixedId>
<Name>Main</Name>
<DeviceClass>0x00000000</DeviceClass>
<EventPriority>0</EventPriority>
<ZigbeeProfile>0xffff</ZigbeeProfile>
<Variables>
<Variable>
<Name>zigbee:InstantaneousDemand</Name>
<Value>1.093000</Value>
<Units>kW</Units>
<Description>Instantaneous Demand</Description>
</Variable>
</Variables>
</Component>
</Components>
</Device>

Posted on
Thu Aug 27, 2020 12:33 pm
DaveL17 offline
User avatar
Posts: 5568
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Rainforest Eagle 200

Sorry to hear that you're having trouble. What you've posted looks like XML and not JSON. Have you tried with XML selected?

Do you need to enter credentials to get the data?

Any information you can provide will help diagnose the problem.

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Sun Aug 30, 2020 5:19 pm
pasosteve offline
Posts: 11
Joined: Aug 04, 2016

Re: Rainforest Eagle 200

Yes I need credentials, this portion seems to work just fine. If I change from json to xml I get the error at the bottom of this message.

If I use curl with the .json file I have back the post request comes back just fine.

Thanks, Steve

GhostXML Debug Stopped: [ 1581825928]
GhostXML Debug Started: [ 1581825928] <Thread(1581825928, started 123145546084352)> <Queue.Queue instance at 0x109262488>
GhostXML Debug [1581825928] URL: file:///Users/Steven/bin/eagle.json (before substitution)
GhostXML Debug [1581825928] URL: file:///Users/Steven/bin/eagle.json (after substitution)
GhostXML Debug HTTPS CURL result: * Closing connection 0

GhostXML Debug ReturnCode: 0
Error device "Z eagle" state key info__postman_id not defined (ignoring update request)
Error device "Z eagle" state key info_name not defined (ignoring update request)
Error device "Z eagle" state key info_schema not defined (ignoring update request)
Error device "Z eagle" state key item_0_name not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_auth_basic_0_key not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_auth_basic_0_type not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_auth_basic_0_value not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_auth_basic_1_key not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_auth_basic_1_type not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_auth_basic_1_value not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_auth_type not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_body_mode not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_body_raw not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_description not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_header not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_method not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_url_host_0 not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_url_host_1 not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_url_host_2 not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_url_host_3 not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_url_path_0 not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_url_path_1 not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_url_protocol not defined (ignoring update request)
Error device "Z eagle" state key item_0_request_url_raw not defined (ignoring update request)
Error device "Z eagle" state key item_0_response not defined (ignoring update request)
Error device "Z eagle" state key protocolProfileBehavior not defined (ignoring update request)

Posted on
Sun Aug 30, 2020 6:07 pm
DaveL17 offline
User avatar
Posts: 5568
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Rainforest Eagle 200

Unfortunately, there's not enough here to go on. I will need to see all the Indigo debug log messages and all of the private plugin debug log messages (located in the plugin log folder). I'll also need to see how you've set up the GhostXML device settings for this data source. If there's anything about the settings that you don't feel comfortable sharing on the forums, feel free to DM me.

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Mon Aug 31, 2020 2:59 pm
pasosteve offline
Posts: 11
Joined: Aug 04, 2016

Re: Rainforest Eagle 200

Results from log file. Basic Authentication is enabled.

2020-08-31 13:51:25.587 DEBUG Plugin.get_the_data [1581825928] URL: file:///Users/Steven/bin/eagle.json (before substitution)
2020-08-31 13:51:25.588 DEBUG Plugin.get_the_data [1581825928] URL: file:///Users/Steven/bin/eagle.json (after substitution)
2020-08-31 13:51:25.603 DEBUG Plugin.get_the_data HTTPS CURL result: * Closing connection 0

Running using eagle.json with curl:
curl --user "00aaea:b399e8219675e337" -d "@eagle.json" -X POST http://192.168.1.211/cgi-bin/post_manager
<Device>
<DeviceDetails>
<Name>Power Meter</Name>
<HardwareAddress>0x00135001014f2ede</HardwareAddress>
<NetworkInterface>0xd8d5b9000000fdaa</NetworkInterface>
<Protocol>Zigbee</Protocol>
<NetworkAddress>0x0000</NetworkAddress>
<Manufacturer>Generic</Manufacturer>
<ModelId>electric_meter</ModelId>
<LastContact>0x5f4d645a</LastContact>
<ConnectionStatus>Connected</ConnectionStatus>
</DeviceDetails>
<Components>
<Component>
<FixedId>0</FixedId>
<Name>Main</Name>
<DeviceClass>0x00000000</DeviceClass>
<EventPriority>0</EventPriority>
<ZigbeeProfile>0xffff</ZigbeeProfile>
<Variables>
<Variable>
<Name>zigbee:InstantaneousDemand</Name>
<Value>-1.267000</Value>
<Units>kW</Units>
<Description>Instantaneous Demand</Description>
</Variable>
</Variables>
</Component>
</Components>
</Device>



Contents of the file eagle.json:

{
"info": {
"_postman_id": "4d9e05b2-6113-478f-9933-365b8a56305c",
"name": "eagle",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
},
"item": [
{
"name": "http://192.168.1.211/cgi-bin/post_manager",
"request": {
"auth": {
"type": "basic",
"basic": [
{
"key": "password",
"value": "b399e8219675e337",
"type": "string"
},
{
"key": "username",
"value": "00aaea",
"type": "string"
}
]
},
"method": "POST",
"header": [],
"body": {
"mode": "raw",
"raw": "<Command>\n <Name>device_query</Name>\n <DeviceDetails>\n<HardwareAddress>0x00135001014f2ede</HardwareAddress> </DeviceDetails>\n <Components>\n <Component>\n <Name>Main</Name>\n <Variables>\n<Variable> <Name>zigbee:InstantaneousDemand</Name>\n </Variable>\n </Variables>\n </Component>\n </Components>\n</Command>"
},
"url": {
"raw": "http://192.168.1.211/cgi-bin/post_manager",
"protocol": "http",
"host": [
"192",
"168",
"1",
"211"
],
"path": [
"cgi-bin",
"post_manager"
]
},
"description": "pull power usage from eagle "
},
"response": []
}
],
"protocolProfileBehavior": {}
}%

Posted on
Mon Aug 31, 2020 4:55 pm
DaveL17 offline
User avatar
Posts: 5568
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Rainforest Eagle 200

I must admit that I'm completely confused as to why calling eagle.json with curl is returning XML.

Running using eagle.json with curl:
curl --user "00aaea:b399e8219675e337" -d "@eagle.json" -X POST http://192.168.1.211/cgi-bin/post_manager
<Device>
<DeviceDetails>
<Name>Power Meter</Name>
<HardwareAddress>0x00135001014f2ede</HardwareAddress>
<NetworkInterface>0xd8d5b9000000fdaa</NetworkInterface>
<Protocol>Zigbee</Protocol>
<NetworkAddress>0x0000</NetworkAddress>
<Manufacturer>Generic</Manufacturer>
<ModelId>electric_meter</ModelId>
<LastContact>0x5f4d645a</LastContact>
<ConnectionStatus>Connected</ConnectionStatus>
</DeviceDetails>
<Components>
<Component>
<FixedId>0</FixedId>
<Name>Main</Name>
<DeviceClass>0x00000000</DeviceClass>
<EventPriority>0</EventPriority>
<ZigbeeProfile>0xffff</ZigbeeProfile>
<Variables>
<Variable>
<Name>zigbee:InstantaneousDemand</Name>
<Value>-1.267000</Value>
<Units>kW</Units>
<Description>Instantaneous Demand</Description>
</Variable>
</Variables>
</Component>
</Components>
</Device>


How are you accessing the eagle.json file that you included above?

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Tue Sep 01, 2020 4:14 pm
pasosteve offline
Posts: 11
Joined: Aug 04, 2016

Re: Rainforest Eagle 200

Within the device I created I specify the file location.

Steve

Posted on
Tue Sep 01, 2020 5:30 pm
DaveL17 offline
User avatar
Posts: 5568
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Rainforest Eagle 200

Sorry, I should have been more clear. How did you get ahold of the json output you copied and posted above?

I'm sorry to say that I'm thoroughly confused as it appears from the above that you used curl to access the eagle.json source and it returned XML (and not JSON). You said that you were interested in the <VALUE> field from the XML you posted, but the JSON output doesn't appear to have that data within it. Something doesn't add up and I'm not sure where to look.

Typically, the errors that folks encounter result from a character that's allowable in JSON or XML tags that isn't allowable in Indigo dictionary keys. We can easily correct for that once we know what to look for. But that doesn't seem to be the case here.

One thing you can try is to completely delete your device and start over. Using the same credentials and source location you posted above, set the device to XML and not JSON. The act of recreating the device may clear out prior data that's causing heartburn.

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 1 guest