<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Redeem Archives - www.iagent.no</title>
	<atom:link href="https://www.iagent.no/category/redeem/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.iagent.no/category/redeem/</link>
	<description>High end 3D printer electronics</description>
	<lastBuildDate>Wed, 22 Feb 2017 21:09:39 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://www.iagent.no/wp-content/uploads/2024/07/cropped-plain-logo-blue-32x32.png</url>
	<title>Redeem Archives - www.iagent.no</title>
	<link>https://www.iagent.no/category/redeem/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Improved automatic bed leveling in Redeem</title>
		<link>https://www.iagent.no/2017/02/22/improved-automatic-bed-leveling-in-redeem/</link>
					<comments>https://www.iagent.no/2017/02/22/improved-automatic-bed-leveling-in-redeem/#comments</comments>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Wed, 22 Feb 2017 21:09:39 +0000</pubDate>
				<category><![CDATA[Redeem]]></category>
		<category><![CDATA[Replicape]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=1704</guid>

					<description><![CDATA[<p>Automatic bed leveling helps improve first layer height above bed. That is very useful, because if the first layer does not stick, the rest of the print does not matter. It also lowers the bar for first times to get started, and it saves a bunch of time for old-timers that have moved their printer. [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2017/02/22/improved-automatic-bed-leveling-in-redeem/">Improved automatic bed leveling in Redeem</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><a href="http://www.thing-printer.com/wp-content/uploads/2016/08/Perfect-first-layer.png"><img fetchpriority="high" decoding="async" class="aligncenter size-large wp-image-1962" src="http://www.thing-printer.com/wp-content/uploads/2016/08/Perfect-first-layer-1024x684.png" alt="Perfect-first-layer" width="1024" height="684" /></a></p>
<p>Automatic bed leveling helps improve first layer height above bed. That is very useful, because if the first layer does not stick, the rest of the print does not matter. It also lowers the bar for first times to get started, and it saves a bunch of time for old-timers that have moved their printer.</p>
<p>But bed probing, the pre-cursor to automatic bed leveling can be done in a lot of ways. There are a bunch of probes available for the actual probing, but choosing the right probe depends on the type of bed, the weight of the sensor, the cost etc. In addition, different printers have different ways of doing the probing.</p>
<p>Redeem has gotten some much needed attention on the bed probing, leveling and visualization of the process and results lately. This blog post aims to go over the new interface, including some helper G-codes for quickly getting started.</p>
<h2>TL;DR &#8211; See the video</h2>
<p><iframe title="Bed compensation in Redeem howto" width="1290" height="726" src="https://www.youtube.com/embed/xCWKeRLxGvE?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe></p>
<h2>G29 interface documentation</h2>
<p>The interface (how to use the command) is pretty straight forward. The G29 code itself is only a macro, meaning that it does almost nothing except execute all the G-codes in it&#8217;s macro definition. The only parameter that can be supplied, is the letter &#8220;S&#8221;, for Simulate. If an S is added, all lines with the letters &#8220;RFS&#8221; (Remove For Simulation) is removed from the macro. The G29 macro is defined in the config file hierarchy, and can be generated using the G-codes G29S and G29C. See further down. Here is the interface definition.</p>
<pre>Send: G29?
Recv: Probe the bed at specified points and update the bed compensation matrix based on the found points. Add 'S' to only simulate and thus remove all lines containing the letters 'RFS' (Remove For Simulation).
</pre>
<h3>Ok, but if it&#8217;s a Macro, what commands can be put in there?</h3>
<p>You can put pretty much<a href="http://wiki.thing-printer.com/index.php?title=Redeem#Implemented_Gcodes"> any G-code that is implemented in Redeem</a>. The reason the G29 is implemented as a macro is to facilitate all the different ways 3D-printers, CNC mills and lasers are built, with all their quirky ways of probing. Here is a list of G-codes that might be useful.</p>
<h4>M561 &#8211; Reset, update or show bed matrix</h4>
<p>This is a utility function for manipulating the bed matrix. M561 is defined to &#8220;reset the bed matrix&#8221; <a href="http://reprap.org/wiki/G-code#M561:_Set_Identity_Transform">according to the reprap wiki</a>. To maintain compatibility with that definition, the M561 without parameters will do just that. It has also been extended with some functionality. If a &#8220;U&#8221; is added as a parameter, the bed calibration matrix is updated based on the data from a probe. If &#8220;S&#8221; is added as parameter, show the current matrix. The reason for having this as a separate G-code and not as a part of the G29 inner workings is so that is can be removed during a simulation and also used in different places in the macro.</p>
<pre id="terminal-output" class="pre-scrollable" data-bind="foreach: displayedLines, visible: fancyFunctionality()"><span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Send: M561?</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: This cancels any bed-plane fitting as the result of probing (or anything else) and returns the machine to moving in the user's coordinate system.</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Add 'S' to show the marix instead of resetting it.</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Add 'U' to update the current matrix based on probe data</span></pre>
<h4>M557 &#8211; Set probe point</h4>
<p>This is used to pre-define which points to probe. No probing occurs, just a definition of a probing point which can later be recalled using the G30 command.</p>
<pre id="terminal-output" class="pre-scrollable" data-bind="foreach: displayedLines, visible: fancyFunctionality()"><span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Send: M557?</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Set the points at which the bed will be probed to compensate for its plane being slightly out of horizontal. The P value is the index of the point(indices start at 0) and the X and Y values are the position to move extruder 0 to to probe the bed. An implementation should allow a minimum of three points (P0, P1 and P2). This just records the point coordinates; it does not actually do the probing.</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: P = Probe point number.</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: X = X-coordinate</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Y = Y-coordinate</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Z = Z-coordinate. If missing, set to 0</span></pre>
<h4>G30  &#8211; Probe point &#8211; Execute a bed probing of a single point.</h4>
<p>The G30 command is used to perform the actual probing. In the G29 macro, this is the meat and potatoes of the routine. During a testing phase, this can also be a very useful command to try when just trying the probing to make sure it works.</p>
<pre id="terminal-output" class="pre-scrollable" data-bind="foreach: displayedLines, visible: fancyFunctionality()"><span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Send: G30?</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Probe the bed at the current position, or if specified, a point previously set by M557. X, Y, and Z starting probe positions can be overridden, D sets the probe length, or taken from config if nothing is specified.</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: F sets the probe speed. If not present, it's taken from the config.</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: A sets the probe acceleration. If not present, it's taken from the config.</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: B determines if the bed marix is used or not. (0 or 1)</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: P the point at which to probe, previously set by M557.</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: P and S save the probed bed distance to a list that corresponds with point P</span></pre>
<h4>G32 &#8211; Undock probe</h4>
<p>Activate whatever probing mechanism you have. This is itself a macro, so typically you would put some G-code that will move a servo with a switch in place, apply power to a solenoid, or simply define an end-stop to be active through the M574 command.</p>
<h4>G31 &#8211; Dock probe</h4>
<p>This should reverse the action done by the G32 command.</p>
<h2>Pattern generator</h2>
<p>The G29 command is implemented as a macro. That means that it is simply a bunch of G-codes read and executed in an orderly fashion. This is useful, because it makes it easy to adjust how the G29 code works for each individual printer. The downside is that it can be meticulous to write the G-codes by hand. Therefore a nifty G29 generator has been made and implemented in Redeem. It can be invoked by the command G29S (S is for Square) or G29C (C is for Circle).</p>
<p>A quick view of what the two pattern generators look like:</p>
<pre id="terminal-output" class="pre-scrollable" data-bind="foreach: displayedLines, visible: fancyFunctionality()"><span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Send: G29C?</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Generate a circular G29 Probing pattern</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: D = bed_diameter_mm, default: 140</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: C = Circles, default = 2</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: P = points_pr_circle, default: 8</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: S = probe_start_height, default: 6.0</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Z = add_zero, default = 1</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: K = probe_speed, default: 3000.0


</span></pre>
<pre id="terminal-output" class="pre-scrollable" data-bind="foreach: displayedLines, visible: fancyFunctionality()"><span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Send: G29S?</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: Generate a square G29 Probing pattern</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: W = bed depth mm, default: 200.0</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: D = bed depth mm, default: 200.0</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: P = points in total, default: 16</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: S = probe start height, default: 6.0</span>
<span data-bind="text: line, css: {muted: type == 'filtered' || type == 'cut'}">Recv: K = probe_speed, default: 3000.0</span></pre>
<p>Here is  visual representation of what that looks like.</p>
<p><a href="http://www.thing-printer.com/wp-content/uploads/2016/08/G29C.png"><img decoding="async" class="aligncenter size-large wp-image-1711" src="http://www.thing-printer.com/wp-content/uploads/2016/08/G29C-1024x683.png" alt="G29C" width="1024" height="683" srcset="https://www.iagent.no/wp-content/uploads/2016/08/G29C-1024x683.png 1024w, https://www.iagent.no/wp-content/uploads/2016/08/G29C-800x533.png 800w, https://www.iagent.no/wp-content/uploads/2016/08/G29C-300x200.png 300w, https://www.iagent.no/wp-content/uploads/2016/08/G29C-768x512.png 768w, https://www.iagent.no/wp-content/uploads/2016/08/G29C-600x400.png 600w, https://www.iagent.no/wp-content/uploads/2016/08/G29C.png 1206w" sizes="(max-width: 1024px) 100vw, 1024px" /></a></p>
<p>For many users, using the pattern generator directly can work, but for users with special probing routines, they can work as starting points for further improvements to the macro.</p>
<h2>Visualizing the result</h2>
<h4>Using Toggle</h4>
<p>There are several ways to visualize the results of a probing. Toggle will give an online (real time) view in 3D of the probing as it occurs using color coded pointers. This is useful to get a glimpse of the skewedness of the bed during a probing, and quickly determine if a probe point is registered as an outlier. That can happen if the probe is triggered too soon. It might be considered too coarse to do any optimization of the bed, but it&#8217;s good for getting an indication.</p>
<p>Looking at the results from the below probing for instance, done on my <a href="http://wiki.thing-printer.com/index.php?title=Thing_Delta">Thing Delta </a>, it&#8217;s clear that the bed is really pretty slanted, having the highest point at +1 mm and the lowest at -1.94 mm. Still, looking at the pattern it appears to be pretty linear with the highest towards the front and the lowest towards the back.</p>
<p><a href="http://www.thing-printer.com/wp-content/uploads/2017/01/Probe-toggle.png"><img loading="lazy" decoding="async" class="aligncenter size-full wp-image-1965" src="http://www.thing-printer.com/wp-content/uploads/2017/01/Probe-toggle.png" alt="Probe-toggle" width="825" height="523" srcset="https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle.png 825w, https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-800x507.png 800w, https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-300x190.png 300w, https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-768x487.png 768w, https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-600x380.png 600w" sizes="auto, (max-width: 825px) 100vw, 825px" /></a></p>
<p>Running the same probe with the command &#8220;G29 S&#8221; reveals the flatness of the bed using the currently implemented bed calibration matrix. The hight map generated by the probing points should now be more or less random, but with a much lower difference between the highest and the lowest probing point. In the testing probe run, the total height difference is only 0.17 mm, which is not great, but good enough for most prints.</p>
<p><a href="http://www.thing-printer.com/wp-content/uploads/2017/01/Probe-toggle-2.png"><img loading="lazy" decoding="async" class="aligncenter size-full wp-image-1967" src="http://www.thing-printer.com/wp-content/uploads/2017/01/Probe-toggle-2.png" alt="Probe-toggle-2" width="824" height="532" srcset="https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-2.png 824w, https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-2-800x517.png 800w, https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-2-300x194.png 300w, https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-2-768x496.png 768w, https://www.iagent.no/wp-content/uploads/2017/01/Probe-toggle-2-600x387.png 600w" sizes="auto, (max-width: 824px) 100vw, 824px" /></a></p>
<h4>Using Review</h4>
<p>Second is using the review website to view the results of the probing. After a probing routine has been completed, a small info box will appear in OctoPrint, with a prompt to view the result of the probing. This link will upload the probing data to a website for viewing in a 3D-preview. Historical data is kept and can be added as an overlay to the previous probing results, giving an indication of whether or not the probing is improving. The review app differs between probing and testing data, depending on whether or not the &#8220;S&#8221; was added during the probing, so it is easy to compare the results before and after.</p>
<p><a href="http://www.thing-printer.com/wp-content/uploads/2017/01/Review-1.png"><img loading="lazy" decoding="async" class="aligncenter size-large wp-image-1968" src="http://www.thing-printer.com/wp-content/uploads/2017/01/Review-1-1024x636.png" alt="Review-1" width="1024" height="636" srcset="https://www.iagent.no/wp-content/uploads/2017/01/Review-1-1024x636.png 1024w, https://www.iagent.no/wp-content/uploads/2017/01/Review-1-800x497.png 800w, https://www.iagent.no/wp-content/uploads/2017/01/Review-1-300x186.png 300w, https://www.iagent.no/wp-content/uploads/2017/01/Review-1-768x477.png 768w, https://www.iagent.no/wp-content/uploads/2017/01/Review-1-600x372.png 600w, https://www.iagent.no/wp-content/uploads/2017/01/Review-1.png 1416w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></p>
<p>The post <a href="https://www.iagent.no/2017/02/22/improved-automatic-bed-leveling-in-redeem/">Improved automatic bed leveling in Redeem</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.iagent.no/2017/02/22/improved-automatic-bed-leveling-in-redeem/feed/</wfw:commentRss>
			<slash:comments>5</slash:comments>
		
		
			</item>
		<item>
		<title>PID autotune algorithm improvements</title>
		<link>https://www.iagent.no/2017/01/06/pid-autotune-algorithm-improvements/</link>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Fri, 06 Jan 2017 15:48:09 +0000</pubDate>
				<category><![CDATA[Redeem]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=1436</guid>

					<description><![CDATA[<p>Redeem is quickly becoming the standard in 3D printer firmwares with self documenting G-codes and pre-processing path planner. Up until recently, two fairly standard features have had somewhat sub-par performance: PID auto-tune and automatic bed calibration. A recent poll on the Thing-printer G+ page revealed that these two things were on the top of list [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2017/01/06/pid-autotune-algorithm-improvements/">PID autotune algorithm improvements</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><a href="http://www.thing-printer.com/wp-content/uploads/2016/08/Screenshot-from-2016-05-21-18-55-40.png"><img loading="lazy" decoding="async" class="aligncenter size-full wp-image-1678" src="http://www.thing-printer.com/wp-content/uploads/2016/08/Screenshot-from-2016-05-21-18-55-40.png" alt="Screenshot from 2016-05-21 18-55-40" width="647" height="420" srcset="https://www.iagent.no/wp-content/uploads/2016/08/Screenshot-from-2016-05-21-18-55-40.png 647w, https://www.iagent.no/wp-content/uploads/2016/08/Screenshot-from-2016-05-21-18-55-40-300x195.png 300w, https://www.iagent.no/wp-content/uploads/2016/08/Screenshot-from-2016-05-21-18-55-40-600x389.png 600w" sizes="auto, (max-width: 647px) 100vw, 647px" /></a></p>
<p><a href="http://wiki.thing-printer.com/index.php?title=Redeem">Redeem</a> is quickly becoming the standard in 3D printer firmwares with self documenting G-codes and pre-processing path planner. Up until recently, two fairly standard features have had somewhat sub-par performance: PID auto-tune and automatic bed calibration. A recent poll on the <a href="https://plus.google.com/+EliasBakken/posts/4dkBbzysKRe">Thing-printer G+ page</a> revealed that these two things were on the top of list of things to improve, so in this article and the next, the new improvements will be documented.</p>
<p>When work started on the PID auto tune code, a few bugs and issues were discovered. Here is a quick rundown of the most important changes.</p>
<ul>
<li>Non standard implementation of the PID algorithm.</li>
<li>Got rid of the &#8216;derivative kick&#8217;</li>
<li>Implemented Steinhart-Hart algorithm</li>
<li>Decimal numbers on temperature</li>
<li>Current set point reported.</li>
<li>Implemented M301</li>
</ul>
<p>The old implementation had something akin to a mix between the standard and the ideal form. The PID algorithm is quite robust to tuning errors, so it was still possible to tune it well with the old implementation, but the current implementation is now a clean standard form implementation, which is what is most used in the industry. That makes it easy to test out new auto tuning calculations, if one was so inclined. Here is the standard formula for reference, taken from <a href="https://en.wikipedia.org/wiki/PID_controller">Wikipedia</a>:</p>
<p><img decoding="async" class="mwe-math-fallback-image-inline" src="https://wikimedia.org/api/rest_v1/media/math/render/svg/c0b2251a7c96240727206f07d267fca833627cc2" alt="\mathrm {MV(t)} =K_{p}\left(\,{e(t)}+{\frac {1}{T_{i}}}\int _{0}^{t}{e(\tau )}\,{d\tau }+T_{d}{\frac {d}{dt}}e(t)\right)" /></p>
<p>Due to this switch, some parameters in the config files have changed:</p>
<p>&#8220;pid_p_E&#8221; changes to &#8220;pid_Kp_E&#8221;</p>
<p>&#8220;pid_i_E&#8221; changes to &#8220;pid_Ti_E&#8221;</p>
<p>&#8220;pid_d_E&#8221; changes to &#8220;pid_Td_E&#8221;</p>
<p>Furthermore, some nice improvements to the code were added, like decimal temperature reporting and set point reporting. Mainly these improvements were for debugging during testing, but they are nice to have either way.</p>
<p>A big change for anyone doing configuration of their printer is the change from table based lookup of temperature to using the <a href="https://en.wikipedia.org/wiki/Steinhart%E2%80%93Hart_equation">Steinhart-Hart algorithm</a> for calculating temperature. This should add accuracy to the temperature and also simplify adding new sensors, since it is no longer necessary to generate a lookup table with a script.</p>
<p>As a result of this, some other important settings have been changed in the config files.</p>
<p>&#8220;temp_chart_E&#8221; changes to &#8220;sensor_E&#8221;</p>
<p>All the config changes are present in the new default.cfg file. If one of the old style configs are found in either printer.cfg or local.cfg, a warning will be given during startup. Please check the log after upgrading.</p>
<p>&nbsp;</p>
<h2>Documentation of new M303 interface</h2>
<p>The G-code M303 has a slightly updated interface compared to the previous versions. Btw, if at any time you need the most up to date documentation for a G-code in Redeem, simply write add a question mark after the G-code, for example: &#8220;M303?&#8221;</p>
<pre id="terminal-output" class="pre-scrollable" style="font-size: 0.7em;" data-bind="foreach: displayedLines, visible: fancyFunctionality()">Send: M303?
Recv: PID Tuning refers to a control algorithm used in some repraps to tune heating behavior for hot ends and heated beds. This command generates Proportional (Kp), Integral (Ki), and Derivative (Kd) values for the hotend or bed (E-1). Send the appropriate code and wait for the output to update the firmware. E overrides the extruder. Use E-1 for heated bed.
Recv: Default is the 'E' extruder with index 0.
Recv: S overrides the temperature to calibrate for. Default is 200.
Recv: C overrides the number of cycles to run, default is 4
Recv: P (0,1) Enable pre-calibration. Useful for systems with very high power
Recv: Q Tuning algorithm. 0 = Tyreus-Luyben, 1 = Zieger-Nichols classic
</pre>
<h2>Improvements over other implementations</h2>
<p>When doing experiments with the new auto tune routine, much advice and inspiration was drawn from the works of Ryan Carlyle, an eager Replicape user and RepRap contributor. One thing in particular he recommended was to add a pre-calibration routine, to figure out the rise time and fall time for the temperature of the hot end. This in turn can be used as a better starting point for the actual calibration cycles by estimating the rise and fall times ahead. A positive side-effect of the pre-calibration is that the amount of over-shoot typically experienced in a naïve bang-bang auto tune cycle diminishes. This can prevent filament from charcoaling due to excess temperatures.</p>
<p>The experiment did work, and can be tested out with the P-parameter added to M303. However, the formula relies on <a href="https://en.wikipedia.org/wiki/Newton%27s_law_of_cooling">Newton&#8217;s law of cooling</a> which breaks in the face of forced convection (IE a fan blowing on  or near the hot end). Thus to get good results, make sure you disable the automatic cold end fan that most hot ends use.</p>
<p>The result of the experimental tuning method can be seen in the header image. The important part is the pre-calibrate routine, something along the lines of:</p>
<ol>
<li>Heat with 25% power to determine the maximum heat-up rate and dead-time.</li>
<li>Heat with full power until calibration temp is reached, minus the dead time.</li>
<li>Wait until peak temp is reached, then record the slope of the falling temperature graph a number of times.</li>
<li>Calculate the relationship between the heat-up rise time and the cool-down time to get a starting point for calibration.</li>
</ol>
<p>The routine in the header image goes on to try and set the steady state temperature using the calculated values before calibrating with a bang-bang type calibration and the finally testing the resulting values.</p>
<p>The new algorithm also allows for specifying which type of tuning parameters are used. Right now, only Tyreus-Luyben and Zieger-Nichols classic are implemented, but other values are easily added, and pull requests are welcome!</p>
<p>&nbsp;</p>
<p>The post <a href="https://www.iagent.no/2017/01/06/pid-autotune-algorithm-improvements/">PID autotune algorithm improvements</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Filament sensor on 3D printer with Replicape</title>
		<link>https://www.iagent.no/2016/04/23/filament-sensor-3d-printer-replicape/</link>
					<comments>https://www.iagent.no/2016/04/23/filament-sensor-3d-printer-replicape/#comments</comments>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Sat, 23 Apr 2016 16:11:28 +0000</pubDate>
				<category><![CDATA[Beaglebone]]></category>
		<category><![CDATA[Redeem]]></category>
		<category><![CDATA[Replicape]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=1312</guid>

					<description><![CDATA[<p>Increased reliability with a filament sensor One of the most annoying things that can happen when printing with 3D-printers is running out of filament or a filament jam. Both are almost unavoidable. There is no infinite filament (yet) and even the best filament manufacturers some times end up with foreign objects in their plastic batches. [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2016/04/23/filament-sensor-3d-printer-replicape/">Filament sensor on 3D printer with Replicape</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><iframe loading="lazy" title="Filament sensor using rotary encoder on Replicape" width="1290" height="726" src="https://www.youtube.com/embed/v7Xa20eVqRM?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe></p>
<p><strong>Increased reliability with a filament sensor</strong></p>
<p>One of the most annoying things that can happen when printing with 3D-printers is running out of filament or a filament jam. Both are almost unavoidable. There is no infinite filament (yet) and even the best filament manufacturers some times end up with foreign objects in their plastic batches. The thing that will separate current and future 3D-printers is most likely more sensors for monitoring stuff. Take a leap into the future right away by adding a rotary encoder based filament monitor to your <a href="http://www.thing-printer.com/product/replicape/">Replicape</a> controlled 3D-printer!</p>
<p>Replicape has support for incremental <a href="https://en.wikipedia.org/wiki/Rotary_encoder">rotary encoders</a> that can be used to monitor the movement of filament past the encoder. Typically a rotary encoder will give off discrete signals as a result of angular movement in one direction. The signals can be used to sense the direction and amount of angular movement the rotary encoder has done, which in turn can be converted into amount of filament consumed by knowing the diameter of the rotary encoders shaft. This information will need to be given to Redeem, in the section <a href="http://wiki.thing-printer.com/index.php?title=Redeem#Rotary-encoders">Rotary-encoders</a>.</p>
<p><b>Software side</b><br />
Behind the scenes, <a href="http://wiki.thing-printer.com/index.php?title=Redeem">Redeem</a> uses Linux&#8217;s <a href="https://www.kernel.org/doc/Documentation/input/rotary-encoder.txt">rotary encoder kernel driver</a>, which simplifies the development and maintainability of this feature. In order to enable this, you will need to know the number of cycles pr. revolution your encoder emits (cpr-e), the diameter of the wheel brushing against the filament and (diameter-e), and the device on which the events are reported, typically /dev/event/input1 (event-e). The big problem with the current setup is that you you need to reconfigure the devicetree in order to activate the rotary encoder kernel module. There is a document for the Linux kernel describing this binding: <a href="http://lxr.free-electrons.com/source/Documentation/devicetree/bindings/input/rotary-encoder.txt">http://lxr.free-electrons.com/source/Documentation/devicetree/bindings/input/rotary-encoder.txt</a>.</p>
<pre>           rotary@0 {
                compatible = "rotary-encoder";
                gpios = &lt;&amp;gpio3 17 0&gt;, &lt;&amp;gpio0 4 0&gt;;
                linux,axis = ; /* REL_X */
                rotary-encoder,relative-axis;
            };
</pre>
<p>Since the input device needs to be mentioned in the config file, it might be a good idea to also set up a udev rule symlinking the rotary encoder to a known name. That way, it will always get the same device name. Here is an example:</p>
<pre>nano  /etc/udev/rules.d/99-rotary.rules
</pre>
<p>Place this into that file:</p>
<pre>SUBSYSTEM=="input", ACTION=="add", ATTRS{name}=="ocp:rotary@2", SYMLINK+="rotary0"
</pre>
<p>A working rotary encoder setup for extruder E will look like this:</p>
<pre>[Rotary-encoders]
enable-e = True
event-e = /dev/rotary0
cpr-e = -360
diameter-e = 0.003
</pre>
<p>Place this into:</p>
<pre>/etc/redeem/local.cfg
</pre>
<p>Notice that the event device name (event-e) corresponds to what was set up with the udev rule.</p>
<p>It is also possible to set up an alarm that will trigger if the sensor deviates too much from what it should be.<br />
If you want an alarm for that, set that up like the following:</p>
<pre>[Filament-sensors]
# If the error is &gt; 10 cm, sound the alarm
alarm-level-e = 0.1
</pre>
<p>Currently, if an alarm is triggered, it will send a &#8220;pause&#8221; action command to OctoPrint.</p>
<p>To visualize the filament use, <a href="http://wiki.thing-printer.com/index.php?title=Toggle">Toggle</a> now has a built in filament graph. To show it, simply tap the temperature graph to toggle between temperature and filament. To enable the streaming of data from Redeem, use the G-code (or M-code) M409. The token E enables all filament sensors connected, while D disables all. You can also specify which sensor to stream for by using an index after the &#8220;E&#8221;, so M409 E0 enables streaming for extruder 0 (E).</p>
<p><b>Electronics part</b><br />
On the hardware side, two end-stop inputs are needed since a rotary encoder has two outputs. In addition to this they typically need a 5V-ish power source (+5V and GND). All of this can be taken from two end stops on Replicape. In the video posted, I&#8217;m using a rotary encoder left by a master student. A quick google search reveals that it is a <a href="http://www.usdigital.com/products/s4">s4-360-125-b-d</a>, a $100 super smooth optical encoder. While doing research, I also ordered a few cheap rotary encoders from Digi-key, but soon realized that &#8220;retention&#8221; is not something you want, since it causes &#8220;drag&#8221; on the encoder. Useful if you want to use it for a user interface, but not so great if you want no additional force for your extruder. These from Digi-key work, but are not recommended for this particular purpose:<br />
<a href="http://www.digikey.no/product-detail/en/C14D32P-A3/102-1923-ND/2039183">http://www.digikey.no/product-detail/en/C14D32P-A3/102-1923-ND/2039183</a><br />
<a href="http://www.digikey.no/product-search/en?keywords=102-1763-nd">http://www.digikey.no/product-search/en?keywords=102-1763-nd</a></p>
<p><b>Mechanical part</b><br />
So using the US digital rotary encoder, I created a simple &#8220;slide along&#8221; filament sensor. It relies on the filament being pushed towards the rotary encoder shaft causing it to rotate. This solution is not ideal, and will easily cause wrongful measurements, from what i have experienced, but it does suffice for a simple experiment.<br />
<a href="http://www.thing-printer.com/wp-content/uploads/2016/04/2016-04-23-17.58.17.jpg"><img loading="lazy" decoding="async" class="size-large wp-image-1396 aligncenter" src="http://www.thing-printer.com/wp-content/uploads/2016/04/2016-04-23-17.58.17-1024x768.jpg" alt="2016-04-23 17.58.17" width="1024" height="768" srcset="https://www.iagent.no/wp-content/uploads/2016/04/2016-04-23-17.58.17-1024x768.jpg 1024w, https://www.iagent.no/wp-content/uploads/2016/04/2016-04-23-17.58.17-scaled-800x600.jpg 800w, https://www.iagent.no/wp-content/uploads/2016/04/2016-04-23-17.58.17-300x225.jpg 300w, https://www.iagent.no/wp-content/uploads/2016/04/2016-04-23-17.58.17-768x576.jpg 768w, https://www.iagent.no/wp-content/uploads/2016/04/2016-04-23-17.58.17-1536x1152.jpg 1536w, https://www.iagent.no/wp-content/uploads/2016/04/2016-04-23-17.58.17-2048x1536.jpg 2048w, https://www.iagent.no/wp-content/uploads/2016/04/2016-04-23-17.58.17-600x450.jpg 600w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></p>
<p>The post <a href="https://www.iagent.no/2016/04/23/filament-sensor-3d-printer-replicape/">Filament sensor on 3D printer with Replicape</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.iagent.no/2016/04/23/filament-sensor-3d-printer-replicape/feed/</wfw:commentRss>
			<slash:comments>6</slash:comments>
		
		
			</item>
		<item>
		<title>Getting started with Kamikaze on Replicape Rev B</title>
		<link>https://www.iagent.no/2016/02/17/getting-started-with-replicape-rev-b/</link>
					<comments>https://www.iagent.no/2016/02/17/getting-started-with-replicape-rev-b/#comments</comments>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Wed, 17 Feb 2016 18:23:30 +0000</pubDate>
				<category><![CDATA[Kamikaze]]></category>
		<category><![CDATA[Redeem]]></category>
		<category><![CDATA[Replicape]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=1276</guid>

					<description><![CDATA[<p>Finally a video that is specific to getting started with Replicape Rev B using the Kamikaze eMMC flasher! There is a new Kamikaze image out that addresses some of the issues that have become apparent after people started to get their capes. To name a few: If I access my printer on IP whatever, the [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2016/02/17/getting-started-with-replicape-rev-b/">Getting started with Kamikaze on Replicape Rev B</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><a href="http://www.thing-printer.com/wp-content/uploads/2016/02/bubamara.jpg" rel="attachment wp-att-1277"><img loading="lazy" decoding="async" class="size-full wp-image-1277 aligncenter" src="http://www.thing-printer.com/wp-content/uploads/2016/02/bubamara.jpg" alt="bubamara" width="640" height="457" srcset="https://www.iagent.no/wp-content/uploads/2016/02/bubamara.jpg 640w, https://www.iagent.no/wp-content/uploads/2016/02/bubamara-300x214.jpg 300w, https://www.iagent.no/wp-content/uploads/2016/02/bubamara-600x428.jpg 600w" sizes="auto, (max-width: 640px) 100vw, 640px" /></a></p>
<p>Finally a video that is specific to getting started with Replicape Rev B using the Kamikaze eMMC flasher!</p>
<p><iframe loading="lazy" title="Replicape getting started with rev B" width="1290" height="726" src="https://www.youtube.com/embed/BKb28fJx26I?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe></p>
<p>There is a new Kamikaze image out that addresses some of the issues that have become apparent after people started to get their capes. To name a few:</p>
<p><strong>If I access my printer on IP whatever, the OctoPrint link does not work.</strong></p>
<p>The link is now gone. Instead, if you access your printer through your prowser you will be directed to OctoPrint directly.</p>
<p><strong>How do I configure my printer?</strong></p>
<p>The easiest way is to use OctoPrint for this. Upload the file you want to use through the redeem plugin interface in OctoPrint.</p>
<p><strong>I can access OctoPrint, but I cannot connect!</strong></p>
<p>When flashing your BeagleBone with Kamikaze, the flasher will check the signature of the EEPROM on the Replicape. If the signature is invalid, it will update it with the Replicape Rev B3 EEPROM file.</p>
<p><strong>Something has gone wrong, where do I start to debug?</strong></p>
<p>The log for Redeem is now placed in the &#8220;logs&#8221; section in OctoPrint, so that is a good place to start.</p>
<p>&nbsp;</p>
<p>Once you are done with this video, go on to <a href="http://www.thing-printer.com/end-stop-configuration-for-redeem/">end stop configuration</a></p>
<p>The post <a href="https://www.iagent.no/2016/02/17/getting-started-with-replicape-rev-b/">Getting started with Kamikaze on Replicape Rev B</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.iagent.no/2016/02/17/getting-started-with-replicape-rev-b/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title>Get Quad extruders for Replicape by adding Reach</title>
		<link>https://www.iagent.no/2016/02/04/quad-extruders-for-replicape-add-reach/</link>
					<comments>https://www.iagent.no/2016/02/04/quad-extruders-for-replicape-add-reach/#comments</comments>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Thu, 04 Feb 2016 16:05:31 +0000</pubDate>
				<category><![CDATA[Reach]]></category>
		<category><![CDATA[Redeem]]></category>
		<category><![CDATA[Replicape]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=1212</guid>

					<description><![CDATA[<p>I&#8217;ve finally gotten around to testing the Reach A0 add-on board for Replicape A4A. This is a board that adds three more extruders to the two extruders that come with Replicape, for a total of five extruders. Any axis can also be configured in slave mode, in case you have multiple steppers pr. axis. The [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2016/02/04/quad-extruders-for-replicape-add-reach/">Get Quad extruders for Replicape by adding Reach</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><a href="http://www.thing-printer.com/wp-content/uploads/2016/02/DSC_0129.jpg"><img loading="lazy" decoding="async" class="aligncenter wp-image-1213 size-large" src="http://www.thing-printer.com/wp-content/uploads/2016/02/DSC_0129-1024x591.jpg" alt="three more extruders with Reach" width="1024" height="591" srcset="https://www.iagent.no/wp-content/uploads/2016/02/DSC_0129-1024x591.jpg 1024w, https://www.iagent.no/wp-content/uploads/2016/02/DSC_0129-scaled-800x462.jpg 800w, https://www.iagent.no/wp-content/uploads/2016/02/DSC_0129-300x173.jpg 300w, https://www.iagent.no/wp-content/uploads/2016/02/DSC_0129-768x443.jpg 768w, https://www.iagent.no/wp-content/uploads/2016/02/DSC_0129-1536x886.jpg 1536w, https://www.iagent.no/wp-content/uploads/2016/02/DSC_0129-2048x1182.jpg 2048w, https://www.iagent.no/wp-content/uploads/2016/02/DSC_0129-600x346.jpg 600w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a>I&#8217;ve finally gotten around to testing the Reach A0 add-on board for Replicape A4A. This is a board that adds three more extruders to the two extruders that come with Replicape, for a total of five extruders. Any axis can also be configured in slave mode, in case you have multiple steppers pr. axis.</p>
<p><iframe loading="lazy" title="Demonstration of 4 extruders on Replicape/Redeem" width="1290" height="726" src="https://www.youtube.com/embed/Jyjv-9uoYqQ?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe></p>
<p>The Reach board was ready for review over <a href="http://www.thing-printer.com/reach-expansion-board-replicape-ready-review/">two years ago</a>, but only now the software for it was ready. Some people have made their own versions of the board, but as far as I know, no one has ever gotten it to work! Well, that all ended on Tuesday, when the Reach board was running for full capacity.</p>
<p>Reach A0 is an add-on board for Replicape A4A, the pre-runner for the Rev B board. Many people have asked for a Reach rev B, one that is compatible with Replicape Rev B. All I can say is that it will be designed, but the volume will likely not make it a viable product for sale. Best case will be small production run, but as you know that really increases the price.</p>
<p>The cool thing about this is that Redeem now has support for up to 8 axes that can be operated at the same time. Previously, one had to chose an extruder, but now you can be fancy and use this G-code:</p>
<p>G0 X10 Y10 Z10 E10 H10 A10 B10 C10</p>
<p>That is if you are one of the three-ish people that have a Reach board. The fans can be connected to the thermistors, so the fan on the extruder starts when the extruder temperature goes above 60 degrees celsius. The M104 command now also supports higher number extruders as well.</p>
<p>Any of the additional axes can also be used in &#8220;slave mode&#8221; so there is no need for a splitting cable if you happen to have an additional stepper driver.</p>
<p>Fun project! Hopefully someone will try this out with a<a href="https://www.kickstarter.com/projects/wr3d/the-diamond-hotend-single-nozzle-multi-color-3d-pr"> diamond hot-end</a> or <a href="http://e3d-online.com/The-Kraken">Kraken</a>.</p>
<p>The post <a href="https://www.iagent.no/2016/02/04/quad-extruders-for-replicape-add-reach/">Get Quad extruders for Replicape by adding Reach</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.iagent.no/2016/02/04/quad-extruders-for-replicape-add-reach/feed/</wfw:commentRss>
			<slash:comments>8</slash:comments>
		
		
			</item>
		<item>
		<title>Some new safety features in Redeem</title>
		<link>https://www.iagent.no/2016/01/31/some-new-safety-features-in-redeem/</link>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Sun, 31 Jan 2016 21:29:12 +0000</pubDate>
				<category><![CDATA[Redeem]]></category>
		<category><![CDATA[Replicape]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=1205</guid>

					<description><![CDATA[<p>Over the weekend, I&#8217;ve been working on some quite important features: Safety! The most important being disabling the heaters if anything goes wrong with the thermistor readings. &#160; It&#8217;s boring, but it&#8217;s necessary. Safety features does nothing to improve the print quality, but it might prevent your house from burning down. It&#8217;s still necessary to [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2016/01/31/some-new-safety-features-in-redeem/">Some new safety features in Redeem</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><a href="http://www.thing-printer.com/wp-content/uploads/2016/01/DSC_0110.jpg"><img loading="lazy" decoding="async" class="size-large wp-image-1207 aligncenter" src="http://www.thing-printer.com/wp-content/uploads/2016/01/DSC_0110-1024x679.jpg" alt="DSC_0110" width="1024" height="679" srcset="https://www.iagent.no/wp-content/uploads/2016/01/DSC_0110-1024x679.jpg 1024w, https://www.iagent.no/wp-content/uploads/2016/01/DSC_0110-scaled-800x530.jpg 800w, https://www.iagent.no/wp-content/uploads/2016/01/DSC_0110-300x199.jpg 300w, https://www.iagent.no/wp-content/uploads/2016/01/DSC_0110-768x509.jpg 768w, https://www.iagent.no/wp-content/uploads/2016/01/DSC_0110-1536x1018.jpg 1536w, https://www.iagent.no/wp-content/uploads/2016/01/DSC_0110-2048x1358.jpg 2048w, https://www.iagent.no/wp-content/uploads/2016/01/DSC_0110-600x398.jpg 600w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a></p>
<p>Over the weekend, I&#8217;ve been working on some quite important features: Safety! The most important being disabling the heaters if anything goes wrong with the thermistor readings.</p>
<p><iframe loading="lazy" title="Stepper and heater disable" width="1290" height="726" src="https://www.youtube.com/embed/oaTdElpZitM?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe></p>
<p>&nbsp;</p>
<p>It&#8217;s boring, but it&#8217;s necessary. Safety features does nothing to improve the print quality, but it might prevent your house from burning down. It&#8217;s still necessary to keep an eye on the printer when it&#8217;s running and always install a smoke detector near by.</p>
<p>The most important feature is the min_temp alarm. This is an alarm that will trigger if the temperature drops below the current target temperature. That means it has to be activated with an M151. So if you want to use this feature, add a M151 to the end of your start.gcode in the slicer profile.</p>
<p>If you do happen to trigger an alarm for some reason, all the heaters will go into an error state. This state can be returned to normal by issuing an M562 command.</p>
<p>Eventually we might automate the enabling of the min_temp alarm, but for now it will have to be enabled &#8220;manually&#8221;.</p>
<p>There are four other alarms related to temperature:</p>
<p>Max_temp reached, triggered if the temperature goes above a certain threshold, currently 250 degrees celsius.</p>
<p>Temp_rising_quickly: If there is a short on the thermistor wires , this will get triggered.</p>
<p>Temp falling quickly: Triggered if a thermistor wire breaks or the connector comes loose.</p>
<p>Thermistor error: If there is an error reading the temperature from the ADC, this is triggered. If this has happened, the board will actually need a complete reboot. This was an error that occurred from time to time on the Rev A boards, but with the new, less noisy Rev B boards, it has not been seen so far.</p>
<p>The new changes are now in the develop branch, and will be packaged into the Debian package of <a href="http://wiki.thing-printer.com/index.php?title=Redeem">redeem</a> as soon as some more people have tested it.</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>The post <a href="https://www.iagent.no/2016/01/31/some-new-safety-features-in-redeem/">Some new safety features in Redeem</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>End stop configuration for Redeem</title>
		<link>https://www.iagent.no/2016/01/26/end-stop-configuration-for-redeem/</link>
					<comments>https://www.iagent.no/2016/01/26/end-stop-configuration-for-redeem/#comments</comments>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Tue, 26 Jan 2016 18:36:13 +0000</pubDate>
				<category><![CDATA[Redeem]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=1193</guid>

					<description><![CDATA[<p>Most of the Replicapes from the Kickstarter has now been delivered, and people are starting to try it out and getting into configuration. Great, but not for everyone! A lot of people seem to be having trouble with the end stop configuration, so I made a video explaining how it works. It really not that difficult [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2016/01/26/end-stop-configuration-for-redeem/">End stop configuration for Redeem</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Most of the Replicapes from the Kickstarter has now been delivered, and people are starting to try it out and getting into configuration. Great, but not for everyone! A lot of people seem to be having trouble with the end stop configuration, so I made a video explaining how it works.</p>
<p><iframe loading="lazy" title="Replicape end stop configuration" width="1290" height="726" src="https://www.youtube.com/embed/5LEjdQtIYe4?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe></p>
<p>It really not that difficult if one wants to use G-codes for it. These are the G-codes you&#8217;ll need:</p>
<p>M574 &#8211; this connects an end stop to one or more stepper motors. Use the form &#8220;M574 X1 x_cw&#8221; if you want end stop X1 to stop stepper X from going clockwise.</p>
<p>M270 &#8211; Set coordinate system, this might be useful for figuring out which axis does what on delta printers.</p>
<p>M206 &#8211; Set offset for each of the axes. After an end stop is hit, it will move to this offset. Remember that the travel distance can be negative, in which case, the offset would most likely be negative also.</p>
<p>M119 &#8211; Get current end stop state. Can also be used for inverting end stops. Non-inverted is NC switches, inverted is NO switches.</p>
<p>M569 &#8211; Set the direction of a stepper. You could just flip the connector, but where is the fun in that?</p>
<p>What is not yet implemented with a G-code interface is &#8220;travel&#8221; for each of the axes. This defines the direction and length each axis should search for an end-stop. Sometimes the end-stop is not located near the 0, 0 origin of the  of the bed, so you might try a negative travel value.</p>
<p>&nbsp;</p>
<p>The post <a href="https://www.iagent.no/2016/01/26/end-stop-configuration-for-redeem/">End stop configuration for Redeem</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.iagent.no/2016/01/26/end-stop-configuration-for-redeem/feed/</wfw:commentRss>
			<slash:comments>8</slash:comments>
		
		
			</item>
		<item>
		<title>Redeem new features preview</title>
		<link>https://www.iagent.no/2015/10/09/redeem-new-features-preview/</link>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Fri, 09 Oct 2015 19:17:54 +0000</pubDate>
				<category><![CDATA[Beaglebone]]></category>
		<category><![CDATA[Redeem]]></category>
		<category><![CDATA[Replicape]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=1003</guid>

					<description><![CDATA[<p>Redeem, the Replicape Daemon, is the &#8220;firmware&#8221; that accepts g-codes and makes the 3D-printer move. What is special about this firmware is that it is mostly written in a high level language. Python is not the fastest language around, but offers a large array of libraries optimized in C, garbage collection, favours readability and has [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2015/10/09/redeem-new-features-preview/">Redeem new features preview</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><a href="http://www.thing-printer.com/wp-content/uploads/2015/04/Redeem_header.png"><img loading="lazy" decoding="async" class="size-full wp-image-654 aligncenter" src="http://www.thing-printer.com/wp-content/uploads/2015/04/Redeem_header.png" alt="Redeem_header" width="960" height="480" srcset="https://www.iagent.no/wp-content/uploads/2015/04/Redeem_header.png 960w, https://www.iagent.no/wp-content/uploads/2015/04/Redeem_header-800x400.png 800w, https://www.iagent.no/wp-content/uploads/2015/04/Redeem_header-300x150.png 300w, https://www.iagent.no/wp-content/uploads/2015/04/Redeem_header-768x384.png 768w, https://www.iagent.no/wp-content/uploads/2015/04/Redeem_header-600x300.png 600w" sizes="auto, (max-width: 960px) 100vw, 960px" /></a></p>
<p><a href="http://wiki.thing-printer.com/index.php?title=Redeem">Redeem</a>, the <a href="https://www.kickstarter.com/projects/1924187374/replicape-a-smart-and-quiet-3d-printer-control-boa/">Replicape</a> Daemon, is the &#8220;firmware&#8221; that accepts g-codes and makes the 3D-printer move. What is special about this firmware is that it is mostly written in a high level language. Python is not the fastest language around, but offers a large array of libraries optimized in C, garbage collection, favours readability and has very good integration with C/C++. That way most of the code base can be kept in Python, with only a small core optimized in C.</p>
<p>The native path planner, was originally ported from <a href="http://www.repetier.com/">Repetier</a> firmware. The porting was done by Mathieu Monney, and although it has worked great, there have been certain short comings with the code base. Looking through any firmware for 3D-printers, you will see a well of pre-processor directives to optimize the code at compile time based on what type of machine the code will be running on. That is necessary when you have 16 MHz of processing power, 256 KB of total flash storage and 8 KB of SRAM. However, using a modern day platform with 1000 MHz of processing power, 4 GB of flash storage and 512 MB of DDR3 SRAM, the need for compile time optimizations diminishes severely. Add to that a floating point unit, and you no longer have to weigh every use of floats in the code.</p>
<p>An effort has therefore been to move the native path planner into something more suited for BeagleBone Black and similar speced platforms. A side effect to this has been to make the whole path planner more stepper agnostic, meaning that the path planner no longer has any concept of what each axis does what, and will simply merge each axis using the <a href="https://en.wikipedia.org/wiki/Bresenham's_line_algorithm">Bresenham</a> algorithm. This enables doing some pretty fancy things, such as having one or more steppers operate in &#8220;<a href="https://bitbucket.org/intelligentagent/redeem/src/2df52dcccf52?at=slave_stepper">slave mode</a>&#8220;, easily adding more stepper motors, in order to facilitate <a href="https://www.kickstarter.com/projects/wr3d/the-diamond-hotend-single-nozzle-multi-color-3d-pr">color mixing</a> etc. It could also be used to specify what each axis does in run time, if one was so inclined.</p>
<p>I&#8217;ve recently done some development on this, and although it&#8217;s still a fairly early proof of concept, printing objects do work and slave mode seems to behave as it should. I made a quick video showing a demo, along with an explanation.</p>
<p><iframe loading="lazy" src="https://www.youtube.com/embed/2uXw5w5nJiM" width="560" height="315" frameborder="0" allowfullscreen="allowfullscreen"></iframe></p>
<p>The post <a href="https://www.iagent.no/2015/10/09/redeem-new-features-preview/">Redeem new features preview</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Cape manager is back baby!</title>
		<link>https://www.iagent.no/2015/07/13/cape-manager-is-back-baby/</link>
					<comments>https://www.iagent.no/2015/07/13/cape-manager-is-back-baby/#comments</comments>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Mon, 13 Jul 2015 16:43:29 +0000</pubDate>
				<category><![CDATA[Beaglebone]]></category>
		<category><![CDATA[Redeem]]></category>
		<category><![CDATA[Replicape]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=844</guid>

					<description><![CDATA[<p>For BeagleBone Black the cape manager has been missing or somewhat broken since 3-odd-8 or something, but with Linux kernel 4.1, it&#8217;s back in business (a part of mainline kernel)! That means you no longer have to recompile the whole device tree in order to enable or disable an IP core slash peripheral, instead you [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2015/07/13/cape-manager-is-back-baby/">Cape manager is back baby!</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><a href="http://www.thing-printer.com/wp-content/uploads/2015/07/cape-manager.jpg"><img loading="lazy" decoding="async" class="aligncenter wp-image-886 size-large" src="http://www.thing-printer.com/wp-content/uploads/2015/07/cape-manager-e1436801580611-1024x613.jpg" alt="cape manager" width="1024" height="613" srcset="https://www.iagent.no/wp-content/uploads/2015/07/cape-manager-e1436801580611-1024x613.jpg 1024w, https://www.iagent.no/wp-content/uploads/2015/07/cape-manager-e1436801580611-800x479.jpg 800w, https://www.iagent.no/wp-content/uploads/2015/07/cape-manager-e1436801580611-300x180.jpg 300w, https://www.iagent.no/wp-content/uploads/2015/07/cape-manager-e1436801580611-768x460.jpg 768w, https://www.iagent.no/wp-content/uploads/2015/07/cape-manager-e1436801580611-1536x919.jpg 1536w, https://www.iagent.no/wp-content/uploads/2015/07/cape-manager-e1436801580611-2048x1226.jpg 2048w, https://www.iagent.no/wp-content/uploads/2015/07/cape-manager-e1436801580611-600x359.jpg 600w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></a><br />
For BeagleBone Black the cape manager has been missing or somewhat broken since 3-odd-8 or something, but with Linux kernel 4.1, it&#8217;s <a href="https://plus.google.com/108019867520491227967/posts/1x2nkiFoDCG">back in business</a> (a part of mainline kernel)! That means you no longer have to recompile the whole device tree in order to enable or disable an IP core slash peripheral, instead you can simply compile the overlay and fix the device tree in the running kernel. This simplifies development and there are also some good tools and a repo for pushing these changes out.</p>
<p><b>What it does</b><br />
Without cape manager, you basically have one single device tree blog that is loaded when the kernel starts. If you want to change which peripherals are enabled, you need to recompile the device and reboot. With cape manager, you can choose to change parts of the device tree in a running kernel. This enables loading cape-specific overlays based on the cape that is attached (read from the EEPROM of the cape) or via command line to enable a specific peripheral or mux the pins to a specific function. This is what the Adafruit BBIO library does behind the scenes.</p>
<p><b>Get started with cape manager</b><br />
Start with a fresh Debian distro. <a href="http://beagleboard.org/latest-images">The official Debain image form March</a> should do.<br />
Install the newest kernel:</p>
<pre>apt-cache search linux-image
</pre>
<p>Pick one of the latest, for instance &#8220;linux-image-4.1.1-bone10&#8221;:</p>
<pre>apt-get install linux-image-4.1.1-bone10
</pre>
<p>Clone the <a href="https://github.com/RobertCNelson/bb.org-overlays">bb.org device tree overlay repository</a>:</p>
<pre>cd /usr/src
git clone https://github.com/RobertCNelson/bb.org-overlays
cd bb.org-overlays
</pre>
<p>Follow the instructions on how to use upgrade and use the cape manager from there. The instructions are good, basically:<br />
&#8211; Upgrade the DTC<br />
&#8211; compile the overlays.</p>
<p><b>Tools for checking your work</b><br />
The cape manager is now located in a more static location in the sys fs than before. The new location is:</p>
<pre>cat /sys/devices/platform/bone_capemgr/slots
</pre>
<p>To see which capes are loaded, cat it.<br />
If you are working on pin-muxing there are a couple of files that can be useful to cat:</p>
<pre>cat /sys/kernel/debug/pinctrl/44e10800.pinmux/pins
</pre>
<p>This file will give you the pin number, the adress of the pin in physical memory and to which function it has been muxed (1 to 7). It will also tell you if it is set up as input/output in the case of GPIO (function 7) and if it has pull-up or pull-down.<br />
Another useful sysfs file is this:</p>
<pre>cat /sys/kernel/debug/pinctrl/44e10800.pinmux/pingroups
</pre>
<p>This can be used to check that a pin has been claimed in the overlay. Very useful for making sure that the groups you add to the <b>am33xx_pinmux</b> node are actually set up as you want them to be.</p>
<p><b>Helpful #define files</b><br />
A while back I posted a <a href="http://hipstercircuits.com/enable-serialuarttty-on-beaglebone-black/">table with the mapping from the headers</a> exposing the different pins on the BeagleBone to the physical address of the pins. For a while now there has been a header file defining this mapping and providing user friendly names that can be used for pin muxing. By adding the following includes to the header of your device tree overlay source files, you can use the pin names from the exposed headers verbatim:</p>
<pre>#include &lt;<a href="https://github.com/beagleboard/bb.org-overlays/blob/master/include/dt-bindings/board/am335x-bbw-bbb-base.h">dt-bindings/board/am335x-bbw-bbb-base.h</a>&gt;
#include &lt;<a href="https://github.com/beagleboard/bb.org-overlays/blob/master/include/dt-bindings/pinctrl/am33xx.h">dt-bindings/pinctrl/am33xx.h</a>&gt;
</pre>
<p>Instead of writing</p>
<pre>    dallas_w1_pins: pinmux_dallas_w1_pins {
        pinctrl-single,pins = &lt; 0x150 0x37 // Dallas 1W &gt;;
    };
</pre>
<p>You can now write</p>
<pre>    dallas_w1_pins: pinmux_dallas_w1_pins {
        pinctrl-single,pins = &lt; BONE_P9_22 (INPUT_EN | PIN_PULLUP | MUX_MODE7) &gt;;
    };
</pre>
<p>so this saves you from having to look up the pins in a table.</p>
<p><b>caveats in porting old overlays</b><br />
A while back I ported the patches for the <a href="http://www.thing-printer.com/converting-device-tree-overlays-kernel-3-12/">cape manager to a kernel 3.12</a> for use in an Angstrom based distro. If you want to port an old cape from the kernel 3.8 era, you will notice that there are a couple of changes. Most importantly that the GPIO banks used to go from 1 to 4, but now go from 0 to 3. Also, the UARTs/serials go from 0 to 6 to match /dev/ttyO* in the file system. You can see this by peeking into the am33xx.dtsi (device tree source inclue file) in the mainline kernel repository: <a href="https://github.com/torvalds/linux/blob/master/arch/arm/boot/dts/am33xx.dtsi#L168">https://github.com/torvalds/linux/blob/master/arch/arm/boot/dts/am33xx.dtsi#L168</a></p>
<p>The post <a href="https://www.iagent.no/2015/07/13/cape-manager-is-back-baby/">Cape manager is back baby!</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.iagent.no/2015/07/13/cape-manager-is-back-baby/feed/</wfw:commentRss>
			<slash:comments>11</slash:comments>
		
		
			</item>
		<item>
		<title>New Kamikaze CNC image released</title>
		<link>https://www.iagent.no/2015/06/30/new-kamikaze-cnc-image-released/</link>
					<comments>https://www.iagent.no/2015/06/30/new-kamikaze-cnc-image-released/#comments</comments>
		
		<dc:creator><![CDATA[Elias Bakken]]></dc:creator>
		<pubDate>Tue, 30 Jun 2015 15:27:20 +0000</pubDate>
				<category><![CDATA[Beaglebone]]></category>
		<category><![CDATA[Manga Screen]]></category>
		<category><![CDATA[Redeem]]></category>
		<category><![CDATA[Replicape]]></category>
		<category><![CDATA[Toggle]]></category>
		<guid isPermaLink="false">http://www.thing-printer.com/?p=850</guid>

					<description><![CDATA[<p>Kamikaze is a Debian-based eMMC flasher image for BeagleBone Black. It is a complete solution for Replicape and Manga-Screen aiming to contain all software needed to slice a model and print it without installing any additional software. And it has now been updated! The latest image has an updated Octoprint 1.2 which now has CuraEngine [&#8230;]</p>
<p>The post <a href="https://www.iagent.no/2015/06/30/new-kamikaze-cnc-image-released/">New Kamikaze CNC image released</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><a href="http://www.thing-printer.com/wp-content/uploads/2015/04/Kamikaze_header.png"><img loading="lazy" decoding="async" class="aligncenter wp-image-653 size-full" src="http://www.thing-printer.com/wp-content/uploads/2015/04/Kamikaze_header.png" alt="Kamikaze_header" width="960" height="480" srcset="https://www.iagent.no/wp-content/uploads/2015/04/Kamikaze_header.png 960w, https://www.iagent.no/wp-content/uploads/2015/04/Kamikaze_header-800x400.png 800w, https://www.iagent.no/wp-content/uploads/2015/04/Kamikaze_header-300x150.png 300w, https://www.iagent.no/wp-content/uploads/2015/04/Kamikaze_header-768x384.png 768w, https://www.iagent.no/wp-content/uploads/2015/04/Kamikaze_header-600x300.png 600w" sizes="auto, (max-width: 960px) 100vw, 960px" /></a></p>
<p><a href="http://wiki.thing-printer.com/index.php?title=Kamikaze">Kamikaze</a> is a Debian-based eMMC flasher image for BeagleBone Black. It is a complete solution for <a href="http://wiki.thing-printer.com/index.php?title=Replicape">Replicape</a> and <a href="http://wiki.thing-printer.com/index.php?title=Manga_Screen">Manga-Screen</a> aiming to contain all software needed to slice a model and print it without installing any additional software. And it has now been updated!</p>
<p>The latest image has an updated<a href="http://octoprint.org/"> Octoprint 1.2</a> which now has <a href="http://reprap.org/wiki/Cura">CuraEngine</a> as a plugin simplifying the slicing of models. So now, you can upload Cura slicer profiles directly from Octoprint.  Further, I&#8217;ve made a plugin for <a href="http://wiki.thing-printer.com/index.php?title=Redeem">Redeem</a>, meaning that you can also import Redeem config files and restart redeem from the Octoprint settings window.</p>
<p>The new image also has the ADC bug removed that was present in the last release. There is also support for <a href="http://www.thing-printer.com/new-major-revision-of-replicape-rev-b/">Replicape Rev B1</a>, of which there only exists one prototype 🙂 This image also has Linux kernel 4.1.0-bone9 with cape manager, so the right device tree is loaded based on the EEPROM on your cape.</p>
<p>There are still a few things I want to fix in an upcoming version, namely having the zeroconf plugin for Octoprint work out of the box, so there will probably be another distro coming in a while. Also, a big project will be better integration between Octoprint and <a href="http://wiki.thing-printer.com/index.php?title=Toggle">Toggle</a> so it is possible to see which model is printing and progress on both screens.</p>
<p>The post <a href="https://www.iagent.no/2015/06/30/new-kamikaze-cnc-image-released/">New Kamikaze CNC image released</a> appeared first on <a href="https://www.iagent.no">www.iagent.no</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.iagent.no/2015/06/30/new-kamikaze-cnc-image-released/feed/</wfw:commentRss>
			<slash:comments>6</slash:comments>
		
		
			</item>
	</channel>
</rss>
