Creating Device Type Updates Status From XML

I have thoroughly confused myself on this and need a little straightening out.

I am attempting to create a new device type that talks with the Autelis.

Referencing this post on the Autelis forum as a starting point.

Using the URI handler, I can successfully turn things on/off with smartthings, however if I do so outside of smartthings then the status is out of sync.

Through the autelis system I can pull a status.xml from ip.address/status.xml


Where I am stuck - I guess I am barking up the wrong tree with creating a device type? Should I be making a service manager? In which the service manager parses the status of the switch? EX circuit5?

Pointing me at something I could reference would also be greatly appreciated.


I am doing a similar job with a parallel structure. See

I am going out for a while. But I can help later this afternoon (after 3PM Texas, USA time).


OK, had some time. I hope this helps (I think you are asking how to receive and parse XML returns).

I have a command similar to the below:

Def GetRadioInfo () {

Sent via the command sendCmd:

private sendCmd(command){
	def cmdStr = new physicalgraph.device.HubAction([
		method: "GET",
		path: command,
		headers: [
			HOST: "${deviceIP}:55001",
		[callback: parseResponse]

The raw output is:

<?xml version="1.0" encoding="UTF-8">
	<response result="ok">
		<title>Country Hits (Americana and Alt. Country)</title>
		<description>Little Big Town - Tornado</description>

The parse method looks like the below (shortened)

void parseResponse(resp) {
	def respMethod = (new XmlSlurper().parseText(resp.body)).method
	def respData = (new XmlSlurper().parseText(resp.body)).response

Some variables:

def title = respData.title
def mediaid = respData.mediaid
def description = respData.description

Key is the “new XMSlurper()” That really makes the string sing.

Hope this is what you are looking for.

I also have an autelis controller and I am looking to do the same things. Any luck with this with project? If so, would you mind sharing what you did?


Unfortunately I havent had enough time to really mess with it.

However, I didnt really make a ton of progress.

Basically I kept running into the same issue which was how to get smartthings to poll/get the status of a given switch by looking at a given xml file at a given IP address.

My confusion kept stemming from my understanding or lack there of - of the structure/hierarchy of how smartthings handles things. Hence my note above about am I creating a device type or a service manager?

I looked for something that was simple that I could reference that would be atleast a starting point and I remember finding a sprinkler controller or something that I thought I would be able to use. However I didnt bookmark it and couldnt find it again.

Im definitely willing to work together to get everything up and running and making things public, but I lost myself in confusion lol.

Check this out somebody might have beat you to it. I tried to get it running yesterday but I ran into a few problems. Post your results on this thread.