Version 3.X
This version is the development version, features can change anytime, feedback, PR and suggestions are welcome.
This version need currently a fork of Marlin
It is already part of Marlin distribution, check how to enable it
This version is the development version, features can change anytime, feedback, PR and suggestions are welcome.
This version need currently a fork of Marlin
It is already part of Marlin distribution, check how to enable it
The V3.X features are :
In Marlin configuration files :
Select an ESP32 based board.
Uncomment the second serial port to allow esp3d to get all printer feedback
/**
* Select a secondary serial port on the board to use for communication with the host.
* :[-1, 0, 1, 2, 3, 4, 5, 6, 7]
*/
#define SERIAL_PORT_2 -1
Enable ESP3DLib support using :
#define ESP3D_WIFISUPPORT // ESP3D Library WiFi management (https://github.com/luc-github/ESP3DLib)
You can optionnaly define to which access point your board need to connect to:
#define WIFI_SSID "Wifi SSID"
#define WIFI_PWD "Wifi Password"
if not defined or you left like this the board will act as an Access Point instead. and you can do further configuration using command line or web interface.
Please be sure these setting are enabled they are mandatory for ESP3DLib
#define WEBSUPPORT // Start a webserver (which may include auto-discovery)
#define WIFI_CUSTOM_COMMAND // Accept feature config commands (e.g., WiFi ESP3D) from the host|
#define CUSTOM_SD_ACCESS // Enable another lib accessing the SD card without conflicts
Web Update is supported by ESP3DLib but you can also use:
#define OTASUPPORT // Support over-the-air firmware updates
To enable the authentication feature which is disabled by default:
//AUTHENTICATION_FEATURE: protect pages by login password.
#define AUTHENTICATION_FEATURE
to disable any of these features which are enabled by default:
//MDNS_FEATURE: this feature allow type the name defined
//in web browser by default: http:\\marlinesp.local and connect
#define DISABLE_MDNS_FEATURE
//SSDD_FEATURE: this feature is a discovery protocol, supported on Windows out of the box
//Rely on Configuration_adv.h
#define DISABLE_SSDP_FEATURE
//CAPTIVE_PORTAL_FEATURE: In SoftAP redirect all unknow call to main page
#define DISABLE_CAPTIVE_PORTAL_FEATURE
The documentation section will help you on:
Syntax and parameters
What is authentication in ESP3D?
Setup and configuration
Update feature description
FTP usage and configuration
WebDav usage and configuration
Frequent asked questions and their answers
API description
1 - Add space to separate parameters
2 - If parameter has space add \
in front of space to not be seen as separator
3 - json
, json=YES
, json=TRUE
, json=1
are paremeters to switch output to json
By default output is plain text, to get json formated output add json or json=yes after main parameters.
The json format is:
{
cmd:"<command id>", //the id of requested command
status:"<ok/error>" //give if it is success or an failure
data:"<response>" // response corresponding to answer in json format too
}
[ESP]<command id> json=<no>
Set / Display Station SSID
Set Station Password
Set / Display Station IP mode
Set / Display Station IP address
Set station fallback mode state at boot
Set / Display Access point SSID
Set Access point password
Set / Display Access point IP value
Set / Display Access point channel value
Set / Display radio state at boot
Display current IP
Set / Display Hostname
Get/Set Boot radio state
Get/Set immediate Network state
Get/Set HTTP state
Get/Set HTTP port
Get/Set TELNET state
Get/Set TELNET port
Sync / Set / Get current time
Get/Set boot delay in ms / Verbose boot
Get/Set WebSocket state
Get/Set WebSocket port
Get/Set Camera commands/values
Save frame to target path and filename
Get/Set Ftp state
Get/Set Ftp ports
Get/Set WebDav state
Get/Set WebDav port
Get/Set SD state
Get/Set pin value
Get/Set SD card Speed factor
Get/Set Sensor Value / type
Output to ESP3D screen status
Start a Touch Calibration
Get ESP3D pins definition
Play sound
Delay/Pause command
Get full ESP3D settings
Set ESP3D settings
Get/Set SD updater check at boot time
List all AP detected around
Get ESP3D current status
Set ESP3D state
List available ESP3D modules/ ESP3D related devices around
Get authentication status
Set/Get session timeout
Set/Change admin password
Set/Change user password
Send Notification
Set/Get Notification settings
Send Notification using encodded URL
Process local file on /FS or /SD
Query and Control ESP700 stream
Format ESP Filesystem
Format SD Card
List files on /FS or defined repository
Do some actions on ESP Filesystem: rmdir / remove / mkdir / exists / create
List files on /SD or defined repository
Do some actions on SD Card: rmdir / remove / mkdir / exists / create
List Global Filesystem
Do some actions on Global Filesystem: rmdir / remove / mkdir / exists / create
Get ESP3D fw capabilities
Get / Set state for main serial communication
Set Serial baudrate for main serial communication
Get / Set state for buzzer
Get / Set state for Serial Bridge
Get / Set baudrate for Serial Bridge
Set quiet boot
Set / Display Station SSID
[ESP100]<SSID> json=<no> pwd=<admin/user password>
json=no
the output format
can be in JSON or plain text
pwd= the admin password if authentication is enabled
SSID
{
"cmd":"100",
"status":"ok",
"data":"esp3d"
}
cmd
Id of requested command, should be 100
status
status of command, should be ok
data
content of response, here the SSIDSet Station Password
[ESP101]<password> <NOPASSWORD> json=<no> pwd=<admin/user password>
json=no
the output format
can be in JSON or plain text
pwd= the admin password if authentication is enabled
password
NOPASSWORD
if password is empty and NOPASSWORD is not present, it will raise error: `Password not displayable``
{
"cmd":"101",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 101
status
status of command, should be ok
data
content of response, here ok
if error :
{
"cmd":"101",
"status":"error",
"data":"Password not displayable"
}
error: Password not displayable
Set / Display Station IP mode
[ESP102]<mode> json=<no> pwd=<admin/user password>
json=no
the output format
can be in JSON or plain text
pwd= the admin password if authentication is enabled
mode
DHCP
or STATIC
{
"cmd":"102",
"status":"ok",
"data":"DHCP"
}
cmd
Id of requested command, should be 102
status
status of command, should be ok
data
content of response, here the modeSet / Display Station IP address
[ESP103]IP=<IP> MSK=<IP> GW=<IP> DNS=<IP> json=<no> pwd=<admin/user password>
json=no
the output format
can be in JSON or plain text
pwd= the admin password if authentication is enabled
IP
MSK
GW
DNS
{
"cmd": "103",
"status": "ok",
"data": {
"ip": "192.168.0.1",
"gw": "192.168.0.1",
"msk": "255.255.255.0",
"dns": "192.168.0.1"
}
}
cmd
Id of requested command, should be 103
status
status of command, should be ok
data
content of response, here the IP, GW, MSK and DNSSet station fallback mode state at boot which can be BT, WIFI-SETUP, OFF
[ESP104]<mode> json=<no> pwd=<admin/user password>
json=no
the output format
can be in JSON or plain text
pwd= the admin password if authentication is enabled
mode
BT
, WIFI-SETUP
or OFF
{
"cmd":"104",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 104
status
status of command, should be ok
data
content of response, here the modeSet / Display Access point SSID
[ESP105]<SSID> json=<no> pwd=<admin/user password>
json=no
the output format
can be in JSON or plain text
pwd= the admin password if authentication is enabled
SSID
{
"cmd":"105",
"status":"ok",
"data":"esp3d"
}
cmd
Id of requested command, should be 105
status
status of command, should be ok
data
content of response, here the SSIDSet Access point password
[ESP106]<password> <NOPASSWORD> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
password
NOPASSWORD
if password is empty and NOPASSWORD is not present, it will raise error: `Password not displayable``
{
"cmd":"106",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 106
status
status of command, should be ok
data
content of response, here ok
Set / Display Access point IP value
[ESP107]<IP> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
IP
{
"cmd":"107",
"status":"ok",
"data":"192.168.0.1"
}
cmd
Id of requested command, should be 107
status
status of command, should be ok
data
content of response, here the IPSet / Display Access point channel value
[ESP108]<channel> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
channel
{
"cmd":"108",
"status":"ok",
"data":"1"
}
cmd
Id of requested command, should be 108
status
status of command, should be ok
data
content of response, here the channelSet / display radio state at boot which can be BT, WIFI-STA, WIFI-AP, ETH-STA, OFF
[ESP110]<mode> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
mode
BT
, WIFI-STA
, WIFI-AP
, ETH-STA
or OFF
{
"cmd":"110",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 110
status
status of command, should be ok
data
content of response, here the modeDisplay current IP
[ESP111]<OUTPUT=PRINTER> <ALL> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
OUTPUT
192.168.0.1
PRINTER
, it will display current IP in printer format M117 192.168.0.1
ALL
{
"cmd":"111",
"status":"ok",
"data":"192.168.0.1"
}
cmd
Id of requested command, should be 111
status
status of command, should be ok
data
content of response, here the IPSet / Display Hostname
[ESP112]<hostname> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
hostname
{
"cmd":"112",
"status":"ok",
"data":"esp3d"
}
cmd
Id of requested command, should be 112
status
status of command, should be ok
data
content of response, here the hostnameGet/Set Boot radio state which can be ON, OFF
[ESP114]<mode> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
mode
ON
or OFF
{
"cmd":"114",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 114
status
status of command, should be ok
data
content of response, here the modeGet/Set immediate Network (WiFi/BT/Ethernet) state which can be ON, OFF
[ESP115]<mode> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
mode
ON
or OFF
{
"cmd":"115",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 115
status
status of command, should be ok
data
content of response, here the modeGet/Set HTTP state which can be ON, OFF
[ESP120]<mode> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
mode
ON
or OFF
{
"cmd":"120",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 120
status
status of command, should be ok
data
content of response, here the modeGet/Set HTTP port
[ESP121]<port> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
port
{
"cmd":"121",
"status":"ok",
"data":"80"
}
cmd
Id of requested command, should be 121
status
status of command, should be ok
data
content of response, here the portGet/Set TELNET state which can be ON, OFF, CLOSE
[ESP130]<mode> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
mode
ON
, OFF
or CLOSE
{
"cmd":"130",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 130
status
status of command, should be ok
data
content of response, here the modeGet/Set TELNET port
[ESP131]<port> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
port
{
"cmd":"131",
"status":"ok",
"data":"23"
}
cmd
Id of requested command, should be 131
status
status of command, should be ok
data
content of response, here the portSync / Set / Get current time
[ESP140]<SYNC> <srv1=XXXXX> <srv2=XXXXX> <srv3=XXXXX> <tzone=+HH:SS> <ntp=YES/NO> <time=YYYY-MM-DDTHH:mm:ss> NOW json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
srv1 / srv2 / srv3
tzone
time
ntp
SYNC
NOW
{
"cmd":"140",
"status":"ok",
"data":"2020-01-01T00:00:00 (+08:00)"
}
cmd
Id of requested command, should be 140
status
status of command, should be ok
data
content of response, here the timeGet/Set boot delay in ms / Verbose boot
[ESP150]<delay=time in milliseconds> <verbose=ON/OFF> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
delay
verbose
{
"cmd":"150",
"status":"ok",
"data": {
"delay": "100",
"verbose": "OFF"
}
}
cmd
Id of requested command, should be 150
status
status of command, should be ok
data
content of response, here the delay and verbose stateGet/Set WebSocket state which can be ON, OFF, CLOSE
[ESP160]<mode> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
mode
ON
, OFF
or CLOSE
{
"cmd":"160",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 160
status
status of command, should be ok
data
content of response, here the modeGet/Set WebSocket port
[ESP161]<port> json=<no> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
port
{
"cmd":"161",
"status":"ok",
"data":"81"
}
cmd
Id of requested command, should be 161
status
status of command, should be ok
data
content of response, here the portGet /Set Camera command value / list all values in JSON/plain text
[ESP170]<label=value> <json=no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
label
label can be: light/framesize/quality/contrast/brightness/saturation/gainceiling/colorbar/awb/agc/aec/hmirror/vflip/awb_gain/agc_gain/aec_value/aec2/cw/bpc/wpc/raw_gma/lenc/special_effect/wb_mode/ae_level
value depend on label
{
"cmd":"170",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 170
status
status of command, should be ok
data
content of response, here ok
Save frame to target path and filename (default target = today date, default name=timestamp.jpg)
[ESP171]<json=no> path=<target path> filename=<target filename> pwd=<admin/user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
path
filename
{
"cmd":"171",
"status":"ok",
"data":"Snapshot taken"
}
cmd
Id of requested command, should be 171
status
status of command, should be ok
data
content of response, here Snapshot taken
Get/Set Ftp state which can be ON, OFF, CLOSE
[ESP180]<state> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
state
{
"cmd":"180",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 180
status
status of command, should be ok
data
content of response, here the stateGet/Set Ftp ports
ESP181]ctrl=<port> active=<port> passive=<port> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
ctrl
active
passive
{
"cmd":"181",
"status":"ok",
"data":{
"ctrl":"21",
"active":"50000",
"passive":"50001"
}
}
Set WebDav state which can be ON, OFF, CLOSE
[ESP190]<state> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
state
{
"cmd":"190",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 190
status
status of command, should be ok
data
content of response, here the stateGet/Set WebDav port
[ESP191]<port> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
{
"cmd":"191",
"status":"ok",
"data":"80"
}
cmd
Id of requested command, should be 191
status
status of command, should be ok
data
content of response, here the portGet/Set SD state
[ESP200] json=<YES/NO> <RELEASESD> <REFRESH> pwd=<user/admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
RELEASESD
REFRESH
{
"cmd":"200",
"status":"ok",
"data":"ok"
}
states can be : Busy
. "Not available
, ok
, No SD card
cmd
Id of requested command, should be 200
status
status of command, should be ok
data
content of response, here ok
Get/Set pin value
[ESP201]P=<pin> V=<value> <json=YES/NO> <PULLUP=YES> <RAW=YES> <ANALOG=NO> <ANALOG_RANGE=255> pwd=<admin password> Range can be 255 / 1024 / 2047 / 4095 / 8191
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
P
V
RAW
PULLUP
ANALOG
ANALOG_RANGE
{
"cmd":"201",
"status":"ok",
"data":"1"
}
cmd
Id of requested command, should be 201
status
status of command, should be ok
data
content of response, here the pin value is 1 or HighGet/Set SD card Speed factor 1 2 4 6 8 16 32
[ESP202]SPEED=<factor> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
SPEED=
{
"cmd":"202",
"status":"ok",
"data":"1"
}
cmd
Id of requested command, should be 202
status
status of command, should be ok
data
content of response, here the current SPI factorGet Sensor Value / type/Set Sensor type
[ESP210]<type=NONE/xxx> <interval=XXX in millisec> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
type
interval
{
"cmd":"210",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 210
status
status of command, should be ok
data
content of response, here ok
Output to esp screen status
[ESP214]<Text> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
Text
{
"cmd":"214",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 214
status
status of command, should be ok
data
content of response, here ok
Start a Touch Calibration
[ESP215]<CALIBRATE> json=<no> pwd=<admin password>
json=no the output format
pwd= the admin password if authentication is enabled
CALIBRATE
{
"cmd":"215",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 215
status
status of command, should be ok
data
content of response, here ok
Get ESP3D pins definition
[ESP220] json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
{
"cmd": "220",
"status": "ok",
"data": [
{
"id": "SD CS",
"value": "13"
},
{
"id": "SD MOSI",
"value": "15"
},
{
"id": "SD MISO",
"value": "2"
},
{
"id": "SD SCK",
"value": "14"
},
{
"id": "SD DETECT",
"value": "-1"
},
{
"id": "SD SWITCH",
"value": "26"
}
]
}
cmd
Id of requested command, should be 220
status
status of command, should be ok
data
content of response, here the pins definitionsSD CS: 13
SD MOSI: 15
SD MISO: 2
SD SCK: 14
SD DETECT: -1
SD SWITCH: 26
Play sound
[ESP250]F=<frequency> D=<duration> json=<no> pwd=<user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
F
D
{
"cmd":"250",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 250
status
status of command, should be ok
data
content of response, here ok
Delay/Pause command
[ESP290]<delay in ms> json=<no> pwd=<user password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
delay
{
"cmd":"290",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 290
status
status of command, should be ok
data
content of response, here ok
Get full ESP3D settings
[ESP400] json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
Passwords are not displayed and replaced by ********
{"cmd":"400","status":"ok","data":[
{"F":"network/network","P":"130","T":"S","R":"1","V":"esp3d","H":"hostname" ,"S":"32", "M":"1"},
{"F":"network/network","P":"0","T":"B","R":"1","V":"1","H":"radio mode","O":[{"none":"0"},
{"sta":"1"},
{"ap":"2"},
{"setup":"5"}]},
{"F":"network/network","P":"1034","T":"B","R":"1","V":"1","H":"radio_boot","O":[{"no":"0"},
{"yes":"1"}]},
{"F":"network/sta","P":"1","T":"S","V":"Luc-Lab","S":"32","H":"SSID","M":"1"},
{"F":"network/sta","P":"34","T":"S","N":"1","MS":"0","R":"1","V":"********","S":"64","H":"pwd","M":"8"},
{"F":"network/sta","P":"99","T":"B","R":"1","V":"1","H":"ip mode","O":[{"dhcp":"1"},
{"static":"0"}]},
{"F":"network/sta","P":"100","T":"A","R":"1","V":"192.168.0.1","H":"ip"},
{"F":"network/sta","P":"108","T":"A","R":"1","V":"192.168.0.1","H":"gw"},
{"F":"network/sta","P":"104","T":"A","R":"1","V":"255.255.255.0","H":"msk"},
{"F":"network/sta","P":"1029","T":"A","R":"1","V":"192.168.0.1","H":"DNS"},
{"F":"network/sta","P":"1035","T":"B","R":"0","V":"5","H":"sta fallback mode","O":[{"none":"0"},
{"setup":"5"}]},
{"F":"network/ap","P":"218","T":"S","R":"1","V":"ESP3D","S":"32","H":"SSID","M":"1"},
{"F":"network/ap","P":"251","T":"S","N":"1","MS":"0","R":"1","V":"********","S":"64","H":"pwd","M":"8"},
{"F":"network/ap","P":"316","T":"A","R":"1","V":"192.168.0.1","H":"ip"},
{"F":"network/ap","P":"118","T":"B","R":"1","V":"11","H":"channel","O":[{"1":"1"},
{"2":"2"},
{"3":"3"},
{"4":"4"},
{"5":"5"},
{"6":"6"},
{"7":"7"},
{"8":"8"},
{"9":"9"},
{"10":"10"},
{"11":"11"},
{"12":"12"},
{"13":"13"},
{"14":"14"}]},
{"F":"service/http","P":"328","T":"B","R":"1","V":"1","H":"enable","O":[{"no":"0"},{"yes":"1"}]},
{"F":"service/http","P":"121","T":"I","R":"1","V":"8181","H":"port","S":"65001","M":"1"},
{"F":"service/telnetp","P":"329","T":"B","R":"1","V":"1","H":"enable","O":[{"no":"0"},{"yes":"1"}]},
{"F":"service/telnetp","P":"125","T":"I","R":"1","V":"23","H":"port","S":"65001","M":"1"},
{"F":"service/webdavp","P":"1024","T":"B","R":"1","V":"1","H":"enable","O":[{"no":"0"},{"yes":"1"}]},
{"F":"service/webdavp","P":"1025","T":"I","R":"1","V":"80","H":"port","S":"65001","M":"1"},
{"F":"service/time","P":"120","T":"B","V":"1","H":"i-time","O":[{"no":"0"},{"yes":"1"}]},
{"F":"service/time","P":"1042","T":"S","R":"1","V":"+08:00","H":"tzone","O":[{"-12:00":"-12:00"},
{"-11:00":"-11:00"},
{"-10:00":"-10:00"},
{"-09:00":"-09:00"},
{"-08:00":"-08:00"},
{"-07:00":"-07:00"},
{"-06:00":"-06:00"},
{"-05:00":"-05:00"},
{"-04:00":"-04:00"},
{"-03:30":"-03:30"},
{"-03:00":"-03:00"},
{"-02:00":"-02:00"},
{"-01:00":"-01:00"},
{"+00:00":"+00:00"},
{"+01:00":"+01:00"},
{"+02:00":"+02:00"},
{"+03:00":"+03:00"},
{"+03:30":"+03:30"},
{"+04:00":"+04:00"},
{"+04:30":"+04:30"},
{"+05:00":"+05:00"},
{"+05:30":"+05:30"},
{"+05:45":"+05:45"},
{"+06:00":"+06:00"},
{"+06:30":"+06:30"},
{"+07:00":"+07:00"},
{"+08:00":"+08:00"},
{"+08:45":"+08:45"},
{"+09:00":"+09:00"},
{"+09:30":"+09:30"},
{"+10:00":"+10:00"},
{"+10:30":"+10:30"},
{"+11:00":"+11:00"},
{"+12:00":"+12:00"},
{"+12:45":"+12:45"},
{"+13:00":"+13:00"},
{"+14:00":"+14:00"}]},
{"F":"service/time","P":"464","T":"S","R":"1","V":"time.windows.com","S":"128","H":"t-server","M":"0"},
{"F":"service/time","P":"593","T":"S","R":"1","V":"time.google.com","S":"128","H":"t-server","M":"0"},
{"F":"service/time","P":"722","T":"S","R":"1","V":"0.pool.ntp.org","S":"128","H":"t-server","M":"0"},
{"F":"service/notification","P":"1022","T":"B","R":"1","V":"1","H":"auto notif","O":[{"no":"0"},{"yes":"1"}]},
{"F":"service/notification","P":"116","T":"B","R":"1","V":"0","H":"notification","O":[{"none":"0"},
{"pushover":"1"},
{"email":"2"},
{"line":"3"},
{"telegram":"4"},
{"IFTTT":"5"}]},
{"F":"service/notification","P":"332","T":"S","R":"1","V":"********","S":"63","H":"t1","M":"0"},
{"F":"service/notification","P":"396","T":"S","R":"1","V":"********","S":"63","H":"t2","M":"0"},
{"F":"service/notification","P":"856","T":"S","R":"1","V":" ","S":"128","H":"ts","M":"0"},
{"F":"system/system","P":"461","T":"B","V":"0","H":"targetfw","O":[{"repetier":"50"},
{"marlin":"20"},
{"smoothieware":"40"},
{"grbl":"10"},
{"unknown":"0"}]},
{"F":"system/system","P":"112","T":"I","V":"115200","H":"baud","O":[{"9600":"9600"},
{"19200":"19200"},
{"38400":"38400"},
{"57600":"57600"},
{"74880":"74880"},
{"115200":"115200"},
{"230400":"230400"},
{"250000":"250000"},
{"500000":"500000"},
{"921600":"921600"},
{"1958400":"1958400"}]},
{"F":"system/boot","P":"320","T":"I","V":"100","H":"bootdelay","S":"40000","M":"0"},
{"F":"system/boot","P":"1023","T":"B","V":"0","H":"verbose","O":[{"no":"0"},{"yes":"1"}]},
{"F":"system/outputmsg","P":"129","T":"B","V":"1","H":"serial","O":[{"no":"0"},{"yes":"1"}]},
{"F":"system/outputmsg","P":"851","T":"B","V":"1","H":"M117","O":[{"no":"0"},{"yes":"1"}]},
{"F":"system/outputmsg","P":"1006","T":"B","V":"1","H":"telnet","O":[{"no":"0"},{"yes":"1"}]
}]}
1 - key : Settings
2 - value: array of data formated like this
{“F”:“network/network”,“P”:“130”,“T”:“S”,“V”:“esp3d”,“H”:“hostname”,“S”:“32”,“M”:“1”}
or
{“F”:“service/notification”,“P”:“1004”,“T”:“B”,“V”:“1”,“H”:“auto notif”,“O”:[{“no”:“0”},{“yes”:“1”}]}
- F: is filter formated as section/sub-section, if section is same as sub-section, it means no sub-section
- P: is id (also position reference so it is unique)
- T: is type of data which can be:
- S: for string
- I: for integer
- B: for Byte
- A: for IP address / Mask
- F: for float (only grblHAL)
- M: for bits mask (only grblHAL)
- X: for exclusive bitsfield (only grblHAL)
- V: is current value, if type is string and value is `********`, (8 stars) then it is a password
- E: is integer for exactess / precision of float/double value (only grblHAL)
- U: is text unit of value (only grblHAL)
- H: is text label of value
- S: is max size if type is string, and max possible value if value is number (byte, integer)
- M: is min size if type is string, and min possible value if value is number (byte, integer)
- MS: is additionnal min size if type is string (e.g for password can be 0 or 8, so need additional min size), M should be the more minimal value
so MS value must be between M and S
- O: is an array of {label:value} used for possible values in selection or bits labels list
- R: need restart to be applied
Note: if Type M
and X
use O
entry to define the label / position, if O
is []
then axis label are used according need X
, Y
, Z
, A
, B
, C
Note2 : the 2.1 Flag type is no more used, several entries are used instead grouped by sub-section
If no json the list is limited to a list of <help>: <value>
Settings:
network/network/hostname: esp3d
network/network/radio mode: 5
network/network/radio_boot: 1
network/sta/SSID: NETWORK_SSID
network/sta/pwd: ********
network/sta/ip mode: 1
network/sta/ip: 192.168.0.254
network/sta/gw: 192.168.0.254
network/sta/msk: 255.255.255.0
network/sta/DNS: 192.168.0.254
network/sta/sta fallback mode: 5
network/ap/SSID: ESP3D
network/ap/pwd: ********
network/ap/ip: 192.168.0.1
network/ap/channel: 11
service/time/i-time: 0
service/time/tzone: +00:00
service/time/t-server: time.windows.com
service/time/t-server: time.google.com
service/time/t-server: 0.pool.ntp.org
service/notification/auto notif: 1
service/notification/notification: 0
service/notification/t1:
service/notification/t2:
service/notification/ts:
system/system/targetfw: 0
system/system/baud: 115200
system/boot/bootdelay: 10000
system/boot/verbose: 0
ok
Set ESP3D settings
[ESP401]<P=id> <T=type> <V=value> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
P
T * T is the type of the setting to change * T can be: - S: for string - I: for integer - B: for Byte - A: for IP address / Mask - F: for float (only grblHAL) - M: for bits mask (only grblHAL) - X: for exclusive bitsfield (only grblHAL)
V
* V is the value to set
if value has space add \`` in front of space to not be seen as separator e.g:
[ESP401]P=1 T=S V=My\ SSID json`
{
"cmd":"401",
"status":"ok",
"data":"1"
}
cmd
Id of requested command, should be 401
status
status of command, should be ok
data
content of response, here the id/position of the setting changedGet/Set SD updater check at boot time
[ESP402]<state> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
state
{
"cmd":"402",
"status":"ok",
"data":"OFF"
}
cmd
Id of requested command, should be 402
status
status of command, should be ok
data
content of response, here the stateList all AP detected around, if signal is too low, AP is not listed to avoid connection problems.
[ESP410] json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
{
"cmd":"410",
"status":"ok",
"data":[
{"SSID":"Luc-Lab","SIGNAL":"100","IS_PROTECTED":"1"},
{"SSID":"CHT0573(Mesh)","SIGNAL":"100","IS_PROTECTED":"1"},
{"SSID":"[LG_AirPurifier]","SIGNAL":"48","IS_PROTECTED":"1"},
]
}
cmd
Id of requested command, should be 410
status
status of command, should be ok
data
content of response, here the list of AP detected with signal strength and if protected or notStart Scan
Luc-Lab 100% Secure
CHT0573(Mesh) 100% Secure
[LG_AirPurifier] 46% Secure
End Scan
Get ESP3D current status
[ESP420] json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
{
"cmd":"420",
"status":"ok",
"data":[
{"id":"chip id","value":"11111"},
{"id":"CPU Freq","value":"240Mhz"},
{"id":"CPU Temp","value":"72.8C"},
{"id":"free mem","value":"232.43 KB"},
{"id":"SDK","value":"v4.4.4"},
{"id":"flash size","value":"4.00 MB"},
{"id":"FS type","value":"LittleFS"},
{"id":"FS usage","value":"112.00 KB/128.00 KB"},
{"id":"baud","value":"115200"},
{"id":"sleep mode","value":"none"},
{"id":"wifi","value":"ON"},
{"id":"hostname","value":"esp3d"},
{"id":"wifi mode","value":"ap"},
{"id":"mac","value":"D4:D4:D4:D4:D4:D4"},
{"id":"SSID","value":"ESP3D"},
{"id":"visible","value":"yes"},
{"id":"authentication","value":"WPA2"},
{"id":"DHCP Server","value":"ON"},
{"id":"ip","value":"192.168.0.1"},
{"id":"gw","value":"192.168.0.1"},
{"id":"msk","value":"255.255.255.0"},
{"id":"clients","value":"0"},{"id":"sta","value":"OFF"},
{"id":"mac","value":"D4:D4:D4:D4:D4:D4"},
{"id":"ntp","value":"OFF"},
{"id":"serial","value":"ON"},
{"id":"notification","value":"ON (none)"},
{"id":"targetfw","value":"unknown"},
{"id":"FW ver","value":"3.0.0.a225"},
{"id":"FW arch","value":"ESP32"}]}
cmd
Id of requested command, should be 420
status
status of command, should be ok
data
content of response, where each status is a key/value pair of id/valueConfiguration:
chip id: 1010100
CPU Freq: 240Mhz
CPU Temp: 72.8C
free mem: 232.47 KB
SDK: v4.4.4
flash size: 4.00 MB
FS type: LittleFS
FS usage: 112.00 KB/128.00 KB
baud: 115200
sleep mode: none
wifi: ON
hostname: esp3d
wifi mode: ap
mac: D4:D4:D4:D4:D4:D4
SSID: ESP3D
visible: yes
authentication: WPA2
DHCP Server: ON
ip: 192.168.0.1
gw: 192.168.0.1
msk: 255.255.255.0
clients: 0
sta: OFF
mac: D4:D4:D4:D4:D4:D4
ntp: OFF
serial: ON
notification: ON (none)
targetfw: unknown
FW ver: 3.0.0.a225
FW arch: ESP32
ok
Set ESP3D state
[ESP444]<state> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
state
{
"cmd":"444",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 444
status
status of command, should be ok
data
content of response, here ok
List available ESP3D modules/ ESP3D related devices around
[ESP450] json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
{
"cmd":"450",
"status":"ok",
"data":[
{
"Hostname":"esp3d-tft",
"IP":"192.168.1.108",
"port":"80",
"TxT":[
{"key":"version","value":"1.0.0.a18"},
{"key":"firmware","value":"ESP3D-TFT"}
]
}
]
}
cmd
Id of requested command, should be 450
status
status of command, should be ok
data
content of response, here the list of modules detected with hostname, IP, port and TXT recordStart Scan
esp3d-tft (192.168.1.108:80) version=1.0.0.a18,firmware=ESP3D-TFT
End Scan
Get authentication status
[ESP500] json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
{
"cmd":"500",
"status":"ok",
"data":"admin"
}
cmd
Id of requested command, should be 500
status
status of command, should be ok
data
content of response, here the current user authenticatedadmin
Set/display session time out
[ESP510]<timeout> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
timeout
pwd= the admin password if authentication is enabled
{
"cmd":"510",
"status":"ok",
"data":"10"
}
cmd
Id of requested command, should be 510
status
status of command, should be ok
data
content of response, here the current timeout10
Set/Change admin password, only authenticated admin can change the password
[ESP550]<password> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
password for the admin limited to 20 characters
{
"cmd":"550",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 550
status
status of command, should be ok
data
content of response, here ok
when password is changedSet/Change user password, only authenticated admin/user can change the password
[ESP555]<password> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
password for the user limited to 20 characters
{
"cmd":"555",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 555
status
status of command, should be ok
data
content of response, here ok
when password is changedSend Notification using defined method, will also send notification to webui and eventually to any connected screen
[ESP600]<message> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
message the message to send, limited to 128 characters. Message can contain some variables:
{
"cmd":"600",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 600
status
status of command, should be ok
data
content of response, here ok
when notification is sentSet/Get Notification settings
[ESP610]type=<NONE/PUSHOVER/EMAIL/LINE/IFTTT/HOMEASSISTANT> T1=<token1> T2=<token2> TS=<Settings> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
type
T1
T2
TS if TS is not empty, it will set the setting token which depend on type of notification
pwd= the admin password if authentication is enabled
{
"cmd":"610",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 610
status
status of command, should be ok
data
content of response, here ok
when notification is sentSend Notification using encodded URL
[ESP620]<url> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
url the url to send, limited to 128 characters, must be encoded
{
"cmd":"620",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 620
status
status of command, should be ok
data
content of response, here ok
when notification is sentProcess local file on /FS or /SD
[ESP700]<filename> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
filename the filename to process, must be a valid file on /FS or /SD
{
"cmd":"700",
"status":"ok",
"data":"Processing <filename>"
}
cmd
Id of requested command, should be 700
status
status of command, should be ok
data
content of response, here Processing <filename>
when file is processingQuery and Control ESP700 stream
[ESP701]action=<action> <CLEAR_ERROR>json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
action
CLEAR_ERROR
{
"cmd":"701",
"status":"ok",
"data":{
"status":"processing",
"total":"1000",
"processed":"500",
"type":"1",
"name":"/SD/myfile.gco"
}
}
cmd
Id of requested command, should be 701
status
status of command, should be ok
data
content of response, here the current state of streamFormat ESP Filesystem
[ESP710]FORMATFS json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
FORMATFS
{
"cmd":"710",
"status":"ok",
"data":"Starting formating..."
}
cmd
Id of requested command, should be 710
status
status of command, should be ok
data
content of response, here Starting formating...
when filesystem is startingan new message is sent when formating is done
{
"cmd":"710",
"status":"ok",
"data":"Formating done"
}
cmd
Id of requested command, should be 710
status
status of command, should be ok
data
content of response, here Formating done
when filesystem is doneFormat SD Card, this depend on SD card format defined in configuration.h
[ESP715]FORMATSD json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
FORMATSD
{
"cmd":"715",
"status":"ok",
"data":"Starting formating..."
}
cmd
Id of requested command, should be 715
status
status of command, should be ok
data
content of response, here Starting formating...
when SD card is startingan new message is sent when formating is done
{
"cmd":"715",
"status":"ok",
"data":"Formating done"
}
cmd
Id of requested command, should be 715
status
status of command, should be ok
data
content of response, here Formating done
when SD card is doneList files on /FS or defined repository
[ESP720]<Root> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
Root
{
"cmd":"720",
"status":"ok",
"data":{
"path":"/",
"files":[
{"name":"index.html.gz","size":"88.67 KB","time":"2023-11-05 11:57:57"}
],
"total":"128.00 KB",
"used":"100.00 KB",
"occupation":"78"
}
}
cmd
Id of requested command, should be 720
status
status of command, should be ok
data
content of response, here the list of files on /FS or defined repository
Text
Directory on Flash : /
index.html.gz 88.67 KB 2023-11-05 11:57:57
Files: 1, Dirs :0
Total: 128.00 KB, Used: 100.00 KB, Available: 28.00 KB
Do some actions on ESP Filesystem: rmdir / remove / mkdir / exists / create
[ESP730]<action>=<path> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
action
path the path to process, must be a valid file or directory on /FS
{
"cmd":"730",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 730
status
status of command, should be ok
data
content of response, here ok
when action is doneList files on /SD or defined repository
[ESP740]<Root> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
Root
{
"cmd":"720",
"status":"ok",
"data":{
"path":"/",
"files":[
{"name":"System Volume Information","size":"-1"},
{"name":"src","size":"-1"},
{"name":"testdir","size":"-1"},
{"name":"Newfolder2","size":"-1"},
{"name":"conventions","size":"-1"},
{"name":"extensions","size":"-1"},
{"name":"fileupload","size":"-1"},
{"name":"realtimecmd","size":"-1"},
{"name":"variableslist","size":"-1"},
{"name":"webhandlers","size":"-1"},
{"name":"websockets","size":"-1"},
{"name":"main","size":"-1"},
{"name":"mks_pft70.sys","size":"5 B"},
{"name":"index.html","size":"57.47 KB"},
{"name":"index.xml","size":"7.53 KB"},
{"name":"index.print.html","size":"77.74 KB"}
],
"total":"7.20 GB",
"used":"52.06 MB",
"occupation":"1"
}
}
cmd
Id of requested command, should be 740
status
status of command, should be ok
data
content of response, here the list of files on /SD or defined repository
text
Directory on SD : /
[DIR] System Volume Information
[DIR] src
[DIR] testdir
[DIR] New%20folder2
[DIR] conventions
[DIR] extensions
[DIR] fileupload
[DIR] realtimecmd
[DIR] variableslist
[DIR] webhandlers
[DIR] websockets
[DIR] main
mks_pft70.sys 5 B
index.html 57.47 KB
index.xml 7.53 KB
index.print.html 77.74 KB
Files: 4, Dirs :12
Total: 7.20 GB, Used: 52.06 MB, Available: 7.15 GB
Do some actions on SD Card: rmdir / remove / mkdir / exists / create
[ESP750]<action>=<path> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
action
path the path to process, must be a valid file or directory on /SD
{
"cmd":"750",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 750
status
status of command, should be ok
data
content of response, here ok
when action is doneList Global Filesystem
[ESP780]<Root> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
Root
{
"cmd":"780",
"status":"ok",
"data":{
"path":"/",
"files":[
{"name":"FS","size":"-1"},
{"name":"SD","size":"-1"}
],
"total":"0 B",
"used":"0 B",
"occupation":"0"
}
}
cmd
Id of requested command, should be 780
status
status of command, should be ok
data
content of response, here the list of files on /FS or defined repository
text
Directory on Global FS : /
[DIR] FS
[DIR] SD
Files: 0, Dirs :2
Total: 0 B, Used: 0 B, Available: 0 B
Do some actions on Global Filesystem: rmdir / remove / mkdir / exists / create
[ESP790]<action>=<path> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
pwd= the admin password if authentication is enabled
action
path the path to process, must be a valid file or directory on /FS or /SD
{
"cmd":"790",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 790
status
status of command, should be ok
data
content of response, here ok
when action is doneGet fw capabilities eventually set time with pc time and set setup state
[ESP800]<time=YYYY-MM-DDTHH:mm:ss> <version=3.0.0-a11> <setup=0/1> json=<no> pwd=<admin password>
* json=yes
the output format
* time=
to set ESP3D time using ISO 8601 format : `YYYY`-`MM`-`DD`T`HH`:`minutes`:`seconds`
* tz=+08:00 (optional)
to set ESP3D time zone using ISO 8601 format : `+`/`-` `HH`-`minutes`
* version
version of webUI
* setup flag
Enable / Disable the setup flag
{
"cmd":"800",
"status":"ok",
"data":{
"FWVersion":"bugfix-2.0.x-3.0.0.a200",
"FWTarget":"marlin",
"FWTargetID":"30",
"Setup":"Enabled",
"SDConnection":"shared",
"SerialProtocol":"Socket",
"Authentication":"Disabled",
"WebCommunication":"Synchronous",
"WebSocketIP":"192.168.2.117",
"WebSocketPort":"81",
"Hostname":"esp3d",
"WiFiMode":"STA",
"WebUpdate":"Enabled",
"FlashFileSystem":"LittleFS",
"HostPath":"www",
"Time":"none"
}
}
cmd
Id of requested command, should be 800
status
status of command, should be ok
data content of response:
FWVersion Version of ESP3D firmware or targeted FW (Marlin with ESP3DLib / grblHal)
FWTarget name of targeted Firmware
FWTargetID numerical ID of targeted FW as same name can have several Ids
Setup
Should be Enabled
or Disabled
according flag in EEPROM/Preferences, this allows to WedUI to start wizard automaticaly (or not)
SDConnection This is SD capability, SD can be
SerialProtocol It define how ESP3D FW communicate with main FW
Authentication
Can be Enabled
or Disabled
WebCommunication
currently only Synchronous
, because Asychronous
has been put in hold
WebSocketIP
Ip address for the websocket terminal 192.168.2.117
WebSocketPort
Port for the web socket terminal 81
Hostname
Hostname of ESP3D or main Baord esp3d
WiFiMode
Current wiFi mode in use can be AP
or STA
WebUpdate
Inform webUI the feature is available or not, can be Enabled
or Disabled
FlashFileSystem (currently FileSystem
, to be updated soon )
The file system used by ESP board can be LittleFS
, SPIFFS
, Fat
, none
HostPath
Path where the preferences.json and index.html.gz are stored and can be updated (e.g: www
)
Time Type of time support
none
Time is not supportedAuto
Board use internet to sync time and it is successfulFailed to set
Board use internet to sync time and it is failedManual
Board use time of ESP800 to set the time and it is successfulNot set
Board use time of ESP800 to set the time and command did not sent it (time may have been set by previous command)CameraID if ESP has camera it contain the camera ID
CameraName if ESP has camera it contain the camera name
Axisletters Currently only used for grbHAL can be :
Get state / Set Serial Communication
[ESP900]<state> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
state
pwd= the admin password if authentication is enabled
{
"cmd":"900",
"status":"ok",
"data":"ENABLED"
}
cmd
Id of requested command, should be 900
status
status of command, should be ok
data
content of response, here the current state-Text
ENABLED
Set Serial baudrate for main serial communication
[ESP901]<baudrate> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
baudrate
pwd= the admin password if authentication is enabled
{
"cmd":"901",
"status":"ok",
"data":"115200"
}
cmd
Id of requested command, should be 901
status
status of command, should be ok
data
content of response, here the current baudrate115200
Get state / Set Enable / Disable buzzer
[ESP910]<state> json=<no> pwd=<admin password>
json=no the output format can be in JSON or plain text
state
pwd= the admin password if authentication is enabled
{
"cmd":"910",
"status":"ok",
"data":"ENABLED"
}
cmd
Id of requested command, should be 910
status
status of command, should be ok
data
content of response, here the current stateENABLED
Set Serial Bridge state which can be ON, OFF, CLOSE
[ESP930]<state> json=<no> pwd=<admin password>
json=no the output format
state
pwd= the admin password if authentication is enabled
{
"cmd":"930",
"status":"ok",
"data":"ENABLED"
}
cmd
Id of requested command, should be 930
status
status of command, should be ok
data
content of response, here the current stateENABLED
Set Serial Bridge baudrate
[ESP931]<baudrate> json=<no> pwd=<admin password>
json=no the output format
baudrate
pwd= the admin password if authentication is enabled
{
"cmd":"931",
"status":"ok",
"data":"115200"
}
cmd
Id of requested command, should be 931
status
status of command, should be ok
data
content of response, here the current baudrate115200
Set quiet boot if strapping pin is High, can only be done once and cannot be reverted
This command is only available if ESP32-S3, ESP32-C3 or ESP32-S2 is used
[ESP999]QUIETBOOT json=<no> pwd=<admin password>
json=no the output format
pwd= the admin password if authentication is enabled
QUIETBOOT
{
"cmd":"999",
"status":"ok",
"data":"ok"
}
cmd
Id of requested command, should be 999
status
status of command, should be ok
data
content of response, here ok
when quiet boot is setok
The authentication is an additional security layer to protect the ESP3D web interface and ESP3D commands from unauthorized access. It is based on a username and a password. The authentication is optional and can be enabled/disabled in the ESP3D configuration. There are 3 login levels for authentication:
Currently the login cannot be customized and so is limited to user
and admin
levels. The guest
level is always available and cannot be disabled.
In configuration.h just uncomment the following line to enable the authentication:
#define AUTHENTICATION_FEATURE
Default password authentication for admin
is admin
and for ‘user’ is user
. You can change them using WebInterface or [ESP550] and [ESP555] commands.
When user authentication is enabled, the web interface will ask for a username and a password. If the authentication is successful, the user will be redirected to the web interface. If the authentication fails, the user will be redirected to the login page.
The web interface allows also inline authentication. This means that you can pass the username and password in the URL. This is useful if you want to use some command line to access the web interface like curl or wget. The URL format is the following:
http://user:password@<ip_address>
On the web interface an authenticated session will stay open until the browser is closed. So if you close the browser and reopen it, you will be asked for authentication again. This session can also have a timeout. The default timeout is 3 minutes of inactivity. This timeout can be changed in the ESP3D configuration web interface or using [ESP510]
command.
When user authentication is enabled, the ESPXXX commands will ask for a password. If the authentication is successful, the command will be executed. If the authentication fails, the command will be rejected.
The session for ESPXXX commands is a sticky session. This means that once authenticated, the session will stay authenticated until the ESP3D is restarted or session is closed (e.g: Telnet / WebSocket).
The current authentication miss a lot of features, like:
So you must not consider authentication as fullproof for security. It is just an additional layer of security.
Because ESPXXX commands only rely on password, do not use same password for user and admin users. If you do so, you will not be able to use ESPXXX commands with user level, everything will be considered as admin when authenticated.
The password are never been displayed in clear text, but they are stored in the ESP3D configuration in clear text. So if you want to change the password, you must use the WebInterface or ESPXXX commands.
In web interface the passwords are replaced by *******
so any modification must be complete not partial.
All passwords and sensitive informations are sent using plain text. So if you want to use ESP3D in a public network or outside of your local network (which is not recommended), you must use a VPN.
Here the scope of right for each authentication level:
Feature | not authenticated | guest | user | admin |
---|---|---|---|---|
Web Interface | No | No | Yes | Yes |
Telnet | No | No | Yes | Yes |
WebSocket | No | No | Yes | Yes |
WebDav | No | No | Yes | Yes |
Bluetooth | No | No | Yes | Yes |
Upload | No | No | Yes | Yes |
Update | No | No | No | Yes |
[ESP0] | Yes | Yes | Yes | Yes |
[ESP100] | No | No | Get | Get/Set |
[ESP101] | No | No | No | Set |
[ESP102] | No | No | Get | Get/Set |
[ESP103] | No | No | Get | Get/Set |
[ESP104] | No | No | Get | Get/Set |
[ESP105] | No | No | Get | Get/Set |
[ESP106] | No | No | No | Set |
[ESP107] | No | No | Get | Get/Set |
[ESP108] | No | No | Get | Get/Set |
[ESP110] | No | No | Get | Get/Set |
[ESP111] | No | No | Get | Get |
[ESP112] | No | No | Get | Get/Set |
[ESP114] | No | No | Get | Get/Set |
[ESP115] | No | No | Get | Get/Set |
[ESP120] | No | No | Get | Get/Set |
[ESP121] | No | No | Get | Get/Set |
[ESP130] | No | No | Get | Get/Set |
[ESP131] | No | No | Get | Get/Set |
[ESP140] | No | No | Get | Get/Set |
[ESP150] | No | No | Get | Get/Set |
[ESP160] | No | No | Get | Get/Set |
[ESP161] | No | No | Get | Get/Set |
[ESP170] | No | No | Get/Set | Get/Set |
[ESP171] | No | No | Get | Get |
[ESP180] | No | No | Get | Get/Set |
[ESP181] | No | No | Get | Get/Set |
[ESP190] | No | No | Get | Get/Set |
[ESP191] | No | No | Get | Get/Set |
[ESP200] | No | No | Get/Set | Get/Set |
[ESP201] | No | No | Get/Set | Get/Set |
[ESP202] | No | No | Get | Get/Set |
[ESP210] | No | No | Get | Get/Set |
[ESP214] | No | No | Set | Set |
[ESP215] | No | No | No | Set |
[ESP220] | No | No | Get | Get |
[ESP250] | No | No | Set | Set |
[ESP290] | No | No | Set | Set |
[ESP400] | No | No | Get | Get |
[ESP401] | No | No | No | Set |
[ESP402] | No | No | Get | Get/Set |
[ESP410] | No | No | Get | Get |
[ESP420] | No | No | Get | Get |
[ESP444] | No | No | Set(only RESTART) | Set |
[ESP450] | No | No | Get | Get |
[ESP500] | Get/Set | Get/Set | Get/Set | Get/Set |
[ESP510] | No | No | Get | Get/Set |
[ESP550] | No | No | No | Get/Set |
[ESP555] | No | No | Get/Set | Get/Set |
[ESP600] | No | No | Set | Set |
[ESP610] | No | No | Get | Get/Set |
[ESP620] | No | No | Set | Set |
[ESP700] | No | No | Set | Set |
[ESP701] | No | No | Get/Set | Get/Set |
[ESP710] | No | No | No | Set |
[ESP715] | No | No | No | Set |
[ESP720] | No | No | Get | Get |
[ESP730] | No | No | Get/Set | Get/Set |
[ESP740] | No | No | Get | Get |
[ESP750] | No | No | Get/Set | Get/Set |
[ESP780] | No | No | Get | Get |
[ESP790] | No | No | Get/Set | Get/Set |
[ESP800] | No | No | Get/Set | Get/Set |
[ESP900] | No | No | Get/Set | Get/Set |
[ESP901] | No | No | Get | Get/Set |
[ESP910] | No | No | Get/Set | Get/Set |
[ESP930] | No | No | Get | Get/Set |
[ESP931] | No | No | Get | Get/Set |
[ESP999] | No | No | No | Set |
Each authenticated session have unique session id, that will be stored on ESP3D with additionnal informations:
When authentication is enabled, the http server will check if the session is authenticated. If not, it will ask for authentication. If the session is authenticated, it will check if the session is still valid. If not, it will ask for authentication again. If the session is still valid, it will process the request.
the Session ID is stored in the cookie ESP3D_SESSIONID
.
You can use only one type of notification from the following ones:
A pay service
Please follow this link for more information on how to setup a pushover notification service
A free service
Please follow this link for more information on how to setup a line notification service
Please follow this link for more information on how to setup a email notification service
A free service up to 5 applets
Please follow this link for more information on how to setup a pushover iftt service
A free service
Please follow this link for more information on how to setup a telegram notification service
The notification will also be sent to the WebUi
Just add following command in your slicer’s end script, or manualy on your GCODE file:
[ESP600]msg pwd=<admin password>
on Repetier
M118 [ESP600]msg
on Marlin
M118 P0 [ESP600]msg
on Smoothieware
echo [ESP600]msg
Pushover is paid service
Considering you have pushover account (even just trial) and you already installed pushover client on you phone/PC:
1 - Go to https://pushover.net/ and connect with email and password
2 - Once connected you will be able to get the token 1, the user token
3 - You also need to generate an application token, which is the token 2
5 - Save the generate token 1 and token 2 in ESP3D, and set PUSHOVER as notification supplier
[ESP610]type=PUSHOVER T1=xxxxxxxxxxxxxxxxxx T2=yyyyyyyyyyyyyyyyy
6 - type [ESP610]
to verify (T1 and T2 won’t be displayed)
7 - Try to send message:
[ESP600]Hi there, test from ESP3D
Line is free service
Considering you have line account and you already installed line on you phone/PC:
1 - Go to https://notify-bot.line.me/my/ and connect with email and password
2 - Once connected you will be able to generate token
3 - Type token name on top, select recipient(s) and press Generate token
4 - Once token is created you need to copy it
5 - You can create as many tokens you want, and delete the ones you do not need
6 - Save the generate token in ESP3D, and set LINE as notification supplier
[ESP610]type=LINE T1=xxxxxxxxxxxxxxxxxx
7 - type [ESP610]
to verify (T1 won’t be displayed)
8 - Try to send message:
[ESP600]Hi there, test from ESP3D
Email Notification is using SMTP and HTTPS, so you need to collect the following information fof your email supplier
ESP3D use the parameters as follow:
the_recipient email#smtp_server:port
where # and : are fields separators.For example: luc@gmail.com#smtp.gmail.com:465
1 -Save the token 1, token 2 and token settings in ESP3D, and set EMAIL as notification supplier
[ESP610]type=EMAIL T1=luc@gmail.com T2=mypassword TS=luc@gmail.com#smtp.gmail.com:465
2 - Type [ESP610]
to verify (T1 and T2 won’t be displayed)
3 - Try to send message:
[ESP600]Hi there, test from ESP3D
4 - Important : if you are using Gmail there is an additional step, as by default https access is disabled.
go to : https://myaccount.google.com/lesssecureapps and allow less secure applications to connect
IFTTT is free service up to 5 applets
IFTTT is a wrapper that allows several kind of notifications, please refer to it documentation.
ESP3D use the webhook method.
1 - If you do not have IFTTT account you can create for free to use up to 5 applets.
Select the service you want to use
As you can see there are a lot, let use email as example, but you can select any one that fit your needs
Define the message
IFTTT allows some variables:
3 - Retrieve the webhook key
4 - Save the generate token and chatID in ESP3D, and set IFTTT as notification supplier
[ESP610]type=IFTTT T1={event} T2={webhooks_key}
5 - type [ESP610]
to verify (T1/T2 won’t be displayed)
6 - Try to send message:
[ESP600]Hi there, test from ESP3D
7 - Verify the workflow
Note: This documentation is not exaustive due to huge features of IFTTT notifications service but base is always same :
IFThis => webhooks based on webrequest
THENThat => IFTTT notification service
Telegram is free service
Considering you have Telegram account and you already installed Telegram on you phone/PC:
You need a bot token and a channel id:
1 - Create a bot with BotFather
/newbot
T1=<bot token>
2 - Create a public channel
@
3 - Assign your bot as administrator of your channel so it can use it4 - Save the generate token and chatID in ESP3D, and set Telegram as notification supplier
[ESP610]type=TELEGRAM T1=<bot token> T2=<@chatID>
5 - Type [ESP610]
to verify (T1/T2 won’t be displayed)
6 - Try to send message:
[ESP600]Hi there, test from ESP3D
You can update Marlin with ESP3DLib using the maintenance page, the web ui and the SD Card and OTA process.
You can update/manage flash file system content and update firmware.
This page is automaticaly available if no index.html / index.html.gz is present on flash filesystem.
Another way to access it, is to add the parameter ?forcefallback=yes
to your IP address in browser.
You need to have webupdate feature enabled.
You can update/manage flash file system content and update firmware.
You need to have sd card enabled and sd update feature enabled in configuration.h
.
You can update all ESP3DLib settings when board is starting using an ini file named esp3dcnf.ini
at root of SD card.
[network]
#hostname string of 32 chars max
hostname = myesp
#radio mode bt, wifi-sta, wifi-ap, eth-sta, off
radio_mode = wifi-sta
#station fallback mode bt, wifi-ap, off
sta_fallback = wifi-ap
#active when boot device or not yes / no
radio_enabled = yes
#sta ssid string of 32 chars max
sta_ssid = myssid
#sta password string of 64 chars max, minimum 0 or 8 chars
sta_password = *******
#sta ip mode dhcp / static
sta_ip_mode = dhcp
#sta static ip
sta_ip = 192.168.0.2
#sta static gateway
sta_gw = 192.168.0.1
#sta static mask
sta_msk = 255.255.255.0
#sta static dns
sta_dns = 192.168.0.1
#ap ssid string of 32 chars max
ap_ssid = myssid
#ap password string of 64 chars max, minimum 0 or 8 chars
ap_password = 12345678
#ap static ip
ap_ip = 192.168.0.1
#ap channel 1~14
ap_channel = 11
[services]
#active or not serial bridge yes / no
serial_bridge_active = yes
# serial bridge baudrate
serial_bridge_baud = 115200
#active or not http yes / no
http_active = yes
#http port
http_port = 80
#active or not telnet yes / no
telnet_active = yes
#telnet port
telnet_port = 23
#active or not websocket yes / no
websocket_active = yes
#websocket port
websocket_port = 8282
#active or not webdav yes / no
webdav_active = yes
#websocket port
webdav_port = 8282
#active or not ftp yes / no
ftp_active = yes
#ftp control port
ftp_control_port = 21
#ftp active port
ftp_active_port = 20
#ftp passive port
ftp_passive_port = 55600
#auto notification
autonotification = yes
#notification type none / pushover / line / email / telegram /ifttt
notif_type = none
#notification token 1 string of 64 chars max
notif_token1 =
#notification token 2 string of 64 chars max
notif_token2 =
#notification settings string of 127 chars max
notif_token_settings=
#sd card speed factor 1 2 4 6 8 16 32
sd_speed = 4
#check update from sd yes / no
check_for_update = yes
#enable buzzer yes / no
active_buzzer = yes
#active internet time yes / no
active_internet_time = yes
#time servers string of 127 chars max
time_server1 = 1.pool.ntp.org
time_server2 = 2.pool.ntp.org
time_server3 = 3.pool.ntp.org
#time zone -12~12
time_zone = 2
#is dst yes/no
time_dst = no
#authentication passwords string of 20 chars max
admin_password = xxxxxxx
user_password = xxxxxxx
#session time out in min
sesion_timeout = 3
#sensor type if enabled none / dht11 / dht22 / analog / bmp280 / bme280
sensor_type = none
#sensor poiling interval in ms
sensor_interval = 30000
[system]
#target firmware marlin / repetier / marlinkimbra / smoothieware / grbl
targetfw=marlin
#baud rate
baud_rate = 115200
#boot delay in ms
boot_delay = 5000
#boot verbose yes / no
boot_verbose = no
#outputs
#printer screen yes / no
active_remote_screen = yes
#esp3d screen yes / no
active_esp3d_screen = yes
#esp3d serial yes / no
active_serial = yes
#serial bridge yes / no
active_serial_bridge = yes
#websocket yes / no
active_websocket = yes
#telnet yes / no
active_telnet = yes
#bluetooth yes / no
active_bt = yes
Once update is done all passwords set in file will be replaced by ********
.
You can update Marlin with ESP3DLib firmware when board is starting using a binary image file of firmware esp3dfw.bin
at root of SD card.
If update is sucessful the file will be renamed to esp3dfw.ok
, if esp3dfw.ok
already exists, it will be first renamed using some index.
If update fail the file is renamed to esp3dfw.bad
to avoid to try to update at each boot.
You can update Marlin with ESP3DLib flash filesystem when board is starting using a binary image file of filesystem esp3dfs.bin
at root of SD card.
If update is sucessful the file will be renamed to esp3dfs.ok
, if esp3dfs.ok
already exists, it will be first renamed using some index.
If update fail the file is renamed to esp3dfs.bad
to avoid to try to update at each boot.
This feature need to be enabled in configuration.h
FTP server accept only one connection at once, be sure you have limited the number of connections in your client settings
The FTP server can serve flash only, sd only or both at once, but the sd support is limited direct sd and shared sd connections, serial connection is not supported (e.g. MKS protocol)
The WebDAV server can serve flash only, sd only or both at once, but the sd support is limited direct sd and shared sd connections, serial connection is not supported (e.g. MKS protocol)
Web handlers description and parameters
Web Sockets description, messages and parameters
#include "esp3dlib.h"
//Serial2
Serial2Socket class
//init
esp3dlib.init();
//idle task
esp3dlib.idletask();
//Custom command
esp3dlib.parse(command_ptr);
root is the default handler where all files will be served, if no file is defined, it looks for index.html or index.html.gz (compressed) if you call specific file, it will look for the filename and filename.gz (compressed) if no file is defined and there is not index.html(.gz) it will display embedded page another way to show the embedded page is /?forcefallback=yes
it will serve any file from SD card if there is one, it is only a wrapper to read SD card, no upload
this handler handle all commands for FS, including upload on FS.
possible options/arguments are:
quiet=yes
can be used when you don’t want list files but just upload thempath=...
define the path to the fileaction=...
define the action to execute which can be:filename=...
it will also use path=...
to do full pathfilename=...
it will also use path=...
to do full path filename=...
it will also use path=...
to do full pathcreatePath=yes
when doing upload and the path do not exists, it will create it, POST only<filename>S=...
give the size of uploaded file with name, need to be set before file is set in upload, POST onlythe output is a json file:
```json
{
"files":[ //the files list
{
"name":"index.html.gz", //the name of the file
"size":"83.46 KB", //the formated size of the file
"time":"2022-09-04 11:56:05" //the time when the file was modified last time, this one is optional and depend on (FILESYSTEM_TIMESTAMP_FEATURE)
},
{
"name":"subdir", //the name of the file / directory
"size":"-1", //the size is -1 because it is a directory
"time":"" //no time for directories optional as depend on (FILESYSTEM_TIMESTAMP_FEATURE)
}
],
"path":"/", //current path
"occupation":"52", //% of occupation
"status":"subdir created", //status
"total":"192.00 KB", //Formated total space of Filesystem
"used":"100.00 KB" //Formated used space of Filesystem
}
```
this handler handle all commands for SD, including upload on SD (only shared and direct SD)
this handler handle all commands for FS, including upload on FS.
possible options/arguments are:
quiet=yes
can be used when you don’t want list files but just upload thempath=...
define the path to the fileaction=...
define the action to execute which can be:filename=...
it will also use path=...
to do full pathfilename=...
it will also use path=...
to do full path filename=...
it will also use path=...
to do full pathcreatePath=yes
when doing upload and the path do not exists, it will create it, POST only<filename>S=...
give the size of uploaded file with name, need to be set before file is set in upload, POST onlythe output is a json file:
```json
{
"files":[ //the files list
{
"name":"3Oc-pika2.gco",//the name of the file
"shortname":"3Oc-pika2.gco", //the 8.3 shortname if available, if not the name of the file
"size":"83.46 KB", //the formated size of the file
"time":"2022-09-04 11:56:05" //the time when the file was modified last time, this one is optional and depend on (SD_TIMESTAMP_FEATURE)
},
{
"name":"subdir", //the name of the file / directory
"size":"-1", //the size is -1 because it is a directory
"time":"" //no time for directories optional as depend on (SD_TIMESTAMP_FEATURE)
}
],
"path":"/", //current path
"occupation":"52", //% of occupation
"status":"subdir created", //status
"total":"192.00 KB", //Formated total space of Filesystem
"used":"100.00 KB" //Formated used space of Filesystem
}
```
this handler is for MKS boards using MKS communication protocol if enabled, it handle only upload on SD
this handler is for all commands the parameter is cmd=...
if it is an [ESPXXX]
command the answer is the [ESPXXX]
response
if it is not an [ESPXXX]
command the answer is ESP3D says: command forwarded
and can be ignored
this handler is for authentication function if enabled
possible options/arguments are:
- DISCONNECT=YES
it will clear current session, remove authentication cookie, set status to disconnected
and response code to 401
- SUBMIT=YES
to login it will need also PASSWORD=...
and USER=...
, the answer will be 200 if success and 401 if failed
if user is already authenticated it can use NEWPASSWORD=...
instead of PASSWORD=...
to change his password, if successful answer will be returned with code 200, otherwise code will be 500 if change failed or if password format is invalid
Output:
{"status":"Identified","authentication_lvl":"admin"}
and code 200{"status":"Wrong authentication!","authentication_lvl":"guest"}
and code 401this handler is a shortcut to [ESP420] command in text mode, to get output in json add json=yes
this handler is for FW upload and update
Answer output is :
{"status":"..."}
if upload is successful the ESP will restart
this handler is on esp32cam with camera enabled to capture a Frame it answer by sending a jpg image
this handler is for SSDP if enabled to present device informations
<root xmlns="urn:schemas-upnp-org:device-1-0">
<specVersion>
<major>1</major>
<minor>0</minor>
</specVersion>
<URLBase>http://192.168.2.178:80/</URLBase>
<device>
<deviceType>urn:schemas-upnp-org:device:upnp:rootdevice:1</deviceType>
<friendlyName>esp3d</friendlyName>
<presentationURL>/</presentationURL>
<serialNumber>52332</serialNumber>
<modelName>ESP Board</modelName>
<modelDescription/>
<modelNumber>ESP3D 3.0</modelNumber>
<modelURL>https://www.espressif.com/en/products/devkits</modelURL>
<manufacturer>Espressif Systems</manufacturer>
<manufacturerURL>https://www.espressif.com</manufacturerURL>
<UDN>uuid:38323636-4558-4dda-9188-cda0e600cc6c</UDN>
<serviceList/>
<iconList/>
</device>
</root>
to avoid a redirect to index.html and so a refresh of the page, some classic handler have been added so they all go to / handler actually
there are 2
terminal websocket used to stream data to webUI and exchange internal data
data websocket used to exchange data with external client (not used by WebUI)
use subprotocol webui-v3
and port is web port +1 (e.g: 80+1=>81)
Reserved
messages between webui / ESP
Format: <label>:<message>
from ESP to WebUI
currentID:<id>
Sent when client is connecting, it is the last ID used and become the active ID
activeID:<id>
Broadcast current active ID, when new client is connecting, client without this is should close, ESP WS Server close all open WS connections but this one also
PING:<time left>:<time out>
It is a response to PING from client to inform the time left if no activity (see below)
ERROR:<code>:<message>
If an error raise when doing upload, it informs client it must stop uploading because sometimes the http answer is not possible,
or cannot cancel the upload, this is a workaround as there is no API in current webserver to cancel active upload
NOTIFICATION:<message>
Forward the message sent by [ESP600] to webUI toast system
SENSOR: <value>[<unit>] <value2>[<unit2>] ...
The sensor connected to ESP like DHT22
from WebUI to ESP
PING:<current cookiesessionID / none >
if any, or “none” if noneReserved
from ESP to WebUI stream data from ESP to WebUI
from WEBUI to ESP
[-> File transfert from WebUI to ESP : not implemented yet]
use sub protocol arduino
and port is any defined port (e.g: 8282)
This mode is used to transfert all GCODE commands and their answers from printer/cnc
This mode is used to transfert files to / from esp board
it use frame of 1024 bytes, can be increased after test
the frame format is : 2 bytes: for frame type 2 bytes: for frame size to check some integrity, currently as already part of frame no checksume is used x bytes : extra data according frame type
type: client -> esp Status Request
S |
R |
0 | 0 |
---|
with hexadecimal values:
0x53 | 0x52 | 0 | 0 |
---|
Response frame use inverted header: Response Status
R |
S |
0 | 1 | A |
---|
with hexadecimal values:
0x52 | 0x53 | 0 | 1 | 0x41 |
---|
the first byte of answer is the state
Code | Hexa | Meaning |
---|---|---|
B |
0x42 | busy |
O |
0x4F | idle/ok |
E |
0x45 | error |
A |
0x41 | abort |
D |
0x44 | download ongoing |
U |
0x55 | upload ongoing |
extra data may be added :
error code and string, 1 byte : error code: 0->255 1 byte : string size 0->255 XX bytes for the string
R |
S |
x | x | C |
4 | X | .. | .. |
---|
Upload informations: 1 byte : path size 0->255 XX bytes : the path string 1 byte : the filename size 0->255 xx bytes : filename string 4 bytes : total file size 4 bytes : currently processed bytes 4 bytes : last packet id processed
R |
S |
x | x | U |
X | .. | .. | X | .. | .. | S1 | S1 | S1 | S1 | S2 | S2 | S2 | S2 |
---|
Download informations: 1 byte : path size 0->255 XX bytes : the path string 1 byte : the filename size 0->255 xx bytes : filename string 4 bytes : total file size 4 bytes : currently processed bytes 4 bytes : last packet id processed
R |
S |
x | x | D |
X | .. | .. | X | .. | .. | S1 | S1 | S1 | S1 | S2 | S2 | S2 | S2 |
---|
header is :
S |
U |
0 | 0 |
---|
the content is: 1 byte : path size 0->255 XX bytes : the path string 1 byte : the filename size 0->255 xx bytes : filename string 4 bytes : total file size
S |
U |
x | x | D |
X | .. | .. | X | .. | .. | S1 | S1 | S1 | S1 |
---|
if answer is :
U |
S |
0 | 1 | O |
---|
it means transfert can start
header is :
U |
P |
x | x | ID | ID | ID | ID | .. | .. |
---|
4 bytes is packet id XXXX bytes is data
if packet is received the answer is
P |
U |
0 | 5 | O |
ID | ID | ID | ID |
---|
header is :
S |
D |
0 | 0 |
---|
the content is: 1 byte : path size 0->255 XX bytes : the path string 1 byte : the filename size 0->255 xx bytes : filename string 4 bytes : total file size
S |
D |
x | x | D |
X | .. | .. | X | .. | .. | S1 | S1 | S1 | S1 |
---|
if answer is :
D |
S |
0 | 1 | O |
---|
it means transfert can start
header is :
D |
P |
x | x | ID | ID | ID | ID | .. | .. |
---|
4 bytes is packet id XXXX bytes is data
if packet is received the answer is
P |
D |
0 | 5 | O |
ID | ID | ID | ID |
---|
header is :
C |
M |
0 | 1 | X |
---|
Commands:
Code | Hexa | Meaning |
---|---|---|
A |
0x41 | abort |
Abort command frame
C |
M |
0 | 1 | A |
---|
FYSETC-E4
MKS Tinybee V1
MRR-ESPA
MRR-ESPE
Panda Zhu/M4
From FYSETC, an ESP32 controller with 16MB flash memory, no IO expander.
From Maker Base, an ESP32 controller with 8MB flash memory, with IO expander.
From Maple Rain, an ESP32 controller with 4MB flash memory, no IO expander.
From Maple Rain, an ESP32 controller with 4MB flash memory, with IO expander.
From Mark Niu, two ESP32 controllers with 4MB flash memory, with IO expander.
ESP3DLib contributors for their suggestions, feedback and ideas submitted during 1.X sustaining phase and 3.X development phase which pushed me to rewrite the ESP3DLib/ESP3D code to make it better and easier to sustain.