0
0
mirror of https://github.com/Doodle3D/doodle3d-firmware.git synced 2025-04-20 10:06:30 +02:00

added printer/listall to API

This commit is contained in:
Rick Companje 2013-12-05 17:31:32 +01:00
parent 52a2d69bdd
commit 34491670b8
2 changed files with 26 additions and 10 deletions

View File

@ -93,15 +93,22 @@ M.printer_type = {
end end
} }
M.printer_bed_width = { M.printer_dimensions_x = {
default = 220, default = 200,
subSection = 'printer_type', subSection = 'printer_type',
type = 'int', type = 'int',
description = '', description = '',
min = 0 min = 0
} }
M.printer_bed_height = { M.printer_dimensions_y = {
default = 220, default = 200,
subSection = 'printer_type',
type = 'int',
description = '',
min = 0
}
M.printer_dimensions_z = {
default = 200,
subSection = 'printer_type', subSection = 'printer_type',
type = 'int', type = 'int',
description = '', description = '',
@ -256,12 +263,12 @@ M.printer_enableTraveling = {
description = '' description = ''
} }
M.printer_maxObjectHeight = { -- M.printer_maxObjectHeight = {
default = 150, -- default = 150,
type = 'int', -- type = 'int',
description = 'Maximum height that will be printed', -- description = 'Maximum height that will be printed',
min = 0 -- min = 0
} -- }
M.printer_screenToMillimeterScale = { M.printer_screenToMillimeterScale = {
default = 0.3, default = 0.3,

View File

@ -89,6 +89,15 @@ function M.state(request, response, onlyReturnState)
return true return true
end end
-- retrieve a list of 3D printers currently supported
function M.listall(request, response)
response:setSuccess()
response:addData('printers', printerUtils.supportedPrinters())
return true
end
function M.heatup_POST(request, response) function M.heatup_POST(request, response)
if not accessManager.hasControl(request.remoteAddress) then if not accessManager.hasControl(request.remoteAddress) then