We have moved at community.getvera.com

Author Topic: 'Command failed: No implementation' on Virtual Device  (Read 8251 times)

Offline grybrd

  • Full Member
  • ***
  • Posts: 218
  • Karma: +0/-0
'Command failed: No implementation' on Virtual Device
« on: November 14, 2010, 04:12:18 pm »
Tried implementing a virtual device based on D_MotionSensor1.xml and get 'Command failed: No implementation' upon execution.   Any help on what this error is trying to tell me would be appreciated.

Thanks

Offline drytoast

  • Newbie
  • *
  • Posts: 16
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #1 on: November 15, 2010, 11:30:59 pm »
I think that means that you don't implement the action (in your actionList) for one of the defined interfaces in MotionSensor like SetArmed.   You get that error when it tries to call it by can't find a definition.

Offline grybrd

  • Full Member
  • ***
  • Posts: 218
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #2 on: November 16, 2010, 08:07:26 pm »
@drytoast ... Thanks for the feedback!!!   As a first time virtual device dabbler ... where is the "action list" ???

Offline drytoast

  • Newbie
  • *
  • Posts: 16
  • Karma: +0/-0

Offline grybrd

  • Full Member
  • ***
  • Posts: 218
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #4 on: November 17, 2010, 02:14:45 pm »
@drytoast ... thanks for the links.   I am not trying to write a plugin .. but trying to utilize one from the code page - D_MotionSensor1.xml.  I believe my problem is not knowing how much of the 'create device' tab needs to be filled in.  There is a forum entry (  http://forum.micasaverde.com/index.php?topic=2495.0 )  that implies one only has to fill in the UpnpDevFilename field with the appropriate .xml file. 

When I create the device I get a motion sensor with ARM and BYPASS functions but get the error when trying to set either button.

Thanks again for your help.

Offline drytoast

  • Newbie
  • *
  • Posts: 16
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #5 on: November 17, 2010, 03:45:40 pm »

That's the problem.   The D_ files are just interfaces.  They aren't attached to anything real so when you click ARM or BYPASS, it has nothing to send it to.  They have to have an implementation.  This can be from a plugin implementation (I_ files) or from implementation part of the core vera system (Z-Wave devices, Insteon devices, UIRT, etc)

Offline grybrd

  • Full Member
  • ***
  • Posts: 218
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #6 on: November 17, 2010, 04:12:42 pm »
@drytoast ... thanks for your patience and help.  If I plug in the "I" file in the 'Create Device' tab it gives me an "error: device not ready" when I try the buttons.   What I believe is needed is something in writing on how to use the MCV provided 'Create Device' tab.


Offline drytoast

  • Newbie
  • *
  • Posts: 16
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #7 on: November 17, 2010, 04:19:05 pm »
What is it that device is going to control?  Normally you use the Add Device button at the top of the UI4 page to add a device.  The create device tab/form is more for developers writing a plugin or a plugin that requests that you use that form (and specifies how to fill it in)

UpnpDevFilename is the device file (D_ files)

That file can sometimes specify an implementation file internally.  If not, then

UpnpImplFilename is the implementation of the above device (I_ files)

MotionSensor is the interface, where as a Z-Wave Motion Sensor or "MySpecialMotionSensor" are implementations.

Offline grybrd

  • Full Member
  • ***
  • Posts: 218
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #8 on: November 17, 2010, 04:30:09 pm »
K ... I am trying to implement a virtual device on UI3 to set a home/away flag and from reading the forum saw that using the sensor .xml would work.  I also thought tat one used the 'create device' tab to set up a virtual device. 

Thanks

Offline woodsby

  • Beta Testers
  • Sr. Member
  • *****
  • Posts: 466
  • Karma: +1/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #9 on: November 17, 2010, 04:46:36 pm »
@gry, you are on the right track, but you need to reference an I_* file in the advanced tab of the device you created under the "impl_file" field or in the D_ file using the <implementationFile> tag.  Unfortunately, I don't believe there are any good examples included in a stock vera, but you can probably find the ping sensor implementation file if you search these forums.
Vera1 (1.1142), Vera2 (1.1182), VRI06 (12), VRS15 (3), VRS05 (2), VRF01 (2), VRCS4 (2), ZRW113, ZRF113 (2), 45602, 45603, TZMT400 (2), FE599 (2), 99100, Thinkstick, Harmony 890Pro (2), Harmony RF Extender, Nevo S70, Nevo NC-50, Minimote, SQ Remote, SQ Blaster, EtherRain-8, Cliste ActiveRFID, TED5002

Offline drytoast

  • Newbie
  • *
  • Posts: 16
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #10 on: November 17, 2010, 05:00:25 pm »
Yes.  You'll need to create an implementation.  Something that has an actionList like:

Code: [Select]
<actionList>

  <action>
    <serviceId>urn:micasaverde-com:serviceId:SecuritySensor1</serviceId>
    <name>SetArmed</name>
    <run>
    luup.variable_set("urn:micasaverde-com:serviceId:SecuritySensor1", "Armed", lul_settings.newArmedValue, lul_device)
    return 4, 0
    </run>
  </action>

</actionList>


This tells the system what to do when the person requests that the device is "Armed" or "Bypassed".  

In this case, it simply sets the local value and that's it.  If it was a different kind of security sensor, it could perhaps send info to an Alarm panel instructing it to act but it looks like you just want a simple state variable.

Offline grybrd

  • Full Member
  • ***
  • Posts: 218
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #11 on: November 17, 2010, 10:02:07 pm »
@drytoast & woodsby ... thanks for the input.   Let me review what I think I have learned -

-  use 'create device' to establish a virtual device
-  use derivative of  D_MotionSensor1.xml in the d_ file entry -  this gives me the UI to see with the arm and bypass buttons.
-  need to write an I_ file that sets the flags I will test for away/home and link that to the I_ file entry.

Questions -

-  do I have to change pointers and rename D_MotionSensor1.xml so it works with new I_ file
-  how do I find D_MotionSensor1.xml code to change it
-  where do I stash the new D & I_ file code

Thanks again

Offline drytoast

  • Newbie
  • *
  • Posts: 16
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #12 on: November 18, 2010, 05:35:09 am »

If you want to keep "Arm" and "Bypass", you don't need to create a new D_ file.  You can use the standard motion/door/window sensor and get the standard UI.

All I've worked with is UI4 so someone may need to correct this for UI3 but:

1. Don't need to rename D_MotionSensor.xml, its a standard interface for all implementations

2. See 1 & 3.

3. In Mios Developers, I have a Luup Files tab where you can download the current files as well as upload new ones such as your implementation file.

So the short of it is:

a. create simple implementation file
b. upload it to the system
c. create your device with the D_MotionSensor.xml as the DevFilename and the uploaded implementation as the ImplFilename.


Offline jgou78

  • Newbie
  • *
  • Posts: 1
  • Karma: +0/-0
Re: 'Command failed: No implementation' on Virtual Device
« Reply #13 on: July 24, 2012, 03:37:55 pm »
Hello,

I am debutant. Or I can find the good file I_MotionSensor1.xml to put on my virtual module?
Thank you for your help