Table of Contents

Spindle Capability Page

The Spindle Capability page edits SpindleCapability attached to the current project's MachiningEquipment (MachiningEquipment; the MachiningProject.MachiningEquipment property itself is internal and therefore not individually linkable). It exposes metadata scalars (name / note / efficiency / working-temperature ceiling), the gear-shift spindle speed, dry-run coefficients, and the power / torque contour lists.

Note

This page exists only in the Quasar webservice. The WPF desktop app has no equivalent today — spindle-capability editing happens via XML through ObjectManagementMenuButton on the Equipment panel in WPF.

Layout

  • Spindle Capability Page
    • Metadata Card
    • Gear Shift Card
      • Has-Gear-Shift CheckBox
      • Gear Shift Spindle Speed NumberField (rpm) — visible when the checkbox is on.
    • Dry Run Card
    • Power Contours Table
      • Rows of { duration key, point count, delete }.
      • Add Contour Button — opens a duration prompt (blank → continuous / ∞) and clones the first existing contour's points as a seed.
    • Torque Contours Table — same shape as the Power Contours table.
    • File Menu
      • Load… — prompts for XML text (read-only paste) plus an optional project-relative path; POSTs to /load which replaces SpindleCapability and stamps SpindleCapabilityFile.
      • Reload — re-reads the file last stamped on the equipment.
      • Save As… — pulls serialised XML via GET /xml and downloads it as a Blob; optionally updates SpindleCapabilityFile.

Behavior

  • Rpm ↔ cycles/s conversion lives server-side. SpindleCapability stores spindle speed in cycles/s (Hz); the controller converts to rpm in DTOs and back on POST. The frontend only sees rpm.
  • Nullable gear shift. The Has-Gear-Shift checkbox flips the value between null (no gear-shift mechanism) and 0 (mechanism present; operator dials in the speed).
  • Project-scoped. Unlike GeneralMechanism (see Mechanism Builder Page), the spindle capability lives on LocalProjectService.MachiningEquipment and is persisted as part of the .hincproj save.
  • Contour seed. Add Contour clones the first existing contour so operators rarely draw from scratch; per-point drag editing is deferred (see below).

Source Code Path

See HiNC App Anatomy for git repository links.

WPF Application Source Code Path

  • Not implemented. Edit via ObjectManagementMenuButton on the Equipment panel using a .SpindleCapability XML file.

Web Page Application Source Code Path

HiNC-2025-webservice (Quasar CLI SPA):

  • wwwroot-src/src/pages/SpindleCapabilityPage.vue — routed page at /equipment/spindle.
  • wwwroot-src/src/api/spindleCapability.ts — typed wrapper over /api/mech/spindle-capability/*.
  • wwwroot-src/src/router/routes.ts/equipment/spindle entry.
  • wwwroot-src/src/layouts/AppMenuBar.vueEnvironment → Spindle Capability menu entry between Controller and Tool House.
  • Mech/SpindleCapabilityController.cs — REST endpoints:
    • GET /api/mech/spindle-capability — flat snapshot (metadata + contour keys).
    • GET /power-contours, GET /torque-contours — per-axis contour lists.
    • PUT /name | /note | /energy-efficiency | /working-temperature-upper-boundary-c | /gear-shift-spindle-speed-rpm | /dry-run-friction-power-coefficient-mwdrpm | /dry-run-windage-power-coefficient-pwdrpm3 — one scalar each.
    • POST /power-contours | /torque-contours — add one contour.
    • DELETE /power-contours/{key} | /torque-contours/{key} — remove one contour ({key} accepts numeric strings and "infinity").
    • GET /xml — serialises to XML text.
    • POST /load | /reload — XML round-trip.
    • PUT /capability-file — set SpindleCapabilityFile without reloading.

Deferred

  • Full contour-curve editor (per-point drag on a chart). Tracked with the uPlot chart engine introduced in Section O of the pages-migration plan.
  • ObjectManagementMenuButton integration. The File menu currently uses a plain XML-paste prompt; revisit once the widget gains an “apply XML without a project-scoped target” mode.