Fileservice

This commit is contained in:
chk
2026-06-14 11:43:37 +02:00
parent a807732b58
commit 8a669f23d3
3 changed files with 30 additions and 21 deletions

View File

@@ -58,27 +58,6 @@ class GCode{
}
static toPiMultiple(gCode){
if(gCode == undefined){return gCode;}
var multipleParameters = gCode.split(" ");
var newGString = "";
multipleParameters.forEach((paramet) => {
if(paramet == undefined || !paramet || paramet.length === 0 || paramet == " " || paramet ==""){
}
else if(['A', 'a', 'B', 'b', 'C', 'c','E','e'].includes(paramet.charAt(0)) )
{
var numberParameter = Number(paramet.substring(1, paramet.length))
newGString += " " + paramet[0] + String(numberParameter*Math.PI/180)
}
else{
newGString += " " + paramet;
}
});
return newGString.trim();
};
/**
* Verarbeitet eine rohe G-Code-Nachricht. Parsing + Steuerlogik liegen jetzt im
* GCodeParser bzw. RobotController (ToDo_6); diese Methode bleibt als Fassade