mirror of
https://github.com/luc-github/ESP3D.git
synced 2025-10-24 11:50:52 -07:00
fix missing sanity check if BT
This commit is contained in:
@@ -36,7 +36,7 @@
|
|||||||
#if COMMUNICATION_PROTOCOL == SOCKET_SERIAL
|
#if COMMUNICATION_PROTOCOL == SOCKET_SERIAL
|
||||||
#include "../modules/serial2socket/serial2socket.h"
|
#include "../modules/serial2socket/serial2socket.h"
|
||||||
#endif // COMMUNICATION_PROTOCOL ==SOCKET_SERIAL
|
#endif // COMMUNICATION_PROTOCOL ==SOCKET_SERIAL
|
||||||
#if defined(WIFI_FEATURE) || defined(ETH_FEATURE)
|
#if defined(WIFI_FEATURE) || defined(ETH_FEATURE) || defined(BLUETOOTH_FEATURE)
|
||||||
#include "../modules/network/netconfig.h"
|
#include "../modules/network/netconfig.h"
|
||||||
#endif // WIFI_FEATURE || ETH FEATURE
|
#endif // WIFI_FEATURE || ETH FEATURE
|
||||||
#if defined(FILESYSTEM_FEATURE)
|
#if defined(FILESYSTEM_FEATURE)
|
||||||
|
|||||||
@@ -22,7 +22,7 @@
|
|||||||
#define _VERSION_ESP3D_H
|
#define _VERSION_ESP3D_H
|
||||||
|
|
||||||
// version and sources location
|
// version and sources location
|
||||||
#define FW_VERSION "3.0.0.7b1"
|
#define FW_VERSION "3.0.0.8b1"
|
||||||
#define REPOSITORY "https://github.com/luc-github/ESP3D/tree/3.0"
|
#define REPOSITORY "https://github.com/luc-github/ESP3D/tree/3.0"
|
||||||
|
|
||||||
#endif //_VERSION_ESP3D_H
|
#endif //_VERSION_ESP3D_H
|
||||||
|
|||||||
26
lua_script_examples/echo-serial/echo-serial.lua
Normal file
26
lua_script_examples/echo-serial/echo-serial.lua
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
--[[
|
||||||
|
Echo Serial
|
||||||
|
|
||||||
|
This example echo serial outout to serial with echo: header
|
||||||
|
Put this script in the ESP3D flash file system and call it from the init script in
|
||||||
|
configuration.h.
|
||||||
|
#define ESP_AUTOSTART_SCRIPT "[ESP300]/FS/detectpush.lua"
|
||||||
|
|
||||||
|
Be sure to have the following line comment out in the configure.h:
|
||||||
|
#define ESP_LUA_INTERPRETER_FEATURE
|
||||||
|
]]--
|
||||||
|
|
||||||
|
-- Setup
|
||||||
|
local availableMsg = 0
|
||||||
|
local message = ""
|
||||||
|
while (true) do
|
||||||
|
-- check if have data
|
||||||
|
availableMsg = available()
|
||||||
|
-- if any message
|
||||||
|
if (availableMsg > 0) then
|
||||||
|
message = "echo:" .. readData()
|
||||||
|
print(message)
|
||||||
|
end
|
||||||
|
-- yield to other tasks
|
||||||
|
yield()
|
||||||
|
end
|
||||||
Reference in New Issue
Block a user