Creative Technologies Lab | dokuWiki

Repository of academic adventures, experimental technology, accidental brilliance, and collaborative nerdery.

User Tools

Site Tools


extras:codikon:p5js:cnc-helper

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
extras:codikon:p5js:cnc-helper [2025/11/29 19:37] – created Felix Hardmood Beckextras:codikon:p5js:cnc-helper [2025/11/29 20:05] (current) Felix Hardmood Beck
Line 10: Line 10:
 // CNC feed suggestion helper with adjustable bit diameter // CNC feed suggestion helper with adjustable bit diameter
 // Includes spindle speed and chip load calculation // Includes spindle speed and chip load calculation
 +// Version 1.01 – angepasst auf DeWalt D26200 Drehzahlstufen
  
 let materialSelect; let materialSelect;
Line 31: Line 32:
   const container = select('#calculator-container');   const container = select('#calculator-container');
  
-  const title = createDiv('CNC Feed & Chip-Load Rechner');+  const title = createDiv('CNC Feed & Chip-Load Rechner V. 1.01');
   title.addClass('app-title');   title.addClass('app-title');
   title.parent(container);   title.parent(container);
  
   const subtitle = createDiv(   const subtitle = createDiv(
-    'Konservative Startwerte für Hobby-CNC-Router. Vor Serienfertigung immer an Reststücken testen.'+    'Konservative Startwerte für Hobby-CNC-Router mit DeWalt D26200. Vor Serienfertigung immer an Reststücken testen.'
   );   );
   subtitle.addClass('app-subtitle');   subtitle.addClass('app-subtitle');
Line 195: Line 196:
     `<div class="summary-pill">Plunge: ${Math.round(settings.plungeRate)} mm/min</div>` +     `<div class="summary-pill">Plunge: ${Math.round(settings.plungeRate)} mm/min</div>` +
     `<div class="summary-pill">Chip Load: ${roundTo(chipLoad, 4)} mm/Zahn</div>` +     `<div class="summary-pill">Chip Load: ${roundTo(chipLoad, 4)} mm/Zahn</div>` +
-    `<div class="summary-pill">Drehzahl: ${Math.round(settings.spindleRPM)} U/min</div>` ++    `<div class="summary-pill">Drehzahl: ${Math.round(settings.spindleRPM)} U/min (Stufe ${settings.dial})</div>` +
     `<div class="summary-pill">Depth/Pass: ${roundTo(settings.depthPerPass, 2)} mm</div>` +     `<div class="summary-pill">Depth/Pass: ${roundTo(settings.depthPerPass, 2)} mm</div>` +
     `<div class="summary-pill">ca. ${passes} Durchgänge</div>` +     `<div class="summary-pill">ca. ${passes} Durchgänge</div>` +
Line 207: Line 208:
     '<th>Ø Bit [mm]</th>' +     '<th>Ø Bit [mm]</th>' +
     '<th>Bit-Typ</th>' +     '<th>Bit-Typ</th>' +
-    '<th>Drehzahl [U/min]</th>' ++    '<th>Drehzahl [U/min] (DeWalt-Stufe)</th>' +
     '<th>Zähne</th>' +     '<th>Zähne</th>' +
     '<th>Chip Load [mm]</th>' +     '<th>Chip Load [mm]</th>' +
Line 221: Line 222:
     `<td>${roundTo(bitD, 2)}</td>` +     `<td>${roundTo(bitD, 2)}</td>` +
     `<td>${bitType}</td>` +     `<td>${bitType}</td>` +
-    `<td>${Math.round(settings.spindleRPM)}</td>` ++    `<td>${Math.round(settings.spindleRPM)} (Stufe ${settings.dial})</td>` +
     `<td>${settings.flutes}</td>` +     `<td>${settings.flutes}</td>` +
     `<td>${roundTo(chipLoad, 4)}</td>` +     `<td>${roundTo(chipLoad, 4)}</td>` +
