A surgical device is disclosed, which has a loading unit (20) having a cartridge assembly(1230), anvil assembly (1207), and a stapling drive member (1213) with a flange (1214) that engages at least one of the cartridge assembly and anvil assembly, the loading unit having a body portion; and a mechanical feature (1020) on the at least one of the cartridge assembly and anvil assembly, the mechanical feature being arranged to be engaged by the flange, the mechanical feature being indicative of an aspect of the loading unit. The mechanical feature can indicate the staple line length, staple size, type of loading unit, and/or whether the loading unit has been fired, for a surgical stapling device.