Skip to content

Commit

Permalink
发布core(V0035)和script_LuaTask(V2.3.3)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhutianhua committed Jul 24, 2019
1 parent 3af73ef commit ab9fd02
Show file tree
Hide file tree
Showing 57 changed files with 455 additions and 152 deletions.
11 changes: 10 additions & 1 deletion core/release notes.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
版本号:Luat_V0034_8955_XXX.lod
版本号:Luat_V0035_8955_XXX.lod
发布时间:2019/07/24 14:15
修改记录:
(1)修正“aes和des加密时,不填充方式加密错误”的问题
(2)修正“aes和des加密时内存泄漏”的问题
(3)新增pio.pin.setbounce接口,可设置中断防抖时间;在设置中断前调用有效,例如pio.pin.setbounce(10),表示中断防抖时间为10ms



版本号:Luat_V0034_8955_XXX.lod
发布时间:2019/05/24 13:50
修改记录:
(1)支持SHA256算法,使用说明参考crypto脚本的demo
Expand Down
27 changes: 11 additions & 16 deletions script_LuaTask/demo/console/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,7 @@ console.setup(1, 115200)
require "httpv2"
require "pins"
require "gpsv2"
pins.setup(pio.P0_28, 1)
local pwb = pins.setup(pio.P0_3, nil, pio.PULLDOWN)
sys.timerStart(function()
pwb(0)
rtos.poweroff()
end, 10000)
-- require "tm1637"
--加载硬件看门狗功能模块
--根据自己的硬件配置决定:1、是否加载此功能模块;2、配置Luat模块复位单片机引脚和互相喂狗引脚
--合宙官方出售的Air201开发板上有硬件看门狗,所以使用官方Air201开发板时,必须加载此功能模块
Expand All @@ -51,16 +46,16 @@ wdt.setup(pio.P0_30, pio.P0_31)
--require "netLed"
--netLed.setup(true,pio.P1_1)
--网络指示灯功能模块中,默认配置了各种工作状态下指示灯的闪烁规律,参考netLed.lua中ledBlinkTime配置的默认值
--如果默认值满足不了需求,此处调用netLed.updateBlinkTime去配置闪烁时长
--加载错误日志管理功能模块【强烈建议打开此功能】
--如下2行代码,只是简单的演示如何使用errDump功能,详情参考errDump的api
require "errDump"
errDump.request("udp://ota.airm2m.com:9072")

--加载远程升级功能模块【强烈建议打开此功能】
--如下3行代码,只是简单的演示如何使用update功能,详情参考update的api以及demo/update
--PRODUCT_KEY = "v32xEAKsGTIEQxtqgwCldp5aPlcnPs3K"
--require "update"
--如果默认值满足不了需求,此处调用netLed.updateBlinkTime去配置闪烁时长
--加载错误日志管理功能模块【强烈建议打开此功能】
--如下2行代码,只是简单的演示如何使用errDump功能,详情参考errDump的api
require "errDump"
errDump.request("udp://ota.airm2m.com:9072")