Line 235: Line 236:
 } }
  
 +// Zuordnung DeWalt D26200 Drehzahl zu Reglerstufe 1–6
 +function dewaltDialForRPM(rpm) {
 +  const table = [
 +    { dial: 1, rpm: 16000 },
 +    { dial: 2, rpm: 18200 },
 +    { dial: 3, rpm: 20400 },
 +    { dial: 4, rpm: 22600 },
 +    { dial: 5, rpm: 24800 },
 +    { dial: 6, rpm: 27000 }
 +  ];
 +
 +  let best = table[0];
 +  let bestDiff = Math.abs(rpm - best.rpm);
 +
 +  for (let i = 1; i < table.length; i++) {
 +    const d = Math.abs(rpm - table[i].rpm);
 +    if (d < bestDiff) {
 +      bestDiff = d;
 +      best = table[i];
 +    }
 +  }
 +  return best.dial;
 +}
 +
 +// Berechnung der Parameter
 function computeSettings(material, thickness, bitDiameter, bitType) { function computeSettings(material, thickness, bitDiameter, bitType) {
   let baseFeed;   let baseFeed;
Line 252: Line 278:
       plunge = 600;       plunge = 600;
       depthFactor = 0.32;       depthFactor = 0.32;
-      spindleRPM = 16000;+      spindleRPM = 16000; // DeWalt Stufe 1
       flutes = 2;       flutes = 2;
       notes =       notes =
Line 261: Line 287:
       plunge = 650;       plunge = 650;
       depthFactor = 0.32;       depthFactor = 0.32;
-      spindleRPM = 16000;+      spindleRPM = 16000; // weiches Holz, DeWalt Stufe 1 ausreichend
       flutes = 2;       flutes = 2;
       notes = 'Weiches Nadelholz; etwas höhere Vorschubgeschwindigkeit möglich.';       notes = 'Weiches Nadelholz; etwas höhere Vorschubgeschwindigkeit möglich.';
Line 270: Line 296:
       plunge = 400;       plunge = 400;
       depthFactor = 0.24;       depthFactor = 0.24;
-      spindleRPM = 16000;+      spindleRPM = 16000; // konservativ, Stufe 1
       flutes = 2;       flutes = 2;
       notes =       notes =
Line 282: Line 308:
       plunge = 700;       plunge = 700;
       depthFactor = 0.32;       depthFactor = 0.32;
-      spindleRPM = 18000;+      spindleRPM = 18000; // nahe DeWalt Stufe 2 (≈18200)
       flutes = 2;       flutes = 2;
       notes =       notes =
Line 292: Line 318:
       plunge = 400;       plunge = 400;
       depthFactor = 0.24;       depthFactor = 0.24;
-      spindleRPM = 16000;+      spindleRPM = 16000; // eher niedrige Drehzahl für Acryl
       flutes = 1;       flutes = 1;
       notes =       notes =
Line 317: Line 343:
       plunge = 250;       plunge = 250;
       depthFactor = 0.12;       depthFactor = 0.12;
-      spindleRPM = 18000;+      spindleRPM = 18000; // kleine Einzahnwerkzeuge, höhere Drehzahl
       flutes = 1;       flutes = 1;
       notes =       notes =
Line 326: Line 352:
       plunge = 220;       plunge = 220;
       depthFactor = 0.1;       depthFactor = 0.1;
-      spindleRPM = 12000;+      spindleRPM = 16000// auf DeWalt-Minimum angehoben (Stufe 1)
       flutes = 2;       flutes = 2;
       notes =       notes =
-        'Metallbearbeitung; geringe Zustelltiefe, gute Spanntechnik und Schmierung notwendig. Empfohlen: 1–2-Schneider-Aluminiumfräser (Upcut).';+        'Metallbearbeitung; geringe Zustelltiefe, gute Spanntechnik und ggf. Schmierung notwendig. Empfohlen: 1–2-Schneider-Aluminiumfräser (Upcut).';
       break;       break;
     default:     default:
Line 373: Line 399:
       notes;       notes;
   }   }
 +
 +  const dial = dewaltDialForRPM(spindleRPM);
  
   return {   return {
Line 381: Line 409:
     flutes: flutes,     flutes: flutes,
     plungeType: plungeType,     plungeType: plungeType,
-    notes: notes+    notes: notes
 +    dial: dial
   };   };
 } }
Line 389: Line 418:
 } }
 </code> </code>
 +
  
  
 ===== html ===== ===== html =====
  
-<code html>+<code> 
 <!doctype html> <!doctype html>
 <html lang="de"> <html lang="de">
 <head> <head>
   <meta charset="utf-8">   <meta charset="utf-8">
