<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[REXYGEN Community Forum / Arduino and the REX Control System (REXduino)]]></title>
	<link rel="self" href="https://www.rexygen.com/oldforum/extern.php?action=feed&amp;fid=9&amp;type=atom"/>
	<link href="http://www.rexygen.com/oldforum/index.php"/>
	<updated>2019-03-20T13:40:01Z</updated>
	<generator>FluxBB</generator>
	<id>http://www.rexygen.com/oldforum/index.php</id>
	<entry>
		<title type="html"><![CDATA[REXYGEN Forum has been moved. This one is closed.]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=603&amp;action=new"/>
		<summary type="html"><![CDATA[<p>This REXYGEN Forum is closed for new topics and comments.<br />To start a new topic, go ahead and start one at our <a href="https://forum.rexygen.com" rel="nofollow">brand new REXYGEN Forum</a>, which can be found at <a href="https://forum.rexygen.com" rel="nofollow">forum.rexygen.com</a>.</p><p>Looking forward to moderating your discussions.</p><p>Regards, <br />Tomas @ REXYGEN Team</p>]]></summary>
		<author>
			<name><![CDATA[tomáš čechura]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=39</uri>
		</author>
		<updated>2019-03-20T13:40:01Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=603&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[Accessing User Functions with rexduino]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=463&amp;action=new"/>
		<summary type="html"><![CDATA[<p>Hi,<br />not stupid at all. User data is passed via the userSend input of the block in REXYGEN algorithm. In the current implementation, only the lowest byte of the signal entering the block is sent. Connect a CNI block and enter the desired value 0..100.</p><p>In the REXduino slave, this value appears as the byte &quot;microseconds&quot; entering the function commandU in REXduino_commands.ino. There you can process the value and use it to control your heater.</p><p>You can also change the data which is returned to the REXduino master. By default, uptime in milliseconds (userSend!=0) or microseconds (userSend==0) is returned and this data appears at the userRecv output of the master block in REXYGEN algorithm.</p><p>Hope this answers your question.</p><p>Jaroslav</p>]]></summary>
		<author>
			<name><![CDATA[jaroslav_sobota]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=3</uri>
		</author>
		<updated>2018-08-17T07:26:50Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=463&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[REXduino_slave.ino compile error(s)]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=265&amp;action=new"/>
		<summary type="html"><![CDATA[<p>Hi Brian,<br />any chance to try compiling the sketch on a different machine? On my PC with Win7 the sketch compiles fine even in 1.6.12.</p><p>Thanks for posting your findings and thanks for your interest in REXduino!</p><p>Jaroslav</p>]]></summary>
		<author>
			<name><![CDATA[jaroslav_sobota]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=3</uri>
		</author>
		<updated>2016-11-02T06:25:29Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=265&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[tradeoffs ?]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=246&amp;action=new"/>
		<summary type="html"><![CDATA[<p>Hello Brian,</p><p>we don&#039;t have any specific document about advantages / disadvantages of using REXduino.<br />This is list of dis/advantages I can think of now:</p><p>Advantages:</p><ul><li><p>analog inputs (e.g. 17x using Arduino MEGA compared to absence of analog inputs on Raspberry PI)</p></li><li><p>more GPIOs (up to 54 GPIO using Arduino MEGA compared to standart 17 GPIO on Raspberry PI)</p></li></ul><p>Disadvantages:</p><ul><li><p>slower sample rate (up to 20 ms in general or up to 10 ms with limited IOs in operation)</p></li><li><p>additional hardware required (Arduino)</p></li></ul><p>If you require any further information, let me know.</p><p>Regards, Tomas</p>]]></summary>
		<author>
			<name><![CDATA[tomáš čechura]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=39</uri>
		</author>
		<updated>2016-10-12T11:43:47Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=246&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[REX and Arduino/Controllino]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=175&amp;action=new"/>
		<summary type="html"><![CDATA[<p>REX can only use Arduinos as input/output devices. There are examples for Arduino MEGA2560 and Arduino Uno/Nano. See <a href="https://www.rexcontrols.com/articles/rex-on-raspberry-pi-meets-arduino" rel="nofollow">this article about REXduino</a> for more details.</p><p>The same probably holds for Controllino but I have no personal experience.</p>]]></summary>
		<author>
			<name><![CDATA[jaroslav_sobota]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=3</uri>
		</author>
		<updated>2016-06-29T09:33:01Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=175&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[Problems with REXduino]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=171&amp;action=new"/>
		<summary type="html"><![CDATA[<p>Hi Jaroslav,</p><p>We were able to get the &quot;Slave&quot; file/code loaded on our Arduino Uno once we defined all the errors. We were then able to the get the blink example you provided to work. We are now just trying to familiarize ourselves with the function blocks. For now we are to just simulating some analog inputs and have basic ouputs.&#160; <br />I&#039;ll keep you posted on our progress.</p>]]></summary>
		<author>
			<name><![CDATA[kevrye]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=78</uri>
		</author>
		<updated>2016-06-15T13:17:10Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=171&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[Multiple Arduino boards?]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=17&amp;action=new"/>
		<summary type="html"><![CDATA[<p>Yes it is but some extra care is necessary. If you just plug the 2 Arduinos in and reboot, you never know which one of them is /dev/ttyACM0 and which one is /dev/ttyACM1 (or /dev/ttyUSB*, see the other topic on <a href="http://www.rexygen.com/oldforum/viewtopic.php?id=4" rel="nofollow">identifying your Arduino</a>). </p><p>So let&#039;s get this sorted out. First plug in only one Arduino and type</p><div class="codebox"><pre><code>ls /dev/ttyACM*</code></pre></div><p>You should get <strong>/dev/ttyACM0</strong>. Use it in the following command.</p><p>Then run this command</p><div class="codebox"><pre><code>udevadm info -a -n /dev/ttyACM0 | less | grep KERNELS</code></pre></div><p>You will get something like:</p><div class="codebox"><pre><code>    KERNELS==&quot;1-1.2:1.0&quot;
    KERNELS==&quot;1-1.2&quot;
    KERNELS==&quot;1-1&quot;
    KERNELS==&quot;usb1&quot;
    KERNELS==&quot;20980000.usb&quot;
    KERNELS==&quot;soc&quot;
    KERNELS==&quot;platform&quot;</code></pre></div><p>Write down the identifier from the first line (&quot;1-1.2:1.0&quot;). This identifies the USB port in your system.</p><p>Repeat the above with the Arduino connected to another USB port(s) and find the USB port identifiers. I have &quot;1-1.2:1.0&quot; and &quot;1-1.3:1.0&quot;.</p><p>Now create a file named <strong>/etc/udev/rules.d/99-arduino.rules</strong>, e.g.</p><div class="codebox"><pre><code>sudo nano /etc/udev/rules.d/99-arduino.rules</code></pre></div><p>Put the following in:</p><div class="codebox"><pre><code>SUBSYSTEM==&quot;tty&quot;, KERNEL==&quot;ttyACM*&quot;, KERNELS==&quot;1-1.2:1.0&quot;, SYMLINK+=&quot;arduino_one&quot;
SUBSYSTEM==&quot;tty&quot;, KERNEL==&quot;ttyACM*&quot;, KERNELS==&quot;1-1.3:1.0&quot;, SYMLINK+=&quot;arduino_two&quot;</code></pre></div><p>Add more lines if you plan to use more than two Arduinos. Save and exit.</p><p>This means that whenever a ttyACM* device is plugged into the USB port &quot;1-1.2:1.0&quot;, a symbolic device /dev/arduino_one is created. And that whenever a ttyACM* device is plugged into the USB port &quot;1-1.3:1.0&quot;, a symbolic device /dev/arduino_two is created.</p><p>Now disconnect your Arduino and run </p><div class="codebox"><pre><code>sudo /etc/init.d/udev reload</code></pre></div><p>Afterwards connect your Arduinos to the appropriate USB ports and you should be able to use <strong>/dev/arduino_one</strong> and <strong>/dev/arduino_two</strong> in the REXduino function blocks. Unless you mismatch the USB ports, you&#039;ll always know which Arduino you are referring to.</p>]]></summary>
		<author>
			<name><![CDATA[jaroslav_sobota]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=3</uri>
		</author>
		<updated>2015-11-10T14:12:48Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=17&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[REXduino hex masks]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=15&amp;action=new"/>
		<summary type="html"><![CDATA[<p>When the HEX mask is used, the pin modes are defined by hexadecimal numbers. E.g. for pins 0 to 7 the parameter pinmodes_00_07 can be 0x320A0800, which means:<br />pin 7: mode 3 = digital input<br />pin 6: mode 2 = digital output<br />pin 5: mode 0 = not used<br />pin 4: mode A = counter DIR<br />pin 3: mode 0 = not used<br />pin 2: mode 8 = counter pulses<br />pin 1: mode 0 = not used<br />pin 0: mode 0 = not used </p><p>Note the reversed order.</p><p>Numbering of the modes is the following:<br />0: Not connected<br />1: Not connected<br />2: Digital output<br />3: Digital input<br />4: Digital input with internal pull-up<br />5: Analog output (PWM) <br />6: Analog input<br />7: 1-Wire temperature<br />8: Counter (only pins 2 and 3)<br />9: Encoder A (only pins 2 and 3)<br />A: Counter DIR / Encoder B (only pins 4 and 5, pin pairs are 2+4 and 3+5)</p>]]></summary>
		<author>
			<name><![CDATA[jaroslav_sobota]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=3</uri>
		</author>
		<updated>2015-11-10T12:22:00Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=15&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[PID Control with REXDuino]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=9&amp;action=new"/>
		<summary type="html"><![CDATA[<p>Find the example attached. The LIN blocks scale the signals to 0-100% range, change it to 0-5 if you prefer.</p><p>As a side note, the PIDU block calculates appropriate output even if the input is above setpoint. Why do you want to implement the IF condition?</p><p><a href="https://www.rexcontrols.cz/forum/img/members/3/REXduino_master.stl" rel="nofollow">REXduino_master.stl</a><br /><a href="https://www.rexcontrols.cz/forum/img/members/3/X_UNO_PIDloop_task.mdl" rel="nofollow">X_UNO_PIDloop_task.mdl</a><br /><a href="https://www.rexcontrols.cz/forum/img/members/3/X_UNO_PIDloop_exec.mdl" rel="nofollow">X_UNO_PIDloop_exec.mdl</a></p>]]></summary>
		<author>
			<name><![CDATA[jaroslav_sobota]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=3</uri>
		</author>
		<updated>2015-11-03T20:42:11Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=9&amp;action=new</id>
	</entry>
	<entry>
		<title type="html"><![CDATA[Serial device on Raspberry Pi?]]></title>
		<link rel="alternate" href="http://www.rexygen.com/oldforum/viewtopic.php?id=4&amp;action=new"/>
		<summary type="html"><![CDATA[<p>Right after plugging the Arduino in, type <strong>dmesg</strong> into the console and at the end of the output you will find something like:</p><div class="codebox"><pre><code>[159084.594626] usb 1-1.2: new full-speed USB device number 4 using dwc_otg
[159084.710558] usb 1-1.2: New USB device found, idVendor=2341, idProduct=0001
[159084.710597] usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=220
[159084.710614] usb 1-1.2: Product: Arduino Uno
[159084.710628] usb 1-1.2: Manufacturer: Arduino (www.arduino.cc)
[159084.710642] usb 1-1.2: SerialNumber: 64935343733351F060E0
[159084.773590] cdc_acm 1-1.2:1.0: ttyACM0: USB ACM device
[159084.778277] usbcore: registered new interface driver cdc_acm
[159084.778312] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters</code></pre></div><p>From which you can see that your Arduino is <strong>/dev/ttyACM0</strong>.</p><p>The Arduinos with FTDI USB chip typically appear as <strong>/dev/ttyUSB0</strong>.</p><p>Another option is to type <strong>ls /dev/tty*</strong> before and after plugging the Arduino in and find the new device in the list. That&#039;s your Arduino.</p>]]></summary>
		<author>
			<name><![CDATA[jaroslav_sobota]]></name>
			<uri>http://www.rexygen.com/oldforum/profile.php?id=3</uri>
		</author>
		<updated>2014-06-13T07:01:58Z</updated>
		<id>http://www.rexygen.com/oldforum/viewtopic.php?id=4&amp;action=new</id>
	</entry>
</feed>
