<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Atom-Editor on Ulis Notizen</title>
    <link>https://wolf-u.li/tag/atom-editor/</link>
    <description>Recent content in Atom-Editor on Ulis Notizen</description>
    <generator>Hugo</generator>
    <language>de</language>
    <copyright>Copyright 2006-CURRENTYEAR Uli Wolf - All rights reserved</copyright>
    <lastBuildDate>Sun, 12 Jun 2016 15:24:07 +1200</lastBuildDate>
    <atom:link href="https://wolf-u.li/tag/atom-editor/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Nutzung von platform.io im Atom Editor zur Entwicklung von Arduino Code</title>
      
      
      <link>https://wolf-u.li/nutzung-von-platform-io-im-atom-editor-zur-entwicklung-von-arduino-code/</link>
      <pubDate>Sun, 12 Jun 2016 14:44:30 +1200</pubDate>
      <guid>https://wolf-u.li/nutzung-von-platform-io-im-atom-editor-zur-entwicklung-von-arduino-code/</guid>
      <description>&lt;p&gt;Wenn man viel Arduino Code entwickelt gehen einem schnell die Abhängigkeiten auf den Senkel. Gleichzeitig fragt man sich ob es nicht ein besser integriertes Tool für diese Art der Entwicklung gibt. Ich kann vermelden: Ja gibts ;)&lt;/p&gt;
