<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent posts to Newbie - how to format decimal values</title><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/dfa45e1859/" rel="alternate"/><link href="https://forge.codesys.com/forge/talk/CODESYS-V2/thread/dfa45e1859/feed.atom" rel="self"/><id>https://forge.codesys.com/forge/talk/CODESYS-V2/thread/dfa45e1859/</id><updated>2020-02-27T19:05:50.035000Z</updated><subtitle>Recent posts to Newbie - how to format decimal values</subtitle><entry><title>Newbie - how to format decimal values</title><link href="https://forge.codesys.com/forge/talk/Codesys%2520V2.3/thread/dfa45e1859/?limit=25#4da0" rel="alternate"/><published>2020-02-27T19:05:50.035000Z</published><updated>2020-02-27T19:05:50.035000Z</updated><author><name>shooter</name><uri>https://forge.codesys.com/u/shooter/</uri></author><id>https://forge.codesys.com3791e4d68c1064f8ba41aadabc4bbc2326030962</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;it looks correct but it is not correct.&lt;br/&gt;
you must first take off the 3 lower bits and then divide by resolution (12 bits )is 4096.&lt;br/&gt;
the lower bits are used as status bits.&lt;br/&gt;
the highest is not used&lt;/p&gt;
&lt;p&gt;the minimum is 8 and the maximum is 32760 so division is 32752&lt;br/&gt;
if status, changes the value is changing when using your way.&lt;/p&gt;
&lt;p&gt;hope you got it.&lt;br/&gt;
not clear in manual.&lt;/p&gt;
&lt;p&gt;in oscat function block ain1 explains this&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Newbie - how to format decimal values</title><link href="https://forge.codesys.com/forge/talk/Codesys%2520V2.3/thread/dfa45e1859/?limit=25#50e3" rel="alternate"/><published>2020-02-27T19:05:48.835000Z</published><updated>2020-02-27T19:05:48.835000Z</updated><author><name>ROmanFetty</name><uri>https://forge.codesys.com/u/romanfetty/</uri></author><id>https://forge.codesys.comf1a9972b7b2bf16675e664456447470baaa4da82</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;that rocks&lt;br/&gt;
thank YOU:)&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Newbie - how to format decimal values</title><link href="https://forge.codesys.com/forge/talk/Codesys%2520V2.3/thread/dfa45e1859/?limit=25#79cf" rel="alternate"/><published>2020-02-27T19:05:47.646000Z</published><updated>2020-02-27T19:05:47.646000Z</updated><author><name>rudolsto</name><uri>https://forge.codesys.com/u/rudolsto/</uri></author><id>https://forge.codesys.com1a8e47e7672937885578800642e59c84d935ecfc</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Yes, that did it&lt;/p&gt;
&lt;p&gt;Thanks   &lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Newbie - how to format decimal values</title><link href="https://forge.codesys.com/forge/talk/Codesys%2520V2.3/thread/dfa45e1859/?limit=25#1ccb" rel="alternate"/><published>2020-02-27T19:05:44.266000Z</published><updated>2020-02-27T19:05:44.266000Z</updated><author><name>Igor Petrov</name><uri>https://forge.codesys.com/u/igor-petrov/</uri></author><id>https://forge.codesys.com9f2360331cc32d7d6674f3389379c266eb38c036</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Vis. element configuration:&lt;/p&gt;
&lt;p&gt;Text: &lt;strong&gt;%3.1f &lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Variables, Textdisplay:  &lt;strong&gt;(.AI_1 /REAL#32760) * 100&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Regards  &lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Newbie - how to format decimal values</title><link href="https://forge.codesys.com/forge/talk/Codesys%2520V2.3/thread/dfa45e1859/?limit=25#2758" rel="alternate"/><published>2020-02-27T19:05:43.080000Z</published><updated>2020-02-27T19:05:43.080000Z</updated><author><name>rudolsto</name><uri>https://forge.codesys.com/u/rudolsto/</uri></author><id>https://forge.codesys.com1119996f7cde3d9885ee4358593bf5f428f0e8d0</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi  &lt;/p&gt;
&lt;p&gt;I'm trying to make a visualisation with analogue inputs. This application has previousely been presentet in MoviconX.&lt;/p&gt;
&lt;p&gt;The input values from Wago 750-466, is treated this way: AI_1 * 1000 / 32760.&lt;/p&gt;
&lt;p&gt;This results in a analogue range of 0-1000.&lt;/p&gt;
&lt;p&gt;In Movicon this is formatted as 0.0 to 100.0 °C.&lt;/p&gt;
&lt;p&gt;Using %3.1f in CoDeSys does'nt display this value with one decimal&lt;/p&gt;
&lt;p&gt;I assume that the input should have been in REAL format but a block with the name LIMITALARM needs this input in INT format.&lt;/p&gt;
&lt;p&gt;I can change the formula to get the range to 0-100 but a temperature monitoring system is'nt usable with that lousy resolution.&lt;/p&gt;
&lt;p&gt;Is there a way to format the analogue value only in the visualisation or is there another way to solve this issue? &lt;/p&gt;
&lt;p&gt;Any replay is higly appreciated  &lt;/p&gt;&lt;/div&gt;</summary></entry></feed>