Skip to content

Commit

Permalink
Deploy for v1.1.7
Browse files Browse the repository at this point in the history
  • Loading branch information
Hieromon committed Apr 18, 2020
1 parent 920d92b commit d39545c
Show file tree
Hide file tree
Showing 25 changed files with 355 additions and 337 deletions.
4 changes: 2 additions & 2 deletions docs/acelements.html
Original file line number Diff line number Diff line change
Expand Up @@ -2091,8 +2091,8 @@ <h3 id="type"><i class="fa fa-caret-right"></i> type<a class="headerlink" href="
<span style="color: #66d9ef">if</span> <span style="color: #f8f8f2">(elm.type()</span> <span style="color: #f92672">==</span> <span style="color: #f8f8f2">AC_Text)</span> <span style="color: #f8f8f2">{</span>
<span style="background-color: #49483e"> <span style="color: #f8f8f2">AutoConnectText</span><span style="color: #f92672">&amp;</span> <span style="color: #f8f8f2">text</span> <span style="color: #f92672">=</span> <span style="color: #f8f8f2">customPage[elm.name].as</span><span style="color: #f92672">&lt;</span><span style="color: #f8f8f2">AutoConnectText</span><span style="color: #f92672">&gt;</span><span style="color: #f8f8f2">();</span>
</span> <span style="color: #f8f8f2">text.style</span> <span style="color: #f92672">=</span> <span style="color: #e6db74">&quot;color:gray;&quot;</span><span style="color: #f8f8f2">;</span>
<span style="color: #7a7a7a">// Or, it is also possible to write the code further reduced as follows.</span>
<span style="color: #7a7a7a">// customPage[elm.name].as&lt;AutoConnectText&gt;().style = &quot;color:gray;&quot;;</span>
<span style="color: #75715e">// Or, it is also possible to write the code further reduced as follows.</span>
<span style="color: #75715e">// customPage[elm.name].as&lt;AutoConnectText&gt;().style = &quot;color:gray;&quot;;</span>
<span style="color: #f8f8f2">}</span>
<span style="color: #f8f8f2">}</span>
</code></pre></div>
Expand Down
104 changes: 52 additions & 52 deletions docs/achandling.html

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions docs/acintro.html
Original file line number Diff line number Diff line change
Expand Up @@ -988,10 +988,10 @@ <h2 id="write-the-custom-web-page-with-json">Write the custom Web page with JSON
<span style="color: #f8f8f2">]</span>
</code></pre></div></p>
<p><strong>the Sketch</strong>
<div class="codehilite" style="background: #272822"><pre style="line-height: 125%"><span></span><code><span style="color: #7a7a7a">#include</span> <span style="color: #7a7a7a">&lt;ESP8266WiFi.h&gt;</span>
<span style="color: #7a7a7a">#include</span> <span style="color: #7a7a7a">&lt;ESP8266WebServer.h&gt;</span>
<span style="color: #7a7a7a">#include</span> <span style="color: #7a7a7a">&lt;FS.h&gt;</span>
<span style="color: #7a7a7a">#include</span> <span style="color: #7a7a7a">&lt;AutoConnect.h&gt;</span>
<div class="codehilite" style="background: #272822"><pre style="line-height: 125%"><span></span><code><span style="color: #75715e">#include</span> <span style="color: #75715e">&lt;ESP8266WiFi.h&gt;</span>
<span style="color: #75715e">#include</span> <span style="color: #75715e">&lt;ESP8266WebServer.h&gt;</span>
<span style="color: #75715e">#include</span> <span style="color: #75715e">&lt;FS.h&gt;</span>
<span style="color: #75715e">#include</span> <span style="color: #75715e">&lt;AutoConnect.h&gt;</span>

<span style="color: #f8f8f2">AutoConnect</span> <span style="color: #f8f8f2">portal;</span>

Expand Down Expand Up @@ -1027,9 +1027,9 @@ <h2 id="passing-parameters-with-sketches-and-custom-web-pages">Passing parameter
</li>
<li id="fn:2">
<p>the Sketch is actually this:
<div class="codehilite" style="background: #272822"><pre style="line-height: 125%"><span></span><code><span style="color: #7a7a7a">#include</span> <span style="color: #7a7a7a">&lt;ESP8266WiFi.h&gt;</span>
<span style="color: #7a7a7a">#include</span> <span style="color: #7a7a7a">&lt;ESP8266WebServer.h&gt;</span>
<span style="color: #7a7a7a">#include</span> <span style="color: #7a7a7a">&lt;AutoConnect.h&gt;</span>
<div class="codehilite" style="background: #272822"><pre style="line-height: 125%"><span></span><code><span style="color: #75715e">#include</span> <span style="color: #75715e">&lt;ESP8266WiFi.h&gt;</span>
<span style="color: #75715e">#include</span> <span style="color: #75715e">&lt;ESP8266WebServer.h&gt;</span>
<span style="color: #75715e">#include</span> <span style="color: #75715e">&lt;AutoConnect.h&gt;</span>

<span style="color: #f8f8f2">AutoConnect</span> <span style="color: #f8f8f2">portal;</span>