&lt;p&gt;Zunächst installiert man sich die Umgebung genau wie &lt;link rel=dns-prefetch href=//docs.platformio.org /&gt; &lt;a href=&#34;http://docs.platformio.org/en/latest/ide/atom.html&#34;
    title=&#34;hier&#34; 
     target=&#34;_blank&#34; rel=&#34;nofollow noopener noreferrer&#34; &gt;
  hier&amp;nbsp;&lt;svg xmlns=&#34;http://www.w3.org/2000/svg&#34; class=&#34;icon&#34; aria-hidden=&#34;true&#34; focusable=&#34;false&#34; viewBox=&#34;0 -128 512 640&#34;&gt;
    &lt;path d=&#34;M384 320c-17.67 0-32 14.33-32 32v96H64V160h96c17.67 0 32-14.32 32-32s-14.33-32-32-32L64 96c-35.35 0-64 28.65-64 64V448c0 35.34 28.65 64 64 64h288c35.35 0 64-28.66 64-64v-96C416 334.3 401.7 320 384 320zM488 0H352c-12.94 0-24.62 7.797-29.56 19.75c-4.969 11.97-2.219 25.72 6.938 34.88L370.8 96L169.4 297.4c-12.5 12.5-12.5 32.75 0 45.25C175.6 348.9 183.8 352 192 352s16.38-3.125 22.62-9.375L416 141.3l41.38 41.38c9.156 9.141 22.88 11.84 34.88 6.938C504.2 184.6 512 172.9 512 160V24C512 10.74 501.3 0 488 0z&#34;/&gt;
  &lt;/svg&gt;&lt;/a&gt; beschrieben. Damit hat man dann schon die meisten Voraussetzungen geschaffen. Ein neues Projekt geht relativ einfach von der Hand:&lt;/p&gt;</description>
      
         <content:encoded><![CDATA[<p>Wenn man viel Arduino Code entwickelt gehen einem schnell die Abhängigkeiten auf den Senkel. Gleichzeitig fragt man sich ob es nicht ein besser integriertes Tool für diese Art der Entwicklung gibt. Ich kann vermelden: Ja gibts ;)</p>
<p>Zunächst installiert man sich die Umgebung genau wie <link rel=dns-prefetch href=//docs.platformio.org /> <a href="http://docs.platformio.org/en/latest/ide/atom.html"
    title="hier" 
     target="_blank" rel="nofollow noopener noreferrer" >
  hier&nbsp;<svg xmlns="http://www.w3.org/2000/svg" class="icon" aria-hidden="true" focusable="false" viewBox="0 -128 512 640">
    <path d="M384 320c-17.67 0-32 14.33-32 32v96H64V160h96c17.67 0 32-14.32 32-32s-14.33-32-32-32L64 96c-35.35 0-64 28.65-64 64V448c0 35.34 28.65 64 64 64h288c35.35 0 64-28.66 64-64v-96C416 334.3 401.7 320 384 320zM488 0H352c-12.94 0-24.62 7.797-29.56 19.75c-4.969 11.97-2.219 25.72 6.938 34.88L370.8 96L169.4 297.4c-12.5 12.5-12.5 32.75 0 45.25C175.6 348.9 183.8 352 192 352s16.38-3.125 22.62-9.375L416 141.3l41.38 41.38c9.156 9.141 22.88 11.84 34.88 6.938C504.2 184.6 512 172.9 512 160V24C512 10.74 501.3 0 488 0z"/>
  </svg></a> beschrieben. Damit hat man dann schon die meisten Voraussetzungen geschaffen. Ein neues Projekt geht relativ einfach von der Hand:</p>
<ul>
<li>Zunächst klingt man im Menü auf &ldquo;PlatformIO&rdquo; und wählt &ldquo;Initialize new PlatformIO Project or modify existing&rdquo;</li>
<li>Nach der Auswahl der/den gewünschten Zielplatform(en) und des Ordners ergibt sich die Struktur des Projektes
<img src="/upload/2016/06/5668-platformio-folders.webp" alt="5668-platformio-folders" loading="lazy"></li>
<li>Im Ordner src legt man nun die Quellcodes an, allerdings mit der Endung .cpp damit alles (autocomplete und syntax-check) klappt ;)</li>
<li>Nun kann man mit einem Klick auf den Upload-Button die Kompilierung und den Upload auf den Arduino/ESP8266 anwerfen:
<img src="/upload/2016/06/5668-platformio-upload.webp" alt="5668-platformio-upload" loading="lazy"></li>
<li>Benötigt man weitere Bibliotheken, sucht man sich zunächst hier die richtige raus (Das ist eine Nummer) und fügt diese dann im projekt in der platformio.ini im entsprechenden environment ein, was dann etwa so aussieht:
<img src="/upload/2016/06/5668-platformio.ini_.webp" alt="5668-platformio.ini" loading="lazy">
Tipp: Direkt den Library Namen mit Nummer als Kommentar (wie im Screenshot) einfügen - dann weiss man hinterher noch was welche Bibliothek ist.</li>
</ul>
<p>Übrigens kann man auch OTA (Over The Air) Updates mit platform.io durchführen - dazu muss man dann nur die <link rel=dns-prefetch href=//docs.platformio.org /> <a href="http://docs.platformio.org/en/latest/projectconf.html?highlight=upload_port#upload-port#upload-port"
    title="upload_port" 
     target="_blank" rel="nofollow noopener noreferrer" >
  upload_port&nbsp;<svg xmlns="http://www.w3.org/2000/svg" class="icon" aria-hidden="true" focusable="false" viewBox="0 -128 512 640">
    <path d="M384 320c-17.67 0-32 14.33-32 32v96H64V160h96c17.67 0 32-14.32 32-32s-14.33-32-32-32L64 96c-35.35 0-64 28.65-64 64V448c0 35.34 28.65 64 64 64h288c35.35 0 64-28.66 64-64v-96C416 334.3 401.7 320 384 320zM488 0H352c-12.94 0-24.62 7.797-29.56 19.75c-4.969 11.97-2.219 25.72 6.938 34.88L370.8 96L169.4 297.4c-12.5 12.5-12.5 32.75 0 45.25C175.6 348.9 183.8 352 192 352s16.38-3.125 22.62-9.375L416 141.3l41.38 41.38c9.156 9.141 22.88 11.84 34.88 6.938C504.2 184.6 512 172.9 512 160V24C512 10.74 501.3 0 488 0z"/>
  </svg></a> Directive in der Konfigurationsdatei setzen und den entsprechenden Code (<link rel=dns-prefetch href=//github.com /> <a href="https://github.com/esp8266/Arduino/blob/master/libraries/ArduinoOTA/examples/BasicOTA/BasicOTA.ino"
    title="Beispiel" 
     target="_blank" rel="nofollow noopener noreferrer" >
  Beispiel&nbsp;<svg xmlns="http://www.w3.org/2000/svg" class="icon" aria-hidden="true" focusable="false" viewBox="0 -128 512 640">
    <path d="M384 320c-17.67 0-32 14.33-32 32v96H64V160h96c17.67 0 32-14.32 32-32s-14.33-32-32-32L64 96c-35.35 0-64 28.65-64 64V448c0 35.34 28.65 64 64 64h288c35.35 0 64-28.66 64-64v-96C416 334.3 401.7 320 384 320zM488 0H352c-12.94 0-24.62 7.797-29.56 19.75c-4.969 11.97-2.219 25.72 6.938 34.88L370.8 96L169.4 297.4c-12.5 12.5-12.5 32.75 0 45.25C175.6 348.9 183.8 352 192 352s16.38-3.125 22.62-9.375L416 141.3l41.38 41.38c9.156 9.141 22.88 11.84 34.88 6.938C504.2 184.6 512 172.9 512 160V24C512 10.74 501.3 0 488 0z"/>
  </svg></a>) im eigenen Quellcode mit einbinden.</p>
<p>Eine wichtige Funktion noch: Der Serielle Monitor wird auch direkt mitgesteuert. D.h. wenn man diesen offen hat und einen Upload macht, dann wird zunächst der Monitor gestopped, dann der Upload durchgeführt und anschließend der Monitor wieder gestartet. Sehr coole Sache, was doch viele Klicks spart ;)</p>
]]></content:encoded>
    </item>
  </channel>
</rss>
