Patent ID: 8857932

Claim:
An image forming apparatus comprising: a print head to discharge liquid droplets; a head tank to contain a liquid to be supplied to the print head; a carriage mounting the print head and the head tank thereon; a main tank to contain a liquid to be supplied to the head tank; a pump to convey the liquid from the main tank to the head tank; a displaceable member disposed on the head tank and displacing in response to an amount of the liquid remaining inside the head tank; a first sensor disposed at the carriage and detecting the displaceable member at a predetermined first position; a second sensor disposed outside the carriage at the apparatus and detecting the displaceable member at a predetermined second position different from the first position, the first position being a position in which the amount of the liquid remaining in the head tank is less than at the second position; a controller to detect and store a displacement difference amount corresponding to a displacement amount of the displaceable member between the position detected by the first sensor and the position detected by the second sensor and to supply an amount of liquid corresponding to the displacement difference amount to the head tank from the main tank, when the liquid is supplied from the main tank to the head tank without using the second sensor after the first sensor detects the displaceable member; and an environmental condition detector to detect an environmental condition in which the apparatus is disposed, the controller being configured to: store the environmental condition detected when the displacement difference amount is stored; calculate and correct the stored displacement difference amount by using a predetermined coefficient, corresponding to the detected environmental condition, without detecting a new displacement difference amount, when a change in a current environmental condition relative to the stored environmental condition is more than a first preset threshold but less than a second preset threshold larger than the first threshold; and detect and store another displacement difference amount without correcting the stored displacement difference amount, when the change in the current environmental condition relative to the stored environmental condition exceeds the second threshold.