An injection device comprising: a housing arranged to contain a liquid medicament or a medicament cartridge an electrical coil arranged at the housing a removable cap arranged to be removably engaged with an end of the housing and a magnet arranged within the removable cap wherein when the removable cap is disengaged from the housing, the magnet moves with respect to the electrical coil such that electrical voltage is induced in the electrical coil and a current is generated.