---
title: M26, M27 (Rotary axis clamping)
slug: m26-m27-rotary-axis-clamping
docTags: 
createdAt: 2023-04-18T13:13:28.000Z
---

The *A* axis is often used to rotate the workpiece on the machine and then do milling on that side of the workpiece. To be sure the workpiece is fixed in its place an axis clamp (Brake) can be used for *A*.&#x20;

`M26 Q... P...` where the *Q* parameter specifies the axis and the *P* parameter specifies an AUX output that will enable the clamp and the optional `P1` specifies the output that controls the brake, e.g. `M26 Qa P1`, `Qa` specifies axis A, `P1` specifies AUX1.

`M27 Q...` disables the clamp on the axis specified by the *Q* parameter, e.g. `M27 Qc` disables the clamp for axis C.&#x20;

When `M26` is active, the software does not accept motion such as from *G-Code* and jogging, an error message will appear that the axis is clamped.
