Remove console.log statements for weight and filament detection in PrinterClient and PrinterDatabase. Update precision of currentFilamentUsed logging to 8 decimal places. Add placeholder for homeAxis method in PrinterClient.
Some checks failed
farmcontrol/farmcontrol-server/pipeline/head There was a failure building this commit
Some checks failed
farmcontrol/farmcontrol-server/pipeline/head There was a failure building this commit
This commit is contained in:
parent
57e0c5a30d
commit
db8e035c86
@ -496,7 +496,6 @@ export class PrinterDatabase {
|
||||
) {
|
||||
const subJobId = subJob._id || subJob.id;
|
||||
const jobId = job._id || job.id;
|
||||
console.log("WEIGHT", weight);
|
||||
try {
|
||||
const filamentStockStockEvents = await this.socketClient.listObjects({
|
||||
objectType: "stockEvent",
|
||||
|
||||
@ -530,7 +530,6 @@ export class PrinterClient {
|
||||
// Calculate weight in grams
|
||||
const filamentWeightG =
|
||||
filamentVolumeCm3 * this.currentFilament?.density || 0;
|
||||
console.log("FILAMENT WEIGHT", this.currentFilament);
|
||||
this.currentFilamentUsed = -1 * filamentWeightG;
|
||||
}
|
||||
|
||||
@ -699,7 +698,6 @@ export class PrinterClient {
|
||||
},
|
||||
});
|
||||
if (newFilamentDetected !== this.filamentDetected) {
|
||||
console.log(status["filament_switch_sensor fsensor"]);
|
||||
logger.info(
|
||||
`Printer ${this.printer.name} filament detection changed from ${this.filamentDetected} to ${newFilamentDetected}.`,
|
||||
);
|
||||
@ -842,7 +840,7 @@ export class PrinterClient {
|
||||
) {
|
||||
logger.debug(
|
||||
"Updating stock event value:",
|
||||
this.currentFilamentUsed.toFixed(2),
|
||||
this.currentFilamentUsed.toFixed(8),
|
||||
);
|
||||
this.database.updateFilamentStockWeight(
|
||||
this.currentFilamentStock,
|
||||
@ -1332,6 +1330,10 @@ export class PrinterClient {
|
||||
}
|
||||
}
|
||||
|
||||
async homeAxis(axis) {
|
||||
|
||||
}
|
||||
|
||||
async restartPrinterFirmware() {
|
||||
logger.info(`Restarting printer firmware for ${this.printer.name}`);
|
||||
if (!this.isOnline) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user