Patent ID: 8851469

Claim:
A sheet conveying apparatus, comprising: a conveying unit configured to convey a sheet; an acquisition unit configured to acquire a size of the sheet in a width direction orthogonal to a conveying direction of the sheet; a light source configured to irradiate the sheet with light; a line sensor configured to receive light from the light source and including a plurality of reading pixels for detecting a side edge position of the sheet in the width direction; a determination unit configured to determine the reading pixels within a predetermined range facing the sheet in the line sensor as reading pixels to be used for light quantity adjustment of the light source based on the size acquired by the acquisition unit; a light quantity adjustment unit configured to adjust a light quantity of the light source based on outputs from the reading pixels determined by the determination unit; a threshold value determination unit configured to determine, after the light quantity is adjusted by the light quantity adjustment unit, a threshold value for detecting the side edge position of the sheet based on outputs from the reading pixels within the region facing the sheet in the line sensor and outputs from reading pixels within a region not facing the sheet; and a position detection unit configured to detect the side edge position of the sheet based on outputs from the plurality of reading pixels of the line sensor and the threshold value determined by the threshold value determination unit.