-  <title>CNC Feed &amp; Chip-Load Rechner – Creative Technologies Lab, FH Münster</title>+  <title>CNC Feed &amp; Chip-Load Rechner V. 1.01 – Creative Technologies Lab, FH Münster</title>
   <meta name="viewport" content="width=device-width, initial-scale=1">   <meta name="viewport" content="width=device-width, initial-scale=1">
  
Line 571: Line 602:
   // CNC feed suggestion helper with adjustable bit diameter   // CNC feed suggestion helper with adjustable bit diameter
   // Includes spindle speed and chip load calculation   // Includes spindle speed and chip load calculation
 +  // Version 1.01 – angepasst auf DeWalt D26200 Drehzahlstufen
  
   let materialSelect;   let materialSelect;
Line 580: Line 612:
  
   function applyCustomStyles() {   function applyCustomStyles() {
-    // Styles werden im Kopfbereich gesetzt+    // Styles sind im <style>-Block definiert
   }   }
  
Line 592: Line 624:
     const container = select('#calculator-container');     const container = select('#calculator-container');
  
-    const title = createDiv('CNC Feed & Chip-Load Rechner');+    const title = createDiv('CNC Feed & Chip-Load Rechner V. 1.01');
     title.addClass('app-title');     title.addClass('app-title');
     title.parent(container);     title.parent(container);
  
     const subtitle = createDiv(     const subtitle = createDiv(
-      'Konservative Startwerte für Hobby-CNC-Router. Vor Serienfertigung immer an Reststücken testen.'+      'Konservative Startwerte für Hobby-CNC-Router mit DeWalt D26200. Vor Serienfertigung immer an Reststücken testen.'
     );     );
     subtitle.addClass('app-subtitle');     subtitle.addClass('app-subtitle');
Line 756: Line 788:
       `<div class="summary-pill">Plunge: ${Math.round(settings.plungeRate)} mm/min</div>` +       `<div class="summary-pill">Plunge: ${Math.round(settings.plungeRate)} mm/min</div>` +
       `<div class="summary-pill">Chip Load: ${roundTo(chipLoad, 4)} mm/Zahn</div>` +       `<div class="summary-pill">Chip Load: ${roundTo(chipLoad, 4)} mm/Zahn</div>` +
-      `<div class="summary-pill">Drehzahl: ${Math.round(settings.spindleRPM)} U/min</div>` ++      `<div class="summary-pill">Drehzahl: ${Math.round(settings.spindleRPM)} U/min (Stufe ${settings.dial})</div>` +
       `<div class="summary-pill">Depth/Pass: ${roundTo(settings.depthPerPass, 2)} mm</div>` +       `<div class="summary-pill">Depth/Pass: ${roundTo(settings.depthPerPass, 2)} mm</div>` +
       `<div class="summary-pill">ca. ${passes} Durchgänge</div>` +       `<div class="summary-pill">ca. ${passes} Durchgänge</div>` +
Line 768: Line 800:
       '<th>Ø Bit [mm]</th>' +       '<th>Ø Bit [mm]</th>' +
       '<th>Bit-Typ</th>' +       '<th>Bit-Typ</th>' +
-      '<th>Drehzahl [U/min]</th>' ++      '<th>Drehzahl [U/min] (DeWalt-Stufe)</th>' +
       '<th>Zähne</th>' +       '<th>Zähne</th>' +
       '<th>Chip Load [mm]</th>' +       '<th>Chip Load [mm]</th>' +
Line 782: Line 814:
       `<td>${roundTo(bitD, 2)}</td>` +       `<td>${roundTo(bitD, 2)}</td>` +
       `<td>${bitType}</td>` +       `<td>${bitType}</td>` +
-      `<td>${Math.round(settings.spindleRPM)}</td>` ++      `<td>${Math.round(settings.spindleRPM)} (Stufe ${settings.dial})</td>` +
       `<td>${settings.flutes}</td>` +       `<td>${settings.flutes}</td>` +
       `<td>${roundTo(chipLoad, 4)}</td>` +       `<td>${roundTo(chipLoad, 4)}</td>` +