--加载远程升级功能模块【强烈建议打开此功能】
--如下3行代码,只是简单的演示如何使用update功能,详情参考update的api以及demo/update
--PRODUCT_KEY = "v32xEAKsGTIEQxtqgwCldp5aPlcnPs3K"
--require "update"
--update.request()
--加载GPS功能测试模块
--启动系统框架
Expand Down
6 changes: 3 additions & 3 deletions script_LuaTask/demo/uart/v3/demo.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ module(..., package.seeall)
-- 串口ID,串口读缓冲区
local UART_ID, sendQueue = 1, {}
-- 串口超时,串口准备好后发布的消息
local uartimeout, recvReady = 25, "UART_RECV_ID"
local uartimeout, recvReady = 500, "UART_RECV_ID"
--保持系统处于唤醒状态,不会休眠
pm.wake("mcuart")
uart.setup(UART_ID, 115200, 8, uart.PAR_NONE, uart.STOP_1)
uart.on(1, "receive", function(uid)
table.insert(sendQueue, uart.read(uid, 1460))
uart.on(1, "receive", function(uid, length)
table.insert(sendQueue, uart.read(uid, length))
sys.timerStart(sys.publish, uartimeout, recvReady)
end)

Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ <h2>Modules</h2>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/aLiPay.html
Original file line number Diff line number Diff line change
Expand Up @@ -506,7 +506,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
95 changes: 94 additions & 1 deletion script_LuaTask/doc/lib/modules/aLiYun.html
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,24 @@ <h3>Info:</h3>

<h2><a href="#Functions">Functions</a></h2>
<table class="function_list">
<tr>
<td class="name" nowrap><a href="#sleep">
sleep ()
</a></td>
<td class="summary">断开阿里云物联网套件的连接,并且不再重连</td>
</tr>
<tr>
<td class="name" nowrap><a href="#wakeup">
wakeup ()
</a></td>
<td class="summary">重新打开阿里云物联网套件的连接</td>
</tr>
<tr>
<td class="name" nowrap><a href="#sleepStatus">
sleepStatus ()
</a></td>
<td class="summary">查看打开阿里云物联网套件的是否允许连接状态</td>
</tr>
<tr>
<td class="name" nowrap><a href="#setup">
setup (productKey<strong style="color: gray;">[, productSecret=nil]</strong>, getDeviceNameFnc, getDeviceSecretFnc<strong style="color: gray;">[, setDeviceSecretFnc=nil]</strong>)
Expand Down Expand Up @@ -141,6 +159,81 @@ <h2><a href="#Functions">Functions</a></h2>
<h2 class="section-header "><a name="Functions"></a>Functions</h2>

<dl class="function">
<dt>
<a name = "sleep"></a>
<strong style="color: red;">
sleep ()
</strong>
</dt>
<dd>
<pre class="example" style="color: red;">断开阿里云物联网套件的连接,并且不再重连</pre>



<h3>Returns:</h3>
<ul>
<li>
<pre class="example">nil</pre></il>
</ul>



<h3>Usage:</h3>
<ul>
<li><pre class="example">aLiYun.sleep()</pre></il>
</ul>

</dd>
<dt>
<a name = "wakeup"></a>
<strong style="color: red;">
wakeup ()
</strong>
</dt>
<dd>
<pre class="example" style="color: red;">重新打开阿里云物联网套件的连接</pre>



<h3>Returns:</h3>
<ul>
<li>
<pre class="example">nil</pre></il>
</ul>



<h3>Usage:</h3>
<ul>
<li><pre class="example">aLiYun.wakeup()</pre></il>
</ul>

</dd>
<dt>
<a name = "sleepStatus"></a>
<strong style="color: red;">
sleepStatus ()
</strong>
</dt>
<dd>
<pre class="example" style="color: red;">查看打开阿里云物联网套件的是否允许连接状态</pre>



<h3>Returns:</h3>
<ul>
<li>
<pre class="example">bool 是否允许连接阿里云</pre></il>
</ul>



<h3>Usage:</h3>
<ul>
<li><pre class="example"><span class="keyword">local</span> ar = aLiYun.sleepStatus()</pre></il>
</ul>

</dd>
<dt>
<a name = "setup"></a>
<strong style="color: red;">
Expand Down Expand Up @@ -375,7 +468,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/aLiYunOta.html
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/agps.html
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ <h3>Info:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
18 changes: 15 additions & 3 deletions script_LuaTask/doc/lib/modules/audio.html
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ <h2><a href="#Functions">Functions</a></h2>
</tr>
<tr>
<td class="name" nowrap><a href="#stop">
stop ()
stop (<strong style="color: gray;">[cbFnc=nil]</strong>)
</a></td>
<td class="summary">停止音频播放</td>
</tr>
Expand Down Expand Up @@ -220,13 +220,25 @@ <h3>Usage:</h3>
<dt>
<a name = "stop"></a>
<strong style="color: red;">
stop ()
stop (<strong style="color: green;">[cbFnc=nil]</strong>)
</strong>
</dt>
<dd>
<pre class="example" style="color: red;">停止音频播放</pre>


<h3>Parameters:</h3>
<ul>
<li><span class="parameter">cbFnc</span>
<span class="types"><span class="type">function</span></span>
[<em>此参数可选,默认值为:</em> nil]
<pre class="example">停止音频播放的回调函数(停止结果通过此函数通知用户),回调函数的调用形式为:
cbFnc(result)
result:number类型
0表示停止成功
1表示之前已经发送了停止动作,请耐心等待停止结果的回调</pre>
</li>
</ul>

<h3>Returns:</h3>
<ul>
Expand Down Expand Up @@ -346,7 +358,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/cc.html
Original file line number Diff line number Diff line change
Expand Up @@ -585,7 +585,7 @@ <h2 class="section-header "><a name="Fields"></a>Fields</h2>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/clib.html
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/common.html
Original file line number Diff line number Diff line change
Expand Up @@ -723,7 +723,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/console.html
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/errDump.html
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/gizwits.html
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
2 changes: 1 addition & 1 deletion script_LuaTask/doc/lib/modules/gps.html
Original file line number Diff line number Diff line change
Expand Up @@ -1329,7 +1329,7 @@ <h2 class="section-header "><a name="Fields"></a>Fields</h2>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
32 changes: 30 additions & 2 deletions script_LuaTask/doc/lib/modules/gpsv2.html
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,12 @@ <h2><a href="#Functions">Functions</a></h2>
</a></td>
<td class="summary">获取GPSGSV解析后的CNO数据</td>
</tr>
<tr>
<td class="name" nowrap><a href="#openLog">
openLog (v)
</a></td>
<td class="summary">是否显示日志</td>
</tr>
</table>

<br/>
Expand Down Expand Up @@ -299,7 +305,7 @@ <h3>Usage:</h3>
<ul>
<li><pre class="example">gpsv2.open()</pre></il>
<li><pre class="example">gpsv2.open(<span class="number">2</span>, <span class="number">115200</span>, <span class="number">0</span>, <span class="number">1</span>) <span class="comment">-- 打开GPS,串口2,波特率115200,正常功耗模式,1秒1个点</span></pre></il>
<li><pre class="example">gpsv2.open(<span class="number">2</span>, <span class="number">115200</span>, <span class="number">2</span>, <span class="number">1</span>, <span class="number">5</span>) <span class="comment">-- 打开GPS,串口2,波特率115200,周期低功耗模式1秒输出,5秒睡眠</span></pre></il>
<li><pre class="example">gpsv2.open(<span class="number">2</span>, <span class="number">115200</span>, <span class="number">2</span>, <span class="number">5</span>) <span class="comment">-- 打开GPS,串口2,波特率115200,周期低功耗模式1秒输出,5秒睡眠</span></pre></il>
</ul>

</dd>
Expand Down Expand Up @@ -923,6 +929,28 @@ <h3>Usage:</h3>



</dd>
<dt>
<a name = "openLog"></a>
<strong style="color: red;">
openLog (v)
</strong>
</dt>
<dd>
<pre class="example" style="color: red;">是否显示日志</pre>


<h3>Parameters:</h3>
<ul>
<li><span class="parameter">v</span>
<pre class="example"></pre>
</li>
</ul>





</dd>
</dl>

Expand All @@ -931,7 +959,7 @@ <h3>Usage:</h3>
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
<i style="float:right;">Last updated 2019-05-24 14:23:11 </i>
<i style="float:right;">Last updated 2019-07-24 14:51:23 </i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
Expand Down
Loading

0 comments on commit ab9fd02

Please sign in to comment.