<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[DIY Blind Control Motor]]></title><description><![CDATA[<p dir="auto">I'm looking to control my vertical blinds using a stepper motor, an arduino, and the mysensors system. Essentially, all I want the system to do is to run the stepper motor in FWD or REV direction for X amount of time (X amount of revolutions is preferred but I don't know if steppers can do this) and control it using Vera.</p>
<p dir="auto">Is this doable? It seems pretty simple but I hope I'm not overlooking anything</p>
]]></description><link>https://forum.mysensors.org/topic/157/diy-blind-control-motor</link><generator>RSS for Node</generator><lastBuildDate>Wed, 12 Aug 2026 20:47:28 GMT</lastBuildDate><atom:link href="https://forum.mysensors.org/topic/157.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 04 Jun 2014 17:11:27 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to DIY Blind Control Motor on Wed, 22 Mar 2017 20:04:24 GMT]]></title><description><![CDATA[<p dir="auto">Yep, both were 3D printed back then. The Toronto library actually has 3D printers so I built a CAD model and had it printed there. There are also have a lot of web-based companies who will print and ship out parts.</p>
<p dir="auto">Since then I've built my own 3D printer, it comes in handy and they're getting pretty cheap.</p>
]]></description><link>https://forum.mysensors.org/post/63119</link><guid isPermaLink="true">https://forum.mysensors.org/post/63119</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Wed, 22 Mar 2017 20:04:24 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Wed, 22 Mar 2017 17:46:33 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a> said in <a href="/post/4354">DIY Blind Control Motor</a>:</p>
<blockquote>
<p dir="auto">Finally finished my setup, here is a picture. Works pretty well, it is slightly louder than I would have hoped but if you run it at 1/16th microsteps its almost silent. The only issue is that it won't run very fast at 1/16 microsteps.<img src="/uploads/upload-8df8ea88-7497-4650-87e6-a7b5897c8146.jpg" alt="IMG_1795-2.jpg" class=" img-fluid img-markdown" /></p>
</blockquote>
<p dir="auto">Sorry, I know this topic is quite old, but where did you get that wheel (that translates motor force to the chain)? I was thinking about building something similar and thats my main problem.</p>
<p dir="auto">Looks 3D printed as well as the holder (I really have to get a 3D printer ;) )..</p>
]]></description><link>https://forum.mysensors.org/post/63091</link><guid isPermaLink="true">https://forum.mysensors.org/post/63091</guid><dc:creator><![CDATA[LastSamurai]]></dc:creator><pubDate>Wed, 22 Mar 2017 17:46:33 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Tue, 21 Jul 2015 09:24:32 GMT]]></title><description><![CDATA[<p dir="auto">Old thread, but is it possible to clean up enough to make a tutorial on this? All the info is quite confusing to a person who's not as good as you guys :-)<br />
Is it also possible to adapt this method into making a door lock?</p>
]]></description><link>https://forum.mysensors.org/post/17360</link><guid isPermaLink="true">https://forum.mysensors.org/post/17360</guid><dc:creator><![CDATA[Øyvind A. Espnes]]></dc:creator><pubDate>Tue, 21 Jul 2015 09:24:32 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Fri, 17 Oct 2014 14:05:05 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/korttoma" aria-label="Profile: korttoma">@<bdi>korttoma</bdi></a> said:</p>
<blockquote>
<p dir="auto">Ahh, I see. Maybe it is an option for you to add another (dummy) device of some type just to get more variables.</p>
</blockquote>
<p dir="auto">That's actually not a bad idea. Seems like a pretty simple solution. Thanks!</p>
]]></description><link>https://forum.mysensors.org/post/5696</link><guid isPermaLink="true">https://forum.mysensors.org/post/5696</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Fri, 17 Oct 2014 14:05:05 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Fri, 17 Oct 2014 04:05:58 GMT]]></title><description><![CDATA[<p dir="auto">Ahh, I see. Maybe it is an option for you to add another (dummy) device of some type just to get more variables.</p>
]]></description><link>https://forum.mysensors.org/post/5686</link><guid isPermaLink="true">https://forum.mysensors.org/post/5686</guid><dc:creator><![CDATA[korttoma]]></dc:creator><pubDate>Fri, 17 Oct 2014 04:05:58 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Thu, 16 Oct 2014 17:05:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/korttoma" aria-label="Profile: korttoma">@<bdi>korttoma</bdi></a> said:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a> said:</p>
<blockquote>
<p dir="auto">I'm moving on to add another stepper and I need a few more custom variables (4) - is there any way to add new variables? Or is he maximum 5?</p>
</blockquote>
<p dir="auto">If you add another stepper to a node you will add another window cover device in Vera right? So shouldn't there be 5 more Variables for this new device right?</p>
</blockquote>
<p dir="auto">I wasn't planning on adding another device. I was planning on implementing the UP/DOWN functionality to control the sliding of the vertical blinds. While the V_DIMMER slider would control the 'tilt'</p>
]]></description><link>https://forum.mysensors.org/post/5673</link><guid isPermaLink="true">https://forum.mysensors.org/post/5673</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Thu, 16 Oct 2014 17:05:15 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Tue, 14 Oct 2014 08:49:34 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a> said:</p>
<blockquote>
<p dir="auto">I'm moving on to add another stepper and I need a few more custom variables (4) - is there any way to add new variables? Or is he maximum 5?</p>
</blockquote>
<p dir="auto">If you add another stepper to a node you will add another window cover device in Vera right? So shouldn't there be 5 more Variables for this new device right?</p>
]]></description><link>https://forum.mysensors.org/post/5590</link><guid isPermaLink="true">https://forum.mysensors.org/post/5590</guid><dc:creator><![CDATA[korttoma]]></dc:creator><pubDate>Tue, 14 Oct 2014 08:49:34 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Wed, 08 Oct 2014 01:27:54 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/hek" aria-label="Profile: hek">@<bdi>hek</bdi></a> said:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a></p>
<p dir="auto">Yes, it is possible! You have a couple of options.</p>
<p dir="auto">##Poll configuration data from node</p>
<ul>
<li>Select one of V_VAR1, V_VAR2, V_VAR3, V_VAR4, V_VAR5 to use for your configuration;<br />
choose from your root or child nodes. You can use all five parameters per each of your root and child device. It is up to you how to design this;</li>
<li>Program your sketch to fetch variable from vera using <strong>gw.request()</strong>. You will have to take care to get reply later by yourself using in your callback method initialized in <strong>gw.setup()</strong>. See RelayActuator sketch for an example on how to handle incoming messages.</li>
<li>First run of your modified sketch to request parameters. Be prepared that you will receive an empty string because at this time we have just created empty variables at vera side;</li>
<li>Refresh your vera and go to particular child into Advanced Tab. You should be able to see your new variables named Variable1...Variable5. Variable1 corresponds to V_VAR1 inside your sketch etc.;<br />
fill free to change empty field on vera side to the value your needed, Save changes; <img src="/uploads/upload-4f4a269a-3d9c-4939-998a-5b6b07654aaa.jpg" alt="forcase1.jpg" class=" img-fluid img-markdown" /></li>
<li>Check with you Arduino, it should receive correct data at this point;</li>
<li>You free to use whatever design you want. You can pull/request data at each start of you node or you can pull each 30 minutes like many z-wave devices do if they operate from battery. Other example can be if you need for your to nodes to communicate to each other and you need to tell a radio ID to one/both nodes to establish their communication. But for this one you probably want to use Push...</li>
</ul>
<p dir="auto">##Push configuration data from Vera to node</p>
<p dir="auto">Example: You need to push data from vera on event or using schedule and it should be initiated instantly by vera, not by node. For example you want your clock to show external temperature received by vera from the Weather plugin or from other sensor.</p>
<p dir="auto"><img src="/uploads/upload-3e94f98e-37ac-466a-81a3-1f2f843c1e1f.JPG" alt="forcase2.JPG" class=" img-fluid img-markdown" /></p>
<ul>
<li>
<p dir="auto">Choose from V_VAR1, V_VAR2, V_VAR3, V_VAR4, V_VAR5 to be used for data push</p>
</li>
<li>
<p dir="auto">Design your sketch to listen for incoming messages with desired variable. See RelayActuator for an example on how to handle incoming data.</p>
</li>
<li>
<p dir="auto">Create a new scene on vera side. The scene should be run according to your goal. For example  each 10 minutes;</p>
</li>
<li>
<p dir="auto">Use Lua tab while editing scene to provide data for the push. For example this Lua is taking current temperature from Weather (vera id = 61) plugin and pushing it to the node (vera id for root device = 372) using VAR_5:</p>
<p dir="auto">local temp = luup.variable_get("urn:upnp-org:serviceId:TemperatureSensor1","CurrentTemperature", 61)<br />
temp = temp*10.0<br />
luup.call_action("urn:upnp-arduino-cc:serviceId:arduino1", "SendCommand", {radioId="4;255", variableId="VAR_5", value=temp}, 372)</p>
</li>
</ul>
<p dir="auto">SendCommand will push a message to your node. You can also call it with static values (without programming) using the Advanced tab in the scene editor.</p>
<p dir="auto">(This post was updated to 1.4 from from <a class="plugin-mentions-user plugin-mentions-a" href="/user/axillent" aria-label="Profile: axillent">@<bdi>axillent</bdi></a> old <a href="http://code.mios.com/trac/mios_arduino-sensor/wiki/TipsAndTricks" rel="nofollow ugc">tips page on micasaverde</a>)</p>
</blockquote>
<p dir="auto">I'm moving on to add another stepper and I need a few more custom variables (4) - is there any way to add new variables? Or is he maximum 5?</p>
]]></description><link>https://forum.mysensors.org/post/5373</link><guid isPermaLink="true">https://forum.mysensors.org/post/5373</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Wed, 08 Oct 2014 01:27:54 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Sun, 28 Sep 2014 00:27:18 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/korttoma" aria-label="Profile: korttoma">@<bdi>korttoma</bdi></a></p>
<p dir="auto">I don't know what I was doing wrong before, but I got the non-block run feature working with your code. I have my blinds controlled by XBMC as well, so if I start and stop a movie in quick succession, I want to make sure the blinds end up in the right spot. I've attached the relevant snippets of code below</p>
<pre><code>void loop(){

 if (gw.messageAvailable()) {
  //Serial.print("New message from GW"); 
  // ot new messsage from gw
  message_s message = gw.getMessage(); 
  setRelayStatus(message);
}

stepper1.run();
}
</code></pre>
<p dir="auto">and then when you get the message:</p>
<pre><code>if (message.header.type==V_DIMMER) { // 
     float IncomingControl = atoi(message.data);
 //Serial.print("Message: ");
 //Serial.println(IncomingControl);
 //Serial.println((100-IncomingControl)/100*-1*fullOpenSteps);
 delay(5);
 
 
 float incomingNewPosition = (100-IncomingControl)/100*-1*fullOpenSteps;

 stepper1.stop();
 stepper1.runToPosition();
 
 stepper1.moveTo(incomingNewPosition);
 
 
 int IncomingControlSend = IncomingControl;
 gw.sendVariable(CHILD_ID, V_DIMMER, IncomingControlSend);  
  
}
</code></pre>
]]></description><link>https://forum.mysensors.org/post/5050</link><guid isPermaLink="true">https://forum.mysensors.org/post/5050</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Sun, 28 Sep 2014 00:27:18 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Mon, 28 May 2018 11:45:43 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a></p>
<p dir="auto">Sorry, I have not experimented with other functions than the once I have in my current sketch since it is working according to my needs except for the problem with position updates to Vera I'm having.<br />
I guess some people would like it if it was possible to use up/down/stop if it is possible with the run() function but I have schedules running my blinds 95% of the time.<br />
I managed to workaround the position updates to vera problem by using the up/down instead of open/close, I will look in to it when I find some time and then I could check out the run() function too.</p>
]]></description><link>https://forum.mysensors.org/post/4851</link><guid isPermaLink="true">https://forum.mysensors.org/post/4851</guid><dc:creator><![CDATA[korttoma]]></dc:creator><pubDate>Mon, 28 May 2018 11:45:43 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Sun, 21 Sep 2014 05:26:22 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/korttoma" aria-label="Profile: korttoma">@<bdi>korttoma</bdi></a> , did you ever try using the accelstepper run() command instead of runToPosition(). From my understanding the run() command is non-blocking and you put it in your main-loop. That way, if Vera sends a new commands you can set it to stop immediately using:</p>
<pre><code>stop();
runToPosition();
</code></pre>
<p dir="auto">I gave it a shot and the motor didn't seem to move at all - I'm not sure if you ever experimented with it, thought I'd ask.</p>
]]></description><link>https://forum.mysensors.org/post/4829</link><guid isPermaLink="true">https://forum.mysensors.org/post/4829</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Sun, 21 Sep 2014 05:26:22 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Wed, 10 Sep 2014 01:46:20 GMT]]></title><description><![CDATA[<p dir="auto">For the next part of my project I'm looking to have two interlocking gears which grab and pull the string in order to slide the vines of the blinds to one side.</p>
<p dir="auto">I can attach one gear to the servo, but the other gear would require some sort of bearing? Does anyone have any idea what type of bearing I can use? If there's a name I can search for them on eBay (I assume they are available there).</p>
]]></description><link>https://forum.mysensors.org/post/4389</link><guid isPermaLink="true">https://forum.mysensors.org/post/4389</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Wed, 10 Sep 2014 01:46:20 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Tue, 09 Sep 2014 19:53:49 GMT]]></title><description><![CDATA[<p dir="auto">@ServiceXp</p>
<p dir="auto">Note: I tried the 16Mhz Arduino Nano and I seem to be able to get much higher speeds with high microstepping. I have almost silent operation with 8 microsteps and the blinds open in about 10 seconds. I assume if you get an even faster processor you can step it even more quickly.</p>
]]></description><link>https://forum.mysensors.org/post/4376</link><guid isPermaLink="true">https://forum.mysensors.org/post/4376</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Tue, 09 Sep 2014 19:53:49 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Tue, 09 Sep 2014 14:14:41 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a></p>
<p dir="auto">Thanks for the update.</p>
]]></description><link>https://forum.mysensors.org/post/4367</link><guid isPermaLink="true">https://forum.mysensors.org/post/4367</guid><dc:creator><![CDATA[RJ_Make]]></dc:creator><pubDate>Tue, 09 Sep 2014 14:14:41 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Tue, 09 Sep 2014 13:59:43 GMT]]></title><description><![CDATA[<p dir="auto">@ServiceXp</p>
<p dir="auto">A few things I should mention for anyone trying to undertake this project:<br />
-I'm assuming that the choice of stepper motor is important to control noise. It is possible that a different stepper would give an improved speed/noise ratio.<br />
-One of the most important factor in reducing noise is ensuring there is no hard surface for the motor to 'rumble' on. This is especially bad when using full stepping - the motor rumbles like crazy. The more microsteps, the less rumble and the less noise.<br />
-I coated the sprocket and bracket in silicon caulking to reduce noise, it seemed to help a little, but was nothing compared to reducing the microsteps<br />
-If you are looking to have the best of both worlds, you can add some code as follows in order to choose the microsteps based on the desired RPM. This way you can control the speed via vera and the arduino will actively choose the best microstepping mode. The regular EasyDriver has similar pins, but I believe the most microsteps is 8 and there are only two pins to control<br />
-I am using a 8Mhz 3.3V APM and it may be possible to increase the steps/second if you use a more powerful processor (for example, 16Mhz APM) - I will test it with a nano when I get a chance. <a class="plugin-mentions-user plugin-mentions-a" href="/user/hek" aria-label="Profile: hek">@<bdi>hek</bdi></a>, the nano used for the gateway is 16Mhz, correct?  It says 16M on the eBay page but I just wanted to confirm.</p>
<pre><code>void newnMicroSteps(){
  if(nMicroSteps==1){
    digitalWrite(MS1pin,LOW);
    digitalWrite(MS2pin,LOW);
    digitalWrite(MS3pin,LOW);
  }

  if(nMicroSteps==2){
    digitalWrite(MS1pin,HIGH);
    digitalWrite(MS2pin,LOW);
    digitalWrite(MS3pin,LOW);
  }

  if(nMicroSteps==4){
    digitalWrite(MS1pin,LOW);
    digitalWrite(MS2pin,HIGH);
    digitalWrite(MS3pin,LOW);
  }

  if(nMicroSteps==8){
    digitalWrite(MS1pin,HIGH);
    digitalWrite(MS2pin,HIGH);
    digitalWrite(MS3pin,LOW);
  }

  if(nMicroSteps==16){
    digitalWrite(MS1pin,HIGH);
    digitalWrite(MS2pin,HIGH);
    digitalWrite(MS3pin,HIGH);
  } 


  maxStepperSpeed = maxRPM/60*stepsPerRev*nMicroSteps;
  fullOpenSteps = fullOpenRevs*stepsPerRev*nMicroSteps;
  maxStepperAccel = maxAccelRPMPM/60*stepsPerRev*nMicroSteps;

  stepper1.setMaxSpeed(maxStepperSpeed);
  stepper1.setAcceleration(maxStepperAccel);
}
</code></pre>
<p dir="auto">Edit: I just noticed that I calculated acceleration wrong. Here is the correct equation:</p>
<pre><code>maxStepperAccel = maxAccelRPMPM/60/60*stepsPerRev*nMicroSteps;
</code></pre>
]]></description><link>https://forum.mysensors.org/post/4363</link><guid isPermaLink="true">https://forum.mysensors.org/post/4363</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Tue, 09 Sep 2014 13:59:43 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Tue, 09 Sep 2014 11:20:41 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a></p>
<p dir="auto">Thank you! Gives me an ideal of speed and noise. Both seem very reasonable.</p>
]]></description><link>https://forum.mysensors.org/post/4361</link><guid isPermaLink="true">https://forum.mysensors.org/post/4361</guid><dc:creator><![CDATA[RJ_Make]]></dc:creator><pubDate>Tue, 09 Sep 2014 11:20:41 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Tue, 09 Sep 2014 03:41:06 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a> nice!!</p>
]]></description><link>https://forum.mysensors.org/post/4358</link><guid isPermaLink="true">https://forum.mysensors.org/post/4358</guid><dc:creator><![CDATA[korttoma]]></dc:creator><pubDate>Tue, 09 Sep 2014 03:41:06 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Tue, 09 Sep 2014 00:59:36 GMT]]></title><description><![CDATA[<p dir="auto">@ServiceXp said:</p>
<blockquote>
<p dir="auto">Pretty cool, would it be possible to get a video with audio of the final 'product'?</p>
</blockquote>
<p dir="auto">Sure! This is with eighth steps - and it seems to be as fast as the motor will go without reducing the microsteps.</p>
<p dir="auto"><a href="http://youtu.be/imQj-p-GoYQ" rel="nofollow ugc">http://youtu.be/imQj-p-GoYQ</a></p>
]]></description><link>https://forum.mysensors.org/post/4356</link><guid isPermaLink="true">https://forum.mysensors.org/post/4356</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Tue, 09 Sep 2014 00:59:36 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Mon, 08 Sep 2014 23:33:03 GMT]]></title><description><![CDATA[<p dir="auto">Pretty cool, would it be possible to get a video with audio of the final 'product'?</p>
]]></description><link>https://forum.mysensors.org/post/4355</link><guid isPermaLink="true">https://forum.mysensors.org/post/4355</guid><dc:creator><![CDATA[RJ_Make]]></dc:creator><pubDate>Mon, 08 Sep 2014 23:33:03 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Mon, 08 Sep 2014 22:46:25 GMT]]></title><description><![CDATA[<p dir="auto">Finally finished my setup, here is a picture. Works pretty well, it is slightly louder than I would have hoped but if you run it at 1/16th microsteps its almost silent. The only issue is that it won't run very fast at 1/16 microsteps.<img src="/uploads/upload-8df8ea88-7497-4650-87e6-a7b5897c8146.jpg" alt="IMG_1795-2.jpg" class=" img-fluid img-markdown" /></p>
]]></description><link>https://forum.mysensors.org/post/4354</link><guid isPermaLink="true">https://forum.mysensors.org/post/4354</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Mon, 08 Sep 2014 22:46:25 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Thu, 04 Sep 2014 23:47:47 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/hek" aria-label="Profile: hek">@<bdi>hek</bdi></a></p>
<p dir="auto">Awesome, thanks! I'll give it a go.</p>
]]></description><link>https://forum.mysensors.org/post/4110</link><guid isPermaLink="true">https://forum.mysensors.org/post/4110</guid><dc:creator><![CDATA[naveen]]></dc:creator><pubDate>Thu, 04 Sep 2014 23:47:47 GMT</pubDate></item><item><title><![CDATA[Reply to DIY Blind Control Motor on Thu, 04 Sep 2014 07:46:12 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/naveen" aria-label="Profile: naveen">@<bdi>naveen</bdi></a></p>
<p dir="auto">Yes, it is possible! You have a couple of options.</p>
<p dir="auto">##Poll configuration data from node</p>
<ul>
<li>Select one of V_VAR1, V_VAR2, V_VAR3, V_VAR4, V_VAR5 to use for your configuration;<br />
choose from your root or child nodes. You can use all five parameters per each of your root and child device. It is up to you how to design this;</li>
<li>Program your sketch to fetch variable from vera using <strong>gw.request()</strong>. You will have to take care to get reply later by yourself using in your callback method initialized in <strong>gw.setup()</strong>. See RelayActuator sketch for an example on how to handle incoming messages.</li>
<li>First run of your modified sketch to request parameters. Be prepared that you will receive an empty string because at this time we have just created empty variables at vera side;</li>
<li>Refresh your vera and go to particular child into Advanced Tab. You should be able to see your new variables named Variable1...Variable5. Variable1 corresponds to V_VAR1 inside your sketch etc.;<br />
fill free to change empty field on vera side to the value your needed, Save changes; <img src="/uploads/upload-4f4a269a-3d9c-4939-998a-5b6b07654aaa.jpg" alt="forcase1.jpg" class=" img-fluid img-markdown" /></li>
<li>Check with you Arduino, it should receive correct data at this point;</li>
<li>You free to use whatever design you want. You can pull/request data at each start of you node or you can pull each 30 minutes like many z-wave devices do if they operate from battery. Other example can be if you need for your to nodes to communicate to each other and you need to tell a radio ID to one/both nodes to establish their communication. But for this one you probably want to use Push...</li>
</ul>
<p dir="auto">##Push configuration data from Vera to node</p>
<p dir="auto">Example: You need to push data from vera on event or using schedule and it should be initiated instantly by vera, not by node. For example you want your clock to show external temperature received by vera from the Weather plugin or from other sensor.</p>
<p dir="auto"><img src="/uploads/upload-3e94f98e-37ac-466a-81a3-1f2f843c1e1f.JPG" alt="forcase2.JPG" class=" img-fluid img-markdown" /></p>
<ul>
<li>
<p dir="auto">Choose from V_VAR1, V_VAR2, V_VAR3, V_VAR4, V_VAR5 to be used for data push</p>
</li>
<li>
<p dir="auto">Design your sketch to listen for incoming messages with desired variable. See RelayActuator for an example on how to handle incoming data.</p>
</li>
<li>
<p dir="auto">Create a new scene on vera side. The scene should be run according to your goal. For example  each 10 minutes;</p>
</li>
<li>
<p dir="auto">Use Lua tab while editing scene to provide data for the push. For example this Lua is taking current temperature from Weather (vera id = 61) plugin and pushing it to the node (vera id for root device = 372) using VAR_5:</p>
<p dir="auto">local temp = luup.variable_get("urn:upnp-org:serviceId:TemperatureSensor1","CurrentTemperature", 61)<br />
temp = temp*10.0<br />
luup.call_action("urn:upnp-arduino-cc:serviceId:arduino1", "SendCommand", {radioId="4;255", variableId="VAR_5", value=temp}, 372)</p>
</li>
</ul>
<p dir="auto">SendCommand will push a message to your node. You can also call it with static values (without programming) using the Advanced tab in the scene editor.</p>
<p dir="auto">(This post was updated to 1.4 from from <a class="plugin-mentions-user plugin-mentions-a" href="/user/axillent" aria-label="Profile: axillent">@<bdi>axillent</bdi></a> old <a href="http://code.mios.com/trac/mios_arduino-sensor/wiki/TipsAndTricks" rel="nofollow ugc">tips page on micasaverde</a>)</p>
]]></description><link>https://forum.mysensors.org/post/4086</link><guid isPermaLink="true">https://forum.mysensors.org/post/4086</guid><dc:creator><![CDATA[hek]]></dc:creator><pubDate>Thu, 04 Sep 2014 07:46:12 GMT</pubDate></item></channel></rss>