<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="pl-pl">
<link rel="self" type="application/atom+xml" href="https://forum.atnel.pl/feed.php?f=4&amp;t=13150&amp;mode" />

<title>ATNEL tech-forum</title>
<link href="https://forum.atnel.pl/index.php" />
<updated>2015-10-08T07:14:24+01:00</updated>

<author><name><![CDATA[ATNEL tech-forum]]></name></author>
<id>https://forum.atnel.pl/feed.php?f=4&amp;t=13150&amp;mode</id>
<entry>
<author><name><![CDATA[wchpikus]]></name></author>
<updated>2015-10-08T07:14:24+01:00</updated>
<published>2015-10-08T07:14:24+01:00</published>
<id>https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141810#p141810</id>
<link href="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141810#p141810"/>
<title type="html"><![CDATA[Re: ds18b20 i lcd , wiem, wiem, bylo]]></title>

<content type="html" xml:base="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141810#p141810"><![CDATA[
ok caly kod:)<br /><br />[syntax=c]char printbuff&#91;8&#93;;<br /><br />int main(){<br />LCD_Initalize();<br />double d = 0;<br /><br />int licznik = 0;<br /><br />while(1){<br />d = ds18b20_gettemp();<br />noga++;<br />licznik++;<br /><br />if (noga == PC6){<br />noga = PC4;<br />}<br />_delay_ms(1000);<br />LCD_Clear();<br /><br /><br />LCD_GoTo(0,0);<br />// przelacznie na drugi ds<br />if (noga == PC5){ <br />LCD_WriteText(&quot;ds = out &quot;);<br />}<br />if (noga == PC4){<br />LCD_WriteText(&quot;ds = in &quot;);<br />}<br />//********************<br />LCD_GoTo(0,1);<br />dtostrf(d, 10, 1, printbuff);<br />LCD_WriteText(printbuff);LCD_WriteText(&quot;*C&quot;);[/syntax]<p>Statystyki: Napisane przez <a href="https://forum.atnel.pl/memberlist.php?mode=viewprofile&amp;u=3859">wchpikus</a> — 8 paź 2015, o 07:14</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[gumeni]]></name></author>
<updated>2015-10-07T19:39:54+01:00</updated>
<published>2015-10-07T19:39:54+01:00</published>
<id>https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141777#p141777</id>
<link href="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141777#p141777"/>
<title type="html"><![CDATA[Re: ds18b20 i lcd , wiem, wiem, bylo]]></title>

<content type="html" xml:base="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141777#p141777"><![CDATA[
Brak &quot;;&quot; po <br />[syntax=c]LCD_GoTo(0,1)[/syntax]<br /><br />poprawione:<br />[syntax=c]LCD_GoTo(0,1);[/syntax]<p>Statystyki: Napisane przez <a href="https://forum.atnel.pl/memberlist.php?mode=viewprofile&amp;u=3088">gumeni</a> — 7 paź 2015, o 19:39</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[wchpikus]]></name></author>
<updated>2015-10-07T16:30:22+01:00</updated>
<published>2015-10-07T16:30:22+01:00</published>
<id>https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141726#p141726</id>
<link href="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141726#p141726"/>
<title type="html"><![CDATA[Re: ds18b20 i lcd , wiem, wiem, bylo]]></title>

<content type="html" xml:base="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141726#p141726"><![CDATA[
Mozliwe,blad kopiowania..<br />W kodzie przecinek jest.<br />Rozwiazanie sprawdze;)<p>Statystyki: Napisane przez <a href="https://forum.atnel.pl/memberlist.php?mode=viewprofile&amp;u=3859">wchpikus</a> — 7 paź 2015, o 16:30</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[git79]]></name></author>
<updated>2015-10-07T16:26:42+01:00</updated>
<published>2015-10-07T16:26:42+01:00</published>
<id>https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141725#p141725</id>
<link href="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141725#p141725"/>
<title type="html"><![CDATA[Re: ds18b20 i lcd , wiem, wiem, bylo]]></title>

<content type="html" xml:base="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141725#p141725"><![CDATA[
chyba w dtostrf zapomniałeś przecinka przed 10<p>Statystyki: Napisane przez <a href="https://forum.atnel.pl/memberlist.php?mode=viewprofile&amp;u=10687">git79</a> — 7 paź 2015, o 16:26</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[Krauser]]></name></author>
<updated>2015-10-07T16:15:55+01:00</updated>
<published>2015-10-07T16:15:55+01:00</published>
<id>https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141723#p141723</id>
<link href="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141723#p141723"/>
<title type="html"><![CDATA[Re: ds18b20 i lcd , wiem, wiem, bylo]]></title>

<content type="html" xml:base="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141723#p141723"><![CDATA[
Nie pomogę, ale podam inne rozwiązanie bez użycia liczb zmiennoprzecinkowych:<br />[syntax=c]int8_t retd1, retd2;<br />int16_t temp;<br />temp = ( temperature_h &lt;&lt; 8 ) + temperature_l;<br />retd1 = temp * 625L /10000; //część całkowita np. -162 * 625 / 10 000 = -10 (dzielenie całkowite)<br />retd2 = temp * 625L /100 ) % 100; //cześć ułamkowa z precyzją 2 znaków np. (-162 * 625 / 100) % 100 = -1012 % 100 = -12<br />if(retd2 &lt; 0) { retd2 = -retd2; } //usunięcie &quot;-&quot; z części ułamkowej<br />lcd_locate(0, 0);<br />lcd_int(retd1);<br />if(retd2 &gt; 0) //jeśli jest część ułamkowa<br />{<br />   lcd_char(','); //przecinek<br />   if(retd2 &lt; 10) { lcd_char('0'); } //jeśli część ułamkowa jest mniejsza od 10 to poprzedź zerem<br />   lcd_int(retd2);<br />}[/syntax]<p>Statystyki: Napisane przez <a href="https://forum.atnel.pl/memberlist.php?mode=viewprofile&amp;u=465">Krauser</a> — 7 paź 2015, o 16:15</p><hr />
]]></content>
</entry>
<entry>
<author><name><![CDATA[wchpikus]]></name></author>
<updated>2015-10-07T14:26:02+01:00</updated>
<published>2015-10-07T14:26:02+01:00</published>
<id>https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141715#p141715</id>
<link href="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141715#p141715"/>
<title type="html"><![CDATA[ds18b20 i lcd , wiem, wiem, bylo]]></title>

<content type="html" xml:base="https://forum.atnel.pl/viewtopic.php?t=13150&amp;p=141715#p141715"><![CDATA[
Witajcie<br />Glupie pytanie.<br /><br />Funkcja odczytu ds zwraca mi:<br />[syntax=c]retd = ( ( temperature_h &lt;&lt; 8 ) + temperature_l ) * 0.0625;[/syntax]<br /><br />Robie sobie buffor:<br />[syntax=c]char printbuff&#91;8&#93;;<br />dtostrf(retd 10, 1, printbuff);<br />LCD_GoTo(0,1)<br />LCD_WriteText(printbuff);[/syntax]<br /><br />Niestety wynik wyswietla mi sie gdzies na srodku lcd..<br />Jak to wyswietlic od lini i znaku 0,0 na lcd?<p>Statystyki: Napisane przez <a href="https://forum.atnel.pl/memberlist.php?mode=viewprofile&amp;u=3859">wchpikus</a> — 7 paź 2015, o 14:26</p><hr />
]]></content>
</entry>
</feed>