A syringe includes a plunger having multiple sections of differing diameters or materials, and a barrel with a cavity into which the plunger is inserted. The barrel includes a first probe and a second probe opposite to one another such that an interior volume of the barrel is radially between the first and second probes. A microcontroller is configured to measure a capacitance between the first and second probes, with the measured capacitance having a first capacitance value when the first section of the plunger shaft is between the first and second probes and a second capacitance value different from the first capacitance value when a second section of the plunger shaft is between the first and second probes. The microcontroller is configured to determine that an injection has been completed when the second capacitance value is measured.