Line 796: Line 828:
   }   }
  
 +  // Zuordnung DeWalt D26200 Drehzahl zu Reglerstufe 1–6
 +  function dewaltDialForRPM(rpm) {
 +    const table = [
 +      { dial: 1, rpm: 16000 },
 +      { dial: 2, rpm: 18200 },
 +      { dial: 3, rpm: 20400 },
 +      { dial: 4, rpm: 22600 },
 +      { dial: 5, rpm: 24800 },
 +      { dial: 6, rpm: 27000 }
 +    ];
 +
 +    let best = table[0];
 +    let bestDiff = Math.abs(rpm - best.rpm);
 +
 +    for (let i = 1; i < table.length; i++) {
 +      const d = Math.abs(rpm - table[i].rpm);
 +      if (d < bestDiff) {
 +        bestDiff = d;
 +        best = table[i];
 +      }
 +    }
 +    return best.dial;
 +  }
 +
 +  // Berechnung der Parameter
   function computeSettings(material, thickness, bitDiameter, bitType) {   function computeSettings(material, thickness, bitDiameter, bitType) {
     let baseFeed;     let baseFeed;
Line 813: Line 870:
         plunge = 600;         plunge = 600;
         depthFactor = 0.32;         depthFactor = 0.32;
-        spindleRPM = 16000;+        spindleRPM = 16000; // DeWalt Stufe 1
         flutes = 2;         flutes = 2;
         notes =         notes =
Line 822: Line 879:
         plunge = 650;         plunge = 650;
         depthFactor = 0.32;         depthFactor = 0.32;
-        spindleRPM = 16000;+        spindleRPM = 16000; // weiches Holz, Stufe 1 ausreichend
         flutes = 2;         flutes = 2;
         notes = 'Weiches Nadelholz; etwas höhere Vorschubgeschwindigkeit möglich.';         notes = 'Weiches Nadelholz; etwas höhere Vorschubgeschwindigkeit möglich.';
Line 831: Line 888:
         plunge = 400;         plunge = 400;
         depthFactor = 0.24;         depthFactor = 0.24;
-        spindleRPM = 16000;+        spindleRPM = 16000; // konservativ, Stufe 1
         flutes = 2;         flutes = 2;
         notes =         notes =
Line 843: Line 900:
         plunge = 700;         plunge = 700;
         depthFactor = 0.32;         depthFactor = 0.32;
-        spindleRPM = 18000;+        spindleRPM = 18000; // nahe Stufe 2 (≈18200 U/min)
         flutes = 2;         flutes = 2;
         notes =         notes =
Line 853: Line 910:
         plunge = 400;         plunge = 400;
         depthFactor = 0.24;         depthFactor = 0.24;
-        spindleRPM = 16000;+        spindleRPM = 16000; // eher niedrige Drehzahl für Acryl
         flutes = 1;         flutes = 1;
         notes =         notes =
Line 878: Line 935:
         plunge = 250;         plunge = 250;
         depthFactor = 0.12;         depthFactor = 0.12;
-        spindleRPM = 18000;+        spindleRPM = 18000; // kleine Einzahnwerkzeuge, höhere Drehzahl
         flutes = 1;         flutes = 1;
         notes =         notes =
Line 887: Line 944:
         plunge = 220;         plunge = 220;
         depthFactor = 0.1;         depthFactor = 0.1;
-        spindleRPM = 12000;+        spindleRPM = 16000// auf DeWalt-Minimum angehoben (Stufe 1)
         flutes = 2;         flutes = 2;
         notes =         notes =
-          'Metallbearbeitung; geringe Zustelltiefe, gute Spanntechnik und Schmierung notwendig. Empfohlen: 1–2-Schneider-Aluminiumfräser (Upcut).';+          'Metallbearbeitung; geringe Zustelltiefe, gute Spanntechnik und ggf. Schmierung notwendig. Empfohlen: 1–2-Schneider-Aluminiumfräser (Upcut).';
         break;         break;
       default:       default:
Line 934: Line 991:
         notes;         notes;
     }     }
 +
 +    const dial = dewaltDialForRPM(spindleRPM);
  
     return {     return {
Line 942: Line 1001:
       flutes: flutes,       flutes: flutes,
       plungeType: plungeType,       plungeType: plungeType,
-      notes: notes+      notes: notes
 +      dial: dial
     };     };
   }   }
/var/www/vhosts/ct-lab.info/wiki.ct-lab.info/data/attic/extras/codikon/p5js/cnc-helper.1764445042.txt.gz · Last modified: by Felix Hardmood Beck