<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[RemoteXY community — servo over internet]]></title>
	<link rel="self" href="https://forum.remotexy.com/extern.php?action=feed&amp;tid=1014&amp;type=atom" />
	<updated>2020-05-20T21:59:50Z</updated>
	<generator>PunBB</generator>
	<id>https://forum.remotexy.com/viewtopic.php?id=1014</id>
		<entry>
			<title type="html"><![CDATA[servo over internet]]></title>
			<link rel="alternate" href="https://forum.remotexy.com/viewtopic.php?pid=2972#p2972" />
			<content type="html"><![CDATA[<p>Hi how can i conect a servo and control it over internet. I try but dont know what it went bad.</p><p>*/</p><p>//////////////////////////////////////////////<br />//&nbsp; &nbsp; &nbsp; &nbsp; RemoteXY include library&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; //<br />//////////////////////////////////////////////</p><p>// RemoteXY select connection mode and include library <br />#define REMOTEXY_MODE__ESP8266WIFI_LIB_CLOUD<br />#include &lt;ESP8266WiFi.h&gt;</p><p>#include &lt;RemoteXY.h&gt;</p><p>// RemoteXY connection settings </p><br /><p>#define REMOTEXY_WIFI_SSID &quot;ssid&quot;<br />#define REMOTEXY_WIFI_PASSWORD &quot;pasword&quot;<br />#define REMOTEXY_CLOUD_SERVER &quot;cloud.remotexy.com&quot;<br />#define REMOTEXY_CLOUD_PORT 6376<br />#define REMOTEXY_CLOUD_TOKEN &quot;7be61463064988e6e3903aa9d7rr32a2&quot;</p><br /><p>// RemoteXY configurate&nbsp; <br />#pragma pack(push, 1)<br />uint8_t RemoteXY_CONF[] =<br />&nbsp; { 255,1,0,0,0,11,0,10,13,1,<br />&nbsp; 4,0,24,22,14,43,2,26 };<br />&nbsp; <br />// this structure defines all the variables and events of your control interface <br />struct {</p><p>&nbsp; &nbsp;// input variables<br />&nbsp; uint8_t select_1; // =0 if select position A, =200 if position B, =500 if position C, =1000</p><p>&nbsp; &nbsp; // other variable<br />&nbsp; uint8_t connect_flag;&nbsp; // =1 if wire connected, else =0 </p><p>} RemoteXY;<br />#pragma pack(pop)</p><p>/////////////////////////////////////////////<br />//&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;END RemoteXY include&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; //<br />/////////////////////////////////////////////</p><br /><p>#include &lt;Servo.h&gt;<br />Servo myservo; </p><br /><br /><p>void setup() <br />{<br />&nbsp; RemoteXY_Init (); <br />&nbsp; &nbsp;myservo.attach(9); <br />&nbsp; RemoteXY.select_1 = 50;</p><br /><br /><p>&nbsp; // TODO you setup code<br />&nbsp; <br />}</p><p>void loop() <br />{ <br />&nbsp; RemoteXY_Handler ();<br />&nbsp; int ms = RemoteXY.select_1; <br />&nbsp; myservo.writeMicroseconds(ms); <br />&nbsp; </p><p>}</p>]]></content>
			<author>
				<name><![CDATA[isidrocampos88]]></name>
				<uri>https://forum.remotexy.com/profile.php?id=1376</uri>
			</author>
			<updated>2020-05-20T21:59:50Z</updated>
			<id>https://forum.remotexy.com/viewtopic.php?pid=2972#p2972</id>
		</entry>
</feed>