Expand Down
12 changes: 6 additions & 6 deletions docs/acjson.html
Original file line number Diff line number Diff line change
Expand Up @@ -1692,11 +1692,11 @@ <h3 id="loading-from-the-streamed-file"><i class="fa fa-caret-right"></i> Loadin
An example of using each function is as follows.
<div class="codehilite" style="background: #272822"><pre style="line-height: 125%"><span></span><code><span style="color: #f8f8f2">AutoConnect</span> <span style="color: #f8f8f2">portal;</span>

<span style="color: #7a7a7a">// Loading from String</span>
<span style="color: #75715e">// Loading from String</span>
<span style="color: #66d9ef">const</span> <span style="color: #f8f8f2">String</span> <span style="color: #f8f8f2">aux</span> <span style="color: #f92672">=</span> <span style="color: #f8f8f2">String(</span><span style="color: #e6db74">&quot;{</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">title</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">:</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">Page 1 title</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">,</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">uri</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">:</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">/page1</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">,</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">menu</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">:true,</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">element</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">:[{</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">name</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">:</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">caption</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">,</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">type</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">:</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">ACText</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">,</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">value</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">:</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">hello, world</span><span style="color: #ae81ff">\&quot;</span><span style="color: #e6db74">}]}&quot;</span><span style="color: #f8f8f2">);</span>
<span style="color: #f8f8f2">portal.load(aux);</span>

<span style="color: #7a7a7a">// Loading from PROGMEM</span>
<span style="color: #75715e">// Loading from PROGMEM</span>
<span style="color: #66d9ef">const</span> <span style="color: #66d9ef">char</span> <span style="color: #f8f8f2">aux[]</span> <span style="color: #f8f8f2">PROGMEM</span> <span style="color: #f92672">=</span> <span style="color: #e6db74">R&quot;raw(</span>
<span style="color: #e6db74">{</span>
<span style="color: #e6db74"> &quot;title&quot; : &quot;Page 1 title&quot;,</span>
Expand All @@ -1713,7 +1713,7 @@ <h3 id="loading-from-the-streamed-file"><i class="fa fa-caret-right"></i> Loadin
<span style="color: #e6db74">)raw&quot;</span><span style="color: #f8f8f2">;</span>
<span style="color: #f8f8f2">portal.load(aux);</span>

<span style="color: #7a7a7a">// Loading from Stream assumes &quot;aux.json&quot; file should be store in SPIFFS.</span>
<span style="color: #75715e">// Loading from Stream assumes &quot;aux.json&quot; file should be store in SPIFFS.</span>
<span style="color: #f8f8f2">File</span> <span style="color: #f8f8f2">aux</span> <span style="color: #f92672">=</span> <span style="color: #f8f8f2">SPIFFS.open(</span><span style="color: #e6db74">&quot;aux.json&quot;</span><span style="color: #f8f8f2">,</span> <span style="color: #e6db74">&quot;r&quot;</span><span style="color: #f8f8f2">);</span>
<span style="color: #f8f8f2">portal.load(aux);</span>
<span style="color: #f8f8f2">aux.close();</span>
Expand All @@ -1722,9 +1722,9 @@ <h3 id="loading-from-the-streamed-file"><i class="fa fa-caret-right"></i> Loadin
<h3 id="adjust-the-json-document-buffer-size"><i class="fa fa-caret-right"></i> Adjust the JSON document buffer size<a class="headerlink" href="#adjust-the-json-document-buffer-size" title="Permanent link">&para;</a></h3>
<p>AutoConnect uses ArduinoJson library's dynamic buffer to parse JSON documents. Its dynamic buffer allocation scheme depends on the version 5 or version 6 of ArduinoJson library. Either version must have enough buffer to parse the custom web page's JSON document successfully. AutoConnect has the following three constants internally to complete the parsing as much as possible in both ArduinoJson version. These constants are macro defined in <a href="https://github.com/Hieromon/AutoConnect/blob/master/src/AutoConnectDefs.h">AutoConnectDefs.h</a>.</p>
<p>If memory insufficiency occurs during JSON document parsing, you can adjust these constants to avoid insufficiency by using the <a href="https://arduinojson.org/v6/assistant/">JsonAssistant</a> with deriving the required buffer size in advance.</p>
<div class="codehilite" style="background: #272822"><pre style="line-height: 125%"><span></span><code><span style="color: #7a7a7a">#define AUTOCONNECT_JSONBUFFER_SIZE 256</span>
<span style="color: #7a7a7a">#define AUTOCONNECT_JSONDOCUMENT_SIZE (8 * 1024)</span>
<span style="color: #7a7a7a">#define AUTOCONNECT_JSONPSRAM_SIZE (16* 1024)</span>
<div class="codehilite" style="background: #272822"><pre style="line-height: 125%"><span></span><code><span style="color: #75715e">#define AUTOCONNECT_JSONBUFFER_SIZE 256</span>
<span style="color: #75715e">#define AUTOCONNECT_JSONDOCUMENT_SIZE (8 * 1024)</span>
<span style="color: #75715e">#define AUTOCONNECT_JSONPSRAM_SIZE (16* 1024)</span>
</code></pre></div>

<h4 id="autoconnect_jsonbuffer_size">AUTOCONNECT_JSONBUFFER_SIZE<a class="headerlink" href="#autoconnect_jsonbuffer_size" title="Permanent link">&para;</a></h4>
Expand Down
Loading

0 comments on commit d39545c

Please sign in to comment.